/* ── Variables ─────────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
  --bg:       #080c14;
  --bg2:      #0e1420;
  --surface:  #111827;
  --surface2: #1a2235;
  --border:   rgba(255,255,255,0.07);
  --border2:  rgba(255,255,255,0.12);
  --accent:   #6366f1;
  --accent2:  #8b5cf6;
  --green:    #22c55e;
  --red:      #ef4444;
  --yellow:   #f59e0b;
  --blue:     #3b82f6;
  --text:     #f1f5f9;
  --text2:    #94a3b8;
  --text3:    #64748b;
  --sidebar-w: 230px;
  --radius:   14px;
  --shadow:   0 4px 24px rgba(0,0,0,0.4);
}

/* ── Reset ─────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── Scrollbar ──────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface2); border-radius: 99px; }

/* ── Sidebar ────────────────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  padding: 24px 16px;
  gap: 8px;
  transition: transform .3s ease;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px 24px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}
.sidebar-logo svg { width: 32px; height: 32px; flex-shrink: 0; }
.sidebar-logo-text { font-size: 1.15rem; font-weight: 800; letter-spacing: -.5px; }
.sidebar-logo-text span { color: var(--accent); }

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  color: var(--text2);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 500;
  transition: all .18s ease;
  position: relative;
}
.nav-item svg { width: 18px; height: 18px; flex-shrink: 0; opacity: .7; transition: opacity .18s; }
.nav-item:hover { background: var(--surface); color: var(--text); }
.nav-item:hover svg { opacity: 1; }
.nav-item.active {
  background: linear-gradient(135deg, rgba(99,102,241,.2), rgba(139,92,246,.1));
  color: var(--text);
  border: 1px solid rgba(99,102,241,.3);
}
.nav-item.active svg { opacity: 1; }
.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0; top: 25%; bottom: 25%;
  width: 3px;
  background: var(--accent);
  border-radius: 0 99px 99px 0;
}

.sidebar-section-label {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text3);
  padding: 16px 14px 6px;
}

/* Language Switcher */
.lang-switcher {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.lang-label {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text3);
  margin-bottom: 8px;
  padding: 0 4px;
}
.lang-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.lang-btn {
  padding: 7px 4px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text2);
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: all .18s;
  display: block;
}
.lang-btn:hover { background: var(--surface); color: var(--text); border-color: var(--border2); }
.lang-btn.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

/* Location Select */
.location-select {
  width: 100%;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border2);
  border-radius: 8px;
  padding: 7px 10px;
  font-size: .78rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  outline: none;
  transition: border-color .18s;
}
.location-select:hover  { border-color: var(--accent); }
.location-select:focus  { border-color: var(--accent); }
.location-select option { background: var(--surface2); }

/* ── Main Content ────────────────────────────────────────────────────────────── */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
}
.topbar-title { font-size: 1.05rem; font-weight: 700; }
.topbar-time { font-size: .78rem; color: var(--text3); display: flex; align-items: center; gap: 6px; }
.topbar-time .dot { width: 7px; height: 7px; background: var(--green); border-radius: 50%; animation: pulse 2s infinite; }

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .4; }
}

.content { padding: 28px; flex: 1; }

/* ── Cards ───────────────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.card-title {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--text3);
  margin-bottom: 12px;
}

/* ── Stat Cards ──────────────────────────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  position: relative;
  overflow: hidden;
  transition: border-color .2s, transform .2s;
}
.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
}
.stat-card.accent::before  { background: linear-gradient(90deg, var(--accent), var(--accent2)); }
.stat-card.green::before   { background: var(--green); }
.stat-card.blue::before    { background: var(--blue); }
.stat-card.yellow::before  { background: var(--yellow); }
.stat-card:hover { border-color: var(--border2); transform: translateY(-1px); }
.stat-expandable { cursor: pointer; overflow: visible; }
.expand-arrow { font-size: .75rem; margin-left: 4px; opacity: .6; transition: transform .2s; }
.stat-expand-panel {
  display: none;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  animation: fadeIn .18s ease;
}
.stat-expand-panel.open { display: block; }
@keyframes fadeIn { from { opacity:0; transform:translateY(-4px); } to { opacity:1; transform:none; } }
.expand-list { display: flex; flex-direction: column; gap: 6px; }
.expand-row {
  display: flex; align-items: center; gap: 8px;
  font-size: .78rem; padding: 5px 8px;
  background: var(--bg2); border-radius: 7px;
}
.expand-ticker { font-weight: 800; font-family: 'Courier New', monospace; color: var(--accent); min-width: 55px; font-size: .75rem; }
.expand-name   { flex: 1; color: var(--text3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.expand-val    { font-weight: 600; white-space: nowrap; }
.expand-pct    { font-size: .73rem; font-weight: 700; min-width: 52px; text-align: right; }
.expand-best-name  { font-weight: 700; font-size: .85rem; margin-bottom: 10px; color: var(--text); }
.expand-best-grid  { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.expand-best-grid > div { background: var(--bg2); border-radius: 7px; padding: 6px 8px; display: flex; flex-direction: column; gap: 2px; }
.ebd-lbl { font-size: .65rem; color: var(--text3); text-transform: uppercase; letter-spacing: .04em; }
.ebd-val { font-size: .82rem; font-weight: 700; }

.stat-label { font-size: .72rem; font-weight: 600; color: var(--text3); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 6px; }
.stat-value { font-size: 1.7rem; font-weight: 800; line-height: 1; margin-bottom: 4px; }
.stat-value.accent { color: var(--accent); }
.stat-value.green  { color: var(--green); }
.stat-value.blue   { color: var(--blue); }
.stat-value.yellow { color: var(--yellow); }
.stat-sub { font-size: .75rem; color: var(--text3); }
.stat-icon {
  position: absolute;
  top: 16px; right: 16px;
  width: 36px; height: 36px;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
}
.stat-icon.accent { background: rgba(99,102,241,.15); }
.stat-icon.green  { background: rgba(34,197,94,.15); }
.stat-icon.blue   { background: rgba(59,130,246,.15); }
.stat-icon.yellow { background: rgba(245,158,11,.15); }

/* ── Charts Row ──────────────────────────────────────────────────────────────── */
.charts-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 14px;
  margin-bottom: 24px;
}
.chart-container { position: relative; }

/* ── Table ───────────────────────────────────────────────────────────────────── */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: .87rem;
}
thead th {
  background: var(--bg2);
  padding: 11px 16px;
  text-align: left;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--text3);
  white-space: nowrap;
  border-bottom: 1px solid var(--border);
}
tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background .15s;
}
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: var(--surface2); }
td {
  padding: 13px 16px;
  color: var(--text);
  white-space: nowrap;
}
.td-ticker {
  font-weight: 700;
  font-size: .9rem;
  color: var(--accent);
  font-family: 'Courier New', monospace;
}
.td-name { color: var(--text2); font-size: .85rem; max-width: 160px; overflow: hidden; text-overflow: ellipsis; }
.td-num { font-variant-numeric: tabular-nums; font-weight: 600; }
.td-right { text-align: right; }

.badge-up   { color: var(--green); font-weight: 700; }
.badge-down { color: var(--red);   font-weight: 700; }
.badge-neu  { color: var(--text2); }

/* P&L colored */
.pl-pos { color: var(--green); font-weight: 700; }
.pl-neg { color: var(--red);   font-weight: 700; }

/* ── Portfolio Summary Footer ────────────────────────────────────────────────── */
.summary-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 14px;
}
.summary-item {
  background: var(--surface2);
  padding: 14px 20px;
  text-align: center;
}
.summary-item .label { font-size: .7rem; color: var(--text3); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 4px; }
.summary-item .value { font-size: 1.1rem; font-weight: 800; }

/* ── Watchlist Cards ─────────────────────────────────────────────────────────── */
.watch-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
}

.watch-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  position: relative;
  overflow: hidden;
  transition: border-color .2s, transform .2s;
}
.watch-card:hover { border-color: var(--border2); transform: translateY(-2px); }
.watch-card-accent {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  border-radius: var(--radius) var(--radius) 0 0;
}
.watch-card-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 12px; }
.watch-ticker { font-size: 1.05rem; font-weight: 800; color: var(--text); font-family: 'Courier New', monospace; }
.watch-company { font-size: .78rem; color: var(--text3); margin-top: 2px; }
.watch-status-badge {
  font-size: .7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 99px;
  border: 1px solid;
  white-space: nowrap;
}
.watch-price-row { display: flex; gap: 16px; margin-bottom: 10px; }
.watch-price-item .lbl { font-size: .65rem; color: var(--text3); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 2px; }
.watch-price-item .val { font-size: 1rem; font-weight: 700; }
.watch-distance { font-size: .75rem; color: var(--text3); margin-bottom: 10px; }
.watch-notes {
  font-size: .78rem;
  color: var(--text2);
  background: var(--bg2);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 10px;
  line-height: 1.5;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: default;
}
/* floating tooltip for notes — appended to body so overflow:hidden doesn't clip */
.notes-tooltip {
  position: fixed;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: .8rem;
  line-height: 1.55;
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-word;
  max-width: 300px;
  z-index: 9999;
  box-shadow: 0 8px 28px rgba(0,0,0,.65);
  pointer-events: none;
  opacity: 0;
  transition: opacity .15s;
}
.watch-actions { display: flex; gap: 6px; justify-content: flex-end; }
.watch-date { font-size: .68rem; color: var(--text3); margin-right: auto; align-self: center; }

/* ── Filter Bar ──────────────────────────────────────────────────────────────── */
.filter-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.filter-btn {
  padding: 7px 16px;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text2);
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all .18s;
}
.filter-btn:hover { border-color: var(--border2); color: var(--text); }
.filter-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ── Buttons ─────────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: 9px;
  border: 1px solid transparent;
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
  text-decoration: none;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover { background: #5254cc; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(99,102,241,.35); }
.btn-ghost {
  background: transparent;
  border-color: var(--border2);
  color: var(--text2);
}
.btn-ghost:hover { background: var(--surface2); color: var(--text); }
.btn-danger {
  background: rgba(239,68,68,.15);
  color: var(--red);
  border-color: rgba(239,68,68,.3);
}
.btn-danger:hover { background: rgba(239,68,68,.25); }
.btn-sm { padding: 6px 12px; font-size: .78rem; border-radius: 7px; }
.btn-icon {
  width: 30px; height: 30px;
  padding: 0;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: .85rem;
}

/* ── Forms ───────────────────────────────────────────────────────────────────── */
.form-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
  display: none;
  animation: fadeDown .25s ease;
}
.form-panel.open { display: block; }

@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: .75rem; font-weight: 600; color: var(--text2); }
.form-input {
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: 8px;
  padding: 9px 12px;
  color: var(--text);
  font-size: .88rem;
  font-family: inherit;
  outline: none;
  transition: border-color .18s, box-shadow .18s;
}
.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
}
.form-input::placeholder { color: var(--text3); }
select.form-input { cursor: pointer; }
textarea.form-input { resize: vertical; min-height: 68px; }
.form-actions { display: flex; gap: 8px; margin-top: 16px; }
.form-hint { font-size: .72rem; color: var(--text3); margin-top: 3px; }

/* ── Page Header ─────────────────────────────────────────────────────────────── */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 12px;
}
.page-title { font-size: 1.3rem; font-weight: 800; }

/* ── Dashboard Watchlist Row ──────────────────────────────────────────────────── */
.wl-period-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
}
.wl-period-btn {
  padding: 4px 14px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface2);
  color: var(--text3);
  font-size: .75rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s;
}
.wl-period-btn:hover  { border-color: var(--accent); color: var(--accent); }
.wl-period-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ── Exchange Status Bar ───────────────────────────────────────────────────── */
#exch-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.exch-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 14px 8px;
  border-radius: 12px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  min-width: 82px;
  gap: 2px;
  cursor: default;
  transition: background .2s, border-color .2s;
}
.exch-card-code {
  font-size: .85rem;
  font-weight: 800;
  letter-spacing: .06em;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}
.exch-card-name {
  font-size: .65rem;
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  letter-spacing: .03em;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}
.exch-card-status {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 5px;
  padding: 3px 8px;
  border-radius: 20px;
  background: var(--surface2);
}
.exch-card-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.exch-card-txt {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
  white-space: nowrap;
}
.exch-card.exch-open {
  border-color: #16a34a;
  background: #16a34a14;
}
.exch-card.exch-open .exch-card-status { background: #16a34a25; }
.exch-card.exch-open .exch-card-dot    { background: #22c55e; animation: live-ripple 1.8s ease-out infinite; }
.exch-card.exch-open .exch-card-txt    { color: #fff; }
.exch-card.exch-closed {
  border-color: rgba(239,68,68,.2);
  background: rgba(239,68,68,.04);
}
.exch-card.exch-closed .exch-card-status { background: rgba(239,68,68,.1); }
.exch-card.exch-closed .exch-card-dot   { background: #ef4444; }
.exch-card.exch-closed .exch-card-txt   { color: #fff; }
.exch-card-timer {
  font-size: .63rem;
  font-weight: 700;
  color: rgba(255,255,255,0.92);
  text-shadow: 0 1px 4px rgba(0,0,0,0.9);
  letter-spacing: .01em;
  margin-top: 2px;
  text-align: center;
}

.dash-watch-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 700px) {
  .dash-watch-split { grid-template-columns: 1fr; }
}
.dash-watch-col { display: flex; flex-direction: column; gap: 8px; }
.dash-watch-col-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .04em;
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid;
  margin-bottom: 2px;
}
.dash-col-count {
  font-size: .72rem;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 10px;
}
.dash-col-empty {
  font-size: .8rem;
  color: var(--text3);
  text-align: center;
  padding: 18px 0;
  font-style: italic;
}
.dash-watch-list { display: flex; flex-direction: column; gap: 8px; }
.dash-watch-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: var(--bg2);
  border-radius: 10px;
  border: 1px solid var(--border);
  transition: border-color .15s;
}
.dash-watch-row:hover { border-color: var(--border2); }
.dash-watch-ticker { font-weight: 800; font-size: .9rem; font-family: 'Courier New', monospace; color: var(--accent); min-width: 60px; }
.dash-watch-name { font-size: .8rem; color: var(--text3); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-watch-price { font-weight: 700; font-size: .9rem; }
.dash-watch-chg { font-size: .78rem; font-weight: 600; min-width: 58px; text-align: right; }

/* ── Toast ───────────────────────────────────────────────────────────────────── */
#toast-container {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: 10px;
  padding: 12px 18px;
  font-size: .85rem;
  font-weight: 500;
  box-shadow: var(--shadow);
  animation: slideIn .25s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 220px;
}
.toast.success { border-left: 3px solid var(--green); }
.toast.error   { border-left: 3px solid var(--red); }

@keyframes slideIn {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* ── Price Lookup Preview ────────────────────────────────────────────────────── */
.price-preview {
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .82rem;
  display: none;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
}
.price-preview.show { display: flex; }
.price-preview .pp-name { font-weight: 600; flex: 1; }
.price-preview .pp-price { font-weight: 800; color: var(--accent); }
.price-preview .pp-chg { font-size: .78rem; }

/* ── Modal ───────────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.open { display: flex; animation: fadeIn .2s ease; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.modal {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: 16px;
  padding: 28px;
  width: 100%;
  max-width: 460px;
  box-shadow: 0 24px 64px rgba(0,0,0,.6);
  animation: scaleIn .2s ease;
}
@keyframes scaleIn {
  from { opacity: 0; transform: scale(.95); }
  to   { opacity: 1; transform: scale(1); }
}
.modal-title { font-size: 1.05rem; font-weight: 700; margin-bottom: 18px; }

/* ── Spinner ─────────────────────────────────────────────────────────────────── */
.spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,.2);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Empty State ─────────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text3);
}
.empty-state .empty-icon { font-size: 3rem; margin-bottom: 12px; }
.empty-state p { font-size: .9rem; }

/* ── Ticker Badge ────────────────────────────────────────────────────────────── */
.ticker-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(99,102,241,.12);
  border: 1px solid rgba(99,102,241,.25);
  border-radius: 7px;
  padding: 3px 9px;
  font-size: .78rem;
  font-weight: 700;
  color: var(--accent);
  font-family: 'Courier New', monospace;
}

/* ── Mobile ──────────────────────────────────────────────────────────────────── */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  font-size: 1.3rem;
  padding: 4px;
}

@media (max-width: 900px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .charts-grid { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.mobile-open { transform: translateX(0); }
  .main { margin-left: 0; }
  .content { padding: 16px; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .watch-grid { grid-template-columns: 1fr; }
  .menu-toggle { display: block; }
  .summary-bar { grid-template-columns: 1fr; }
  .page-header { flex-wrap: wrap; }
  .form-grid { grid-template-columns: 1fr; }
}

/* ── Category Badge ──────────────────────────────────────────────────────────── */
.cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: .72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid;
  white-space: nowrap;
  letter-spacing: .02em;
}

/* Count pill on filter buttons */
.cat-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  background: rgba(255,255,255,.15);
  border-radius: 99px;
  font-size: .65rem;
  font-weight: 800;
  padding: 0 5px;
  margin-left: 4px;
}

/* ── Utility ─────────────────────────────────────────────────────────────────── */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.mt-4  { margin-top: 4px; }
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mb-16 { margin-bottom: 16px; }
.mb-20 { margin-bottom: 20px; }
.text-muted { color: var(--text3); font-size: .78rem; }
.text-right { text-align: right; }
.w-full { width: 100%; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── Live pulse animation ────────────────────────────────────────────────────── */
@keyframes live-ripple {
  0%   { box-shadow: 0 0 0 0   rgba(34,197,94,.8); }
  70%  { box-shadow: 0 0 0 8px rgba(34,197,94,0);  }
  100% { box-shadow: 0 0 0 0   rgba(34,197,94,0);  }
}
.live-pulse {
  animation: live-ripple 1.4s ease-out infinite;
}

/* ── Buy Button ──────────────────────────────────────────────────────────────── */
.btn-buy {
  background: #22c55e18;
  border: 1px solid #22c55e40;
  color: #22c55e;
  padding: 4px 10px;
  border-radius: 7px;
  font-size: .75rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s;
  font-family: 'Inter', sans-serif;
}
.btn-buy:hover {
  background: #22c55e;
  border-color: #22c55e;
  color: #fff;
}

/* ── Watchlist nav sub-items ─────────────────────────────────────────────────── */
.nav-watch {
  padding-left: 22px;
  font-size: .82rem;
}
.wl-flag { font-size: 1rem; width: 22px; text-align: center; flex-shrink: 0; }
.wl-flag-img { width: 18px; height: 12px; object-fit: cover; border-radius: 2px; flex-shrink: 0; opacity: .9; }
.wl-label { display: flex; align-items: center; gap: 5px; flex: 1; }
.wl-cur { font-size: .75rem; font-weight: 800; letter-spacing: .04em; }
.wl-exch { font-size: .68rem; color: #64748b; margin-left: auto; }
.nav-wl-upgrade {
  color: #f59e0b !important; border: 1px dashed #f59e0b33;
  border-radius: 6px; margin-top: 4px; justify-content: center;
  padding: 5px 8px !important; font-weight: 600;
}
.nav-wl-upgrade:hover { background: #f59e0b15 !important; }

/* ── Card click hint ─────────────────────────────────────────────────────────── */
.card-click-hint {
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: .62rem;
  color: var(--text3);
  opacity: 0;
  transition: opacity .2s;
  pointer-events: none;
}
.watch-card:hover .card-click-hint { opacity: 1; }

/* ── Chart / Detail Modal ────────────────────────────────────────────────────── */
.chart-overlay {
  z-index: 300;
}
.chart-overlay.open {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.chart-modal {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: 20px;
  width: 100%;
  max-width: 960px;
  max-height: 92vh;
  overflow-y: auto;
  padding: 28px 28px 24px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,.7);
  animation: modalIn .25s ease;
}

/* ── Chart Modal Header ───────────────────────────────────────────────────────── */
.chart-modal-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 20px;
}
.chart-modal-title-area {
  flex: 1;
}
.dm-ticker {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -.02em;
  color: var(--text);
  line-height: 1;
}
.dm-name {
  font-size: .82rem;
  color: var(--text3);
  margin-top: 4px;
  max-width: 340px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dm-price-area {
  text-align: right;
}
.dm-price {
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1;
}
.dm-change {
  font-size: .82rem;
  font-weight: 600;
  margin-top: 5px;
}
.chart-modal-close {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text2);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
  flex-shrink: 0;
}
.chart-modal-close:hover {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* ── Portfolio detail stats bar ──────────────────────────────────────────────── */
.port-detail-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
  padding: 14px;
  background: var(--bg2);
  border-radius: 12px;
}
.pds-item { text-align: center; }
.pds-lbl  { font-size: .65rem; color: var(--text3); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; margin-bottom: 4px; }
.pds-val  { font-size: .92rem; font-weight: 700; color: var(--text); }

@media (max-width: 500px) {
  .port-detail-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ── Period Button Bar ────────────────────────────────────────────────────────── */
.period-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.period-btn {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text3);
  padding: 6px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .04em;
  transition: all .18s;
  font-family: 'Inter', sans-serif;
}
.period-btn:hover {
  background: var(--surface2);
  border-color: var(--accent);
  color: var(--text);
}
.period-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ── Chart Canvas Area ────────────────────────────────────────────────────────── */
.chart-area {
  position: relative;
  height: 260px;
  background: var(--bg2);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 10px;
}
.chart-area canvas {
  width: 100% !important;
  height: 100% !important;
}
.chart-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg2);
}

/* ── Volume info line ─────────────────────────────────────────────────────────── */
.volume-info {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 0 12px;
}

/* ── Metrics Grid ─────────────────────────────────────────────────────────────── */
.dm-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.dm-metric {
  background: var(--bg2);
  border-radius: 10px;
  padding: 12px 14px;
}
.dm-metric-lbl {
  font-size: .68rem;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  margin-bottom: 5px;
}
.dm-metric-val {
  font-size: .92rem;
  font-weight: 700;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ── Responsive chart modal ───────────────────────────────────────────────────── */
@media (max-width: 700px) {
  .chart-modal {
    padding: 18px 14px 18px;
    border-radius: 16px;
  }
  .chart-modal-header { flex-wrap: wrap; }
  .dm-price-area { text-align: left; }
  .chart-area { height: 200px; }
  .dm-metrics { grid-template-columns: repeat(2, 1fr); }
  .period-btn { padding: 5px 10px; font-size: .75rem; }
}


/* ══════════════════════════════════════════════════════════════════════════════
   AUTH PAGES (login / register)
══════════════════════════════════════════════════════════════════════════════ */
.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  background-image: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(99,102,241,.15), transparent);
  padding: 24px;
}
.auth-wrap { width: 100%; max-width: 420px; display: flex; flex-direction: column; align-items: center; gap: 24px; }
.auth-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-size: 1.3rem; font-weight: 800; letter-spacing: -.5px; }
.auth-logo span { color: var(--accent); }
.auth-card { width: 100%; background: var(--surface); border: 1px solid var(--border2); border-radius: 20px; padding: 36px 32px; display: flex; flex-direction: column; }
.auth-title { font-size: 1.5rem; font-weight: 800; margin-bottom: 6px; color: var(--text); }
.auth-sub { font-size: .88rem; color: var(--text2); margin-bottom: 24px; }
.auth-error { background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.3); color: #fca5a5; border-radius: 10px; padding: 10px 14px; font-size: .85rem; margin-bottom: 18px; }
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-field { display: flex; flex-direction: column; gap: 6px; }
.auth-field label { font-size: .82rem; font-weight: 600; color: var(--text2); }
.auth-field input { background: var(--bg2); border: 1px solid var(--border2); border-radius: 10px; padding: 11px 14px; color: var(--text); font-size: .92rem; font-family: inherit; outline: none; transition: border-color .2s; }
.auth-field input:focus { border-color: var(--accent); }
.auth-hint { font-weight: 400; color: var(--text3); font-size: .78rem; }
.auth-submit { background: linear-gradient(135deg, var(--accent), var(--accent2)); color: #fff; border: none; border-radius: 12px; padding: 13px; font-size: .95rem; font-weight: 700; cursor: pointer; margin-top: 4px; transition: opacity .2s, transform .15s; font-family: inherit; }
.auth-submit:hover { opacity: .9; transform: translateY(-1px); }
.auth-divider { text-align: center; color: var(--text3); font-size: .82rem; margin: 18px 0 10px; }
.auth-link-btn { display: block; text-align: center; padding: 11px; border: 1.5px solid var(--border2); border-radius: 12px; color: var(--text); text-decoration: none; font-size: .9rem; font-weight: 600; transition: border-color .2s, background .2s; }
.auth-link-btn:hover { border-color: var(--accent); background: rgba(99,102,241,.07); }
.auth-terms { text-align: center; color: var(--text3); font-size: .75rem; margin-top: 16px; line-height: 1.5; }
.auth-footer { color: var(--text3); font-size: .75rem; }

/* Sidebar User + Upgrade Banner */
.sidebar-user { padding: 10px 12px; background: var(--surface); border-radius: 10px; border: 1px solid var(--border); margin-top: 4px; }
.sidebar-user-email { font-size: .72rem; color: var(--text2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 4px; }
.sidebar-plan { font-size: .7rem; font-weight: 700; border-radius: 6px; padding: 2px 8px; display: inline-block; }
.sidebar-plan-pro { background: linear-gradient(135deg, rgba(99,102,241,.25), rgba(139,92,246,.15)); color: #a78bfa; border: 1px solid rgba(99,102,241,.3); }
.sidebar-plan-free { color: var(--accent); text-decoration: none; background: transparent; padding: 0; }
.sidebar-plan-free:hover { text-decoration: underline; }
.upgrade-banner { background: linear-gradient(135deg, rgba(99,102,241,.18), rgba(139,92,246,.10)); border-bottom: 1px solid rgba(99,102,241,.25); padding: 9px 24px; font-size: .82rem; color: #c4b5fd; display: flex; align-items: center; gap: 12px; }
.upgrade-banner a { color: #a78bfa; font-weight: 700; text-decoration: none; white-space: nowrap; }
.upgrade-banner a:hover { text-decoration: underline; }
.plan-badge { padding: 6px 16px; border-radius: 99px; font-size: .8rem; font-weight: 700; align-self: center; }
.plan-badge-pro { background: linear-gradient(135deg, rgba(99,102,241,.2), rgba(139,92,246,.1)); color: #a78bfa; border: 1px solid rgba(99,102,241,.4); }
.plan-badge-free { background: rgba(255,255,255,.05); color: var(--text2); border: 1px solid var(--border2); }

/* Account Page */
.acc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 24px; }
@media (max-width: 640px) { .acc-grid { grid-template-columns: 1fr; } }
.acc-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }
.acc-card-title { font-size: .75rem; font-weight: 700; color: var(--text3); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 14px; }
.acc-plan-name { font-size: 1.4rem; font-weight: 800; margin-bottom: 10px; }
.acc-plan-pro { color: #a78bfa; }
.acc-plan-desc { font-size: .88rem; color: var(--text2); line-height: 1.5; }
.acc-usage-label { font-size: .82rem; color: var(--text2); margin-bottom: 6px; }
.acc-usage-bar-wrap { height: 6px; background: var(--surface2); border-radius: 99px; overflow: hidden; margin-bottom: 4px; }
.acc-usage-bar { height: 100%; border-radius: 99px; transition: width .4s; min-width: 4px; }
.acc-usage-count { font-size: .78rem; color: var(--text3); }
.acc-upgrade-section { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; margin-bottom: 24px; }
.acc-upgrade-title { font-size: 1.15rem; font-weight: 800; margin-bottom: 8px; }
.acc-upgrade-sub { color: var(--text2); font-size: .88rem; margin-bottom: 24px; }
.acc-plans { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) { .acc-plans { grid-template-columns: 1fr; } }
.acc-plan-card { background: var(--bg2); border: 1.5px solid var(--border); border-radius: 14px; padding: 22px; display: flex; flex-direction: column; gap: 10px; position: relative; padding-top: 28px; }
.acc-plan-featured { border-color: rgba(99,102,241,.5); background: linear-gradient(160deg, rgba(99,102,241,.1), var(--bg2)); }
.acc-plan-badge { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); background: var(--accent); color: #fff; font-size: .7rem; font-weight: 700; padding: 3px 12px; border-radius: 99px; white-space: nowrap; }
.acc-plan-badge-green { background: #16a34a; }
.acc-plan-name-lg { font-size: 1rem; font-weight: 700; }
.acc-plan-price-lg { font-size: 2rem; font-weight: 800; color: var(--text); }
.acc-plan-price-lg span { font-size: .9rem; font-weight: 500; color: var(--text2); }
.acc-plan-list { list-style: none; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.acc-plan-list li { font-size: .85rem; color: var(--text2); }
.acc-stripe-note { font-size: .78rem; color: var(--text3); text-align: center; padding: 8px; }
.acc-danger { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 24px; display: flex; align-items: center; gap: 20px; }
.btn-danger { border-color: rgba(239,68,68,.4) !important; color: #fca5a5 !important; }
.btn-danger:hover { background: rgba(239,68,68,.08) !important; }
.btn-outline { display: inline-block; padding: 9px 20px; border: 1.5px solid var(--border2); border-radius: 10px; color: var(--text); text-decoration: none; font-size: .88rem; font-weight: 600; transition: border-color .2s, background .2s; cursor: pointer; background: transparent; font-family: inherit; }
.btn-outline:hover { border-color: var(--accent); background: rgba(99,102,241,.07); }
.alert-error { background: rgba(239,68,68,.1); border: 1px solid rgba(239,68,68,.25); color: #fca5a5; border-radius: 10px; padding: 12px 16px; font-size: .88rem; }

/* Pro Locked */
.pro-locked-wrap { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 60vh; text-align: center; padding: 40px 24px; }
.pro-locked-icon { font-size: 3.5rem; margin-bottom: 16px; filter: drop-shadow(0 0 20px rgba(99,102,241,.6)); }
.pro-locked-title { font-size: 1.6rem; font-weight: 800; margin-bottom: 10px; }
.pro-locked-sub { color: var(--text2); font-size: 1rem; margin-bottom: 24px; }
.pro-locked-features { display: flex; flex-direction: column; gap: 8px; color: var(--text2); font-size: .9rem; margin-bottom: 8px; }
.pro-locked-feat { color: #86efac; font-weight: 500; }

/* Landing Page */
.landing-body { display: block !important; background: #080c14; }
.lp-nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: rgba(8,12,20,.85); backdrop-filter: blur(16px); border-bottom: 1px solid rgba(255,255,255,.06); }
.lp-nav-inner { max-width: 1100px; margin: 0 auto; padding: 0 24px; height: 64px; display: flex; align-items: center; gap: 32px; }
.lp-logo { display: flex; align-items: center; gap: 8px; text-decoration: none; color: #f1f5f9; font-size: 1.1rem; font-weight: 800; letter-spacing: -.4px; flex-shrink: 0; }
.lp-logo span { color: #6366f1; }
.lp-nav-links { display: flex; gap: 24px; flex: 1; }
.lp-nav-links a { text-decoration: none; color: #94a3b8; font-size: .9rem; font-weight: 500; transition: color .2s; }
.lp-nav-links a:hover { color: #f1f5f9; }
.lp-nav-cta { display: flex; gap: 10px; align-items: center; flex-shrink: 0; }
.lp-btn-primary { background: linear-gradient(135deg, #6366f1, #8b5cf6); color: #fff; padding: 9px 20px; border-radius: 10px; font-weight: 700; font-size: .9rem; text-decoration: none; transition: opacity .2s, transform .15s; display: inline-block; }
.lp-btn-primary:hover { opacity: .9; transform: translateY(-1px); }
.lp-btn-ghost { color: #94a3b8; padding: 9px 16px; border-radius: 10px; font-weight: 600; font-size: .9rem; text-decoration: none; transition: color .2s, background .2s; display: inline-block; }
.lp-btn-ghost:hover { color: #f1f5f9; background: rgba(255,255,255,.06); }
.lp-btn-lg { padding: 14px 28px; font-size: 1rem; border-radius: 12px; }
.lp-hero { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 100px 24px 60px; position: relative; overflow: hidden; gap: 48px; }
.lp-hero-glow { position: absolute; top: -200px; left: 50%; transform: translateX(-50%); width: 800px; height: 600px; background: radial-gradient(ellipse, rgba(99,102,241,.2) 0%, transparent 70%); pointer-events: none; }
.lp-hero-content { text-align: center; max-width: 700px; z-index: 1; }
.lp-badge { display: inline-block; background: rgba(99,102,241,.15); border: 1px solid rgba(99,102,241,.35); color: #a78bfa; padding: 5px 16px; border-radius: 99px; font-size: .78rem; font-weight: 700; margin-bottom: 20px; }
.lp-h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 900; line-height: 1.15; letter-spacing: -.04em; color: #f1f5f9; margin-bottom: 20px; }
.lp-gradient { background: linear-gradient(135deg, #818cf8, #a78bfa, #c084fc); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.lp-sub { font-size: 1.05rem; color: #94a3b8; line-height: 1.65; margin-bottom: 32px; }
.lp-hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.lp-mockup { width: 100%; max-width: 680px; background: #0e1420; border: 1px solid rgba(255,255,255,.1); border-radius: 16px; overflow: hidden; box-shadow: 0 40px 80px rgba(0,0,0,.6); z-index: 1; }
.lp-mockup-bar { background: #0e1420; border-bottom: 1px solid rgba(255,255,255,.07); padding: 10px 16px; display: flex; align-items: center; gap: 6px; }
.lp-dot-r,.lp-dot-y,.lp-dot-g { width: 10px; height: 10px; border-radius: 50%; }
.lp-dot-r { background: #ef4444; } .lp-dot-y { background: #f59e0b; } .lp-dot-g { background: #22c55e; }
.lp-mockup-body { display: flex; height: 280px; }
.lp-mock-sidebar { width: 48px; background: #0a0f1a; border-right: 1px solid rgba(255,255,255,.06); padding: 12px 8px; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.lp-mock-logo { width: 30px; height: 30px; background: linear-gradient(135deg,#6366f1,#8b5cf6); border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: .55rem; font-weight: 900; color: white; margin-bottom: 8px; }
.lp-mock-nav { width: 28px; height: 5px; background: rgba(255,255,255,.1); border-radius: 3px; }
.lp-mock-nav.active { background: #6366f1; }
.lp-mock-content { flex: 1; padding: 14px; overflow: hidden; }
.lp-mock-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-bottom: 12px; }
.lp-mock-card { background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.07); border-radius: 8px; padding: 8px 10px; }
.lp-mock-card.green { border-color: rgba(34,197,94,.2); } .lp-mock-card.blue { border-color: rgba(59,130,246,.2); } .lp-mock-card.purple { border-color: rgba(99,102,241,.2); }
.lp-mock-label { font-size: .55rem; color: #64748b; margin-bottom: 2px; }
.lp-mock-val { font-size: .8rem; font-weight: 800; color: #f1f5f9; }
.lp-mock-chg { font-size: .55rem; color: #22c55e; font-weight: 600; }
.lp-mock-chart { background: rgba(255,255,255,.02); border-radius: 8px; padding: 8px; margin-bottom: 10px; border: 1px solid rgba(255,255,255,.05); }
.lp-mock-wl { display: flex; flex-direction: column; gap: 5px; }
.lp-mock-wl-row { display: flex; justify-content: space-between; padding: 4px 8px; background: rgba(255,255,255,.025); border-radius: 5px; font-size: .62rem; }
.lp-mock-tick { color: #94a3b8; font-weight: 700; } .lp-mock-price { color: #f1f5f9; font-weight: 600; }
.lp-mock-up { color: #22c55e; font-weight: 700; } .lp-mock-dn { color: #ef4444; font-weight: 700; }
.lp-stats { display: flex; justify-content: center; align-items: center; padding: 24px; border-top: 1px solid rgba(255,255,255,.06); border-bottom: 1px solid rgba(255,255,255,.06); background: rgba(255,255,255,.015); flex-wrap: wrap; }
.lp-stat { display: flex; flex-direction: column; align-items: center; padding: 12px 40px; }
.lp-stat-n { font-size: 1.6rem; font-weight: 900; color: #f1f5f9; }
.lp-stat-l { font-size: .78rem; color: #64748b; margin-top: 2px; }
.lp-stat-div { width: 1px; height: 40px; background: rgba(255,255,255,.08); }
.lp-section { padding: 80px 24px; }
.lp-section-dark { background: rgba(255,255,255,.02); border-top: 1px solid rgba(255,255,255,.05); border-bottom: 1px solid rgba(255,255,255,.05); }
.lp-section-inner { max-width: 1100px; margin: 0 auto; }
.lp-section-label { font-size: .75rem; font-weight: 700; color: #6366f1; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 12px; }
.lp-h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); font-weight: 900; letter-spacing: -.03em; line-height: 1.2; color: #f1f5f9; margin-bottom: 48px; }
.lp-features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.lp-feature-card { background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.07); border-radius: 16px; padding: 28px 24px; transition: border-color .2s, background .2s; }
.lp-feature-card:hover { border-color: rgba(99,102,241,.3); background: rgba(99,102,241,.04); }
.lp-feature-icon { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; margin-bottom: 16px; }
.lp-feature-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 8px; }
.lp-feature-card p { font-size: .88rem; color: #94a3b8; line-height: 1.6; }
.lp-exch-preview { display: flex; flex-wrap: wrap; gap: 10px; }
.lp-exch-card { background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); border-radius: 10px; padding: 10px 14px; display: flex; align-items: center; gap: 8px; transition: border-color .2s; }
.lp-exch-card:hover { border-color: rgba(99,102,241,.35); }
.lp-exch-flag { width: 24px; height: 16px; object-fit: cover; border-radius: 2px; }
.lp-exch-code { font-size: .75rem; font-weight: 800; color: #f1f5f9; }
.lp-exch-name { font-size: .68rem; color: #64748b; }
.lp-exch-status { font-size: .65rem; font-weight: 700; color: #22c55e; background: rgba(34,197,94,.1); padding: 1px 6px; border-radius: 4px; }
.lp-pricing { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.lp-plan { background: rgba(255,255,255,.03); border: 1.5px solid rgba(255,255,255,.08); border-radius: 20px; padding: 32px 28px 28px; display: flex; flex-direction: column; gap: 12px; position: relative; }
.lp-plan-featured { border-color: rgba(99,102,241,.5); background: linear-gradient(160deg, rgba(99,102,241,.1), rgba(255,255,255,.02)); box-shadow: 0 0 40px rgba(99,102,241,.12); }
.lp-plan-badge { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: linear-gradient(135deg, #6366f1, #8b5cf6); color: #fff; font-size: .7rem; font-weight: 800; padding: 4px 16px; border-radius: 99px; white-space: nowrap; }
.lp-plan-badge-green { background: linear-gradient(135deg, #16a34a, #22c55e); }
.lp-plan-name { font-size: .95rem; font-weight: 700; color: #94a3b8; margin-top: 6px; }
.lp-plan-price { display: flex; align-items: baseline; gap: 4px; }
.lp-plan-amount { font-size: 2.4rem; font-weight: 900; color: #f1f5f9; }
.lp-plan-per { font-size: .88rem; color: #64748b; }
.lp-plan-desc { font-size: .82rem; color: #64748b; }
.lp-plan-features { list-style: none; display: flex; flex-direction: column; gap: 8px; flex: 1; margin-bottom: 8px; }
.lp-plan-features li { font-size: .88rem; color: #94a3b8; padding-left: 18px; position: relative; }
.lp-plan-features li::before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 12px; height: 12px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,.15); }
.lp-plan-features li.yes { color: #cbd5e1; }
.lp-plan-features li.yes::before { background: #22c55e; border-color: #22c55e; }
.lp-plan-features li.no { color: #475569; }
.lp-plan-features li.no::before { background: rgba(255,255,255,.08); }
.lp-plan-btn { display: block; text-align: center; padding: 13px; border-radius: 12px; font-size: .92rem; font-weight: 700; text-decoration: none; transition: opacity .2s, transform .15s; margin-top: auto; }
.lp-plan-btn-primary { background: linear-gradient(135deg, #6366f1, #8b5cf6); color: #fff; }
.lp-plan-btn-primary:hover { opacity: .9; transform: translateY(-1px); }
.lp-plan-btn-ghost { border: 1.5px solid rgba(255,255,255,.15); color: #f1f5f9; }
.lp-plan-btn-ghost:hover { border-color: rgba(99,102,241,.5); background: rgba(99,102,241,.08); }
.lp-faq-wrap { max-width: 680px; }
.lp-faq { display: flex; flex-direction: column; }
.lp-faq-item { padding: 20px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
.lp-faq-q { font-weight: 700; color: #f1f5f9; margin-bottom: 8px; }
.lp-faq-a { color: #94a3b8; font-size: .9rem; line-height: 1.6; }
.lp-cta-banner { padding: 80px 24px; text-align: center; position: relative; overflow: hidden; border-top: 1px solid rgba(99,102,241,.15); }
.lp-cta-glow { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 600px; height: 400px; background: radial-gradient(ellipse, rgba(99,102,241,.15) 0%, transparent 70%); pointer-events: none; }
.lp-cta-banner h2 { font-size: 2rem; font-weight: 900; margin-bottom: 12px; position: relative; }
.lp-cta-banner p { color: #94a3b8; margin-bottom: 28px; position: relative; }
.lp-footer { padding: 28px 24px; border-top: 1px solid rgba(255,255,255,.06); background: rgba(255,255,255,.01); }
.lp-footer-inner { max-width: 1100px; margin: 0 auto; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.lp-footer-logo { display: flex; align-items: center; gap: 6px; font-weight: 800; font-size: .92rem; color: #94a3b8; }
.lp-footer-links { display: flex; gap: 20px; flex: 1; }
.lp-footer-links a { color: #64748b; text-decoration: none; font-size: .82rem; transition: color .2s; }
.lp-footer-links a:hover { color: #94a3b8; }
.lp-footer-copy { color: #475569; font-size: .75rem; }
@media (max-width: 768px) {
  .lp-nav-links { display: none; }
  .lp-hero { padding: 80px 20px 40px; }
  .lp-mockup-body { height: 200px; }
  .lp-stat { padding: 10px 20px; }
  .lp-stat-div { display: none; }
  .lp-pricing { grid-template-columns: 1fr; }
}
