/* ============================================================
   BONKERS — site design system (reusable component library)
   Warm-dark poster identity: kraft + gold + rubber-stamp red.
   Deliberately single-theme (commits to the artwork's world).
   ============================================================ */

:root {
	/* — warm neutrals (biased toward the gold/kraft accent, not pure black) — */
	--ink:        #100c09;
	--ink-1:      #16110c;
	--ink-2:      #1e1811;
	--line:       rgba(199, 154, 99, 0.16);
	--line-soft:  rgba(199, 154, 99, 0.09);

	/* — accents — */
	--gold:        #e7b53c;
	--gold-bright: #ffd24a;
	--kraft:       #c79a63;
	--stamp:       #c43b2c;

	/* — text — */
	--paper:  #f3ead9;
	--muted:  #a2937c;
	--faint:  #6f6555;

	/* — type — */
	--font-display: ui-rounded, "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
	--font-body:    "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;

	/* — scale — */
	--maxw: 1120px;
	--pad:  clamp(20px, 5vw, 64px);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
	margin: 0;
	background: var(--ink);
	color: var(--paper);
	font-family: var(--font-body);
	font-size: 17px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
	/* faint warm vignette so the ground reads as lit, not flat black */
	background-image:
		radial-gradient(1200px 620px at 50% -8%, rgba(231, 181, 60, 0.10), transparent 62%),
		radial-gradient(900px 700px at 88% 8%, rgba(196, 59, 44, 0.06), transparent 60%);
	background-attachment: fixed;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---------- layout primitives ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad); }

.section { padding-block: clamp(56px, 9vw, 120px); }
.section--tight { padding-block: clamp(40px, 6vw, 72px); }

.eyebrow {
	font-family: var(--font-display);
	font-size: 12.5px;
	font-weight: 800;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--gold);
	margin: 0 0 14px;
}

.h-sec {
	font-family: var(--font-display);
	font-weight: 900;
	font-size: clamp(28px, 4.6vw, 46px);
	line-height: 1.04;
	letter-spacing: -0.01em;
	text-wrap: balance;
	margin: 0 0 16px;
}

.lede { color: var(--muted); font-size: clamp(17px, 2vw, 20px); max-width: 60ch; }

/* ---------- rubber-stamp motif (the one flourish) ---------- */
.stamp {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-family: var(--font-display);
	font-weight: 800;
	font-size: 12px;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--stamp);
	padding: 7px 13px;
	border: 2px solid var(--stamp);
	border-radius: 4px;
	transform: rotate(-3.5deg);
	opacity: 0.92;
	background: rgba(196, 59, 44, 0.05);
}

/* ---------- buttons ---------- */
.btn {
	--btn-bg: transparent;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	font-family: var(--font-display);
	font-weight: 800;
	font-size: 16px;
	letter-spacing: 0.01em;
	padding: 15px 26px;
	border-radius: 12px;
	border: 2px solid transparent;
	background: var(--btn-bg);
	color: var(--paper);
	cursor: pointer;
	transition: transform 0.14s ease, box-shadow 0.14s ease, background 0.14s ease, border-color 0.14s ease;
}
.btn:focus-visible { outline: 3px solid var(--gold-bright); outline-offset: 3px; }
.btn:hover { transform: translateY(-2px); }
@media (prefers-reduced-motion: reduce) { .btn:hover { transform: none; } }

.btn--gold {
	background: linear-gradient(180deg, var(--gold-bright), var(--gold));
	color: #2a1e08;
	box-shadow: 0 10px 26px rgba(231, 181, 60, 0.28);
}
.btn--gold:hover { box-shadow: 0 14px 34px rgba(231, 181, 60, 0.42); }

.btn--ghost { border-color: var(--line); background: rgba(199, 154, 99, 0.04); color: var(--paper); }
.btn--ghost:hover { border-color: var(--gold); background: rgba(231, 181, 60, 0.08); }

.btn__sub { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.75; }

/* ---------- top nav ---------- */
.nav {
	position: sticky; top: 0; z-index: 50;
	backdrop-filter: blur(9px);
	background: linear-gradient(180deg, rgba(16, 12, 9, 0.86), rgba(16, 12, 9, 0.4));
	border-bottom: 1px solid var(--line-soft);
}
.nav__row { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.nav__brand { font-family: var(--font-display); font-weight: 900; letter-spacing: 0.16em; color: var(--gold); font-size: 19px; }
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__links a { color: var(--muted); font-weight: 600; font-size: 15px; transition: color 0.12s ease; }
.nav__links a:hover { color: var(--paper); }
.nav__links a.is-cta { color: var(--gold); }
/* Mobile: don't hide the links (that stranded every page but Discord) — let the
   bar wrap to a second row so all destinations stay reachable without JS. */
@media (max-width: 680px) {
	.nav__row { height: auto; flex-wrap: wrap; padding-block: 10px; row-gap: 8px; }
	.nav__links { width: 100%; gap: 8px 16px; flex-wrap: wrap; justify-content: flex-start; }
	.nav__links a { font-size: 14px; }
}

/* ---------- hero ---------- */
.hero { position: relative; padding-top: clamp(28px, 5vw, 56px); padding-bottom: clamp(40px, 6vw, 80px); text-align: center; }
.hero__art {
	width: min(980px, 100%);
	margin: 0 auto clamp(22px, 3vw, 34px);
	border-radius: 16px;
	filter: drop-shadow(0 30px 70px rgba(0, 0, 0, 0.6));
	animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.hero__stamp { display: flex; justify-content: center; margin-bottom: 20px; animation: rise 0.7s 0.05s cubic-bezier(0.2,0.7,0.2,1) both; }
.hero__tagline {
	font-family: var(--font-display);
	font-weight: 900;
	font-size: clamp(26px, 4.4vw, 44px);
	line-height: 1.05;
	letter-spacing: -0.015em;
	text-wrap: balance;
	max-width: 18ch;
	margin: 0 auto 16px;
	animation: rise 0.7s 0.1s cubic-bezier(0.2,0.7,0.2,1) both;
}
.hero__tagline .hl { color: var(--gold); }
.hero__sub { color: var(--muted); max-width: 52ch; margin: 0 auto 12px; font-size: clamp(16px, 2vw, 19px); animation: rise 0.7s 0.15s cubic-bezier(0.2,0.7,0.2,1) both; }
/* Only the final subtitle carries the gap down to the buttons, so a second line
   sits tight under the first instead of opening a hole mid-hero. */
.hero__sub:last-of-type { margin-bottom: clamp(26px, 3vw, 34px); }
/* The personality line: lands just after the genre line, in warmer ink. */
.hero__sub--wild { color: #cdbfa6; animation-delay: 0.2s; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; animation: rise 0.7s 0.25s cubic-bezier(0.2,0.7,0.2,1) both; }

@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .hero__art, .hero__stamp, .hero__tagline, .hero__sub, .hero__cta { animation: none; } }

/* ---------- feature cards (kraft surfaces) ---------- */
.grid-feat { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 900px) { .grid-feat { grid-template-columns: 1fr; } }

.card {
	background:
		linear-gradient(180deg, rgba(199, 154, 99, 0.07), rgba(199, 154, 99, 0.02)),
		var(--ink-1);
	border: 1px solid var(--line);
	border-radius: 16px;
	padding: 28px 26px 30px;
	transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}
.card:hover { transform: translateY(-4px); border-color: rgba(231, 181, 60, 0.4); }
@media (prefers-reduced-motion: reduce) { .card:hover { transform: none; } }
.card__ic { font-size: 30px; line-height: 1; margin-bottom: 16px; }
.card__t { font-family: var(--font-display); font-weight: 800; font-size: 21px; margin: 0 0 8px; }
.card__d { color: var(--muted); font-size: 15.5px; margin: 0; }

/* ---------- banner (humor line) ---------- */
.banner {
	border: 1px dashed rgba(199, 154, 99, 0.35);
	border-radius: 16px;
	background: rgba(196, 59, 44, 0.05);
	padding: clamp(26px, 4vw, 40px);
	text-align: center;
}
.banner__t { font-family: var(--font-display); font-weight: 900; font-size: clamp(22px, 3.4vw, 34px); margin: 0 0 8px; text-wrap: balance; }
.banner__d { color: var(--muted); margin: 0 auto; max-width: 54ch; }

/* ---------- screenshot tiles (honest placeholders) ---------- */
.grid-shots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 820px) { .grid-shots { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .grid-shots { grid-template-columns: 1fr; } }
.shot {
	aspect-ratio: 16 / 10;
	border-radius: 12px;
	border: 1px solid var(--line);
	background:
		repeating-linear-gradient(135deg, rgba(199,154,99,0.05) 0 12px, rgba(199,154,99,0.02) 12px 24px),
		var(--ink-2);
	display: flex; align-items: center; justify-content: center;
	color: var(--faint);
	font-family: var(--font-display); font-weight: 700; font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase;
}

.shot--art { position: relative; overflow: hidden; aspect-ratio: 1 / 1; background: var(--ink-1); text-decoration: none; }
.shot--art img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease; }
.shot--art:hover img, .shot--art:focus-visible img { transform: scale(1.04); }
.shot__cap {
	position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 14px 12px;
	background: linear-gradient(to top, rgba(16,12,9,0.92), rgba(16,12,9,0));
	color: var(--muted); font-family: var(--font-body, inherit); font-weight: 600; font-size: 12px;
	letter-spacing: 0.06em; text-transform: none; text-align: left;
}
.shot__cap b { display: block; color: var(--gold); font-family: var(--font-display); font-size: 15px; letter-spacing: 0.02em; }
.wiki-nav a:not([href]), .cat-card.is-soon { opacity: 0.55; cursor: default; }
.cat-card.is-soon:hover { transform: none; }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(28px, 5vw, 60px); align-items: start; }
@media (max-width: 820px) { .about { grid-template-columns: 1fr; } }
.about p { color: var(--muted); }
.about p + p { margin-top: 14px; }
.stat-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 22px; }
.stat { flex: 1 1 120px; border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; background: var(--ink-1); }
.stat__n { font-family: var(--font-display); font-weight: 900; font-size: 24px; color: var(--gold); }
.stat__l { color: var(--muted); font-size: 13px; letter-spacing: 0.04em; }

/* ---------- creator note (deadpan: facts small, turn big, shrug tiny) ---------- */
.creator { text-align: center; }
.creator__facts { color: var(--muted); max-width: 54ch; margin: 0 auto; }
.creator__turn {
	font-family: var(--font-display);
	font-weight: 900;
	font-size: clamp(21px, 3vw, 30px);
	line-height: 1.15;
	text-wrap: balance;
	margin: 16px auto 0;
}
.creator__note { color: var(--faint); font-size: 14px; margin: 14px auto 0; }

/* ---------- CTA / newsletter ---------- */
.join { text-align: center; }
.join__form { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 22px; }
.field {
	background: var(--ink-1); border: 2px solid var(--line); color: var(--paper);
	border-radius: 12px; padding: 14px 18px; font-size: 16px; font-family: var(--font-body);
	/* flex-basis 260 but allowed to shrink (min-width:0) so it never overflows
	   narrow phones; capped so it doesn't sprawl on desktop */
	flex: 1 1 260px; min-width: 0; max-width: 360px;
}
.field:focus-visible { outline: none; border-color: var(--gold); }
.field::placeholder { color: var(--faint); }
.join__note { color: var(--faint); font-size: 13px; margin-top: 14px; }
.join__msg { color: var(--gold-bright); font-weight: 700; margin-top: 14px; min-height: 1.2em; }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--line-soft); background: var(--ink-1); }
.foot__row { display: flex; flex-wrap: wrap; gap: 24px; justify-content: space-between; align-items: center; padding-block: 34px; }
.foot__brand { font-family: var(--font-display); font-weight: 900; letter-spacing: 0.16em; color: var(--gold); }
.foot__links { display: flex; flex-wrap: wrap; gap: 22px; }
.foot__links a { color: var(--muted); font-size: 14.5px; font-weight: 600; }
.foot__links a:hover { color: var(--paper); }
.foot__fine { color: var(--faint); font-size: 13px; padding-bottom: 30px; }

/* ---------- shared section divider glow ---------- */
.rule { height: 1px; background: var(--line-soft); border: 0; margin: 0; }

/* ============================================================
   Press / Media Kit components (additive — reusable across pages)
   ============================================================ */

.btn-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

/* small status tag / placeholder marker */
.tag {
	display: inline-block;
	font-family: var(--font-display);
	font-size: 11px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase;
	padding: 3px 9px; border-radius: 5px; border: 1px solid; vertical-align: middle;
	margin-left: 6px;
}
.tag--ph { color: var(--stamp); border-color: rgba(196, 59, 44, 0.6); background: rgba(196, 59, 44, 0.06); }
.tag--soon { color: var(--muted); border-color: var(--line); }

/* fact sheet — label / value pairs */
.factsheet { display: grid; grid-template-columns: max-content 1fr; gap: 12px 28px; margin: 24px 0 0; }
.factsheet dt {
	font-family: var(--font-display); font-weight: 800; font-size: 12.5px;
	letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); padding-top: 2px;
}
.factsheet dd { margin: 0; color: var(--paper); }
.factsheet a { color: var(--gold); }
.factsheet a:hover { color: var(--gold-bright); }
@media (max-width: 560px) { .factsheet { grid-template-columns: 1fr; gap: 4px 0; } .factsheet dd { margin-bottom: 12px; } }

/* readable prose blocks */
.prose { max-width: 68ch; }
.prose p { margin: 0 0 14px; color: #d8ccb4; }
.prose p:last-child { margin-bottom: 0; }

/* feature bullet list */
.feature-list { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 11px; max-width: 68ch; }
.feature-list li { position: relative; padding-left: 26px; color: #d8ccb4; }
.feature-list li::before { content: "▪"; color: var(--gold); position: absolute; left: 5px; top: -1px; }

/* download cards */
.dl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 820px) { .dl-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .dl-grid { grid-template-columns: 1fr; } }
.dl-card { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--ink-1); display: flex; flex-direction: column; }
.dl-card__thumb { aspect-ratio: 16 / 10; overflow: hidden; background: var(--ink-2); }
.dl-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.dl-card__thumb--empty {
	display: flex; align-items: center; justify-content: center;
	color: var(--faint); font-family: var(--font-display); font-weight: 700;
	font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase;
	background: repeating-linear-gradient(135deg, rgba(199,154,99,0.05) 0 12px, rgba(199,154,99,0.02) 12px 24px), var(--ink-2);
}
.dl-card__body { padding: 18px 18px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.dl-card__t { font-family: var(--font-display); font-weight: 800; font-size: 18px; margin: 0; }
.dl-card__meta { color: var(--muted); font-size: 14px; margin: 0 0 6px; }
.dl-card__btn { margin-top: auto; }

/* disabled control (placeholder, not a real link) */
.is-disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* contact block */
.contact-card { border: 1px solid var(--line); border-radius: 16px; padding: clamp(22px, 4vw, 32px); background: var(--ink-1); }

/* ============================================================
   Steam-prep / brand-guide components (additive — reusable)
   ============================================================ */

/* selectable copy blocks (paste-ready store text) */
.copyblock { border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: 10px; background: var(--ink-1); padding: 18px 20px; margin-top: 16px; }
.copyblock__label { display: flex; justify-content: space-between; gap: 12px; font-family: var(--font-display); font-weight: 800; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.copyblock__label .count { color: var(--faint); }
.copyblock p { margin: 0 0 10px; color: #e4dac6; } .copyblock p:last-child { margin-bottom: 0; }

/* capsule placeholder layouts (aspect ratio set inline per Steam spec) */
.capsule-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; margin-top: 28px; align-items: start; }
.capsule figure { margin: 0; }
.capsule__box {
	width: 100%;
	border: 2px dashed rgba(199, 154, 99, 0.42); border-radius: 8px;
	background: repeating-linear-gradient(135deg, rgba(199,154,99,0.05) 0 12px, rgba(199,154,99,0.02) 12px 24px), var(--ink-2);
	display: flex; align-items: center; justify-content: center;
	color: var(--faint); font-family: var(--font-display); font-weight: 800; font-size: 13px; letter-spacing: 0.05em; text-align: center; padding: 8px;
}
.capsule figcaption { margin-top: 10px; }
.capsule__name { font-weight: 700; color: var(--paper); font-size: 14.5px; }
.capsule__use { color: var(--muted); font-size: 13px; margin-top: 2px; }

/* brand color swatches */
.swatch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)); gap: 14px; margin-top: 24px; }
.swatch { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--ink-1); }
.swatch__chip { height: 74px; border-bottom: 1px solid var(--line-soft); }
.swatch__meta { padding: 10px 12px; }
.swatch__name { font-weight: 700; font-size: 14px; }
.swatch__hex { color: var(--muted); font-size: 12.5px; font-family: ui-monospace, "Cascadia Code", Consolas, monospace; }

/* checklist with status pills */
.checklist { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 10px; }
.checklist li { display: flex; align-items: flex-start; gap: 12px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 10px; background: var(--ink-1); }
.checklist .ck-label { flex: 1; }
.checklist .ck-t { font-weight: 600; }
.checklist .ck-d { color: var(--muted); font-size: 14px; margin-top: 2px; }

/* numbered storyboard (a real ordered sequence) */
.storyboard { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 14px; counter-reset: shot; }
.storyboard li { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start; border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; background: var(--ink-1); }
.storyboard li::before {
	counter-increment: shot; content: counter(shot, decimal-leading-zero);
	font-family: var(--font-display); font-weight: 900; font-size: 17px; color: var(--gold);
	background: rgba(231, 181, 60, 0.08); border: 1px solid rgba(231, 181, 60, 0.3); border-radius: 8px;
	width: 42px; height: 42px; display: flex; align-items: center; justify-content: center;
}
.storyboard .sb-t { font-weight: 700; margin: 0 0 3px; }
.storyboard .sb-d { color: var(--muted); font-size: 14.5px; margin: 0; }

/* type + spacing specimens */
.specimen { border: 1px solid var(--line); border-radius: 12px; padding: 20px 22px; background: var(--ink-1); margin-top: 16px; }
.specimen .sp-role { color: var(--muted); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 6px; }
.spacing-row { display: flex; gap: 12px; align-items: flex-end; margin-top: 18px; flex-wrap: wrap; }
.spacing-row .sp { background: rgba(231, 181, 60, 0.16); border: 1px solid rgba(231, 181, 60, 0.35); border-radius: 4px; }
.spacing-row .sp b { display: block; text-align: center; color: var(--muted); font-size: 11px; font-weight: 600; margin-top: 6px; }

/* ============================================================
   Wiki shell components (additive — reusable)
   ============================================================ */

.wiki-layout { display: grid; grid-template-columns: 264px 1fr; gap: clamp(24px, 4vw, 48px); align-items: start; }
@media (max-width: 860px) { .wiki-layout { grid-template-columns: 1fr; } }

.wiki-side { position: sticky; top: 80px; display: flex; flex-direction: column; gap: 18px; }
@media (max-width: 860px) { .wiki-side { position: static; } }
.wiki-side__brand { font-family: var(--font-display); font-weight: 900; letter-spacing: 0.1em; color: var(--gold); font-size: 18px; }
.wiki-side__brand small { display: block; color: var(--muted); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 700; margin-top: 2px; }

.wiki-search { width: 100%; }
.search-results { margin-top: 10px; display: none; flex-direction: column; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--ink-1); }
.search-results.is-open { display: flex; }
.search-results a { padding: 10px 14px; border-bottom: 1px solid var(--line-soft); color: var(--paper); font-size: 14.5px; }
.search-results a:last-child { border-bottom: 0; }
.search-results a:hover { background: rgba(231, 181, 60, 0.08); }
.search-results a .sr-cat { color: var(--muted); font-size: 12px; display: block; }
.search-results .sr-empty { padding: 12px 14px; color: var(--faint); font-size: 14px; }

.wiki-nav { display: flex; flex-direction: column; gap: 2px; border: 1px solid var(--line); border-radius: 12px; padding: 10px; background: var(--ink-1); }
.wiki-nav__h { font-family: var(--font-display); font-weight: 800; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); padding: 6px 10px 4px; }
.wiki-nav a { padding: 8px 10px; border-radius: 8px; color: #d8ccb4; font-size: 14.5px; }
.wiki-nav a:hover { background: rgba(199, 154, 99, 0.08); color: var(--paper); }
.wiki-nav a.is-active { background: rgba(231, 181, 60, 0.1); color: var(--gold); }

.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; margin-top: 26px; }
.cat-card { border: 1px solid var(--line); border-radius: 14px; padding: 20px; background: var(--ink-1); transition: transform 0.16s ease, border-color 0.16s ease; display: flex; flex-direction: column; gap: 6px; }
.cat-card:hover { transform: translateY(-3px); border-color: rgba(231, 181, 60, 0.4); }
@media (prefers-reduced-motion: reduce) { .cat-card:hover { transform: none; } }
.cat-card__t { font-family: var(--font-display); font-weight: 800; font-size: 18px; margin: 0; }
.cat-card__d { color: var(--muted); font-size: 14px; margin: 0; }

.breadcrumb { color: var(--muted); font-size: 14px; margin-bottom: 14px; }
.breadcrumb a { color: var(--gold); } .breadcrumb a:hover { color: var(--gold-bright); }
.breadcrumb .sep { color: var(--faint); margin: 0 8px; }

.stub-banner { display: flex; gap: 12px; align-items: flex-start; border: 1px solid rgba(231, 181, 60, 0.35); background: rgba(231, 181, 60, 0.06); border-radius: 12px; padding: 14px 16px; margin: 6px 0 24px; }
.stub-banner .sb-ic { font-size: 20px; line-height: 1.2; }
.stub-banner p { margin: 0; color: #e4dac6; font-size: 14.5px; }

.article { max-width: 74ch; }
.article h2 { font-family: var(--font-display); font-weight: 800; font-size: 24px; margin: 30px 0 10px; scroll-margin-top: 80px; }
.article h3 { font-family: var(--font-display); font-weight: 700; font-size: 18px; margin: 22px 0 8px; }
.article p { color: #d8ccb4; margin: 0 0 12px; }

.infobox { float: right; width: 280px; margin: 0 0 20px 24px; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--ink-1); }
@media (max-width: 620px) { .infobox { float: none; width: 100%; margin: 0 0 20px; } }
.infobox__title { font-family: var(--font-display); font-weight: 800; text-align: center; padding: 12px; background: rgba(231, 181, 60, 0.08); border-bottom: 1px solid var(--line); }
.infobox__img { aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; color: var(--faint); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; background: repeating-linear-gradient(135deg, rgba(199,154,99,0.05) 0 12px, rgba(199,154,99,0.02) 12px 24px), var(--ink-2); }
.infobox dl { margin: 0; padding: 6px 14px 14px; display: grid; grid-template-columns: max-content 1fr; gap: 8px 14px; }
.infobox dt { color: var(--muted); font-size: 12.5px; font-weight: 700; letter-spacing: 0.04em; }
.infobox dd { margin: 0; font-size: 14px; }

.toc { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; background: var(--ink-1); margin: 0 0 22px; max-width: 74ch; }
.toc__h { font-family: var(--font-display); font-weight: 800; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.toc ol { margin: 0; padding-left: 20px; color: var(--muted); }
.toc a { color: #d8ccb4; } .toc a:hover { color: var(--gold); }

.cat-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; padding-top: 18px; border-top: 1px solid var(--line-soft); }
.cat-tags .tag { margin-left: 0; }

/* Article data tables. Wrapped so a wide table scrolls inside itself instead of
   forcing the whole page sideways on a phone. */
.tbl-wrap { overflow-x: auto; margin: 0 0 18px; max-width: 74ch; -webkit-overflow-scrolling: touch; }
.tbl { border-collapse: collapse; width: 100%; min-width: 420px; font-size: 14.5px; background: var(--ink-1); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.tbl th, .tbl td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
.tbl thead th { font-family: var(--font-display); font-weight: 800; font-size: 12.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); background: rgba(231, 181, 60, 0.06); border-bottom: 1px solid var(--line); }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover td { background: rgba(231, 181, 60, 0.035); }
.tbl td b { color: var(--paper); }

/* Long reference lists (console commands): dense multi-column, collapses to one
   column on narrow screens. */
.cmd-list { list-style: none; margin: 0 0 20px; padding: 0; columns: 3 190px; column-gap: 22px; max-width: 74ch; }
.cmd-list li { break-inside: avoid; margin: 0 0 5px; font-size: 13.5px; }
.cmd-list code { color: #d8ccb4; background: var(--ink-2); border: 1px solid var(--line-soft); border-radius: 5px; padding: 2px 6px; display: inline-block; }

/* Inline code and code blocks inside articles. */
.article code, .gen-meta code, .infobox code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.92em; color: #e0d3b6; background: var(--ink-2); border: 1px solid var(--line-soft); border-radius: 5px; padding: 1px 5px; }
.codeblock { overflow-x: auto; max-width: 74ch; margin: 0 0 14px; padding: 12px 14px; background: var(--ink-2); border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: 10px; }
.codeblock code { background: none; border: 0; padding: 0; font-size: 13px; line-height: 1.55; white-space: pre; color: #d8ccb4; }

/* Machine-readable provenance footer: what generated the page, when it was
   verified, and what status the repository actually supports. */
.gen-meta { margin-top: 26px; border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: 10px; background: var(--ink-1); padding: 14px 16px; max-width: 74ch; }
.gen-meta dl { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; }
.gen-meta dt { color: var(--muted); font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.gen-meta dd { margin: 0; font-size: 13.5px; color: #d8ccb4; }
@media (max-width: 520px) { .gen-meta dl { grid-template-columns: 1fr; gap: 2px 0; } .gen-meta dd { margin-bottom: 8px; } }
