/* A Vote for the King of the Romans: promo site. Colours follow the trailer's grades:
   ember (turmoil, John), steel dawn (Louis), candle (Charles), gold (the finale). */
:root {
  --night: #0c0907;
  --night-2: #15100b;
  --night-3: #1e1710;
  --ink: #ecdfc4;
  --ink-soft: #c2b296;
  --ink-mute: #8f8169;
  --gold: #d9ad55;
  --gold-hi: #f6d98f;
  --gold-deep: #8a6420;
  --ember: #d0662c;
  --lux: #c3352f;
  --lux-deep: #5e1512;
  --witt: #5b95d6;
  --witt-deep: #15304f;
  --rule: rgba(217, 173, 85, .28);
  --title: "Grenze Gotisch", "UnifrakturMaguntia", "Old English Text MT", serif;
  --serif: "EB Garamond", Garamond, "Times New Roman", serif;
  --gutter: clamp(16px, 4vw, 40px);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--night); color: var(--ink);
  font: 400 clamp(17px, 1.1vw + 12px, 20px)/1.6 var(--serif);
  overflow-x: hidden; text-rendering: optimizeLegibility;
}
img, video, canvas, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--gold-hi); text-underline-offset: .18em; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; }
p { margin: 0 0 1em; }
.wrap { width: min(1200px, 100%); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { width: min(820px, 100%); }
.center { text-align: center; }
.skip { position: absolute; left: -999px; top: 0; }
.skip:focus { left: 16px; z-index: 50; background: var(--gold); color: var(--night); padding: 8px 12px; }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; }

/* Type, as in the trailer: blackletter caps with wide tracking, Garamond italic beneath */
.caps {
  font-family: var(--title); font-weight: 700; text-transform: uppercase;
  letter-spacing: .12em; font-size: clamp(30px, 4.4vw, 58px); line-height: 1.05;
  color: #f3e6cc; text-shadow: 0 0 24px rgba(240, 190, 110, .28), 0 2px 0 rgba(0, 0, 0, .6);
}
.sub { font-style: italic; color: var(--ink-soft); font-size: 1.05em; }
.kicker {
  font-family: var(--title); font-weight: 500; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold); font-size: .85em; margin-bottom: .6em;
}
.line { text-wrap: balance; font-style: italic; font-size: clamp(24px, 2.6vw, 34px); line-height: 1.35; color: #f1e2c3; }
.body { color: var(--ink-soft); }
.intro { color: var(--ink-soft); font-style: italic; max-width: 640px; margin: 1em auto 0; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: .55em; justify-content: center;
  padding: .8em 1.5em; border: 1px solid var(--gold); color: var(--ink);
  font: 500 .82em/1 var(--title); letter-spacing: .22em; text-transform: uppercase; text-decoration: none;
  background: rgba(12, 9, 7, .45); backdrop-filter: blur(4px);
  transition: background .25s, color .25s, box-shadow .25s, transform .25s;
}
.btn:hover { background: rgba(217, 173, 85, .14); box-shadow: 0 0 28px rgba(217, 173, 85, .25); transform: translateY(-1px); }
.btn svg { width: 1.1em; height: 1.1em; fill: currentColor; }
.btn-gold { background: linear-gradient(180deg, #ecc777, #b8862f); color: #1b1208; border-color: #f3d48c; font-weight: 700; }
.btn-gold:hover { background: linear-gradient(180deg, #f7d98f, #c99637); color: #1b1208; }
.btn-small { padding: .6em 1em; font-size: .72em; }
.ctas { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }

/* Header bar */
.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 20; height: 60px;
  display: flex; align-items: center; gap: 18px; padding: 0 var(--gutter);
  transition: background .35s, border-color .35s; border-bottom: 1px solid transparent;
}
.bar.solid { background: rgba(12, 9, 7, .88); backdrop-filter: blur(10px); border-color: var(--rule); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--gold); margin-right: auto; }
.brand svg { width: 34px; fill: var(--gold); }
.brand span { font: 700 22px/1 var(--title); letter-spacing: .14em; }
.bar nav { display: flex; gap: 22px; }
.bar nav a, .lang {
  color: var(--ink-soft); text-decoration: none; font: 500 13px/1 var(--title);
  letter-spacing: .2em; text-transform: uppercase;
}
.bar nav a:hover, .lang:hover { color: var(--gold-hi); }
.lang { border: 1px solid var(--rule); padding: 6px 8px; }
@media (max-width: 980px) { .bar nav { display: none; } }
@media (max-width: 420px) { .bar .btn-small { display: none; } }

/* Hero: the map out of the darkness, fire light and embers */
.hero {
  position: relative; min-height: 100svh; display: grid; place-items: center;
  overflow: hidden; isolation: isolate; text-align: center; padding: 96px var(--gutter) 88px;
}
.hero-map {
  position: absolute; inset: -6%; z-index: -3;
  background: url(map.webp) center/cover no-repeat;
  filter: sepia(.6) saturate(1.3) brightness(.3) contrast(1.2);
  animation: drift 40s ease-in-out infinite alternate;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(42% 38% at 50% 50%, rgba(8, 5, 3, .55), transparent 100%),
    radial-gradient(60% 55% at 50% 62%, rgba(208, 102, 44, .24), transparent 70%),
    radial-gradient(120% 90% at 50% 50%, transparent 35%, rgba(5, 3, 2, .92) 100%),
    linear-gradient(180deg, rgba(12, 9, 7, .7) 0%, transparent 25%, transparent 70%, var(--night) 100%);
  animation: flicker 5s ease-in-out infinite;
}
.embers { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; pointer-events: none; }
.hero-in { max-width: 1060px; }
.title { text-wrap: balance;
  font-family: var(--title); font-weight: 700; text-transform: uppercase; letter-spacing: .07em;
  font-size: clamp(40px, 7.4vw, 104px); line-height: .98; margin: .1em 0 .25em;
  color: #f8e7bd;
  background: linear-gradient(180deg, #fff1c9 10%, #e9bd62 55%, #a8741f 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 22px rgba(236, 170, 80, .35)) drop-shadow(0 3px 2px rgba(0, 0, 0, .8));
}
.tagline { font-style: italic; font-size: clamp(18px, 1.8vw, 24px); color: #e6d4b0; letter-spacing: .03em; }
.lead { max-width: 640px; margin: 1.2em auto 2em; color: var(--ink-soft); }
.rise { opacity: 0; transform: translateY(18px); animation: rise 1.4s cubic-bezier(.2, .7, .2, 1) forwards; }
.rise:nth-child(2) { animation-delay: .35s; } .rise:nth-child(3) { animation-delay: .9s; }
.rise:nth-child(4) { animation-delay: 1.2s; } .rise:nth-child(5) { animation-delay: 1.5s; }
.scroll-cue { position: absolute; bottom: 26px; left: 50%; translate: -50% 0; width: 26px; height: 42px; border: 1px solid var(--rule); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 9px; width: 3px; height: 8px; translate: -50% 0; background: var(--gold); border-radius: 2px; animation: cue 2.2s infinite; }

@keyframes drift { from { transform: scale(1) translate(0, 0); } to { transform: scale(1.12) translate(-2%, 1.5%); } }
@keyframes flicker { 0%, 100% { opacity: 1; } 45% { opacity: .86; } 60% { opacity: .97; } 75% { opacity: .9; } }
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* Sections */
section { position: relative; }
.prologue { padding: clamp(80px, 12vw, 160px) 0 clamp(40px, 6vw, 80px); text-align: center; }
.prologue .sub { margin-top: .6em; }
.prologue .line { margin: 1.4em 0; }
.prologue .body { max-width: 700px; margin: 0 auto; }

.trailer { padding: clamp(40px, 6vw, 80px) 0 clamp(80px, 10vw, 140px); }
.heading-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.heading-row .sub { margin: 0; }
.screen {
  position: relative; aspect-ratio: 16 / 9; background: #000;
  border: 1px solid var(--rule); box-shadow: 0 30px 90px rgba(0, 0, 0, .7), 0 0 0 6px rgba(217, 173, 85, .05);
}
.screen::before, .screen::after {
  content: ""; position: absolute; width: 38px; height: 38px; border: 2px solid var(--gold); pointer-events: none; z-index: 2;
}
.screen::before { top: -9px; left: -9px; border-right: 0; border-bottom: 0; }
.screen::after { bottom: -9px; right: -9px; border-left: 0; border-top: 0; }
.screen video { width: 100%; height: 100%; object-fit: cover; }
.play {
  position: absolute; inset: 0; margin: auto; width: clamp(72px, 9vw, 112px); height: clamp(72px, 9vw, 112px);
  border: 0; background: none; cursor: pointer; padding: 0; transition: transform .25s;
}
.play svg circle { fill: rgba(12, 9, 7, .55); stroke: var(--gold); stroke-width: 2; }
.play svg path { fill: var(--gold-hi); }
.play:hover { transform: scale(1.08); }
.screen.playing .play { display: none; }

/* Houses: red against blue */
.houses { padding: clamp(80px, 10vw, 140px) 0; background: linear-gradient(180deg, var(--night), var(--night-2) 30%, var(--night-2) 70%, var(--night)); }
.duel {
  display: grid; grid-template-columns: 1fr auto 1fr; gap: 0; align-items: stretch;
  width: min(1320px, 100%); margin: 48px auto 0; padding: 0 var(--gutter);
}
.house { position: relative; overflow: hidden; border: 1px solid var(--rule); background: var(--night-3); display: flex; flex-direction: column; }
.house-art { position: relative; aspect-ratio: 3 / 2; overflow: hidden; }
.house-art img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s ease, filter 1.4s ease; }
.house.lux .house-art img { filter: sepia(.35) saturate(1.2) brightness(.62) contrast(1.1) hue-rotate(-8deg); }
.house.witt .house-art img { filter: grayscale(.45) brightness(.66) contrast(1.12) sepia(.1) hue-rotate(170deg) saturate(.6); }
.house:hover .house-art img { transform: scale(1.04); filter: none; }
.house-art::after { content: ""; position: absolute; inset: 0; }
.house.lux .house-art::after { background: linear-gradient(180deg, transparent 40%, var(--night-3)), linear-gradient(135deg, rgba(195, 53, 47, .35), transparent 60%); }
.house.witt .house-art::after { background: linear-gradient(180deg, transparent 40%, var(--night-3)), linear-gradient(225deg, rgba(91, 149, 214, .35), transparent 60%); }
.house-text { position: relative; padding: 0 clamp(20px, 3vw, 40px) clamp(24px, 3vw, 40px); margin-top: -64px; }
.shield { width: 74px; height: auto; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .7)); margin-bottom: 14px; }
.house h3 { font-family: var(--title); text-transform: uppercase; letter-spacing: .1em; font-size: clamp(24px, 2.4vw, 34px); line-height: 1.1; }
.house .sub { margin: .4em 0 1em; }
.house .style { margin: 1.2em 0 0; padding-top: 1em; border-top: 1px solid var(--rule); font-style: italic; color: var(--ink-soft); }
.house.lux { border-top: 3px solid var(--lux); }
.house.lux h3 { color: #f4c9b8; }
.house.witt { border-top: 3px solid var(--witt); }
.house.witt h3 { color: #cfe0f5; }
.versus { display: grid; place-items: center; width: clamp(56px, 7vw, 100px); }
.versus span {
  font: italic 400 clamp(18px, 1.6vw, 24px)/1 var(--serif); color: var(--gold);
  writing-mode: vertical-rl; letter-spacing: .3em; text-transform: lowercase;
}
@media (max-width: 860px) {
  .duel { grid-template-columns: 1fr; }
  .versus { width: auto; padding: 18px 0; }
  .versus span { writing-mode: horizontal-tb; }
}

/* Cast: four words, two cards each */
.cast { padding: clamp(80px, 10vw, 140px) 0; }
.cast-group { margin-top: clamp(48px, 7vw, 90px); }
.word {
  font-family: var(--title); font-weight: 700; text-transform: uppercase; letter-spacing: .28em;
  font-size: clamp(28px, 5vw, 64px); text-align: center; color: transparent;
  -webkit-text-stroke: 1px rgba(217, 173, 85, .75);
  margin-bottom: 26px; line-height: 1;
}
.cast-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(16px, 3vw, 36px); }
.card { margin: 0; background: var(--night-2); border: 1px solid var(--rule); display: flex; flex-direction: column; }
.card-art { aspect-ratio: 640 / 438; overflow: hidden; position: relative; }
.card-art img { width: 100%; height: 100%; object-fit: cover; filter: sepia(.4) saturate(1.1) brightness(.6) contrast(1.1); transition: filter .9s ease, transform 1.2s ease; }
.card:hover .card-art img, .card:focus-within .card-art img { filter: none; transform: scale(1.03); }
.card-art::after { content: ""; position: absolute; inset: 0; box-shadow: inset 0 0 60px rgba(0, 0, 0, .65); pointer-events: none; }
.card figcaption { padding: 18px 22px 22px; }
.card h4 { font-family: var(--title); font-size: 1.35em; letter-spacing: .06em; color: #f3e3c2; }
.card-sub { font-style: italic; color: var(--gold); margin: .1em 0 .7em; font-size: .95em; }
.card p:last-child { margin: 0; color: var(--ink-soft); }
@media (max-width: 640px) { .cast-cards { grid-template-columns: 1fr; } }

/* Electors */
.electors { padding: clamp(80px, 10vw, 140px) 0; background: radial-gradient(70% 60% at 20% 30%, rgba(40, 60, 110, .2), transparent 70%), var(--night-2); }
.electors-head { display: grid; grid-template-columns: minmax(160px, 300px) 1fr; gap: clamp(28px, 5vw, 70px); align-items: center; }
.card-back { width: 100%; border-radius: 10px; box-shadow: 0 25px 70px rgba(0, 0, 0, .7), 0 0 50px rgba(217, 173, 85, .12); transform: rotate(-4deg); }
.electors-head .line { margin: .6em 0 .8em; }
.electors-head .line strong { font-family: var(--title); font-style: normal; letter-spacing: .1em; color: var(--gold-hi); text-transform: uppercase; }
@media (max-width: 720px) { .electors-head { grid-template-columns: 1fr; } .card-back { width: 58%; margin: 0 auto; } }
.elector-grid { list-style: none; padding: 0; margin: clamp(48px, 6vw, 80px) 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 26px 16px; }
.elector { text-align: center; flex: 0 1 calc((100% - 6 * 16px) / 7); min-width: 140px; }
@media (max-width: 640px) { .elector { flex-basis: calc((100% - 16px) / 2); min-width: 0; } }
.elector-art {
  aspect-ratio: 3 / 4; overflow: hidden; border-radius: 999px 999px 6px 6px; border: 1px solid var(--rule);
  margin-bottom: 12px; position: relative;
}
.elector-art img { width: 100%; height: 100%; object-fit: cover; filter: sepia(.35) brightness(.7) contrast(1.08); transition: filter .6s; }
.elector:hover .elector-art img { filter: none; }
.elector.voted .elector-art { border-color: rgba(195, 53, 47, .8); box-shadow: 0 0 0 3px rgba(195, 53, 47, .18); }
.elector.absent .elector-art img { filter: grayscale(.7) brightness(.5); }
.elector h3 { font-family: var(--title); text-transform: uppercase; letter-spacing: .12em; font-size: 1.1em; color: #f3e3c2; }
.elector-title { font-style: italic; color: var(--ink-soft); font-size: .88em; margin: .15em 0 .3em; line-height: 1.3; }
.elector-who { font-size: .88em; color: var(--ink); margin: 0 0 .4em; line-height: 1.3; }
.elector-vote { font-size: .78em; margin: 0; letter-spacing: .02em; line-height: 1.3; }
.elector-vote span { color: var(--ink-mute); }
.elector.voted .elector-vote { color: #f09a8a; }
.elector.absent .elector-vote { color: var(--ink-mute); }

/* How it plays */
.how { padding: clamp(80px, 10vw, 140px) 0; }
.facts { list-style: none; padding: 0; margin: 40px 0 56px; display: grid; grid-template-columns: repeat(4, 1fr); border-block: 1px solid var(--rule); }
.facts li { text-align: center; padding: 22px 8px; }
.facts li + li { border-left: 1px solid var(--rule); }
.facts b { display: block; font: 700 clamp(40px, 5vw, 64px)/1 var(--title); color: var(--gold); }
.facts span { font-style: italic; color: var(--ink-soft); font-size: .92em; }
@media (max-width: 620px) { .facts { grid-template-columns: repeat(2, 1fr); } .facts li:nth-child(3) { border-left: 0; } .facts li:nth-child(n+3) { border-top: 1px solid var(--rule); } }
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; }
.pillars article { padding: 26px 24px; background: linear-gradient(180deg, var(--night-3), var(--night-2)); border: 1px solid var(--rule); }
.pillars svg { width: 44px; height: 44px; fill: none; stroke: var(--gold); stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; margin-bottom: 14px; }
.pillars h3 { font-family: var(--title); letter-spacing: .08em; font-size: 1.35em; color: #f3e3c2; margin-bottom: .4em; }
.pillars p { color: var(--ink-soft); margin: 0; font-size: .95em; }
.howto-screen { margin: 28px 0 8px; }
.board { margin: 64px 0 0; }
.board img { width: 100%; border: 1px solid var(--rule); box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }
.board figcaption { text-align: center; font-style: italic; color: var(--ink-mute); margin-top: 12px; font-size: .92em; }

/* History */
.history { padding: clamp(80px, 10vw, 140px) 0; background: linear-gradient(180deg, var(--night), var(--night-2)); }
.timeline { list-style: none; margin: 56px 0 0; padding: 0 0 0 clamp(96px, 16vw, 168px); position: relative; }
.timeline::before { content: ""; position: absolute; left: calc(clamp(96px, 16vw, 168px) - 22px); top: 8px; bottom: 8px; width: 1px; background: linear-gradient(180deg, transparent, var(--gold-deep) 6%, var(--gold-deep) 94%, transparent); }
.timeline li { position: relative; padding-bottom: 30px; }
.timeline li::before { content: ""; position: absolute; left: -27px; top: .55em; width: 11px; height: 11px; transform: rotate(45deg); background: var(--night); border: 1px solid var(--gold); }
.timeline li.key::before { background: var(--lux); border-color: var(--gold-hi); box-shadow: 0 0 14px rgba(195, 53, 47, .7); }
.timeline .year { position: absolute; right: calc(100% + 44px); top: .1em; width: clamp(70px, 13vw, 130px); text-align: right; font: 700 1.25em/1.1 var(--title); color: var(--gold); letter-spacing: .04em; }
.timeline li.key .year { font-size: 1em; color: var(--gold-hi); }
.timeline h3 { font-family: var(--title); letter-spacing: .08em; font-size: 1.25em; color: #f3e3c2; text-transform: uppercase; }
.timeline p { color: var(--ink-soft); margin: .2em 0 0; }
.whatif { margin: 36px 0 0; padding: 28px 30px; border: 1px solid var(--rule); border-left: 3px solid var(--gold); background: rgba(217, 173, 85, .05); }
.whatif p { margin: 0; font-style: italic; font-size: 1.1em; color: #ead9b6; }

/* Finale: the question in golden light */
.finale {
  padding: clamp(90px, 12vw, 170px) 0; overflow: hidden; isolation: isolate;
  background:
    radial-gradient(55% 70% at 32% 50%, rgba(233, 182, 85, .32), transparent 70%),
    radial-gradient(80% 90% at 50% 50%, #2a1d0c, var(--night) 85%);
}
.dust { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.finale-in { display: grid; grid-template-columns: minmax(220px, 420px) 1fr; gap: clamp(32px, 6vw, 90px); align-items: center; }
.box { width: 100%; border-radius: 4px; box-shadow: 0 40px 100px rgba(0, 0, 0, .75), 0 0 80px rgba(240, 190, 100, .25); transform: perspective(1200px) rotateY(10deg); transition: transform 1s ease; }
.box:hover { transform: perspective(1200px) rotateY(2deg); }
.question { text-wrap: balance; font-style: italic; font-size: clamp(28px, 3.4vw, 46px); line-height: 1.25; color: #fbe7ba; text-shadow: 0 0 30px rgba(240, 190, 100, .3); }
.soon { font: 700 clamp(22px, 2.4vw, 32px)/1 var(--title); letter-spacing: .45em; color: var(--gold); margin: 1.2em 0 1.1em; }
.finale .body { max-width: 560px; }
.finale .ctas { justify-content: flex-start; margin-top: 1.6em; }
@media (max-width: 820px) {
  .finale-in { grid-template-columns: 1fr; text-align: center; }
  .box { width: min(340px, 78%); margin: 0 auto; transform: none; }
  .finale .body { margin: 0 auto 1em; }
  .finale .ctas { justify-content: center; }
}

/* Footer */
.foot { padding: 56px 0 64px; border-top: 1px solid var(--rule); text-align: center; color: var(--ink-mute); }
.foot-title { font: 700 22px/1.2 var(--title); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.foot .small { font-size: .85em; }
.foot a { color: var(--ink-soft); }

/* Scroll reveal (only when JS runs) */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity 1.1s ease, transform 1.1s cubic-bezier(.2, .7, .2, 1); }
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-map, .hero::before, .scroll-cue span { animation: none; }
  .rise { animation: none; opacity: 1; transform: none; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
