/* r831.net — Soot & Ember, the game's own UI (R831_DEV docs/ART_BIBLE.md §5):
   blackened iron and brass, an ember glow, square corners, a hard shadow
   down-right as the extrusion. Colours are UIKit's (data/pixel_ui.json). */

@font-face { font-family: "Pixelify Sans"; src: url("/assets/fonts/pixelify-sans-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Pixelify Sans"; src: url("/assets/fonts/pixelify-sans-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Pixelify Sans"; src: url("/assets/fonts/pixelify-sans-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Pixelify Sans"; src: url("/assets/fonts/pixelify-sans-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/assets/fonts/inter-latin-wght-normal.woff2") format("woff2-variations"); font-weight: 100 900; font-display: swap; }

:root {
  --bg: #0a080c;
  --slot: #120e14;
  --panel: #1a141c;
  --btn: #2e262e;
  --btn-hover: #3e3440;
  --text: #ddd2bc;
  --text-dim: #9a8e7c;
  --text-bright: #e6dcc6;
  --border: #4a3010;
  --border-bright: #a07428;
  --gold: #e0b452;
  --gold-light: #ffd870;
  --ember: #f6801a;
  --ember-dark: #c8400a;
  --ember-light: #ffc04a;
  --ice: #5e94b0;
  --violet: #8030a8;
  --good: #8ccf7e;
  --bad: #f0785a;
  --ink: #060408;
  --on-ember: #1e0608;

  --px: "Pixelify Sans", ui-monospace, monospace;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --hard: 3px 3px 0 var(--ink);
  --wrap: 1280px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 1rem/1.65 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-light); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
ul, ol { padding: 0; margin: 0; list-style: none; }
figure { margin: 0; }

.container { width: min(var(--wrap), 100% - var(--gutter) * 2); margin-inline: auto; }
.narrow { width: min(920px, 100% - var(--gutter) * 2); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 100; background: var(--gold); color: var(--ink); padding: 10px 14px; font: 600 14px var(--px); }
.skip:focus { top: 12px; }

.px-icon { width: 24px; height: 24px; flex: none; }

/* ---------- Type ---------- */

.eyebrow { display: inline-flex; align-items: center; gap: 12px; margin: 0 0 14px; font: 600 14px/1 var(--px); letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.eyebrow::before { content: ""; width: 8px; height: 8px; background: var(--ember); box-shadow: 0 0 0 2px var(--ink), 0 0 12px var(--ember); }
.h2, .page-title { margin: 0; font-family: var(--px); font-weight: 700; text-transform: uppercase; color: var(--text-bright); letter-spacing: .01em; }
.h2 { font-size: clamp(2rem, 4.4vw, 3.4rem); line-height: 1.02; text-shadow: 3px 3px 0 var(--ink); }
.h2--xl { font-size: clamp(2.8rem, 7vw, 5.6rem); text-shadow: 4px 4px 0 var(--ink); }
.h3 { margin: 0 0 12px; font: 700 clamp(1.5rem, 2.4vw, 2rem)/1.1 var(--px); text-transform: uppercase; color: var(--text-bright); text-shadow: 2px 2px 0 var(--ink); }
.page-title { font-size: clamp(2.6rem, 7.5vw, 5.4rem); line-height: .98; text-shadow: 4px 4px 0 var(--ink); }
.lede { max-width: 38em; margin: 18px 0 0; font-size: clamp(1.05rem, 1.5vw, 1.25rem); color: var(--text); text-shadow: 1px 1px 0 var(--ink); }
.note { margin: 20px 0 0; font-size: 14px; color: var(--text-dim); }
.tbd { display: inline-block; padding: 2px 6px; font: 600 11px/1.4 var(--px); letter-spacing: .12em; color: var(--bad); border: 2px dashed currentColor; vertical-align: middle; cursor: help; }

/* ---------- Buttons: flat boxes, square corners, a hard shadow ---------- */

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 14px 22px; font: 600 16px/1 var(--px); letter-spacing: .08em; text-transform: uppercase; color: var(--text-bright); background: var(--btn); border: 2px solid var(--border-bright); box-shadow: inset 0 2px 0 #4a3e44, inset 0 -3px 0 #1a141c, var(--hard); cursor: pointer; transition: transform .08s steps(2), box-shadow .08s steps(2), background-color .12s; }
.btn:hover { color: #fff; background: var(--btn-hover); }
.btn:active { transform: translate(3px, 3px); box-shadow: inset 0 2px 0 #4a3e44, inset 0 -3px 0 #1a141c, 0 0 0 var(--ink); }
.btn .px-icon { width: 20px; height: 20px; }
.btn--primary { color: var(--on-ember); background: var(--ember); border-color: var(--ember-light); box-shadow: inset 0 2px 0 var(--gold-light), inset 0 -4px 0 var(--ember-dark), var(--hard), 0 0 28px rgba(246, 128, 26, .38); }
.btn--primary:hover { color: var(--on-ember); background: #ff9430; box-shadow: inset 0 2px 0 #fff0b0, inset 0 -4px 0 var(--ember-dark), var(--hard), 0 0 44px rgba(246, 128, 26, .6); }
.btn--primary:active { box-shadow: inset 0 2px 0 var(--gold-light), inset 0 -4px 0 var(--ember-dark), 0 0 0 var(--ink), 0 0 28px rgba(246, 128, 26, .38); }
.btn--primary:disabled { cursor: not-allowed; filter: saturate(.6) brightness(.85); }
.btn--sm { padding: 10px 14px; font-size: 14px; }
.btn--lg { padding: 18px 30px; font-size: 18px; }
.btn--xl { padding: 22px 36px; font-size: 20px; }
.btn--lg .px-icon, .btn--xl .px-icon { width: 24px; height: 24px; }
.btn.is-off { color: var(--text-dim); background: var(--slot); border-color: var(--border); box-shadow: var(--hard); cursor: default; }

.link-more { display: inline-flex; align-items: center; gap: 10px; font: 600 15px/1 var(--px); letter-spacing: .12em; text-transform: uppercase; color: var(--ember); white-space: nowrap; }
.link-more:hover { color: var(--ember-light); }
.link-more .px-icon { width: 20px; height: 16px; transition: transform .15s steps(3); }
.link-more:hover .px-icon { transform: translateX(4px); }
.links-more { display: flex; flex-wrap: wrap; gap: 14px 28px; }

/* ---------- The iron frame: the game's window page, 9-sliced ---------- */

.frame { border: 24px solid transparent; border-image: url("/assets/ui/frame.svg") 8 / 24px stretch; }
.panel { background: var(--panel); padding: clamp(20px, 3vw, 36px); box-shadow: 0 0 0 0 transparent, 6px 6px 0 rgba(6, 4, 8, .7); }

/* ---------- Header ---------- */

.site-header { position: fixed; inset: 0 0 auto; z-index: 50; height: var(--header-h); background: rgba(10, 8, 12, .86); backdrop-filter: blur(8px); border-bottom: 2px solid var(--border); box-shadow: 0 2px 0 var(--ink); }
.bar { height: 100%; display: flex; align-items: center; gap: clamp(16px, 3vw, 48px); }
.brand img { width: 64px; height: auto; image-rendering: pixelated; } /* the 32 px mark, at 2x */
.nav { display: flex; gap: clamp(14px, 2.2vw, 34px); margin-right: auto; }
.nav a { position: relative; padding: 26px 2px; font: 600 15px/1 var(--px); letter-spacing: .1em; text-transform: uppercase; color: var(--text); }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 16px; height: 4px; background: var(--ember); box-shadow: 0 0 12px var(--ember); transform: scaleX(0); transition: transform .16s steps(4); }
.nav a:hover { color: var(--text-bright); }
.nav a:hover::after { transform: scaleX(.5); }
.nav a[aria-current="page"] { color: var(--gold); }
.nav a[aria-current="page"]::after { transform: scaleX(1); }
.bar-end { display: flex; align-items: center; gap: 12px; margin-left: auto; }

.menu { display: none; }
.menu summary { list-style: none; display: grid; place-items: center; width: 48px; height: 44px; background: var(--btn); border: 2px solid var(--border-bright); box-shadow: var(--hard); cursor: pointer; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary .px-icon { width: 22px; height: 16px; }
.menu-panel { position: fixed; top: var(--header-h); left: 0; right: 0; display: grid; padding: 8px var(--gutter) 24px; background: var(--panel); border-bottom: 2px solid var(--border); box-shadow: 0 6px 0 rgba(6, 4, 8, .7); }
.menu-panel a { padding: 16px 0; font: 600 20px/1 var(--px); letter-spacing: .08em; text-transform: uppercase; color: var(--text); border-bottom: 2px solid var(--slot); }
.menu-panel a[aria-current="page"] { color: var(--gold); }

/* Over the home hero the bar starts clear and fills in as you scroll. */
@supports (animation-timeline: scroll()) {
  .home .site-header { animation: bar-fill linear both; animation-timeline: scroll(root); animation-range: 0 240px; }
  @keyframes bar-fill {
    from { background: rgba(10, 8, 12, 0); border-bottom-color: transparent; box-shadow: none; backdrop-filter: none; }
  }
}

/* ---------- Hero ---------- */

.hero { position: relative; isolation: isolate; overflow: hidden; display: grid; place-items: center; min-height: max(100svh, 720px); padding: calc(var(--header-h) + 48px) 0 140px; text-align: center; }
.hero--small { min-height: 80svh; }
.hero-art { position: absolute; inset: 0; z-index: -3; width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; }
.hero-art--shade { object-position: 50% 50%; filter: brightness(.42) saturate(.85); }
.hero::after, .page-hero::after, .band::before, .band::after, .cta-band::before, .post-hero::after { content: ""; position: absolute; left: 0; right: 0; height: 96px; background: url("/assets/ui/dither.svg") repeat-x bottom / 16px 96px; pointer-events: none; }
.hero::after, .page-hero::after, .band::after, .post-hero::after { bottom: 0; z-index: -1; }
.section--slot + .band::before, .section--slot + .cta-band::before { background-image: url("/assets/ui/dither-slot.svg"); }
.band::before, .cta-band::before { top: 0; z-index: 1; transform: scaleY(-1); }

.lockup { display: grid; justify-items: center; gap: 18px; margin: 0; }
.lockup img { width: min(384px, 72vw); height: auto; image-rendering: pixelated; filter: drop-shadow(0 0 26px rgba(246, 128, 26, .42)) drop-shadow(0 0 2px rgba(255, 216, 112, .4)); }
.cite { display: flex; align-items: center; gap: 18px; padding-left: .4em; font: 600 clamp(14px, 1.6vw, 18px)/1 var(--px); letter-spacing: .4em; text-transform: uppercase; color: var(--gold); text-shadow: 2px 2px 0 var(--ink), 0 0 12px var(--ink); }
.cite::before, .cite::after { content: ""; width: clamp(28px, 6vw, 72px); height: 2px; background: var(--border-bright); box-shadow: 0 2px 0 var(--ink); }
.verse { max-width: 32em; margin: 30px auto 0; font: italic 400 clamp(1.05rem, 1.7vw, 1.3rem)/1.6 var(--sans); color: #fff6e6; text-shadow: 2px 2px 0 var(--ink), 0 0 12px var(--ink), 0 0 28px rgba(6, 4, 8, .85); }
.verse p { margin: 0; }
.verse footer { margin-top: 12px; font: 500 13px/1 var(--px); font-style: normal; letter-spacing: .16em; text-transform: uppercase; color: var(--text); text-shadow: 2px 2px 0 var(--ink), 0 0 10px var(--ink), 0 0 20px rgba(6, 4, 8, .9); }
.hero-tag { margin: 38px 0 20px; font: 600 clamp(13px, 1.4vw, 16px)/1.4 var(--px); letter-spacing: .24em; text-transform: uppercase; color: var(--gold-light); text-shadow: 2px 2px 0 var(--ink), 0 0 12px var(--ink); }
.hero-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
.hero-meta { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 24px; margin-top: 24px; font: 500 13px/1 var(--px); letter-spacing: .16em; text-transform: uppercase; color: var(--text); text-shadow: 2px 2px 0 var(--ink); }
.hero-meta li { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta li + li::before { content: ""; width: 4px; height: 4px; margin-right: 16px; background: var(--border-bright); }
.hero-meta .px-icon { width: 16px; height: 16px; }
.scroll-cue { position: absolute; bottom: 28px; left: 50%; translate: -50% 0; z-index: 1; animation: bob 1.6s steps(4) infinite; }
.scroll-cue .px-icon { width: 30px; height: 18px; }
@keyframes bob { 50% { transform: translateY(6px); } }

.embers { position: absolute; inset: 0; z-index: -2; overflow: hidden; pointer-events: none; }
.embers i { position: absolute; bottom: -12px; left: var(--x); width: var(--s); height: var(--s); background: var(--c); box-shadow: 0 0 8px var(--c), 0 0 2px #fff0b0; opacity: 0; animation: rise var(--d) linear var(--t) infinite; }
@keyframes rise {
  0% { transform: translate(0, 0); opacity: 0; }
  12% { opacity: 1; }
  60% { opacity: .85; }
  100% { transform: translate(var(--dx), -82vh); opacity: 0; }
}

/* ---------- Page hero ---------- */

.page-hero, .post-hero { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end; min-height: clamp(380px, 58vh, 580px); padding: calc(var(--header-h) + 56px) 0 88px; }
.page-hero-art { position: absolute; inset: 0; z-index: -3; width: 100%; height: 100%; object-fit: cover; }
.page-hero::before, .post-hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(90deg, rgba(10, 8, 12, .86), rgba(10, 8, 12, .5) 45%, rgba(10, 8, 12, 0) 80%); }

/* ---------- Sections ---------- */

.section { position: relative; padding-block: clamp(64px, 9vw, 120px); }
.section--slot { background: var(--slot); border-block: 2px solid var(--ink); }
.page-hero + .section, .hero + .section { padding-top: clamp(40px, 5vw, 72px); }
.section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 32px; margin-bottom: clamp(28px, 4vw, 48px); }
.section-head--center { justify-content: center; text-align: center; }

/* ---------- Cards ---------- */

.card { position: relative; background: var(--panel); border: 2px solid var(--border); box-shadow: var(--hard); transition: transform .12s steps(3), box-shadow .12s steps(3), border-color .12s; }
a.card:hover, .card:has(.card-link:hover) { transform: translate(-3px, -3px); box-shadow: 6px 6px 0 var(--ink); border-color: var(--border-bright); }
.card-link { display: flex; flex-direction: column; height: 100%; color: inherit; }
.card-link:hover { color: inherit; }
.card-art { position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-bottom: 2px solid var(--border); background: var(--slot); }
.card-art img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.card:hover .card-art img { transform: scale(1.06); }
.card-body { display: flex; flex-direction: column; flex: 1; padding: 20px 22px 24px; }
.card-body time { font: 500 13px/1 var(--px); letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim); }
.card-body h3 { margin: 10px 0; font: 600 22px/1.15 var(--px); color: var(--text-bright); }
.card-body p { margin: 0 0 18px; font-size: 15px; color: var(--text-dim); }
.card-more { display: inline-flex; align-items: center; gap: 10px; margin-top: auto; font: 600 13px/1 var(--px); letter-spacing: .14em; text-transform: uppercase; color: var(--ember); }
.card-more .px-icon { width: 18px; height: 14px; transition: transform .15s steps(3); }
.card:hover .card-more .px-icon { transform: translateX(4px); }

.chip { display: inline-block; padding: 7px 9px 6px; font: 600 12px/1 var(--px); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); background: var(--ink); border: 2px solid var(--border-bright); }
.card-art .chip { position: absolute; left: 12px; top: 12px; }
.card-play { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: grid; place-items: center; width: 56px; height: 56px; background: var(--ember); border: 2px solid var(--ember-light); box-shadow: inset 0 -3px 0 var(--ember-dark), var(--hard); }
.card-play .px-icon { width: 24px; height: 24px; margin-left: 3px; }
.chip--announcement { color: var(--on-ember); background: var(--ember); border-color: var(--ember-light); }
.chip--patch-notes { color: #a0d0e4; border-color: #346078; }
.chip--community { color: var(--good); border-color: #3e4a2c; }

.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.news-grid--index .news-card:first-child { grid-column: span 2; }
.news-grid--index .news-card:first-child .card-link { display: grid; grid-template-columns: 1.35fr 1fr; }
.news-grid--index .news-card:first-child .card-art { aspect-ratio: auto; min-height: 100%; border-bottom: 0; border-right: 2px solid var(--border); }
.news-grid--index .news-card:first-child .card-body { justify-content: center; padding: 32px; }
.news-grid--index .news-card:first-child h3 { font-size: clamp(26px, 2.6vw, 34px); }

/* Filter tabs: radios, no script. */
.tabs { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 36px; }
.tabs input { position: absolute; opacity: 0; pointer-events: none; }
.tabs label { padding: 11px 16px 10px; font: 600 14px/1 var(--px); letter-spacing: .1em; text-transform: uppercase; color: var(--text-dim); background: var(--slot); border: 2px solid var(--border); box-shadow: var(--hard); cursor: pointer; }
.tabs label:hover { color: var(--text-bright); }
.tabs input:checked + label { color: var(--gold); background: var(--btn); border-color: var(--border-bright); }
.tabs input:focus-visible + label { outline: 2px solid var(--gold); outline-offset: 3px; }
.news-index:has(#cat-all:not(:checked)) .news-grid--index .news-card:first-child { grid-column: auto; }
.news-index:has(#cat-all:not(:checked)) .news-grid--index .news-card:first-child .card-link { display: flex; }
.news-index:has(#cat-all:not(:checked)) .news-grid--index .news-card:first-child .card-art { aspect-ratio: 16 / 9; border-right: 0; border-bottom: 2px solid var(--border); }
.news-index:has(#cat-all:not(:checked)) .news-grid--index .news-card:first-child .card-body { padding: 20px 22px 24px; }
.news-index:has(#cat-all:not(:checked)) .news-grid--index .news-card:first-child h3 { font-size: 22px; }
.news-index:has(#cat-announcement:checked) .news-card:not([data-cat="announcement"]),
.news-index:has(#cat-devlog:checked) .news-card:not([data-cat="devlog"]),
.news-index:has(#cat-patch-notes:checked) .news-card:not([data-cat="patch-notes"]),
.news-index:has(#cat-community:checked) .news-card:not([data-cat="community"]) { display: none; }

.pager { display: flex; justify-content: center; gap: 8px; margin-top: 48px; }
.pager-btn { display: grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px; font: 600 16px/1 var(--px); color: var(--text-dim); background: var(--slot); border: 2px solid var(--border); box-shadow: var(--hard); }
.pager-btn[aria-current] { color: var(--on-ember); background: var(--ember); border-color: var(--ember-light); }
.pager-btn .px-icon { width: 18px; height: 14px; }

/* ---------- Home: pillars, band, shots, duo ---------- */

.pillars { display: grid; grid-template-columns: repeat(6, 1fr); gap: 24px; }
.pillar { grid-column: span 2; padding: 32px 26px 30px; background: var(--panel); border: 2px solid var(--border); box-shadow: var(--hard); }
.pillar:nth-child(n+4) { grid-column: span 3; }
.pillar .px-icon { width: 60px; height: 60px; margin-bottom: 22px; }
.pillar h3 { margin: 0 0 10px; font: 700 20px/1.15 var(--px); text-transform: uppercase; color: var(--text-bright); }
.pillar p { margin: 0; font-size: 15px; color: var(--text-dim); }

.band { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: center; min-height: clamp(460px, 64vh, 680px); }
.band-art { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.band-inner { display: grid; justify-items: end; text-align: right; }
.band-inner .btn { margin-top: 28px; }

.shots { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: repeat(2, auto); gap: 16px; }
.shot { position: relative; overflow: hidden; border: 2px solid var(--border); box-shadow: var(--hard); background: var(--slot); }
.shot img { width: 100%; height: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.shot:hover img { transform: scale(1.05); }
.shot--wide { grid-row: span 2; }
.shot figcaption { position: absolute; left: 10px; bottom: 10px; padding: 6px 8px 5px; font: 600 11px/1 var(--px); letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); background: rgba(6, 4, 8, .82); border: 2px solid var(--border); }
.shots .shot:nth-child(4) { grid-column: 2 / span 2; }

.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.channel-list { display: grid; gap: 10px; margin-top: 20px; }
.channel-list li { display: flex; align-items: center; gap: 14px; padding: 10px 14px; background: var(--slot); border: 2px solid var(--ink); }
.channel-list .px-icon { width: 26px; height: 26px; }
.channel-list span { font: 600 16px/1 var(--px); color: var(--text-bright); }
.channel-list em { margin-left: auto; font: 500 12px/1 var(--px); font-style: normal; letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim); }

/* ---------- Forms ---------- */

.signup { display: grid; gap: 16px; margin-top: 18px; }
.field-row { display: flex; gap: 12px; }
.field-row input { flex: 1; min-width: 0; padding: 14px 16px; font: 400 16px var(--sans); color: var(--text-bright); background: var(--slot); border: 2px solid var(--border); box-shadow: inset 3px 3px 0 var(--ink); }
.field-row input::placeholder { color: #6e665a; }
.field-row input:focus { outline: none; border-color: var(--gold); }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--text); cursor: pointer; }
.check input { appearance: none; flex: none; width: 20px; height: 20px; margin: 2px 0 0; background: var(--slot); border: 2px solid var(--border-bright); box-shadow: 2px 2px 0 var(--ink); cursor: pointer; }
.check input:checked { background: var(--ember); box-shadow: inset 0 0 0 3px var(--slot), 2px 2px 0 var(--ink); }
.fine { margin: 0; font-size: 13px; color: var(--text-dim); }

/* ---------- Game page ---------- */

.feature { display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; gap: clamp(32px, 6vw, 88px); }
.feature + .feature { margin-top: clamp(72px, 10vw, 136px); }
.feature:nth-child(even) .feature-art { order: 2; }
.feature-art { background: var(--slot); box-shadow: 8px 8px 0 rgba(6, 4, 8, .7); }
.feature-art img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.feature-text > p:not(.eyebrow) { margin: 20px 0 0; font-size: 1.08rem; }
.feature-text .btn { margin-top: 28px; }
.ticks { display: grid; gap: 10px; margin-top: 24px; }
.ticks li { display: flex; align-items: center; gap: 14px; font: 500 15px/1.3 var(--px); letter-spacing: .04em; color: var(--text-bright); }
.ticks li::before { content: ""; flex: none; width: 10px; height: 10px; background: var(--gold); box-shadow: 0 0 0 2px var(--ink), 3px 3px 0 2px var(--ink); }
.status-panel { max-width: 760px; margin-inline: auto; text-align: center; }
.status-panel .eyebrow { justify-content: center; }
.status-panel p:last-child { margin: 0; color: var(--text); }

/* ---------- Media ---------- */

.media-panel { display: none; }
.media:has(#m-shots:checked) [data-panel="shots"],
.media:has(#m-videos:checked) [data-panel="videos"],
.media:has(#m-walls:checked) [data-panel="walls"],
.media:has(#m-brand:checked) [data-panel="brand"] { display: block; }
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.gallery--walls { grid-template-columns: repeat(2, 1fr); gap: 28px; }
.sizes { display: flex; flex-wrap: wrap; gap: 8px; }
.sizes span { padding: 6px 8px 5px; font: 600 12px/1 var(--px); letter-spacing: .08em; color: var(--text-dim); background: var(--slot); border: 2px solid var(--border); }
.videos { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; }
.video { position: relative; overflow: hidden; border: 2px solid var(--border); box-shadow: var(--hard); }
.video--main { grid-row: span 2; }
.video img { width: 100%; height: 100%; aspect-ratio: 16 / 9; object-fit: cover; filter: brightness(.7); }
.video .play { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: grid; place-items: center; width: 72px; height: 72px; background: var(--ember); border: 2px solid var(--ember-light); box-shadow: inset 0 -4px 0 var(--ember-dark), var(--hard), 0 0 36px rgba(246, 128, 26, .5); }
.video--main .play { width: 104px; height: 104px; }
.video .play .px-icon { width: 30px; height: 30px; margin-left: 4px; }
.video figcaption { position: absolute; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; background: linear-gradient(transparent, rgba(6, 4, 8, .9)); }
.video figcaption strong { font: 700 20px/1 var(--px); text-transform: uppercase; color: var(--text-bright); }
.video figcaption span { font: 500 12px/1 var(--px); letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim); }
.brand-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.brand-tile { display: grid; place-items: center; gap: 18px; min-height: 260px; text-align: center; }
.brand-tile img { width: min(256px, 100%); image-rendering: pixelated; }
.brand-tile .brand-mark { width: 128px; }
.brand-tile--light { background: #ddd2bc; border: 2px solid var(--border-bright); box-shadow: var(--hard); }
.brand-tile figcaption { font: 600 12px/1 var(--px); letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); }
.brand-tile--light figcaption { color: #48423c; }

/* ---------- Download ---------- */

.dl { display: grid; grid-template-columns: 1.3fr 1fr; align-items: center; gap: 40px; padding: clamp(28px, 4vw, 56px); }
.dl-main > p:not(.eyebrow):not(.dl-meta) { margin: 16px 0 30px; font-size: 1.1rem; }
.dl-meta { margin: 22px 0 0; font: 500 13px/1 var(--px); letter-spacing: .1em; text-transform: uppercase; color: var(--text-dim); }
.dl-art { width: min(100%, 384px); justify-self: center; image-rendering: pixelated; filter: drop-shadow(0 0 30px rgba(246, 128, 26, .35)); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 48px; }
.step { padding: 28px 26px; background: var(--panel); border: 2px solid var(--border); box-shadow: var(--hard); }
.step-n { display: block; font: 700 44px/1 var(--px); color: var(--ember); text-shadow: 3px 3px 0 var(--ink), 0 0 20px rgba(246, 128, 26, .4); }
.step h3 { margin: 16px 0 8px; font: 700 20px/1 var(--px); text-transform: uppercase; color: var(--text-bright); }
.step p { margin: 0; color: var(--text-dim); }
.spec { width: 100%; border-collapse: collapse; background: var(--panel); border: 2px solid var(--border); box-shadow: var(--hard); }
.spec th, .spec td { padding: 16px 20px; text-align: left; border-bottom: 2px solid var(--slot); }
.spec thead th { font: 600 13px/1 var(--px); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); background: var(--btn); }
.spec tbody th { font: 600 15px/1 var(--px); color: var(--text-bright); }
.verify { margin-top: 32px; }
.verify h3 { margin: 0 0 8px; font: 700 18px/1 var(--px); text-transform: uppercase; color: var(--text-bright); }
.verify p { margin: 0 0 14px; color: var(--text-dim); }
.verify code { display: block; padding: 12px 14px; font: 500 14px/1.4 ui-monospace, monospace; color: var(--text); background: var(--slot); border: 2px solid var(--ink); overflow-x: auto; }

/* ---------- Community, support, press, legal ---------- */

.channels { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.channel { display: grid; justify-items: start; gap: 10px; padding: 28px 24px; }
.channel .px-icon { width: 52px; height: 52px; margin-bottom: 6px; }
.channel h3 { margin: 0; font: 700 22px/1 var(--px); text-transform: uppercase; color: var(--text-bright); }
.channel p { margin: 0 0 8px; color: var(--text-dim); }

.search { display: flex; align-items: center; gap: 14px; padding: 14px 18px; margin-bottom: 40px; background: var(--slot); border: 2px solid var(--border); box-shadow: inset 3px 3px 0 var(--ink); }
.search input { flex: 1; min-width: 0; padding: 4px 0; font: 400 17px var(--sans); color: var(--text); background: none; border: 0; }
.search input:focus { outline: none; }
.faq-group { margin: 40px 0 16px; font: 600 14px/1 var(--px); letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.faq-group:first-child { margin-top: 0; }
.faq details { margin-bottom: 12px; background: var(--panel); border: 2px solid var(--border); box-shadow: var(--hard); }
.faq details[open] { border-color: var(--border-bright); }
.faq summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 22px; font: 600 18px/1.25 var(--px); color: var(--text-bright); list-style: none; cursor: pointer; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 700 24px/1 var(--px); color: var(--gold); }
.faq details[open] summary::after { content: "−"; color: var(--ember); }
.faq .answer { padding: 0 22px 18px; }
.faq .answer p { margin: 0; }
.contact { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; margin-top: 48px; }
.contact p:last-child { margin: 0; color: var(--text-dim); }

.press { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: start; }
.facts { display: grid; margin: 0 0 40px; border: 2px solid var(--border); box-shadow: var(--hard); }
.facts div { display: grid; grid-template-columns: 180px 1fr; gap: 16px; padding: 14px 18px; background: var(--panel); }
.facts div:nth-child(even) { background: var(--slot); }
.facts dt { font: 600 13px/1.5 var(--px); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.facts dd { margin: 0; color: var(--text-bright); }
.press-side { display: grid; gap: 24px; }
.press-side h3 { margin: 0 0 16px; font: 700 18px/1 var(--px); text-transform: uppercase; color: var(--text-bright); }
.dl-list { display: grid; gap: 10px; }
.dl-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; background: var(--slot); border: 2px solid var(--ink); }

.legal-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; }
.legal-card { display: grid; gap: 18px; padding: 24px; height: 100%; color: inherit; }
.legal-card h3 { margin: 0; font: 700 20px/1.15 var(--px); text-transform: uppercase; color: var(--text-bright); }
.legal { display: grid; grid-template-columns: 240px 1fr; gap: clamp(32px, 5vw, 72px); align-items: start; padding-block: clamp(56px, 7vw, 96px); }
.legal-nav { position: sticky; top: calc(var(--header-h) + 24px); display: grid; border: 2px solid var(--border); box-shadow: var(--hard); }
.legal-nav a { padding: 14px 16px; font: 600 14px/1.2 var(--px); letter-spacing: .06em; text-transform: uppercase; color: var(--text-dim); background: var(--panel); border-bottom: 2px solid var(--slot); }
.legal-nav a:last-child { border-bottom: 0; }
.legal-nav a:hover { color: var(--text-bright); }
.legal-nav a[aria-current="page"] { color: var(--on-ember); background: var(--ember); }
.draft-note, .sample-note { margin: 0 0 32px; padding: 12px 16px; font: 600 13px/1.4 var(--px); letter-spacing: .08em; text-transform: uppercase; color: var(--bad); background: var(--slot); border: 2px dashed var(--bad); }

/* ---------- Posts ---------- */

.post-hero { min-height: clamp(420px, 64vh, 640px); }
.post-hero--video { min-height: 0; padding-bottom: 56px; } /* the video below is the picture */
.post-title { max-width: 18em; font-size: clamp(2.2rem, 5.4vw, 4.2rem); }
.back { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 26px; font: 600 14px/1 var(--px); letter-spacing: .12em; text-transform: uppercase; color: var(--gold); text-shadow: 2px 2px 0 var(--ink); }
.back .px-icon { width: 18px; height: 14px; transform: scaleX(-1); }
.post-meta { display: flex; align-items: center; gap: 16px; margin: 0 0 18px; font: 500 14px/1 var(--px); letter-spacing: .12em; text-transform: uppercase; color: var(--text); text-shadow: 2px 2px 0 var(--ink); }
.post-meta .chip { text-shadow: none; }
.post-body { padding-block: clamp(48px, 6vw, 80px) clamp(64px, 8vw, 112px); }
.prose { max-width: 70ch; margin-inline: auto; font-size: 1.075rem; }
.legal .prose { margin: 0; }
.prose h2 { margin: 2.2em 0 .6em; font: 700 clamp(1.5rem, 2.4vw, 1.9rem)/1.15 var(--px); text-transform: uppercase; color: var(--text-bright); text-shadow: 2px 2px 0 var(--ink); }
.prose > h2:first-of-type { margin-top: 0; }
.prose p, .prose ul { margin: 0 0 1.25em; }
.prose ul { display: grid; gap: .5em; }
.prose ul li { position: relative; padding-left: 26px; }
.prose ul li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 8px; height: 8px; background: var(--ember); box-shadow: 0 0 0 2px var(--ink); }
.prose blockquote { margin: 1.8em 0; padding: 6px 0 6px 24px; font: italic 400 1.25rem/1.55 var(--sans); color: var(--text-bright); border-left: 4px solid var(--ember); }
.prose blockquote p { margin: 0; }
.prose figure { margin: 2em 0; }
.prose figure img { width: 100%; border: 2px solid var(--border); box-shadow: var(--hard); }
.prose figcaption { margin-top: 12px; font-size: 14px; color: var(--text-dim); }
.prose a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }

/* A devlog's video: a still until pressed (assets/js/yt.js) */
.yt { max-width: 1040px; margin: 0 auto clamp(40px, 5vw, 64px); }
.yt-link, .yt iframe { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border: 2px solid var(--border); box-shadow: var(--hard); background: var(--ink); }
.yt iframe { border-color: var(--border-bright); }
.yt-link img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.78); transition: filter .15s steps(3); }
.yt-link:hover img { filter: brightness(.95); }
.yt .play { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: grid; place-items: center; width: 96px; height: 96px; background: var(--ember); border: 2px solid var(--ember-light); box-shadow: inset 0 -4px 0 var(--ember-dark), var(--hard), 0 0 36px rgba(246, 128, 26, .5); }
.yt .play .px-icon { width: 34px; height: 34px; margin-left: 5px; }
.yt figcaption { margin-top: 12px; font-size: 13px; color: var(--text-dim); text-align: center; }

/* ---------- Footer ---------- */

.cta-band { position: relative; isolation: isolate; overflow: hidden; display: grid; place-items: center; min-height: 440px; padding: 120px 0; text-align: center; }
.cta-art { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 50% 70%; filter: brightness(.7); }
.cta-inner { display: grid; justify-items: center; }
.cta-inner .eyebrow { justify-content: center; }
.cta-sub { margin: 16px 0 30px; font-size: 1.15rem; color: var(--text-bright); text-shadow: 2px 2px 0 var(--ink); }
.site-footer { background: var(--slot); border-top: 2px solid var(--ink); }
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 40px; padding-block: 72px 56px; }
.footer-brand img { width: 128px; image-rendering: pixelated; }
.cta-band--news .signup { width: min(560px, 100%); text-align: left; }
.cta-band--news .cta-sub { margin-bottom: 8px; }
.footer-cite { margin: 14px 0 0; font: 600 13px/1 var(--px); letter-spacing: .3em; text-transform: uppercase; color: var(--text-dim); }
.socials { display: flex; gap: 10px; margin-top: 24px; }
.socials a { display: grid; place-items: center; width: 46px; height: 46px; background: var(--panel); border: 2px solid var(--border); box-shadow: var(--hard); }
.socials a:hover { border-color: var(--border-bright); }
.socials .px-icon { width: 24px; height: 24px; }
.footer-col h2 { margin: 0 0 16px; font: 600 14px/1 var(--px); letter-spacing: .18em; text-transform: uppercase; color: var(--gold); }
.footer-col a { display: block; padding: 6px 0; font-size: 15px; color: var(--text-dim); }
.footer-col a:hover { color: var(--text-bright); }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-block: 22px 30px; font-size: 13px; color: var(--text-dim); border-top: 2px solid var(--panel); }
.footer-base p { margin: 0; }


/* ---------- Narrow screens ---------- */

@media (max-width: 1080px) {
  .pillars, .channels { grid-template-columns: repeat(2, 1fr); }
  .pillar, .pillar:nth-child(n+4) { grid-column: auto; }
  .pillar:last-child { grid-column: 1 / -1; }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .news-grid--home .news-card:nth-child(3) { display: none; }
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 960px) {
  .nav { display: none; }
  .menu { display: block; }
  .feature, .duo, .dl, .press, .legal { grid-template-columns: 1fr; }
  .feature:nth-child(even) .feature-art { order: 0; }
  .dl-art { display: none; }
  .legal-nav { position: static; }
  .videos { grid-template-columns: 1fr; }
  .band-inner { justify-items: start; text-align: left; }
}

@media (max-width: 720px) {
  .news-grid, .pillars, .channels, .steps, .gallery, .gallery--walls, .brand-grid { grid-template-columns: 1fr; }
  .news-grid--home .news-card:nth-child(3) { display: block; }
  .news-grid--index .news-card:first-child { grid-column: auto; }
  .news-grid--index .news-card:first-child .card-link { display: flex; }
  .news-grid--index .news-card:first-child .card-art { aspect-ratio: 16 / 9; border-right: 0; border-bottom: 2px solid var(--border); }
  .shots { grid-template-columns: 1fr 1fr; }
  .shot--wide { grid-column: 1 / -1; grid-row: auto; }
  .shots .shot:nth-child(4) { grid-column: auto; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .bar-end .btn--sm span { display: none; }
  .field-row { flex-direction: column; }
  .facts div { grid-template-columns: 1fr; gap: 4px; }
  .hero-cta .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .embers, .hero-video { display: none; }
}
