:root {
  --ink: #202934;
  --muted: #566476;
  --paper: #f6f8f8;
  --surface: #fff;
  --line: #dce3e5;
  --brand: #c6513c;
  --brand-dark: #963823;
  --teal: #1e706c;
  --teal-soft: #e4f1ee;
  --gold: #f3c778;
  --shadow: 0 12px 32px rgba(25, 43, 51, .07);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; line-height: 1.62; }
a { color: var(--brand-dark); text-underline-offset: 3px; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.skip-link { position: fixed; top: -100px; left: 16px; z-index: 50; padding: 8px 14px; background: white; }
.skip-link:focus { top: 8px; }
.container, .nav, .hero-inner, .footer-inner { width: min(1160px, calc(100% - 40px)); margin-inline: auto; }

/* The compact wiki navigation follows AnvilWiki's content-first header pattern. */
.site-header { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); backdrop-filter: blur(12px); }
.nav { min-height: 62px; display: flex; align-items: center; gap: 30px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; white-space: nowrap; font-size: 1.02rem; font-weight: 800; }
.brand-mark { display: grid; place-items: center; width: 29px; height: 29px; color: var(--brand); font-size: 1.65rem; line-height: 1; }
.nav-links { display: flex; align-items: stretch; align-self: stretch; gap: 4px; }
.nav-links a { display: inline-flex; align-items: center; padding: 0 13px; border-bottom: 2px solid transparent; color: var(--muted); text-decoration: none; font-size: .9rem; font-weight: 650; }
.nav-links a:hover, .nav-links a[aria-current="page"] { border-color: var(--brand); color: var(--ink); }
.mobile-nav { display: none; margin-left: auto; position: relative; }
.mobile-nav summary { display: grid; place-items: center; width: 38px; height: 38px; list-style: none; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; font-size: 1.1rem; }
.mobile-nav summary::-webkit-details-marker { display: none; }
.mobile-nav > div { position: absolute; right: 0; top: 46px; width: 190px; padding: 6px; border: 1px solid var(--line); border-radius: 6px; background: white; box-shadow: var(--shadow); }
.mobile-nav a { display: block; padding: 9px 11px; border-radius: 4px; color: var(--ink); text-decoration: none; font-size: .92rem; }
.mobile-nav a:hover { background: var(--teal-soft); }

.hero { position: relative; display: grid; align-items: center; min-height: 425px; overflow: hidden; background: #184e46; color: white; }
.hero-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(13, 42, 39, .96) 0%, rgba(14, 49, 45, .78) 51%, rgba(15, 58, 54, .26) 100%); }
.hero-inner { position: relative; z-index: 1; padding-block: 44px 48px; }
.eyebrow { margin: 0 0 12px; color: var(--brand-dark); font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.hero .eyebrow { color: var(--gold); }
h1 { max-width: 850px; margin: 0; font-size: clamp(2.35rem, 4.1vw, 4.15rem); line-height: 1.08; font-weight: 850; letter-spacing: 0; }
.hero-copy { max-width: 700px; margin: 18px 0 22px; color: #e9f1ee; font-size: 1.02rem; }
.hero-actions, .tool-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.button { min-height: 43px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 9px 17px; border: 1px solid var(--brand-dark); border-radius: 5px; background: var(--brand-dark); color: white; text-decoration: none; font-size: .9rem; font-weight: 750; transition: background .15s, border-color .15s, transform .15s; }
.button:hover { background: #762914; border-color: #762914; transform: translateY(-1px); }
.button.secondary { border-color: rgba(255,255,255,.62); background: rgba(255,255,255,.08); color: white; }
.button.secondary:hover { background: rgba(255,255,255,.17); }
.button.ghost { border-color: var(--line); background: white; color: var(--ink); }
.button.ghost:hover { border-color: var(--teal); background: var(--teal-soft); }
.button.danger { border-color: #e6c6bf; background: white; color: var(--brand-dark); }
.button.danger:hover { background: #fff0ec; }

.quick-nav { border-bottom: 1px solid var(--line); background: white; }
.quick-nav-inner { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.quick-nav a { display: flex; align-items: center; gap: 14px; min-width: 0; padding: 17px 20px; color: var(--ink); text-decoration: none; transition: background .15s; }
.quick-nav a:first-child { padding-left: 0; }
.quick-nav a + a { border-left: 1px solid var(--line); }
.quick-nav a:hover { background: #f5f8f8; }
.quick-icon { flex: 0 0 34px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 5px; background: var(--teal-soft); color: var(--teal); font-size: .7rem; font-weight: 850; }
.quick-nav strong, .quick-nav small { display: block; }
.quick-nav strong { font-size: .9rem; line-height: 1.2; }
.quick-nav small { margin-top: 3px; color: var(--muted); font-size: .76rem; line-height: 1.3; }
.quick-arrow { margin-left: auto; color: var(--brand); font-size: 1.05rem; }

.band { padding: 65px 0; }
.band#planner { padding-top: 52px; scroll-margin-top: 70px; }
.band.white { border-block: 1px solid var(--line); background: white; }
.game-gallery { border-top: 1px solid var(--line); }
.screenshot-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.screenshot-grid figure { min-width: 0; margin: 0; }
.screenshot-grid img { display: block; width: 100%; height: auto; aspect-ratio: 794 / 445; object-fit: cover; border: 1px solid var(--line); border-radius: 5px; }
.screenshot-grid figcaption { margin-top: 9px; color: var(--muted); font-size: .86rem; }
.image-credit { margin: 18px 0 0; color: var(--muted); font-size: .76rem; }
.section-heading { max-width: 780px; margin-bottom: 27px; }
.section-heading h2, .content-page h1 { margin: 0 0 10px; font-size: clamp(1.85rem, 3vw, 2.65rem); line-height: 1.14; font-weight: 820; letter-spacing: 0; }
.section-heading p, .lede { margin: 0; color: var(--muted); font-size: 1.01rem; }
.section-heading .eyebrow { margin-bottom: 9px; color: var(--brand-dark); font-size: .75rem; }

.planner-shell { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(290px, .7fr); gap: 20px; align-items: start; }
.tool-panel, .result-panel { border: 1px solid var(--line); border-radius: 7px; background: white; box-shadow: var(--shadow); }
.tool-panel { padding: 26px; }
.result-panel { position: sticky; top: 82px; min-height: 220px; padding: 24px; border-top: 3px solid var(--teal); }
.tool-step + .tool-step { margin-top: 25px; padding-top: 24px; border-top: 1px solid var(--line); }
.step-label { display: flex; align-items: center; gap: 10px; margin-bottom: 17px; font-weight: 800; }
.step-number { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 5px; background: var(--teal); color: white; font-size: .8rem; }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; }
.field.full { grid-column: 1 / -1; }
label { display: grid; gap: 6px; color: #3c4a58; font-size: .85rem; font-weight: 700; }
input, textarea { width: 100%; padding: 10px 12px; border: 1px solid #cbd5d9; border-radius: 5px; background: white; color: var(--ink); }
input::placeholder, textarea::placeholder { color: #7d8993; opacity: 1; }
textarea { min-height: 88px; resize: vertical; }
input:focus, textarea:focus { border-color: var(--teal); outline: 3px solid rgba(30,112,108,.15); }
.candidate-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.candidate { padding-top: 12px; border-top: 2px solid var(--line); }
.candidate:first-child { border-color: var(--teal); }
.candidate:last-child { border-color: var(--brand); }
.candidate h3 { margin: 0 0 10px; font-size: .97rem; }
.candidate label + label { margin-top: 11px; }
.tool-actions { margin-top: 22px; }
.status { min-height: 24px; margin: 10px 0 0; color: var(--teal); font-size: .84rem; }
.status.error { color: var(--brand-dark); }
.result-empty { margin: 0; color: var(--muted); }
.result-panel h3 { margin: 2px 0 13px; font-size: 1.22rem; }
.result-panel ul { padding-left: 20px; }
.score-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding: 16px 0; border-top: 1px solid var(--line); }
.score-row strong { overflow-wrap: anywhere; }
.score { color: var(--teal); font-size: 1.35rem; font-weight: 850; }
.match-list { margin: 6px 0 0; color: var(--muted); font-size: .86rem; overflow-wrap: anywhere; }
.callout { margin-top: 17px; padding: 13px 16px; border-left: 3px solid var(--brand); background: #fff5f1; color: #623b33; }
.badge { display: inline-block; margin-bottom: 10px; padding: 4px 8px; border-radius: 4px; background: var(--teal-soft); color: #185a57; font-size: .72rem; font-weight: 800; }

.proof-grid, .feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 25px; }
.proof, .feature { padding: 19px 0; border-top: 2px solid var(--line); }
.proof:first-child { border-color: var(--teal); }
.proof:nth-child(2) { border-color: var(--brand); }
.proof:nth-child(3) { border-color: #d59c39; }
.proof strong { display: block; margin-bottom: 6px; font-size: 1.15rem; }
.proof p, .feature p { margin: 0; color: var(--muted); }
.feature h3 { margin: 0 0 8px; font-size: 1.05rem; }
.guide-band { background: #f0f5f4; }
.guide-layout { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(260px, .7fr); gap: 55px; align-items: start; }
.guide-copy { max-width: 760px; }
.guide-copy h3, .limits-copy h3 { margin: 32px 0 9px; font-size: 1.24rem; line-height: 1.35; }
.guide-copy h3:first-child { margin-top: 0; }
.guide-copy p, .guide-aside p, .limits-copy p { color: #435461; }
.guide-aside { position: sticky; top: 88px; padding: 20px 0; border-top: 3px solid var(--brand); border-bottom: 1px solid var(--line); }
.guide-aside h3 { margin: 0 0 10px; font-size: 1.18rem; line-height: 1.35; }
.text-link { display: inline-block; margin-top: 7px; font-weight: 750; }
.limits-copy { max-width: 850px; margin-top: 28px; }

.faq { max-width: 850px; }
.faq details { border-top: 1px solid var(--line); padding: 17px 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 750; }
.faq details p { color: var(--muted); }
.content-page { min-height: calc(100svh - 240px); padding: 65px 0 90px; background: white; }
.content-page > .container > header { max-width: 800px; margin-bottom: 40px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.content-page h1 { color: var(--ink); }
.article-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(240px, .75fr); gap: 60px; }
.article h2 { margin: 35px 0 10px; font-size: 1.5rem; line-height: 1.3; }
.article h2:first-child { margin-top: 0; }
.article p, .article li { color: #435461; }
.source-box { align-self: start; padding: 19px 0; border-top: 3px solid var(--teal); border-bottom: 1px solid var(--line); }
.source-box h2 { margin: 0 0 8px; font-size: .96rem; }
.source-box ul { margin: 0; padding-left: 18px; }
.source-box li + li { margin-top: 8px; }

.site-footer { padding: 31px 0; border-top: 1px solid #22363a; background: #203235; color: #d8e4e2; }
.footer-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 25px; align-items: end; }
.footer-inner p { max-width: 760px; margin: 0; font-size: .84rem; }
.footer-links { display: flex; gap: 18px; }
.footer-links a { color: white; font-size: .85rem; }
.footer-links button { padding: 0; border: 0; background: none; color: white; font-size: .85rem; text-decoration: underline; text-underline-offset: 3px; }
.analytics-consent { position: fixed; right: 20px; bottom: 20px; z-index: 40; display: flex; align-items: center; gap: 24px; width: min(620px, calc(100% - 40px)); padding: 18px 20px; border: 1px solid var(--line); border-radius: 6px; background: white; box-shadow: 0 12px 35px rgba(25,43,51,.2); }
.analytics-consent strong { font-size: .94rem; }
.analytics-consent p { margin: 4px 0 0; color: var(--muted); font-size: .82rem; line-height: 1.45; }
.analytics-consent-actions { flex: 0 0 auto; display: flex; gap: 8px; }
.analytics-consent-actions button { min-height: 38px; padding: 7px 11px; border: 1px solid var(--line); border-radius: 5px; background: white; color: var(--ink); font-size: .82rem; font-weight: 700; }
.analytics-consent-actions button[data-consent="accepted"] { border-color: var(--teal); background: var(--teal); color: white; }

@media (max-width: 820px) {
  .planner-shell, .article-grid, .guide-layout { grid-template-columns: 1fr; }
  .result-panel, .guide-aside { position: static; }
  .proof-grid, .feature-grid, .screenshot-grid { gap: 15px; }
  .article-grid { gap: 30px; }
}
@media (max-width: 650px) {
  .container, .nav, .hero-inner, .footer-inner { width: min(100% - 32px, 1160px); }
  .nav-links { display: none; }
  .mobile-nav { display: block; }
  .hero { min-height: 390px; }
  .hero::after { background: rgba(13,42,39,.78); }
  .hero-inner { padding-block: 35px; }
  .hero-copy { font-size: .94rem; }
  .quick-nav-inner { grid-template-columns: 1fr; }
  .quick-nav a, .quick-nav a:first-child { padding: 10px 4px; }
  .quick-nav a + a { border-left: 0; border-top: 1px solid var(--line); }
  .quick-icon { width: 29px; height: 29px; flex-basis: 29px; }
  .quick-nav small { display: none; }
  .band { padding: 48px 0; }
  .band#planner { padding-top: 43px; }
  .tool-panel, .result-panel { padding: 18px; }
  .fields, .candidate-grid, .proof-grid, .feature-grid, .screenshot-grid { grid-template-columns: 1fr; }
  .field.full { grid-column: auto; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-links { flex-wrap: wrap; }
  .analytics-consent { right: 16px; bottom: 16px; width: calc(100% - 32px); flex-direction: column; align-items: stretch; gap: 12px; }
  .analytics-consent-actions { justify-content: flex-end; }
}
@media (max-width: 390px) {
  .hero { min-height: 420px; }
  .hero-actions .button { width: 100%; }
  .tool-actions .button { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .button { transition: none; } }
@media print {
  .site-header, .hero, .quick-nav, .tool-actions, .site-footer, .proof-grid, .faq, .analytics-consent { display: none !important; }
  .band { padding: 0; }
  .planner-shell { display: block; }
  .tool-panel { display: none; }
  .result-panel { border: 0; box-shadow: none; }
}
