/* ===========================================================
   SUPRANOMICS — Stylesheet
   Theme: deep navy + cobalt + violet, glassmorphism, mobile first
   =========================================================== */

:root {
  --bg-0: #050a17;
  --bg-1: #0a1628;
  --bg-2: #0f1d36;
  --surface: rgba(20, 32, 60, 0.55);
  --surface-2: rgba(30, 44, 78, 0.65);
  --border: rgba(120, 160, 240, 0.18);
  --border-strong: rgba(120, 160, 240, 0.32);
  --text: #e6ecf7;
  --text-dim: #93a3c4;
  --text-mute: #5d6d8c;
  --primary: #4a7df0;
  --primary-2: #1e4dd6;
  --accent: #8b5cf6;
  --accent-2: #c084fc;
  --green: #22c55e;
  --green-soft: rgba(34, 197, 94, 0.15);
  --red: #ef4444;
  --red-soft: rgba(239, 68, 68, 0.15);
  --yellow: #f59e0b;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 22px;
  --header-h: 64px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

/* Always honor the [hidden] attribute, even on flex/grid containers */
[hidden] { display: none !important; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  background: var(--bg-0);
  color: var(--text);
  font-size: 15px;
  line-height: 1.55;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

/* ---------- Background ---------- */
#bg-canvas {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: -2; pointer-events: none;
  background:
    radial-gradient(ellipse at 20% 10%, rgba(74, 125, 240, 0.18), transparent 55%),
    radial-gradient(ellipse at 85% 25%, rgba(139, 92, 246, 0.18), transparent 60%),
    radial-gradient(ellipse at 50% 90%, rgba(34, 197, 94, 0.08), transparent 60%),
    linear-gradient(180deg, #050a17 0%, #0a1628 60%, #050a17 100%);
}
.bg-glow {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(circle at var(--mx, 50%) var(--my, 30%),
      rgba(74, 125, 240, 0.10), transparent 35%);
  transition: background 0.3s ease;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-weight: 600; font-size: 14px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  transition: all 0.18s ease;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  color: #fff;
  box-shadow: 0 8px 24px -8px rgba(74, 125, 240, 0.55);
}
.btn-primary:hover { box-shadow: 0 12px 32px -8px rgba(74, 125, 240, 0.75); }
.btn-ghost {
  background: var(--surface);
  border-color: var(--border);
  backdrop-filter: blur(10px);
}
.btn-ghost:hover { border-color: var(--border-strong); background: var(--surface-2); }
.btn-icon {
  padding: 9px;
  background: var(--surface);
  border-color: var(--border);
  color: var(--text-dim);
}
.btn-icon:hover { color: var(--text); border-color: var(--border-strong); }
.btn-coin {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff;
  box-shadow: 0 8px 24px -8px rgba(245, 158, 11, 0.5);
}
.btn-lg { padding: 14px 24px; font-size: 15px; }
.full { width: 100%; justify-content: center; }
.icon-btn {
  background: transparent; border: none; color: var(--text-dim);
  font-size: 22px; padding: 4px 10px; border-radius: 6px;
}
.icon-btn:hover { background: var(--surface); color: var(--text); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(16px);
  background: rgba(5, 10, 23, 0.7);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  max-width: 1400px; margin: 0 auto;
  padding: 12px 24px;
  height: var(--header-h);
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo { width: 36px; height: 36px; border-radius: 8px; }
.brand-logo.small { width: 24px; height: 24px; }
.brand-name {
  font-weight: 800; font-size: 18px; letter-spacing: -0.01em;
  background: linear-gradient(135deg, #fff 0%, #9bbcf5 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}

.primary-nav { display: flex; gap: 4px; }
.nav-link {
  color: var(--text-dim);
  padding: 8px 14px; border-radius: 8px;
  font-size: 14px; font-weight: 500;
  transition: all 0.15s ease;
}
.nav-link:hover { color: var(--text); background: var(--surface); }
.nav-link.active { color: var(--text); background: var(--surface); }

.header-actions { display: flex; align-items: center; gap: 8px; }
.mobile-only { display: none; }

.mobile-menu {
  display: flex; flex-direction: column; gap: 4px;
  padding: 12px 24px 16px;
  border-top: 1px solid var(--border);
  background: rgba(5, 10, 23, 0.95);
}
.mobile-menu .nav-link { padding: 12px 14px; }

/* ---------- Demo banner ---------- */
.demo-banner {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 24px;
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.15), rgba(139, 92, 246, 0.15));
  border-bottom: 1px solid rgba(245, 158, 11, 0.3);
  font-size: 13px;
}
.demo-banner .dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--yellow);
  box-shadow: 0 0 8px var(--yellow);
  animation: pulseDot 1.6s infinite;
}
.demo-banner strong { color: var(--yellow); letter-spacing: 0.06em; }
.demo-banner .demo-meta { color: var(--text-dim); }
.demo-banner button { margin-left: auto; background: none; border: none; color: var(--text-dim); font-size: 18px; }

@keyframes pulseDot { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ---------- Hero ---------- */
.hero {
  padding: 56px 24px 32px;
  max-width: 1200px; margin: 0 auto;
  text-align: center;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 13px; color: var(--text-dim);
  backdrop-filter: blur(10px);
}
.pulse {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulseDot 1.6s infinite;
}
.hero-title {
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 18px 0 14px;
}
.hero-title .grad {
  background: linear-gradient(135deg, #4a7df0 0%, #8b5cf6 50%, #c084fc 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-sub {
  max-width: 640px; margin: 0 auto 28px;
  color: var(--text-dim);
  font-size: clamp(15px, 1.6vw, 18px);
}
.hero-stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 12px; max-width: 800px; margin: 0 auto 28px;
}
.stat {
  background: var(--surface); border: 1px solid var(--border);
  padding: 16px 12px; border-radius: var(--radius);
  backdrop-filter: blur(10px);
}
.stat-num {
  font-size: clamp(18px, 2.4vw, 24px);
  font-weight: 800; letter-spacing: -0.02em;
}
.stat-label { color: var(--text-dim); font-size: 12px; }
.hero-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------- Section heads ---------- */
.section-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap;
  max-width: 1400px; margin: 0 auto 16px;
  padding: 0 24px;
}
.section-head h2 {
  margin: 0; font-size: clamp(22px, 3vw, 28px);
  font-weight: 800; letter-spacing: -0.02em;
}
.section-head .link { color: var(--primary); font-weight: 600; font-size: 14px; }
.tag-new {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff; padding: 2px 10px; border-radius: 6px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.05em;
}
.section-sub {
  max-width: 1400px; margin: -8px auto 24px; padding: 0 24px;
  color: var(--text-dim);
}

/* ---------- Featured rail ---------- */
.featured { padding: 32px 0 16px; }
.featured-rail {
  display: flex; gap: 14px; overflow-x: auto;
  padding: 4px 24px 16px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
}
.featured-rail::-webkit-scrollbar { height: 6px; }
.featured-rail::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.feat-card {
  flex: 0 0 320px; scroll-snap-align: start;
  background: linear-gradient(135deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  position: relative; overflow: hidden;
  backdrop-filter: blur(10px);
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.feat-card:hover { transform: translateY(-3px); border-color: var(--border-strong); }
.feat-card .hot {
  position: absolute; top: 12px; right: 12px;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff; font-size: 10px; font-weight: 800;
  padding: 3px 8px; border-radius: 100px;
  letter-spacing: 0.05em;
}
.feat-card .feat-cat {
  font-size: 12px; color: var(--primary); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
}
.feat-card h3 {
  font-size: 15px; margin: 8px 0 14px;
  line-height: 1.35; font-weight: 700;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 41px;
}
.feat-bar {
  height: 6px; border-radius: 100px;
  background: var(--red-soft); overflow: hidden; margin-bottom: 6px;
}
.feat-bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--green), #34d399); border-radius: 100px; }
.feat-prices {
  display: flex; justify-content: space-between;
  font-size: 13px; color: var(--text-dim); margin-bottom: 12px;
}
.feat-meta {
  display: flex; justify-content: space-between;
  font-size: 11px; color: var(--text-mute); margin-bottom: 12px;
}
.feat-actions { display: flex; gap: 8px; }
.feat-actions .btn { flex: 1; padding: 9px 10px; font-size: 13px; }

/* ---------- Markets section ---------- */
.markets-section { padding: 24px 0 48px; }
.search-wrap {
  display: flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 100px; padding: 8px 14px; min-width: 280px;
  backdrop-filter: blur(10px);
}
.search-wrap input {
  flex: 1; background: transparent; border: none; color: var(--text);
  outline: none; font-size: 14px; font-family: inherit;
}
.search-wrap svg { color: var(--text-dim); flex-shrink: 0; }

.category-bar {
  display: flex; gap: 6px; overflow-x: auto;
  padding: 4px 24px 12px;
  max-width: 1400px; margin: 0 auto;
  scrollbar-width: none;
}
.category-bar::-webkit-scrollbar { display: none; }
.cat-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 100px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text-dim); font-size: 13px; font-weight: 500;
  white-space: nowrap; flex-shrink: 0;
  transition: all 0.15s ease; backdrop-filter: blur(10px);
}
.cat-pill:hover { color: var(--text); border-color: var(--border-strong); }
.cat-pill.active {
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  color: #fff; border-color: transparent;
  box-shadow: 0 6px 20px -8px rgba(74, 125, 240, 0.55);
}
.cat-pill .count {
  background: rgba(255,255,255,0.18); padding: 1px 7px;
  border-radius: 10px; font-size: 11px; font-weight: 700;
}

.sort-bar {
  display: flex; gap: 6px; align-items: center; flex-wrap: wrap;
  max-width: 1400px; margin: 0 auto 16px;
  padding: 0 24px;
}
.sort-label { color: var(--text-mute); font-size: 13px; margin-right: 4px; }
.sort-btn {
  background: transparent; border: 1px solid transparent;
  color: var(--text-dim); padding: 6px 12px; border-radius: 8px;
  font-size: 13px; font-weight: 500;
}
.sort-btn:hover { color: var(--text); }
.sort-btn.active {
  background: var(--surface); border-color: var(--border);
  color: var(--text);
}

/* ---------- Market grid ---------- */
.market-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 14px;
  max-width: 1400px; margin: 0 auto;
  padding: 0 24px;
}

.market-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px;
  position: relative;
  display: flex; flex-direction: column; gap: 10px;
  backdrop-filter: blur(10px);
  transition: all 0.18s ease;
}
.market-card:hover {
  transform: translateY(-2px); border-color: var(--border-strong);
  box-shadow: 0 10px 30px -10px rgba(74, 125, 240, 0.25);
}
.market-card.parlay-selected {
  border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 10px 30px -10px rgba(139, 92, 246, 0.5);
}

.mc-head { display: flex; align-items: center; gap: 8px; }
.mc-cat {
  font-size: 11px; color: var(--primary);
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
}
.mc-tag {
  font-size: 10px; padding: 2px 7px; border-radius: 100px;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff; font-weight: 700; letter-spacing: 0.05em;
}
.mc-tag.featured { background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.mc-title {
  font-size: 14.5px; font-weight: 600; line-height: 1.4;
  color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 40px;
}

.mc-prob-bar {
  height: 6px; border-radius: 100px;
  background: var(--red-soft); overflow: hidden;
  position: relative;
}
.mc-prob-bar > span {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--green), #34d399);
  border-radius: 100px;
  transition: width 0.4s ease;
}
.mc-prices { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.mc-prices .yes { color: var(--green); font-weight: 700; }
.mc-prices .no  { color: var(--red);   font-weight: 700; }

.mc-meta {
  display: flex; gap: 12px; flex-wrap: wrap;
  font-size: 11px; color: var(--text-mute);
}

.mc-actions { display: flex; gap: 6px; }
.mc-btn {
  flex: 1; padding: 9px 8px; font-size: 12.5px;
  border-radius: 8px; font-weight: 600;
  border: 1px solid var(--border);
  background: var(--surface); color: var(--text);
  transition: all 0.15s ease;
}
.mc-btn:hover { border-color: var(--border-strong); }
.mc-btn.yes:hover { background: var(--green-soft); border-color: var(--green); color: var(--green); }
.mc-btn.no:hover  { background: var(--red-soft);   border-color: var(--red);   color: var(--red); }
.mc-btn.parlay:hover { background: rgba(139, 92, 246, 0.18); border-color: var(--accent); color: var(--accent-2); }
.mc-btn.parlay.in {
  background: rgba(139, 92, 246, 0.25); border-color: var(--accent); color: var(--accent-2);
}

.mc-options {
  display: flex; flex-direction: column; gap: 6px;
  max-height: 140px; overflow-y: auto;
}
.mc-option {
  display: flex; justify-content: space-between; align-items: center;
  padding: 7px 10px; border-radius: 8px;
  background: rgba(255,255,255,0.03);
  font-size: 12.5px;
}
.mc-option .pct { color: var(--primary); font-weight: 700; }

.empty-state {
  text-align: center; padding: 60px 24px; color: var(--text-dim);
}
.empty-icon { font-size: 48px; margin-bottom: 12px; }

/* ---------- Agents ---------- */
.agents-section { padding: 48px 0 32px; }
.agents-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  max-width: 1400px; margin: 0 auto;
  padding: 0 24px;
}
.agent-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px;
  display: flex; flex-direction: column; gap: 10px;
  backdrop-filter: blur(10px); transition: all 0.18s ease;
}
.agent-card:hover { transform: translateY(-3px); border-color: var(--border-strong); }
.agent-icon {
  width: 48px; height: 48px; border-radius: 12px;
  display: grid; place-items: center; font-size: 22px;
}
.agent-card h3 { margin: 0; font-size: 16px; }
.agent-card p  { margin: 0; color: var(--text-dim); font-size: 13.5px; }
.agent-stats {
  display: flex; gap: 14px; font-size: 12px; color: var(--text-dim);
  margin-top: 4px;
}
.green { color: var(--green); }

/* ---------- Leaderboard ---------- */
.leaderboard-section { padding: 32px 0; }
.leaderboard {
  max-width: 1400px; margin: 0 auto;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  margin-left: 24px; margin-right: 24px;
  backdrop-filter: blur(10px);
}
.lb-row {
  display: grid; grid-template-columns: 40px 1.5fr 1fr 1fr 80px;
  padding: 12px 18px; gap: 8px;
  border-bottom: 1px solid var(--border);
  font-size: 14px; align-items: center;
}
.lb-row:last-child { border-bottom: none; }
.lb-head {
  background: rgba(74, 125, 240, 0.06);
  font-size: 12px; color: var(--text-dim);
  text-transform: uppercase; letter-spacing: 0.05em; font-weight: 700;
}
.addr { font-family: 'JetBrains Mono', ui-monospace, Menlo, monospace; color: var(--text); }

/* ---------- Features ---------- */
.features-section { padding: 32px 0 64px; }
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
  max-width: 1400px; margin: 0 auto;
  padding: 0 24px;
}
.feature {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px;
  backdrop-filter: blur(10px);
}
.feature-icon {
  font-size: 28px; margin-bottom: 10px;
  width: 52px; height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(74,125,240,0.2), rgba(139,92,246,0.2));
  display: grid; place-items: center;
}
.feature h3 { margin: 0 0 6px; font-size: 16px; }
.feature p  { margin: 0; color: var(--text-dim); font-size: 13.5px; }

/* ---------- Parlay panel ---------- */
.parlay-fab {
  position: fixed; bottom: 20px; right: 20px;
  display: flex; align-items: center; gap: 8px;
  padding: 14px 18px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff; border: none;
  border-radius: 100px; font-weight: 700;
  box-shadow: 0 12px 36px -10px rgba(139, 92, 246, 0.6);
  z-index: 40;
  transition: transform 0.2s ease;
}
.parlay-fab:hover { transform: scale(1.05); }
.fab-count {
  background: #fff; color: var(--accent);
  width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center;
  font-size: 12px; font-weight: 800;
}

.parlay-panel {
  position: fixed; top: 0; right: 0; bottom: 0;
  width: min(380px, 90vw); z-index: 60;
  background: rgba(10, 22, 40, 0.95);
  backdrop-filter: blur(20px);
  border-left: 1px solid var(--border);
  display: flex; flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.25s ease;
  box-shadow: -20px 0 60px rgba(0,0,0,0.5);
}
.parlay-panel.open { transform: translateX(0); }
.parlay-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.parlay-head h3 { margin: 0; font-size: 16px; }

.parlay-empty { padding: 40px 20px; text-align: center; color: var(--text-dim); }
.parlay-empty .big-icon { font-size: 56px; margin-bottom: 8px; }
.parlay-empty small { color: var(--text-mute); }

.parlay-list {
  flex: 1; list-style: none; margin: 0;
  padding: 12px 16px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 8px;
}
.parlay-item {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 12px;
  display: flex; flex-direction: column; gap: 4px; position: relative;
}
.parlay-item .pi-title {
  font-size: 12.5px; padding-right: 24px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.parlay-item .pi-side {
  display: inline-block; padding: 1px 8px; border-radius: 100px;
  font-size: 10px; font-weight: 700;
}
.parlay-item .pi-side.yes { background: var(--green-soft); color: var(--green); }
.parlay-item .pi-side.no  { background: var(--red-soft);   color: var(--red); }
.parlay-item .pi-meta { display: flex; gap: 10px; font-size: 11px; color: var(--text-mute); }
.parlay-item .pi-remove {
  position: absolute; top: 6px; right: 6px;
  background: none; border: none; color: var(--text-mute);
  font-size: 16px; padding: 2px 6px; border-radius: 4px;
}
.parlay-item .pi-remove:hover { background: var(--surface-2); color: var(--red); }

.parlay-foot {
  border-top: 1px solid var(--border);
  padding: 16px 18px; display: flex; flex-direction: column; gap: 10px;
}
.parlay-row {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 13px; color: var(--text-dim);
}
.parlay-row strong { color: var(--text); font-size: 14px; }
.parlay-row input {
  width: 100px; background: var(--surface); border: 1px solid var(--border);
  color: var(--text); padding: 6px 10px; border-radius: 8px;
  text-align: right; font-family: inherit;
}

/* ---------- Modals ---------- */
.modal {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(0,0,0,0.65);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  animation: fadeIn 0.15s ease;
}
@keyframes fadeIn { from { opacity: 0; } }
.modal-card {
  background: var(--bg-1); border: 1px solid var(--border);
  border-radius: var(--radius); width: min(420px, 100%);
  overflow: hidden;
  animation: slideUp 0.2s ease;
}
@keyframes slideUp { from { transform: translateY(8px); opacity: 0; } }
.modal-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.modal-head h3 { margin: 0; font-size: 16px; }
.modal-body { padding: 18px 20px; display: flex; flex-direction: column; gap: 12px; }
.muted { color: var(--text-dim); font-size: 13px; }

.bet-side-pick { display: flex; gap: 8px; }
.bet-side {
  flex: 1; padding: 14px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text); font-weight: 700;
  display: flex; flex-direction: column; gap: 2px; font-size: 14px;
}
.bet-side.yes { color: var(--green); }
.bet-side.no  { color: var(--red); }
.bet-side.active { border-color: currentColor; background: rgba(34,197,94,0.08); box-shadow: 0 0 0 1px currentColor; }
.bet-side.no.active { background: rgba(239,68,68,0.08); }
.bet-side span { font-size: 13px; opacity: 0.8; font-weight: 500; }

.lbl {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 13px; color: var(--text-dim);
}
.lbl input {
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text); padding: 10px 12px; border-radius: 8px;
  font-family: inherit; font-size: 14px;
}

.bet-summary {
  display: flex; flex-direction: column; gap: 6px;
  background: var(--surface); border-radius: 10px; padding: 12px;
  font-size: 13px;
}
.bet-summary > div { display: flex; justify-content: space-between; }
.bet-summary span { color: var(--text-dim); }
.bet-summary strong { color: var(--text); }

.wallet-option {
  display: flex; align-items: center; gap: 12px;
  width: 100%; padding: 14px 14px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text); border-radius: 10px;
  font-family: inherit; font-size: 14px; font-weight: 600;
  transition: all 0.15s ease;
}
.wallet-option:hover { background: var(--surface-2); border-color: var(--border-strong); transform: translateX(2px); }
.w-emoji { font-size: 22px; }
.w-detect { margin-left: auto; font-size: 11px; color: var(--text-mute); font-weight: 500; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--bg-2); border: 1px solid var(--border);
  border-left: 3px solid var(--green);
  padding: 12px 18px; border-radius: 10px;
  font-size: 14px; color: var(--text);
  z-index: 200; box-shadow: var(--shadow);
  opacity: 0; transition: all 0.25s ease;
  max-width: 90vw;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.error { border-left-color: var(--red); }
.toast.warn  { border-left-color: var(--yellow); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: rgba(5, 10, 23, 0.6);
  margin-top: 32px;
}
.footer-inner {
  max-width: 1400px; margin: 0 auto;
  padding: 28px 24px;
  display: flex; flex-wrap: wrap; gap: 16px;
  align-items: center; justify-content: space-between;
}
.footer-brand { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.footer-links { display: flex; gap: 16px; flex-wrap: wrap; font-size: 14px; }
.footer-links a { color: var(--text-dim); }
.footer-links a:hover { color: var(--text); }
.footer-legal { width: 100%; color: var(--text-mute); font-size: 12px; padding-top: 10px; border-top: 1px dashed var(--border); }

/* ---------- Parlay dashboard section ---------- */
.parlay-section { padding: 32px 0; }
.parlay-dash-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 14px;
  max-width: 1400px; margin: 0 auto;
  padding: 0 24px;
}
.parlay-dash-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px;
  backdrop-filter: blur(10px);
  display: flex; flex-direction: column; gap: 10px;
}
.parlay-dash-card.highlight {
  border-color: rgba(245, 158, 11, 0.4);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(139, 92, 246, 0.08));
}
.parlay-dash-card h3 { margin: 0 0 4px; font-size: 16px; }

.calc-row {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
}
.calc-row label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 11px; color: var(--text-dim); font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.04em;
}
.calc-row input {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 8px 10px; border-radius: 8px;
  font-family: inherit; font-size: 14px; font-weight: 600;
}
.calc-output {
  background: rgba(74, 125, 240, 0.08);
  border: 1px solid rgba(74, 125, 240, 0.2);
  border-radius: 10px; padding: 12px;
  display: flex; flex-direction: column; gap: 6px;
}
.calc-output > div { display: flex; justify-content: space-between; font-size: 13px; }
.calc-output span { color: var(--text-dim); }
.calc-output strong { color: var(--text); font-size: 14px; }

.parlay-stats {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
}
.parlay-stats > div {
  background: rgba(255,255,255,0.03);
  border-radius: 8px; padding: 10px 12px;
  display: flex; flex-direction: column; gap: 2px;
}
.parlay-stats span { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.04em; }
.parlay-stats strong { font-size: 16px; }

.suggested-parlays {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
  max-width: 1400px; margin: 0 auto;
  padding: 0 24px;
}
.sug-parlay {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px;
  display: flex; flex-direction: column; gap: 10px;
}
.sug-parlay-head {
  display: flex; align-items: center; justify-content: space-between;
}
.sug-parlay-head h4 { margin: 0; font-size: 14px; }
.sug-parlay-mult {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff; padding: 4px 10px; border-radius: 100px;
  font-size: 13px; font-weight: 800;
}
.sug-legs { display: flex; flex-direction: column; gap: 4px; max-height: 160px; overflow-y: auto; }
.sug-leg {
  background: rgba(255,255,255,0.03); padding: 8px 10px;
  border-radius: 6px; font-size: 12.5px;
  display: flex; justify-content: space-between; gap: 8px;
}
.sug-leg span:first-child {
  flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sug-leg .price { color: var(--green); font-weight: 700; flex-shrink: 0; }
.sug-leg .price.no { color: var(--red); }

/* ---------- Docs section ---------- */
.docs-section { padding: 32px 0 64px; }
.docs-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 20px;
  max-width: 1400px; margin: 0 auto;
  padding: 0 24px;
}
.docs-toc {
  display: flex; flex-direction: column; gap: 4px;
  position: sticky; top: 80px; align-self: start;
}
.toc-btn {
  text-align: left;
  background: transparent; border: 1px solid transparent;
  color: var(--text-dim); padding: 10px 14px; border-radius: 8px;
  font-size: 14px; font-weight: 500;
  transition: all 0.15s ease;
}
.toc-btn:hover { color: var(--text); background: var(--surface); }
.toc-btn.active {
  background: linear-gradient(135deg, rgba(74, 125, 240, 0.2), rgba(139, 92, 246, 0.2));
  border-color: rgba(74, 125, 240, 0.3);
  color: var(--text);
}

.docs-content {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 32px;
  min-height: 400px;
  backdrop-filter: blur(10px);
}
.doc-pane { display: none; animation: fadeIn 0.18s ease; }
.doc-pane.active { display: block; }
.doc-pane h3 {
  margin: 0 0 16px; font-size: 22px; font-weight: 800; letter-spacing: -0.02em;
}
.doc-pane h4 {
  margin: 18px 0 8px; font-size: 15px; color: var(--primary);
}
.doc-pane p { color: var(--text-dim); margin: 0 0 12px; line-height: 1.65; }
.doc-pane p strong { color: var(--text); }
.doc-pane ul, .doc-pane ol {
  color: var(--text-dim); padding-left: 22px;
  margin: 0 0 12px;
}
.doc-pane li { margin-bottom: 6px; line-height: 1.6; }
.doc-pane li strong { color: var(--text); }

.docs-table { width: 100%; border-collapse: collapse; margin: 8px 0 12px; }
.docs-table th {
  text-align: left; font-size: 12px; color: var(--text-dim);
  text-transform: uppercase; letter-spacing: 0.05em;
  padding: 8px 10px; border-bottom: 1px solid var(--border);
}
.docs-table td {
  padding: 10px; border-bottom: 1px solid var(--border);
  color: var(--text-dim); font-size: 14px;
}
.docs-table td strong { color: var(--text); }

.doc-pane details {
  background: rgba(255,255,255,0.03); border: 1px solid var(--border);
  border-radius: 8px; padding: 10px 14px; margin-bottom: 8px;
}
.doc-pane details summary {
  cursor: pointer; font-weight: 600; color: var(--text); list-style: none;
  display: flex; justify-content: space-between; align-items: center;
}
.doc-pane details summary::after { content: '+'; color: var(--text-dim); font-size: 18px; }
.doc-pane details[open] summary::after { content: '–'; }
.doc-pane details p { margin: 8px 0 0; }

/* ---------- Agent simulator modal ---------- */
.modal-card.agent-card-lg { width: min(680px, 100%); max-height: 90vh; display: flex; flex-direction: column; }
.modal-card.agent-card-lg .modal-body { overflow-y: auto; }
.agent-body { padding: 18px 22px 22px; gap: 16px; }
.agent-stats-bar {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
}
.agent-stats-bar > div {
  background: rgba(255,255,255,0.03); border-radius: 8px;
  padding: 10px; display: flex; flex-direction: column; gap: 2px;
}
.agent-stats-bar span { font-size: 10.5px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; }
.agent-stats-bar strong { font-size: 15px; }

.agent-section {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: 10px; padding: 12px 14px;
}
.agent-section-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 8px;
}
.agent-section h4 { margin: 0 0 8px; font-size: 13px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em; }
.ag-pulse { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; color: var(--green); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; }
.ag-pulse .dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulseDot 1.2s infinite;
}
.ag-pulse.paused { color: var(--yellow); }
.ag-pulse.paused .dot { background: var(--yellow); box-shadow: 0 0 8px var(--yellow); animation: none; }

.ag-log {
  font-family: 'JetBrains Mono', ui-monospace, Menlo, monospace;
  font-size: 12px;
  background: rgba(0,0,0,0.35);
  border-radius: 8px; padding: 10px 12px;
  height: 160px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 4px;
  border: 1px solid rgba(74,125,240,0.15);
}
.ag-log .line {
  display: flex; gap: 8px;
  animation: logSlide 0.18s ease;
}
@keyframes logSlide { from { opacity: 0; transform: translateY(4px); } }
.ag-log .ts { color: var(--text-mute); flex-shrink: 0; }
.ag-log .lvl-info  { color: var(--text-dim); }
.ag-log .lvl-scan  { color: var(--primary); }
.ag-log .lvl-pick  { color: var(--accent-2); }
.ag-log .lvl-trade { color: var(--green); }
.ag-log .lvl-warn  { color: var(--yellow); }

.ag-picks { display: flex; flex-direction: column; gap: 8px; max-height: 220px; overflow-y: auto; }
.ag-empty { color: var(--text-mute); font-size: 13px; text-align: center; padding: 20px; }
.ag-pick {
  background: rgba(74, 125, 240, 0.06);
  border: 1px solid rgba(74, 125, 240, 0.2);
  border-radius: 8px; padding: 10px 12px;
  display: flex; flex-direction: column; gap: 6px;
  animation: logSlide 0.22s ease;
}
.ag-pick-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.ag-pick-title {
  font-size: 13px; font-weight: 600; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.ag-pick-side {
  font-size: 10px; padding: 2px 8px; border-radius: 100px;
  font-weight: 800; letter-spacing: 0.05em; flex-shrink: 0;
}
.ag-pick-side.yes { background: var(--green-soft); color: var(--green); }
.ag-pick-side.no  { background: var(--red-soft); color: var(--red); }
.ag-pick-reason { font-size: 12px; color: var(--text-dim); line-height: 1.5; }
.ag-pick-meta {
  display: flex; gap: 12px; font-size: 11px; color: var(--text-mute);
  border-top: 1px dashed var(--border); padding-top: 6px;
}
.ag-pick-meta .score {
  color: var(--accent-2); font-weight: 700;
}
.ag-pick-meta .delta-up { color: var(--green); font-weight: 700; }
.ag-pick-meta .delta-down { color: var(--red); font-weight: 700; }

.agent-actions {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.agent-actions .btn { flex: 1; min-width: 120px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .primary-nav { display: none; }
  .mobile-only { display: inline-flex; }
  .header-actions .btn-coin span,
  .header-actions .wallet-label { display: none; }
  .header-actions .btn-coin,
  .header-actions #connect-wallet { padding: 9px 10px; }
  .header-actions #demo-toggle span { display: none; }
  .header-inner { padding: 10px 16px; gap: 8px; }
  .hero { padding: 32px 16px 16px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
  .market-grid { padding: 0 16px; }
  .features-grid, .agents-grid { padding: 0 16px; }
  .section-head, .sort-bar { padding-left: 16px; padding-right: 16px; }
  .category-bar { padding-left: 16px; padding-right: 16px; }
  .leaderboard { margin-left: 16px; margin-right: 16px; }
  .lb-row { grid-template-columns: 30px 1.4fr 1fr 1fr 60px; padding: 10px 14px; font-size: 13px; }
  .footer-inner { padding: 24px 16px; flex-direction: column; align-items: flex-start; }
  .featured-rail { padding-left: 16px; padding-right: 16px; }
  .feat-card { flex-basis: 280px; }
  .search-wrap { min-width: 0; flex: 1; }
  .parlay-dash-grid { grid-template-columns: 1fr; padding: 0 16px; }
  .docs-grid { grid-template-columns: 1fr; padding: 0 16px; }
  .docs-toc {
    position: static; flex-direction: row;
    overflow-x: auto; gap: 6px; padding-bottom: 8px;
  }
  .docs-toc::-webkit-scrollbar { display: none; }
  .toc-btn { white-space: nowrap; flex-shrink: 0; padding: 8px 12px; font-size: 13px; }
  .docs-content { padding: 20px 18px; }
  .suggested-parlays { padding: 0 16px; }
  .agent-stats-bar { grid-template-columns: 1fr 1fr; }
  .calc-row { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 600px) {
  .hero-title { font-size: 38px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat { padding: 12px 10px; }
  .market-grid { grid-template-columns: 1fr; }
  .parlay-fab { padding: 12px 14px; bottom: 16px; right: 16px; }
  .fab-label { display: none; }
}

@media (max-width: 480px) {
  .brand-name { display: none; }
  .header-actions { gap: 6px; }
  .btn-icon { padding: 8px; }
}

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