/* Global Takeover games: the landing page's tokens (graphite and signal orange, Sora and Figtree) as an app shell. */
:root {
  --bg: #18191b; --surface: #222427; --surface-2: #2b2e32; --ink: #eff0f1; --muted: #9c9ea3;
  --line: rgba(239, 240, 241, .12); --accent: #ff4a1f; --accent-ink: #18191b;
  --good: #3ccf8e; --mid: #ffc23d; --bad: #ff6b5e;
  --ocean: #142330; --land: #39444e; --land-hi: #4b5864; --border: #22303b;
  --font-display: "Sora", system-ui, sans-serif; --font-text: "Figtree", system-ui, sans-serif;
  --r: 16px; --r-sm: 10px; --bar: 64px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--ink); font: 16px/1.5 var(--font-text); -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; }
a { color: inherit; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* top bar */
.bar { position: fixed; inset: 0 0 auto; height: var(--bar); z-index: 20; display: flex; align-items: center; gap: 16px;
  padding: 0 24px; background: var(--bg); border-bottom: 1px solid var(--line); }
.bar__home { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 500 17px/1 var(--font-display); letter-spacing: -.02em; min-height: 44px; }
.bar__home svg { width: 22px; height: 22px; }
.bar__sep { width: 1px; height: 24px; background: var(--line); }
.bar__game { font: 500 15px/1 var(--font-text); color: var(--muted); }
.bar__spacer { flex: 1; }
.stat { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; min-width: 64px; }
.stat__k { font-size: 12px; color: var(--muted); line-height: 1; }
.stat__v { font: 500 18px/1 var(--font-display); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.dots { display: flex; gap: 6px; }
.dots i { width: 22px; height: 6px; border-radius: 3px; background: var(--surface-2); transition: background .3s; }
.dots i.is-done { background: var(--ink); }
.dots i.is-now { background: var(--accent); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border-radius: 999px;
  border: 1px solid transparent; font: 500 16px/1 var(--font-text); cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: transform .18s cubic-bezier(.2,.8,.2,1), background-color .18s, opacity .18s; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(1px) scale(.98); transition-duration: .06s; }
.btn--go { background: var(--accent); color: var(--accent-ink); }
.btn--go:hover { background: #ff6640; }
.btn--ghost { background: transparent; border-color: rgba(239,240,241,.28); }
.btn--ghost:hover { background: rgba(239,240,241,.06); }
.btn[disabled] { opacity: .38; cursor: not-allowed; transform: none; }
.btn svg { width: 14px; height: 14px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border-radius: 999px; background: var(--surface-2);
  font: 500 13px/1 var(--font-text); color: var(--ink); }

/* map */
.wm { display: block; width: 100%; height: 100%; touch-action: none; cursor: crosshair; user-select: none; }
.wm__ocean { fill: var(--ocean); }
.wm__grat { fill: none; stroke: rgba(255,255,255,.05); stroke-width: .6; vector-effect: non-scaling-stroke; }
.wm__c { fill: var(--land); transition: fill .25s; }
.wm__c:hover { fill: var(--land-hi); }
.wm__c.is-answer { fill: var(--accent); }
.wm__c.is-wrong { fill: #6b4a44; }
.wm__b { fill: none; stroke: var(--border); stroke-width: .7; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.wm__line { fill: none; stroke: var(--ink); stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.wm__line.is-done { stroke-dasharray: 2 6; }
.wm__labels { pointer-events: none; }
.wm__label { font: 500 11px/1 var(--font-text); fill: rgba(255,255,255,.72); text-anchor: middle; dominant-baseline: central;
  paint-order: stroke; stroke: rgba(20,35,48,.85); stroke-width: 3px; stroke-linejoin: round; opacity: 0; transition: opacity .2s; }
.wm__label.is-on { opacity: 1; }
.wm__pin { pointer-events: none; }
.wm__pin .wm__head { stroke: var(--bg); stroke-width: 2; transition: transform .35s cubic-bezier(.3,1.6,.5,1); }
.wm__pin .wm__dot { fill: var(--bg); transition: transform .35s cubic-bezier(.3,1.6,.5,1); }
.wm__pin.is-new .wm__head, .wm__pin.is-new .wm__dot { transform: translateY(-18px) scale(.6); }
.wm__shadow { fill: rgba(0,0,0,.45); }
.wm__pin--guess .wm__head { fill: var(--ink); }
.wm__pin--answer .wm__head { fill: var(--accent); }
.map-tools { position: absolute; right: 12px; bottom: 12px; display: flex; flex-direction: column; gap: 6px; z-index: 2; }
.map-tools button { width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: rgba(24,25,27,.92); cursor: pointer;
  display: grid; place-items: center; transition: background .15s, transform .15s; }
.map-tools button:hover { background: var(--surface-2); }
.map-tools button:active { transform: scale(.94); }
.map-tools svg { width: 16px; height: 16px; }

/* shared panels */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.t-h { font: 400 clamp(28px, 3.2vw, 44px)/1.08 var(--font-display); letter-spacing: -.035em; margin: 0; }
.t-h3 { font: 400 24px/1.2 var(--font-display); letter-spacing: -.02em; margin: 0; }
.muted { color: var(--muted); }
.count-up { font-variant-numeric: tabular-nums; }

/* start and end screens */
.screen { min-height: 100svh; padding: calc(var(--bar) + 48px) 24px 48px; display: grid; place-items: center; }
.screen[hidden] { display: none; }
.intro { width: min(100%, 1040px); display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.intro__art { aspect-ratio: 4 / 3; border-radius: var(--r); overflow: hidden; background: var(--surface); }
.intro__art img { width: 100%; height: 100%; object-fit: cover; }
.intro__copy { display: grid; gap: 20px; justify-items: start; }
.intro__copy p { margin: 0; font-size: 18px; line-height: 1.55; max-width: 44ch; }
.rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rules li { display: grid; grid-template-columns: 28px 1fr; gap: 10px; align-items: start; font-size: 16px; }
.rules b { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--surface-2); font: 500 13px/1 var(--font-display); }
.best { font-size: 14px; color: var(--muted); }

@media (max-width: 820px) {
  .intro { grid-template-columns: 1fr; gap: 28px; }
  .bar { padding: 0 16px; gap: 12px; }
  .bar__sep, .bar__game { display: none; }
}
@media (max-width: 560px) {
  .bar__home span, .dots { display: none; }
  .bar { gap: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
