/* Phantrium Markets — mobile-first redesign (Bloomberg-meets-Linear, scherp + leesbaar) */

:root {
  --bg-0: #07090f;
  --bg-1: #0c1018;
  --bg-2: #131826;
  --bg-3: #1a2030;
  --bg-4: #232a3d;
  --line: #232a3d;
  --line-soft: #1a2030;
  --text-0: #e9edf6;
  --text-1: #aab2c5;
  --text-2: #6b7591;
  --accent: #4f8cff;
  --accent-2: #6dd3ff;
  --up: #14d39a;
  --up-bg: rgba(20, 211, 154, 0.12);
  --down: #ff4d6d;
  --down-bg: rgba(255, 77, 109, 0.12);
  --warn: #ffb44a;
  --warn-bg: rgba(255, 180, 74, 0.12);
  --neutral: #8c95ad;
  --shadow-lg: 0 24px 48px -16px rgba(0, 0, 0, 0.5);
  --topbar-h: 56px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--topbar-h) + 12px);
}

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(79, 140, 255, 0.08), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(20, 211, 154, 0.05), transparent 60%),
    var(--bg-0);
  color: var(--text-0);
  font-family: 'Inter', -apple-system, system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 16px; }

/* ===== TOPBAR (mobile-first) ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(7, 9, 15, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 16px;
  max-width: 1280px;
  margin: 0 auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 15px;
}
.logo-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 12px rgba(79, 140, 255, 0.7);
  flex-shrink: 0;
}
.logo-text { letter-spacing: -0.01em; white-space: nowrap; }
.logo-text em { color: var(--accent-2); font-style: normal; font-weight: 800; }

.topmeta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--text-1);
  font-family: 'JetBrains Mono', monospace;
  margin-left: auto;
  margin-right: 8px;
  white-space: nowrap;
}
.live-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--up); box-shadow: 0 0 10px rgba(20, 211, 154, 0.8);
  animation: pulse 2s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* Hamburger */
.hamburger {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  width: 38px; height: 38px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  padding: 0;
  transition: border-color 0.15s;
}
.hamburger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text-0);
  border-radius: 1px;
  transition: transform 0.25s, opacity 0.2s;
}
.hamburger[aria-expanded="true"] { border-color: var(--accent); }
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile nav drawer */
.mobilenav {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  background: rgba(7, 9, 15, 0.98);
  border-bottom: 1px solid var(--line);
}
.mobilenav.open { max-height: 600px; }
.mobilenav a {
  display: block;
  padding: 13px 20px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--text-0);
  font-size: 15px;
  font-weight: 500;
  transition: background 0.15s, color 0.15s;
}
.mobilenav a:hover,
.mobilenav a:active { background: var(--bg-2); color: var(--accent-2); }
.mobilenav a:last-child { border-bottom: 0; }

/* Desktop: horizontal nav inside topbar */
@media (min-width: 900px) {
  .topbar-inner { padding: 0 24px; }
  .brand { font-size: 16px; }
  .hamburger { display: none; }
  .mobilenav {
    max-height: none;
    overflow: visible;
    background: transparent;
    border-bottom: 0;
    display: flex;
    gap: 20px;
    padding: 0;
    margin-left: 24px;
    margin-right: auto;
  }
  .mobilenav a {
    padding: 0;
    border: 0;
    color: var(--text-1);
    font-size: 14px;
    font-weight: 500;
  }
  .mobilenav a:hover { background: transparent; color: var(--text-0); }
  .topmeta { font-size: 12px; margin-right: 0; }
}

/* ===== HERO ===== */
.hero {
  padding: 24px 16px 8px;
  max-width: 1280px;
  margin: 0 auto;
}
.kicker {
  font-family: 'JetBrains Mono', monospace;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 11px;
  color: var(--accent-2);
  margin-bottom: 12px;
}
.hero h1 {
  font-size: clamp(28px, 7vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0 0 14px;
  font-weight: 800;
  background: linear-gradient(135deg, #fff 0%, #aab2c5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.lede { color: var(--text-1); font-size: 15px; margin: 0 0 20px; max-width: 56ch; }
.hero-cta { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 10px; font-weight: 600;
  font-size: 15px; transition: transform 0.15s, background 0.15s;
  cursor: pointer; border: 0;
}
.btn.primary { background: var(--accent); color: #06090f; }
.btn.primary:hover, .btn.primary:active { background: #6ba0ff; }
.btn.ghost { background: transparent; color: var(--text-0); border: 1px solid var(--line); }
.btn.ghost:hover { border-color: var(--accent); color: var(--accent-2); }

.big-tiles {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.tile {
  background: linear-gradient(180deg, var(--bg-2) 0%, var(--bg-1) 100%);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  position: relative;
  overflow: hidden;
  min-height: 88px;
}
.tile::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(79, 140, 255, 0.05) 0%, transparent 50%);
  pointer-events: none;
}
.tile-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
}
.tile-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 19px;
  font-weight: 700;
  margin-top: 6px;
  letter-spacing: -0.01em;
}
.tile-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-1);
  margin-top: 3px;
  line-height: 1.3;
}
[data-loading] { color: var(--text-2); }

@media (min-width: 600px) {
  .big-tiles { grid-template-columns: repeat(3, 1fr); }
  .tile { padding: 16px; min-height: 96px; }
  .tile-value { font-size: 20px; }
}
@media (min-width: 900px) {
  .container { padding: 0 24px; }
  .hero {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 48px;
    align-items: center;
    padding: 48px 24px 32px;
  }
  .hero-cta { margin-bottom: 0; }
  .lede { font-size: 17px; }
  .tile { padding: 18px; min-height: 100px; }
  .tile-value { font-size: 22px; }
  .tile-label { font-size: 11px; }
  .tile-sub { font-size: 12px; }
}

/* ===== SECTIONS ===== */
section.container { margin: 36px auto; scroll-margin-top: calc(var(--topbar-h) + 16px); }
.section-head { margin-bottom: 18px; }
.section-head h2 {
  font-size: clamp(20px, 4vw, 26px);
  letter-spacing: -0.02em;
  margin: 0 0 6px;
  font-weight: 700;
  line-height: 1.25;
}
.section-head p { color: var(--text-1); margin: 0; font-size: 14px; }
@media (min-width: 900px) {
  section.container { margin: 56px auto; }
  .section-head p { font-size: 15px; }
}

/* ===== OPPORTUNITIES ===== */
.opp-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 600px) {
  .opp-grid { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
}
.opp-card {
  background: linear-gradient(180deg, var(--bg-2) 0%, var(--bg-1) 100%);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  position: relative;
  overflow: hidden;
  transition: transform 0.15s, border-color 0.15s;
}
.opp-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.opp-tag {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 4px 8px;
  border-radius: 6px;
  margin-bottom: 10px;
  text-transform: uppercase;
}
.opp-tag.up { background: var(--up-bg); color: var(--up); }
.opp-tag.down { background: var(--down-bg); color: var(--down); }
.opp-tag.warn { background: var(--warn-bg); color: var(--warn); }
.opp-tag.info { background: rgba(79, 140, 255, 0.14); color: var(--accent-2); }
.opp-symbol {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-bottom: 2px;
  font-family: 'JetBrains Mono', monospace;
  word-break: break-all;
}
.opp-name { color: var(--text-1); font-size: 13px; margin-bottom: 12px; }
.opp-reason { color: var(--text-0); font-size: 14px; line-height: 1.5; }
.opp-meta {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-1);
  flex-wrap: wrap;
}
.opp-meta span strong { color: var(--text-0); }

.skeleton-card {
  height: 160px;
  background: linear-gradient(90deg, var(--bg-1) 0%, var(--bg-2) 50%, var(--bg-1) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.8s ease-in-out infinite;
  border-radius: 14px;
  border: 1px solid var(--line);
}
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ===== INLEG-ANALYSE ===== */
.inleg-controls {
  background: linear-gradient(180deg, var(--bg-2) 0%, var(--bg-1) 100%);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 16px;
}
.inleg-toggle {
  display: flex;
  background: var(--bg-3);
  border-radius: 10px;
  padding: 4px;
  margin-bottom: 14px;
  gap: 0;
}
.toggle-btn {
  flex: 1;
  background: transparent;
  border: 0;
  color: var(--text-1);
  font-size: 14px;
  font-weight: 600;
  padding: 10px 14px;
  border-radius: 7px;
  cursor: pointer;
  transition: background 0.18s, color 0.15s;
}
.toggle-btn.active { background: var(--accent); color: #06090f; }

.inleg-amount label {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
  margin-bottom: 8px;
}
.amount-row {
  display: flex;
  align-items: center;
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 4px 10px;
  margin-bottom: 12px;
}
.amount-prefix {
  font-family: 'JetBrains Mono', monospace;
  font-size: 22px;
  font-weight: 700;
  color: var(--text-1);
  margin-right: 6px;
}
#inleg-input {
  flex: 1;
  background: transparent;
  border: 0;
  color: var(--text-0);
  font-family: 'JetBrains Mono', monospace;
  font-size: 22px;
  font-weight: 700;
  padding: 8px 0;
  width: 100%;
  outline: none;
  min-width: 0;
}
#inleg-input::-webkit-outer-spin-button,
#inleg-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
#inleg-input[type=number] { -moz-appearance: textfield; }

.amount-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--bg-3);
  border-radius: 2px;
  outline: none;
  margin: 6px 0 12px;
}
.amount-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--bg-0);
  box-shadow: 0 0 12px rgba(79, 140, 255, 0.5);
  cursor: pointer;
}
.amount-slider::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--bg-0);
  cursor: pointer;
}

.amount-hints {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.hint-pill {
  background: var(--bg-3);
  border: 1px solid var(--line);
  color: var(--text-1);
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.hint-pill:hover, .hint-pill.active { background: var(--accent); color: #06090f; border-color: var(--accent); }

/* Allocation grid */
.alloc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}
@media (min-width: 600px) {
  .alloc-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
}
.alloc-card {
  background: var(--bg-1);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  position: relative;
}
.alloc-card .alloc-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
}
.alloc-card .alloc-pct {
  font-family: 'JetBrains Mono', monospace;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 4px 0 2px;
}
.alloc-card .alloc-eur {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--accent-2);
}
.alloc-card .alloc-eur-year {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-2);
  margin-top: 2px;
}
.alloc-card .alloc-desc {
  font-size: 12px;
  color: var(--text-1);
  margin-top: 8px;
  line-height: 1.45;
}
.alloc-card .alloc-bar {
  height: 4px;
  background: var(--bg-3);
  border-radius: 2px;
  margin-top: 10px;
  overflow: hidden;
}
.alloc-card .alloc-bar > div {
  height: 100%;
  border-radius: 2px;
  transition: width 0.5s;
}
.alloc-notes-card {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, rgba(79,140,255,0.08), var(--bg-1));
}
@media (min-width: 600px) {
  .alloc-card { padding: 18px; }
  .alloc-card .alloc-pct { font-size: 30px; }
  .alloc-card .alloc-desc { font-size: 13px; }
}

/* Projections */
.projections {
  background: var(--bg-1);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
}
.proj-head h3 { margin: 0 0 6px; font-size: 18px; font-weight: 700; }
.proj-head p { margin: 0 0 16px; color: var(--text-1); font-size: 13px; }
.proj-scenarios {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 16px;
}
@media (min-width: 600px) {
  .proj-scenarios { grid-template-columns: repeat(3, 1fr); }
}
.scen-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px;
  position: relative;
  overflow: hidden;
}
.scen-card.realistisch { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.scen-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 6px;
}
.scen-label .scen-dot {
  width: 8px; height: 8px; border-radius: 50%;
}
.scen-card.conservatief .scen-dot { background: var(--warn); }
.scen-card.realistisch .scen-dot { background: var(--accent); }
.scen-card.optimistisch .scen-dot { background: var(--up); }
.scen-roi {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--text-1);
  margin-top: 4px;
}

.proj-table-wrap {
  margin: 0 -16px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.proj-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 480px;
}
.proj-table thead th {
  background: var(--bg-2);
  padding: 10px 12px;
  text-align: right;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-2);
  font-weight: 600;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.proj-table thead th:first-child { text-align: left; padding-left: 16px; }
.proj-table thead th:last-child { padding-right: 16px; }
.proj-table tbody td {
  padding: 11px 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  text-align: right;
  border-bottom: 1px solid var(--line-soft);
  white-space: nowrap;
}
.proj-table tbody td:first-child {
  text-align: left;
  color: var(--text-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding-left: 16px;
}
.proj-table tbody td:last-child { padding-right: 16px; }
.proj-table tbody tr.scen-conservatief td:not(:first-child) { color: var(--warn); }
.proj-table tbody tr.scen-realistisch td { background: rgba(79, 140, 255, 0.04); }
.proj-table tbody tr.scen-realistisch td:not(:first-child) { color: var(--text-0); font-weight: 700; }
.proj-table tbody tr.scen-optimistisch td:not(:first-child) { color: var(--up); }
.proj-table tbody tr.scen-inleg td:not(:first-child) { color: var(--text-2); font-style: italic; }
.proj-table tbody tr:last-child td { border-bottom: 0; }

.proj-disclaimer {
  margin-top: 16px;
  font-size: 12px;
  color: var(--text-2);
  background: var(--bg-2);
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line-soft);
  line-height: 1.5;
}
@media (min-width: 600px) {
  .projections { padding: 22px; }
  .proj-head h3 { font-size: 20px; }
  .proj-table-wrap { margin: 0; }
}

/* ===== SIGNAL CARDS ===== */
.signal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
@media (min-width: 600px) {
  .signal-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
}
.signal-card {
  background: var(--bg-1);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.signal-card .label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
}
.signal-card .value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.signal-card .delta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-1);
  line-height: 1.3;
}
.signal-card .delta.up { color: var(--up); }
.signal-card .delta.down { color: var(--down); }
.signal-card .delta.warn { color: var(--warn); }
.signal-card.flag-fear { background: linear-gradient(135deg, rgba(255,77,109,0.06), var(--bg-1)); }
.signal-card.flag-greed { background: linear-gradient(135deg, rgba(20,211,154,0.06), var(--bg-1)); }
@media (min-width: 600px) {
  .signal-card { padding: 14px 16px; }
  .signal-card .value { font-size: 18px; }
  .signal-card .delta { font-size: 12px; }
}

/* ===== CARD / CRYPTO ===== */
.card {
  background: linear-gradient(180deg, var(--bg-2) 0%, var(--bg-1) 100%);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
}
.crypto-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (min-width: 600px) {
  .crypto-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
  .card { padding: 22px; }
}
.crypto-cell { display: flex; flex-direction: column; gap: 4px; }
.crypto-cell .label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
}
.crypto-cell .value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
}
.crypto-cell .delta { font-family: 'JetBrains Mono', monospace; font-size: 11px; }
.crypto-card-foot {
  margin-top: 14px;
  color: var(--text-1);
  font-size: 13px;
  line-height: 1.5;
}
@media (min-width: 600px) {
  .crypto-cell .value { font-size: 18px; }
  .crypto-cell .delta { font-size: 12px; }
  .crypto-card-foot { font-size: 14px; }
}

/* ===== TABS ===== */
.tab-row {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
  padding-bottom: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.tab {
  background: transparent;
  border: 0;
  color: var(--text-1);
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  cursor: pointer;
  border-radius: 8px 8px 0 0;
  position: relative;
  white-space: nowrap;
  flex-shrink: 0;
}
.tab:hover { color: var(--text-0); }
.tab.active {
  color: var(--text-0);
  background: var(--bg-2);
}
.tab.active::after {
  content: '';
  position: absolute;
  left: 12px; right: 12px; bottom: -5px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ===== DATA CARDS (mobile-first) ===== */
.data-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media (min-width: 600px) {
  .data-cards { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}
@media (min-width: 900px) {
  .data-cards { grid-template-columns: repeat(3, 1fr); }
}
.asset-card {
  background: var(--bg-1);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: border-color 0.15s, transform 0.15s;
}
.asset-card:hover { border-color: var(--accent); transform: translateY(-1px); }
.asset-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}
.asset-symbol {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-0);
  letter-spacing: -0.01em;
  word-break: break-word;
}
.asset-name {
  font-size: 12px;
  color: var(--text-2);
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.asset-price {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-0);
  text-align: right;
  white-space: nowrap;
}
.asset-deltas {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.delta-cell {
  background: var(--bg-2);
  border-radius: 6px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.delta-cell .dc-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.delta-cell .dc-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
}
.asset-bot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
  flex-wrap: wrap;
}
.asset-rsi-bar {
  flex: 1;
  min-width: 80px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.asset-rsi-bar .rsi-track {
  flex: 1;
  height: 5px;
  background: var(--bg-3);
  border-radius: 3px;
  position: relative;
  overflow: hidden;
}
.asset-rsi-bar .rsi-fill {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--up) 0%, var(--warn) 50%, var(--down) 100%);
  opacity: 0.3;
}
.asset-rsi-bar .rsi-marker {
  position: absolute;
  top: -2px;
  width: 2px;
  height: 9px;
  background: #fff;
  border-radius: 1px;
  transform: translateX(-1px);
}
.asset-rsi-bar .rsi-val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-1);
  font-weight: 700;
  min-width: 22px;
  text-align: right;
}
.asset-pills {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.pill {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.pill-strong { background: var(--up-bg); color: var(--up); }
.pill-overbought { background: var(--warn-bg); color: var(--warn); }
.pill-weak { background: var(--down-bg); color: var(--down); }
.pill-neutral { background: rgba(140, 149, 173, 0.12); color: var(--neutral); }
.pill-trend { background: var(--bg-3); color: var(--text-1); }

.delta-up { color: var(--up); }
.delta-down { color: var(--down); }
.delta-zero { color: var(--text-2); }

/* ===== REGIME TIMELINE ===== */
.regime-timeline {
  background: var(--bg-1);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  max-height: 480px;
  overflow-y: auto;
}
.regime-entry {
  padding: 10px 0;
  border-bottom: 1px solid var(--line-soft);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.regime-entry:last-child { border-bottom: 0; }
.regime-ts {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-2);
}
.regime-shifts {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 13px;
}
.regime-shifts .shift { color: var(--text-0); }
@media (min-width: 700px) {
  .regime-timeline { padding: 20px 24px; }
  .regime-entry {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 16px;
    align-items: baseline;
    flex-direction: row;
  }
  .regime-ts { font-size: 12px; }
  .regime-shifts { font-size: 14px; }
}

/* ===== FOOTER ===== */
.footer {
  margin-top: 56px;
  padding: 24px 0 36px;
  border-top: 1px solid var(--line);
  background: var(--bg-1);
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: var(--text-1);
  font-size: 13px;
}
.footer-disclaimer { color: var(--text-2); font-size: 12px; }
@media (min-width: 700px) {
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
  }
}

/* ===== Loading helpers ===== */
.loading-line { color: var(--text-2); font-family: 'JetBrains Mono', monospace; }

/* iOS safe area + reduced motion */
@supports (padding: env(safe-area-inset-bottom)) {
  body { padding-bottom: env(safe-area-inset-bottom); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}
