/* til.today — shared daily (run + inline deep-dive) styles.
   One stylesheet, many ideas. Per-idea page = window.IDEA + engine.js. */
/* self-hosted webfonts so non-Mac visitors get the intended look; Mac keeps its native Didot/Charter (earlier in the stack) */
@font-face { font-family: 'Bodoni Moda'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('/fonts/bodoni-moda-400.woff2') format('woff2'); }
@font-face { font-family: 'Bodoni Moda'; font-style: italic; font-weight: 400 700; font-display: swap; src: url('/fonts/bodoni-moda-500-italic.woff2') format('woff2'); }
@font-face { font-family: 'Source Serif 4'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/source-serif-4-400.woff2') format('woff2'); }
@font-face { font-family: 'Source Serif 4'; font-style: italic; font-weight: 400; font-display: swap; src: url('/fonts/source-serif-4-400-italic.woff2') format('woff2'); }
:root {
  --bg: #0d181c; --bg-2: #14262c; --tile: #162b32; --tile-hi: #1d373f; --line: #274952;
  --text: #eef1e9; --soft: #9fb4b5; --faint: #6d8388;
  --cyan: #3ad6e6; --gold: #e7b64d; --good: #5fcf92; --bad: #f2705e;
  --display: "Didot", "Bodoni 72", "Hoefler Text", "Bodoni Moda", serif;
  --serif: "Charter", "Iowan Old Style", Palatino, "Source Serif 4", Georgia, serif;
  --sans: "Helvetica Neue", Inter, system-ui, -apple-system, sans-serif;
  --mono: "SF Mono", "IBM Plex Mono", ui-monospace, Menlo, monospace;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--text); font-family: var(--serif); -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(1100px 460px at 50% -8%, rgba(58,214,230,0.08), transparent 70%); background-repeat: no-repeat; }
.wrap { max-width: 620px; margin: 0 auto; padding: 0 24px 40px; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

.hud { display: flex; justify-content: space-between; align-items: center; padding: 22px 0 18px; border-bottom: 1px solid var(--line); }
.hud .brand { font-family: var(--display); font-size: 22px; text-decoration: none; color: var(--text); } .hud .brand span { color: var(--cyan); font-style: italic; }
.hud .score { text-align: right; }
.hud .score .k { font-family: var(--sans); font-size: 9.5px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--faint); }
.hud .score .v { font-family: var(--mono); font-size: 24px; font-weight: 700; color: var(--gold); transition: transform 140ms; }
.hud .score .v.pop { transform: scale(1.22); }

/* inline SVG icons — inherit the colour + size of surrounding text (see icons.js) */
.ico { width: 1em; height: 1em; display: inline-block; vertical-align: -0.13em; flex: none; }
.ico + * , * + .ico { } /* no-op: spacing handled by a literal space in markup */
/* meter labels colour their leading icon by the meter's meaning */
.meter.stop .mh .ico { color: var(--good); }
.meter.lost .mh .ico { color: var(--bad); }
.meter .mh span:first-child { display: inline-flex; align-items: center; gap: 6px; }

/* director — the combo pill (momentum) sits between brand and score */
.combo { font-family: var(--sans); font-weight: 800; font-size: 13px; letter-spacing: 0.05em; color: var(--gold); opacity: 0; transform: scale(0.7); }
.combo.on { opacity: 1; animation: comboPop 320ms ease-out; }
@keyframes comboPop { 0% { opacity: 0; transform: scale(0.6) translateY(3px); } 55% { opacity: 1; transform: scale(1.25); } 100% { opacity: 1; transform: scale(1); } }
/* director — the host voice, a line that reacts to your run */
.host { text-align: center; font-family: var(--serif); font-style: italic; font-size: 15.5px; color: var(--soft); min-height: 21px; margin: 12px 0 0; transition: opacity 160ms; }
.cflare { font-family: var(--sans); font-weight: 800; font-size: 12px; color: var(--gold); margin-left: 6px; }

.pips { display: flex; gap: 7px; justify-content: center; margin: 22px 0 4px; }
.pip { width: 34px; height: 5px; border-radius: 3px; background: var(--line); transition: background 200ms; }
.pip.on { background: var(--cyan); } .pip.good { background: var(--good); } .pip.bad { background: var(--bad); }

.stage { padding: 30px 0 10px; animation: rise 340ms ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.rnd { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase; color: var(--cyan); text-align: center; margin-bottom: 18px; }
.setup { text-align: center; font-family: var(--serif); font-size: 16.5px; line-height: 1.5; color: var(--soft); max-width: 40ch; margin: 0 auto 14px; }
.q { font-family: var(--display); font-weight: 400; font-size: clamp(27px, 5vw, 40px); line-height: 1.1; text-align: center; margin: 0 auto 26px; max-width: 15ch; }

.wager { text-align: center; margin-bottom: 20px; }
.wager .lab { font-family: var(--sans); font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); margin-bottom: 10px; }
.chips { display: inline-flex; gap: 8px; }
.chip { font-family: var(--sans); font-size: 13px; font-weight: 700; color: var(--soft); background: var(--tile); border: 1px solid var(--line); border-radius: 10px; padding: 9px 15px; cursor: pointer; transition: all 120ms; }
.chip:hover { border-color: var(--gold); }
.chip.sel { background: rgba(231,182,77,0.14); border-color: var(--gold); color: var(--gold); }

.tiles { display: flex; flex-direction: column; gap: 11px; }
.tile { position: relative; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 18px 20px; background: var(--tile); border: 1px solid var(--line); border-radius: 13px; color: var(--text); font-family: var(--serif); font-size: 20px; cursor: pointer; box-shadow: 0 3px 0 rgba(0,0,0,0.35); transition: transform 120ms, border-color 120ms, background 120ms; }
.tile:hover:not(.dead) { border-color: var(--cyan); background: var(--tile-hi); transform: translateY(-2px); }
.tile.dead { cursor: default; opacity: 0.85; }
.tile.correct { border-color: var(--good); background: rgba(95,207,146,0.15); box-shadow: 0 0 0 1px var(--good), 0 0 24px rgba(95,207,146,0.18); }
.tile.wrong { border-color: var(--bad); background: rgba(242,112,94,0.14); }
.tile.wrong.shake { animation: shake 300ms; }
@keyframes shake { 10%,90%{transform:translateX(-2px)} 30%,70%{transform:translateX(4px)} 50%{transform:translateX(-5px)} }
.tile .mk { font-family: var(--sans); font-weight: 800; }

.netbox { text-align: center; margin: 6px 0 20px; }
.netbox .k { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--faint); }
.netbox .net { font-family: var(--mono); font-size: 58px; font-weight: 700; line-height: 1; color: var(--cyan); }
.netbox .zone { font-family: var(--sans); font-size: 12px; color: var(--gold); height: 16px; margin-top: 6px; }
.slider-wrap { margin: 6px 0 14px; }
input[type=range] { width: 100%; -webkit-appearance: none; appearance: none; height: 8px; border-radius: 999px; background: var(--tile); outline: none; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 30px; height: 30px; border-radius: 50%; background: var(--gold); border: 3px solid var(--bg); box-shadow: 0 2px 8px rgba(0,0,0,0.5); cursor: grab; }
.slabels { display: flex; justify-content: space-between; font-family: var(--sans); font-size: 11px; color: var(--faint); font-weight: 600; margin-top: 6px; }
.meters { display: flex; flex-direction: column; gap: 10px; margin: 16px 0 6px; font-family: var(--sans); }
.meter .mh { display: flex; justify-content: space-between; font-size: 12.5px; font-weight: 700; color: var(--soft); margin-bottom: 5px; }
.meter .mt { height: 10px; background: var(--tile); border-radius: 999px; overflow: hidden; }
.meter .mf { height: 100%; border-radius: 999px; transition: width 120ms; }
.meter.stop .mf { background: var(--good); } .meter.lost .mf { background: var(--bad); }

/* estimate — guess a number, real value revealed */
.guessbox { text-align: center; margin: 6px 0 18px; }
.guessbox .k { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--faint); }
.guessbox .guess { font-family: var(--mono); font-size: 54px; font-weight: 700; line-height: 1; color: var(--cyan); font-variant-numeric: tabular-nums; }
.track-mark { position: relative; }
.truth { position: absolute; top: -7px; width: 3px; height: 22px; background: var(--good); border-radius: 2px; transform: translateX(-1px); box-shadow: 0 0 10px rgba(95,207,146,0.7); }
.truth::after { content: 'real'; position: absolute; top: -15px; left: 50%; transform: translateX(-50%); font-family: var(--sans); font-size: 9px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--good); }

/* order — arrange into the right sequence */
.ordlist { display: flex; flex-direction: column; gap: 9px; }
.ordrow { display: flex; align-items: center; gap: 12px; padding: 13px 14px; background: var(--tile); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 3px 0 rgba(0,0,0,0.35); transition: border-color 140ms, background 140ms; }
.ordrow .oi { font-family: var(--mono); font-size: 15px; font-weight: 700; color: var(--gold); width: 22px; text-align: center; flex: none; }
.ordrow .ot { flex: 1; font-family: var(--serif); font-size: 18px; line-height: 1.25; }
.ordrow .oc { display: flex; gap: 6px; align-items: center; font-family: var(--sans); font-size: 13px; font-weight: 800; color: var(--soft); flex: none; }
.omv { width: 34px; height: 34px; border-radius: 9px; background: var(--bg-2); border: 1px solid var(--line); color: var(--soft); font-size: 15px; cursor: pointer; transition: all 120ms; }
.omv:hover:not(:disabled) { border-color: var(--cyan); color: var(--cyan); }
.omv:disabled { opacity: 0.3; cursor: default; }
.ordrow.ok { border-color: var(--good); background: rgba(95,207,146,0.13); } .ordrow.ok .oc { color: var(--good); }
.ordrow.no { border-color: var(--bad); background: rgba(242,112,94,0.1); } .ordrow.no .oc { color: var(--bad); }

/* sort — swipe cards into two buckets */
.sortprog { font-family: var(--mono); font-size: 13px; color: var(--faint); text-align: center; margin-bottom: 12px; }
.sortcard { min-height: 128px; display: flex; align-items: center; justify-content: center; background: var(--tile); border: 1px solid var(--line); border-radius: 16px; padding: 24px; box-shadow: 0 4px 0 rgba(0,0,0,0.35); transition: transform 140ms, border-color 140ms, background 140ms; }
.sortcard .scinner { font-family: var(--serif); font-size: 21px; line-height: 1.35; text-align: center; }
.sortcard .scinner.done { font-family: var(--mono); font-size: 18px; color: var(--gold); }
.sortcard.flash-ok { border-color: var(--good); background: rgba(95,207,146,0.14); transform: scale(1.02); }
.sortcard.flash-no { border-color: var(--bad); background: rgba(242,112,94,0.12); }
.sortbtns { display: flex; gap: 11px; margin-top: 14px; }
.sortb { flex: 1; padding: 16px 12px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 13px; color: var(--text); font-family: var(--sans); font-weight: 800; font-size: 14px; cursor: pointer; box-shadow: 0 3px 0 rgba(0,0,0,0.35); transition: all 120ms; }
.sortb:hover:not(:disabled) { border-color: var(--cyan); background: var(--tile-hi); transform: translateY(-2px); }
.sortb:disabled { opacity: 0.5; cursor: default; }

.feedback { margin-top: 22px; text-align: center; }
.verdict { font-family: var(--sans); font-size: 14px; font-weight: 800; letter-spacing: 0.13em; text-transform: uppercase; margin-bottom: 10px; }
.verdict.good { color: var(--good); } .verdict.bad { color: var(--bad); } .verdict.gold { color: var(--gold); }
.why { font-size: 18px; line-height: 1.5; color: var(--text); max-width: 42ch; margin: 0 auto; }

.cta { display: inline-flex; align-items: center; gap: 10px; background: var(--cyan); color: #06222a; font-family: var(--sans); font-weight: 800; font-size: 14px; letter-spacing: 0.05em; text-transform: uppercase; padding: 15px 30px; border-radius: 12px; text-decoration: none; border: 0; cursor: pointer; box-shadow: 0 3px 0 #0a4650; transition: transform 120ms; }
.cta:hover { transform: translateY(-2px); } .cta:active { transform: translateY(1px); box-shadow: 0 1px 0 #0a4650; }
.footer-cta { text-align: center; margin-top: 30px; }

.end { text-align: center; padding: 20px 0; animation: rise 380ms ease-out; }
.end .endtag { font-family: var(--sans); font-size: 12px; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase; color: var(--soft); margin-bottom: 8px; }
.end .endtag.gold { color: var(--gold); animation: rise 500ms ease-out; }
.end .bestline { font-family: var(--sans); font-size: 13px; font-weight: 700; color: var(--soft); margin: -14px 0 22px; }
.end .bestline.gold { color: var(--gold); }
.streaknote .tease { font-family: var(--sans); font-size: 12.5px; color: var(--soft); margin-top: 10px; opacity: 0.92; }
.end .fin { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: var(--cyan); }
.end .total { font-family: var(--mono); font-size: 72px; font-weight: 700; line-height: 1; margin: 8px 0 2px; color: var(--gold); }
.end .rank { font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--soft); margin-bottom: 24px; }
.card { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 22px; margin: 0 auto 20px; max-width: 420px; }
.card .ct { font-family: var(--display); font-size: 19px; margin-bottom: 12px; }
.card .squares { font-size: 26px; letter-spacing: 4px; margin-bottom: 8px; }
.card .cstat { font-family: var(--mono); font-size: 13px; color: var(--soft); }
.end .row { display: inline-flex; gap: 14px; align-items: center; flex-wrap: wrap; justify-content: center; }
.ghost { background: transparent; color: var(--soft); border: 1px solid var(--line); border-radius: 12px; padding: 15px 22px; font-family: var(--sans); font-weight: 700; font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; cursor: pointer; text-decoration: none; }
.ghost:hover { border-color: var(--cyan); color: var(--cyan); }
.streaknote { font-family: var(--sans); font-size: 13px; color: var(--gold); margin-top: 18px; }
.tally { color: var(--gold); vertical-align: -4px; margin-right: 6px; }

/* inline deep dive */
.deepdive { display: none; border-top: 3px double var(--line); margin-top: 20px; padding-top: 20px; }
.deepdive.on { display: block; animation: rise 400ms ease-out; }
.dd-inner { max-width: 600px; margin: 0 auto; }
.dd-eyebrow { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--cyan); text-align: center; margin: 6px 0 14px; }
.dd h2 { font-family: var(--display); font-weight: 400; font-size: clamp(26px, 4.6vw, 36px); line-height: 1.12; text-align: center; margin: 0 auto 26px; max-width: 20ch; }
.dd h3 { font-family: var(--display); font-weight: 400; font-size: 23px; margin: 34px 0 12px; }
.dd p { font-size: 18px; line-height: 1.62; color: var(--text); margin: 0 0 18px; }
.dd .soft { color: var(--soft); }
.pull { border-left: 3px solid var(--cyan); padding: 4px 0 4px 20px; margin: 22px 0; font-size: 21px; line-height: 1.4; font-style: italic; color: var(--text); }
.pull cite { display: block; margin-top: 8px; font-family: var(--sans); font-style: normal; font-size: 13px; color: var(--faint); }
.refs { margin: 30px 0; }
.refs .rl { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); margin-bottom: 6px; }
.refrow { display: grid; grid-template-columns: 1fr auto; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); font-family: var(--sans); font-size: 13.5px; line-height: 1.45; }
.refrow .st { font-size: 10.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; padding: 3px 8px; border-radius: 999px; height: fit-content; }
.st.v { background: rgba(95,207,146,0.15); color: var(--good); } .st.r { background: rgba(231,182,77,0.15); color: var(--gold); }
.refrow a, .dd a { color: var(--cyan); }
.src { font-family: var(--sans); font-size: 14px; color: var(--soft); }
.src li { margin-bottom: 8px; }
.dd-foot { text-align: center; margin: 34px 0 10px; }
@media (prefers-reduced-motion: reduce) { .stage, .end, .deepdive.on, .tile.wrong.shake { animation: none; } .tile, .cta { transition: none; } }

/* author byline + "who's this?" card styles moved to the shared authors.css
   (loaded by every *-article.html alongside this file, and by the landing) so the
   landing and the played covers share ONE definition and can't drift. See authors.css. */
