/* MONSTER MASH MOTORS — the site's design system: an arena bill.
   Poster paper with a faint halftone, Anton headlines with an off-register
   orange/blue shadow, Bangers for sound words and badges, Lexend for reading.
   Chunky black-outlined cards and buttons with hard offset shadows, starburst
   stickers, and dark "night at the Rumble Bowl" bands.
   Built by tools/build_site.py into site/public/css/; never edit the output.
   Tap targets: 48 px or more (64 px for the play doors and big buttons).
   Motion: html[data-motion="off"] (the Motion switch) and prefers-reduced-motion. */

@font-face { font-family: "Anton"; src: url("../fonts/Anton-Regular.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Bangers"; src: url("../fonts/Bangers-Regular.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Lexend"; src: url("../fonts/Lexend-Variable.woff2") format("woff2"); font-weight: 300 800; font-display: swap; }

:root {
  /* House inks (docs/art/ART-BIBLE.md §2) */
  --paper: #F4EBDD; --paper-hi: #FFF9EE; --key: #15110F;
  --orange: #FB652D; --flame-hi: #FFB23F; --blue: #6AB9D7; --blue-deep: #1A4AA6;
  --dirt: #996D54; --rust: #AA512F; --stone: #8A7D6D; --chrome: #CFCAC0; --steel: #5E5A55;
  --night: #13162C; --night-2: #182046; --night-3: #2C3152; --gold: #F2C12E; --yellow: #FFD23A;
  --ink: var(--orange); --deep: var(--rust); --spot: var(--orange);
  --focus: #1A4AA6;
  /* Type */
  --f-title: "Anton", Impact, "Arial Narrow Bold", sans-serif;
  --f-sfx: "Bangers", "Anton", Impact, sans-serif;
  --f-text: "Lexend", "Segoe UI", system-ui, -apple-system, sans-serif;
  /* Shape */
  --line: 3px; --r: 14px; --r-small: 10px;
  --drop: 5px 5px 0 var(--key); --drop-big: 8px 8px 0 var(--key);
  --gutter: 16px; --max: 1180px; --read: 44rem;
  --burst: polygon(50% 0%,58.5% 13%,70.4% 7.7%,73.7% 20.3%,89.1% 18.8%,84.2% 33.5%,96.8% 39.3%,88% 50%,94.8% 60.2%,84.2% 66.5%,89.1% 81.2%,73.7% 79.7%,71% 93.7%,58.5% 87%,50% 100%,41.5% 87%,29.6% 92.3%,26.3% 79.7%,10.9% 81.2%,15.8% 66.5%,3.2% 60.7%,12% 50%,5.2% 39.8%,15.8% 33.5%,10.9% 18.8%,26.3% 20.3%,29% 6.3%,41.5% 13%);
  color-scheme: light;
}

/* ------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; min-width: 320px; overflow-x: hidden;
  font: 400 1.125rem/1.6 var(--f-text); color: var(--key);
  background-color: var(--paper);
  /* the poster paper's faint 45-degree halftone */
  background-image:
    radial-gradient(circle at 50% 50%, rgba(21, 17, 15, .075) 0 1.1px, transparent 1.5px),
    radial-gradient(circle at 50% 50%, rgba(21, 17, 15, .075) 0 1.1px, transparent 1.5px);
  background-size: 9px 9px; background-position: 0 0, 4.5px 4.5px;
}
@media (min-width: 900px) { body { font-size: 1.1875rem; } }
img, svg { max-width: 100%; }
img { height: auto; display: block; }
a { color: var(--blue-deep); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--key); }
p { margin: 0 0 .9em; }
h1, h2, h3 { margin: 0 0 .5em; line-height: 1.05; }
strong { font-weight: 700; }
q { quotes: "“" "”"; }
code { font-family: ui-monospace, Consolas, monospace; font-size: .9em; overflow-wrap: anywhere; }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 4px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.night :focus-visible, .top :focus-visible, .foot :focus-visible { --focus: var(--yellow); }
main:focus { outline: none; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
/* Icons are <use> references into the page's sprite: their stroke and fill are
   inherited from here (a symbol's own <svg> attributes do not reach them). */
.ico {
  width: 1.35em; height: 1.35em; flex: none; vertical-align: -.3em;
  fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round;
}
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.wrap-read { max-width: calc(var(--read) + 2 * var(--gutter)); }
.js .no-js { display: none; }
.note { font-size: .95rem; color: #4a403a; }
.night .note { color: #d9d0c4; }
.notice {
  display: inline-block; margin: .6em 0; padding: .45em .8em; font-size: .95rem; font-weight: 600;
  background: var(--paper-hi); border: 2px dashed var(--key); border-radius: var(--r-small);
}
.skip {
  position: absolute; left: 8px; top: -60px; z-index: 50; padding: .6em 1em; background: var(--yellow);
  color: var(--key); font-weight: 700; border: 3px solid var(--key); border-radius: var(--r-small);
}
.skip:focus { top: 8px; }

/* ------------------------------------------------------------ type */
.headline, .page-h, .sec-h, .ch-h, .book-title, .card-name, .door-name, .bill-title, .shelf-t, .wm {
  font-family: var(--f-title); font-weight: 400; text-transform: uppercase; letter-spacing: .01em;
}
.page-h, .sec-h, .headline {
  color: var(--key);
  text-shadow: .035em .035em 0 var(--orange), .07em .07em 0 var(--blue);
}
.page-h { font-size: clamp(2.4rem, 8vw, 4.4rem); margin-top: .1em; }
.sec-h { font-size: clamp(2rem, 6vw, 3.2rem); }
.small-h { font-size: clamp(1.5rem, 4.4vw, 2rem); }
.night .page-h, .night .sec-h, .night .headline { color: var(--paper-hi); }
.lede { font-size: clamp(1.15rem, 2.6vw, 1.4rem); line-height: 1.5; max-width: 40em; }
.sec-lede { font-size: 1.1rem; max-width: 42em; margin-top: -.2em; }
.kicker {
  display: inline-block; margin: 0 0 .5em; padding: .25em .7em .15em; font: 400 1.15rem/1.1 var(--f-sfx); letter-spacing: .05em;
  background: var(--key); color: var(--paper-hi); border-radius: 6px; transform: rotate(-2deg);
}
.sfx {
  font-family: var(--f-sfx); font-weight: 400; letter-spacing: .03em; color: var(--flame-hi);
  -webkit-text-stroke: .07em var(--key); paint-order: stroke fill;
  text-shadow: .07em .07em 0 var(--orange);
}

/* ------------------------------------------------------------ header */
.top {
  position: relative; z-index: 10; background-color: var(--orange); color: var(--key);
  background-image: radial-gradient(circle, rgba(21, 17, 15, .16) 0 1.2px, transparent 1.6px);
  background-size: 8px 8px; border-bottom: 4px solid var(--key);
}
.top-in {
  max-width: var(--max); margin: 0 auto; padding: 8px var(--gutter) 6px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.brand { display: block; color: var(--key); text-decoration: none; min-height: 48px; padding: 4px 0; }
.wm { display: block; margin: 0; line-height: .92; font-size: clamp(1.45rem, 6.4vw, 2.6rem); color: var(--key);
  text-shadow: .045em .045em 0 var(--blue), -.02em -.02em 0 var(--paper-hi); }
.wm1, .wm2 { display: block; white-space: nowrap; }
@media (min-width: 760px) { .wm1, .wm2 { display: inline; } .wm { font-size: 2.3rem; } }
.switches { display: flex; gap: 8px; flex: none; }
.switch {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 0;
  min-width: 64px; min-height: 56px; padding: 4px 8px 3px; cursor: pointer;
  font: 700 .8rem/1.05 var(--f-text); color: var(--key); background: var(--paper-hi);
  border: var(--line) solid var(--key); border-radius: 12px; box-shadow: 3px 3px 0 var(--key);
}
.switch .ico { width: 24px; height: 24px; }
.switch .sw-state { font: 400 .78rem/1 var(--f-sfx); letter-spacing: .06em; text-transform: uppercase; opacity: .75; }
.switch[aria-pressed="true"] { background: var(--yellow); }
.switch[aria-pressed="true"] .sw-state { opacity: 1; }
.switch .on-ico { display: none; }
.switch[aria-pressed="true"] .on-ico { display: inline; }
.switch[aria-pressed="true"] .off-ico { display: none; }
.switch:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--key); }
@media (min-width: 760px) {
  .switch { flex-direction: row; gap: 6px; min-height: 48px; padding: 4px 12px; font-size: .95rem; }
  .switch .sw-state { font-size: .95rem; }
}
/* Three switches (Sound, Music, Motion) beside the wordmark down to 320 px: phones get slimmer
   switches with smaller labels, every label still shown (audio agent). */
@media (max-width: 479px) {
  .switches { gap: 4px; }
  .switch { min-width: 0; padding: 4px 3px 3px; font-size: .64rem; }
}
@media (max-width: 340px) { .top-in { gap: 6px; } }

.nav { background: var(--key); }
.nav ul {
  list-style: none; margin: 0 auto; padding: 0 6px; max-width: var(--max);
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
}
.nav a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  min-height: 56px; padding: 4px 2px; color: var(--paper); text-decoration: none;
  font: 600 clamp(.72rem, 3.5vw, .95rem)/1.1 var(--f-text); letter-spacing: -.01em; white-space: nowrap;
  border-bottom: 4px solid transparent;
}
.nav a .ico { width: 24px; height: 24px; }
.nav a:hover { color: var(--flame-hi); }
.nav a[aria-current] { color: var(--flame-hi); border-bottom-color: var(--orange); }
@media (min-width: 760px) {
  .nav ul { display: flex; justify-content: center; gap: 6px; }
  .nav a { flex-direction: row; gap: 8px; min-height: 52px; padding: 4px 16px; font-size: 1.02rem; }
}

/* ------------------------------------------------------------ buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45em;
  min-height: 48px; padding: .4em 1.05em; cursor: pointer;
  font: 700 1.05rem/1.15 var(--f-text); color: var(--key); text-decoration: none; text-align: center;
  background: var(--orange); border: var(--line) solid var(--key); border-radius: var(--r-small);
  box-shadow: 4px 4px 0 var(--key); transition: transform .08s ease, box-shadow .08s ease;
}
.btn:hover { color: var(--key); transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--key); }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--key); }
.btn-big { min-height: 64px; padding: .25em 1.2em; font: 400 1.7rem/1 var(--f-title); text-transform: uppercase; letter-spacing: .03em; }
.btn-big .ico { width: 1.05em; height: 1.05em; vertical-align: 0; }
.btn-blue { background: var(--blue); }
.btn-ghost { background: var(--paper-hi); }
.btn-small { min-height: 48px; font-size: .98rem; padding: .3em .9em; }
.btn[disabled] { opacity: .55; cursor: default; transform: none; box-shadow: 2px 2px 0 var(--key); }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin: 1em 0 .4em; }
.more-link { margin: 1.4em 0 0; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.more-s { color: #4a403a; }

/* ------------------------------------------------------------ sections */
.sec { padding: clamp(28px, 6vw, 64px) 0; }
.page-top { padding-bottom: 12px; }
.night {
  background-color: var(--night); color: var(--paper);
  background-image:
    radial-gradient(ellipse 60% 45% at 15% 0%, rgba(106, 185, 215, .22), transparent 70%),
    radial-gradient(ellipse 55% 40% at 85% 0%, rgba(251, 101, 45, .2), transparent 70%),
    radial-gradient(circle, rgba(255, 249, 238, .06) 0 1.1px, transparent 1.5px);
  background-size: auto, auto, 9px 9px;
}
.night a:not(.btn) { color: var(--flame-hi); }
.night a:not(.btn):hover { color: var(--paper-hi); }

/* ------------------------------------------------------------ home: the bill */
.hero { padding: clamp(16px, 4vw, 40px) 0 clamp(28px, 5vw, 56px); }
.bill {
  background: var(--paper); color: var(--key); border: 4px solid var(--key); border-radius: 6px;
  box-shadow: var(--drop-big); overflow: hidden;
}
.bill-top {
  position: relative; padding: 14px 16px 12px; text-align: center;
  background-color: var(--orange);
  background-image: radial-gradient(circle, rgba(21, 17, 15, .18) 0 1.3px, transparent 1.7px); background-size: 8px 8px;
  border-bottom: 4px solid var(--key);
}
.headline { margin: 0; line-height: .95; }
.hl-kicker {
  display: block; width: fit-content; margin: -4px auto 4px; padding: .95em 1.7em .85em;
  clip-path: var(--burst); background: var(--yellow);
  font: 400 clamp(1.5rem, 6vw, 2.5rem)/1 var(--f-sfx); letter-spacing: .05em; color: var(--key); text-shadow: none;
  transform: rotate(-4deg); animation: burst-pulse 2.4s ease-in-out infinite;
}
.hl-main { display: block; font-size: clamp(2.3rem, 9.5vw, 5.6rem); color: var(--key);
  text-shadow: .03em .03em 0 var(--paper-hi), .07em .07em 0 var(--blue); }
.bill-sub { margin: .5em 0 0; font: 400 clamp(1rem, 3vw, 1.35rem)/1.1 var(--f-sfx); letter-spacing: .08em; }
.bill-art { background: var(--night); border-bottom: 4px solid var(--key); }
.hero-art { width: 100%; }
.bill-foot { padding: 14px 18px 18px; display: grid; gap: 4px; }
.bill-foot .lede { margin: 0; }
@media (min-width: 860px) {
  .bill-foot { grid-template-columns: 1fr auto; align-items: center; gap: 24px; padding: 18px 26px 20px; }
  .bill-foot .cta-row { margin: 0; }
}
@keyframes burst-pulse { 0%, 100% { transform: rotate(-4deg) scale(1); } 50% { transform: rotate(-1deg) scale(1.05); } }
@media (min-width: 900px) {
  .bill { max-width: 1060px; margin: 0 auto; }
  .hero-art { aspect-ratio: 16 / 7.4; object-fit: cover; object-position: 50% 100%; }
}

/* ------------------------------------------------------------ home: the trailer
   In the bill, between the headline and PLAY/READ (tools/build_site.py,
   trailer_block; the film is made by tools/video/). A plain <video controls>
   that never autoplays; without JavaScript the browser's own controls play it.
   With JavaScript (video/trailer.js) a big starburst play button sits over the
   poster until the film starts, and comes back when it ends. */
.trailer { --focus: var(--yellow); padding: 12px 12px 14px; background: var(--night); color: var(--paper); border-bottom: 4px solid var(--key); }
.trailer-h {
  margin: 0 0 10px; text-align: center; color: var(--paper-hi);
  font: 400 clamp(1.45rem, 5.4vw, 2.2rem)/1.05 var(--f-title); text-transform: uppercase; letter-spacing: .02em;
}
.trailer-meta { display: block; margin-top: .35em; font: 600 clamp(.88rem, 2.6vw, 1rem)/1.3 var(--f-text); text-transform: none; letter-spacing: 0; color: #d9d0c4; }
.trailer-frame {
  position: relative; max-width: 820px; margin: 0 auto; overflow: hidden;
  background: var(--key); border: 3px solid var(--key); border-radius: 8px; box-shadow: 0 0 0 3px var(--paper-hi);
}
.trailer-video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: var(--key); }
.trailer-fallback { margin: 0; padding: 1em; color: var(--paper); }
.trailer-play {
  position: absolute; left: 50%; top: 50%; z-index: 1; transform: translate(-50%, -58%);
  display: grid; place-items: center; width: clamp(78px, 19vw, 150px); aspect-ratio: 1; padding: 0;
  cursor: pointer; color: var(--key); background: none; border: 0; border-radius: 50%;
  filter: drop-shadow(3px 0 0 var(--key)) drop-shadow(-3px 0 0 var(--key)) drop-shadow(0 3px 0 var(--key)) drop-shadow(0 -3px 0 var(--key)) drop-shadow(5px 6px 0 var(--key));
}
.trailer-play::before {
  content: ""; position: absolute; inset: 0; clip-path: var(--burst); background: var(--yellow);
  transition: transform .12s ease;
}
.trailer-play:hover::before { transform: scale(1.07) rotate(-4deg); }
.trailer-play:active::before { transform: scale(.96); }
.trailer-play-ico { position: relative; width: 44%; height: 44%; margin-left: 7%; fill: var(--key); }
.trailer-play-t {
  position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%);
  padding: .3em .8em; white-space: nowrap; border-radius: 6px;
  font: 400 clamp(1rem, 3.4vw, 1.4rem)/1 var(--f-sfx); letter-spacing: .06em; color: var(--key); background: var(--paper-hi);
}
.trailer-words { margin: 0; padding: 0 18px 16px; }
.trailer-words summary { min-height: 48px; padding: 10px 0; cursor: pointer; font-weight: 700; }
.trailer-words ol { margin: .3em 0 0; padding-left: 1.4em; }
.trailer-words li { margin: 0 0 .8em; }
.trailer-words li p { margin: 0; }
.tw-scene { font-size: .96rem; color: #4a403a; }
@media (max-width: 419px) {
  .trailer-play { transform: translate(-50%, -50%); }
  .trailer-play-t { display: none; }   /* the button keeps its name (aria-label) */
}
@media (min-width: 860px) {
  .trailer { padding: 16px 20px 20px; }
  .trailer-words { padding: 0 26px 18px; }
}

/* ------------------------------------------------------------ home: lineup */
.lineup {
  list-style: none; margin: 18px 0 0; padding: 0; align-items: start;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px;
}
@media (min-width: 620px) { .lineup { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .lineup { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 14px; } }
.rev { position: relative; }
.rev-btn {
  display: block; width: 100%; padding: 0; cursor: pointer; text-align: center; overflow: hidden;
  background: var(--paper-hi); border: var(--line) solid var(--key); border-radius: var(--r);
  box-shadow: var(--drop); transition: transform .1s ease, box-shadow .1s ease;
}
.rev-btn[disabled] { cursor: default; }
.rev-btn:not([disabled]):hover { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 var(--key); }
.rev-btn:not([disabled]):active { transform: translate(3px, 3px); box-shadow: 2px 2px 0 var(--key); }
.rev-btn .portrait { width: 100%; aspect-ratio: 1; object-fit: cover; }
.rev-name {
  display: block; padding: .3em .2em .2em; font: 400 clamp(1.15rem, 4.2vw, 1.5rem)/1 var(--f-title);
  text-transform: uppercase; letter-spacing: .03em; color: var(--paper-hi); background: var(--key);
  border-top: 3px solid var(--key); box-shadow: inset 0 -6px 0 var(--ink);
}
.bubble {
  margin: 10px 0 0; padding: 10px 12px; font-size: .95rem; line-height: 1.35;
  background: var(--paper-hi); border: var(--line) solid var(--key); border-radius: 16px; box-shadow: 3px 3px 0 var(--key);
}
.bubble-say { display: block; font: 400 1.2rem/1.1 var(--f-sfx); letter-spacing: .03em; margin-bottom: .3em; }
.js .rev .bubble { position: relative; margin-top: 16px; transform-origin: 50% 0; display: none; }
.js .rev .bubble::before {
  content: ""; position: absolute; left: 50%; top: -17px; width: 24px; height: 17px; margin-left: -12px;
  background: var(--key); clip-path: polygon(60% 0, 100% 100%, 0 100%);
}
.js .rev.is-on .bubble { display: block; animation: pop .22s ease-out; }
.rev.is-revving .portrait, .portrait.is-shaking { animation: rev-shake .5s linear 2; }
@keyframes pop { from { transform: scale(.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes rev-shake {
  0%, 100% { transform: translate(0, 0); } 20% { transform: translate(-2px, 1px); } 40% { transform: translate(2px, -1px); }
  60% { transform: translate(-1px, -1px); } 80% { transform: translate(1px, 1px); }
}
.portrait-blank { display: block; width: 100%; aspect-ratio: 1; background: var(--ink); }

/* ------------------------------------------------------------ doors */
.doors { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .doors { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 700px) and (max-width: 1039px) { .doors-five { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .doors-five { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.door a {
  display: flex; flex-direction: column; height: 100%; min-height: 64px; color: var(--key); text-decoration: none;
  background: var(--paper-hi); border: 4px solid var(--key); border-radius: var(--r); box-shadow: var(--drop-big);
  overflow: hidden; transition: transform .1s ease, box-shadow .1s ease;
}
.door a:hover { transform: translate(-2px, -2px); box-shadow: 10px 10px 0 var(--key); }
.door a:active { transform: translate(4px, 4px); box-shadow: 3px 3px 0 var(--key); }
.door-pic { position: relative; display: block; aspect-ratio: 16 / 9; background: var(--night); border-bottom: 4px solid var(--key); }
.door-art { width: 100%; height: 100%; object-fit: cover; }
.door-ico {
  position: absolute; right: 10px; bottom: -26px; display: grid; place-items: center; width: 64px; height: 64px;
  background: var(--yellow); clip-path: var(--burst);
}
.door-ico .ico { width: 30px; height: 30px; }
.door-stunt .door-ico { background: var(--orange); }
.door-wash .door-ico { background: var(--blue); }
.door-paint .door-ico { background: var(--yellow); }
.door-poster .door-ico { background: #F07C9B; }
.door-pitpass .door-ico { background: var(--gold); }
.door-name { display: block; padding: 14px 76px 0 16px; font-size: clamp(1.6rem, 5vw, 2.1rem); line-height: 1; }
@media (min-width: 700px) and (max-width: 1039px) { .door-name { font-size: 1.55rem; padding-right: 60px; } }
.door-line { display: block; padding: 8px 16px 18px; font-size: 1rem; }

/* ------------------------------------------------------------ home: the season bill */
.bill-list { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 14px; }
@media (min-width: 900px) { .bill-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 22px; } }
.bill-row a {
  display: grid; grid-template-columns: 76px 1fr; grid-template-rows: auto auto auto 1fr; column-gap: 14px;
  height: 100%; padding: 12px; color: var(--key); text-decoration: none;
  background: var(--paper); border: 3px solid var(--key); border-radius: var(--r-small); box-shadow: 5px 5px 0 var(--orange);
}
.night .bill-row a { color: var(--key); }
.bill-row a:hover { box-shadow: 7px 7px 0 var(--blue); color: var(--key); }
.bill-thumb { grid-row: 1 / span 4; }
.bill-thumb .thumb { width: 76px; border: 2px solid var(--key); border-radius: 4px; }
.bill-when { font: 400 1.05rem/1.1 var(--f-sfx); letter-spacing: .06em; color: var(--rust); }
.bill-what { font-size: .9rem; font-weight: 600; }
.bill-where { text-transform: uppercase; letter-spacing: .03em; }
.bill-title { margin-top: 4px; font-size: clamp(1.3rem, 4vw, 1.6rem); line-height: 1.02; }
.bill-n { display: block; font: 400 .8rem/1.2 var(--f-text); font-weight: 700; letter-spacing: .08em; color: #4a403a; }
.bill-tag { margin-top: 4px; font-size: .95rem; line-height: 1.35; }
.thumb-blank {
  display: flex; flex-direction: column; justify-content: flex-end; aspect-ratio: 5 / 8; padding: 6px;
  background: var(--spot, var(--orange)); color: var(--key); border: 2px solid var(--key);
}
.tb-n { font: 400 .75rem/1 var(--f-sfx); }
.tb-t { font: 400 .8rem/1 var(--f-title); text-transform: uppercase; }

/* ------------------------------------------------------------ home: more */
.more { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .more { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .more { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.more a {
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 12px; align-items: center;
  min-height: 64px; padding: 12px 14px; color: var(--key); text-decoration: none;
  background: var(--paper-hi); border: 3px solid var(--key); border-radius: var(--r-small); box-shadow: 4px 4px 0 var(--key);
}
.more a:hover { box-shadow: 6px 6px 0 var(--orange); }
.more .ico { grid-row: 1 / span 2; width: 34px; height: 34px; }
.more-t { font: 400 1.35rem/1.05 var(--f-title); text-transform: uppercase; }
.more-s { font-size: .92rem; line-height: 1.3; }

/* ------------------------------------------------------------ crew cards */
.cards { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); margin-top: 18px; }
.cards-one { grid-template-columns: minmax(0, 560px); }
.card {
  display: flex; flex-direction: column; background: var(--paper-hi); color: var(--key); scroll-margin-top: 16px;
  border: 4px solid var(--key); border-radius: 18px; box-shadow: var(--drop-big); overflow: hidden;
}
.card:target { box-shadow: 8px 8px 0 var(--orange), 0 0 0 6px var(--yellow); }
.card-art { position: relative; background: var(--ink); border-bottom: 4px solid var(--key); }
.card-art .portrait { width: 100%; aspect-ratio: 1; object-fit: cover; }
.card-sfx {
  position: absolute; right: 10px; top: 10px; padding: .1em .35em; transform: rotate(8deg);
  font: 400 clamp(1.3rem, 4vw, 1.7rem)/1 var(--f-sfx); letter-spacing: .04em; color: var(--flame-hi);
  -webkit-text-stroke: .08em var(--key); paint-order: stroke fill; text-shadow: .08em .08em 0 var(--orange);
}
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.card-name { margin: 0; font-size: clamp(2rem, 6vw, 2.6rem); line-height: .95; color: var(--key);
  text-shadow: .045em .045em 0 var(--ink); }
.card-role { margin: .25em 0 .5em; font: 400 1.2rem/1.1 var(--f-sfx); letter-spacing: .06em; }
.card-line { font-size: 1rem; }
.card-power { margin: 0 0 .7em; display: grid; gap: 8px; }
.card-power div { padding: 8px 10px; border: 2px solid var(--key); border-radius: 8px; background: var(--paper); }
.card-power div:first-child { background: var(--deep); color: var(--paper-hi); }
.card-power dt { font: 400 .8rem/1 var(--f-sfx); letter-spacing: .1em; text-transform: uppercase; }
.card-power dd { margin: 2px 0 0; font-weight: 700; line-height: 1.25; }
.card-how { font-size: .98rem; line-height: 1.45; }
.card-stats { margin: 0 0 .7em; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 10px; font-size: .92rem; }
.card-stats div:last-child:nth-child(odd) { grid-column: 1 / -1; }
.card-stats dt { font-weight: 700; font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: #4a403a; }
.card-stats dd { margin: 0; line-height: 1.3; }
.card-says { margin: auto 0 .6em; padding-top: 6px; font: 400 1.3rem/1.15 var(--f-sfx); letter-spacing: .03em; }
.says-label { display: block; font: 700 .75rem/1 var(--f-text); letter-spacing: .08em; text-transform: uppercase; color: #4a403a; }
.card-rev { margin: 0; }
/* Power blocks: the deep ink with paper text (AA contrast); the light inks keep key text. */
#bounce .card-power div:first-child, #torque .card-power div:first-child, #al .card-power div:first-child,
#pip .card-power div:first-child { background: var(--ink); color: var(--key); }

.crew-jump ul { list-style: none; margin: 14px 0 6px; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(68px, 1fr)); max-width: 900px; }
.crew-jump a {
  display: flex; flex-direction: column; align-items: center; min-height: 64px; padding: 0 0 4px; overflow: hidden;
  font-size: .72rem; font-weight: 700; line-height: 1.1; text-align: center; color: var(--key); text-decoration: none;
  background: var(--paper-hi); border: 3px solid var(--key); border-radius: 10px; box-shadow: 2px 2px 0 var(--key);
}
.crew-jump a:hover { box-shadow: 3px 3px 0 var(--ink); }
.jump-img { width: 100%; aspect-ratio: 1; object-fit: cover; margin-bottom: 3px; border-bottom: 3px solid var(--ink); }

/* ------------------------------------------------------------ quizzes */
.quiz-sec { scroll-margin-top: 8px; }
.quizzes { display: grid; gap: 26px; margin-top: 16px; }
@media (min-width: 1040px) { .quizzes { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; } }
.quiz { background: var(--paper-hi); border: 4px solid var(--key); border-radius: 18px; box-shadow: var(--drop-big); padding: 16px; }
.quiz-h { display: flex; align-items: center; gap: 10px; font: 400 clamp(1.5rem, 5vw, 2rem)/1 var(--f-title); text-transform: uppercase; }
.quiz-q { font-size: 1.05rem; }
.quiz-round { display: inline-block; font: 400 1rem/1 var(--f-sfx); letter-spacing: .06em; padding: .2em .5em; background: var(--key); color: var(--paper-hi); border-radius: 6px; }
.quiz-stage {
  display: grid; place-items: center; min-height: 200px; margin: 6px 0 14px; padding: 10px;
  background: var(--paper); border: 3px solid var(--key); border-radius: 12px;
}
.shadow-stage img { width: min(100%, 460px); }
.shadow-blank { display: block; width: 240px; height: 140px; background: var(--key); border-radius: 40px 60px 20px 20px; }
.quiz-off { padding: 10px 12px; background: var(--yellow); border: 3px solid var(--key); border-radius: 10px; font-weight: 600; }
.choices { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
.choice {
  display: flex; flex-direction: column; align-items: stretch; width: 100%; min-height: 64px; padding: 0; overflow: hidden; cursor: pointer;
  background: var(--paper-hi); border: 3px solid var(--key); border-radius: 12px; box-shadow: 3px 3px 0 var(--key);
}
.choice-img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.choice-name { padding: 5px 2px 4px; font: 400 1.05rem/1 var(--f-title); text-transform: uppercase; background: var(--key); color: var(--paper-hi); box-shadow: inset 0 -4px 0 var(--ink); }
.choice:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--key); }
.choice:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--key); }
.choice[aria-disabled="true"] { opacity: .45; }
.choice.is-right { box-shadow: 0 0 0 5px var(--yellow), 4px 4px 0 var(--key); }
.quiz-say { min-height: 1.6em; margin: 12px 0 4px; font: 400 1.45rem/1.15 var(--f-sfx); letter-spacing: .03em; }
.quiz-actions { margin: 0; }
.listen { background: var(--blue); }

/* ------------------------------------------------------------ books shelf */
.shelf { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 24px 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 640px) { .shelf { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .shelf { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.shelf-book a { display: flex; flex-direction: column; gap: 4px; height: 100%; color: var(--key); text-decoration: none; }
.shelf-cover .thumb { width: 100%; border: 3px solid var(--key); border-radius: 6px; box-shadow: 5px 5px 0 var(--key); transition: transform .12s ease; }
.shelf-book a:hover .thumb { transform: rotate(-1.5deg) translateY(-3px); }
.shelf-n { margin-top: 10px; font: 400 1rem/1 var(--f-sfx); letter-spacing: .08em; color: var(--rust); }
.shelf-t { font-size: clamp(1.2rem, 3.6vw, 1.45rem); line-height: 1.02; }
.shelf-tag { font-size: .92rem; line-height: 1.35; }
.shelf-read { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 6px; font-weight: 700; font-size: .95rem; color: var(--blue-deep); text-decoration: underline; text-underline-offset: 3px; }
.shelf-read.soon { color: #4a403a; text-decoration: none; font-weight: 600; }

/* ------------------------------------------------------------ book page */
.book-top { padding-top: clamp(20px, 4vw, 44px); }
.book-hero { display: grid; gap: 18px 28px; grid-template-columns: minmax(0, 1fr); }
.book-cover { max-width: 300px; }
.book-cover .cover-img { width: 100%; border: 4px solid var(--key); border-radius: 8px; box-shadow: var(--drop-big); }
@media (min-width: 760px) {
  .book-hero { grid-template-columns: minmax(220px, 340px) minmax(0, 1fr); align-items: start; }
  .book-cover { grid-row: 1 / span 2; max-width: none; }
}
.book-title { margin: 0; font-size: clamp(2.3rem, 7.4vw, 4.2rem); line-height: .95; color: var(--key);
  text-shadow: .045em .045em 0 var(--spot); }
.tagline { margin: .6em 0 .3em; font-size: clamp(1.2rem, 3vw, 1.5rem); font-weight: 600; line-height: 1.35; }
.book-when { font: 400 1.1rem/1.2 var(--f-sfx); letter-spacing: .06em; color: var(--rust); }
.blurb p { max-width: 38em; }
.cast-sec { padding-top: 8px; }
.cast { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.cast a {
  display: flex; flex-direction: column; align-items: center; width: 96px; min-height: 64px; padding: 0 0 6px; overflow: hidden;
  font-weight: 700; font-size: .85rem; line-height: 1.1; text-align: center; color: var(--key); text-decoration: none;
  background: var(--paper-hi); border: 3px solid var(--key); border-radius: 12px; box-shadow: 3px 3px 0 var(--key);
}
.cast a:hover { box-shadow: 4px 4px 0 var(--ink); }
.cast-img { width: 100%; aspect-ratio: 1; object-fit: cover; margin-bottom: 5px; border-bottom: 3px solid var(--key); }
.idea {
  position: relative; margin: 28px 0 0; padding: 16px 18px 12px; max-width: 46rem;
  background: var(--paper-hi); border: 4px solid var(--key); border-radius: 16px; box-shadow: 6px 6px 0 #FF9A1F;
}
.idea-h { display: flex; align-items: center; gap: 10px; font: 400 clamp(1.4rem, 4.4vw, 1.9rem)/1 var(--f-title); text-transform: uppercase; }
.idea-h .ico { width: 36px; height: 36px; padding: 5px; background: #FF9A1F; border: 3px solid var(--key); border-radius: 50%; }
.idea-big { font-size: 1.15rem; font-weight: 600; line-height: 1.45; }
.idea-home { font-size: 1rem; }

.chapter { padding: clamp(28px, 6vw, 60px) 0; background: var(--paper-hi); border-top: 4px solid var(--key); border-bottom: 4px solid var(--key); scroll-margin-top: 0; }
.ch-h { margin: 0 0 .8em; font-size: clamp(2.1rem, 7vw, 3.4rem); line-height: .95; }
.ch-n { display: block; font: 400 1.1rem/1.2 var(--f-sfx); letter-spacing: .1em; color: var(--rust); text-transform: uppercase; }
.ch-t { color: var(--key); text-shadow: .045em .045em 0 var(--spot); }
.prose { font-size: clamp(1.2rem, 2.6vw, 1.35rem); line-height: 1.7; }
.prose p { margin: 0 0 1em; }
.sfx-line { margin: .6em 0 .8em !important; text-align: center; line-height: 1; }
.sfx-line .sfx { display: inline-block; font-size: clamp(3rem, 14vw, 6rem); transform: rotate(-4deg); }
/* Tap-to-hear sound words (audio agent; js/soundwords.js turns the word into a button, same text). */
.sfx-btn {
  appearance: none; margin: 0; padding: 0 .12em; background: none; border: 0; border-radius: 12px; cursor: pointer;
  line-height: 1; touch-action: manipulation;
}
.sfx-btn .sfx-ico {
  width: .3em; height: .3em; margin-left: .06em; vertical-align: .9em; color: var(--key);
  -webkit-text-stroke: 0; stroke-width: 2.6;
}
.sfx-btn:hover .sfx-ico { color: var(--orange); }
.sfx-btn.is-pop { animation: sfx-pop .38s ease-out; }
@keyframes sfx-pop {
  0% { transform: rotate(-4deg) scale(1); }
  35% { transform: rotate(-8deg) scale(1.12); }
  100% { transform: rotate(-4deg) scale(1); }
}
.sfx-tip { display: block; margin: .5em auto 0; max-width: 24em; font: 600 1rem/1.35 var(--f-text); letter-spacing: 0; color: var(--key); }
.sfx-tip:empty { display: none; }
@media print { .sfx-btn .sfx-ico, .sfx-tip { display: none; } }
.ch-pic { margin: 1.4em 0 1.6em; }
.ch-pic img { width: 100%; border: 4px solid var(--key); border-radius: 8px; box-shadow: 6px 6px 0 var(--key); background: var(--paper); }
/* A spot is a sticker with a see-through outside: no frame, centred, smaller. */
.ch-pic.spot { text-align: center; }
.ch-pic.spot img { width: 60%; height: auto; margin: 0 auto; border: 0; border-radius: 0; box-shadow: none; background: none; }
.ch-pic.spot.wide img { width: 78%; }
@media (max-width: 599px) { .ch-pic.spot img { width: 74%; } .ch-pic.spot.wide img { width: 92%; } }
.ch-break { text-align: center; letter-spacing: .6em; }
/* The Chapter One read-along beside the text (read-along agent: build_site.py readalong_html).
   Plain <video>/<audio controls>, framed like the chapter's pictures. */
.readalong { margin: 0 0 2em; padding: 14px 14px 16px; background: var(--paper); border: 3px solid var(--key); border-radius: 14px; }
.ra-h { margin: 0 0 .5em; font: 400 clamp(1.3rem, 4.6vw, 1.75rem)/1.05 var(--f-title); text-transform: uppercase; letter-spacing: .02em; }
.ra-meta { display: block; margin-top: .35em; font: 600 clamp(.86rem, 2.5vw, .98rem)/1.3 var(--f-text); text-transform: none; letter-spacing: 0; color: #4a403a; }
.ra-video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: var(--key); border: 4px solid var(--key); border-radius: 8px; box-shadow: 5px 5px 0 var(--key); }
.ra-h-listen { margin-top: 1.1em; font-size: clamp(1.1rem, 3.8vw, 1.4rem); }
.ra-audio { display: block; width: 100%; min-height: 48px; }
.ra-fallback { margin: 0; padding: 1em; color: var(--paper); }
.ra-audio .ra-fallback { color: var(--key); }
.ra-note { margin: .8em 0 0; font-size: .92rem; line-height: 1.45; color: #4a403a; }
@media print { .readalong { display: none; } }
.ch-end { margin-top: 2em; padding: 18px; text-align: center; background: var(--paper); border: 3px dashed var(--key); border-radius: 14px; }
.ch-end-h { margin: 0 0 .3em; font: 400 clamp(1.6rem, 5vw, 2.2rem)/1 var(--f-sfx); letter-spacing: .05em; }
.badge-say { margin: .4em 0 0; font-weight: 700; }
.badge-say:empty { display: none; }
.badge-say::before { content: "★ "; color: var(--orange); }

.share {
  padding: 18px; background: var(--paper-hi); border: 4px solid var(--key); border-radius: 16px; box-shadow: 6px 6px 0 var(--blue);
}
.share-h { display: flex; align-items: center; gap: 10px; font: 400 clamp(1.4rem, 4.4vw, 1.9rem)/1.05 var(--f-title); text-transform: uppercase; }
.share-label { display: block; margin: 0 0 4px; font-weight: 700; font-size: .95rem; }
.share textarea {
  width: 100%; min-height: 7.2em; padding: 10px 12px; font: 400 1.05rem/1.45 var(--f-text); color: var(--key);
  background: #fff; border: 3px solid var(--key); border-radius: 10px; resize: vertical;
}
/* Grow to show the whole message where the browser can (no inner scrolling on phones). */
@supports (field-sizing: content) { .share textarea { field-sizing: content; max-height: 60vh; } }
.share-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 14px 0 6px; }
.share-status { min-height: 1.4em; font-weight: 700; margin: 0 0 6px; }
.share-url { margin: 0; font-size: .95rem; }
.share-url code { display: inline-block; padding: 2px 6px; background: var(--paper); border-radius: 4px; user-select: all; }

.booknav { display: grid; grid-template-columns: 1fr; gap: 12px; padding-top: 28px; padding-bottom: 36px; }
@media (min-width: 760px) { .booknav { grid-template-columns: 1fr auto 1fr; align-items: stretch; } }
.booknav a {
  display: flex; align-items: center; gap: 10px; min-height: 64px; padding: 10px 14px; color: var(--key); text-decoration: none;
  background: var(--paper-hi); border: 3px solid var(--key); border-radius: var(--r-small); box-shadow: 4px 4px 0 var(--key);
}
.booknav a:hover { box-shadow: 6px 6px 0 var(--orange); }
.bn-next { justify-content: flex-end; text-align: right; }
.bn-all { justify-content: center; font-weight: 700; }
.bn-l { display: block; font: 400 .95rem/1 var(--f-sfx); letter-spacing: .08em; color: var(--rust); }
.bn-t { display: block; font: 400 1.15rem/1.05 var(--f-title); text-transform: uppercase; }
span.bn-prev, span.bn-next { display: none; }
@media (min-width: 760px) { span.bn-prev, span.bn-next { display: block; } }

/* ------------------------------------------------------------ grown-ups, about (calm) */
.calm { background-color: var(--paper-hi); background-image: none; }
.calm .page-h, .calm .sec-h { text-shadow: .03em .03em 0 var(--blue); }
.calm .sec { padding: 26px 0; border-top: 2px solid #e6dccb; }
.toc ul { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.toc a { display: inline-flex; align-items: center; min-height: 48px; padding: 4px 14px; font-weight: 600; font-size: .98rem; color: var(--key); background: var(--paper); border: 2px solid var(--key); border-radius: 999px; text-decoration: none; }
.toc a:hover { background: var(--yellow); }
.table-wrap { overflow-x: auto; margin: 12px 0; border: 3px solid var(--key); border-radius: 10px; background: #fff; }
.levels { width: 100%; border-collapse: collapse; font-size: .95rem; }
.levels th, .levels td { padding: 8px 10px; text-align: left; border-bottom: 1px solid #ddd2c0; vertical-align: top; }
.levels thead th { background: var(--key); color: var(--paper-hi); font-weight: 700; font-size: .85rem; white-space: nowrap; }
.levels td { font-variant-numeric: tabular-nums; }
.levels .pending { color: #5d5249; font-style: italic; }
@media (max-width: 599px) {
  /* One labelled block per book instead of a table that scrolls sideways. */
  .levels thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .levels tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 14px; padding: 12px 14px; border-bottom: 1px solid #ddd2c0; }
  .levels tr:last-child { border-bottom: 0; }
  .levels th, .levels td { display: block; padding: 0; border: 0; }
  .levels tbody th { grid-column: 1 / -1; }
  .levels td.pending { grid-column: 1 / -1; }
  .levels td[data-label]::before { content: attr(data-label); display: block; font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: #5d5249; }
}
.science { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 12px; }
.sci { padding: 12px 14px; background: #fff; border: 2px solid var(--key); border-left: 10px solid var(--spot); border-radius: 10px; }
.sci p { margin: 0 0 .4em; }
.sci-n { font-size: .9rem; font-weight: 700; }
.sci-stem { font: 400 1.35rem/1.1 var(--f-title); text-transform: uppercase; }
.sci-home { font-size: .98rem; }
.small-parts { font-size: .88rem; color: #6b3d20; font-weight: 600; }
.promise-lede { font: 400 clamp(1.3rem, 3.6vw, 1.7rem)/1.2 var(--f-sfx); letter-spacing: .03em; }
.promise, .plain-list { margin: 10px 0 0; padding-left: 1.3em; }
.promise li, .plain-list li { margin-bottom: .55em; }
.promise li::marker { content: "★  "; color: var(--orange); }
.coloring { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); }
.coloring a { display: flex; flex-direction: column; gap: 6px; padding: 8px; color: var(--key); text-decoration: none; font-weight: 700; background: #fff; border: 3px solid var(--key); border-radius: 10px; box-shadow: 3px 3px 0 var(--key); }
.coloring a:hover { box-shadow: 5px 5px 0 var(--orange); }
.coloring-img { width: 100%; border: 1px solid #ddd2c0; }
.coloring-go { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: .9rem; color: var(--blue-deep); }
.publisher { font-size: 1rem; }
.about-grid { display: grid; gap: 28px; }
@media (min-width: 900px) { .about-grid { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; } }
.about-main { max-width: var(--read); }
.facts { padding: 16px; background: var(--paper); border: 4px solid var(--key); border-radius: 14px; box-shadow: var(--drop); }
.facts-h { font: 400 1.6rem/1 var(--f-title); text-transform: uppercase; }
.facts dl { margin: 0; display: grid; gap: 8px; }
.facts dt { font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #4a403a; }
.facts dd { margin: 0; font-weight: 600; }

/* ------------------------------------------------------------ game pages */
.game-page { padding-top: clamp(14px, 3vw, 28px); }
.wrap-game { max-width: 1240px; }
.game-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 18px; margin-bottom: 12px; }
.game-h { display: flex; align-items: center; gap: 10px; margin: 0; font-size: clamp(1.9rem, 6vw, 3rem); }
.game-h .ico { width: .9em; height: .9em; }
.game-line { margin: 0; font-size: 1.05rem; }
.game-stage { position: relative; display: block; width: 100%; min-width: 0; }
.js .game-stage:not(:has(> :not(noscript)))::before {
  content: "…"; display: grid; place-items: center; min-height: 300px; font: 400 3rem/1 var(--f-sfx); letter-spacing: .2em;
  background: var(--night); color: var(--paper); border: 4px solid var(--key); border-radius: 14px;
}
.game-stage noscript img, .game-soon img, .game-fail img, .still-img { width: 100%; border: 4px solid var(--key); border-radius: 14px; box-shadow: var(--drop-big); }
.game-stage noscript img, .game-fail img { margin-bottom: 20px; }
.game-soon { text-align: center; }
.soon-h { margin: 18px 0 .2em; font: 400 clamp(2.2rem, 8vw, 4rem)/1 var(--f-sfx); letter-spacing: .04em; color: var(--flame-hi);
  -webkit-text-stroke: .06em var(--key); paint-order: stroke fill; text-shadow: .06em .06em 0 var(--orange); }
.game-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin: 22px 0 0; }

/* ------------------------------------------------------------ 404 */
.lost-main { min-height: 100vh; padding: 28px 0; }
.lost-wm a { color: var(--paper-hi); text-decoration: none; }
.lost-wm { font-size: 2rem; margin-bottom: 20px; }
.lost-card { max-width: 760px; padding: 20px; background: var(--paper); color: var(--key); border: 4px solid var(--key); border-radius: 16px; box-shadow: 8px 8px 0 var(--orange); }
.lost-img { width: 100%; margin-bottom: 16px; border: 3px solid var(--key); border-radius: 10px; }
.night .lost-card .page-h { color: var(--key); }

/* ------------------------------------------------------------ footer */
.foot { margin-top: 0; padding: 30px 0 34px; background: var(--key); color: var(--paper); border-top: 6px solid var(--orange); }
.foot-in { display: grid; gap: 18px; }
@media (min-width: 900px) { .foot-in { grid-template-columns: 1.1fr 1.4fr 1fr; align-items: start; } .foot-small { grid-column: 1 / -1; } }
.wm-foot { font-size: 1.8rem; line-height: 1.05; color: var(--paper-hi); text-shadow: .045em .045em 0 var(--orange); margin-bottom: .3em; }
.wm-foot .wm1, .wm-foot .wm2 { display: inline; white-space: normal; }
.foot p { margin: 0 0 .5em; font-size: .98rem; }
.foot .sale strong { color: var(--flame-hi); font-weight: 700; }
.foot-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.foot-nav a { display: inline-flex; align-items: center; min-height: 48px; min-width: 48px; color: var(--paper-hi); font-weight: 600; }
.foot-nav a:hover { color: var(--flame-hi); }
.foot-small { font-size: .85rem !important; color: #c9bfb2; }

/* ------------------------------------------------------------ toast, gate */
.toast {
  position: fixed; z-index: 60; left: 50%; bottom: 16px; width: min(92vw, 420px); transform: translateX(-50%);
  display: flex; align-items: center; gap: 12px; padding: 12px 14px; color: var(--key);
  background: var(--paper-hi); border: 4px solid var(--key); border-radius: 16px; box-shadow: 6px 6px 0 var(--orange);
  animation: toast-in .25s ease-out;
}
.toast-burst { flex: none; display: grid; place-items: center; width: 56px; height: 56px; background: var(--yellow); clip-path: var(--burst); }
.toast-burst .ico { width: 26px; height: 26px; }
.toast-t { margin: 0; font: 400 1.3rem/1.05 var(--f-sfx); letter-spacing: .04em; }
.toast-s { margin: 2px 0 0; font-size: .95rem; }
.toast-x { margin-left: auto; min-width: 48px; min-height: 48px; border: 0; background: none; font-size: 1.6rem; cursor: pointer; }
@keyframes toast-in { from { transform: translate(-50%, 30px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
.gate {
  width: min(92vw, 440px); padding: 20px; color: var(--key); background: var(--paper-hi);
  border: 4px solid var(--key); border-radius: 16px; box-shadow: 8px 8px 0 var(--orange);
}
.gate::backdrop { background: rgba(19, 22, 44, .72); }
.gate h2 { font: 400 1.8rem/1 var(--f-title); text-transform: uppercase; }
.gate label { display: block; font-weight: 700; margin: 10px 0 6px; }
.gate input { width: 8em; min-height: 48px; padding: 6px 10px; font: 600 1.3rem/1 var(--f-text); border: 3px solid var(--key); border-radius: 10px; }
.gate .row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.gate .say { min-height: 1.3em; font-weight: 700; color: #8a2a12; margin: 8px 0 0; }

/* ------------------------------------------------------------ motion */
html[data-motion="off"] *, html[data-motion="off"] *::before, html[data-motion="off"] *::after {
  animation-duration: .001ms !important; animation-iteration-count: 1 !important;
  transition-duration: .001ms !important; scroll-behavior: auto !important;
}
html[data-motion="off"] { scroll-behavior: auto; }
@media (prefers-reduced-motion: reduce) {
  html:not([data-motion="on"]) *, html:not([data-motion="on"]) *::before, html:not([data-motion="on"]) *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important;
    transition-duration: .001ms !important; scroll-behavior: auto !important;
  }
  html:not([data-motion="on"]) { scroll-behavior: auto; }
}

/* ------------------------------------------------------------ print */
/* The Paint Shop and poster print through a .mk-print box appended to <body>
   (css/paint.css shows only that box while html[data-mk-print] is set): never
   hide .mk-print or its contents here. */
@media print {
  body { background: #fff; font-size: 12pt; }
  .top, .nav, .foot, .skip, .share-sec, .booknav, .cta-row, .toast, .card-rev, .quiz-sec, .game-foot { display: none !important; }
  .night, .calm, .chapter { background: #fff !important; color: #000 !important; }
  .card, .bill, .door a, .idea { box-shadow: none !important; }
}
