/* Civilization Unlocked: public landing page. Dark stone and gold, like the channel's banner. */
@font-face { font-family: 'Cinzel'; src: url('/site/fonts/cinzel.woff2') format('woff2'); font-weight: 400 900; font-display: swap; }
@font-face { font-family: 'Source Sans 3'; src: url('/site/fonts/source-sans-3.woff2') format('woff2'); font-weight: 200 900; font-style: normal; font-display: swap; }
@font-face { font-family: 'Source Sans 3'; src: url('/site/fonts/source-sans-3-italic.woff2') format('woff2'); font-weight: 200 900; font-style: italic; font-display: swap; }

:root {
  --bg: #0d0b08;
  --bg-2: #15110c;
  --bg-3: #1d1810;
  --ink: #f3eadb;
  --ink-2: #d9cdb8;
  --muted: #a99a80;
  --gold: #d8b26a;
  --gold-hi: #f2d79b;
  --gold-lo: #9a7432;
  --line: rgba(216, 178, 106, 0.22);
  --display: 'Cinzel', 'Trajan Pro', Georgia, serif;
  --body: 'Source Sans 3', -apple-system, 'Segoe UI', Roboto, sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1200px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 18px/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: .01em; margin: 0; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; border-radius: 4px; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--gold); color: #1a1208; padding: 8px 14px; border-radius: 6px; }
.skip:focus { left: 8px; }

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--gutter);
  padding-top: max(14px, env(safe-area-inset-top));
  transition: background .4s var(--ease), border-color .4s var(--ease), backdrop-filter .4s;
  border-bottom: 1px solid transparent;
}
.nav.solid { background: rgba(13, 11, 8, .82); backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2); border-color: var(--line); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; }
.brand img { width: 40px; height: 40px; flex: none; }
.brand span { font-family: var(--display); font-weight: 700; font-size: 17px; letter-spacing: .06em; color: var(--gold-hi); white-space: nowrap; }
.nav nav { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 28px); }
.nav nav a { text-decoration: none; font-size: 15px; font-weight: 600; letter-spacing: .02em; color: var(--ink-2); transition: color .2s; }
.nav nav a:hover { color: var(--gold-hi); }
.nav .login { padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); white-space: nowrap; }
.nav .login:hover { border-color: var(--gold); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: 999px;
  font: 600 17px/1 var(--body); letter-spacing: .01em; text-decoration: none;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s, border-color .25s;
}
.btn svg { width: 22px; height: 22px; fill: currentColor; }
.btn.gold { color: #1a1208; background: linear-gradient(180deg, var(--gold-hi), var(--gold) 55%, #c49a50); box-shadow: 0 10px 30px -12px rgba(216, 178, 106, .7), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn.gold:hover { transform: translateY(-2px); box-shadow: 0 16px 36px -12px rgba(216, 178, 106, .85), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn.ghost { color: var(--ink); border: 1px solid rgba(243, 234, 219, .35); background: rgba(13, 11, 8, .25); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.btn.ghost:hover { border-color: var(--gold-hi); color: var(--gold-hi); }

/* ---------- hero ---------- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; align-items: flex-end; overflow: hidden; isolation: isolate; }
.hero-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transform: scale(1.04); animation: drift 24s var(--ease) infinite alternate; }
.hero-shade { position: absolute; inset: 0; z-index: -1; background:
  linear-gradient(180deg, rgba(13, 11, 8, .55) 0%, rgba(13, 11, 8, .05) 28%, rgba(13, 11, 8, .2) 52%, rgba(13, 11, 8, .94) 88%, var(--bg) 100%),
  radial-gradient(120% 70% at 0% 100%, rgba(13, 11, 8, .75), transparent 60%); }
.hero-copy { width: 100%; max-width: var(--max); margin: 0 auto; padding: 120px var(--gutter) clamp(72px, 12vh, 120px); }
.eyebrow, .kicker { display: inline-flex; align-items: center; gap: 12px; font: 600 13px/1.2 var(--body); letter-spacing: .22em; text-transform: uppercase; color: var(--gold); }
.eyebrow::before, .kicker::before { content: ''; width: 36px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.hero h1 { margin: 18px 0 22px; max-width: 15ch; font-size: clamp(36px, 6.4vw, 78px); line-height: 1.04; font-weight: 600; text-shadow: 0 2px 30px rgba(0, 0, 0, .55); }
.hero h1 em, .section-head h2 em { font-style: normal; background: linear-gradient(180deg, var(--gold-hi) 10%, var(--gold) 60%, var(--gold-lo)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lede { max-width: 58ch; font-size: clamp(18px, 1.6vw, 21px); color: var(--ink-2); text-shadow: 0 1px 16px rgba(0, 0, 0, .6); }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
.premiere { display: flex; align-items: center; gap: 10px; margin-top: 26px; font-size: 15px; color: var(--ink-2); letter-spacing: .02em; }
.premiere .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold-hi); box-shadow: 0 0 0 0 rgba(242, 215, 155, .6); animation: pulse 2.4s infinite; flex: none; }
.scroll-cue { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); width: 26px; height: 42px; border: 1.5px solid rgba(243, 234, 219, .45); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 3px; height: 8px; margin-left: -1.5px; border-radius: 2px; background: var(--gold-hi); animation: cue 1.8s var(--ease) infinite; }

/* ---------- sections ---------- */
section { position: relative; }
.season, .road, .how { padding: clamp(80px, 12vw, 150px) 0; }
.section-head { max-width: 720px; margin-bottom: clamp(36px, 5vw, 60px); }
.section-head h2 { margin: 14px 0 16px; font-size: clamp(30px, 4.4vw, 54px); line-height: 1.1; }
.section-head p:not(.kicker) { color: var(--ink-2); font-size: clamp(17px, 1.5vw, 20px); }

/* episodes */
.episodes { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2vw, 28px); }
.ep { background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; transition: transform .4s var(--ease), border-color .4s, box-shadow .4s; }
.ep:hover { transform: translateY(-4px); border-color: rgba(216, 178, 106, .5); box-shadow: 0 24px 60px -30px rgba(216, 178, 106, .35); }
.ep-img { position: relative; aspect-ratio: 16 / 10; overflow: hidden; }
.ep-img img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.02); transition: transform 1.2s var(--ease); }
.ep:hover .ep-img img { transform: scale(1.08); }
.ep-img::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(21, 17, 12, .9)); }
.badge { position: absolute; top: 14px; left: 14px; z-index: 1; padding: 6px 12px; border-radius: 999px; font: 700 12px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: #1a1208; background: var(--gold-hi); }
.ep-body { padding: 22px 24px 28px; }
.ep-num { font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.ep h3 { margin: 10px 0 10px; font-size: clamp(22px, 2vw, 27px); line-height: 1.15; }
.ep-body p:last-child { color: var(--ink-2); font-size: 17px; }
.ep.next { border-style: dashed; }
.later { margin-top: clamp(28px, 4vw, 44px); padding-top: 24px; border-top: 1px solid var(--line); color: var(--ink-2); font-size: 17px; line-height: 1.8; }
.later span { display: block; margin-bottom: 4px; font-size: 13px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); }

/* timeline */
.road { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 50%, var(--bg) 100%); }
.timeline { --p: 0; position: relative; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; }
.timeline::before, .timeline::after { content: ''; position: absolute; left: 0; top: 9px; height: 2px; border-radius: 2px; }
.timeline::before { right: 0; background: var(--line); }
.timeline::after { width: calc(var(--p) * 100%); background: linear-gradient(90deg, var(--gold-lo), var(--gold-hi)); box-shadow: 0 0 14px rgba(242, 215, 155, .5); }
.timeline li { position: relative; padding-top: 34px; opacity: .45; transition: opacity .6s var(--ease); }
.timeline li::before { content: ''; position: absolute; top: 3px; left: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--bg); border: 2px solid var(--gold-lo); transition: background .5s, border-color .5s, box-shadow .5s; z-index: 1; }
.timeline li.lit { opacity: 1; }
.timeline li.lit::before { background: var(--gold-hi); border-color: var(--gold-hi); box-shadow: 0 0 0 5px rgba(242, 215, 155, .14); }
.timeline .when { display: block; font-size: 13px; color: var(--muted); letter-spacing: .02em; }
.timeline .what { display: block; margin-top: 6px; font: 600 clamp(15px, 1.4vw, 18px)/1.25 var(--display); color: var(--ink); }
.timeline li:first-child .what { color: var(--gold-hi); }

/* quote band */
.band { min-height: clamp(420px, 70vh, 720px); display: grid; place-items: center; overflow: hidden; isolation: isolate; text-align: center; padding: 80px var(--gutter); }
.band-img { position: absolute; inset: -6% 0; z-index: -1; background: url('/site/img/fire.jpg') center / cover no-repeat; transform: translateY(calc(var(--shift, 0) * 1px)) scale(1.08); will-change: transform; }
.band::after { content: ''; position: absolute; inset: 0; z-index: -1; background: radial-gradient(80% 90% at 50% 50%, rgba(13, 11, 8, .35), rgba(13, 11, 8, .85)), linear-gradient(180deg, var(--bg), transparent 22%, transparent 78%, var(--bg)); }
.band blockquote { margin: 0; max-width: 900px; }
.band blockquote p { font: 600 clamp(28px, 4.6vw, 58px)/1.15 var(--display); text-shadow: 0 2px 40px rgba(0, 0, 0, .7); }
.band cite { display: block; margin-top: 22px; font-style: normal; font-size: 14px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--gold-hi); }

/* pillars */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2vw, 28px); }
.pillar { padding: 30px 28px 32px; border-radius: 18px; background: linear-gradient(180deg, var(--bg-3), var(--bg-2)); border: 1px solid var(--line); }
.pillar .num { display: inline-grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--gold-lo); font: 700 15px/1 var(--display); color: var(--gold-hi); }
.pillar h3 { margin: 20px 0 10px; font-size: 22px; }
.pillar p { color: var(--ink-2); font-size: 17px; }

/* final call */
.final { padding: clamp(80px, 12vw, 150px) 0; text-align: center; background: radial-gradient(60% 60% at 50% 40%, rgba(216, 178, 106, .12), transparent 70%); }
.final .mark { width: 112px; height: 112px; margin: 0 auto 26px; filter: drop-shadow(0 10px 40px rgba(242, 215, 155, .25)); }
.final h2 { font-size: clamp(28px, 4vw, 48px); line-height: 1.12; max-width: 18ch; margin: 0 auto 16px; }
.final p { color: var(--ink-2); margin-bottom: 30px; font-size: 19px; }

/* footer */
.foot { padding: 40px 0 calc(40px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
.foot .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 28px; }
.foot-brand { font: 700 15px/1 var(--display); letter-spacing: .08em; color: var(--gold-hi); }
.foot nav { display: flex; gap: 22px; }
.foot nav a { font-size: 15px; color: var(--ink-2); text-decoration: none; }
.foot nav a:hover { color: var(--gold-hi); }
.fine { flex-basis: 100%; font-size: 13px; color: var(--muted); }

/* ---------- reveal on scroll ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js [data-reveal].in { opacity: 1; transform: none; }
.js .episodes [data-reveal]:nth-child(2), .js .pillars [data-reveal]:nth-child(2) { transition-delay: .12s; }
.js .episodes [data-reveal]:nth-child(3), .js .pillars [data-reveal]:nth-child(3) { transition-delay: .24s; }

@keyframes drift { from { transform: scale(1.04) translate3d(0, 0, 0); } to { transform: scale(1.1) translate3d(-1.5%, -1%, 0); } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(242, 215, 155, .6); } 70% { box-shadow: 0 0 0 10px rgba(242, 215, 155, 0); } 100% { box-shadow: 0 0 0 0 rgba(242, 215, 155, 0); } }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- smaller screens ---------- */
@media (max-width: 980px) {
  .episodes, .pillars { grid-template-columns: 1fr 1fr; }
  .episodes .ep.next { grid-column: 1 / -1; }
  .timeline { grid-template-columns: 1fr; gap: 0; padding-left: 30px; }
  .timeline::before, .timeline::after { left: 6px; top: 6px; bottom: 6px; width: 2px; height: auto; right: auto; }
  .timeline::after { height: calc(var(--p) * (100% - 12px)); bottom: auto; }
  .timeline li { padding: 0 0 26px; }
  .timeline li::before { left: -30px; top: 3px; }
}
@media (max-width: 640px) {
  body { font-size: 17px; }
  .hide-sm { display: none; }
  .brand span { font-size: 14px; letter-spacing: .04em; }
  .brand img { width: 34px; height: 34px; }
  .nav .login { padding: 7px 12px; font-size: 14px; }
  .episodes, .pillars { grid-template-columns: 1fr; }
  .cta-row .btn { flex: 1 1 100%; }
  .hero-copy { padding-bottom: 84px; }
  .scroll-cue { display: none; }
}
@media (max-width: 360px) { .brand span { display: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-media, .premiere .dot, .scroll-cue span { animation: none; }
  .band-img { transform: scale(1.08); }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
}
