/* Broadcast Ink for the web: the game's menu look (SCREEN_STYLE_GUIDE.md §0) on its two faces.
   Paper with an ink halftone, giant cropped words behind, slanted plates on a hard offset shadow,
   a slanted ink panel with an accent stripe, and one green action. Ink type on light plates, white on ink.

   Fort Foundry is already a black-weight italic: never ask for bold or italic on it (font-synthesis is off,
   so the browser can't smear or double-slant it). The body face is Supercell Text. */

@font-face {
  font-family: "Foundry";
  src: url("/fonts/fort-foundry-industry-black-italic.ttf") format("truetype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Supercell";
  src: url("/fonts/supercell-text-bd.ttf") format("truetype");
  font-weight: 400; font-style: normal; font-display: swap;
}

:root {
  --ink: #0E1424;
  --ink-raised: #1C2640;
  --paper: #F3F1EC;
  --muted: #5B6275;
  --go: #22E06B;
  --accent: #56A8FF;
  --link: #1466C7;
  --warn: #D6392B;
  --gold: #FFD21F;
  --display: "Foundry", "Arial Black", Impact, sans-serif;
  --body: "Supercell", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; position: relative; overflow-x: hidden;
  background: var(--paper); color: var(--ink);
  font: 400 18px/1.55 var(--body); font-synthesis: none;
}
/* The halftone ground: 16px dots, ink at 10%. */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image: radial-gradient(circle, rgba(14, 20, 36, .10) 1.7px, transparent 2px);
  background-size: 16px 16px;
}
/* Three giant cropped rows of the page's word, very faint. */
.ground { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; user-select: none; }
.ground span {
  display: block; white-space: nowrap; text-transform: uppercase; font: 400 clamp(150px, 24vw, 260px)/.86 var(--display);
  color: rgba(14, 20, 36, .05); margin-left: -4vw;
}
.ground span:nth-child(2) { margin-left: -14vw; color: rgba(14, 20, 36, .06); }
.ground span:nth-child(3) { margin-left: 2vw; }

h1, h2, h3, .display { font-family: var(--display); font-weight: 400; font-style: normal; text-transform: uppercase; margin: 0; line-height: 1.02; }
a { color: var(--link); }
img { max-width: 100%; }

/* ---- the slanted ink panel, with its accent stripe along the slant ------------------------------ */
.panel-wrap { background: var(--accent); position: relative; }
.panel {
  position: relative; background: var(--ink); color: #fff; min-height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 32px 28px;
}
/* The white halftone, lean with the panel. */
.panel::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(circle, rgba(255, 255, 255, .07) 1.4px, transparent 1.8px); background-size: 14px 14px;
}
.panel > * { position: relative; }
.panel .logo { width: min(360px, 78%); height: auto; display: block; filter: drop-shadow(0 6px 0 rgba(0, 0, 0, .25)); }
.panel .tag { font-family: var(--display); text-transform: uppercase; letter-spacing: .06em; color: var(--accent); font-size: 20px; }

/* ---- plates: white, leaned, on a hard offset shadow with a stripe along the foot ---------------- */
.plate { position: relative; isolation: isolate; padding: 26px 30px 34px; color: var(--ink); }
.plate::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: #fff; border-radius: 12px;
  transform: skewX(-6deg); box-shadow: 10px 10px 0 var(--accent);
}
.plate::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 8px; z-index: -1; background: var(--accent);
  transform: skewX(-6deg); border-radius: 0 0 12px 12px;
}
.plate.ink { color: #fff; }
.plate.ink::before { background: var(--ink); box-shadow: 10px 10px 0 var(--accent); }

/* ---- chips and buttons: leaned 12 degrees; the green one is the action --------------------------- */
.chip, a.btn, button.btn {
  position: relative; isolation: isolate; display: inline-block; font-family: var(--display); font-weight: 400;
  text-transform: uppercase; letter-spacing: .03em; text-decoration: none; text-align: center; border: 0; background: none; cursor: pointer;
}
.chip { font-size: 15px; padding: 5px 16px; color: #fff; }
.chip::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ink); border-radius: 8px; transform: skewX(-12deg); }
.chip.accent { color: var(--ink); }
.chip.accent::before { background: var(--accent); }

a.btn, button.btn { font-size: 26px; padding: 15px 30px; color: var(--ink); -webkit-tap-highlight-color: transparent; transition: transform .12s cubic-bezier(.34, 1.56, .64, 1); }
a.btn::before, button.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: #fff; border-radius: 12px;
  transform: skewX(-12deg); box-shadow: 6px 6px 0 var(--ink);
}
a.btn.go::before, button.btn.go::before { background: var(--go); }
a.btn:active, button.btn:active { transform: scale(.97); }
a.btn:focus-visible, button.btn:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
button.btn:disabled { opacity: .45; cursor: default; }

/* ---- the top bar on the text pages ------------------------------------------------------------ */
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 20px; max-width: 980px; margin: 0 auto; }
.bar .brand img { height: 64px; width: auto; display: block; }
.bar nav { display: flex; flex-wrap: wrap; gap: 6px 22px; font-family: var(--display); text-transform: uppercase; font-size: 17px; letter-spacing: .03em; }
.bar nav a { color: var(--ink); text-decoration: none; padding: 6px 0; border-bottom: 4px solid transparent; }
.bar nav a:hover, .bar nav a[aria-current] { border-bottom-color: var(--accent); }

/* ---- long text: a white sheet under a leaning ink title band ------------------------------------ */
.page { max-width: 820px; margin: 8px auto 0; padding: 0 16px 40px; }
.title { position: relative; isolation: isolate; color: #fff; padding: 30px 34px 30px 28px; margin: 0 0 -18px; }
.title::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ink); border-radius: 12px;
  transform: skewX(-6deg); box-shadow: 10px 10px 0 var(--accent);
}
.title .chip { margin-bottom: 12px; }
.title h1 { font-size: clamp(34px, 6vw, 52px); }
.title p { margin: 10px 0 0; color: #C9D2E4; font-size: 17px; }
.sheet { background: #fff; border-radius: 12px; padding: 44px 34px 34px; box-shadow: 8px 8px 0 var(--ink); position: relative; z-index: -0; }
.sheet h2 { font-size: 26px; margin: 34px 0 10px; padding-left: 16px; position: relative; }
.sheet h2:first-child { margin-top: 0; }
.sheet h2::before { content: ""; position: absolute; left: 0; top: 2px; bottom: 2px; width: 7px; background: var(--accent); transform: skewX(-12deg); border-radius: 2px; }
.sheet h3 { font-size: 19px; margin: 22px 0 6px; color: var(--ink-raised); }
.sheet p, .sheet li { font-size: 17px; }
.sheet p { margin: 0 0 14px; }
.sheet ul, .sheet ol { padding-left: 22px; margin: 8px 0 16px; }
.sheet li { margin: 6px 0; }
.sheet strong { color: var(--ink); }
.sheet .muted, small.muted { color: var(--muted); }
.sheet a.btn { margin: 22px 8px 14px 0; }
.updated { color: var(--muted); font-size: 15px; }

.foot { max-width: 820px; margin: 0 auto; padding: 4px 20px 48px; text-align: center; color: var(--muted); font-size: 14px; }
.foot a { color: var(--muted); }

/* ---- forms --------------------------------------------------------------------------------------- */
label { display: block; margin: 18px 0 8px; font-family: var(--display); text-transform: uppercase; letter-spacing: .04em; font-size: 14px; color: var(--muted); }
input, textarea {
  width: 100%; padding: 13px 14px; border-radius: 10px; border: 3px solid var(--ink); background: #fff; color: var(--ink);
  font: 400 17px var(--body); font-synthesis: none;
}
input:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 4px 4px 0 var(--accent); }

@media (prefers-reduced-motion: reduce) { a.btn, button.btn { transition: none; } }
@media (max-width: 600px) {
  body { font-size: 17px; }
  .bar { padding: 10px 14px; }
  .bar .brand img { height: 52px; }
  .sheet { padding: 40px 20px 26px; }
  .title { padding: 24px 22px 28px 20px; }
}
