/* Udoiana Raunes 3 — landing page. No external resources: the font is bundled (fonts/, SIL OFL). */
@font-face {
  font-family: 'Nunito';
  font-weight: 800;
  font-style: normal;
  font-display: swap;
  src: url('../fonts/nunito-extrabold.woff2') format('woff2');
}

:root {
  --ink: #1a110a;          /* page background: dark leather */
  --ink-2: #24170d;
  --ink-3: #33210f;
  --cream: #f6ecd6;        /* text on dark */
  --muted: #cdb996;
  --parchment: #f1e2bf;
  --parchment-2: #e3cc9c;
  --parchment-ink: #2b1d14;
  --parchment-muted: #5c4630;
  --gold: #f0b43c;
  --gold-2: #ffcf5a;
  --red: #c4461d;          /* the logo's red-orange */
  --red-2: #a83612;
  --jungle: #1d3523;
  --focus: #ffd66b;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .45);
  --display: 'Nunito', ui-rounded, 'Arial Rounded MT Bold', system-ui, sans-serif;
  --body: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0; background: var(--ink); color: var(--cream);
  font: 17px/1.6 var(--body);
  overflow-x: hidden;
}
img, video { max-width: 100%; display: block; }
a { color: var(--gold-2); text-underline-offset: 3px; }
a:hover { color: #fff; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; line-height: 1.15; margin: 0 0 .5em; letter-spacing: .005em; }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); color: var(--gold); text-shadow: 0 2px 0 rgba(0,0,0,.45); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 10; background: var(--gold); color: var(--ink); padding: 8px 14px; border-radius: 8px; font-weight: 700; }
.skip:focus { top: 12px; }

/* ---------------------------------------------------------------- top bar */
.topbar { position: absolute; inset: 0 0 auto 0; z-index: 3; }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; }
.brand { font-family: var(--display); color: var(--cream); text-decoration: none; font-size: 1.05rem; opacity: .9; }
.topbar nav { display: flex; gap: 6px 18px; flex-wrap: wrap; justify-content: flex-end; }
.topbar nav a { color: var(--muted); text-decoration: none; font-size: .95rem; }
.topbar nav a:hover { color: var(--cream); }
@media (max-width: 720px) { .topbar nav { display: none; } }

/* ---------------------------------------------------------------- hero */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  padding: 76px 0 64px; text-align: center;
  background:
    radial-gradient(120% 80% at 50% 30%, rgba(26,17,10,0) 0%, rgba(26,17,10,.55) 60%, var(--ink) 100%),
    url('../img/jungle.jpg') center / cover no-repeat, var(--jungle);
}
.hero::after { /* soft fade into the page */
  content: ''; position: absolute; inset: auto 0 0 0; height: 120px; z-index: -1;
  background: linear-gradient(to bottom, rgba(26,17,10,0), var(--ink));
}
.hero .banner { width: min(900px, 100%); height: auto; margin: 0 auto -6px; filter: drop-shadow(0 18px 28px rgba(0,0,0,.55)); }
.hero h1 { font-size: clamp(1.5rem, 3.6vw, 2.4rem); color: var(--cream); margin: .2em 0 .25em; text-shadow: 0 3px 0 rgba(0,0,0,.5); }
.hero h1 .sub { display: block; color: var(--gold); font-size: .72em; margin-top: .2em; }
.hero .lead { max-width: 640px; margin: 0 auto 28px; color: var(--cream); font-size: 1.08rem; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.play { display: flex; gap: 16px 20px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  min-width: 260px; padding: 16px 28px 14px; border-radius: 16px; text-decoration: none;
  font-family: var(--display); font-size: 1.45rem; line-height: 1.1; color: var(--parchment-ink);
  background: linear-gradient(#ffd66b, var(--gold)); border: 3px solid #2b1d14;
  box-shadow: 0 6px 0 #2b1d14, 0 14px 26px rgba(0,0,0,.45);
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}
.btn small { font-family: var(--body); font-size: .8rem; font-weight: 600; opacity: .8; letter-spacing: .01em; }
.btn:hover { color: var(--parchment-ink); transform: translateY(-2px); box-shadow: 0 8px 0 #2b1d14, 0 18px 30px rgba(0,0,0,.5); filter: brightness(1.04); }
.btn:active { transform: translateY(4px); box-shadow: 0 2px 0 #2b1d14, 0 8px 16px rgba(0,0,0,.45); }
.btn.alt { background: linear-gradient(var(--parchment), var(--parchment-2)); }
.btn:focus-visible { outline-offset: 5px; }
.note { margin: 22px auto 0; font-size: .92rem; color: var(--muted); }
.touch-note { display: none; }
@media (pointer: coarse) { .touch-note { display: block; } }
.touch-note { max-width: 520px; margin: 12px auto 0; padding: 8px 14px; border-radius: 10px; background: rgba(0,0,0,.45); font-size: .9rem; color: var(--cream); }

/* ---------------------------------------------------------------- sections */
section { padding: 72px 0; }
section.alt { background: linear-gradient(180deg, var(--ink) 0, var(--ink-2) 12%, var(--ink-2) 88%, var(--ink) 100%); }
.intro-text { max-width: 720px; color: var(--muted); font-size: 1.05rem; }
.center { text-align: center; }
.center .intro-text { margin-inline: auto; }

/* parchment panels */
.parchment {
  background:
    radial-gradient(120% 120% at 50% 40%, rgba(255,255,255,.28), rgba(255,255,255,0) 60%),
    radial-gradient(140% 140% at 50% 50%, rgba(0,0,0,0) 60%, rgba(120,80,30,.35) 100%),
    var(--parchment);
  color: var(--parchment-ink);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.parchment a { color: var(--red-2); }
.parchment a:hover { color: #6e1f06; }
.parchment :focus-visible { outline-color: var(--red-2); }

/* ---------------------------------------------------------------- trailer */
.video-frame { padding: 12px; border-radius: 18px; background: linear-gradient(#3b2614, #1f140b); box-shadow: var(--shadow), inset 0 0 0 2px rgba(240,180,60,.25); }
.video-frame video { width: 100%; height: auto; aspect-ratio: 16 / 9; border-radius: 10px; background: #000; }
.caption { margin-top: 12px; color: var(--muted); font-size: .92rem; text-align: center; }

/* ---------------------------------------------------------------- before / after */
.ba { position: relative; margin-top: 8px; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 16 / 10; background: #000; user-select: none; -webkit-user-select: none; touch-action: pan-y; }
.ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ba .vga { image-rendering: pixelated; image-rendering: crisp-edges; clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0); }
.ba .handle { position: absolute; top: 0; bottom: 0; left: var(--pos, 50%); width: 0; pointer-events: none; }
.ba .handle::before { content: ''; position: absolute; top: 0; bottom: 0; left: -2px; width: 4px; background: var(--gold); box-shadow: 0 0 10px rgba(0,0,0,.6); }
.ba .handle::after {
  content: '◀ ▶'; position: absolute; top: 50%; left: 0; transform: translate(-50%, -50%);
  padding: 8px 10px; border-radius: 999px; background: var(--gold); color: var(--parchment-ink);
  font: 800 14px/1 var(--display); letter-spacing: 2px; white-space: nowrap; box-shadow: 0 4px 12px rgba(0,0,0,.5);
}
.ba .tag { position: absolute; top: 12px; padding: 4px 10px; border-radius: 8px; background: rgba(20,13,8,.78); font: 800 14px/1.2 var(--display); pointer-events: none; }
.ba .tag.l { left: 12px; color: #ffe27a; }
.ba .tag.r { right: 12px; color: var(--cream); }
.ba input[type=range] { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.ba:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
.tabs { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 18px 0 6px; }
.tabs button {
  font: 800 .98rem/1 var(--display); color: var(--cream); cursor: pointer;
  background: var(--ink-3); border: 2px solid rgba(240,180,60,.35); border-radius: 999px; padding: 9px 16px;
}
.tabs button[aria-pressed="true"] { background: var(--gold); color: var(--parchment-ink); border-color: var(--gold); }
.tabs button:hover { border-color: var(--gold); }

/* ---------------------------------------------------------------- cast */
.cast { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin-top: 28px; align-items: end; }
@media (max-width: 860px) { .cast { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 520px) { .cast { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.who { margin: 0; text-align: center; padding: 18px 10px 14px; border-radius: var(--radius); cursor: pointer; }
.who .fig { position: relative; height: 230px; display: flex; justify-content: center; align-items: flex-end; }
.who .fig img { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); height: calc(var(--h, 260) * .8px); width: auto; max-width: none; transition: opacity .25s ease, transform .25s ease; }
.who .px { image-rendering: pixelated; image-rendering: crisp-edges; opacity: 0; }
.who:hover .px, .who:focus-visible .px, .cast.pixels .px { opacity: 1; }
.who:hover .hd, .who:focus-visible .hd, .cast.pixels .hd { opacity: 0; }
.cast.pixels .who:hover .px, .cast.pixels .who:focus-visible .px { opacity: 0; }
.cast.pixels .who:hover .hd, .cast.pixels .who:focus-visible .hd { opacity: 1; }
.who figcaption { margin-top: 12px; }
.who strong { display: block; font: 800 1.08rem/1.2 var(--display); }
.who span { display: block; font-size: .9rem; color: var(--parchment-muted); line-height: 1.35; margin-top: 4px; }
.cast-ctl { display: flex; justify-content: center; margin-top: 22px; }
.toggle {
  font: 800 1rem/1 var(--display); cursor: pointer; color: var(--cream); background: var(--ink-3);
  border: 2px solid var(--gold); border-radius: 999px; padding: 11px 18px;
}
.toggle:hover { background: #41290f; }
kbd { font: 800 .82em/1 var(--display); padding: 3px 7px 2px; border-radius: 6px; background: var(--cream); color: var(--parchment-ink); border-bottom: 2px solid #9c8566; white-space: nowrap; }

/* ---------------------------------------------------------------- timeline */
.timeline { list-style: none; margin: 36px 0 0; padding: 0; position: relative; }
.timeline::before { /* the red travel line of the in-game map */
  content: ''; position: absolute; left: 128px; top: 12px; bottom: 12px; width: 0;
  border-left: 4px dashed var(--red);
}
.timeline li { position: relative; display: grid; grid-template-columns: 110px 1fr; gap: 0 36px; margin: 0 0 22px; }
.timeline .year { font: 800 1.35rem/1.1 var(--display); color: var(--gold); text-align: right; padding-top: 18px; }
.timeline .year small { display: block; font-size: .72rem; color: var(--muted); letter-spacing: .04em; margin-top: 3px; }
.timeline li::before { /* the map pin */
  content: ''; position: absolute; left: 128px; top: 22px; width: 18px; height: 18px; margin-left: -7px;
  background: var(--red); border: 3px solid var(--cream); border-radius: 50%; box-shadow: 0 2px 6px rgba(0,0,0,.5);
}
.timeline .card { padding: 18px 22px 8px; }
.timeline .card h3 { color: var(--parchment-ink); }
.timeline .quote { font-style: italic; color: var(--parchment-muted); }
.timeline li.now .card { background: linear-gradient(135deg, #fff2c9, var(--parchment-2)); }
@media (max-width: 640px) {
  .timeline::before, .timeline li::before { left: 10px; }
  .timeline li { grid-template-columns: 1fr; padding-left: 36px; }
  .timeline .year { text-align: left; padding: 0 0 8px; }
  .timeline li::before { top: 2px; }
}
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 14px 0 10px; }
@media (max-width: 640px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat { background: rgba(43,29,20,.08); border: 1px solid rgba(43,29,20,.18); border-radius: 10px; padding: 10px 12px; }
.stat b { display: block; font: 800 1.35rem/1.1 var(--display); color: var(--red-2); }
.stat span { font-size: .86rem; line-height: 1.3; display: block; margin-top: 3px; }

/* ---------------------------------------------------------------- how to play */
.howto { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; margin-top: 26px; }
.howto .parchment { padding: 22px 24px 10px; }
.howto h3 { color: var(--red-2); }
.verbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 4px 0 16px; padding: 10px; border-radius: 10px; background: #0d1a6e; }
.verbs span { text-align: center; font: 800 .82rem/1 var(--display); color: #0d1a6e; background: #e3e6fa; border-radius: 5px; padding: 7px 2px; }
.keys { list-style: none; padding: 0; margin: 0 0 14px; }
.keys li { display: grid; grid-template-columns: 76px 1fr; gap: 10px; padding: 6px 0; border-bottom: 1px dashed rgba(43,29,20,.2); }
.keys li:last-child { border-bottom: 0; }
.keys .k { display: flex; gap: 4px; align-items: flex-start; }
.keys kbd { justify-self: start; align-self: start; margin-top: 2px; background: var(--parchment-ink); color: var(--cream); border-bottom-color: #000; }

/* ---------------------------------------------------------------- credits */
.credits { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; margin-top: 28px; }
.credit { padding: 20px 22px 12px; }
.credit .role { font-size: .9rem; color: var(--parchment-muted); margin-bottom: 10px; }
.credit h3 { margin-bottom: 4px; }
.purist { display: flex; gap: 20px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 22px 26px; margin-top: 30px; }
.purist p { margin: 0; max-width: 640px; }
.purist .btn { min-width: 0; font-size: 1.1rem; padding: 12px 20px 10px; }

/* ---------------------------------------------------------------- footer */
footer { padding: 42px 0 90px; color: var(--muted); font-size: .88rem; border-top: 1px solid rgba(240,180,60,.15); background: #140d07; }
footer p { max-width: 900px; }
footer .links { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-bottom: 14px; }
footer .links a { color: var(--cream); }

/* ---------------------------------------------------------------- storage notice (tiny, non-blocking) */
.storage-note {
  position: fixed; right: 14px; bottom: 14px; z-index: 20; max-width: calc(100% - 28px);
  display: flex; align-items: center; gap: 10px; padding: 7px 7px 7px 14px; border-radius: 999px;
  background: rgba(20,13,8,.92); color: var(--cream); font-size: .84rem; line-height: 1.3;
  border: 1px solid rgba(240,180,60,.35); box-shadow: 0 6px 18px rgba(0,0,0,.45);
}
.storage-note[hidden] { display: none; }
.storage-note a { color: var(--gold-2); }
.storage-note button {
  flex: none; cursor: pointer; font: 800 .82rem/1 var(--display); color: var(--parchment-ink);
  background: var(--gold); border: 0; border-radius: 999px; padding: 7px 12px;
}

/* ---------------------------------------------------------------- legal pages */
.legal { padding: 110px 0 60px; }
.legal .parchment { padding: 28px 30px 16px; max-width: 820px; }
.legal h1 { color: var(--parchment-ink); font-size: clamp(1.7rem, 4vw, 2.3rem); }
.legal h2 { color: var(--red-2); font-size: 1.3rem; text-shadow: none; margin-top: 1.2em; }
.legal address { font-style: normal; margin-bottom: 1em; }
@media (max-width: 520px) { .play .btn { width: 100%; min-width: 0; } .storage-note { font-size: .78rem; } }
