@font-face {
  font-family: "Black Ops One";
  src: url("/fonts/blackops.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Special Elite";
  src: url("/fonts/specialelite.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Oswald";
  src: url("/fonts/oswald.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Oswald";
  src: url("/fonts/oswald-semibold.woff") format("woff");
  font-weight: 650;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #14160f;
  --bg-elev: #1c2016;
  --panel: #23281b;
  --ink: #f3ebd3;
  --muted: #c2b99c;
  --gold: #d4b45a;
  --gold-dim: #9a7f32;
  --olive: #7a8a4a;
  --olive-dark: #3a4526;
  --allies: #7eb0d4;
  --axis: #d07a6c;
  --line: rgba(212, 180, 90, 0.38);
  --shadow: rgba(0, 0, 0, 0.45);
  --focus: #ffe08a;
  --error: #e8b07a;
  --max: 68rem;
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Georgia, "Times New Roman", Times, serif;
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(122, 138, 74, 0.16), transparent 55%),
    radial-gradient(ellipse at 100% 80%, rgba(80, 50, 20, 0.2), transparent 45%),
    var(--bg);
  background-attachment: fixed;
}

/* faint film grain without images */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--gold);
  color: #1a1608;
  padding: 0.5rem 0.8rem;
  z-index: 20;
  font-family: Oswald, sans-serif;
  text-decoration: none;
}
.skip:focus { top: 0.6rem; }

.wrap {
  position: relative;
  z-index: 1;
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(20, 22, 15, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: inherit;
  text-decoration: none;
}

.brand img, .brand svg {
  width: 2.4rem;
  height: 2.4rem;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-kicker {
  font-family: Oswald, sans-serif;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.7rem;
  color: var(--gold);
}

.brand-name {
  font-family: "Black Ops One", Impact, sans-serif;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  font-family: Oswald, sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4rem 0.7rem;
  cursor: pointer;
}

.nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav a {
  font-family: Oswald, sans-serif;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #ddd4b6;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  padding: 0.2rem 0;
}

.nav a:hover, .nav a:focus-visible {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

/* Hero */
.hero {
  padding: 2.6rem 0 2rem;
  text-align: center;
}

.stamp {
  display: inline-block;
  font-family: "Special Elite", "Courier New", monospace;
  font-size: 0.92rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  border: 2px solid var(--gold-dim);
  padding: 0.35rem 0.8rem;
  transform: rotate(-1.4deg);
  margin-bottom: 1.1rem;
}

h1 {
  font-family: "Black Ops One", Impact, sans-serif;
  font-weight: 400;
  font-size: clamp(2.1rem, 6vw, 3.6rem);
  line-height: 1.05;
  margin: 0 0 0.6rem;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 0 #000, 0 0 24px rgba(212, 180, 90, 0.15);
}

.lede {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 40rem;
  margin: 0 auto 1.6rem;
}

/* Quick card */
.quick {
  display: grid;
  gap: 0.8rem;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 12px 40px var(--shadow), inset 0 0 0 1px rgba(0,0,0,0.35);
  padding: 1.2rem 1.3rem 1.3rem;
  text-align: left;
  margin: 0 auto 0.5rem;
  max-width: 46rem;
}

.quick h2 {
  margin: 0 0 0.4rem;
  font-size: 1.1rem;
}

.cmd-row {
  display: flex;
  align-items: stretch;
  gap: 0.45rem;
  margin: 0.35rem 0;
}

code, .cmd, kbd {
  font-family: ui-monospace, "Cascadia Code", "SF Mono", Menlo, Consolas, "Courier New", monospace;
  font-size: 1rem;
  background: #10120c;
  color: #f6e7b0;
  border: 1px solid rgba(212, 180, 90, 0.45);
}
kbd {
  display: inline-flex;
  align-items: flex-end;
  justify-content: center;
  font-family: "Courier New", Courier, monospace;
  font-size: 1.7rem;
  line-height: 1;
  height: 2.15rem;
  padding: 0 0.45rem 0.15rem;
  min-width: 1.8rem;
  text-align: center;
  font-weight: 700;
  color: #fff6d0;
  text-shadow: 0 1px 0 #000;
  border-color: var(--gold);
  box-shadow: 0 2px 0 #000;
  vertical-align: middle;
}

.cmd {
  flex: 1;
  padding: 0.55rem 0.7rem;
  overflow-x: auto;
  white-space: nowrap;
}

p code, li code {
  padding: 0.08rem 0.32rem;
  white-space: nowrap;
}

.copy {
  font-family: Oswald, sans-serif;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--olive-dark);
  color: var(--ink);
  border: 1px solid var(--gold-dim);
  padding: 0 0.7rem;
  cursor: pointer;
  min-width: 4.4rem;
}

.copy:hover, .copy:focus-visible { background: #4d5c30; color: #fff; }
.copy.done { background: var(--olive); color: #111; }

.note {
  color: var(--muted);
  font-size: 1rem;
  margin: 0.5rem 0 0;
}

/* Sections */
section {
  padding: 1.8rem 0 0.4rem;
}

section > h2, .section-title {
  font-family: "Black Ops One", Impact, sans-serif;
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2rem);
  letter-spacing: 0.03em;
  margin: 0 0 0.8rem;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid var(--line);
}

h3 {
  font-family: Oswald, sans-serif;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 1.15rem;
  margin: 1.3rem 0 0.4rem;
  color: var(--gold);
}

p { margin: 0 0 0.85rem; }
ul, ol { margin: 0 0 1rem; padding-left: 1.3rem; }
li { margin: 0.25rem 0; }
a { color: var(--gold); }
a:hover { color: #f0d589; }

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(15.5rem, 1fr));
}

.card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  padding: 1rem 1.1rem 1.15rem;
}

.card h3 { margin-top: 0; }

.btn {
  display: inline-block;
  font-family: Oswald, sans-serif;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  background: linear-gradient(#5c6b38, #3d4a26);
  color: var(--ink);
  border: 1px solid var(--gold-dim);
  padding: 0.55rem 0.9rem;
  margin: 0.2rem 0.4rem 0.2rem 0;
}

.btn:hover, .btn:focus-visible {
  color: #fff;
  background: linear-gradient(#6e8244, #4a5a2c);
}

.btn.secondary {
  background: transparent;
  color: var(--gold);
}

.pill {
  display: inline-block;
  font-family: Oswald, sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  padding: 0.1rem 0.45rem;
  margin-right: 0.25rem;
  color: var(--muted);
}

.team-axis { color: var(--axis); border-color: rgba(208, 122, 108, 0.5); }
.team-allies { color: var(--allies); border-color: rgba(126, 176, 212, 0.5); }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps > li {
  position: relative;
  padding: 0.7rem 0 0.7rem 3.2rem;
  border-top: 1px dashed var(--line);
}
.steps > li:last-child { border-bottom: 1px dashed var(--line); }
.steps > li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0.7rem;
  width: 2.2rem;
  height: 2.2rem;
  border: 2px solid var(--gold-dim);
  color: var(--gold);
  font-family: "Black Ops One", sans-serif;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.kids {
  background:
    linear-gradient(180deg, rgba(122, 138, 74, 0.16), rgba(20, 22, 15, 0.2)),
    var(--panel);
  border: 2px solid var(--gold-dim);
  padding: 1.2rem 1.3rem;
}

.kids h2 {
  border-bottom-color: var(--gold-dim);
  color: #f6e7b0;
}

.troubles dt {
  font-family: Oswald, sans-serif;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 1rem;
}
.troubles dd { margin: 0.25rem 0 0 0; }

.site-footer {
  margin-top: 2.5rem;
  border-top: 1px solid var(--line);
  padding: 1.4rem 0 2.4rem;
  color: var(--muted);
  font-size: 0.98rem;
  text-align: center;
}

/* Login */
.login-main {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem 1rem;
}

.login-card {
  width: min(100%, 28rem);
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 16px 50px var(--shadow);
  padding: 1.6rem 1.5rem 1.7rem;
  text-align: center;
}

.login-card h1 {
  font-size: 1.8rem;
}

.login-card label {
  display: block;
  text-align: left;
  font-family: Oswald, sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.9rem;
  color: var(--gold);
  margin-bottom: 0.35rem;
}

.login-card input[type="password"] {
  width: 100%;
  font-family: "Special Elite", monospace;
  font-size: 1.2rem;
  padding: 0.7rem 0.75rem;
  background: #10120c;
  color: var(--ink);
  border: 1px solid var(--gold-dim);
  margin-bottom: 0.9rem;
}

.login-card button[type="submit"] {
  width: 100%;
  font-family: Oswald, sans-serif;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 1.05rem;
  padding: 0.75rem;
  background: linear-gradient(#5c6b38, #3d4a26);
  color: var(--ink);
  border: 1px solid var(--gold);
  cursor: pointer;
}

.login-card button[type="submit"]:hover {
  color: #fff;
}

.err {
  color: var(--error);
  font-family: "Special Elite", monospace;
  margin: 0 0 0.8rem;
}

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

@media (max-width: 720px) {
  body { font-size: 1.05rem; }
  .nav-toggle { display: inline-block; }
  .nav { display: none; width: 100%; }
  .site-header .wrap { flex-wrap: wrap; }
  .nav.is-open { display: block; }
  .nav.is-open ul { flex-direction: column; padding: 0.4rem 0 0.6rem; gap: 0.45rem; }
  .cmd { white-space: normal; }
}

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