/* Layout: full-bleed key-art hero with a live tremor ring, then alternating screenshot/text rows like layers of soil,
   a row of general portraits, FAQ and footer. One dark look on purpose: the game lives underground. */
:root {
  --soil-0: #0e0a07;      /* page */
  --soil-1: #18110b;      /* raised surfaces */
  --soil-2: #2c2016;      /* lines */
  --bone: #efe6d6;        /* text */
  --dust: #b3a289;        /* secondary text */
  --amber: #f2a541;       /* fungus-lamp glow, the accent */
  --ember: #d4512d;       /* tremor warning red, as in the game */
  --display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
  --body: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--soil-0); color: var(--bone); font-family: var(--body); font-size: 17px; line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--amber); text-underline-offset: 3px; }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--display); font-weight: 900; line-height: 1; letter-spacing: 0.01em; text-wrap: balance; margin: 0; }
h2 { font-size: clamp(36px, 6vw, 64px); text-transform: uppercase; }
h3 { font-size: clamp(28px, 3.6vw, 40px); text-transform: uppercase; }
p { margin: 0; }
code { font-size: 0.9em; }

/* Header and footer */
.top { position: absolute; inset: 0 0 auto 0; z-index: 3; display: flex; justify-content: space-between; align-items: center;
  gap: 16px; padding-inline: max(16px, 4vw); padding-block: calc(18px + env(safe-area-inset-top, 0px)) 18px; flex-wrap: wrap; }
.docpage .top { position: static; border-bottom: 1px solid var(--soil-2); }
.wordmark { font-family: var(--display); font-weight: 900; font-size: 24px; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--bone); text-decoration: none; }
.top nav, .foot nav { display: flex; gap: 6px 22px; flex-wrap: wrap; }
.top nav a { color: var(--bone); text-decoration: none; font-size: 15px; font-weight: 500; }
.top nav a:hover { color: var(--amber); }

.foot { border-top: 1px solid var(--soil-2); padding-inline: max(16px, 4vw); padding-block: 40px calc(40px + env(safe-area-inset-bottom, 0px));
  display: grid; gap: 20px; grid-template-columns: 1fr auto; align-items: start; color: var(--dust); font-size: 15px; }
.foot__brand { display: flex; flex-direction: column; gap: 4px; }
.foot nav a { color: var(--bone); }
.foot__small { grid-column: 1 / -1; font-size: 13px; }
.mail { color: var(--bone); user-select: all; }

/* Hero */
.hero { position: relative; min-height: min(92vh, 860px); display: flex; align-items: flex-end; overflow: hidden;
  background: linear-gradient(180deg, rgba(14,10,7,0.55) 0%, rgba(14,10,7,0.15) 35%, rgba(14,10,7,0.85) 78%, var(--soil-0) 100%),
    url("assets/keyart.jpg") center 40% / cover no-repeat; }
.hero__tremor { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__inner { position: relative; z-index: 2; max-width: 720px; padding-inline: max(16px, 4vw); padding-block: 140px 72px; display: grid; gap: 18px; }
.eyebrow { text-transform: uppercase; letter-spacing: 0.14em; font-size: 13px; font-weight: 600; color: var(--amber); }
.hero h1 { font-size: clamp(64px, 13vw, 156px); text-transform: uppercase; text-shadow: 0 4px 40px rgba(0,0,0,0.7); }
.hero__tagline { font-family: var(--display); font-weight: 700; font-size: clamp(22px, 3vw, 30px); text-transform: uppercase; letter-spacing: 0.06em; color: var(--amber); }
.hero__lede { max-width: 56ch; color: var(--bone); font-size: 18px; }

.stores { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.store { display: inline-flex; align-items: center; min-height: 48px; padding: 10px 20px; border-radius: 10px; font-weight: 600;
  font-size: 15px; background: var(--amber); color: var(--soil-0); text-decoration: none; }
.store--soon { background: transparent; color: var(--bone); border: 1px solid rgba(239,230,214,0.35); }
.store--ghost { background: transparent; color: var(--amber); border: 1px solid var(--amber); }

/* In-game tremor warning, styled after the alert band in the game */
.alert { position: absolute; z-index: 2; right: max(16px, 4vw); top: 120px; max-width: min(420px, calc(100% - 32px));
  display: flex; gap: 12px; align-items: center; padding: 12px 16px; border-radius: 12px;
  background: rgba(24,17,11,0.88); border: 1px solid var(--ember); box-shadow: 0 0 0 1px rgba(212,81,45,0.25), 0 12px 40px rgba(0,0,0,0.5);
  font-size: 14px; line-height: 1.4; }
.alert__icon { flex: none; width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--ember);
  background: radial-gradient(circle, var(--ember) 0 22%, transparent 24% 46%, var(--ember) 48% 54%, transparent 56%); }
.alert__text { display: flex; flex-direction: column; }
.alert__text b { color: #ff8a66; font-weight: 600; }
.alert__text span { color: var(--dust); }

/* Thesis and facts */
.thesis { padding-inline: max(16px, 4vw); padding-block: 96px 64px; max-width: 1200px; margin: 0 auto; display: grid; gap: 24px; }
.thesis > p { max-width: 62ch; font-size: 19px; color: var(--dust); }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 24px 0 0; border-top: 1px solid var(--soil-2); }
.facts div { padding: 20px 20px 0 0; border-right: 1px solid var(--soil-2); }
.facts div + div { padding-left: 20px; }
.facts div:last-child { border-right: 0; }
.facts dt { font-family: var(--display); font-weight: 900; font-size: clamp(30px, 4vw, 48px); color: var(--amber); font-variant-numeric: tabular-nums; }
.facts dd { margin: 4px 0 0; color: var(--dust); font-size: 15px; }

/* Feature rows */
.feature { max-width: 1200px; margin: 0 auto; padding-inline: max(16px, 4vw); padding-block: 56px;
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.feature--flip figure { order: 2; }
.feature figure { margin: 0; border-radius: 14px; overflow: hidden; border: 1px solid var(--soil-2); box-shadow: 0 24px 60px rgba(0,0,0,0.55); }
.feature__text { display: grid; gap: 16px; min-width: 0; }
.feature__text p { color: var(--dust); max-width: 52ch; }
.note { border-left: 2px solid var(--amber); padding-left: 14px; color: var(--bone) !important; font-size: 15px; }

.feature--solo { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.ranks { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; border-top: 1px solid var(--soil-2); }
.ranks li { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--soil-2); }
.ranks b { font-family: var(--display); font-size: 26px; text-transform: uppercase; color: var(--amber); }
.ranks span { color: var(--dust); font-size: 15px; text-align: right; align-self: center; }

/* Generals */
.generals { max-width: 1200px; margin: 0 auto; padding-inline: max(16px, 4vw); padding-block: 72px; display: grid; gap: 16px; }
.generals__lede { color: var(--dust); }
.cards { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.card { background: var(--soil-1); border: 1px solid var(--soil-2); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; }
.card img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.card h3 { font-size: 30px; padding: 16px 18px 0; }
.card .species { padding: 2px 18px 0; font-size: 13px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--amber); }
.card p:last-child { padding: 12px 18px 20px; color: var(--dust); font-size: 15px; }
.card p b { color: var(--bone); }

/* FAQ */
.faq { max-width: 860px; margin: 0 auto; padding-inline: max(16px, 4vw); padding-block: 72px; display: grid; gap: 8px; }
.faq h2 { margin-bottom: 16px; }
details { border-top: 1px solid var(--soil-2); }
details:last-of-type { border-bottom: 1px solid var(--soil-2); }
summary { cursor: pointer; padding: 18px 32px 18px 0; font-weight: 600; list-style: none; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 4px; top: 14px; font-size: 24px; color: var(--amber); }
details[open] summary::after { content: "–"; }
details p { padding: 0 0 20px; color: var(--dust); max-width: 68ch; }

/* Closing call */
.cta { text-align: center; padding-inline: 16px; padding-block: 96px 112px; display: grid; gap: 14px; justify-items: center;
  background: radial-gradient(ellipse at 50% 120%, rgba(242,165,65,0.18), transparent 60%); }
.cta p { color: var(--dust); }

/* Legal and help pages */
.doc { max-width: 760px; margin: 0 auto; padding-inline: max(16px, 4vw); padding-block: 48px 80px; }
.doc h1 { font-size: clamp(44px, 7vw, 72px); text-transform: uppercase; margin-bottom: 24px; }
.doc h2 { font-size: 28px; text-transform: none; font-family: var(--body); font-weight: 600; margin: 40px 0 12px; }
.doc p, .doc li { color: #d9cfbf; }
.doc p + p { margin-top: 12px; }
.doc ul, .doc ol { padding-left: 22px; margin: 12px 0; }
.doc li + li { margin-top: 6px; }
.doc strong { color: var(--bone); }
.doc .tablewrap { overflow-x: auto; margin: 16px 0; }
.doc table { border-collapse: collapse; width: 100%; font-size: 15px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid rgba(232, 220, 200, 0.14); color: #d9cfbf; }
.doc th { color: var(--bone); font-weight: 600; }
.doc .steps { counter-reset: s; list-style: none; padding: 0; }
.doc .steps li { counter-increment: s; position: relative; padding-left: 44px; min-height: 32px; }
.doc .steps li::before { content: counter(s); position: absolute; left: 0; top: -2px; width: 30px; height: 30px; border-radius: 50%;
  border: 1px solid var(--amber); color: var(--amber); display: grid; place-items: center; font-weight: 600; font-size: 15px; }
.box { margin: 24px 0; padding: 18px 20px; border: 1px solid var(--soil-2); border-radius: 12px; background: var(--soil-1); }

@media (max-width: 900px) {
  .feature { grid-template-columns: 1fr; gap: 24px; padding-block: 40px; }
  .feature--flip figure { order: 0; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts div:nth-child(2) { border-right: 0; }
  .facts div:nth-child(3) { padding-left: 0; }
  .alert { top: auto; bottom: 24px; }
  .hero__inner { padding-bottom: 150px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .top nav { display: none; }
  .cards { grid-template-columns: 1fr; }
  .foot { grid-template-columns: 1fr; }
  .alert { left: 16px; right: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
