/* Launch Day v2. The game's ink-on-paper tokens (src/renderer/src/styles/core/variables.css at 596f76b) and its
   four typefaces, laid out like a phone game: one column, one decision on screen at a time. Light only: the game's
   own design rule is paper and ink. */

@font-face { font-family: 'Fraunces Variable'; src: url(fonts/fraunces-latin-full-normal.woff2) format('woff2'); font-weight: 100 900; font-display: swap; }
@font-face { font-family: 'Archivo Variable'; src: url(fonts/archivo-latin-wdth-normal.woff2) format('woff2'); font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url(fonts/newsreader-latin-400-normal.woff2) format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url(fonts/newsreader-latin-400-italic.woff2) format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: 'JetBrains Mono'; src: url(fonts/jetbrains-mono-latin-700-normal.woff2) format('woff2'); font-weight: 700; font-display: swap; }

:root {
  --desk: #eae3d6;
  --base: #f4eee3;
  --sheet: #fbf7ee;
  --inset: #ece4d4;
  --ink: #262319;
  --body: #3b372c;
  --muted: #6c6553;
  --faint: #8f8672;
  --rule: rgba(38, 35, 25, 0.16);
  --green: #3f6b4f;
  --green-wash: rgba(63, 107, 79, 0.12);
  --stamp: #b4552d;
  --stamp-dark: #9c4825;
  --bad: #b0432f;
  --bad-wash: rgba(176, 67, 47, 0.12);
  --amber: #d9a441;
  --plum: #6b4f8f;
  --f-display: 'Fraunces Variable', Georgia, serif;
  --f-ui: 'Archivo Variable', -apple-system, 'Segoe UI', sans-serif;
  --f-serif: 'Newsreader', Georgia, serif;
  --f-mono: 'JetBrains Mono', Menlo, monospace;
  --r: 10px;
  --print: 4px 4px 0 var(--ink);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--desk);
  color: var(--body);
  font-family: var(--f-ui);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }

/* ------------------------------------------------------------------ top bar */
.bar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; background: rgba(234, 227, 214, 0.92); backdrop-filter: blur(6px); }
.bar__brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--ink); font-weight: 800; font-size: 14px; letter-spacing: 0.02em; }
.bar__brand img { border-radius: 6px; }
.bar__wish { font-weight: 800; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink); text-decoration: none; padding: 7px 11px; border: 2px solid var(--ink); border-radius: 8px; background: var(--sheet); }
@media (max-width: 420px) { .bar__brand span { display: none; } }

.app { width: 100%; max-width: 560px; margin: 0 auto; padding: 4px 16px 24px; }
.scr { animation: rise 0.35s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
.kicker { margin: 0 0 6px; font-weight: 800; font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--stamp); }

/* ------------------------------------------------------------------ buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 12px 22px;
  font-weight: 800; font-size: 15px; letter-spacing: 0.06em; text-transform: uppercase; text-decoration: none;
  color: var(--ink); background: var(--sheet); border: 2.5px solid var(--ink); border-radius: var(--r); box-shadow: var(--print);
  cursor: pointer; transition: transform 0.08s ease, box-shadow 0.08s ease;
}
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.btn:focus-visible, .opt:focus-visible { outline: 3px solid #3f618f; outline-offset: 3px; }
.btn--go { background: var(--green); color: var(--sheet); }
.btn--stamp { background: var(--stamp); color: var(--sheet); }
.btn--lg { min-height: 58px; font-size: 16px; }

/* ------------------------------------------------------------------ intro */
.intro { padding-top: 8px; }
.intro__art { margin: 0 0 22px; border: 2.5px solid var(--ink); border-radius: 14px; overflow: hidden; box-shadow: 6px 6px 0 var(--ink); }
.intro__h { margin: 0 0 12px; font-family: var(--f-display); font-weight: 900; font-variation-settings: 'opsz' 144; font-size: clamp(38px, 10vw, 54px); line-height: 0.98; letter-spacing: -0.015em; color: var(--ink); }
.intro__lede { margin: 0 0 22px; font-family: var(--f-serif); font-size: 20px; line-height: 1.4; color: var(--ink); }
.intro .btn--go { width: 100%; font-size: 18px; min-height: 60px; }
.intro__meta { margin: 12px 0 0; text-align: center; font-size: 13px; color: var(--muted); }

/* ------------------------------------------------------------------ HUD */
.hud { position: sticky; top: 52px; z-index: 5; margin: 0 -16px 14px; padding: 8px 16px 10px; background: rgba(234, 227, 214, 0.95); backdrop-filter: blur(6px); border-bottom: 1px solid var(--rule); }
.day__bars { display: grid; grid-template-columns: repeat(24, 1fr); gap: 2px; align-items: end; height: 44px; }
.day__bars i { display: block; height: 6px; border-radius: 2px 2px 0 0; background: rgba(38, 35, 25, 0.14); transition: height 0.25s ease, background 0.25s ease; position: relative; }
.day__bars i.on { background: var(--ink); }
.day__bars i.fail { background: var(--bad); }
.day__bars i.slow { background: var(--amber); }
.day__bars i.down { background: var(--faint); }
.day__bars i.rival::after { content: ''; position: absolute; left: 0; right: 0; top: -7px; height: 4px; border-radius: 2px; background: var(--plum); }
.day__bars i.now { outline: 2px solid var(--stamp); outline-offset: 1px; }
.day__axis { display: flex; justify-content: space-between; align-items: baseline; margin-top: 4px; font-size: 11px; color: var(--faint); font-family: var(--f-mono); }
.day__axis b { font-family: var(--f-ui); font-size: 12px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 10px 0 0; }
.stats div { background: var(--sheet); border: 2px solid var(--ink); border-radius: 8px; padding: 5px 8px 6px; min-width: 0; }
.stats dt { font-size: 10px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.stats dd { margin: 0; font-family: var(--f-mono); font-weight: 700; font-size: 19px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stats dd small { font-size: 11px; margin-left: 4px; }
.pos { color: var(--green) !important; }
.neg { color: var(--bad) !important; }
.bump { animation: bump 0.45s ease; }
@keyframes bump { 40% { transform: scale(1.18); } }
.focus { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.focus__k { font-size: 10px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.focus__dots { display: flex; gap: 5px; }
.focus__dots i { width: 13px; height: 13px; border-radius: 50%; background: var(--ink); border: 2px solid var(--ink); transition: background 0.2s; }
.focus__dots i.spent { background: transparent; border-color: var(--faint); }

/* ------------------------------------------------------------------ the card */
.card {
  position: relative; background: var(--sheet); border: 2.5px solid var(--ink); border-radius: 14px; box-shadow: 6px 6px 0 var(--ink);
  padding: 16px 16px 14px; animation: deal 0.32s cubic-bezier(0.2, 0.9, 0.3, 1.05);
}
@keyframes deal { from { opacity: 0; transform: translateY(24px) rotate(1.2deg); } }
.card__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.chip { display: inline-block; padding: 3px 9px; font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--stamp); border: 2px solid var(--stamp); border-radius: 6px; transform: rotate(-1.5deg); }
.card__hour { font-family: var(--f-mono); font-size: 12px; color: var(--faint); }
.who { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; }
.who img { width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--ink); }
.who b { display: block; font-size: 15px; color: var(--ink); }
.who span { font-size: 12px; color: var(--muted); }
.card__note { margin: 0 0 8px; font-family: var(--f-serif); font-style: italic; font-size: 15px; color: var(--muted); }
.card__h { margin: 0 0 14px; font-family: var(--f-display); font-weight: 800; font-variation-settings: 'opsz' 72; font-size: clamp(21px, 5.6vw, 25px); line-height: 1.22; color: var(--ink); }
.tip { margin: -6px 0 12px; font-size: 13px; color: var(--muted); }
.tip b { color: var(--ink); }
.opts { display: grid; gap: 9px; }
.opt {
  display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center; width: 100%; text-align: left;
  padding: 12px 14px; min-height: 56px; background: var(--base); border: 2px solid var(--ink); border-radius: 10px; cursor: pointer;
  box-shadow: 3px 3px 0 var(--ink); transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.15s ease, opacity 0.2s;
}
.opt:hover { background: #fffaf0; }
.opt:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.opt__label { font-weight: 700; font-size: 16px; color: var(--ink); line-height: 1.3; }
.opt__hint { grid-column: 1; font-size: 13px; color: var(--muted); line-height: 1.3; }
.opt__cost { grid-row: 1 / span 2; grid-column: 2; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font-family: var(--f-mono); font-size: 13px; color: var(--ink); white-space: nowrap; }
.opt__cost .dots { letter-spacing: 2px; font-size: 14px; }
.opt__cost .free { font-family: var(--f-ui); font-weight: 800; font-size: 11px; letter-spacing: 0.1em; color: var(--muted); }
.opt__cost .cash { font-size: 12px; color: var(--muted); }
.opt[disabled] { opacity: 0.45; cursor: not-allowed; box-shadow: none; }
.opt.picked, .opt.picked[disabled] { background: var(--ink); color: var(--sheet); opacity: 1; box-shadow: 3px 3px 0 var(--stamp); }
.opt.picked .opt__label, .opt.picked .opt__hint, .opt.picked .opt__cost, .opt.picked .opt__cost .free, .opt.picked .opt__cost .cash { color: var(--sheet); }
.opts.done .opt:not(.picked) { opacity: 0.32; }
.reply { margin-top: 14px; padding: 12px 14px; border-left: 4px solid var(--ink); background: var(--inset); border-radius: 0 10px 10px 0; animation: rise 0.3s ease-out; }
.reply__line { margin: 0; font-family: var(--f-serif); font-style: italic; font-size: 17px; line-height: 1.4; color: var(--ink); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; padding: 0; list-style: none; }
.chips li { font-family: var(--f-mono); font-size: 13px; padding: 2px 8px; border-radius: 6px; border: 1.5px solid currentColor; }
.chips .up { color: var(--green); background: var(--green-wash); }
.chips .down { color: var(--bad); background: var(--bad-wash); }
.next { margin-top: 14px; width: 100%; }
.clockline { margin: 16px 2px 0; text-align: center; font-family: var(--f-mono); font-size: 13px; color: var(--muted); }

/* ------------------------------------------------------------------ the verdict */
.end { padding-top: 10px; }
.end__h { margin: 0; font-family: var(--f-display); font-weight: 900; font-variation-settings: 'opsz' 144; font-size: clamp(36px, 9vw, 50px); line-height: 1; letter-spacing: -0.01em; color: var(--ink); }
.end__sub { margin: 8px 0 18px; font-family: var(--f-serif); font-size: 19px; color: var(--ink); }
.stamp { display: inline-block; margin: 0 0 18px; padding: 8px 16px; border: 4px solid var(--stamp); border-radius: 10px; color: var(--stamp); font-weight: 900; font-stretch: 85%; white-space: nowrap; font-size: clamp(24px, 7.5vw, 36px); letter-spacing: 0.04em; text-transform: uppercase; transform: rotate(-2deg); animation: slam 0.45s cubic-bezier(0.2, 1.5, 0.4, 1) both 0.15s; background: rgba(180, 85, 45, 0.05); }
@keyframes slam { from { opacity: 0; transform: rotate(-8deg) scale(1.8); } }
.end__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 16px; }
.end__stats div { background: var(--sheet); border: 2px solid var(--ink); border-radius: 10px; padding: 8px 10px; }
.end__stats dt { font-size: 10px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.end__stats dd { margin: 0; font-family: var(--f-mono); font-weight: 700; font-size: 22px; color: var(--ink); }
.grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 4px; max-width: 360px; }
.grid i, .g { display: inline-block; aspect-ratio: 1; border-radius: 4px; background: #4f8a5c; }
.grid i.fail, .g--fail { background: var(--bad); }
.grid i.slow, .g--slow { background: var(--amber); }
.grid i.down, .g--down { background: var(--ink); }
.grid i.rival, .g--rival { background: var(--plum); }
.grid i { animation: pop 0.25s ease-out both; }
@keyframes pop { from { transform: scale(0.4); opacity: 0; } }
.grid__key { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin: 8px 0 0; font-size: 12px; color: var(--muted); }
.g { width: 11px; height: 11px; margin-right: -6px; vertical-align: -1px; }
.pct { margin: 16px 0 0; padding: 10px 12px; font-weight: 700; font-size: 15px; color: var(--ink); background: var(--green-wash); border: 2px solid var(--green); border-radius: 10px; }
.why__h { margin: 26px 0 0; font-size: 12px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.why { margin: 10px 0 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.why li { position: relative; padding-left: 18px; font-family: var(--f-serif); font-size: 16px; color: var(--ink); line-height: 1.4; }
.why li::before { content: ''; position: absolute; left: 2px; top: 9px; width: 7px; height: 7px; border-radius: 50%; background: var(--stamp); }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.actions .btn { padding: 12px 10px; font-size: 13px; }
.share__msg { min-height: 1em; margin: 8px 0 0; font-size: 13px; color: var(--green); text-align: center; }
.cta { margin-top: 18px; background: var(--sheet); border: 2.5px solid var(--ink); border-radius: 16px; box-shadow: 6px 6px 0 var(--ink); overflow: hidden; }
.cta__art { border-bottom: 2.5px solid var(--ink); }
.cta__copy { padding: 16px; }
.cta__h { margin: 0 0 6px; font-family: var(--f-display); font-weight: 900; font-size: 28px; color: var(--ink); }
.cta__copy p { margin: 0 0 14px; font-family: var(--f-serif); font-size: 17px; line-height: 1.45; color: var(--ink); }
.cta .btn { width: 100%; }

/* ------------------------------------------------------------------ footer */
.foot { max-width: 560px; margin: 0 auto; padding: 18px 16px 36px; font-size: 12px; line-height: 1.5; color: var(--muted); }
.foot p { margin: 0 0 6px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body.debug *, body.debug *::before, body.debug *::after { animation: none !important; transition: none !important; }
