/* TheObservers public site (spec 025). Brand tokens from the console (spec 014):
   ink #0b1020, signal blue #3d9be9, violet #6c5ad8, pitch green #35a872.
   Sora for headings, Manrope for text. Light and dark both defined. */

@font-face { font-family: 'Sora'; src: url('/static/fonts/sora-variable.woff2') format('woff2'); font-weight: 300 800; font-display: swap; }
@font-face { font-family: 'Manrope'; src: url('/static/fonts/manrope-variable.woff2') format('woff2'); font-weight: 300 800; font-display: swap; }

:root {
  --ink: #0b1020;
  --signal: #1f6fc0;
  --signal-strong: #175a9e;
  --violet: #5a48c9;
  --pitch: #1f7f52;
  --warn: #9a5b00;
  --bg: #f6f8fb;
  --surface: #ffffff;
  --text: #0b1020;
  --text-muted: #4c5770;
  --border: #dbe1ec;
  --on-primary: #ffffff;
  --radius: 14px;
  --space: 8px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --signal: #5aa9ee;
    --signal-strong: #7cc0f5;
    --violet: #9a8cf0;
    --pitch: #4cc48a;
    --warn: #e7b14d;
    --bg: #0b1020;
    --surface: #131a2e;
    --text: #eef2f8;
    --text-muted: #a3aec4;
    --border: #26304a;
    --on-primary: #0b1020;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
h1, h2, h3 { font-family: 'Sora', system-ui, sans-serif; line-height: 1.2; letter-spacing: -0.01em; margin: 0 0 calc(var(--space) * 2); }
h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 700; }
h2 { font-size: 22px; font-weight: 650; margin-top: calc(var(--space) * 5); }
p { margin: 0 0 calc(var(--space) * 2); }
a { color: var(--signal); }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; border-radius: 6px; }
img { max-width: 100%; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--text-muted); }
.small { font-size: 14px; }
.lead { font-size: 20px; color: var(--text-muted); max-width: 62ch; }

/* Header */
.top { border-bottom: 1px solid var(--border); background: var(--surface); position: sticky; top: 0; z-index: 10; }
.top-row { display: flex; align-items: center; gap: calc(var(--space) * 3); min-height: 64px; }
.brand { display: flex; align-items: center; gap: var(--space); font-family: 'Sora', sans-serif; font-weight: 700; color: var(--text); text-decoration: none; }
.brand img { border-radius: 50%; }
.nav { display: flex; gap: calc(var(--space) * 3); flex: 1; }
.nav a { color: var(--text-muted); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.top-actions { display: flex; align-items: center; gap: calc(var(--space) * 2); }
.nav-login { color: var(--text); text-decoration: none; font-weight: 600; font-size: 15px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 12px; font: 700 16px/1 'Manrope', sans-serif; text-decoration: none; border: 1px solid transparent; cursor: pointer; }
.btn-primary { background: var(--signal); color: var(--on-primary); }
.btn-primary:hover { background: var(--signal-strong); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--text-muted); }
.btn-small { min-height: 40px; padding: 0 16px; font-size: 15px; }
.btn-block { width: 100%; }
.cta-row { display: flex; flex-wrap: wrap; gap: calc(var(--space) * 1.5); margin: calc(var(--space) * 3) 0 calc(var(--space) * 2); }
.text-link { font-weight: 700; text-decoration: none; }
.text-link:hover { text-decoration: underline; }

/* Hero */
.hero { padding: calc(var(--space) * 8) 0 calc(var(--space) * 7); }
.hero-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: calc(var(--space) * 7); align-items: center; }

/* Cards */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: calc(var(--space) * 3); }
.signal { margin: 0; max-width: 420px; justify-self: end; width: 100%; box-shadow: 0 12px 32px rgb(11 16 32 / 10%); }
.signal-head { display: flex; align-items: center; gap: var(--space); font-weight: 700; font-size: 15px; margin-bottom: calc(var(--space) * 1.5); }
.signal-head .muted { margin-left: auto; font-weight: 600; font-size: 13px; }
.signal-match { font-family: 'Sora', sans-serif; font-size: 20px; font-weight: 650; margin: 0; }
.legs, .bets, .breakdown { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.legs { margin: calc(var(--space) * 2) 0; }
.legs th, .bets th { text-align: left; font-size: 13px; color: var(--text-muted); font-weight: 600; padding: 6px 0; border-bottom: 1px solid var(--border); }
.legs td { padding: 8px 0; border-bottom: 1px solid var(--border); }
.legs td:not(:first-child), .legs th:not(:first-child) { text-align: right; }
.tag { display: inline-block; font-size: 12px; font-weight: 700; padding: 1px 6px; border-radius: 6px; background: color-mix(in srgb, var(--pitch) 16%, transparent); color: var(--pitch); margin-left: 4px; }
.signal-actions { display: flex; gap: var(--space); }
.pill { flex: 1; text-align: center; padding: 10px; border-radius: 10px; background: var(--signal); color: var(--on-primary); font-weight: 700; font-size: 15px; }
.pill-ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--text-muted); }
.dot-live, .dot-ok { background: var(--pitch); }
.dot-warn { background: var(--warn); }

/* Steps band */
.band { background: var(--surface); border-block: 1px solid var(--border); padding: calc(var(--space) * 6) 0; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: calc(var(--space) * 4); }
.step h2 { margin-top: calc(var(--space) * 1.5); font-size: 20px; }
.step p { color: var(--text-muted); margin: 0; }
.step-n { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--border); font-weight: 800; font-family: 'Sora', sans-serif; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: calc(var(--space) * 6); padding-block: calc(var(--space) * 7); }
.split h2 { margin-top: 0; }

/* Content pages */
.page { padding-block: calc(var(--space) * 6) calc(var(--space) * 8); }
.narrow { max-width: 760px; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.center > img { border-radius: 50%; }
.ticks { padding-left: 20px; margin: 0 0 calc(var(--space) * 2); }
.ticks li { margin-bottom: var(--space); }
.prose h2 { font-size: 20px; margin-top: calc(var(--space) * 4); }
.notice { padding: 12px 16px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); }
.notice-error { border-color: var(--warn); }
.widget { display: flex; justify-content: center; min-height: 48px; margin: calc(var(--space) * 3) 0; }

/* Pricing */
.plan { margin-top: calc(var(--space) * 3); }
.plan h2 { margin-top: 0; }
.price { font-family: 'Sora', sans-serif; font-size: 32px; font-weight: 700; margin-bottom: 4px; }

/* FAQ */
.faq { border-bottom: 1px solid var(--border); padding: calc(var(--space) * 2) 0; }
.faq summary { cursor: pointer; font-weight: 700; font-size: 18px; }
.faq p { margin: var(--space) 0 0; color: var(--text-muted); }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: calc(var(--space) * 2); margin: calc(var(--space) * 4) 0; }
.stats-2 { grid-template-columns: repeat(2, 1fr); margin-top: calc(var(--space) * 2); }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: calc(var(--space) * 2.5); }
.stat-label { font-size: 14px; color: var(--text-muted); font-weight: 600; margin: 0 0 4px; }
.stat-value { font-family: 'Sora', sans-serif; font-size: clamp(22px, 6vw, 30px); white-space: nowrap; font-weight: 700; margin: 0 0 4px; font-variant-numeric: tabular-nums; }
.stat .small { margin: 0; }
.breakdown th, .breakdown td { text-align: left; padding: 12px 8px 12px 0; border-bottom: 1px solid var(--border); }
.breakdown th { font-weight: 700; }
.breakdown td:nth-child(2) { font-weight: 700; width: 80px; }

/* Account */
.account-head { display: flex; align-items: center; justify-content: space-between; gap: calc(var(--space) * 2); }
.account-head h1 { margin: 0; }
.account-head form { margin: 0; }
.status-card { margin-top: calc(var(--space) * 3); }
.status-card p:first-child { font-size: 18px; }
.bets td { padding: 10px 8px 10px 0; border-bottom: 1px solid var(--border); vertical-align: top; font-size: 15px; }

/* Footer */
.foot { border-top: 1px solid var(--border); background: var(--surface); padding: calc(var(--space) * 5) 0; margin-top: calc(var(--space) * 4); }
.foot-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: calc(var(--space) * 4); }
.foot-brand { display: flex; align-items: center; gap: var(--space); font-family: 'Sora', sans-serif; font-weight: 700; }
.foot-brand img { border-radius: 50%; }
.foot-links { display: grid; grid-template-columns: repeat(2, auto); gap: var(--space) calc(var(--space) * 3); justify-content: end; align-content: start; }
.foot-links a { color: var(--text-muted); text-decoration: none; font-size: 15px; }
.foot-links a:hover { color: var(--text); }

@media (max-width: 860px) {
  .top-row { flex-wrap: wrap; justify-content: space-between; row-gap: 0; }
  .nav { order: 3; flex: 0 0 100%; gap: calc(var(--space) * 2.5); overflow-x: auto; padding: 4px 0 12px; }
  .hero { padding-top: calc(var(--space) * 5); }
  .hero-grid, .split, .foot-grid { grid-template-columns: 1fr; gap: calc(var(--space) * 4); }
  .signal { justify-self: stretch; max-width: none; }
  .steps { grid-template-columns: 1fr; gap: calc(var(--space) * 3); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .foot-links { justify-content: start; }
  .lead { font-size: 18px; }
  .bets th:nth-child(3), .bets td:nth-child(3) { display: none; }
}

@media (max-width: 520px) {
  .stats-2 { grid-template-columns: 1fr; }
}
