@font-face {
  font-family: Cinzel;
  src: url('/media/Cinzel.ttf') format('truetype');
  font-weight: 400 900;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --background: #0b1113;
  --surface: #11191b;
  --border: #343735;
  --text: #ede6d8;
  --muted: #bac0ba;
  --gold: #d8b77c;
  --serif: Cinzel, Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 16px/1.55 system-ui, sans-serif;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: .24em; }
a:hover { color: var(--gold); }
:focus-visible { outline: 2px solid #f9d696; outline-offset: 4px; }
button, input { font: inherit; }
h1, h2, h3, p, figure { margin: 0; }
h1, h2 { font-family: var(--serif); font-weight: 600; line-height: 1.05; }
h2 { font-size: clamp(2.1rem, 4vw, 3.35rem); letter-spacing: -.025em; }
.wrap { width: min(1160px, calc(100% - clamp(2rem, 9vw, 8rem))); margin-inline: auto; }
.eyebrow {
  margin-bottom: .78rem;
  color: var(--gold);
  font-size: .74rem;
  font-weight: 680;
  letter-spacing: .135em;
  text-transform: uppercase;
}
.screen-reader {
  position: absolute; width: 1px; height: 1px; padding: 0;
  margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.skip-link {
  position: fixed; z-index: 4; top: .65rem; left: .65rem;
  padding: .6rem 1rem; background: var(--surface); transform: translateY(-160%);
}
.skip-link:focus { transform: none; }

.site-header { position: relative; z-index: 2; border-bottom: 1px solid var(--border); background: #0b1113; }
.navigation, .footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.navigation { min-height: 72px; }
.brand { color: var(--text); font-family: var(--serif); font-weight: 720; letter-spacing: .045em; text-decoration: none; }
.navigation .brand { display: inline-flex; align-items: center; gap: .55rem; line-height: 1.15; }
.navigation .brand img { flex: none; }
.navigation .brand small { display: block; margin-top: .2rem; color: var(--gold); font-size: .66rem; letter-spacing: .14em; }
.nav-links { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(.8rem, 2.8vw, 2.25rem); }
.nav-links a { font-size: .9rem; color: var(--muted); text-decoration: none; }
.nav-links a:hover, .nav-links a[aria-current] { color: var(--gold); }
.nav-links .nav-download { color: var(--gold); }

.hero { position: relative; isolation: isolate; overflow: hidden; border-bottom: 1px solid var(--border); }
.hero-art { position: absolute; inset: 0; z-index: -1; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 61% 48%; }
.hero-art::after {
  position: absolute; inset: 0; content: '';
  background: linear-gradient(90deg, #0b1113 0%, #0b1113e8 24%, #0b11138f 48%, transparent 74%),
              linear-gradient(0deg, #0b1113 0%, transparent 46%);
}
.hero-content { padding-block: clamp(4.75rem, 10vw, 8.3rem) clamp(3.6rem, 8vw, 6.2rem); }
.hero h1 { font-size: clamp(4.15rem, 10.6vw, 9rem); letter-spacing: -.056em; line-height: .87; }
.hero-copy { max-width: 34ch; margin-top: 1.62rem; color: var(--muted); font-size: clamp(1rem, 2vw, 1.2rem); }
.actions, .download-actions { display: flex; align-items: flex-start; flex-wrap: wrap; gap: .65rem; }
.actions { margin-top: 1.65rem; }
.button {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 2.75rem; padding: .66rem .92rem;
  border: 1px solid var(--border); border-radius: 3px;
  font-size: .87rem; font-weight: 700; text-decoration: none;
  cursor: pointer;
}
.button.primary { background: #d9bb88; color: #17130e; border-color: #d9bb88; }
.button.primary:hover { background: #edd1a1; color: #17130e; }
.button.quiet { background: #101617e8; color: var(--text); }
.button.quiet:hover { border-color: var(--gold); color: var(--gold); }
.button span { font-size: 1.04rem; line-height: 1; }
.invite {
  max-width: 33rem; margin-top: 1.4rem; padding: .9rem 1.05rem;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: .45rem .8rem;
  border: 1px solid #6f5b3a; border-left: 3px solid var(--gold); background: #111b1bed;
}
.invite label { display: block; color: var(--gold); font-size: .85rem; font-weight: 650; }
.invite input { width: 100%; color: var(--text); background: transparent; border: 0; padding: .2rem 0; font: 700 1.24rem/1.5 ui-monospace, monospace; }
.invite p { grid-column: 1 / -1; font-size: .88rem; color: var(--muted); }
.hero noscript p { margin-top: 1rem; color: var(--muted); }

.section { padding-block: clamp(2.8rem, 6vw, 5rem); }
.section + .section { border-top: 1px solid var(--border); }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.7rem; }
.build { padding: .36rem .68rem; border: 1px solid var(--border); font: .78rem/1.5 ui-monospace, monospace; color: var(--muted); white-space: nowrap; }
.download-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: .85rem; }
.download-card { padding: clamp(1.08rem, 2.35vw, 1.65rem); border: 1px solid var(--border); background: var(--surface); }
.download-card h3 { margin-bottom: .92rem; font: 630 1.73rem/1.12 var(--serif); }
.download-card .eyebrow { margin-bottom: .47rem; letter-spacing: .1em; }
.archive-note { margin-top: .85rem; min-height: 3.3em; color: var(--muted); font-size: .87rem; }
.download-card details { margin-top: .85rem; color: var(--muted); font-size: .8rem; }
.download-card summary { min-height: 1.65rem; cursor: pointer; }
.download-card code { display: block; margin-top: .3rem; overflow-wrap: anywhere; color: var(--text); }
.unavailable { padding: 1rem 1.2rem; border: 1px solid var(--border); background: var(--surface); color: var(--muted); }

.guide, .gameplay { display: grid; grid-template-columns: .8fr 1.3fr; gap: clamp(1.25rem, 6vw, 5rem); }
.guide h2 + p, .gameplay h2 + p { max-width: 37ch; margin-top: 1rem; color: var(--muted); }
.guide ol { margin: 0; padding-left: 1.5rem; }
.guide li { padding: .6rem 0 .75rem .45rem; }
.guide li + li { border-top: 1px solid var(--border); }
.guide li::marker { color: var(--gold); font-family: var(--serif); }
.guide li h3, .change-list h3 { font-size: 1.02rem; font-weight: 720; }
.guide li p, .change-list p { margin-top: .25rem; color: var(--muted); font-size: .94rem; }
.gameplay { align-items: center; }
.gameplay figure { border: 1px solid var(--border); background: #000; }
.gameplay video { width: 100%; aspect-ratio: 16 / 9; }

.change-page { max-width: 52rem; min-height: 58vh; padding-block: clamp(2.7rem, 8vw, 5.75rem); }
.change-page h1 { font-size: clamp(2.9rem, 8vw, 5.7rem); }
.release-notes { margin-block: 1.8rem; border: 1px solid var(--border); background: var(--surface); padding: clamp(1.2rem, 4.5vw, 2.45rem); }
.release-notes > p:last-child { margin-top: 1rem; color: var(--muted); }
.history-help { color: var(--muted); margin-top: .6rem; }
.release-notes[id] { scroll-margin-top: 1rem; }
.change-list { padding-left: 1.25rem; margin: 1.1rem 0 0; }
.change-list li { padding: .72rem 0 .8rem .3rem; }
.change-list li + li { border-top: 1px solid var(--border); }
.change-list li::marker { color: var(--gold); }
.site-footer { border-top: 1px solid var(--border); }
.footer-inner { min-height: 82px; flex-wrap: wrap; padding-block: 1rem; color: var(--muted); font-size: .88rem; }

@media (max-width: 670px) {
  .navigation { gap: .5rem; min-height: 0; flex-wrap: wrap; padding-block: .85rem; }
  .nav-links { width: 100%; }
  .hero-content { padding-top: 7.5rem; }
  .hero-art img { object-position: 65% top; }
  .hero-art::after {
    background: linear-gradient(90deg, #0b1113bd, #0b111317 85%),
                linear-gradient(0deg, #0b1113 11%, #0b1113b3 48%, transparent 84%);
  }
  .guide, .gameplay { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 360px) {
  .section-heading { align-items: flex-start; flex-direction: column; }
  .invite { grid-template-columns: 1fr; }
  .invite button { justify-self: start; }
}
