/* ═══════════════════════════════════════════════════════════
   APEX ELITE — Premium Trading Design System
   ═══════════════════════════════════════════════════════════ */
:root {
  --bg: #050505;
  --bg2: #0c0c0c;
  --bg3: #111111;
  --panel: rgba(18, 18, 18, 0.92);
  --panel2: rgba(24, 24, 24, 0.95);
  --glass: rgba(255, 255, 255, 0.03);
  --line: rgba(255, 255, 255, 0.06);
  --line2: rgba(255, 255, 255, 0.1);
  --ink: #f0f0f0;
  --ink2: #c8c8c8;
  --mute: #6b6b6b;
  --brand: #26a69a;
  --brand2: #1e8a80;
  --brand-glow: rgba(38, 166, 154, 0.35);
  --brand-dim: #1e8a80;
  --buy: #26a69a;
  --buy-glow: rgba(38, 166, 154, 0.25);
  --sell: #f87171;
  --sell-glow: rgba(248, 113, 113, 0.25);
  --ok: #34d399;
  --bad: #f87171;
  --warn: #fbbf24;
  --nav-h: 52px;
  --account-h: 40px;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
  --shadow-glow: 0 0 40px var(--brand-glow);
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg: #f8fafc;
  --bg2: #f1f5f9;
  --bg3: #e2e8f0;
  --panel: rgba(255, 255, 255, 0.95);
  --panel2: #fff;
  --glass: rgba(0, 0, 0, 0.02);
  --line: rgba(0, 0, 0, 0.08);
  --line2: rgba(0, 0, 0, 0.12);
  --ink: #0f172a;
  --ink2: #334155;
  --mute: #64748b;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
html, body { height: 100%; font-family: var(--font); background: var(--bg); color: var(--ink); }
<body { background: var(--bg); }
a { color: var(--brand); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--brand2); }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font-family: inherit; font-size: inherit; }
.hidden { display: none !important; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 9px 18px; border-radius: var(--radius); font-weight: 600; font-size: 13px;
  transition: all var(--transition); white-space: nowrap; position: relative; overflow: hidden;
}
.btn::after {
  content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(255,255,255,0.12), transparent);
  opacity: 0; transition: opacity var(--transition);
}
.btn:hover::after { opacity: 1; }
.btn-brand {
  background: linear-gradient(135deg, var(--brand), var(--brand-dim));
  color: #000; font-weight: 700; box-shadow: 0 4px 20px var(--brand-glow);
}
.btn-brand:hover { transform: translateY(-1px); box-shadow: 0 8px 28px var(--brand-glow); }
.btn-ghost { background: var(--glass); border: 1px solid var(--line); color: var(--ink2); backdrop-filter: blur(8px); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); background: rgba(45,212,191,0.06); }
.btn-buy { background: linear-gradient(135deg, var(--buy), var(--brand-dim)); color: #000; font-weight: 700; box-shadow: 0 4px 16px var(--buy-glow); }
.btn-sell { background: linear-gradient(135deg, var(--sell), #dc2626); color: #fff; font-weight: 700; box-shadow: 0 4px 16px var(--sell-glow); }
.btn-sm { padding: 5px 12px; font-size: 11px; border-radius: 8px; }
.btn-lg { padding: 14px 28px; font-size: 15px; font-weight: 700; border-radius: 12px; }
.btn-icon { width: 36px; height: 36px; padding: 0; border-radius: 10px; }

/* ── Forms ── */
.field {
  background: var(--panel2); border: 1px solid var(--line); color: var(--ink);
  border-radius: var(--radius); padding: 10px 14px; width: 100%; outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.field:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-glow); }
.label { font-size: 10px; color: var(--mute); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 6px; display: block; font-weight: 600; }

/* ── Tables ── */
.table { width: 100%; border-collapse: collapse; font-size: 12px; }
.table th { text-align: left; padding: 10px 12px; color: var(--mute); font-weight: 600; font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; border-bottom: 1px solid var(--line); background: var(--glass); position: sticky; top: 0; z-index: 1; }
.table td { padding: 10px 12px; border-bottom: 1px solid var(--line); font-family: var(--mono); font-size: 11px; }
.table tr { transition: background var(--transition); }
.table tr:hover td { background: rgba(45, 212, 191, 0.04); }
.pos { color: var(--ok); }
.neg { color: var(--bad); }

/* ── Toast ── */
.toast-wrap { position: fixed; top: 20px; right: 20px; z-index: 99999; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast {
  background: var(--panel2); border: 1px solid var(--line2); border-radius: 12px;
  padding: 14px 18px; font-size: 13px; box-shadow: var(--shadow); pointer-events: auto;
  animation: toastIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); max-width: 360px; backdrop-filter: blur(20px);
}
.toast.ok { border-left: 3px solid var(--ok); }
.toast.err { border-left: 3px solid var(--bad); }
@keyframes toastIn { from { transform: translateX(120%) scale(0.9); opacity: 0; } to { transform: translateX(0) scale(1); opacity: 1; } }

/* ── Loader ── */
.apex-loader { position: fixed; inset: 0; background: var(--bg); z-index: 99998; display: grid; place-items: center; transition: opacity 0.4s; }
.apex-loader.done { opacity: 0; pointer-events: none; }
.apex-spinner { width: 40px; height: 40px; border: 2px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Status dot ── */
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 8px var(--ok); animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

/* ── Toggle ── */
.toggle { width: 40px; height: 22px; background: var(--line2); border-radius: 11px; position: relative; cursor: pointer; transition: background var(--transition); flex-shrink: 0; }
.toggle.on { background: var(--brand); box-shadow: 0 0 12px var(--brand-glow); }
.toggle::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; background: #fff; border-radius: 50%; transition: left var(--transition); box-shadow: 0 2px 4px rgba(0,0,0,0.3); }
.toggle.on::after { left: 21px; }

/* ── Dropdown ── */
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; top: calc(100% + 6px); right: 0;
  background: var(--panel2); border: 1px solid var(--line2); border-radius: 12px;
  min-width: 220px; z-index: 1000; box-shadow: var(--shadow); display: none;
  backdrop-filter: blur(24px); overflow: hidden; animation: dropIn 0.2s ease;
}
.dropdown.open .dropdown-menu { display: block; }
@keyframes dropIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
.dropdown-menu a, .dropdown-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 11px 16px; font-size: 13px; color: var(--ink2); border-bottom: 1px solid var(--line); transition: all var(--transition);
}
.dropdown-menu a:hover, .dropdown-menu button:hover { background: rgba(45,212,191,0.08); color: var(--brand); padding-left: 20px; }
.dropdown-menu a:last-child, .dropdown-menu button:last-child { border-bottom: none; color: var(--bad); }

/* ═══ LANDING ═══ */
.landing-nav {
  position: sticky; top: 0; z-index: 200;
  background: rgba(5, 5, 5, 0.8); backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--line);
}
.nav-inner { max-width: 1280px; margin: 0 auto; padding: 14px 28px; display: flex; align-items: center; gap: 32px; }
.nav-links { display: flex; gap: 28px; font-size: 14px; font-weight: 500; }
.nav-links a { color: var(--mute); text-decoration: none; transition: color var(--transition); }
.nav-links a:hover { color: var(--ink); }

.ticker-strip { overflow: hidden; border-block: 1px solid var(--line); background: var(--bg2); padding: 12px 0; }
.ticker-track { display: flex; gap: 40px; animation: marquee 50s linear infinite; white-space: nowrap; }
.ticker-item { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-family: var(--mono); }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.landing-hero {
  min-height: 92vh; display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 80px 28px; position: relative; overflow: hidden;
}
.landing-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle 600px at 50% 40%, rgba(45,212,191,0.08), transparent 70%);
  pointer-events: none;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px;
  background: rgba(45,212,191,0.1); border: 1px solid rgba(45,212,191,0.25);
  border-radius: 99px; font-size: 12px; font-weight: 600; color: var(--brand);
  letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 28px;
}
.hero-title { font-size: clamp(40px, 7vw, 72px); font-weight: 800; line-height: 1.05; margin-bottom: 24px; max-width: 900px; letter-spacing: -0.02em; }
.hero-title .gradient { background: linear-gradient(135deg, var(--brand), #6ee7b7, var(--brand)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-sub { font-size: 19px; color: var(--mute); max-width: 580px; margin-bottom: 40px; line-height: 1.7; }
.hero-stats { display: flex; gap: 48px; flex-wrap: wrap; justify-content: center; margin-top: 56px; }
.hero-stat .num { font-size: 32px; font-weight: 800; font-family: var(--mono); color: var(--brand); }
.hero-stat .lbl { font-size: 13px; color: var(--mute); margin-top: 4px; }

.section { padding: 100px 28px; max-width: 1280px; margin: 0 auto; }
.section-head { text-align: center; margin-bottom: 56px; }
.section-head h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 800; letter-spacing: -0.02em; margin-bottom: 16px; }
.section-head p { color: var(--mute); max-width: 520px; margin: 0 auto; font-size: 16px; line-height: 1.6; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.feature-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 28px; transition: all var(--transition); position: relative; overflow: hidden;
}
.feature-card::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(45,212,191,0.05), transparent); opacity: 0; transition: opacity var(--transition); }
.feature-card:hover { border-color: rgba(45,212,191,0.3); transform: translateY(-4px); box-shadow: var(--shadow-glow); }
.feature-card:hover::before { opacity: 1; }
.feature-icon { width: 48px; height: 48px; border-radius: 12px; background: rgba(45,212,191,0.12); display: grid; place-items: center; font-size: 22px; margin-bottom: 16px; }
.feature-card h3 { font-weight: 700; font-size: 17px; margin-bottom: 10px; }
.feature-card p { color: var(--mute); font-size: 14px; line-height: 1.65; }

.terminal-preview {
  background: var(--panel); border: 1px solid var(--line2); border-radius: 20px;
  overflow: hidden; box-shadow: 0 40px 100px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.04);
}
.preview-bar { background: var(--bg3); padding: 10px 16px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--line); font-size: 12px; }
.preview-dots { display: flex; gap: 6px; }
.preview-dots span { width: 10px; height: 10px; border-radius: 50%; }
.preview-dots span:nth-child(1) { background: #f87171; }
.preview-dots span:nth-child(2) { background: #fbbf24; }
.preview-dots span:nth-child(3) { background: #34d399; }

/* ═══ TERMINAL ═══ */
.terminal {
  display: grid; grid-template-rows: var(--nav-h) var(--account-h) 1fr auto auto;
  height: 100vh; overflow: hidden; background: var(--bg);
}

.term-nav {
  display: flex; align-items: center; gap: 6px; padding: 0 16px;
  background: var(--panel); border-bottom: 1px solid var(--line);
  height: var(--nav-h); backdrop-filter: blur(20px);
}
.term-nav .logo {
  display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 16px;
  margin-right: 20px; letter-spacing: -0.02em;
}
.term-nav .logo svg { width: 26px; height: 26px; filter: drop-shadow(0 0 8px var(--brand-glow)); }
.term-tabs { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.term-tabs::-webkit-scrollbar { display: none; }
.term-tab {
  padding: 7px 14px; font-size: 12px; font-weight: 500; color: var(--mute);
  border-radius: 8px; white-space: nowrap; transition: all var(--transition);
}
.term-tab.active { color: var(--brand); background: rgba(45,212,191,0.1); }
.term-tab:hover:not(.active) { color: var(--ink2); background: var(--glass); }
.term-nav-right { margin-left: auto; display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

.term-account-bar {
  display: flex; align-items: center; gap: 20px; padding: 0 16px;
  background: linear-gradient(180deg, var(--bg2), var(--bg));
  border-bottom: 1px solid var(--line); height: var(--account-h);
  font-size: 11px; overflow-x: auto; scrollbar-width: none;
}
.term-metric { display: flex; flex-direction: column; min-width: 72px; gap: 2px; }
.term-metric .val { font-weight: 700; font-size: 12px; font-family: var(--mono); transition: color 0.3s; }
.term-metric .lbl { color: var(--mute); font-size: 9px; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; }
.term-metric .val.flash-up { animation: flashUp 0.5s; }
.term-metric .val.flash-down { animation: flashDown 0.5s; }
@keyframes flashUp { 0%,100% { color: var(--ink); } 50% { color: var(--ok); } }
@keyframes flashDown { 0%,100% { color: var(--ink); } 50% { color: var(--bad); } }

.term-main { display: grid; grid-template-columns: 240px 1fr 280px; overflow: hidden; min-height: 0; }

.term-watchlist { background: var(--panel); border-right: 1px solid var(--line); display: flex; flex-direction: column; overflow: hidden; }
.term-watchlist-search { padding: 10px; border-bottom: 1px solid var(--line); }
.term-watchlist-list { flex: 1; overflow-y: auto; }
.wl-header { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; padding: 8px 12px; font-size: 9px; color: var(--mute); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; border-bottom: 1px solid var(--line); }
.wl-row {
  display: grid; grid-template-columns: auto 1fr auto auto; gap: 8px; padding: 9px 12px;
  font-size: 11px; cursor: pointer; border-bottom: 1px solid var(--line); align-items: center;
  transition: background var(--transition);
}
.wl-row:hover { background: rgba(45,212,191,0.04); }
.wl-row.active { background: rgba(45,212,191,0.08); border-left: 2px solid var(--brand); }
.wl-row .sym { font-weight: 600; font-size: 12px; }
.wl-row .price { text-align: right; font-family: var(--mono); }
.wl-row .chg { text-align: right; font-size: 10px; font-family: var(--mono); padding: 2px 6px; border-radius: 4px; }
.wl-row .chg.pos { background: rgba(52,211,153,0.12); }
.wl-row .chg.neg { background: rgba(248,113,113,0.12); }
.wl-star { opacity: 0.3; font-size: 14px; transition: opacity var(--transition); }
.wl-star.on { opacity: 1; color: var(--warn); }

.term-center { display: flex; flex-direction: column; overflow: hidden; min-height: 0; }
.term-chart-header {
  display: flex; align-items: center; gap: 8px; padding: 8px 14px;
  background: var(--panel); border-bottom: 1px solid var(--line); font-size: 11px; flex-wrap: wrap;
}
.chart-tab { padding: 5px 12px; border-radius: 6px; font-weight: 600; font-size: 11px; color: var(--mute); cursor: pointer; transition: all var(--transition); }
.chart-tab.active { color: var(--brand); background: rgba(45,212,191,0.1); }
.bid-ask-bar { display: flex; gap: 16px; margin-left: auto; font-family: var(--mono); font-size: 12px; }
.bid-ask-bar .bid { color: var(--sell); }
.bid-ask-bar .ask { color: var(--buy); }
.bid-ask-bar .spread { color: var(--mute); font-size: 10px; }
.tf-btn.active { background: rgba(45,212,191,0.15) !important; color: var(--brand) !important; border-color: rgba(45,212,191,0.3) !important; }

.term-chart-area { flex: 1; position: relative; min-height: 200px; background: var(--bg); }
.term-chart-area #chartContainer { width: 100% !important; height: 100% !important; }
.chart-info-panel { padding: 20px; display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 16px; height: 100%; overflow-y: auto; }
.info-cell { background: var(--panel2); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.info-cell .lbl { font-size: 10px; color: var(--mute); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 6px; }
.info-cell .val { font-family: var(--mono); font-weight: 600; font-size: 14px; }

.term-order-panel {
  background: var(--panel); border-top: 1px solid var(--line); padding: 14px 18px;
  display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center;
  backdrop-filter: blur(12px);
}
.order-side-btns { display: flex; gap: 4px; background: var(--bg3); padding: 4px; border-radius: 10px; }
.order-side-btns button { padding: 11px 28px; font-weight: 700; border-radius: 8px; opacity: 0.45; font-size: 13px; transition: all var(--transition); }
.order-side-btns button.active-buy { background: var(--buy); color: #000; opacity: 1; box-shadow: 0 4px 16px var(--buy-glow); }
.order-side-btns button.active-sell { background: var(--sell); color: #fff; opacity: 1; box-shadow: 0 4px 16px var(--sell-glow); }
.order-fields { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.order-field { display: flex; flex-direction: column; gap: 4px; }
.qty-stepper { display: flex; align-items: center; gap: 4px; background: var(--bg3); border-radius: 8px; padding: 2px; }
.qty-stepper button { width: 32px; height: 32px; background: var(--panel2); border: 1px solid var(--line); border-radius: 6px; font-size: 16px; transition: all var(--transition); }
.qty-stepper button:hover { border-color: var(--brand); color: var(--brand); }
.toggle-row { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 600; color: var(--mute); }

.term-sidebar { background: var(--panel); border-left: 1px solid var(--line); overflow-y: auto; display: flex; flex-direction: column; }
.sidebar-section { padding: 14px; border-bottom: 1px solid var(--line); }
.sidebar-section h4 { font-size: 10px; color: var(--mute); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 12px; font-weight: 700; }
.mover-card { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: 11px; border-bottom: 1px solid var(--line); }
.mover-card:last-child { border-bottom: none; }
.mover-card .spark { width: 56px; height: 28px; }
.news-item { padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 12px; line-height: 1.5; }
.news-item a { color: var(--ink2); display: block; }
.news-item a:hover { color: var(--brand); text-decoration: none; }
.social-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; font-size: 11px; border-bottom: 1px solid var(--line); }
.social-row .avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--brand-dim), var(--brand)); display: grid; place-items: center; font-weight: 800; color: #000; font-size: 13px; }
.social-row .roi-bar { height: 4px; border-radius: 2px; background: var(--line); margin-top: 4px; overflow: hidden; }
.social-row .roi-bar fill { height: 100%; background: var(--brand); border-radius: 2px; }

.term-positions { background: var(--panel); border-top: 1px solid var(--line); max-height: 200px; overflow: hidden; display: flex; flex-direction: column; }
.pos-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--line); background: var(--bg2); }
.pos-tab { padding: 10px 20px; font-size: 12px; font-weight: 600; color: var(--mute); border-bottom: 2px solid transparent; transition: all var(--transition); }
.pos-tab.active { color: var(--brand); border-bottom-color: var(--brand); background: rgba(45,212,191,0.05); }
.pos-content { flex: 1; overflow: auto; }

/* ── Auth ── */
.auth-wrap {
  min-height: 100vh; display: grid; place-items: center; padding: 28px;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(45,212,191,0.1), transparent 60%);
}
.auth-card {
  background: var(--panel); border: 1px solid var(--line2); border-radius: 20px;
  padding: 40px; width: 100%; max-width: 440px; box-shadow: var(--shadow);
  backdrop-filter: blur(24px);
}
.auth-card h1 { font-size: 26px; font-weight: 800; margin-bottom: 8px; letter-spacing: -0.02em; }
.auth-card p { color: var(--mute); font-size: 14px; margin-bottom: 28px; }
.form-group { margin-bottom: 18px; }

/* ── Portal ── */
.portal-wrap { max-width: 960px; margin: 0 auto; padding: 32px 24px; }
.portal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; flex-wrap: wrap; gap: 16px; }
.portal-header h1 { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.portal-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; margin-bottom: 20px; }
.portal-nav {
  display: flex; align-items: center; gap: 12px; padding: 14px 24px;
  background: rgba(5,5,5,0.9); backdrop-filter: blur(20px); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 100; flex-wrap: wrap;
}

/* ── Admin ── */
.admin-wrap { max-width: 1280px; margin: 0 auto; padding: 28px 24px; }
.admin-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 28px; }
.stat-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 22px; transition: all var(--transition); position: relative; overflow: hidden;
}
.stat-card::after { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, var(--brand), transparent); }
.stat-card:hover { border-color: rgba(45,212,191,0.25); transform: translateY(-2px); }
.stat-card .num { font-size: 32px; font-weight: 800; font-family: var(--mono); color: var(--brand); }
.stat-card .lbl { font-size: 12px; color: var(--mute); margin-top: 4px; font-weight: 500; }

/* ── Keyboard hint ── */
.kbd-hint { position: fixed; bottom: 16px; left: 16px; font-size: 10px; color: var(--mute); background: var(--panel); border: 1px solid var(--line); padding: 8px 12px; border-radius: 8px; z-index: 50; opacity: 0.7; }
.kbd-hint kbd { background: var(--bg3); padding: 2px 6px; border-radius: 4px; font-family: var(--mono); border: 1px solid var(--line); }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .term-main { grid-template-columns: 220px 1fr; }
  .term-sidebar { display: none; }
}
@media (max-width: 768px) {
  .term-main { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .term-watchlist { max-height: 180px; border-right: none; border-bottom: 1px solid var(--line); }
  .term-order-panel { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .term-tabs { display: none; }
  .kbd-hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
