/* Verdict design tokens — warmer ink palette w/ acid yellow + signal red */
:root {
  /* Backgrounds: near-black with cool ink tone */
  --bg-base: #07090C;
  --bg-elev: #0C1014;
  --bg-elev-2: #11161B;
  --bg-elev-3: #181F26;

  --line-subtle: #1A2128;
  --line: #232C35;
  --line-strong: #38444F;

  --text: #F5F1E8;       /* warm off-white instead of pure white */
  --text-2: #99A1AA;
  --text-3: #5C656F;
  --text-4: #3A4148;

  /* Acid yellow = primary accent. YES = mint. NO = coral. */
  --acid: #E8FF52;
  --acid-dim: #A8B82F;
  --acid-hover: #F2FF7A;
  --acid-bg10: rgba(232,255,82,0.10);
  --acid-bg20: rgba(232,255,82,0.20);
  --on-accent: #07090C;
  --nav-bg: rgba(7,9,12,0.92);
  --body-dot: rgba(245,241,232,0.025);
  --backdrop-bg: rgba(7, 12, 14, 0.72);

  --mint: #6BE5C1;        /* slightly more saturated, less tropical */
  --mint-dim: #3F9B82;
  --mint-bg10: rgba(107,229,193,0.10);
  --mint-bg20: rgba(107,229,193,0.20);

  --coral: #FF5C6E;       /* sharper, redder than coral pink */
  --coral-dim: #B84050;
  --coral-bg10: rgba(255,92,110,0.10);
  --coral-bg20: rgba(255,92,110,0.20);

  --amber: #F0B23F;
  --info:  #5FA8D9;

  /* Chart series palette extensions (multi-outcome odds lines). */
  --sky: #6FBBF2;
  --violet: #A78BFA;

  /* Rounded like the venues traders already live in (Kalshi ~10px cards). */
  --r-sm: 4px;
  --r:    6px;
  --r-lg: 10px;
  --r-xl: 14px;
  --r-full: 9999px;

  --ease: cubic-bezier(0.2, 0, 0, 1);
  --spring: cubic-bezier(0.34, 1.4, 0.64, 1);
  --d-fast: 120ms;
  --d-base: 200ms;
  --d-slow: 320ms;
  --d-draw: 720ms;
  color-scheme: dark;
}

:root[data-theme="light"] {
  /* Clean white: pure white surfaces, neutral cool grays — no cream/parchment cast. */
  --bg-base: #FFFFFF;
  --bg-elev: #FFFFFF;
  --bg-elev-2: #F5F6F8;
  --bg-elev-3: #ECEEF1;

  --line-subtle: #E7E9EC;
  --line: #D6DADF;
  --line-strong: #AEB4BC;

  --text: #14181D;
  --text-2: #454C55;
  --text-3: #7A828C;
  --text-4: #BFC5CC;

  --acid: #56610A;
  --acid-dim: #7B8700;
  --acid-hover: #2E3400;
  --acid-bg10: rgba(232,255,82,0.15);
  --acid-bg20: rgba(232,255,82,0.26);
  --on-accent: #FFFFFF;

  --mint: #078461;
  --mint-dim: #075F49;
  --mint-bg10: rgba(7,132,97,0.10);
  --mint-bg20: rgba(7,132,97,0.18);

  --coral: #C42839;
  --coral-dim: #8A202B;
  --coral-bg10: rgba(196,40,57,0.10);
  --coral-bg20: rgba(196,40,57,0.18);

  --amber: #8E620F;
  --info: #1D668F;

  /* Chart series palette extensions (multi-outcome odds lines). */
  --sky: #1D6FB0;
  --violet: #6D4FC4;
  --nav-bg: rgba(255,255,255,0.92);
  --body-dot: rgba(20,24,29,0.03);
  --backdrop-bg: rgba(246,247,249,0.78);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { background: var(--bg-base); color: var(--text); margin: 0; padding: 0; }
/* Belt-and-braces: prevent any rogue fixed-width child from blowing out the viewport on mobile.
   Without this, an 800px chart inside a 375px screen would expand the page and break layout.
   `clip` does not create a scroll container, so sticky nav/ticket rails keep working. */
html, body { overflow-x: clip; max-width: 100vw; }
body {
  /* Sans = IBM Plex Sans (technical, neutral, slightly humanist).
     Display = Instrument Serif (high-contrast editorial serif for hero numerics + headlines).
     Mono = JetBrains Mono (sharp tabular numerals). */
  font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  /* Subtle dotted-grid background for the entire app — adds texture without noise */
  background-image: none;
  
}
:root[data-theme="light"] body {
  /* Flat clean white, no texture — dot grids read as template, not product. */
  background-color: var(--bg-base);
  background-image: none;
}
.serif {
  font-family: 'Instrument Serif', 'Times New Roman', serif;
  font-weight: 400;
  letter-spacing: -0.02em;
}

button { font-family: inherit; color: inherit; background: none; border: none; cursor: pointer; padding: 0; }
input, textarea, select { font-family: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }

.num {
  font-family: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' on, 'zero' on, 'ss01' on;
  letter-spacing: -0.01em;
  font-weight: 500;
}

.mono { font-family: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace; }

.cap {
  font-size: 11.5px;
  line-height: 1.4;
  letter-spacing: 0.01em;
  text-transform: none;
  color: var(--text-3);
  font-family: 'IBM Plex Sans', -apple-system, system-ui, sans-serif;
  font-weight: 550;
}
.cap-sm {
  font-size: 11px;
  letter-spacing: 0.01em;
  text-transform: none;
  color: var(--text-3);
  font-family: 'IBM Plex Sans', -apple-system, system-ui, sans-serif;
  font-weight: 500;
}

.h1 { font-family: 'Instrument Serif', serif; font-size: 44px; line-height: 1.05; letter-spacing: -0.03em; font-weight: 400; margin: 0; }
.h2 { font-family: 'Instrument Serif', serif; font-size: 28px; line-height: 1.15; letter-spacing: -0.02em; font-weight: 400; margin: 0; }
.dxl { font-family: 'JetBrains Mono', monospace; font-size: 80px; line-height: 1; letter-spacing: -0.045em; font-weight: 500; }
.dlg { font-family: 'JetBrains Mono', monospace; font-size: 56px; line-height: 1; letter-spacing: -0.04em;  font-weight: 500; }
.dmd { font-family: 'JetBrains Mono', monospace; font-size: 36px; line-height: 1.05; letter-spacing: -0.025em; font-weight: 500; }
.dsm { font-family: 'JetBrains Mono', monospace; font-size: 28px; line-height: 1.1; letter-spacing: -0.025em; font-weight: 500; }

/* ─── Mobile breakpoints ───
   Scales typography and reduces global padding on phones. Inline JSX styles
   that use explicit pixel widths/grids still need component-level isMobile
   handling — these CSS overrides only affect things expressed via classes. */
@media (max-width: 768px) {
  .h1   { font-size: 32px; }
  .h2   { font-size: 22px; }
  .dxl  { font-size: 52px; }
  .dlg  { font-size: 40px; }
  .dmd  { font-size: 28px; }
  .dsm  { font-size: 22px; }
}
@media (max-width: 480px) {
  body  { font-size: 13.5px; }
  .h1   { font-size: 26px; }
  .h2   { font-size: 19px; }
  .dxl  { font-size: 42px; }
  .dlg  { font-size: 34px; }
  .dmd  { font-size: 24px; }
  .dsm  { font-size: 20px; }
  /* Backdrop padding for modals; inner widths still need component handling */
  .vd-backdrop { padding: 12px; }
  /* Tape ticker shorter on phone */
  .tape { height: 26px; }
  /* Reduce default button height a touch */
  .btn-xl { height: 46px; padding: 0 18px; font-size: 14px; }
}

/* Scrollbars */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 8px; border: 2px solid var(--bg-base); }
::-webkit-scrollbar-thumb:hover { background: var(--line-strong); }

/* Selection */
::selection { background: var(--acid-bg20); color: var(--acid); }

/* Skeleton */
@keyframes vd-pulse { 0%,100% { opacity: 0.6; } 50% { opacity: 1; } }
.skel { background: var(--bg-elev-3); border-radius: 6px; animation: vd-pulse 1.5s var(--ease) infinite; }

/* Modal backdrop */
.vd-backdrop {
  position: fixed; inset: 0;
  background: var(--backdrop-bg);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 80;
  display: flex; align-items: center; justify-content: center;
  animation: vd-fade var(--d-base) var(--ease);
}
@keyframes vd-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes vd-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.vd-card-rise { animation: vd-rise var(--d-slow) var(--ease); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 36px; padding: 0 14px;
  border-radius: var(--r);
  font-size: 13px; font-weight: 600;
  border: 1px solid var(--line);
  background: var(--bg-elev-2);
  color: var(--text);
  transition: background var(--d-fast) var(--ease), border-color var(--d-fast) var(--ease), transform var(--d-fast) var(--ease);
}
.btn:hover { background: var(--bg-elev-3); border-color: var(--line-strong); }
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--acid); color: var(--on-accent); border-color: var(--acid);
  font-weight: 600; letter-spacing: -0.01em;
}
.btn-primary:hover { background: var(--acid-hover); border-color: var(--acid-hover); }
.btn-primary-mint {
  background: var(--mint); color: #07090C; border-color: var(--mint);
}
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--bg-elev-2); color: var(--text); }
.btn-lg { height: 44px; padding: 0 18px; font-size: 14px; }
.btn-xl { height: 52px; padding: 0 22px; font-size: 15px; border-radius: var(--r-lg); }
.btn-full { width: 100%; }

/* Chips */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 26px; padding: 0 10px;
  font-size: 12px; font-weight: 600;
  border-radius: var(--r-full);
  border: 1px solid var(--line);
  background: var(--bg-elev);
  color: var(--text-2);
  transition: background var(--d-fast) var(--ease), color var(--d-fast) var(--ease), border-color var(--d-fast) var(--ease);
}
.chip:hover { color: var(--text); border-color: var(--line-strong); }
.chip.is-active { background: var(--bg-elev-3); color: var(--text); border-color: var(--line-strong); }
.chip-mint.is-active { background: var(--mint-bg20); color: var(--mint); border-color: rgba(107,229,193,0.4); }
.chip-acid.is-active { background: var(--acid-bg20); color: var(--acid); border-color: rgba(232,255,82,0.4); }

/* Logo button: hover = subtle lift + acid glow on the mark */
.vd-logo-btn:hover .vd-logo-mark {
  transform: rotate(-6deg) scale(1.06);
  filter: drop-shadow(0 0 10px rgba(232,255,82,0.55));
}
.vd-logo-mark { will-change: transform, filter; }

/* Subtle constant breath on the V's apex dot — adds a "live" pulse to the brand */
@keyframes vd-logo-breathe { 0%,100% { filter: none; } 50% { filter: drop-shadow(0 0 4px rgba(232,255,82,0.35)); } }
.vd-logo-mark { animation: vd-logo-breathe 3.6s var(--ease) infinite; }

/* Live dot */
.live-dot {
  width: 6px; height: 6px; border-radius: 999px; background: var(--acid);
  box-shadow: 0 0 0 0 var(--acid);
  animation: vd-live 2.4s var(--ease) infinite;
}
@keyframes vd-live {
  0% { box-shadow: 0 0 0 0 rgba(232,255,82,0.5); }
  70% { box-shadow: 0 0 0 6px rgba(232,255,82,0); }
  100% { box-shadow: 0 0 0 0 rgba(232,255,82,0); }
}

/* Chart-loading skeleton: a soft band sweeping across the plot while history loads. */
.vd-chart-loading {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.vd-chart-loading::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 45%;
  background: linear-gradient(90deg, transparent, var(--bg-elev-2), transparent);
  animation: vd-chart-shimmer 1.5s var(--ease) infinite;
}
@keyframes vd-chart-shimmer {
  from { transform: translateX(-100%); }
  to { transform: translateX(320%); }
}

/* Generic shimmer block for skeleton placeholders (cards, sparklines). */
.vd-skel {
  position: relative;
  overflow: hidden;
  background: var(--bg-elev-2);
  border-radius: var(--r);
}
.vd-skel::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 45%;
  background: linear-gradient(90deg, transparent, var(--bg-elev-3), transparent);
  animation: vd-chart-shimmer 1.5s var(--ease) infinite;
}

/* ── EXPERIMENTAL: Hyperliquid palette (their trade UI, sampled from their bundle).
   Opt-in only via ?theme=hl — never reachable from the normal toggle. Roll back with
   ?theme=light (or ?theme=dark). Delete this block to kill the experiment. */
:root[data-theme="hl"] {
  --bg-base: #0F1A1F;
  --bg-elev: #14232B;
  --bg-elev-2: #192B34;
  --bg-elev-3: #20353F;

  --line-subtle: rgba(157,178,189,0.12);
  --line: rgba(157,178,189,0.20);
  --line-strong: rgba(157,178,189,0.34);

  --text: #F1F6F9;
  --text-2: #C2D1D9;
  --text-3: #9DB2BD;
  --text-4: #64798A;

  --acid: #50D2C1;
  --acid-dim: #3AA392;
  --acid-hover: #74E2D3;
  --acid-bg10: rgba(80,210,193,0.12);
  --acid-bg20: rgba(80,210,193,0.22);
  --on-accent: #0F1A1F;
  --nav-bg: rgba(15,26,31,0.88);
  --body-dot: rgba(157,178,189,0.04);
  --backdrop-bg: rgba(8,16,20,0.74);

  --mint: #26A69A;
  --mint-dim: #1E7F76;
  --mint-bg10: rgba(38,166,154,0.13);
  --mint-bg20: rgba(38,166,154,0.24);

  --coral: #ED7088;
  --coral-dim: #B25266;
  --coral-bg10: rgba(237,112,136,0.12);
  --coral-bg20: rgba(237,112,136,0.22);

  --amber: #E8C268;
  --info: #6FA8D9;
  --sky: #6AA6FF;
  --violet: #8B7BFF;
}
:root[data-theme="hl"] body {
  background-color: var(--bg-base);
  background-image: radial-gradient(circle at 1px 1px, var(--body-dot) 1px, transparent 0);
  background-size: 24px 24px;
}

/* Landing: scroll-reveal, floating hero card, diagram draw-in. */
.vd-reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 560ms var(--ease), transform 560ms var(--ease);
  will-change: opacity, transform;
}
.vd-reveal.is-in { opacity: 1; transform: none; }
.vd-float { animation: vd-float 7s ease-in-out infinite; }
@keyframes vd-float {
  0%, 100% { transform: translateY(0) rotate(var(--tilt, 0deg)); }
  50% { transform: translateY(-9px) rotate(var(--tilt, 0deg)); }
}
.vd-draw [data-draw] {
  stroke-dasharray: 300;
  stroke-dashoffset: 300;
}
.is-in .vd-draw [data-draw],
.vd-reveal.is-in [data-draw] {
  animation: vd-drawin 1100ms var(--ease) 220ms forwards;
}
@keyframes vd-drawin { to { stroke-dashoffset: 0; } }

/* Scanning HUD frame — corner brackets + mono label + acid sweep line that
   frames the hero live-market card (the "scanning" motif). */
.vd-scan { position: relative; display: inline-block; padding: 26px 22px; }
.vd-scan__corner { position: absolute; width: 16px; height: 16px; pointer-events: none; z-index: 2; }
.vd-scan__corner::before, .vd-scan__corner::after { content: ""; position: absolute; background: var(--line-strong); }
.vd-scan__corner::before { width: 16px; height: 1px; }
.vd-scan__corner::after  { width: 1px; height: 16px; }
.vd-scan__corner.tl { top: 0; left: 0; }
.vd-scan__corner.tr { top: 0; right: 0; } .vd-scan__corner.tr::before { right: 0; } .vd-scan__corner.tr::after { right: 0; }
.vd-scan__corner.bl { bottom: 0; left: 0; } .vd-scan__corner.bl::before { bottom: 0; } .vd-scan__corner.bl::after { bottom: 0; }
.vd-scan__corner.br { bottom: 0; right: 0; } .vd-scan__corner.br::before { bottom: 0; right: 0; } .vd-scan__corner.br::after { bottom: 0; right: 0; }
.vd-scan__tag {
  position: absolute; top: 7px; z-index: 2;
  font-family: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 9px; letter-spacing: 0.18em; text-transform: uppercase;
}
.vd-scan__tag--l { left: 12px; color: var(--acid); }
.vd-scan__tag--r { right: 12px; color: var(--text-3); }
.vd-scan__line {
  position: absolute; left: 14px; right: 14px; top: 14px; height: 1px; z-index: 2; pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--acid), transparent);
  opacity: 0.7; will-change: top;
  animation: vd-scan-sweep 4.2s cubic-bezier(.4, 0, .2, 1) infinite;
}
@keyframes vd-scan-sweep { 0%, 100% { top: 14px; } 50% { top: calc(100% - 15px); } }
.vd-scan__line { box-shadow: 0 0 8px var(--acid); }

/* ---- Landing nav tabs: bigger + animated acid underline ---- */
.vd-tab {
  position: relative; background: transparent; border: 0; cursor: pointer;
  font-family: inherit; font-size: 15.5px; font-weight: 500; letter-spacing: -0.01em;
  color: var(--text-2); height: 42px; padding: 0 16px; border-radius: var(--r);
  transition: color 160ms var(--ease);
}
.vd-tab::after {
  content: ""; position: absolute; left: 16px; right: 16px; bottom: 7px; height: 2px;
  background: var(--acid); border-radius: 2px;
  transform: scaleX(0); transform-origin: center; opacity: 0;
  transition: transform 240ms var(--spring), opacity 200ms var(--ease);
}
.vd-tab:hover { color: var(--text); }
.vd-tab:hover::after { transform: scaleX(1); opacity: 1; }
.vd-tab--mobile { height: 38px; font-size: 14.5px; white-space: nowrap; }

/* ---- Dopamine: breathing acid glow on the primary CTA ---- */
.vd-pulse-glow { animation: vd-pulse-glow 2.8s ease-in-out infinite; }
@keyframes vd-pulse-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(232,255,82,0.0); }
  50% { box-shadow: 0 0 24px 1px var(--acid-bg20); }
}

/* ---- Ambient-music equalizer ---- */
.vd-eq { display: inline-flex; align-items: flex-end; gap: 2.5px; height: 15px; }
.vd-eq i { width: 2.5px; background: var(--acid); border-radius: 1px; height: 30%; transition: height 90ms linear; }
.vd-eq.is-idle i { opacity: 0.5; height: 30%; }

/* ---- Force dark-theme tokens for content on a dark media background (rocket video)
   so light-theme dark text/borders don't vanish on the footage. No-op in dark theme. ---- */
.vd-on-dark {
  --text: #F5F1E8; --text-2: #C2C8D0; --text-3: #8A93A0; --text-4: #3A4148;
  --acid: #E8FF52; --acid-hover: #F2FF7A; --acid-dim: #A8B82F; --on-accent: #07090C;
  --bg-elev: #0C1014; --bg-elev-2: #11161B; --bg-elev-3: #181F26; --bg-base: #07090C;
  --line: #232C35; --line-subtle: #1A2128; --line-strong: #38444F;
  --mint: #6BE5C1; --mint-bg10: rgba(107,229,193,0.10); --mint-bg20: rgba(107,229,193,0.20);
  --coral: #FF5C6E; --coral-bg10: rgba(255,92,110,0.10); --coral-bg20: rgba(255,92,110,0.20);
  color: var(--text);
}

/* ---- In-app access gate (client-side guard screen) ---- */
.vd-gate-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--bg-base); }
.vd-gate-box { width: min(380px, calc(100vw - 48px)); border: 1px solid var(--line-subtle); border-radius: var(--r-xl);
  background: var(--bg-elev); padding: 30px 28px; box-shadow: 0 24px 60px rgba(0,0,0,0.35); }
.vd-gate-box input { width: 100%; box-sizing: border-box; height: 46px; padding: 0 14px; margin-top: 6px; font-size: 15px;
  font-family: inherit; color: var(--text); background: var(--bg-elev-2); border: 1px solid var(--line); border-radius: var(--r); outline: none; }
.vd-gate-box input:focus { border-color: var(--acid); }

/* Chat typing indicator — three bouncing dots. */
.vd-typing { display: inline-flex; gap: 4px; align-items: center; }
.vd-typing i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--acid);
  display: block;
  animation: vd-bounce 1.2s var(--ease) infinite;
}
.vd-typing i:nth-child(2) { animation-delay: 0.15s; }
.vd-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes vd-bounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-4px); opacity: 1; }
}

/* Chart-loading squiggle: a placeholder step-line that draws itself, loops, fades. */
.vd-skel-line {
  stroke-dasharray: 1000;
  animation: vd-line-draw 2.6s ease-in-out infinite;
}
/* World Cup hub: staggered box pop-in, hover-lift, hero sheen, tab-pane fade. */
.vd-wc-box {
  animation: vd-pop var(--d-slow) var(--ease) both;
  transition: transform var(--d-fast) var(--ease), box-shadow var(--d-fast) var(--ease), border-color var(--d-fast) var(--ease);
}
.vd-wc-box:hover {
  transform: translateY(-3px);
  border-color: var(--mint) !important;
  box-shadow: 0 10px 26px rgba(17,16,13,0.10);
}
:root[data-theme="dark"] .vd-wc-box:hover { box-shadow: 0 10px 28px rgba(0,0,0,0.35); }
@keyframes vd-pop { from { opacity: 0; transform: translateY(10px) scale(0.985); } to { opacity: 1; transform: none; } }
.vd-wc-hero { position: relative; overflow: hidden; animation: vd-rise var(--d-slow) var(--ease) both; }
.vd-wc-hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 38%, rgba(107,229,193,0.12) 50%, transparent 62%);
  transform: translateX(-130%);
  animation: vd-wc-sheen 5s var(--ease) 0.8s infinite;
}
@keyframes vd-wc-sheen { 0% { transform: translateX(-130%); } 32%, 100% { transform: translateX(130%); } }
.vd-wc-tabpane { animation: vd-fade var(--d-base) var(--ease); }

/* ── AI Strategies: polished conversational redesign ── */
/* Soft elevated answer card. */
.vd-ai-card {
  background: var(--bg-elev);
  border: 1px solid var(--line-subtle);
  border-radius: 16px;
  transition: transform var(--d-fast) var(--ease), box-shadow var(--d-fast) var(--ease), border-color var(--d-fast) var(--ease);
}
:root[data-theme="light"] .vd-ai-card { box-shadow: 0 1px 2px rgba(17,16,13,0.04), 0 14px 34px rgba(17,16,13,0.06); }
:root[data-theme="dark"]  .vd-ai-card { box-shadow: 0 1px 2px rgba(0,0,0,0.30), 0 14px 34px rgba(0,0,0,0.22); }
.vd-ai-card.is-interactive { cursor: pointer; }
.vd-ai-card.is-interactive:hover { transform: translateY(-2px); border-color: var(--line-strong); }
/* Probability meter inside a card. */
.vd-meter { height: 8px; border-radius: 999px; background: var(--bg-elev-3); overflow: hidden; }
.vd-meter > i { display: block; height: 100%; border-radius: 999px; transition: width var(--d-slow) var(--ease); }
/* Suggestion chip on the welcome screen. */
.vd-suggest {
  text-align: left; cursor: pointer; width: 100%; min-width: 0;
  border: 1px solid var(--line-subtle); background: var(--bg-elev);
  border-radius: 14px; padding: 13px 15px;
  display: grid; gap: 3px;
  transition: border-color var(--d-fast) var(--ease), transform var(--d-fast) var(--ease), box-shadow var(--d-fast) var(--ease);
}
.vd-suggest:hover { border-color: var(--acid); transform: translateY(-1px); }
:root[data-theme="light"] .vd-suggest:hover { box-shadow: 0 8px 22px rgba(17,16,13,0.06); }
/* Rounded input pill (welcome + sticky composer). */
.vd-ai-input {
  border: 1px solid var(--line-subtle); background: var(--bg-elev);
  border-radius: 18px;
  transition: border-color var(--d-fast) var(--ease), box-shadow var(--d-fast) var(--ease);
}
.vd-ai-input:focus-within { border-color: var(--acid); box-shadow: 0 0 0 3px var(--acid-bg10); }
:root[data-theme="light"] .vd-ai-input { box-shadow: 0 2px 4px rgba(17,16,13,0.04), 0 18px 44px rgba(17,16,13,0.08); }
:root[data-theme="dark"]  .vd-ai-input { box-shadow: 0 18px 44px rgba(0,0,0,0.30); }
/* Round send button. */
.vd-send {
  flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  border: none; cursor: pointer; background: var(--acid); color: var(--acid-ink, #1b1f00);
  transition: transform var(--d-fast) var(--ease), opacity var(--d-fast) var(--ease);
}
.vd-send:hover:not(:disabled) { transform: scale(1.06); }
.vd-send:disabled { opacity: 0.4; cursor: default; }
/* Numbered source pill. */
.vd-cite {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line-subtle); background: var(--bg-elev-2);
  border-radius: 999px; padding: 4px 10px 4px 6px; font-size: 12px; color: var(--text-3);
  transition: border-color var(--d-fast) var(--ease), color var(--d-fast) var(--ease);
}
.vd-cite:hover { border-color: var(--line-strong); color: var(--text-2); }
.vd-cite > b { width: 16px; height: 16px; border-radius: 50%; background: var(--bg-elev-3); color: var(--text-3); font-size: 10px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
/* Entrances. */
.vd-ai-hero { animation: vd-rise var(--d-slow) var(--ease) both; }
.vd-ai-msg { animation: vd-fade var(--d-base) var(--ease); }

/* Accessibility: kill decorative animation for users who ask for less motion. */
@media (prefers-reduced-motion: reduce) {
  .vd-skel::after,
  .vd-skel-line,
  .vd-chart-loading::before,
  .live-dot,
  .vd-typing i,
  .vd-float,
  .vd-scan__line,
  .vd-pulse-glow,
  .vd-wc-box,
  .vd-wc-hero,
  .vd-wc-hero::after,
  .vd-wc-tabpane,
  .vd-ai-hero,
  .vd-ai-msg,
  .vd-glyph { animation: none !important; }
  .vd-ai-card.is-interactive:hover, .vd-suggest:hover, .vd-send:hover:not(:disabled) { transform: none; }
  .vd-wc-box:hover { transform: none; }
  .vd-reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .vd-draw [data-draw] { stroke-dashoffset: 0 !important; animation: none !important; }
}

@keyframes vd-line-draw {
  0% { stroke-dashoffset: 1000; opacity: 0.75; }
  60% { stroke-dashoffset: 0; opacity: 0.75; }
  82% { stroke-dashoffset: 0; opacity: 0.75; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}

/* Hairline divider */
.hr { height: 1px; background: var(--line-subtle); border: 0; margin: 0; }

/* Card */
.card {
  background: var(--bg-elev);
  border: 1px solid var(--line-subtle);
  border-radius: var(--r-lg);
}
:root[data-theme="light"] .card {
  box-shadow: 0 1px 0 rgba(17,16,13,0.04), 0 16px 38px rgba(17,16,13,0.045);
}
:root[data-theme="light"] .btn-primary {
  box-shadow: 0 0 0 1px rgba(81,90,0,0.12), 0 10px 24px rgba(81,90,0,0.16);
}
:root[data-theme="light"] .lift:hover {
  border-color: rgba(81,90,0,0.34);
}

/* Toast */
.vd-toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%);
  background: var(--bg-elev-3);
  border: 1px solid var(--line);
  border-left: 2px solid var(--acid);
  padding: 12px 16px;
  border-radius: var(--r-lg);
  z-index: 200;
  display: flex; align-items: center; gap: 10px;
  font-size: 13px;
  animation: vd-toast-in var(--d-slow) var(--spring);
}
@keyframes vd-toast-in {
  from { opacity: 0; transform: translate(-50%, 12px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* Hover lift cards */
.lift {
  transition: transform var(--d-base) var(--ease), border-color var(--d-base) var(--ease), background var(--d-base) var(--ease);
}
.lift:hover {
  transform: translateY(-2px);
  border-color: rgba(232,255,82,0.30);
}

/* Tape ticker — for top of page */
.tape {
  border-top: 1px solid var(--line-subtle);
  border-bottom: 1px solid var(--line-subtle);
  background: linear-gradient(180deg, var(--bg-elev) 0%, var(--bg-base) 100%);
  overflow: hidden;
  height: 30px; display: flex; align-items: center;
}
:root[data-theme="light"] .tape {
  background:
    linear-gradient(180deg, rgba(255,254,250,0.96) 0%, rgba(240,238,229,0.86) 100%),
    linear-gradient(90deg, rgba(232,255,82,0.20), transparent 42%);
}
.tape-track { display: flex; gap: 36px; animation: vd-tape 60s linear infinite; padding-left: 24px; white-space: nowrap; }
.tape:hover .tape-track { animation-play-state: paused; }
@keyframes vd-tape { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.tape-item { display: inline-flex; align-items: center; gap: 8px; font-size: 11px; color: var(--text-3); }
.tape-item .num { font-size: 11px; }

@media (prefers-reduced-motion: reduce) {
  .tape-track,
  .live-dot,
  .vd-logo-mark {
    animation: none !important;
  }
  .lift,
  .btn,
  .chip {
    transition: none !important;
  }
}

/* Pill labels */
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 2px 8px; border-radius: 4px;
  font-size: 10px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  font-family: 'JetBrains Mono', monospace;
}
.pill-acid { background: var(--acid-bg20); color: var(--acid); border: 1px solid rgba(232,255,82,0.3); }
.pill-mint { background: var(--mint-bg20); color: var(--mint); border: 1px solid rgba(107,229,193,0.3); }
.pill-coral { background: var(--coral-bg20); color: var(--coral); border: 1px solid rgba(255,92,110,0.3); }

/* Crosshair separator */
.xhair {
  position: relative;
}
.xhair::before, .xhair::after {
  content: ''; position: absolute; background: var(--line);
}

/* Acid focus ring */
:focus-visible { outline: 2px solid var(--acid); outline-offset: 2px; }



input.vd-input, textarea.vd-input {
  width: 100%;
  background: var(--bg-elev-2);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: var(--r);
  padding: 10px 12px;
  font-size: 14px;
  outline: none;
  transition: border-color var(--d-fast) var(--ease);
}
input.vd-input:focus, textarea.vd-input:focus { border-color: var(--mint-dim); }

/* Asset glyph: subtle pop + glow on row hover */
.vd-row:hover .vd-glyph,
.vd-glyph:hover {
  transform: scale(1.08) rotate(-3deg);
  filter: drop-shadow(0 4px 10px rgba(232,255,82,0.18));
}
.vd-row:hover .vd-glyph svg circle,
.vd-row:hover .vd-glyph svg rect {
  filter: brightness(1.08);
}

/* Watchlist row chevron — slides in on hover */
.vd-row .vd-rowchev {
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 200ms var(--ease), transform 240ms cubic-bezier(.2,1.2,.4,1);
}
.vd-row:hover .vd-rowchev {
  opacity: 1;
  transform: translateX(0);
}

/* Sparkline: ride into focus on hover */
.vd-row .vd-spark {
  transition: transform 280ms var(--ease), filter 280ms var(--ease);
}
.vd-row:hover .vd-spark {
  transform: scaleY(1.08);
  filter: brightness(1.15) drop-shadow(0 0 6px currentColor);
}
