/* Fonts (OFL, files and licences in tools/frontend/fonts/): Chakra Petch for headings and names, its cut corners match the
   game logo's lettering; Share Tech Mono for what the game's HUD prints (prices, keys, stats, small labels); Overpass,
   drawn from US highway signs, for reading text. */
@font-face { font-family: Chakra; font-weight: 600; src: url("/_a/chakra-petch-600.4d6d5f0b31.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: Chakra; font-weight: 700; src: url("/_a/chakra-petch-700.3c2433eb16.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: HudMono; src: url("/_a/share-tech-mono.73b87eb7b0.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: Overpass; font-weight: 400; src: url("/_a/overpass-400.f835f9c7e1.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: Overpass; font-weight: 700; src: url("/_a/overpass-700.6a855eb539.woff2") format("woff2"); font-display: swap; }

:root {
  /* The game's map at night: dark streets for the ground, the HUD's navy bar for panels. One accent, the mint of
     "ZOMBIES" in the logo, marks what you can click and where you are: links, the current sidebar row, the store button,
     focus. Headings are white like "REAL". Money yellow stays on prices only, as in the game's HUD; the other colours
     name kinds of things on list pages. */
  --ground: #0f1217;   /* the streets */
  --bar-bg: #0a0c10;
  --panel: #161a21;    /* the HUD bar: sidebar, cards, tables */
  --panel-hi: #1e232c;
  --panel-lo: #12151b;
  --well: #0b0d11;
  --edge: #252b35;     /* quiet 1px rule */
  --line: #3a4250;     /* frame of a control at rest */
  --ink: #e4e1d8;
  --ink-hi: #ffffff;
  --ink-dim: #b3ad9e;
  --ink-mute: #8f8a7d;
  --accent: #5fe3b4;   /* safe-zone mint: headings, frames, current place, focus */
  --accent-hi: #9cf3d2;
  --cash: #ffd35c;     /* money: prices only */
  --amber: #e8b04a;    /* skill points, level-up costs */
  --go: #3fc46b;       /* READY, confirm */
  --go-bg: #12301d;
  --stop: #ff6a5c;     /* danger, refunds */
  --khaki: #b9ad8e;    /* the map's buildings: a group tone on list pages */
  --blue: #4f8fd6;     /* the map's water */
  --violet: #9a77e0;   /* the infection haze */
  --rule: 1px;
  --cut: 10px;         /* the corner a control has cut off, like the logo's letters */
  --display: Chakra, "Arial Narrow", sans-serif;
  --mono: HudMono, ui-monospace, monospace;
  --sans: Overpass, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Type scale: every font declaration in style/ uses one of these (check.py, type-scale). */
  --f-label: 12px/16px var(--mono);   /* small caps labels over a group or column */
  --f-hud: 15px/22px var(--mono);     /* prices, keys, stats, table numbers */
  --f-name: 600 20px/26px var(--display);
  --f-h3: 600 22px/28px var(--display);
  --f-h2: 700 30px/36px var(--display);
  --f-h1: 700 44px/48px var(--display);
  --f-body: 16px/26px var(--sans);
  --f-small: 14px/22px var(--sans);
  /* Spacing steps: 4, 8, 12, 16, 24, 32, 48. */
  --bar: 64px; /* the top bar's height: everything that sticks or scrolls to an anchor clears it */
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--ground); color: var(--ink); font: var(--f-body); -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--bar) + 16px);
  scrollbar-color: var(--line) var(--bar-bg); }
body { margin: 0; min-height: 100vh; }
::selection { background: var(--accent); color: var(--ground); }
a { color: var(--accent-hi); text-decoration-color: color-mix(in srgb, var(--accent) 60%, transparent); text-underline-offset: 3px; }
a:hover { color: var(--ink-hi); text-decoration-color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3, h4, p, ul, ol, dl, dd { margin: 0; padding: 0; }
h1, h2, h3 { font-weight: 400; }
ul, ol { list-style: none; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
[hidden] { display: none !important; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 40; background: var(--accent); color: var(--ground); padding: 8px 12px; }
.skip:focus { left: 8px; }
/* Grey HUD section label (COMBAT, AMMO, DEPLOY). */
.hud-lbl { font: var(--f-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-dim); }
/* A key the game binds, written as the HUD writes it: [B]. */
.key { font: var(--f-hud); color: var(--ink-dim); white-space: nowrap; }

/* Controls are framed boxes with the lower right corner cut off, the way the logo cuts its letters. The frame is the
   element's own fill (--f), the face a layer 1px inside it (--b), so the cut edge is drawn too; a focused control gets a
   2px frame because the clip would hide an outline. Every framed control on the site uses these lines. */
.btn, .related a, .ac.can-open, .menu-link {
  --f: var(--line); --b: var(--panel-hi); position: relative; isolation: isolate; background: var(--f); border: 0;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%); }
.btn::before, .related a::before, .ac.can-open::before, .menu-link::before {
  content: ""; position: absolute; z-index: -1; inset: var(--rule); background: var(--b);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--cut) + .4px), calc(100% - var(--cut) + .4px) 100%, 0 100%); }
:is(.btn, .related a, .menu-link):hover { --f: var(--accent); color: var(--ink-hi); }
:is(.btn, .related a, .ac.can-open, .menu-link):focus-visible, .ac.can-open:focus-within { outline: 0; --f: var(--accent-hi); }
:is(.btn, .related a, .menu-link):focus-visible::before, .ac.can-open:focus-within::before { inset: 2px; }

.btn { display: inline-block; padding: 8px 24px 8px 16px; font: var(--f-name); color: var(--ink); text-decoration: none; white-space: nowrap; cursor: pointer; }
.btn:active { transform: translateY(1px); }
/* The main action (the store button): a solid mint plate with dark letters. */
.btn-main { --f: var(--accent); --b: var(--accent); color: var(--ground); }
.btn-main:hover { --f: var(--accent-hi); --b: var(--accent-hi); color: var(--ground); }
.btn-main:focus-visible { --f: var(--ink-hi); }

/* Top bar: stays on screen on every page and every width, like the game's bottom HUD bar. It holds search, the brand as the
   way home, the game version the data matches and the store button. Sections live in the sidebar only. */
.bar { position: sticky; top: 0; z-index: 20; height: var(--bar); display: flex; align-items: center; gap: 24px; padding: 0 32px 0 24px; background: var(--bar-bg); border-bottom: var(--rule) solid var(--line); }
.brand { flex: none; display: flex; align-items: baseline; gap: 12px; font: var(--f-h3); color: var(--ink-hi); text-decoration: none; white-space: nowrap; }
.brand span, .foot-brand span { color: var(--accent); }
.brand:hover { color: var(--ink-hi); }
.brand:hover span { color: var(--accent-hi); }
.brand, .foot-brand { font: var(--f-h3); }
.find { position: relative; }
.bar-find { flex: 1 1 0; max-width: 560px; }
.find input { width: 100%; height: 40px; padding: 0 12px; font: var(--f-small); color: var(--ink); background: var(--well); border: var(--rule) solid var(--line); border-radius: 0; caret-color: var(--accent); -webkit-appearance: none; appearance: none; }
.find input::placeholder { color: var(--ink-mute); }
.find input:hover { border-color: var(--ink-dim); }
.find input:focus-visible { outline-offset: 0; border-color: var(--accent); }
/* The key that jumps to the box, as the HUD writes keys; it leaves while the box is in use. */
.find kbd { position: absolute; right: 10px; top: 9px; font: var(--f-hud); color: var(--ink-mute); pointer-events: none; }
.find kbd::before { content: "["; } .find kbd::after { content: "]"; }
.find input:focus + kbd, .find input:not(:placeholder-shown) + kbd { display: none; }
.search-out:empty { display: none; }
.search-out { position: absolute; z-index: 5; left: 0; right: 0; top: calc(100% + 4px); max-height: min(60vh, 480px); overflow-y: auto; background: var(--panel); border: var(--rule) solid var(--line); box-shadow: 0 12px 24px rgb(0 0 0 / .45); text-align: left; }
.search-out a { display: flex; justify-content: space-between; gap: 8px; padding: 8px 12px; font: var(--f-small); color: var(--ink); text-decoration: none; }
.search-out a:hover, .search-out a:focus-visible { background: var(--panel-hi); outline: 0; box-shadow: inset 2px 0 0 var(--accent); }
.search-out small { font: var(--f-label); line-height: 22px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-dim); white-space: nowrap; }
.search-out .none { padding: 8px 12px; font: var(--f-small); color: var(--ink-dim); }
.bar-ver { margin-left: auto; font: var(--f-hud); color: var(--ink-dim); text-decoration: none; white-space: nowrap; }
.bar-ver b { font-weight: 400; color: var(--ink); }
/* Labels every page repeats. */
.bar-ver b::before { content: "Game "; color: var(--ink-dim); } .bar-ver span::before { content: " · data "; }
.bar-ver:hover, .bar-ver:hover b { color: var(--ink-hi); }
.bar-buy { flex: none; }
.bar-icon { flex: none; width: 44px; height: 44px; margin-left: auto; padding: 10px; border: 0; background: none; color: var(--ink); cursor: pointer; }
.bar-icon:hover { color: var(--accent-hi); }
.menu-link, .bar-icon { display: none; }

/* Sidebar sits flush against the left edge; the article and its list of contents are centred in what is left. */
.app { display: grid; grid-template-columns: 264px minmax(0, 1fr); align-items: start; }
.col { min-width: 0; }
#main { padding: 32px 32px 0; }
.page { max-width: 1120px; margin: 0 auto; }
.page.has-rail { max-width: 1416px; display: grid; grid-template-columns: minmax(0, 1120px) 256px; gap: 40px; align-items: start; }

/* The sidebar, as on slotbound.net: section labels over plain rows of icon, name and count. A row lights on hover; the
   page being read is a mint plate with the logo's cut corner. Only the rows are links, so only they react. */
.side { position: sticky; top: var(--bar); height: calc(100vh - var(--bar)); overflow: hidden auto; padding: 24px 16px 32px; background: var(--panel); border-right: var(--rule) solid var(--edge); scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.side-box + .side-box { margin-top: 24px; }
.side-h { font: var(--f-label); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; }
.side ul { display: grid; gap: 2px; }
.side li { display: flex; align-items: center; position: relative; margin: 0 -8px; }
.side li > a, .side li > span { flex: 1; display: flex; align-items: center; gap: 12px; min-height: 36px; padding: 0 48px 0 8px; font: var(--f-small); text-decoration: none; color: var(--ink); }
.side li > a:hover { background: var(--panel-hi); color: var(--ink-hi); }
.side li > a:hover .nav-ico { color: var(--accent); }
/* A page not written yet: plain text, it is not a link. */
.side li > span { color: var(--ink-mute); }
.side li > b { position: absolute; right: 8px; font: var(--f-hud); font-weight: 400; color: var(--ink-dim); pointer-events: none; }
.side li:has(> a[aria-current]) { background: var(--accent); clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%); }
.side li > a[aria-current] { font-weight: 700; color: var(--ground); background: none; }
.side li > a[aria-current] .nav-ico, .side li > a[aria-current] + b { color: var(--ground); }
.nav-ico { flex: 0 0 20px; display: flex; color: var(--ink-dim); }
.nav-ico svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.side-close, .rail-close, .scrim, .toc-tab { display: none; }

/* List of contents: no frame, it belongs to the article. */
.rail { position: sticky; top: calc(var(--bar) + 32px); }
.rail-box { max-height: calc(100vh - var(--bar) - 48px); overflow: hidden auto; padding: 16px 16px 16px 20px; background: var(--panel); scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.rail .side-h { margin-bottom: 12px; }
.rail .side-h-next { margin-top: 24px; }
.toc-guide { margin: 0; padding: 0; list-style: none; }
.toc-guide a { display: block; margin-left: -17px; padding: 8px 0 8px 16px; border-left: 2px solid transparent; font: var(--f-small); color: var(--ink-dim); text-decoration: none; }
.toc-guide a:hover { color: var(--ink); }
.toc-guide a > b { float: right; margin-left: 8px; font: var(--f-label); font-weight: 400; color: var(--ink-dim); line-height: 22px; }
.toc > li + li { margin-top: 4px; }
.toc a { text-decoration: none; }
.toc > li > a { display: flex; align-items: center; min-height: 36px; margin-left: -17px; padding-left: 16px; border-left: 2px solid transparent; font: var(--f-hud); color: var(--ink); }
.toc > li > a:hover { color: var(--ink-hi); }
.toc > li > a > b { margin-left: auto; font: var(--f-hud); font-weight: 400; color: var(--ink-dim); }
.toc ol { padding: 4px 0 12px; }
/* With JS only the group being read is open; the rest fold to one line each. */
.js .toc > li:not(.open) > ol { display: none; }
.toc ol a { display: flex; align-items: center; gap: 12px; min-height: 36px; margin-left: -17px; padding-left: 16px; border-left: 2px solid transparent; font: var(--f-small); color: var(--ink-dim); }
.toc-ico { flex: 0 0 32px; height: 32px; display: flex; align-items: flex-end; justify-content: center; overflow: hidden; }
.toc-ico img { flex: none; max-width: none; }
.toc-flat .toc-ico { margin-right: 12px; align-items: center; }
.toc ol a:hover { color: var(--ink); }
/* The part being read: a mint edge on the line of contents. */
.toc ol a.is-here, .toc > li > a.is-here, .toc-guide a.is-here { color: var(--ink-hi); border-left-color: var(--accent); }

.foot { margin-top: 64px; border-top: var(--rule) solid var(--edge); background: var(--bar-bg); }
.foot-in { max-width: 1416px; margin: 0 auto; padding: 32px; display: grid; grid-template-columns: minmax(0, 2fr) repeat(2, minmax(0, 1fr)); gap: 32px; font: var(--f-small); color: var(--ink-dim); }
.foot-about p { max-width: 60ch; }
.foot-brand { font: var(--f-name); color: var(--ink-hi); margin-bottom: 8px; }
.foot-h { font: var(--f-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-dim); margin-bottom: 8px; }
.foot li { padding: 4px 0; }
.foot a { color: var(--ink); text-decoration: none; }
.foot a:hover { color: var(--accent-hi); text-decoration: underline; }
.foot li > span { color: var(--ink-mute); }

/* Group accent. A list page names a tone per group; the tones are the map's colours, never money, selection or go. */
[class*="g-"] > i, .grade-head h2 > i { display: inline-block; width: 11px; height: 11px; margin-right: 12px; background: var(--g); vertical-align: 2px; }
.g-khaki { --g: var(--khaki); } .g-blue { --g: var(--blue); } .g-violet { --g: var(--violet); }
.g-green { --g: var(--go); } .g-red { --g: var(--stop); } .g-white { --g: var(--ink); } .g-orange { --g: var(--amber); }

/* No room for the list of contents: it becomes a drawer on the right, opened from a small tab of ticks on the right edge. */
@media (max-width: 1551px) {
  .page.has-rail { max-width: 1120px; grid-template-columns: minmax(0, 1fr); }
  .rail { display: none; }
  .js .rail { display: block; position: fixed; z-index: 30; inset: 0 0 0 auto; width: min(288px, 86vw); padding: 16px 12px 16px 8px; background: var(--panel); border-left: var(--rule) solid var(--line); transform: translateX(105%); visibility: hidden; }
  .js.toc-open .rail { transform: none; visibility: visible; }
  .js .rail-box { max-height: calc(100vh - 96px); border-left: 0; }
  .js .rail-close { display: block; margin: 0 0 16px auto; }
  /* A solid tab, so its ticks never read as part of the card under it. */
  .js .toc-tab { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; position: fixed; z-index: 20; right: 0; top: 38vh; padding: 8px 8px 8px 12px; background: var(--bar-bg); border: var(--rule) solid var(--line); border-right: 0; cursor: pointer; }
  .toc-tab i { display: block; width: 10px; height: 4px; background: var(--ink-dim); opacity: .55; transition: width .12s ease-out; }
  .toc-tab i.on { width: 20px; background: var(--accent); opacity: 1; }
  .toc-tab:hover i, .toc-tab:focus-visible i { opacity: 1; }
  .js.toc-open .scrim, .js.nav-open .scrim { display: block; position: fixed; inset: 0; z-index: 25; width: 100%; border: 0; padding: 0; background: rgb(15 17 22 / .72); cursor: pointer; }
}
/* Sidebar becomes a drawer. Without JS it stays in the page, after the article. */
@media (max-width: 1279px) {
  .bar { gap: 16px; padding: 0 16px; }
  .bar-ver { display: none; }
  .menu-link { display: block; flex: none; }
  .bar-buy { margin-left: auto; }
  .app { display: flex; flex-direction: column; }
  .col { width: 100%; }
  #main { padding: 24px 16px 0; }
  .side { position: static; height: auto; order: 2; border-right: 0; border-top: var(--rule) solid var(--edge); }
  .js .side { position: fixed; z-index: 30; inset: 0 auto 0 0; width: min(304px, 86vw); height: auto; border-top: 0; border-right: var(--rule) solid var(--line); transform: translateX(-105%); visibility: hidden; }
  .js.nav-open .side { transform: none; visibility: visible; }
  .js .side-close { display: block; margin: 0 0 8px auto; }
  .foot-in { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); padding: 24px 16px; gap: 24px 16px; }
  .foot-about { grid-column: 1 / -1; }
}
/* Drawers animate only after the first tap, so nothing slides during page load. */
.anim .side, .anim .rail { transition: transform .18s cubic-bezier(.2, .8, .2, 1), visibility 0s .18s; }
.anim.nav-open .side, .anim.toc-open .rail { transition: transform .18s cubic-bezier(.2, .8, .2, 1); }
/* Narrow bars: the store button goes first, then the search box folds into a button that opens it under the bar. */
@media (max-width: 1023px) { .bar-buy { display: none; } .bar-find { margin-left: auto; } }
@media (max-width: 719px) {
  .bar { gap: 8px; }
  .js .bar-icon { display: block; }
  /* Phones: the ticks stay inside the 16px page gutter, clear of the cards' right-aligned numbers. */
  .js .toc-tab { padding: 8px 2px 8px 4px; background: none; border: 0; }
  .toc-tab i { width: 6px; } .toc-tab i.on { width: 12px; }
  .bar-find { display: none; position: absolute; left: 0; right: 0; top: 100%; max-width: none; margin: 0; padding: 8px 16px; background: var(--bar-bg); border-bottom: var(--rule) solid var(--edge); }
  .find-open .bar-find { display: block; }
  .bar-find kbd { display: none; }
  .bar-find .search-out { left: 16px; right: 16px; top: calc(100% - 4px); }
}
@media (max-width: 480px) { .brand { font: var(--f-name); gap: 8px; } }
/* The game name is long: below 420px "Wiki" would push the Menu button off screen. */
@media (max-width: 419px) { .brand span { display: none; } }
@media (prefers-reduced-motion: reduce) { .anim .side, .anim .rail, .toc-tab i { transition: none; } .btn:active { transform: none; } }

/* Page header (crumbs, H1, lead, figures) and group headings, shared by every template. */
/* An article's header sits on official game art, faded into the ground, the way a wiki.gg page sits on its game's art.
   The image covers the top of the main column; text stays on the dark half so it keeps its contrast. */
#main { position: relative; }
.head-art { position: absolute; z-index: 0; top: 0; left: 0; width: 100%; height: 400px; object-fit: cover; object-position: 50% 40%; opacity: .4;
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent 100%); mask-image: linear-gradient(to bottom, #000 30%, transparent 100%); pointer-events: none; }
.doc-head > :not(.head-art) { position: relative; z-index: 1; }
.doc-head.has-art { padding-top: 64px; min-height: 304px; }
.has-art .lead { text-shadow: 0 1px 2px rgb(0 0 0 / .8); }
.crumbs { font: var(--f-small); color: var(--ink-dim); margin-bottom: 12px; }
.crumbs i { font-style: normal; margin: 0 4px; }
.crumbs a { color: var(--ink-dim); } .crumbs a:hover { color: var(--ink-hi); }
.doc h1 { font: var(--f-h1); letter-spacing: -.01em; color: var(--ink-hi); text-wrap: balance; text-shadow: 0 2px 8px rgb(0 0 0 / .6); }
.lead { margin-top: 16px; color: var(--ink); }
/* Plain figures, no frame: they are not clickable. Grey label over a number in the HUD's type. */
.facts { display: flex; flex-wrap: wrap; gap: 12px 32px; margin-top: 24px; }
.facts > div + div { padding-left: 32px; border-left: var(--rule) solid var(--edge); }
.facts dt { font: var(--f-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-dim); }
.facts dd { font: var(--f-name); color: var(--ink-hi); margin-top: 4px; }
.facts dd a { display: inline-block; padding: 10px 8px; margin: -10px -8px; color: var(--ink-hi); }
.doc-meta { margin-top: 16px; font: var(--f-small); color: var(--ink-dim); }

.grade { margin-top: 48px; scroll-margin-top: 16px; }
.grade-head { padding-bottom: 12px; margin-bottom: 16px; border-bottom: var(--rule) solid var(--line); }
.grade-head h2 { font: var(--f-h2); color: var(--ink-hi); }
.grade-head p { margin-top: 4px; font: var(--f-small); color: var(--ink-dim); }

@media (max-width: 999px) { .doc h1 { font: var(--f-h2); } .doc-head.has-art { padding-top: 40px; min-height: 240px; } .head-art { height: 320px; } }
@media (max-width: 639px) { .facts { gap: 12px 16px; } .facts > div + div { padding-left: 16px; } .grade-head h2 { font: var(--f-h3); } }

/* Shared blocks for list, article and home pages. */
.block { margin-top: 48px; scroll-margin-top: 16px; }
/* Section heads in white over a quiet rule, as slotbound.net sets them; the accent stays on what can be clicked. */
.block > h2 { font: var(--f-h2); color: var(--ink-hi); padding-bottom: 12px; margin-bottom: 16px; border-bottom: var(--rule) solid var(--line); text-wrap: balance; }
.note { font: var(--f-small); color: var(--ink-dim); margin-bottom: 12px; }

/* Tables read like a game database (tarkov.dev): khaki-grey text on the HUD panel, a darker head row of small mono
   labels, names bright, numbers right-aligned in the HUD's mono, money in yellow; a row lights up under the pointer. */
.table-wrap { overflow-x: auto; margin-top: 24px; background: var(--panel); }
.block .table-wrap { margin-top: 0; }
.data { width: 100%; border-collapse: collapse; font: var(--f-small); font-variant-numeric: tabular-nums; }
.data th, .data td { padding: 12px 16px; text-align: left; vertical-align: top; border-bottom: var(--rule) solid var(--edge); }
.data tbody tr:last-child > * { border-bottom: 0; }
.data thead th { font: var(--f-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-dim); background: var(--well); white-space: nowrap; border-bottom-color: var(--line); }
.data td { color: var(--ink-dim); }
.data tbody tr:hover > * { background: var(--panel-hi); }
/* Row names wrap so a long one ("Boston and San Francisco level 1") never pushes the numbers out of the box. */
.data tbody th { min-width: 9em; font: var(--f-small); font-weight: 700; color: var(--ink-hi); }
.data tbody th a { color: inherit; text-decoration: none; }
.data tbody th a:hover { color: var(--accent-hi); }
.data .num { font: var(--f-hud); text-align: right; white-space: nowrap; }
.data .cash { color: var(--cash); }
.data thead .num { font: var(--f-label); }
@media (max-width: 639px) { .data th, .data td { padding: 8px; } .data thead th { white-space: normal; } .data tbody th { min-width: 6em; } }
.status { display: inline-block; padding: 0 8px; font: var(--f-label); line-height: 22px; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; color: var(--ink-dim); border: var(--rule) solid currentColor; }
.st-yes { color: var(--go); } .st-planned { color: var(--amber); } .st-no { color: var(--stop); }

.shot { margin: 24px 0 0; }
.shot img { display: block; width: 100%; height: auto; }
.shot figcaption { margin-top: 8px; font: var(--f-small); color: var(--ink-dim); }

.prose p + p, .prose ul, .prose ul + p, .prose p + .shot { margin-top: 12px; }
.prose ul { list-style: square; padding-left: 20px; }
.prose li + li { margin-top: 8px; }
.prose ol { list-style: decimal; padding-left: 24px; margin-top: 12px; }
.prose h3 { font: var(--f-h3); color: var(--ink-hi); margin-top: 32px; }
.prose h3 + p, .prose h3 + ul, .prose h3 + ol, .prose h3 + .table-wrap { margin-top: 8px; }
.prose p + .table-wrap, .prose .table-wrap + p { margin-top: 12px; }
/* Keys: written the way the HUD writes them, [B]. */
.prose kbd { font: var(--f-hud); color: var(--ink-hi); white-space: nowrap; }
.prose kbd::before { content: "["; color: var(--ink-dim); } .prose kbd::after { content: "]"; color: var(--ink-dim); }
.prose code { font: var(--f-hud); padding: 0 4px; background: var(--panel-lo); color: var(--ink); overflow-wrap: anywhere; }
.log-entry { margin-top: 24px; }
.log-entry h3 { margin-top: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.log-entry time { font: var(--f-small); color: var(--ink-dim); }
.prose li::marker { color: var(--ink-dim); }
.faq > div + div { margin-top: 24px; }
.faq dt { font: var(--f-body); font-weight: 700; color: var(--ink-hi); }
.faq dd { margin-top: 4px; color: var(--ink); }
.toc-flat > li + li { margin-top: 4px; }
.toc.toc-flat > li > a { font: var(--f-small); color: var(--ink-dim); padding: 4px 0 4px 16px; margin-left: -17px; border-left: 2px solid transparent; }
.toc.toc-flat > li > a:hover { color: var(--ink); }
.toc.toc-flat > li > a.is-here { color: var(--ink-hi); border-left-color: var(--accent); }

/* The guide under a list: it starts on its own panel edge, so the reference above reads as finished. */
.guide-part { margin-top: 64px; padding-top: 32px; border-top: var(--rule) solid var(--line); }
.guide-part .part-kicker { display: none; }
.guide-part > .block:first-of-type { margin-top: 0; }
.related ul { display: flex; flex-wrap: wrap; gap: 8px; }
.related a { display: inline-block; padding: 10px 24px 10px 16px; font: var(--f-small); font-weight: 700; color: var(--ink); text-decoration: none; }

.is-empty { display: none; }

/* Narrow screens: heads step down one size each, H2 still above H3. */
@media (max-width: 999px) { .block > h2 { font: var(--f-h3); } .prose h3 { font: var(--f-name); } }

/* List pages: the price strip, the rules, the search box and one card per entity. */

/* The price strip copies the game's deploy bar: grey labels over slot rows, key, name and the price in yellow. Each row jumps to its card. */
.deploy { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 12px; margin-top: 32px; padding: 16px; background: var(--panel); }
.deploy .hud-lbl { margin-bottom: 8px; }
.deploy ul + .hud-lbl { margin-top: 16px; }
.deploy ul { display: grid; gap: 4px; }
.deploy a { display: flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 12px; font: var(--f-hud); color: var(--ink); text-decoration: none; background: var(--panel-hi); border: var(--rule) solid var(--edge); }
.deploy a:hover { color: var(--ink-hi); border-color: var(--ink-dim); }
.deploy .dn { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.deploy b { font-weight: 400; white-space: nowrap; }
.cash { color: var(--cash); } .amb { color: var(--amber); }
.is-locked { color: var(--ink-mute); }
.legend { margin-top: 12px; font: var(--f-small); color: var(--ink-dim); }

.rules dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; }
.rules dl > div { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 12px; padding: 12px 0; border-top: var(--rule) solid var(--edge); }
.rules dt { font: var(--f-hud); color: var(--ink-hi); }
.rules dd { font: var(--f-small); color: var(--ink); }
.rules kbd { font: var(--f-hud); color: var(--ink-hi); }
.rules kbd::before { content: "["; color: var(--ink-dim); } .rules kbd::after { content: "]"; color: var(--ink-dim); }

.list-tools { margin-top: 32px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 12px; }
.tools-n { grid-column: 1 / -1; font: var(--f-small); color: var(--ink-dim); min-height: 22px; }
.tool-search input { width: 100%; height: 44px; padding: 0 12px; font: var(--f-small); color: var(--ink); background: var(--well); border: var(--rule) solid var(--line); border-radius: 0; caret-color: var(--accent); -webkit-appearance: none; appearance: none; }
.tool-search input::placeholder { color: var(--ink-mute); }
.tool-search input:hover, .pick-btn:hover { border-color: var(--ink-dim); }
.tool-search input:focus-visible { outline-offset: 0; border-color: var(--accent); }
.pick { position: relative; }
.pick-btn { position: relative; display: flex; align-items: center; gap: 8px; height: 52px; padding: 0 40px 0 12px; font: var(--f-small); color: var(--ink); cursor: pointer;
  background: var(--well); border: var(--rule) solid var(--panel-hi); border-radius: 0; }
.pick-btn span { color: var(--ink-dim); }
.pick-btn b { font-weight: 400; }
/* A stepped arrow; it turns over while the menu is open. */
.pick-btn::after { content: ""; position: absolute; right: 16px; top: 22px; width: 12px; height: 8px; background: var(--ink-dim);
  clip-path: polygon(0 0, 100% 0, 100% 25%, 83% 25%, 83% 50%, 67% 50%, 67% 75%, 33% 75%, 33% 50%, 17% 50%, 17% 25%, 0 25%); }
.pick-btn[aria-expanded="true"]::after { transform: scaleY(-1); }
.pick.is-set .pick-btn { border-color: var(--accent); }
.pick.is-set .pick-btn b { color: var(--accent); }
.pick-menu { position: absolute; z-index: 10; top: calc(100% + 4px); left: 0; min-width: 100%; display: grid; padding: 4px;
  background: var(--panel); border: var(--rule) solid var(--line); box-shadow: 0 12px 24px rgb(0 0 0 / .45); }
.pick-menu button { display: flex; align-items: center; gap: 8px; padding: 8px 12px 8px 8px; font: var(--f-small); color: var(--ink); text-align: left; white-space: nowrap;
  background: none; border: 0; cursor: pointer; }
.pick-menu button::before { content: ""; flex: none; width: 8px; height: 8px; }
.pick-menu button[aria-checked="true"] { color: var(--accent); }
.pick-menu button[aria-checked="true"]::before { background: var(--accent); }
.pick-menu button:hover, .pick-menu button:focus-visible { background: var(--panel-hi); outline: 0; }
.pick-menu small { margin-left: auto; padding-left: 16px; font: var(--f-label); color: var(--ink-dim); }

.list-tools ~ .grade:first-of-type { margin-top: 16px; }

.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-items: start; }
.it { scroll-margin-top: 16px; }
.sheet { width: min(600px, calc(100% - 32px)); max-height: calc(100vh - 64px); max-height: calc(100dvh - 64px); overflow: auto; padding: 32px 36px 36px; color: var(--ink);
  background: var(--panel); border: var(--rule) solid var(--line); }
.sheet::backdrop { background: rgb(14 16 17 / .72); }
.sheet[open] { animation: sheet-in .16s ease-out; }
@keyframes sheet-in { from { opacity: 0; transform: translateY(8px); } }
.sheet-top { display: grid; grid-template-columns: 72px minmax(0, 1fr) 40px; gap: 16px; align-items: center; }
/* The name and close button stay in view while a long sheet scrolls. */
.sheet-top { position: sticky; z-index: 1; top: -32px; margin-top: -16px; padding: 16px 0 8px; background: var(--panel); }
.sheet-top:not(:has(.it-ico)) { grid-template-columns: minmax(0, 1fr) 40px; }
.sheet-top .it-ico { grid-area: auto; }
.sheet-name { font: var(--f-name); }
.sheet-kind { margin-top: 4px; font: var(--f-small); color: var(--ink-dim); }
.sheet-kind::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; background: var(--g); box-shadow: 0 0 0 2px var(--ink); vertical-align: 1px; }
.sheet-x { align-self: start; width: 40px; height: 40px; padding: 0; cursor: pointer; background: none; border: var(--rule) solid var(--panel-hi); }
.sheet-x::before { content: "×"; font: var(--f-name); color: var(--ink); }
.sheet-x:hover { border-color: var(--ink); }
.sheet-levels { margin-top: 24px; }
.sheet-levels > div { display: grid; grid-template-columns: 80px minmax(0, 1fr); gap: 12px; padding: 8px 0; border-top: var(--rule) solid var(--panel-hi); }
.sheet-levels dt { font: var(--f-name); color: var(--ink-dim); }
.sheet-levels dd { font: var(--f-small); }
/* One fact per row: a long value (a skill, an unlock chain) wraps in its own row instead of squeezing a column beside it. */
.sheet-facts { margin-top: 16px; }
.sheet-facts > div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; padding: 8px 0; border-top: var(--rule) solid var(--panel-hi); }
.sheet-facts dt { font: var(--f-label); color: var(--ink-dim); padding-top: 2px; }
.sheet-bar { display: flex; height: 12px; margin-top: 24px; box-shadow: 0 0 0 2px var(--ink); }
.sheet-bar > span { min-width: 2px; background: var(--g); }
.sheet-odds { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 12px; }
.sheet-odds .odd { color: var(--ink); }
.sheet-odds .odd::before { box-shadow: 0 0 0 2px var(--ink); }
.sheet-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; margin-top: 24px; }
.sheet-stats > div { padding: 8px 12px; background: var(--panel-lo); }
.sheet-stats dt { font: var(--f-label); color: var(--ink-dim); }
.sheet-stats dd { font: var(--f-name); }
.sheet-facts dd { font: var(--f-small); }

@media (max-width: 999px) {
  .rules dl { grid-template-columns: minmax(0, 1fr); }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .deploy { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  .rules dl > div { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .cards { grid-template-columns: minmax(0, 1fr); }
  .deploy { grid-template-columns: minmax(0, 1fr); }
  .list-tools { grid-template-columns: minmax(0, 1fr); }
  /* On phones the detail card comes up from the bottom edge. */
  .sheet { width: 100%; max-width: none; margin: auto 0 0; max-height: 88vh; max-height: 88dvh; padding: 28px 24px 32px; }
  .sheet-top { top: -28px; }
  .tool-search input, .find input { font: var(--f-body); }  /* under 16px, iOS zooms into a field on focus */
  .sheet[open] { animation-name: sheet-up; animation-duration: .2s; }
}
@keyframes sheet-up { from { transform: translateY(100%); } }
@media (prefers-reduced-motion: reduce) { .sheet[open] { animation: none; } }

/* /units: each unit is the game's unit panel. Name and level pips on top, grey section labels, stats right-aligned with a
   thin accent bar, the level ladder at the foot. The panel is not a control, so it has no frame; it takes the accent
   "selected" frame when the price strip jumps to it. */
.unit, .bcard, .tool { display: flex; flex-direction: column; gap: 12px; padding: 16px; background: var(--panel); }
.unit:target, .bcard:target, .tool:target { box-shadow: 0 0 0 1px var(--accent), inset 0 0 0 1px var(--accent); }
.u-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-bottom: 12px; border-bottom: var(--rule) solid var(--edge); }
.u-head h3 { font: var(--f-name); color: var(--ink-hi); }
.u-head .key { margin-right: 4px; }
.u-lv { flex: none; display: flex; align-items: center; gap: 8px; font: var(--f-hud); color: var(--ink-dim); }
.pips { display: flex; gap: 4px; }
.pips i { width: 11px; height: 11px; border: var(--rule) solid var(--ink-dim); transition: background-color .16s ease-out; }
.pips i.on { background: var(--ink-hi); border-color: var(--ink-hi); }

.u-cost { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.u-price { font: var(--f-name); font-weight: 400; color: var(--cash); text-align: right; }
.u-price.is-locked { color: var(--ink-mute); }
.tool .u-price, .tool .u-head h3 { font: var(--f-hud); }
.u-note { margin-top: -8px; font: var(--f-small); color: var(--ink-dim); }
.u-text { margin: 0; padding-left: 12px; border-left: var(--rule) solid var(--line); font: var(--f-small); color: var(--ink); }
.u-text p::before { content: "“"; } .u-text p::after { content: "”"; }

/* Section labels inside the panel are in the accent over an accent hairline, as the game's unit panel draws COMBAT, AMMO and INFO. */
.l-combat, .l-ammo, .l-level { display: flex; align-items: center; gap: 8px; margin-bottom: -4px; padding-top: 4px; color: var(--accent-hi); }
.l-combat::after, .l-ammo::after, .l-level::after { content: ""; order: 1; flex: 1; height: 1px; background: color-mix(in srgb, var(--accent) 55%, transparent); }
.l-combat .seen { order: 2; }
.l-combat::before { content: "Combat"; } .l-combat[data-at]::before { content: "Combat at level " attr(data-at); }
.l-ammo::before { content: "Ammo"; } .l-level::before { content: "Level up"; }
.l-price { display: flex; flex-direction: column; gap: 4px; }
.l-price::before { content: "Price"; }
/* Where a value was read; the legend under the price strip spells the tags out. */
.seen { font: var(--f-label); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-dim); white-space: nowrap; }
.seen::before { display: inline-block; width: 5px; height: 5px; margin-right: 8px; vertical-align: 2px; background: var(--ink-mute); content: ""; }
.s-after::after { content: "Seen 18 Nov"; } .s-before::after { content: "Before 16 Nov"; } .s-patch::after { content: "16 Nov notes"; }
.legend .seen::after { content: none; }
.u-stats > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 0 12px; padding: 4px 0 8px; }
.u-stats dt { font: var(--f-hud); color: var(--ink); }
.u-stats dt small { display: block; font: var(--f-small); color: var(--ink-dim); }
.u-stats dd { font: var(--f-hud); color: var(--ink-hi); text-align: right; white-space: nowrap; }
/* The HUD's stat bar: share of the highest value on the page. */
.u-bar { grid-column: 1 / -1; height: 3px; margin-top: 4px; background: var(--panel-lo); position: relative; }
.u-bar::before { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--accent); transition: width .24s cubic-bezier(.2, .8, .2, 1); }
.u-ammo { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.u-ammo dt { font: var(--f-small); color: var(--ink-dim); }
.u-ammo dd { font: var(--f-hud); color: var(--ink-hi); }
/* A value that just changed with the level flashes the go colour once. */
.u-stats dd.is-new, .u-ammo dd.is-new { animation: lv-new .6s ease-out; }
@keyframes lv-new { from { color: var(--go); } }

/* The level ladder: one row per level, like the panel's "Lv2: 3x Damage" line beside its Level Up button. */
.u-ladder { display: grid; gap: 4px; }
.u-ladder li > button, .u-ladder li { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 8px; }
.u-ladder li > button { width: 100%; min-height: 36px; padding: 0 12px; text-align: left; color: var(--ink); background: var(--panel-hi); border: var(--rule) solid var(--edge); cursor: pointer; font: inherit; }
.u-ladder li:has(> button) { display: block; }
.u-ladder li:not(:has(> button)) { min-height: 36px; padding: 0 12px; border: var(--rule) dashed var(--edge); }
.u-ladder li > button:hover { border-color: var(--ink-dim); }
.u-ladder li > button[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.lv-n { font: var(--f-hud); color: var(--ink-dim); }
.lv-n::before { content: "Lv"; }
[aria-pressed="true"] .lv-n { color: var(--ink-hi); }
.lv-e { font: var(--f-small); color: var(--go); }
.lv-e.is-unseen { color: var(--ink-mute); }
.u-ladder b { font: var(--f-hud); font-weight: 400; white-space: nowrap; }
.u-ladder li.is-off .lv-n { color: var(--ink-mute); }

/* A panel with stats is about three short panels tall: it takes three rows, and the short ones fill the cells beside it. */
@media (min-width: 640px) { .cards.units { grid-auto-flow: row dense; align-items: stretch; } .cards.units > .has-stats { grid-row: span 3; } }
/* Battle cards and build tools: the same panel, shorter; a row shares one height. */
.cards.bcards, .cards.tools { align-items: stretch; }
.b-stats { display: flex; flex-wrap: wrap; gap: 0 16px; }
.cards.bcards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.b-sp { flex: none; font: var(--f-hud); font-weight: 400; color: var(--amber); }
.b-sp::after { content: " SP"; } .b-sp:empty { display: none; }

.b-uses::before { content: "Level 1: "; } .b-uses::after { content: " per battle"; }
.b-text { font: var(--f-small); color: var(--ink); }
.b-stats, .b-uses { font: var(--f-small); color: var(--ink-dim); }
.bcard .u-head, .tool .u-head { padding-bottom: 8px; }
.bcard .u-head h3 { font: var(--f-hud); }

@media (max-width: 1279px) { .cards.bcards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 999px) { .cards.bcards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639px) { .cards.bcards { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .u-bar::before, .pips i { transition: none; } .u-stats dd.is-new, .u-ammo dd.is-new { animation: none; } }

/* Home, the /guides index, the header's version line, the guide part, group markers. Joined after 40-pages.css in name order. */
/* Home. Each block covers one kind of page and has one way on to the full page.
   The hero sits on the game's key art (press kit), faded into the ground the way slotbound.net's hero sits on its art. */
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 24px; }
.hero { margin: -24px -32px 0; padding: 0 32px;
  background: linear-gradient(to top, var(--ground) 0, rgb(15 18 23 / .88) 45%, rgb(15 18 23 / .25) 100%), var(--panel) url("https://img.zombiesarentreal.net/s_5n4a2i00404o5m/band-key.9f7d83005f.webp") 50% 30% / cover no-repeat; }
.hero-in { max-width: 1120px; margin: 0 auto; padding: 136px 0 8px; }
.hero h1 { font: var(--f-h1); color: var(--ink-hi); text-shadow: 0 2px 12px rgb(0 0 0 / .7); }
.hero .lead { text-shadow: 0 1px 2px rgb(0 0 0 / .8); }
.hero .lead { max-width: 760px; }
.hero-find { max-width: 640px; margin-top: 24px; }
.hero-find input { height: 56px; padding: 0 16px; font: var(--f-body); border-color: var(--line); }
.hero-find input:focus { border-color: var(--accent); }
.hero-more { display: flex; gap: 16px; margin-left: 8px; font: var(--f-small); }
.home > .block:first-child { margin-top: 32px; }
/* A heading with the way on to the full page at its right end. */
.row-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; font: var(--f-small); }
.block > .row-head { padding-bottom: 12px; margin-bottom: 16px; border-bottom: var(--rule) solid var(--panel-hi); }
.row-head h2 { font: var(--f-h2); color: var(--ink); }
.row-all { white-space: nowrap; } .row-all::after { content: " ›"; }
/* Page tiles: one per sidebar page, a press-kit crop over its name and the count its header states. */
.tile-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.tile { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: var(--ink); background: var(--panel); border: var(--rule) solid var(--line); }
.tile img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; filter: saturate(.85) brightness(.85); transition: filter .15s ease-out; }
.tile-cap { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 12px 16px; }
.tile:hover { color: var(--ink-hi); border-color: var(--accent); }
.tile:hover img { filter: none; }
.tile-name { font: var(--f-name); }
.tile-n { font: var(--f-label); color: var(--ink-dim); }
.tile-n::after { content: attr(data-n); }
.tile:active, .pick-card:active, .news:active { transform: translateY(var(--rule)); }
.news { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 8px 24px; padding: 16px 24px; text-decoration: none; color: var(--ink); background: var(--panel); border: var(--rule) solid var(--panel-hi); }
.news:hover { color: var(--ink); border-color: var(--accent); }
.news-date { font: var(--f-name); }
.news-go { font: var(--f-small); color: var(--accent); white-space: nowrap; } .news-go::after { content: " ›"; }
.pick-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pick-card { display: flex; flex-direction: column; justify-content: space-between; gap: 8px; height: 100%; padding: 16px 20px; text-decoration: none; color: var(--ink); background: var(--panel); border: var(--rule) solid var(--panel-hi); border-left-color: var(--accent); }
.pick-card:hover { color: var(--ink); border-color: var(--accent); }
.pick-title { font: var(--f-name); }
.pick-page { font: var(--f-label); color: var(--ink-dim); } .pick-page::after { content: attr(data-page); }
/* Units by group: a card per group, its members as plain text under the name. */
.group-n { font: var(--f-label); color: var(--ink-dim); }
.group-grid .pick-card { justify-content: flex-start; }
.group-names { font: var(--f-small); color: var(--ink-dim); }
/* Campaign cities: not links, so no frame; a number in the HUD's mono before each name. */
.city-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 24px; margin: 0; padding: 0; list-style: none; counter-reset: city; }
.city-list li { counter-increment: city; display: flex; gap: 12px; align-items: baseline; padding: 8px 0; border-bottom: var(--rule) solid var(--panel-hi); }
.city-list li::before { content: counter(city, decimal-leading-zero); font: var(--f-label); color: var(--ink-dim); }
.home .facts { display: grid; grid-template-columns: repeat(2, minmax(0, max-content)); margin-top: 16px; }
.home .facts > div:nth-child(odd) { padding-left: 0; border-left: 0; }  /* two per row: a rule only between the pair */
.home .facts dd a { text-decoration: none; } .home .facts dd a:hover { color: var(--accent); }
/* The index of guides (/guides): one short list per page. */
.guide-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px 32px; }
.guide-cols .idx-h { font: var(--f-name); margin: 0 0 4px; } .guide-cols .idx-h a { color: var(--accent); text-decoration: none; } .guide-cols .idx-h a:hover { text-decoration: underline; }
.guide-cols ul { list-style: none; padding: 0; margin: 0; } .guide-cols li { padding: 4px 0; font: var(--f-small); }

@media (max-width: 1279px) { .hero { margin: -16px -16px 0; padding: 0 16px; } .hero-in { padding-top: 120px; } }
@media (max-width: 999px) {
  .pick-grid, .guide-cols, .tile-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .city-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .row-head h2 { font: var(--f-name); }
}
@media (max-width: 639px) {
  .pick-grid, .guide-cols { grid-template-columns: minmax(0, 1fr); }
  .tile-grid { gap: 8px; }
  .tile-cap { padding: 8px 12px; }
  .news { grid-template-columns: minmax(0, 1fr); }
  .hero h1 { font: var(--f-h2); }
  .hero-in { padding-top: 96px; }
}

/* Header line with the game version and data date. */
.doc-meta { margin-top: 16px; font: var(--f-small); color: var(--ink-dim); }

/* Hand-written part after the data: a clear break, then text beside its screenshot on wide screens. */
.guide-part { margin-top: 80px; padding-top: 32px; border-top: 4px solid var(--panel-hi); }
.part-kicker { font: var(--f-name); color: var(--ink-dim); }
.guide-part > .block:first-of-type { margin-top: 16px; }
.block.has-shot, .block.wide { max-width: none; }
.block.has-shot .shot { margin-top: 0; }
@media (min-width: 1280px) {
  .block.has-shot .block-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 44%); gap: 40px; align-items: start; }
  .faq { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 40px; }
  .faq > div + div { margin-top: 0; }
}
@media (max-width: 1279px) { .block.has-shot .shot { margin-top: 24px; } }
/* From 1552px the contents rail takes 296px; until the column is back near its 1120px cap, text beside a shot is too narrow for a five-column table. */
@media (min-width: 1552px) and (max-width: 1719px) {
  .has-rail .block.has-shot .block-body { display: block; }
  .has-rail .block.has-shot .shot { margin-top: 24px; }
}
.related ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.related a { display: inline-block; padding: 8px 12px; font: var(--f-small); color: var(--ink); text-decoration: none; background: var(--panel); border: var(--rule) solid var(--panel-hi); }
.related a:hover { border-color: var(--accent); }

/* Group markers on pages without tones: an icon (a list group's art) or one colour per tab (/updates groups). */
.grade-head h2 .g-ico { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; margin-right: 12px; vertical-align: middle; overflow: hidden; }
.g-tab-1 { --g: var(--khaki); } .g-tab-2 { --g: var(--go); } .g-tab-3 { --g: var(--blue); } .g-tab-4 { --g: var(--amber); }
.toc-ico { flex: 0 0 32px; height: 32px; margin-right: 8px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.toc-ico img { max-width: 32px; max-height: 32px; width: auto; height: auto; }

/* /updates: a timeline of cards, newest first. Version and date on the left, the changes on the right; each change carries its type. */
.upd-group .grade-head p a { color: var(--accent); }
.upd-line { position: relative; display: grid; gap: 12px; padding-left: 24px; }
.upd-line::before { content: ""; position: absolute; left: 4px; top: 8px; bottom: 8px; width: var(--rule); background: var(--panel-hi); }
.upd { position: relative; display: grid; grid-template-columns: 176px minmax(0, 1fr); gap: 8px 24px; padding: 16px 24px; background: var(--panel); scroll-margin-top: 16px; }
/* The timeline marker: a square on the line, hazard yellow for the latest update. */
.upd::before { content: ""; position: absolute; left: -24px; top: 24px; width: 12px; height: 12px; background: var(--panel-hi); box-shadow: 0 0 0 var(--rule) var(--ground); }
.upd.is-latest { box-shadow: inset 0 var(--rule) 0 var(--accent); }
.upd.is-latest::before { background: var(--accent); }
.upd:target { outline: var(--rule) solid var(--accent); }
.upd-kicker { font: var(--f-label); color: var(--ink-dim); text-transform: uppercase; letter-spacing: .04em; margin-bottom: 4px; }
.upd-meta h3 { font: var(--f-name); }
.upd-meta h3 a { color: var(--ink); }
.upd-meta h3 a:hover { color: var(--accent); }
.upd-meta time { display: block; margin-top: 4px; font: var(--f-small); color: var(--ink-dim); }
.upd-sum { font-weight: 700; color: var(--ink); }
.upd-list { margin-top: 12px; display: grid; gap: 8px; }
.upd-list li { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 12px; align-items: baseline; font: var(--f-small); }
/* Change types, each in its own colour. The type word and the 'On this wiki' label repeat on every card,
   so they come from CSS content, not the page text (page-content/README.md, tier 5 labels). */
.chg::after { content: attr(data-l); }
.upd-pages::before { content: "On this wiki"; margin-right: 4px; }
.chg { display: inline-block; text-align: center; padding: 0 6px; font: var(--f-label); line-height: 20px; color: var(--well); background: var(--g); }
.chg-new { --g: var(--khaki); } .chg-balance { --g: var(--blue); } .chg-change { --g: var(--violet); } .chg-fix { --g: var(--go); }
.upd-pages { margin-top: 12px; padding-top: 12px; border-top: var(--rule) solid var(--panel-lo); display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font: var(--f-label); color: var(--ink-dim); }
/* Older history folds away; the summary is a button, so it takes the frame. */
.upd-fold > summary { display: inline-block; margin-bottom: 16px; padding: 8px 12px; font: var(--f-small); color: var(--ink); background: var(--panel); border: var(--rule) solid var(--panel-hi); cursor: pointer; list-style: none; }
.upd-fold > summary::-webkit-details-marker { display: none; }
.upd-fold > summary::before { content: "▸ "; color: var(--accent); }
.upd-fold[open] > summary::before { content: "▾ "; }
.upd-fold > summary:hover { border-color: var(--accent); }
.toc ol a > b { margin-left: auto; padding-right: 8px; font: var(--f-label); font-weight: 400; color: var(--ink-dim); }
@media (max-width: 639px) {
  .upd { grid-template-columns: minmax(0, 1fr); padding: 12px 16px; }
  .upd::before { top: 16px; }
  .upd-list li { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .upd-list li .chg { justify-self: start; }
}

/* Article pages: answer cards first, as the data block on list pages, then the text. */
.answer-cards { margin-top: 32px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.ac { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 16px 20px 20px 16px; background: var(--panel); box-shadow: inset 0 2px 0 var(--g, var(--panel-hi)); }
.ac.st-yes { --g: var(--go); } .ac.st-planned { --g: var(--amber); } .ac.st-no { --g: var(--stop); } .ac.st-unknown { --g: var(--ink-dim); }
.ac-h { font: var(--f-name); color: var(--ink-hi); }
.ac-text { font: var(--f-small); color: var(--ink-dim); }
/* A card that jumps to its section: the title link covers the card, which takes the cut frame (10-base.css). */
.ac.can-open { --f: var(--edge); --b: var(--panel); box-shadow: none; }
.ac.can-open:hover { --f: var(--accent); }
.ac-open { color: inherit; text-decoration: none; }
.ac-open::after { content: ""; position: absolute; inset: 0; }
.ac-open:focus-visible { outline: none; }
.ac-code { display: flex; align-items: center; gap: 8px; }
.ac-code code { flex: 1; min-width: 0; padding: 8px 12px; font: var(--f-hud); color: var(--ink); background: var(--well); overflow-wrap: anywhere; }
.ac-copy { position: relative; z-index: 1; padding: 8px 12px; font: var(--f-small); color: var(--ink); background: var(--panel-lo); border: var(--rule) solid var(--panel-hi); cursor: pointer; }
.ac-copy:hover { border-color: var(--accent); }
.ac-copy.done { color: var(--well); background: var(--go); border-color: var(--go); }
.answer-cards.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Controls: action names wrap on phones so all three columns fit. */
@media (max-width: 639px) { .keys tbody th { white-space: normal; } .keys th, .keys td { padding: 8px; } }

/* Fix steps: the part a reader acts on, set apart from the explanation. */
.prose ol.steps { margin-top: 12px; padding: 16px 24px 16px 48px; background: var(--panel); }

/* A screenshot under its text (controls) stays at a readable size instead of the full column. */
.block:not(.has-shot) > .block-body > .shot { max-width: 640px; }
.prose ol.steps + p { margin-top: 12px; }

.stage-results caption { padding: 8px 16px; text-align: left; }
.stage-results thead .num { white-space: normal; }
.stage-results tbody th { min-width: 0; }
.stage-results tbody th a { color: var(--accent); text-decoration: underline; white-space: nowrap; }
.stage-results .num small { display: block; font: var(--f-small); color: var(--ink-dim); }
.run-result { display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 0 0 16px; padding: 12px 16px; background: var(--panel); }
.run-result dt { font: var(--f-label); color: var(--ink-dim); }
.run-result dd { margin: 0; font: var(--f-hud); color: var(--ink); }

/* Questions: a single question takes the full width. */
.faq > div:only-child { grid-column: 1 / -1; }

/* Site pages (about, contact, privacy, terms): plain text, lighter section heads. */
.site-doc .block { margin-top: 32px; }
.site-doc .block > h2 { padding-bottom: 0; margin-bottom: 8px; border-bottom: 0; }

@media (max-width: 999px) { .answer-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639px) { .answer-cards, .answer-cards.two { grid-template-columns: minmax(0, 1fr); } }

/* /guides: the guide pages as cards, the beginner guide on a row of its own. */
.prose .guide-picks { margin-top: 12px; padding: 0; list-style: none; }
.guide-picks .start { grid-column: 1 / -1; }
.guide-picks .pick-card { justify-content: flex-start; }
.guide-start { font: var(--f-label); color: var(--ink-dim); text-transform: uppercase; letter-spacing: 0.08em; }
.guide-desc { font: var(--f-small); color: var(--ink-dim); }

/* Comments (engine behaviour via data-gf-*): below the page, same width as the article column. */
.comments { max-width: 1120px; margin: 48px auto 0; }
/* From 1552px a rail page is a centred 1416px grid (20-shell.css): line up with its 1120px article column, not the middle. */
@media (min-width: 1552px) { #main:has(> .has-rail) > .comments { max-width: min(1120px, 100% - 296px); margin-left: max(0px, (100% - 1416px) / 2); margin-right: 0; } }
.comments h2 { font: var(--f-h2); color: var(--ink-hi); padding-bottom: 12px; margin-bottom: 16px; border-bottom: var(--rule) solid var(--line); }
.comments h2 span { display: inline-block; margin-left: 8px; padding: 0 8px; font: var(--f-small); line-height: 24px; vertical-align: 4px; color: var(--ink-dim); background: var(--panel); }
.comments .note { margin-top: 8px; }
.c-list { margin-top: 0; }
/* Outside the list: the engine's script empties the list, so a child would be lost. */
.c-empty { display: none; font: var(--f-small); color: var(--ink-dim); }
.c-list[data-gf-empty] + .c-empty { display: block; }
.c-list[data-gf-off] ~ .c-form { display: none; }
.c-item { padding: 12px 0; border-bottom: var(--rule) solid var(--panel-lo); }
.c-meta { font: var(--f-small); color: var(--ink-dim); }
.c-meta b { color: var(--ink); }
.c-owner { display: none; padding: 0 4px; color: var(--well); background: var(--accent); }
[data-gf-owner] > .c-meta .c-owner { display: inline; }
.c-text { margin-top: 4px; white-space: pre-wrap; overflow-wrap: anywhere; }
.c-reply { margin-top: 4px; padding: 4px 0; font: var(--f-small); color: var(--accent); background: none; border: 0; cursor: pointer; }
.c-replies { margin-left: 24px; }
.c-form { display: grid; gap: 8px; margin-top: 16px; }
.c-replying { display: none; font: var(--f-small); color: var(--ink-dim); }
.c-form[data-gf-replying] .c-replying { display: block; }
.c-form input, .c-form textarea { width: 100%; padding: 8px 12px; font: var(--f-body); color: var(--ink); background: var(--well); border: var(--rule) solid var(--panel-hi); border-radius: 0; -webkit-appearance: none; appearance: none; }
.c-form textarea { resize: vertical; }
.c-send { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.c-msg { font: var(--f-small); color: var(--ink-dim); }
