/* ---------------------------------------------------------------------------
   Oddsy: landing page
   The oddsy.trade design system v4, "instrument panel", without Tailwind:
   graphite cards on near-black, 28px radii, a darker header strip split from
   the body by a hairline. One signal red, spent on the primary action, live
   state and Yes; green only where something is a bet on direction. Geist for
   words, Geist Mono for figures. 1920px wide with the app's 16 / 24 / 40px
   gutters. Tokens are shared verbatim with app/globals.css and the docs.
--------------------------------------------------------------------------- */


:root {
  /* surfaces, darkest to lightest */
  --bg: #0b0b0b;
  --surface: #141414;
  --surface-2: #1c1c1c;
  --surface-3: #262626;
  --border: #232323;
  --border-strong: #343434;

  /* text */
  --text: #f4f4f4;
  --text-2: #a6a6a6;
  --text-3: #6e6e6e;

  /* signal red in three strengths */
  --brand: #fb1424;
  --brand-2: #d40d1c;
  --brand-dim: #7c1219;
  --brand-tint: #2a0f11;
  --brand-soft: #ff5a64;
  --brand-ink: #ffffff;

  --light: #e6e6e6;
  --up-soft: #4ade80;

  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 28px;

  --shadow-card: 0 1px 0 0 rgb(255 255 255 / 0.035) inset, 0 30px 60px -30px rgb(0 0 0 / 0.75);
  --ease: cubic-bezier(0.23, 1, 0.32, 1);

  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --gutter: 16px;
  --topbar-h: 68px;
  color-scheme: dark;
}

@media (min-width: 768px) {
  :root { --gutter: 24px; }
}
@media (min-width: 1280px) {
  :root { --gutter: 40px; }
}

/* --------------------------------------------------------------- base ---- */

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--topbar-h) + 20px);
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: -0.015em;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Graphite falloff from the top of the page, with a faint red ember at the
   centre, the only colour in the chrome. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(50% 38% at 50% -4%, rgb(251 20 36 / 0.11), transparent 72%),
    radial-gradient(120% 70% at 50% 0%, #161616, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.08;
  text-wrap: balance;
}

p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
strong { font-weight: 500; color: var(--text); }
em { font-style: italic; color: var(--text); }
svg { flex-shrink: 0; }

code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  letter-spacing: -0.02em;
  color: var(--text);
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--surface-3);
}

.num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

::selection { background: var(--brand); color: var(--brand-ink); }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 8px;
}

::-webkit-scrollbar { width: 10px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 999px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--border-strong); }

.wrap {
  width: 100%;
  max-width: 1920px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 60;
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* --------------------------------------------------------- primitives ---- */

.label {
  font-size: 12px;
  font-weight: 450;
  letter-spacing: -0.005em;
  color: var(--text-3);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--brand);
  flex-shrink: 0;
}

.card {
  position: relative;
  isolation: isolate;
  background: linear-gradient(180deg, #171717 0%, #131313 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  background: rgb(0 0 0 / 0.22);
  border-bottom: 1px solid var(--border);
  border-top-left-radius: inherit;
  border-top-right-radius: inherit;
}

.card-foot {
  padding: 12px;
  border-top: 1px solid var(--border);
  background: rgb(0 0 0 / 0.2);
  border-bottom-left-radius: inherit;
  border-bottom-right-radius: inherit;
}

.head-copy { min-width: 0; }
.head-title { font-size: 15.5px; font-weight: 500; letter-spacing: -0.025em; line-height: 1.2; }
.head-sub { font-size: 13px; color: var(--text-3); margin-top: 2px; }

.icon-well {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  color: var(--text-2);
}
.icon-well svg { width: 18px; height: 18px; }

.tag {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  background: var(--surface-3);
  color: var(--text-2);
  white-space: nowrap;
}

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.015em;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 180ms ease, color 180ms ease, border-color 180ms ease, opacity 180ms ease,
    transform 160ms var(--ease);
}
.btn:active { transform: scale(0.97); }
.btn svg { width: 16px; height: 16px; }

.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { background: var(--brand-2); }
.btn-light { background: var(--light); color: #0b0b0b; }
.btn-light:hover { background: #ffffff; }
.btn-ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--border-strong); }
.btn-ghost:hover { background: var(--surface-3); }
.btn-quiet { background: transparent; color: var(--text-2); }
.btn-quiet:hover { background: var(--surface-2); color: var(--text); }
.btn-icon { width: 40px; padding: 0; }
.btn-block { width: 100%; }
.btn[aria-disabled="true"] { opacity: 0.35; pointer-events: none; }

/* ------------------------------------------------------------- top bar ---- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid transparent;
  transition: background-color 300ms ease, border-color 300ms ease, backdrop-filter 300ms ease;
}
.topbar.is-scrolled {
  background: rgb(11 11 11 / 0.75);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-color: var(--border);
}

.topbar-inner {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  margin-right: 16px;
}
.logo-mark {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  overflow: hidden;
  transition: transform 500ms var(--ease);
}
.logo-mark img { width: 100%; height: 100%; object-fit: cover; }
.logo:hover .logo-mark { transform: rotate(-8deg) scale(1.05); }
.logo-word { font-size: 18px; font-weight: 500; letter-spacing: -0.04em; }

/* Page switcher: the app's primary nav pill, with a glide that follows the
   pointer and rests on the current page. */
.pill-nav {
  position: relative;
  display: none;
  align-items: center;
  padding: 4px;
  border-radius: 999px;
  background: rgb(20 20 20 / 0.7);
  border: 1px solid var(--border);
}
.pill-nav a {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 16px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-3);
  transition: color 200ms ease;
}
.pill-nav a:hover, .pill-nav a[aria-current="page"] { color: var(--text); }
.pill-nav-glide {
  position: absolute;
  top: 4px;
  left: 0;
  height: 32px;
  width: 0;
  border-radius: 999px;
  background: var(--surface-2);
  opacity: 0;
  transition: transform 420ms var(--ease), width 420ms var(--ease), background-color 200ms ease, opacity 200ms ease;
  pointer-events: none;
}
.pill-nav-glide.is-current { background: var(--surface-3); box-shadow: 0 0 0 1px var(--border-strong); }
.pill-nav a.is-active { color: var(--text); }

.topbar-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
}
.btn-docs { display: none; }
.btn-launch { height: 40px; padding: 0 14px 0 18px; }

@media (min-width: 640px) {
  .btn-docs { display: inline-flex; }
}
@media (min-width: 1024px) {
  .pill-nav { display: flex; }
}

/* -------------------------------------------------------------- footer ---- */

.site-footer { margin-top: 64px; padding-bottom: 24px; }
.footer-grid {
  display: grid;
  gap: 40px;
  padding: 24px;
}
.footer-brand p {
  margin-top: 16px;
  max-width: 320px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text-3);
}
.footer-grid nav .label { margin-bottom: 12px; }
.footer-grid nav li + li { margin-top: 8px; }
.footer-grid nav a { font-size: 14px; color: var(--text-2); transition: color 200ms ease; }
.footer-grid nav a:hover { color: var(--text); }
.footer-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 16px;
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  background: rgb(0 0 0 / 0.2);
  border-bottom-left-radius: inherit;
  border-bottom-right-radius: inherit;
  font-size: 12px;
  color: var(--text-3);
}
.footer-bar-end { margin-left: auto; }
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.4fr repeat(3, 1fr); padding: 32px; }
  .footer-bar { padding: 16px 32px; }
}


/* ------------------------------------------------------ extra primitives ---- */

:root {
  --up: #2fd27e;
  --up-2: #25bd6f;
  --up-ink: #06140d;
  --up-tint: #0d2218;
}

.btn-lg { height: 52px; padding: 0 26px; font-size: 15px; }
.btn-lg svg { width: 18px; height: 18px; }
.btn-up { background: var(--up); color: var(--up-ink); }
.btn-up:hover { background: var(--up-2); }
.btn-down { background: var(--brand); color: var(--brand-ink); }
.btn-down:hover { background: var(--brand-2); }
.btn-primary { box-shadow: 0 10px 30px -10px rgb(251 20 36 / 0.55); }

.tag-brand { background: var(--brand-tint); color: var(--brand-soft); }
.tag-up { background: var(--up-tint); color: var(--up-soft); }

.live-dot {
  position: relative;
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--brand);
  flex-shrink: 0;
}
.live-dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: inherit;
  animation: ping 1.6s cubic-bezier(0, 0, 0.2, 1) infinite;
}

.fade {
  background-image: linear-gradient(180deg, #ffffff 30%, #7a7a7a);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.coin {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  height: 38px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface-3);
  border: 1px solid var(--border-strong);
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text);
}
.coin-brand { background: var(--brand-tint); border-color: var(--brand-dim); color: var(--brand-soft); }

/* ---------------------------------------------------------------- hero ---- */

/* Sized and laid out as the app's own home hero: a 1360px stage inside the
   1920px page, copy on the left, one featured-market card on the right. */
.hero { padding-top: 40px; padding-bottom: 56px; }
.hero-inner {
  max-width: 1360px;
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
  align-items: center;
}
.hero-copy { min-width: 0; }
.hero-title {
  font-size: 46px;
  letter-spacing: -0.055em;
  line-height: 0.98;
}
.hero-title .line { display: block; }
.hero-title .word { display: inline-block; }
.hero-title .keep { white-space: nowrap; }
.hero-title .accent { color: var(--brand); }
.hero-title .muted { color: var(--text-3); }
.hero-sub {
  margin-top: 24px;
  max-width: 480px;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-2);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: 480px;
  margin: 48px 0 0;
  border-block: 1px solid var(--border);
}
.hero-stats > div { padding: 14px 16px; }
.hero-stats > div:first-child { padding-left: 0; }
.hero-stats > div + div { border-left: 1px solid var(--border); }
.hero-stats dd { margin: 4px 0 0; font-size: 14px; color: var(--text); }

.hero-stage { min-width: 0; }
.stage-market { overflow: hidden; }
.stage-progress { display: flex; gap: 6px; padding: 16px 20px 4px; }
.stage-progress span { flex: 1; height: 3px; border-radius: 999px; background: rgb(255 255 255 / 0.1); overflow: hidden; }
.stage-progress span.on { position: relative; }
.stage-progress span.on::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--brand);
  transform-origin: left;
  animation: progress 7s linear infinite;
}
.stage-market-head { display: flex; gap: 14px; padding: 12px 20px 0; align-items: flex-start; }
.stage-thumb {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--surface-3);
  box-shadow: inset 0 0 0 1px var(--border-strong);
  color: var(--text-2);
  flex-shrink: 0;
}
.stage-thumb svg { width: 20px; height: 20px; }
.stage-market-head .eyebrow { margin: 0; }
.stage-market-head .sep { color: var(--border-strong); }
.stage-q { margin-top: 4px; font-size: 16px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.3; }
.stage-market-figures {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 20px 0;
}
.stage-market-figures .label { margin-bottom: 6px; }
.stage-pct { font-size: 60px; line-height: 1; }
.stage-pct .unit { font-size: 0.5em; color: var(--text-3); margin-left: 2px; letter-spacing: -0.02em; }
.stage-move { text-align: right; padding-bottom: 4px; }
.stage-move .tag { height: 28px; font-size: 12px; }
.stage-move .label { margin-top: 8px; }
.glow-chart { display: block; width: 100%; height: 150px; margin-top: 12px; }
.glow-fill { animation: fade-in 1.2s var(--ease) both; }
.reveal-rect { animation: draw 1.4s var(--ease) both; }
.stage-market-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 16px; }
.stage-market-actions .btn { height: 44px; font-size: 13.5px; cursor: default; }
.stage-market-actions .num { opacity: 0.7; }

@media (min-width: 640px) {
  .hero-title { font-size: 60px; }
}
@media (min-width: 768px) {
  .hero { padding-top: 64px; padding-bottom: 80px; }
}
@media (min-width: 1024px) {
  .hero { padding-block: 32px; }
  .hero-inner {
    grid-template-columns: minmax(0, 1fr) minmax(0, 460px);
    gap: 48px;
    min-height: calc(100svh - var(--topbar-h) - 67px);
  }
  /* Two lines beside the card: the first line is about 9.5em long, so the
     headline scales down with its column rather than breaking a third time. */
  .hero-copy { container-type: inline-size; }
  .hero-title { font-size: clamp(48px, 10.3cqi, 60px); }
}
@media (min-width: 1280px) {
  .hero-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 540px); gap: 80px; }
  .hero-title { font-size: clamp(48px, 10.3cqi, 64px); }
}

.figure {
  font-family: var(--font-sans);
  font-variant-numeric: tabular-nums;
  font-weight: 400;
  letter-spacing: -0.05em;
  line-height: 1;
  color: var(--text);
}
.num-light { color: var(--text-3); font-weight: 300; }

/* ------------------------------------------------------------ sections ---- */

.section {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  padding-top: 88px;
  scroll-margin-top: calc(var(--topbar-h) - 40px);
}
.section-head { min-width: 0; }
.section-head .eyebrow { margin-bottom: 16px; }
.section-head h2 {
  font-size: 30px;
  letter-spacing: -0.045em;
  line-height: 1.08;
  max-width: 20ch;
}
.section-head p {
  margin-top: 14px;
  max-width: 52ch;
  font-size: 15px;
  line-height: 1.65;
  color: var(--text-2);
}

@media (min-width: 1280px) {
  .section-head h2 { font-size: 36px; }
  .section:not(.section-wide) {
    grid-template-columns: minmax(340px, 0.7fr) minmax(0, 1.6fr);
    gap: 56px;
    align-items: start;
  }
  .section:not(.section-wide) .section-head {
    position: sticky;
    top: calc(var(--topbar-h) + 32px);
  }
}
@media (min-width: 1536px) {
  .section:not(.section-wide) { gap: 72px; }
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 28px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border-strong);
  padding-bottom: 4px;
  transition: border-color 200ms ease;
}
.text-link svg { width: 15px; height: 15px; transition: transform 300ms var(--ease); }
.text-link:hover { border-color: var(--brand); }
.text-link:hover svg { transform: translateX(3px); color: var(--brand); }

/* ------------------------------------------------- 01 question board ---- */

/* board.js: a list of questions, and the book behind the one in focus. */
.board { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; min-width: 0; }
.board-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--border-strong); }
.board-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px 24px;
  width: 100%;
  padding: 20px 0 18px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.board-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}
.board-row[data-kind="native"] .board-src { color: var(--brand-soft); }
.board-q {
  grid-column: 1;
  font-size: 17px;
  letter-spacing: -0.025em;
  line-height: 1.35;
  color: var(--text-2);
  transition: color 300ms ease;
}
.board-odds {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
  font-size: 32px;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.05em;
  line-height: 1;
  color: var(--text-3);
  transition: color 300ms ease;
}
.board-odds .unit { margin-left: 2px; font-size: 0.5em; letter-spacing: 0; color: var(--text-3); }
.board-bar {
  grid-column: 1 / -1;
  height: 2px;
  margin-top: 10px;
  border-radius: 2px;
  background: var(--surface-3);
  overflow: hidden;
}
.board-bar i {
  display: block;
  height: 100%;
  border-radius: 2px;
  background: #4a4a4a;
  transition: width 900ms var(--ease), background-color 300ms ease;
}
.board-row:hover .board-q { color: var(--text); }
.board-row[aria-pressed="true"] .board-q,
.board-row[aria-pressed="true"] .board-odds { color: var(--text); }
.board-row[aria-pressed="true"] .board-bar i { background: var(--brand); }
.board-row:focus-visible { outline: 2px solid var(--brand); outline-offset: 4px; border-radius: 4px; }
.board-foot { grid-column: 1 / -1; }

/* The book, or the pools, of the question in focus. */
.board-book { border-top: 1px solid var(--border-strong); padding-top: 18px; min-width: 0; }
.board-book:empty { display: none; }
.book-in { animation: book-in 500ms var(--ease) both; }
@keyframes book-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.book-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.book-src {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}
.book-src-brand { color: var(--brand-soft); }
.book-cols { display: flex; justify-content: space-between; margin: 18px 0 6px; padding: 0 10px; }
.lv {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 28px;
  padding: 0 10px;
  font-size: 12.5px;
  border-radius: 8px;
}
.lv-bar {
  position: absolute;
  top: 3px;
  bottom: 3px;
  right: 0;
  border-radius: 6px;
  transition: width 900ms var(--ease);
}
.lv-p, .lv-s { position: relative; }
.lv-ask .lv-bar { background: rgb(255 255 255 / 0.05); }
.lv-ask .lv-p { color: var(--text-2); }
.lv-bid .lv-bar { background: rgb(251 20 36 / 0.14); }
.lv-bid .lv-p { color: var(--brand-soft); }
.lv-s { color: var(--text-2); }
.lv.hit { animation: lv-hit 900ms ease-out; }
@keyframes lv-hit { from { background: rgb(255 255 255 / 0.1); } to { background: transparent; } }
.book-mid {
  display: flex;
  justify-content: space-between;
  margin: 8px 0;
  padding: 11px 10px;
  border-block: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-3);
}
.book-mid b { margin-left: 6px; font-weight: 400; color: var(--text); }

.pools { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 22px; }
.pool-num { margin-top: 6px; font-size: 26px; letter-spacing: -0.04em; line-height: 1; color: var(--text); }
.pool-num .num { letter-spacing: -0.04em; }
.pool-num .unit { font-size: 12px; letter-spacing: 0; color: var(--text-3); }
.pools > div + div { text-align: right; }
.pool-split { display: flex; gap: 3px; height: 6px; margin-top: 16px; }
.pool-split i { display: block; border-radius: 3px; transition: flex-grow 900ms var(--ease); }
.pool-yes { background: var(--brand); }
.pool-no { background: #3a3a3a; }
.pool-meta { margin-top: 12px; }
.bets { list-style: none; margin: 0; padding: 0; }
.bet {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 36px;
  gap: 12px;
  align-items: center;
  height: 34px;
  padding: 0 10px;
  border-bottom: 1px solid var(--border);
  font-size: 12.5px;
}
.bet-who { color: var(--text-3); }
.bet-amt { color: var(--text-2); }
.bet-side { text-align: right; font-size: 12px; }
.bet-yes { color: var(--brand-soft); }
.bet-no { color: var(--text-3); }
.bet-new { animation: bet-new 600ms var(--ease) both; }
@keyframes bet-new { from { opacity: 0; transform: translateY(-6px); background: rgb(255 255 255 / 0.06); } to { opacity: 1; transform: none; background: transparent; } }

@media (min-width: 1024px) {
  .board { grid-template-columns: minmax(0, 1fr) 320px; gap: 24px 48px; align-items: start; }
}

/* -------------------------------------------------------- 02 perps list ---- */

/* perps.js: a few of the listed perps, the way the app's table sets them. */
.perps { min-width: 0; }
.perps-head,
.perps-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 84px 52px;
  gap: 16px;
  align-items: center;
}
.perps-head { padding: 0 0 12px; border-bottom: 1px solid var(--border-strong); }
.perps-head span:nth-child(n + 2) { text-align: right; }
.perps-spark-h, .perps-spark, .perps-fund { display: none; }
.perps-head span:nth-child(3) { display: none; }
.perps-list { list-style: none; margin: 0; padding: 0; }
.perps-row {
  height: 64px;
  border-bottom: 1px solid var(--border);
  transition: background-color 200ms ease;
}
.perps-row .perps-px { display: none; }
.perps-mkt { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.perps-mkt b { font-size: 17px; font-weight: 500; letter-spacing: -0.03em; color: var(--text); }
.perps-mkt small { font-size: 13px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.perps-hot .perps-mkt b { color: var(--brand); }
.perps-spark { width: 100%; height: 28px; overflow: visible; }
.perps-spark path { fill: none; stroke: var(--up-soft); stroke-width: 1.5; vector-effect: non-scaling-stroke; opacity: 0.85; }
.perps-row-down .perps-spark path { stroke: var(--brand-soft); }
.perps-px, .perps-chg, .perps-fund, .perps-lev { text-align: right; font-size: 14px; }
.perps-px { color: var(--text); border-radius: 6px; padding: 2px 4px; margin-right: -4px; }
.perps-chg.up { color: var(--up-soft); }
.perps-chg.down { color: var(--brand-soft); }
.perps-fund { color: var(--text-3); }
.perps-lev { color: var(--text-2); }
.tick-up { animation: tick-up 900ms ease-out; }
.tick-down { animation: tick-down 900ms ease-out; }
@keyframes tick-up { from { background: rgb(74 222 128 / 0.16); } to { background: transparent; } }
@keyframes tick-down { from { background: rgb(251 20 36 / 0.18); } to { background: transparent; } }
.perps-foot { margin-top: 18px; }
.perps-foot .num { color: var(--text-2); margin-right: 4px; }

@media (min-width: 768px) {
  .perps-head,
  .perps-row { grid-template-columns: minmax(150px, 1fr) minmax(80px, 160px) 120px 84px 104px 52px; gap: 24px; }
  .perps-spark-h, .perps-head span:nth-child(3), .perps-fund { display: block; }
  .perps-spark { display: block; }
  .perps-row .perps-px { display: block; }
}

/* ------------------------------------------------------------- 03 loop ---- */

.loop { position: relative; padding-top: 72px; }
/* The arc from the last stop back to the first: the money comes home. */
.loop-arc {
  position: absolute;
  top: 18px;
  left: 12px;
  right: calc(25% - 12px);
  height: 54px;
  border: 1px dashed rgb(251 20 36 / 0.5);
  border-bottom: 0;
  border-radius: 28px 28px 0 0;
  display: none;
}
.loop-arc span {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  padding: 0 12px;
  background: var(--bg);
  font-size: 11.5px;
  color: var(--brand-soft);
  white-space: nowrap;
}
.loop-stops { position: relative; display: grid; grid-template-columns: 1fr; gap: 32px; }
.loop-stops li { position: relative; padding-left: 48px; font-size: 14.5px; line-height: 1.6; color: var(--text-2); }
.loop-stops li::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 30px;
  bottom: -32px;
  width: 1px;
  background: var(--border-strong);
}
.loop-stops li:last-child::before { display: none; }
.stop {
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--bg);
  font-size: 10.5px;
  color: var(--text-2);
}
.stop-home { border-color: var(--brand); color: var(--brand-soft); box-shadow: 0 0 0 5px rgb(251 20 36 / 0.12); }
.loop-stops h3 { font-size: 18px; letter-spacing: -0.035em; color: var(--text); margin-bottom: 8px; }
.loop-note { margin-top: 40px; font-size: 12.5px; color: var(--text-3); font-family: var(--font-mono); letter-spacing: -0.02em; }

@media (min-width: 1024px) {
  .loop { padding-top: 96px; }
  /* Four even columns, each stop centred over its own column; the line runs
     centre to centre and the arc spans first to last, so the row is symmetric. */
  .loop-arc {
    display: block;
    top: 24px;
    height: 72px;
    left: calc((100% - 120px) / 8);
    right: calc((100% - 120px) / 8);
  }
  .loop-stops { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px; }
  .loop-stops li { padding: 48px 12px 0; text-align: center; }
  .loop-stops li::before { left: calc(50% + 12.5px); right: calc(-50% - 40px + 12.5px); top: 12px; bottom: auto; width: auto; height: 1px; }
  .stop { left: 50%; transform: translateX(-50%); }
  .loop-stops p { max-width: 30ch; margin-inline: auto; }
  .loop-note { text-align: center; }
  .section-wide .section-head { text-align: center; }
  .section-wide .section-head .eyebrow { justify-content: center; }
  .section-wide .section-head h2,
  .section-wide .section-head p { margin-inline: auto; }
}

/* ------------------------------------------------------------- 04 fees ---- */

.fee-figures { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.fee-fig {
  margin-top: 10px;
  font-family: var(--font-sans);
  font-size: clamp(48px, 5.4vw, 88px);
  font-weight: 400;
  letter-spacing: -0.06em;
  line-height: 1;
  color: var(--text-2);
}
.fee-fig span { font-size: 0.45em; color: var(--text-3); margin-left: 4px; letter-spacing: -0.02em; }
.fee-fig-hot { color: var(--text); }
.fee-sub { margin-top: 10px; font-size: 13.5px; color: var(--text-3); }
/* Maker sits on the left edge and taker on the right, as their pins do on the ruler. */
.fee-figures > div + div { text-align: right; }

.ruler { position: relative; margin-top: 48px; padding-top: 30px; }
.ruler-track { height: 4px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.ruler-fill { display: block; width: 90%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--text-3) 0 30%, var(--brand) 100%); }
.pin { position: absolute; top: 0; left: var(--x); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; }
.pin b { font-weight: 400; font-size: 11px; color: var(--text-2); }
.pin::after { content: ""; width: 1px; height: 18px; margin-top: 4px; background: var(--text-3); }
.pin-taker b { color: var(--brand-soft); }
.pin-taker::after { background: var(--brand); }
.ruler-ticks { display: flex; justify-content: space-between; margin-top: 10px; font-size: 11px; color: var(--text-3); }
.fee-foot { margin-top: 36px; padding-top: 18px; border-top: 1px solid var(--border); font-size: 13.5px; line-height: 1.6; color: var(--text-3); }
.fee-foot .num { color: var(--text-2); margin-right: 10px; }

/* ----------------------------------------------------------------- CTA ---- */

.cta {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 64px 0;
}
.cta-glow {
  position: absolute;
  inset: 0 10%;
  background: radial-gradient(45% 55% at 50% 55%, rgb(251 20 36 / 0.16), transparent 70%);
  z-index: -1;
  pointer-events: none;
}
.cta h2 {
  margin-top: 22px;
  font-size: clamp(36px, 4vw, 64px);
  letter-spacing: -0.055em;
  line-height: 1;
  max-width: 16ch;
}
.cta p { margin-top: 18px; max-width: 46ch; font-size: 16px; line-height: 1.65; color: var(--text-2); }
.cta .hero-cta { justify-content: center; }

/* footer tweak: the site footer sits a touch further down on a long page */
.site-footer { margin-top: 24px; }
.footer-bar-end { max-width: 72ch; text-align: right; }
@media (max-width: 767.98px) {
  .footer-bar-end { text-align: left; margin-left: 0; }
}

/* -------------------------------------------------------------- motion ---- */

@keyframes ping { 75%, 100% { transform: scale(2.2); opacity: 0; } }
@keyframes ticker { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }
@keyframes progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes draw { from { width: 0; } to { width: 600px; } }
@keyframes blur-in {
  from { opacity: 0; transform: translateY(18px); filter: blur(10px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

.hero-title .word { animation: blur-in 800ms var(--ease) both; }
.hero-title .word + .word { animation-delay: 60ms; }
.hero-title .keep .word { animation-delay: 120ms; }
.hero-title .keep .word + .word { animation-delay: 180ms; }
.hero-title .line:nth-child(2) .word { animation-delay: 280ms; }
.hero-title .line:nth-child(2) .word + .word { animation-delay: 340ms; }
.hero-title .line:nth-child(2) .word + .word + .word { animation-delay: 400ms; }
.hero .reveal { animation: blur-in 800ms var(--ease) both; animation-delay: 480ms; }
.hero .hero-cta.reveal { animation-delay: 560ms; }
.hero .hero-stats.reveal { animation-delay: 680ms; }
.stage-market { animation: blur-in 900ms var(--ease) both; animation-delay: 250ms; }

/* Sections rise in as they reach the viewport (the script adds .is-in). */
.js .rise { opacity: 0; transform: translateY(24px); filter: blur(8px); transition: opacity 800ms var(--ease), transform 800ms var(--ease), filter 800ms var(--ease); }
.js .rise.is-in { opacity: 1; transform: none; filter: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .band-track { animation: none; }
  .js .rise { opacity: 1; transform: none; filter: none; }
}

/* One content column for the whole page: the app's 1360px hero stage. The bar,
   the ticker band and the footer still run to the 1920px page width. */
.hero.wrap,
.section.wrap,
.cta-wrap.wrap { max-width: calc(1360px + 2 * var(--gutter)); }
.hero-inner { max-width: none; }

/* Breathing room: one section to a screen. Each starts well clear of the last,
   with a hairline above its head so the change of subject reads. */
.section { padding-top: 120px; }
.cta-wrap { padding-top: 120px; }
.section-head .eyebrow { margin-bottom: 20px; }
.section-head p { margin-top: 20px; }
@media (min-width: 768px) {
  .section, .cta-wrap { padding-top: 160px; }
}
/* From laptop width up, each section owns a full screen under the bar and sits
   centred in it, so two subjects never share the view. */
@media (min-width: 1024px) {
  .section {
    min-height: calc(100svh - var(--topbar-h));
    padding-block: 96px;
    align-content: center;
    scroll-margin-top: var(--topbar-h);
  }
  .cta-wrap {
    min-height: calc(100svh - var(--topbar-h));
    display: grid;
    align-content: center;
    padding-block: 96px;
  }
}

/* ------------------------------------------------------- hero backdrop ---- */

/* The field of odds (field.js), full bleed behind the hero and fading out at
   the top and bottom so the copy and the next section sit on plain dark. */
.hero { position: relative; isolation: isolate; }
.hero-field {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  z-index: -1;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 34%, #000 78%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 34%, #000 78%, transparent 100%);
}
.hero-field canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ------------------------------------------------------ featured market ---- */

/* featured.js: the app's highlighted-markets card, with example markets. */
.fm-progress { padding: 16px 20px 4px; gap: 6px; }
.fm-progress button {
  flex: 1;
  padding: 6px 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.fm-progress button span {
  display: block;
  height: 3px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.1);
  overflow: hidden;
  transition: background-color 200ms ease;
}
.fm-progress button:hover span { background: rgb(255 255 255 / 0.2); }
.fm-progress i { display: block; height: 100%; width: 100%; transform: scaleX(0); transform-origin: left; }
.fm-progress .is-done i { transform: none; background: var(--text-2); }
.fm-progress .is-on i {
  background: var(--brand);
  animation: progress var(--rotate, 7000ms) linear forwards;
}
.is-paused .fm-progress .is-on i { animation-play-state: paused; }
.stage-progress span.on::after { display: none; }

.fm-slot { position: relative; }
.fm-body { animation: fm-in 400ms var(--ease) both; }
.fm-body.is-leaving { animation: fm-out 200ms var(--ease) both; }
.fm-body.is-leaving-back { animation: fm-out-back 200ms var(--ease) both; }
.fm-body.is-entering-back { animation: fm-in-back 400ms var(--ease) both; }
@keyframes fm-in { from { opacity: 0; transform: translateX(12px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes fm-in-back { from { opacity: 0; transform: translateX(-12px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes fm-out { to { opacity: 0; transform: translateX(-12px); filter: blur(6px); } }
@keyframes fm-out-back { to { opacity: 0; transform: translateX(12px); filter: blur(6px); } }

.fm-mark { font-size: 11px; font-weight: 500; color: var(--text); letter-spacing: 0; }
.fm-title { min-width: 0; flex: 1; }
.fm-title .stage-q {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.6em;
  transition: color 200ms ease;
}
.fm-title .stage-q:hover { color: #fff; }
.fm-nav { display: flex; gap: 4px; flex-shrink: 0; }
.fm-step {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: none;
  color: var(--text-3);
  cursor: pointer;
  transition: color 200ms ease, border-color 200ms ease;
}
.fm-step svg { width: 14px; height: 14px; }
.fm-step:hover { color: var(--text); border-color: var(--border-strong); }

.stage-move .tag:not(.tag-brand) { background: var(--surface-3); color: var(--text-2); }

.fm-chart { position: relative; margin-top: 12px; padding: 0 4px; }
.fm-chart svg { display: block; width: 100%; height: 150px; touch-action: none; }
.fm-glow { animation: fade-in 1.2s var(--ease) both; }
.fm-reveal { animation: draw 1.4s var(--ease) both; }
.fm-cursor { opacity: 0; transition: opacity 150ms ease; }
.fm-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 0 4px rgb(251 20 36 / 0.35);
  pointer-events: none;
  transition: left 150ms ease-out, top 150ms ease-out;
}
.fm-readout {
  position: absolute;
  right: 10px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-size: 11px;
  line-height: 1.35;
  color: var(--text);
  pointer-events: none;
  white-space: nowrap;
  transition: left 150ms ease-out, top 150ms ease-out;
}
.fm-readout b { font-weight: 400; color: var(--text-3); }
.fm-readout.is-free { right: auto; transform: translateX(-50%); align-items: center; }
.fm-ticks { position: relative; height: 26px; margin: 4px 16px 0; font-size: 10.5px; color: var(--text-3); }
.fm-ticks span { position: absolute; top: 6px; transform: translateX(-50%); white-space: nowrap; }
.fm-ticks span:first-child { transform: none; }
.fm-ticks span:last-child { transform: translateX(-100%); }

.stage-market-actions a.btn { cursor: pointer; }

.fm-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 44px;
  padding: 0 20px;
  border-top: 1px solid var(--border);
  background: rgb(0 0 0 / 0.2);
  border-bottom-left-radius: inherit;
  border-bottom-right-radius: inherit;
  font-size: 12.5px;
  color: var(--text-3);
  transition: color 200ms ease;
}
.fm-foot svg { width: 16px; height: 16px; }
.fm-foot:hover { color: var(--text); }
.fm-title .eyebrow { flex-wrap: nowrap; white-space: nowrap; overflow: hidden; }
@media (max-width: 479.98px) {
  .fm-title .eyebrow { letter-spacing: 0.04em; gap: 6px; }
}
.fm-readout { right: 16px; }
