@font-face {
  font-family: "Pixelify Sans";
  src: url("/fonts/pixelify-sans/files/pixelify-sans-latin-400-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Pixelify Sans";
  src: url("/fonts/pixelify-sans/files/pixelify-sans-latin-600-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: "Pixelify Sans";
  src: url("/fonts/pixelify-sans/files/pixelify-sans-latin-700-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "Cinzel";
  src: url("/fonts/cinzel/files/cinzel-latin-600-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter/files/inter-latin-400-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter/files/inter-latin-600-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --ink: #17120e;
  --ink-soft: #211913;
  --surface: #302319;
  --surface-raised: #453220;
  --line: #8a653f;
  --line-soft: #5b3c2a;
  --text: #fff0c7;
  --muted: #d2bc91;
  --gold: #e2a93f;
  --gold-bright: #ffd884;
  --moss: #58735e;
  --teal: #5a9690;
  --crimson: #a94f48;
  --good: #74b985;
  --warn: #e4a45e;
  --paper: #fff0c7;
  --paper-soft: #f4d997;
  --paper-ink: #261c16;
  --paper-muted: #6c5741;
  --wood: #6a4228;
  --wood-dark: #2d1e19;
  --font-micro: .875rem;
  --font-compact: 1rem;
  --font-body: 1.125rem;
  --font-emphasis: 1.25rem;
  --header-height: 72px;
  --page-width: 1180px;
  font-family: "Pixelify Sans", system-ui, sans-serif;
  letter-spacing: 0;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--ink); }
body { margin: 0; min-width: 320px; background: var(--ink); color: var(--text); font-size: var(--font-body); line-height: 1.6; letter-spacing: 0; }
body, button, input, select, textarea { font: inherit; letter-spacing: 0; }
img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { font-family: "Pixelify Sans", system-ui, sans-serif; font-weight: 700; line-height: 1.08; letter-spacing: 0; }
h1 { font-size: 4.025rem; }
h2 { font-size: 2.475rem; }
h3 { font-size: 1.225rem; }
p { color: var(--muted); }
:focus-visible { outline: 3px solid var(--gold-bright); outline-offset: 3px; }
[hidden] { display: none !important; }

.page-width { width: min(calc(100% - 48px), var(--page-width)); margin-inline: auto; }
.page-width.narrow { max-width: 860px; }
.eyebrow { margin-bottom: 10px; color: var(--gold-bright); font-size: .885rem; font-weight: 600; text-transform: uppercase; }
.meta-line { color: #b3bdb6; font-size: .925rem; }
.online-text { color: var(--good) !important; }

.site-header {
  position: fixed;
  z-index: 50;
  inset: 0 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  min-height: var(--header-height);
  padding: 0 28px;
  border-bottom: 3px solid var(--wood-dark);
  background: linear-gradient(180deg, rgba(255,240,199,.98), rgba(232,186,98,.97));
  box-shadow: 0 5px 0 rgba(40,29,22,.25);
}

.site-header.is-scrolled { background: linear-gradient(180deg, #fff0c7, #e8ba62); }
.brand { display: inline-flex; align-items: center; gap: 10px; min-width: 170px; color: var(--wood-dark); font-family: "Pixelify Sans", system-ui, sans-serif; font-weight: 700; text-shadow: 1px 1px 0 var(--gold-bright); }
.brand img { width: 32px; height: 32px; }
.site-nav { display: flex; justify-content: center; align-items: center; gap: 28px; }
.site-nav a, .nav-actions > a:not(.button) { color: var(--paper-ink); font-size: 1.075rem; font-weight: 600; }
.site-nav a:hover, .site-nav a[aria-current="page"], .nav-actions > a:not(.button):hover { color: var(--grass-deep, #244b2b); }
.nav-actions { display: flex; justify-content: flex-end; align-items: center; gap: 13px; min-width: 250px; }
.nav-command { display: inline-flex; align-items: center; gap: 7px; }
.nav-command img { width: 17px; height: 17px; filter: invert(87%) sepia(33%) saturate(825%); }
.site-header .nav-command img, .site-header .icon-button img { filter: sepia(70%) saturate(650%) brightness(45%); }
.world-indicator { display: inline-flex; align-items: center; gap: 6px; min-width: 46px; color: var(--paper-muted); font-size: .925rem; font-variant-numeric: tabular-nums; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #707a74; box-shadow: 0 0 0 3px rgba(112,122,116,.15); }
.status-dot.is-online { background: var(--good); box-shadow: 0 0 0 3px rgba(116,185,133,.16); }
.nav-toggle { display: none !important; }
.mobile-only { display: none; }

.button, .icon-button, .segmented-control a {
  border-radius: 2px;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease;
}
.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 10px 18px;
  border: 3px solid var(--wood-dark);
  font-weight: 700;
  box-shadow: 0 5px 0 rgba(45,30,25,.34);
  cursor: pointer;
}
.button img { width: 18px; height: 18px; }
.button:hover:not(:disabled) { transform: translateY(-1px); }
.button.primary { background: linear-gradient(180deg, #ffdd79, var(--gold)); color: var(--paper-ink); }
.button.primary:hover { background: linear-gradient(180deg, #ffe79a, #edb84d); }
.button.accent { background: linear-gradient(180deg, #79a64a, #3f7133); color: #fff8cf; border-color: var(--wood-dark); }
.button.accent:hover { background: linear-gradient(180deg, #8bb75a, #4b8140); }
.button.secondary { background: linear-gradient(180deg, #fff8db, var(--paper-soft)); border-color: var(--wood-dark); color: var(--paper-ink); }
.button.secondary:hover { background: #fff8db; }
.button.ghost { background: rgba(255,240,199,.14); border-color: rgba(255,240,199,.72); color: var(--paper); }
.button.ghost:hover { background: rgba(255,240,199,.25); border-color: var(--paper); }
.button.compact { min-height: 40px; padding: 7px 13px; font-size: .965rem; }
.button.full { width: 100%; }
.button:disabled { cursor: not-allowed; opacity: .45; }
.icon-button {
  display: inline-grid;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  place-items: center;
  padding: 0;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
}
.icon-button:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.14); }
.icon-button img { width: 19px; height: 19px; filter: invert(92%); }
.text-link { display: inline-flex; align-items: center; gap: 8px; color: var(--gold-bright); font-weight: 600; }
.text-link img { width: 18px; height: 18px; filter: invert(84%) sepia(70%) saturate(500%); }

.home-hero {
  position: relative;
  display: flex;
  min-height: min(84vh, 820px);
  align-items: flex-end;
  overflow: hidden;
  padding: calc(var(--header-height) + 70px) 7vw 80px;
  isolation: isolate;
}
.home-hero-image { position: absolute; z-index: -3; inset: -7% 0; width: 100%; height: 114%; object-fit: cover; object-position: center; transform: translate3d(0, var(--hero-parallax-y, 0px), 0) scale(1.04); will-change: transform; }
.home-hero-shade { position: absolute; z-index: -2; inset: 0; background: linear-gradient(90deg, rgba(28,18,11,.72) 0%, rgba(28,18,11,.48) 36%, rgba(28,18,11,.13) 68%, transparent 86%); }
.home-hero::after { content: ""; position: absolute; z-index: -1; inset: auto 0 0; height: 48%; background: linear-gradient(0deg, rgba(18,12,8,.76), transparent); }
.home-hero-content { width: min(720px, 100%); }
.home-hero h1 { margin-bottom: 14px; color: var(--paper); font-size: 5.125rem; text-shadow: 3px 3px 0 rgba(45,30,25,.7); }
.home-hero-content > p:not(.eyebrow) { max-width: 650px; margin-bottom: 28px; color: #fff8db; font-size: 1.245rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 11px; }
.hero-scroll { position: absolute; right: 32px; bottom: 26px; display: grid; width: 42px; height: 42px; place-items: center; border: 1px solid rgba(255,255,255,.35); border-radius: 50%; }
.hero-scroll img { width: 20px; filter: invert(100%); }

.world-section { position: relative; min-height: 760px; height: 82vh; max-height: 940px; display: flex; align-items: center; overflow: hidden; isolation: isolate; border-top: 3px solid rgba(45,30,25,.78); }
.world-media { position: absolute; z-index: -3; inset: -14% 0; transform: translate3d(0, var(--parallax-y, 0px), 0) scale(1.04); will-change: transform; }
.world-poster, .world-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.world-video { opacity: 0; transition: opacity .9s ease; }
.world-media.is-playing .world-video { opacity: 1; }
.world-shade { position: absolute; z-index: -2; inset: 0; background: linear-gradient(180deg, rgba(20,13,8,.34), rgba(20,13,8,.08) 24%, rgba(20,13,8,.12) 72%, rgba(20,13,8,.58)); }
.world-section::after { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg, rgba(31,20,12,.86) 0%, rgba(31,20,12,.68) 28%, rgba(31,20,12,.34) 49%, rgba(31,20,12,.08) 68%, transparent 80%); }
.world-section.align-right::after { background: linear-gradient(270deg, rgba(31,20,12,.86) 0%, rgba(31,20,12,.68) 28%, rgba(31,20,12,.34) 49%, rgba(31,20,12,.08) 68%, transparent 80%); }
.world-content { opacity: 1; transform: translateY(0); }
.world-motion-ready .world-content > * { opacity: 0; transform: translateX(-48px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.world-motion-ready .world-section.align-right .world-content > * { transform: translateX(48px); }
.world-motion-ready .world-content.wide > :last-child { transform: translateX(48px); }
.world-motion-ready .world-section.is-visible .world-content > * { opacity: 1; transform: translateX(0); }
.world-motion-ready .world-section.is-visible .world-content > :nth-child(2) { transition-delay: .08s; }
.world-motion-ready .world-section.is-visible .world-content > :nth-child(3) { transition-delay: .16s; }
.world-motion-ready .world-section.is-visible .world-content > :nth-child(4) { transition-delay: .24s; }
.world-content > * { max-width: 590px; }
.world-content:not(.wide, .centered) { border-left: 3px solid rgba(255,216,132,.62); padding-left: 28px; }
.align-right .world-content { display: flex; flex-direction: column; align-items: flex-end; border-right: 3px solid rgba(255,216,132,.62); border-left: 0; padding-right: 28px; padding-left: 0; text-align: right; }
.world-content.wide { display: grid; grid-template-columns: minmax(0, 1fr) minmax(340px, 520px); align-items: end; gap: 72px; }
.world-content.wide > * { max-width: none; }
.world-content.wide .world-copy { border-left: 3px solid rgba(255,216,132,.62); padding-left: 28px; }
.world-content.centered { display: flex; flex-direction: column; align-items: center; text-align: center; }
.world-content h2 { margin-bottom: 18px; color: var(--paper); font-size: 3.125rem; text-shadow: 3px 3px 0 rgba(45,30,25,.82); }
.world-content p:not(.eyebrow) { color: #fff4d0; font-size: 1.145rem; text-shadow: 2px 2px 0 rgba(45,30,25,.65); }
.final-world .welcome-title { margin-bottom: 10px; font-size: 3.625rem; }
.final-world .world-memory { margin: 0 0 16px; color: var(--gold-bright); font-size: 1.65rem; font-weight: 600; text-transform: uppercase; }
.leader-preview { margin: 0; padding: 0; list-style: none; border-top: 1px solid rgba(255,255,255,.28); }
.leader-preview li { display: flex; min-height: 52px; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid rgba(255,255,255,.2); }
.leader-preview b { display: inline-block; width: 30px; color: var(--gold-bright); }
.leader-preview strong { font-variant-numeric: tabular-nums; }
.final-world { min-height: 700px; }
.final-world::after { inset: 0; background: linear-gradient(90deg, rgba(31,20,12,.58), rgba(31,20,12,.24) 38%, rgba(31,20,12,.24) 62%, rgba(31,20,12,.58)); }

.masthead { position: relative; min-height: 330px; display: flex; align-items: flex-end; overflow: hidden; margin-top: var(--header-height); padding: 70px 0 46px; isolation: isolate; }
.masthead-image { position: absolute; z-index: -3; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 44%; }
.masthead-poster { z-index: -5; }
.masthead-video { z-index: -4; opacity: 0; transition: opacity .9s ease; will-change: opacity; }
.masthead-video.is-active { opacity: 1; }
.masthead-shade { position: absolute; z-index: -2; inset: 0; background: rgba(25,16,10,.32); }
.masthead::after { content: ""; position: absolute; z-index: -1; inset: 28% 0 0; background: linear-gradient(0deg, rgba(31,20,12,.82), transparent); }
.masthead h1 { margin-bottom: 8px; font-size: 3.525rem; }
.masthead-content > p:last-child { max-width: 680px; margin-bottom: 0; color: #e2e5e1; }
.page-standard { display: flex; min-height: 100vh; min-height: 100dvh; flex-direction: column; }
.page-standard > .masthead-page { flex: 1 0 auto; }
.masthead-page { display: flex; flex-direction: column; }
.masthead-page > .masthead { flex: 1 0 330px; }
.masthead-page > .page-band, .masthead-page > .account-band, .masthead-page > .article-shell { flex: 0 0 auto; }
.page-band, .account-band { padding: 72px 0 96px; background: linear-gradient(180deg, var(--paper-soft), #e8c579); color: var(--paper-ink); }
.account-band { background: linear-gradient(180deg, #f8e2a8, var(--paper-soft)); }
.page-band p, .account-band p, .article-shell p { color: var(--paper-muted); }
.page-band .text-link, .account-band .text-link, .article-shell .text-link { color: #315d35; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 40px; margin-bottom: 34px; border-bottom: 1px solid var(--line); padding-bottom: 20px; }
.section-heading h2 { margin-bottom: 0; }
.section-heading > p { max-width: 480px; margin-bottom: 0; }

.download-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.download-card { display: grid; grid-template-rows: auto 1fr auto; min-height: 340px; gap: 22px; padding: 28px; border: 3px solid var(--line); border-radius: 2px; background: var(--paper); color: var(--paper-ink); box-shadow: 7px 7px 0 rgba(45,30,25,.2); }
.download-card:hover:not(.is-unavailable) { border-color: var(--wood-dark); }
.download-card.is-current-platform:not(.is-unavailable) { border-color: var(--gold); }
.download-icon { width: 44px; height: 44px; filter: invert(80%) sepia(46%) saturate(600%); }
.download-card h3 { margin-bottom: 8px; font-size: 1.525rem; }
.download-card p { min-height: 52px; color: var(--paper-muted); }
.download-card.is-unavailable { background: #dfc787; }

.update-list { border-top: 1px solid var(--line); }
.update-card { display: grid; grid-template-columns: 130px minmax(0, 1fr) 42px; gap: 24px; align-items: start; padding: 30px 0; border-bottom: 1px solid var(--line); }
.update-card h2 { margin-bottom: 9px; font-size: 1.675rem; }
.update-card h2 a:hover { color: #315d35; }
.update-card p { margin-bottom: 8px; }
.update-date { color: #315d35; font-size: .905rem; text-transform: uppercase; }
.article-shell { width: min(calc(100% - 48px), 920px); margin: 48px auto 80px; padding: 46px; border: 3px solid var(--line); background: var(--paper); color: var(--paper-ink); box-shadow: 8px 8px 0 rgba(45,30,25,.22); }
.article-meta { display: flex; gap: 20px; margin-bottom: 36px; padding-bottom: 18px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .965rem; }
.prose { color: var(--paper-ink); font-size: 1.145rem; }
.prose h2, .prose h3, .prose h4 { margin-top: 2.2em; color: var(--paper-ink); }
.prose h2 { font-size: 2.025rem; }
.prose h3 { font-size: 1.525rem; }
.prose a { color: #315d35; text-decoration: underline; }
.prose pre { overflow-x: auto; padding: 18px; border: 3px solid var(--line); border-radius: 2px; background: #fff8db; }
.prose code { color: #583921; }
.prose blockquote { margin-left: 0; padding-left: 20px; border-left: 3px solid var(--gold); color: var(--muted); }
.article-shell > .text-link { margin-top: 48px; }

.leader-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 28px; margin-bottom: 24px; }
.segmented-control { display: inline-flex; padding: 3px; border: 3px solid var(--line); border-radius: 2px; background: var(--paper); }
.segmented-control a { min-width: 130px; padding: 8px 14px; text-align: center; color: var(--paper-muted); }
.segmented-control a.is-active { background: var(--paper-soft); color: #315d35; }
.table-wrap { overflow-x: auto; border: 3px solid var(--line); border-radius: 2px; background: var(--paper); color: var(--paper-ink); box-shadow: 6px 6px 0 rgba(45,30,25,.18); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 18px; border-bottom: 1px solid var(--line-soft); text-align: left; }
thead th { background: var(--paper-soft); color: var(--paper-muted); font-size: .865rem; text-transform: uppercase; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
.leader-table th:last-child, .leader-table td:last-child { text-align: right; }
.leader-table tbody th { font-family: "Pixelify Sans", system-ui, sans-serif; }
.rank-mark { display: inline-grid; width: 34px; height: 34px; place-items: center; border: 1px solid var(--line); border-radius: 50%; color: #315d35; font-size: .925rem; }
.empty-cell { padding: 42px; text-align: center !important; color: var(--paper-muted); }
.pagination { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 28px; color: var(--paper-muted); }

.account-grid { display: grid; grid-template-columns: minmax(280px, .8fr) minmax(420px, 1.4fr); gap: 24px; }
.info-panel { padding: 26px; border: 3px solid var(--line); border-radius: 2px; background: var(--paper); color: var(--paper-ink); box-shadow: 7px 7px 0 rgba(45,30,25,.2); }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.panel-heading h2, .panel-heading h3 { margin-bottom: 0; font-size: 1.525rem; }
.panel-heading > img, .panel-icon { width: 30px; height: 30px; filter: invert(80%) sepia(46%) saturate(600%); }
.detail-list { margin: 0; }
.detail-list > div { display: flex; justify-content: space-between; gap: 20px; padding: 13px 0; border-bottom: 1px solid var(--line-soft); }
.detail-list > div:last-child { border-bottom: 0; }
.detail-list dt { color: var(--paper-muted); }
.detail-list dd { margin: 0; text-align: right; }
.account-security-action { margin-top: 22px; }
.status-label { display: inline-flex; padding: 4px 9px; border-radius: 4px; background: #2d3430; font-size: .885rem; }
.status-label.good { color: var(--good); }
.status-label.warn { color: var(--warn); }
.character-vitals { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-bottom: 20px; background: var(--line); border: 1px solid var(--line); }
.character-vitals > div { min-width: 0; padding: 15px; background: #fff8db; }
.character-vitals span, .skill-grid span { display: block; color: var(--paper-muted); font-size: .845rem; text-transform: capitalize; }
.character-vitals strong { display: block; overflow: hidden; margin-top: 5px; text-overflow: ellipsis; white-space: nowrap; }
.skill-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 22px; }
.skill-grid > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border: 2px solid var(--line-soft); border-radius: 2px; background: #fff8db; }

.rules-list > section { display: grid; grid-template-columns: 70px 1fr; gap: 24px; padding: 28px 0; border-bottom: 1px solid var(--line); }
.rules-list > section > span { color: var(--gold); font-family: "Cinzel", serif; font-size: 1.375rem; }
.rules-list h2 { margin-bottom: 8px; font-size: 1.575rem; }
.rules-list p { margin-bottom: 0; }

.auth-shell { position: relative; min-height: 100dvh; display: grid; place-items: center; overflow: hidden; padding: calc(var(--header-height) + 36px) 20px 36px; isolation: isolate; }
.auth-backdrop { position: absolute; z-index: -3; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.auth-shade { position: absolute; z-index: -2; inset: 0; background: rgba(7,10,8,.69); }
.auth-panel { width: min(100%, 450px); padding: 34px; border: 3px solid var(--line); border-radius: 2px; background: rgba(255,240,199,.96); color: var(--paper-ink); box-shadow: 8px 8px 0 rgba(45,30,25,.36); }
.auth-panel h1 { margin-bottom: 24px; font-size: 2.425rem; }
.auth-panel p { color: var(--paper-muted); }
.auth-panel.compact-panel { text-align: center; }
.auth-panel.compact-panel .panel-icon { margin: 0 auto 18px; width: 42px; height: 42px; }
label { display: grid; gap: 7px; margin-bottom: 15px; color: inherit; font-size: .965rem; }
input, select, textarea { width: 100%; border: 3px solid var(--line); border-radius: 2px; background: #fff9dc; color: var(--paper-ink); }
input, select { min-height: 43px; padding: 8px 11px; }
textarea { resize: vertical; padding: 10px 11px; }
input:focus, select:focus, textarea:focus { border-color: var(--gold); outline: 0; box-shadow: 0 0 0 2px rgba(212,173,85,.18); }
.form-message { min-height: 24px; margin-bottom: 12px; color: var(--warn); font-size: .945rem; }
.form-message.is-success { color: var(--good); }
.auth-intro { margin: -12px 0 22px; }
.auth-help { margin: 14px 0 0; text-align: right; font-size: .925rem; }
.auth-help a { color: #315d35; }
.auth-switch { margin: 20px 0 0; text-align: center; font-size: .985rem; }
.auth-switch a { color: #315d35; }
.registration-pending { text-align: center; }
.registration-pending .panel-icon { width: 42px; height: 42px; margin: 0 auto 18px; }
.registration-pending h2 { margin: 0 0 12px; font-size: 1.775rem; }
.registration-pending .form-message { min-height: 0; margin: 0 0 10px; }
.registration-email { overflow-wrap: anywhere; font-weight: 700; }
.registration-pending form { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.reset-state { min-height: 0; margin-bottom: 18px; }
.reset-state + form { margin-bottom: 18px; text-align: left; }

.empty-state { padding: 70px 24px; text-align: center; }
.empty-state img { width: 38px; height: 38px; margin: 0 auto 16px; filter: invert(80%) sepia(46%) saturate(600%); }
.empty-state.compact { padding: 30px 10px; }

.page-play { overflow: hidden; }
.game-shell { position: relative; width: 100%; height: calc(100dvh - var(--header-height)); margin-top: var(--header-height); overflow: hidden; background: #050706; }
.game-frame { width: 100%; height: 100%; border: 0; background: #050706; }
.game-loading { position: absolute; z-index: 2; inset: 0; display: grid; place-content: center; justify-items: center; gap: 14px; background: #080b09; }
.game-loading.is-hidden { opacity: 0; visibility: hidden; transition: opacity .35s ease, visibility .35s ease; }
.loading-ring { width: 38px; height: 38px; border: 3px solid #39423d; border-top-color: var(--gold); border-radius: 50%; animation: spin .85s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.bug-toggle { position: absolute; z-index: 3; right: 18px; bottom: 18px; background: rgba(20,25,22,.9); border-color: var(--line); }
.bug-panel { position: absolute; z-index: 5; right: 18px; bottom: 68px; width: min(420px, calc(100% - 36px)); max-height: calc(100% - 90px); overflow-y: auto; padding: 22px; border: 1px solid var(--line); border-radius: 7px; background: #151a18; box-shadow: 0 18px 60px rgba(0,0,0,.55); }

.error-page { position: relative; min-height: 100dvh; display: grid; place-items: center; padding: calc(var(--header-height) + 40px) 20px 40px; overflow: hidden; isolation: isolate; text-align: center; }
.error-page > img { position: absolute; z-index: -3; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.error-shade { position: absolute; z-index: -2; inset: 0; background: rgba(5,8,6,.74); }
.error-page section { max-width: 650px; }
.error-code { margin-bottom: 6px; color: var(--gold-bright); font-family: "Pixelify Sans", system-ui, sans-serif; font-size: 1.525rem; }
.error-page h1 { margin-bottom: 12px; }

.site-footer { display: flex; align-items: center; justify-content: space-between; gap: 28px; min-height: 160px; padding: 36px max(24px, calc((100vw - var(--page-width)) / 2)); border-top: 3px solid var(--wood-dark); background: linear-gradient(180deg, var(--paper), var(--paper-soft)); color: var(--paper-muted); font-size: .925rem; }
.site-footer > div { display: grid; gap: 3px; }
.footer-brand { color: var(--paper-ink); font-family: "Pixelify Sans", system-ui, sans-serif; font-size: 1.125rem; font-weight: 700; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 20px; }
.site-footer a:hover { color: #315d35; }
.footer-icon-link { display: inline-flex; align-items: center; gap: 6px; }
.footer-icon-link img { width: 16px; height: 16px; filter: sepia(70%) saturate(650%) brightness(45%); }

@media (max-width: 1080px) {
  .site-header { grid-template-columns: 1fr auto auto; padding: 0 18px; }
  .nav-toggle { display: inline-grid !important; grid-column: 2; }
  .site-nav { position: absolute; top: var(--header-height); right: 0; left: 0; display: none; align-items: stretch; padding: 15px 20px 20px; border-bottom: 3px solid var(--wood-dark); background: var(--paper); }
  .site-nav.is-open { display: grid; }
  .site-nav .mobile-only { display: block; }
  .site-nav a { padding: 9px 4px; }
  .nav-actions { grid-column: 3; min-width: 0; }
  .nav-actions > a:not(.icon-button, .button, .nav-command), .world-indicator { display: none; }
  .nav-actions .button { display: none; }
  .world-content.wide { grid-template-columns: 1fr; align-items: start; gap: 34px; }
  .leader-preview { max-width: 580px; }
  .download-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .download-card:last-child { grid-column: 1 / -1; }
  .account-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  h1 { font-size: 2.825rem; }
  h2 { font-size: 1.975rem; }
  .page-width { width: min(calc(100% - 30px), var(--page-width)); }
  .brand { min-width: 0; }
  .brand span { display: none; }
  .nav-command { display: none !important; }
  .home-hero { min-height: 78vh; padding: calc(var(--header-height) + 55px) 20px 58px; }
  .home-hero h1 { font-size: 3.625rem; }
  .home-hero-content > p:not(.eyebrow) { font-size: 1.125rem; }
  .hero-scroll { display: none; }
  .hero-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .world-section { min-height: 650px; height: 82vh; max-height: 780px; }
  .world-media { inset: 0; transform: none !important; }
  .world-section::after, .world-section.align-right::after { inset: 0; background: linear-gradient(0deg, rgba(31,20,12,.9) 0%, rgba(31,20,12,.7) 42%, rgba(31,20,12,.2) 70%, transparent 88%); }
  .world-content:not(.wide, .centered), .world-content.wide .world-copy { border-left: 3px solid rgba(255,216,132,.62); padding-left: 20px; }
  .align-right .world-content { align-items: flex-start; border-right: 0; border-left: 3px solid rgba(255,216,132,.62); padding-right: 0; padding-left: 20px; text-align: left; }
  .world-content h2 { font-size: 2.325rem; }
  .final-world .welcome-title { font-size: 2.725rem; }
  .final-world .world-memory { font-size: 1.35rem; }
  .world-content.wide { gap: 24px; }
  .leader-preview { width: 100%; }
  .masthead { min-height: 285px; padding-bottom: 34px; }
  .masthead h1 { font-size: 2.625rem; }
  .page-band, .account-band { padding: 48px 0 70px; }
  .section-heading, .leader-toolbar { align-items: flex-start; flex-direction: column; }
  .download-grid { grid-template-columns: 1fr; }
  .download-card:last-child { grid-column: auto; }
  .update-card { grid-template-columns: 1fr 40px; gap: 12px; }
  .update-date { grid-column: 1 / -1; }
  .article-meta { flex-direction: column; gap: 3px; }
  .segmented-control { width: 100%; }
  .segmented-control a { flex: 1; min-width: 0; }
  th, td { padding: 12px; }
  .info-panel { padding: 20px; }
  .character-vitals { grid-template-columns: repeat(2, 1fr); }
  .skill-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-panel { padding: 26px 22px; }
  .site-footer { align-items: flex-start; flex-direction: column; padding: 34px 22px; }
  .site-footer nav { gap: 12px 18px; }
}

@media (max-width: 430px) {
  .nav-actions { gap: 4px; }
  .home-hero h1 { font-size: 3.025rem; }
  .world-content h2 { font-size: 2.025rem; }
  .skill-grid { grid-template-columns: 1fr; }
  .rules-list > section { grid-template-columns: 42px 1fr; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .world-media { transform: none !important; }
  .home-hero-image { transform: none !important; }
  .masthead-video { display: none; }
  .world-motion-ready .world-content > * { opacity: 1; transform: none; }
}
