/* =========================================================
   Shaiya Maharlika Mobile – public website
   Direction: "The Storm Gate". A rain-swept frontier at night, forged
   dark metal and antique gold, one giant molten-gold countdown that the
   heroes stand in front of.
   ========================================================= */

@font-face { font-family: "Grenze Gotisch"; src: url("../assets/fonts/grenze-gotisch-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Grenze Gotisch"; src: url("../assets/fonts/grenze-gotisch-vietnamese-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "Grenze Gotisch"; src: url("../assets/fonts/grenze-gotisch-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Grenze Gotisch"; src: url("../assets/fonts/grenze-gotisch-vietnamese-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "Grenze"; src: url("../assets/fonts/grenze-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Grenze"; src: url("../assets/fonts/grenze-vietnamese-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "Grenze"; src: url("../assets/fonts/grenze-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Grenze"; src: url("../assets/fonts/grenze-vietnamese-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
/* Alegreya Sans 500 and 700 (bold words below the first screen) load later: see css/fonts-later.css */
@font-face { font-family: "Alegreya Sans"; src: url("../assets/fonts/alegreya-sans-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Alegreya Sans"; src: url("../assets/fonts/alegreya-sans-vietnamese-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }

:root {
  --causeway: #0b0e13;   /* page */
  --slate: #151a21;      /* raised surfaces */
  --stone: #232a33;
  --silver: #c9ced6;     /* body text */
  --silver-dim: #8f97a3;
  --parchment: #ece4d0;  /* bright text */
  --gold: #b8913f;       /* frames */
  --ember: #ffd27a;      /* glow */
  --lapis: #6cc4ff;      /* Light */
  --garnet: #d0465a;     /* Fury */

  --f-display: "Grenze Gotisch", "Grenze", Georgia, serif;
  --f-forge: "Grenze", Georgia, serif;
  --f-body: "Alegreya Sans", system-ui, sans-serif;

  --gutter: 16px;
  --gilt: linear-gradient(180deg, #fbe7ab 0%, #e2b85c 30%, #a8782c 55%, #7a5418 62%, #c8973f 82%, #e9c477 100%);
  --frame: inset 0 0 0 1px var(--gold), inset 0 0 0 4px #07090b, inset 0 0 0 5px rgba(184,145,63,.38);
  --ornament: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 260 22'%3E%3Cdefs%3E%3ClinearGradient id='l' x1='0' x2='1'%3E%3Cstop offset='0' stop-color='%23b8913f' stop-opacity='0'/%3E%3Cstop offset='1' stop-color='%23d9b45e'/%3E%3C/linearGradient%3E%3ClinearGradient id='r' x1='1' x2='0'%3E%3Cstop offset='0' stop-color='%23b8913f' stop-opacity='0'/%3E%3Cstop offset='1' stop-color='%23d9b45e'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M0 11h104' stroke='url(%23l)' stroke-width='1.2'/%3E%3Cpath d='M156 11h104' stroke='url(%23r)' stroke-width='1.2'/%3E%3Cg fill='none' stroke='%23d9b45e' stroke-width='1.2'%3E%3Cpath d='M104 11c5-6 10-7 15-3M156 11c-5-6-10-7-15-3M104 11c5 6 10 7 15 3M156 11c-5 6-10 7-15 3'/%3E%3C/g%3E%3Cpath d='M130 2l9 9-9 9-9-9z' fill='%23e8c56f'/%3E%3Cpath d='M130 6l5 5-5 5-5-5z' fill='%236e5320'/%3E%3C/svg%3E");
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--causeway);
  color: var(--silver);
  font: 400 1.0625rem/1.55 var(--f-body);
  overflow-x: hidden;
}
/* Film grain over everything: makes flat darks feel like a printed poster, not a web page */
body::after {
  content: ""; position: fixed; inset: 0; z-index: 90; pointer-events: none; opacity: .06;
  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='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--ember); }
:focus-visible { outline: 2px solid var(--ember); outline-offset: 3px; }
.visually-hidden { font-weight: 400; position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: var(--gutter); top: 8px; z-index: 100; background: var(--slate); padding: .5em 1em; }

/* Phone vs PC (the game is phones only). js/main.js adds "is-pc" on desktop computers. */
html:not(.is-pc) .only-pc { display: none !important; }
html.is-pc .only-phone { display: none !important; }

/* =========================================================
   Forged buttons: notched corners like the classic game windows
   ========================================================= */
.btn {
  --cut: 10px;
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  min-height: 48px; padding: .55em 1.5em;
  font: 800 1.15rem/1 var(--f-forge); letter-spacing: .03em;
  text-decoration: none; text-align: center; white-space: nowrap;
  border: 0; cursor: pointer;
  clip-path: polygon(var(--cut) 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, var(--cut) 100%, 0 calc(100% - var(--cut)), 0 var(--cut));
  transition: filter .2s ease, transform .15s ease;
}
.btn::after { /* a sheen that sweeps across on hover */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.55) 50%, transparent 65%);
  transform: translateX(-120%); transition: transform .7s cubic-bezier(.2,.8,.2,1);
}
.btn:hover::after { transform: translateX(120%); }
.btn:active { transform: translateY(1px); }
.btn svg { width: 1.2em; height: 1.2em; fill: currentColor; }

.btn--gold {
  color: #2a1804;
  background: linear-gradient(180deg, rgba(255,255,255,.35), rgba(255,255,255,0) 40%), var(--gilt);
  text-shadow: 0 1px 0 rgba(255,236,190,.55);
  box-shadow: inset 0 0 0 1px rgba(255,240,200,.6), inset 0 0 0 3px rgba(70,44,8,.55), inset 0 -10px 18px rgba(90,55,10,.35);
}
.btn--gold:hover { filter: brightness(1.1) saturate(1.1); }
.btn--steel {
  color: var(--ember);
  background: linear-gradient(180deg, #3a434f, #1c2229 52%, #11151a);
  box-shadow: var(--frame);
}
.btn--steel:hover { filter: brightness(1.25); }
.btn--sm { min-height: 44px; padding: .4em 1em; font-size: 1rem; --cut: 7px; }
.btn--lg { min-height: 58px; padding: .6em 2.1em; font-size: 1.35rem; --cut: 13px; }
.btn--lg-alt { min-height: 54px; padding: .6em 1.6em; font-size: 1.2rem; --cut: 12px; }
.btn--xl { min-height: 72px; padding: .7em 2.4em; font-size: clamp(1.4rem, 4.6vw, 1.9rem); --cut: 16px; }
.btn--block { width: 100%; }
.btn--lg, .btn--xl { filter: drop-shadow(0 0 18px rgba(255,190,80,.32)); }
.btn--lg:hover, .btn--xl:hover { filter: drop-shadow(0 0 28px rgba(255,200,90,.6)) brightness(1.08); }

/* =========================================================
   Top bar: transparent over the hero, forged metal once you scroll
   ========================================================= */
.topbar {
  position: fixed; inset: 0 0 auto; z-index: 40;
  height: calc(58px + env(safe-area-inset-top));
  display: flex; align-items: center; gap: 1rem;
  padding: env(safe-area-inset-top) var(--gutter) 0;
  background: linear-gradient(180deg, rgba(6,8,11,.85), rgba(6,8,11,0));
  transition: background .35s ease, box-shadow .35s ease, height .35s ease;
}
.topbar.is-solid {
  background: linear-gradient(180deg, rgba(30,36,44,.96), rgba(13,16,21,.96));
  box-shadow: 0 1px 0 var(--gold), 0 10px 30px rgba(0,0,0,.55);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.topbar__crest { align-self: flex-start; width: 112px; margin-top: calc(4px + env(safe-area-inset-top)); filter: drop-shadow(0 8px 14px rgba(0,0,0,.8)); transition: width .35s ease, margin .35s ease; }
.topbar__crest img { width: 100%; height: auto; }
.topbar.is-solid .topbar__crest { width: 78px; margin-top: calc(2px + env(safe-area-inset-top)); }
.topbar__nav { display: none; gap: 1.2rem; margin-left: auto; }
.topbar__nav a {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; color: var(--parchment); text-decoration: none;
  font: 800 1.12rem/1 var(--f-forge); letter-spacing: .04em; padding: .5em .7em;
  text-shadow: 0 1px 6px #000;
}
.topbar__nav a::after { content: ""; position: absolute; left: 50%; bottom: -2px; width: 0; height: 1px; background: var(--gold); transform: translateX(-50%); transition: width .3s ease; }
.topbar__nav a:hover { color: var(--ember); }
.topbar__nav a:hover::after { width: 100%; }
.topbar__play { margin-left: auto; }

/* =========================================================
   HERO
   ========================================================= */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  height: 100svh; min-height: 640px;
  container-type: size;
  background: #05070a;
}
.layer { position: absolute; inset: 0; will-change: transform; }
.layer--scene { z-index: 0; inset: -3%; }
.layer--scene picture, .layer--scene img { display: block; width: 100%; height: 100%; }
.layer--scene img { object-fit: cover; object-position: 50% 38%; }
.layer--scene::after { /* grade: cool shadows, dark top for the bar, dark floor for the buttons, vignette */
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 70% at 50% 45%, transparent 40%, rgba(3,4,7,.75) 100%),
    linear-gradient(180deg, rgba(5,7,10,.6) 0%, rgba(5,7,10,.1) 20%, rgba(5,7,10,.15) 55%, rgba(5,7,10,.85) 100%),
    rgba(10,16,28,.22);
}
.hero__lightning {
  position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0;
  background: radial-gradient(ellipse 70% 55% at var(--lx, 45%) 10%, rgba(214,232,255,.55), rgba(150,180,230,.12) 50%, transparent 75%);
  mix-blend-mode: screen;
}
.hero.is-flash .hero__lightning { animation: strike .9s ease-out 1; }
@keyframes strike { 0%{opacity:0} 6%{opacity:1} 12%{opacity:.2} 18%{opacity:.85} 40%{opacity:.1} 100%{opacity:0} }

/* The eagle: circles above the goddess, behind the numbers */
.eagle { position: absolute; z-index: 2; top: 0; left: 0; width: 24vw; pointer-events: none; will-change: transform; opacity: 0; transition: opacity 2.5s ease; }
.eagle.is-flying { opacity: 1; }
.eagle__svg { display: block; width: 100%; height: auto; overflow: visible; filter: drop-shadow(0 6px 10px rgba(0,0,0,.45)); transition: filter .3s ease; }
.eagle .wing { transform-box: view-box; }
.eagle .wing--r { transform-origin: 207px 66px; }
.eagle .wing--l { transform-origin: 193px 66px; }
.eagle.is-flapping .wing--r { animation: flapR 1.05s cubic-bezier(.45,0,.55,1) 2; }
.eagle.is-flapping .wing--l { animation: flapL 1.05s cubic-bezier(.45,0,.55,1) 2; }
@keyframes flapR { 0%,100% { transform: rotate(0) scaleY(1); } 35% { transform: rotate(-20deg) scaleY(.9); } 70% { transform: rotate(14deg) scaleY(.82); } }
@keyframes flapL { 0%,100% { transform: rotate(0) scaleY(1); } 35% { transform: rotate(20deg) scaleY(.9); } 70% { transform: rotate(-14deg) scaleY(.82); } }
.hero.is-flash .eagle__svg { filter: drop-shadow(0 0 6px rgba(220,235,255,.9)) brightness(1.5); }

/* The giant countdown */
.layer--clock { z-index: 3; pointer-events: none; }
.clock {
  position: absolute; left: 0; right: 0; top: calc(96px + env(safe-area-inset-top));
  display: grid; grid-template-columns: repeat(2, auto); justify-content: center;
  column-gap: 7vw; row-gap: 12px;
}
.clock[hidden] { display: none; }
.clock__group { display: grid; justify-items: center; }
.clock__label {
  display: flex; align-items: center; gap: .55em;
  font: 800 1.05rem/1 var(--f-forge); text-transform: uppercase; letter-spacing: .18em;
  color: var(--parchment); text-shadow: 0 2px 10px #000, 0 0 2px #000;
  height: 18px; padding-left: .18em;
}
.clock__label::before, .clock__label::after { content: ""; width: 5px; height: 5px; background: var(--gold); transform: rotate(45deg); box-shadow: 0 0 6px rgba(255,190,80,.7); }
.clock__num { display: flex; font: 800 30vw/.86 var(--f-forge); }
.clock__digit, .clock-live span {
  /* molten gold with a slow light sweep */
  background:
    linear-gradient(100deg, transparent 42%, rgba(255,255,255,.85) 50%, transparent 58%) 160% 0 / 260% 100% no-repeat,
    linear-gradient(180deg, #fffbea 0%, #ffe8a8 26%, #ffcf6b 48%, #d48f25 70%, #9a5e12 84%, #e6a94a 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-text-stroke: 1px rgba(255,230,170,.25);
  filter: drop-shadow(0 0 12px rgba(255,170,50,.55)) drop-shadow(0 0 46px rgba(255,130,20,.35)) drop-shadow(0 6px 3px rgba(0,0,0,.55));
  animation: sheen 9s ease-in-out infinite;
}
.clock__group:nth-child(2) .clock__digit { animation-delay: .25s; }
.clock__group:nth-child(3) .clock__digit { animation-delay: .5s; }
.clock__group:nth-child(4) .clock__digit { animation-delay: .75s; }
@keyframes sheen { 0%, 70% { background-position: 160% 0, 0 0; } 100% { background-position: -60% 0, 0 0; } }
.clock__digit { display: inline-block; width: .56em; text-align: center; }
.clock__digit.is-tick { animation: tick .7s cubic-bezier(.2,.8,.2,1), sheen 9s ease-in-out infinite; }
@keyframes tick { 0% { transform: translateY(-4%); filter: brightness(1.7) drop-shadow(0 0 18px rgba(255,200,90,.9)); } 100% { transform: none; } }

.clock-live {
  position: absolute; left: 0; right: 0; top: calc(110px + env(safe-area-inset-top)); margin: 0;
  display: grid; justify-items: center; text-align: center;
  font: 800 19vw/.92 var(--f-forge); text-transform: uppercase; letter-spacing: .01em;
}
.clock-live[hidden] { display: none; }
/* Room above the letters so accents on capitals (Á, Ă, Ắ, Ế …) are painted gold too, not cut off.
   The padding is taken back with a negative margin, so the layout does not move. */
.clock-live span { padding-top: .32em; margin-top: -.32em; background-origin: content-box, content-box; background-repeat: no-repeat, repeat-y; }

/* The heroes, in front of the numbers */
.layer--cast { z-index: 4; pointer-events: none; }
.cast { position: absolute; height: auto; filter: drop-shadow(0 0 22px rgba(0,0,0,.6)); }
.cast--mage { left: -22vw; width: 72vw; top: calc(140px + 51.6vw - 40px + env(safe-area-inset-top)); }
.cast--warrior { right: -30vw; width: 80vw; top: calc(140px + 51.6vw - 18px + env(safe-area-inset-top)); }

.hero__rain { position: absolute; inset: 0; z-index: 5; width: 100%; height: 100%; pointer-events: none; opacity: .6; }
.hero__mist {
  position: absolute; left: 0; right: 0; bottom: 0; height: 42%; z-index: 6; pointer-events: none;
  background: linear-gradient(180deg, rgba(8,10,14,0), rgba(8,10,14,.7) 45%, rgba(8,10,14,.97) 85%, var(--causeway));
}

/* Bottom: counter, buttons, date */
.hero__foot {
  position: absolute; z-index: 7; left: 0; right: 0; bottom: 0;
  display: grid; justify-items: center; gap: .7rem;
  padding: 0 var(--gutter) calc(18px + env(safe-area-inset-bottom));
  text-align: center;
}
.hero__actions { display: grid; gap: .6rem; width: min(100%, 380px); }
.hero__actions .btn { width: 100%; }
.hero__when { margin: 0; display: grid; gap: .05rem; font-size: .9rem; color: var(--silver); text-shadow: 0 1px 3px #000; }
.hero__local { color: var(--ember); }

.tally { display: grid; justify-items: center; gap: .35rem; width: min(100%, 420px); }
.tally[hidden] { display: none; }
.tally__line { margin: 0; font: 600 1.05rem/1.25 var(--f-forge); color: var(--parchment); text-shadow: 0 1px 3px #000; }
.tally__num { font-weight: 800; font-size: 1.6em; color: var(--ember); vertical-align: -.08em; margin-right: .12em; text-shadow: 0 0 16px rgba(255,170,60,.45); }
.tally__bar { position: relative; width: 100%; height: 6px; background: rgba(20,24,30,.9); box-shadow: 0 0 0 1px rgba(184,145,63,.7), 0 0 0 3px rgba(5,6,8,.8); }
.tally__bar span { position: relative; display: block; height: 100%; width: var(--p, 0%); background: linear-gradient(90deg, #8a6526, var(--gold), #f6dc98); box-shadow: 0 0 10px rgba(255,190,80,.6); transition: width 1.6s cubic-bezier(.2,.8,.2,1) .8s; }
.tally__bar span::after { content: ""; position: absolute; right: -5px; top: 50%; width: 10px; height: 10px; margin-top: -5px; background: #fff1c4; transform: rotate(45deg); box-shadow: 0 0 10px #ffd27a; }
.tally__next { margin: 0; font-size: .875rem; color: var(--silver); }
.tally__sample { display: inline-block; margin-left: .4em; font-size: .875rem; color: #f1c6a0; border: 1px dashed rgba(240,170,110,.5); padding: 0 .45em; background: rgba(60,25,10,.45); }

/* ---------- Opening sequence (once, on load) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .layer--scene img { animation: sceneIn 2s cubic-bezier(.2,.7,.2,1) both; }
  .clock__group { animation: ignite 1.3s cubic-bezier(.2,.8,.2,1) both; }
  .clock__group:nth-child(1) { animation-delay: .3s; }
  .clock__group:nth-child(2) { animation-delay: .42s; }
  .clock__group:nth-child(3) { animation-delay: .54s; }
  .clock__group:nth-child(4) { animation-delay: .66s; }
  .cast--mage { animation: fromLeft 1.6s cubic-bezier(.2,.8,.2,1) .9s both; }
  .cast--warrior { animation: fromRight 1.6s cubic-bezier(.2,.8,.2,1) .9s both; }
  .hero__foot { animation: rise 1s cubic-bezier(.2,.8,.2,1) 1s both; }
  .topbar__crest { animation: rise 1s cubic-bezier(.2,.8,.2,1) .3s both; }
}
@keyframes sceneIn { from { opacity: 0; transform: scale(1.1); } to { opacity: 1; transform: none; } }
@keyframes ignite { 0% { opacity: 0; filter: blur(14px) brightness(2.4); transform: scale(1.06); } 60% { opacity: 1; } 100% { opacity: 1; filter: none; transform: none; } }
@keyframes fromLeft { from { opacity: 0; transform: translateX(-6%); } to { opacity: 1; transform: none; } }
@keyframes fromRight { from { opacity: 0; transform: translateX(6%); } to { opacity: 1; transform: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Short phones: dock and top bar already offer Play, so the hero keeps one button */
@media (max-aspect-ratio: 1/1) and (max-height: 760px) {
  .hero__actions .btn--lg-alt { display: none !important; }
}

/* ---------- Wide screens (landscape phones, tablets in landscape, PC) ---------- */
@media (min-aspect-ratio: 1/1) {
  .clock { grid-template-columns: repeat(4, auto); top: 19cqh; column-gap: 3.4vw; }
  .clock__label { font-size: clamp(.85rem, 1.7vw, 2rem); height: auto; margin-bottom: .2em; }
  .clock__num { font-size: min(14.5vw, 32cqh); }
  .clock-live { top: 22cqh; font-size: min(12vw, 26cqh); }
  .clock-soon { grid-auto-flow: column; justify-content: center; column-gap: .28em; top: 30cqh; font-size: min(10.5vw, 24cqh); }
  .eagle { width: 8vw; }
  .cast { top: auto; bottom: 0; height: 84cqh; width: auto; }
  .cast--mage { left: -6vw; }
  .cast--warrior { right: -9vw; }
  .hero__mist { height: 34%; }
}

/* =========================================================
   SECTIONS
   ========================================================= */
.section { position: relative; padding: 64px var(--gutter); }
.section-title { margin: 0 0 .4rem; font: 800 clamp(2.2rem, 7.5vw, 3.8rem)/1.02 var(--f-display); color: var(--ember); text-shadow: 0 2px 0 #000, 0 0 30px rgba(255,170,60,.2); }
.section-title--center { text-align: center; }
.section-title--center::after { content: ""; display: block; width: 260px; max-width: 80%; height: 22px; margin: .5rem auto 0; background: var(--ornament) center / contain no-repeat; }
.section-lead { margin: 0 auto 2rem; max-width: 34rem; text-align: center; color: var(--silver); font-size: 1.1rem; }
.sample-note { display: inline-block; margin: 1rem 0 0; padding: .3em .8em; font-size: .875rem; color: #f1c6a0; background: rgba(160,70,30,.16); border: 1px dashed rgba(240,170,110,.5); }
.sample-note--center { display: table; margin-inline: auto; }

/* ---------- Muster: register panel + rewards ---------- */
.section--muster { padding-inline: 0; background: var(--causeway); overflow: hidden; }
.section--muster::before { /* ambient storm light behind the panel */
  content: ""; position: absolute; inset: 0; z-index: 0; opacity: .9;
  background:
    radial-gradient(ellipse 50% 60% at 70% 50%, rgba(255,190,90,.08), transparent 70%),
    linear-gradient(180deg, var(--causeway), rgba(11,14,19,.4) 30%, rgba(11,14,19,.4) 70%, var(--causeway)),
    url("../assets/img/ambient.webp") center / cover no-repeat;
}
.muster { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1fr); gap: 52px; max-width: 1180px; margin: 0 auto; }

.panel {
  /* frame art in three slices so the corners never stretch */
  aspect-ratio: 1086 / 1300;
  background:
    url("../assets/img/panel-top.webp") top center / 100% auto no-repeat,
    url("../assets/img/panel-bottom.webp") bottom center / 100% auto no-repeat,
    url("../assets/img/panel-mid.webp") center / 100% auto repeat-y;
  padding: 15% 12.5% 12%;
  width: 100%; max-width: 560px; margin-inline: auto;
  scroll-margin-top: 70px;
  filter: drop-shadow(0 30px 60px rgba(0,0,0,.7));
}
.panel__title { margin: 0; text-align: center; font: 800 clamp(2.1rem, 8vw, 2.8rem)/1 var(--f-display); color: var(--ember); text-shadow: 0 0 20px rgba(255,170,60,.25); }
.panel__lead { margin: .4rem 0 1.1rem; text-align: center; font-size: .95rem; color: var(--silver); line-height: 1.4; }

.form { display: grid; gap: .8rem; }
.field { display: grid; gap: .25rem; min-width: 0; }
.field label { font: 600 1rem/1.1 var(--f-forge); color: #e7dcc2; letter-spacing: .02em; }
.field label em { font: 400 .875rem var(--f-body); color: var(--silver-dim); font-style: normal; margin-left: .3em; }
.field input {
  width: 100%; min-height: 46px; padding: .5em .75em;
  font: 500 1rem var(--f-body); color: #f2efe8;
  background: linear-gradient(180deg, #050608, #111418);
  border: 1px solid #4a3c22; border-radius: 0;
  box-shadow: inset 0 2px 8px rgba(0,0,0,.85);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field input:focus { outline: none; border-color: var(--ember); box-shadow: inset 0 2px 8px rgba(0,0,0,.85), 0 0 0 1px var(--ember), 0 0 18px rgba(255,190,80,.28); }
.field small { font-size: .875rem; color: var(--silver-dim); min-height: 1em; }
.field small.is-bad { color: #ff9a8a; }
.field small.is-good { color: #9fd9a7; }
.field-row { display: grid; gap: .8rem; }
.botcheck { display: flex; align-items: center; gap: .7rem; min-height: 64px; padding: .5rem .9rem; border: 1px dashed rgba(201,206,214,.35); color: var(--silver-dim); font-size: .9rem; background: rgba(255,255,255,.02); }
.botcheck__box { width: 24px; height: 24px; border: 2px solid var(--silver-dim); flex: none; }
.form__status { margin: 0; min-height: 1.2em; font-size: .9rem; text-align: center; color: var(--ember); }

.reveal { position: relative; }
.reveal input { padding-right: 4.2rem; }
.reveal__btn { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); min-height: 44px; min-width: 44px; padding: 0 .75rem; border: 0; cursor: pointer; font: 600 .95rem var(--f-forge); color: var(--ember); background: transparent; }
.reveal__btn:hover { text-decoration: underline; }

.rewards { padding: 0 var(--gutter); max-width: 560px; margin-inline: auto; width: 100%; }
.rewards__count { margin: .5rem 0 .2rem; font: 600 1.15rem/1.2 var(--f-forge); color: var(--parchment); }
.rewards__num {
  display: block; width: fit-content; font: 800 clamp(3.6rem, 16vw, 6rem)/1 var(--f-forge);
  background: linear-gradient(180deg, #fffbea, #ffcf6b 50%, #c98522); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 20px rgba(255,170,60,.35));
}
.rewards__lead { margin: .6rem 0 1.6rem; max-width: 30rem; }

.milestones { list-style: none; margin: 0; padding: 0; display: grid; position: relative; --progress: 0%; }
.milestones::before, .milestones::after { content: ""; position: absolute; left: 13px; top: 14px; width: 3px; }
.milestones::before { bottom: 14px; background: #2b323c; }
.milestones::after { height: var(--progress); max-height: calc(100% - 28px); background: linear-gradient(180deg, #f6dc98, var(--gold)); box-shadow: 0 0 12px rgba(255,190,80,.55); }
.milestone { position: relative; display: grid; grid-template-columns: 6rem 1fr; gap: .2rem 1rem; padding: .6rem 0 .6rem 42px; align-items: baseline; }
.milestone::before { content: ""; position: absolute; left: 5px; top: 50%; width: 19px; height: 19px; margin-top: -9.5px; z-index: 1; background: #1a1f26; border: 2px solid #4a525e; transform: rotate(45deg); }
.milestone__goal { font: 800 1.4rem/1 var(--f-forge); color: var(--silver-dim); }
.milestone__reward { grid-column: 1 / -1; color: var(--silver-dim); }
.milestone.is-reached::before { background: radial-gradient(circle, #fff6d6, var(--ember) 60%, #b8791f); border-color: #fff1c4; box-shadow: 0 0 14px rgba(255,190,80,.85); }
.milestone.is-reached .milestone__goal { color: var(--ember); }
.milestone.is-reached .milestone__reward { color: var(--parchment); }
.milestone.is-next .milestone__goal { color: #e7dcc2; }
.milestone.is-next::before { border-color: var(--gold); animation: beacon 2.4s ease-in-out infinite; }
@keyframes beacon { 50% { box-shadow: 0 0 14px rgba(255,190,80,.6); } }

/* ---------- Get the game ---------- */
.section--gate { background: linear-gradient(180deg, var(--causeway), #0e1217); }
.gate { max-width: 1080px; margin: 1.8rem auto 0; display: grid; gap: 1.25rem; }
.gate__main {
  position: relative; display: grid; justify-items: center; gap: 1.1rem; text-align: center;
  padding: 2.8rem 1.25rem 2.6rem; overflow: hidden;
  background: linear-gradient(180deg, rgba(8,10,13,.45), rgba(8,10,13,.9)), url("../assets/img/plate-1100.webp") 50% 70% / cover no-repeat;
  box-shadow: var(--frame), inset 0 0 90px rgba(0,0,0,.85);
  clip-path: polygon(16px 0, calc(100% - 16px) 0, 100% 16px, 100% calc(100% - 16px), calc(100% - 16px) 100%, 16px 100%, 0 calc(100% - 16px), 0 16px);
}
.gate__lead { margin: 0; max-width: 30rem; color: #e6e9ee; text-shadow: 0 1px 4px #000; }
.gate__ways { display: grid; gap: 1.25rem; }
.way {
  position: relative; padding: 1.5rem 1.3rem 1.6rem;
  background: linear-gradient(180deg, #1a2028, #11151b);
  box-shadow: var(--frame);
  clip-path: polygon(12px 0, calc(100% - 12px) 0, 100% 12px, 100% calc(100% - 12px), calc(100% - 12px) 100%, 12px 100%, 0 calc(100% - 12px), 0 12px);
}
.way__title { display: flex; align-items: center; gap: .5rem; margin: 0 0 .3rem; font: 800 1.95rem/1 var(--f-display); color: var(--ember); }
.way__icon { width: 28px; height: 28px; fill: var(--silver); }
.way p { margin: 0 0 1rem; }
.way__note { display: block; margin-top: .5rem; color: var(--silver-dim); font-size: .875rem; text-align: center; }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: .7rem; }
.steps li { counter-increment: step; position: relative; padding-left: 2.6rem; min-height: 1.9rem; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: -.1rem; width: 1.9rem; height: 1.9rem; display: grid; place-items: center; font: 800 1.05rem/1 var(--f-forge); color: #2a1a05; background: var(--gilt); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.steps strong { color: #f2efe8; font-weight: 700; }
.steps__glyph { width: 1.25em; height: 1.25em; vertical-align: -.25em; fill: var(--lapis); margin: 0 .1em; }

.gate__main--qr { grid-template-columns: auto 1fr; justify-items: start; align-items: center; text-align: left; gap: 2.4rem; padding: 3rem; }
.qr { padding: 12px; background: var(--gilt); clip-path: polygon(10px 0, calc(100% - 10px) 0, 100% 10px, 100% calc(100% - 10px), calc(100% - 10px) 100%, 10px 100%, 0 calc(100% - 10px), 0 10px); filter: drop-shadow(0 0 24px rgba(255,190,80,.35)); }
.qr__code { display: block; width: 200px; height: 200px; }
.qr__text { max-width: 30rem; }
.qr__title { margin: 0 0 .5rem; font: 800 clamp(2rem, 3vw, 2.7rem)/1.05 var(--f-display); color: var(--ember); }
.qr__text p { margin: 0 0 .6rem; font-size: 1.15rem; color: #e6e9ee; text-shadow: 0 1px 4px #000; }
.qr__url strong { color: var(--ember); }

/* ---------- Factions ---------- */
.section--factions { background: linear-gradient(180deg, #0e1217, var(--causeway)); overflow: hidden; }
.versus { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; max-width: 1180px; margin: 0 auto; }
.faction { position: relative; display: grid; isolation: isolate; overflow: hidden; }
.faction__art { grid-area: 1 / 1; overflow: hidden; }
.faction__art img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; transition: transform 1.2s cubic-bezier(.2,.8,.2,1), filter .6s ease; }
.faction:hover .faction__art img { transform: scale(1.05); filter: brightness(1.08); }
.faction__body { grid-area: 1 / 1; align-self: end; z-index: 1; padding: 2.5rem .7rem .9rem; background: linear-gradient(180deg, transparent, rgba(10,12,16,.85) 45%, rgba(10,12,16,.96)); }
.faction--light .faction__art img { object-position: 45% 10%; }
.faction--fury .faction__art img { object-position: 55% 10%; }
.faction::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 2; box-shadow: inset 0 0 0 1px var(--edge), inset 0 -80px 80px -60px var(--edge); transition: box-shadow .5s ease; }
.faction:hover::after { box-shadow: inset 0 0 0 1px var(--edge), inset 0 -120px 110px -60px var(--edge); }
.faction--light { --edge: rgba(108,196,255,.55); }
.faction--fury { --edge: rgba(208,70,90,.55); }
.faction__name { margin: 0; font: 800 clamp(1.35rem, 5.6vw, 2.8rem)/1 var(--f-display); }
.faction--light .faction__name { color: #d6eeff; text-shadow: 0 0 20px rgba(108,196,255,.6); }
.faction--fury .faction__name { color: #ffd6d4; text-shadow: 0 0 20px rgba(208,70,90,.65); }
.faction__races { margin: .25rem 0 .4rem; font-size: .875rem; color: var(--silver-dim); }
.faction__stat { margin: 0; font-size: .9rem; }
.faction__stat[hidden], .balance[hidden], [data-live][hidden], [data-empty][hidden] { display: none; }
.faction__first { margin: 1.4rem auto 0; text-align: center; font: 600 1.3rem/1.3 var(--f-forge); color: var(--parchment); }
.faction__num { font: 800 clamp(1.4rem, 6vw, 2.6rem)/1 var(--f-forge); color: #f2efe8; margin-right: .15em; }
.versus__mark {
  position: absolute; left: 50%; top: 40%; z-index: 3; transform: translate(-50%, -50%);
  width: 70px; height: 70px; display: grid; place-items: center;
  background: radial-gradient(circle, #262d36, #0b0d10);
  box-shadow: inset 0 0 0 2px var(--gold), 0 0 0 4px var(--causeway), 0 0 30px rgba(0,0,0,.9);
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
}
.versus__mark span { font: 800 1.5rem/1 var(--f-display); color: var(--ember); margin-top: -.15em; }
.balance { max-width: 1180px; margin: 1.4rem auto 0; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .75rem; }
.balance__pct { font: 800 1.4rem/1 var(--f-forge); }
.balance__pct--light { color: var(--lapis); }
.balance__pct--fury { color: var(--garnet); }
.balance__bar { position: relative; height: 12px; background: linear-gradient(90deg, #6b1d2a, var(--garnet)); box-shadow: 0 0 0 1px var(--gold), 0 0 0 3px #07090b; }
.balance__fill { position: absolute; inset: 0 auto 0 0; width: var(--light); background: linear-gradient(90deg, #2c6fa8, var(--lapis)); }
.balance__fill::after { content: ""; position: absolute; right: -6px; top: 50%; width: 12px; height: 12px; margin-top: -6px; background: #fff1c4; transform: rotate(45deg); box-shadow: 0 0 10px #fff1c4; }

/* ---------- Finale band ---------- */
.finale {
  position: relative; overflow: hidden; text-align: center;
  padding: 96px var(--gutter);
  background:
    radial-gradient(ellipse 60% 80% at 50% 50%, rgba(11,14,19,.35), rgba(11,14,19,.92) 80%),
    linear-gradient(180deg, var(--causeway), rgba(11,14,19,.2) 30%, rgba(11,14,19,.2) 70%, var(--causeway)),
    url("../assets/img/plate-tall.webp") 50% 30% / cover no-repeat;
}
.finale__inner { display: grid; justify-items: center; gap: 1rem; max-width: 40rem; margin: 0 auto; }
.finale__title { margin: 0; font: 800 clamp(2.4rem, 9vw, 4.6rem)/1 var(--f-display); color: var(--ember); text-shadow: 0 2px 0 #000, 0 0 40px rgba(255,170,60,.3); }
.finale__title::after { content: ""; display: block; width: 260px; max-width: 80%; height: 22px; margin: .8rem auto 0; background: var(--ornament) center / contain no-repeat; }
.finale__lead { margin: 0 0 .6rem; font-size: 1.15rem; color: var(--parchment); }

/* ---------- Footer ---------- */
.footer {
  display: grid; justify-items: center; gap: .9rem; text-align: center;
  padding: 56px var(--gutter) calc(110px + env(safe-area-inset-bottom));
  background: #07090c; border-top: 1px solid rgba(184,145,63,.35);
}
.footer__logo { width: 180px; opacity: .95; }
.footer__fb { min-width: 260px; }
.footer__line { margin: 0; color: var(--silver-dim); font-size: .95rem; }
.footer__copy { margin: 0; color: var(--silver-dim); font-size: .875rem; }

/* ---------- Phone dock ---------- */
.dock {
  position: fixed; inset: auto 0 0; z-index: 30;
  display: grid; grid-template-columns: 1fr 1.3fr; gap: 8px;
  padding: 8px var(--gutter) calc(8px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(8,10,13,.8), rgba(8,10,13,.97));
  border-top: 1px solid rgba(184,145,63,.4);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  transform: translateY(110%); transition: transform .3s ease;
}
.dock.is-shown { transform: none; }
.dock .btn { min-height: 46px; font-size: 1.05rem; }

/* =========================================================
   Phone landscape (short screens)
   ========================================================= */
@media (orientation: landscape) and (max-height: 520px) {
  .hero { min-height: 340px; }
  .topbar { height: calc(46px + env(safe-area-inset-top)); }
  .topbar__crest { width: 84px; }
  .clock { top: 17cqh; column-gap: 3vw; }
  .clock__num { font-size: min(13vw, 30cqh); }
  .cast { height: 80cqh; }
  .cast--mage { left: -9vw; }
  .cast--warrior { right: -12vw; }
  .hero__foot {
    grid-template-columns: 1fr auto; align-items: end; justify-items: start; text-align: left;
    gap: .3rem 1.2rem; padding: 0 max(24px, env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left));
  }
  .tally { justify-items: start; width: 100%; max-width: 360px; gap: .2rem; }
  .tally__line { font-size: .9rem; }
  .tally__next { font-size: .875rem; }
  .hero__actions { grid-column: 2; grid-row: 1 / span 2; grid-template-columns: auto auto; width: auto; }
  .hero__actions .btn { min-height: 44px; font-size: 1rem; padding-inline: 1.1em; }
  .hero__when { font-size: .875rem; grid-column: 1; display: block; }
  .hero__when span + span::before { content: " / "; color: var(--silver-dim); }
  .dock { display: none; }
  .versus { max-width: 760px; }
}

/* =========================================================
   Tablet / PC
   ========================================================= */
@media (min-width: 700px) {
  :root { --gutter: 32px; }
  .field-row { grid-template-columns: 1fr 1fr; }
  .gate__ways { grid-template-columns: 1fr 1fr; align-items: start; }
  .faction__body { padding: 5rem 1.8rem 1.8rem; }
  .faction__races { font-size: 1rem; }
  .faction__stat { font-size: 1.05rem; }
  .versus__mark { width: 104px; height: 104px; top: 44%; }
  .versus__mark span { font-size: 2.4rem; }
  .muster { padding-inline: var(--gutter); }
  .rewards { padding: 0; }
}

@media (min-width: 1000px) and (min-height: 521px) {
  .topbar { height: 78px; padding-inline: 44px; }
  .topbar.is-solid { height: 64px; }
  .topbar__crest { width: 190px; margin-top: 8px; }
  .topbar.is-solid .topbar__crest { width: 104px; margin-top: 4px; }
  .topbar__nav { display: flex; }
  .topbar__play { margin-left: 2.4rem; }

  .hero__foot { gap: .85rem; padding-bottom: 3.4cqh; }
  .tally { width: 480px; }
  .tally__line { font-size: 1.2rem; }
  .hero__actions { width: auto; grid-template-columns: auto auto; gap: 1rem; }
  .hero__actions .btn--lg-alt { min-height: 58px; padding-inline: 2em; font-size: 1.25rem; }
  .hero__when { font-size: 1rem; display: block; }
  .hero__when span + span::before { content: "   /   "; color: var(--silver-dim); white-space: pre; }
  .dock { display: none; }
  .footer { padding-bottom: 56px; }

  .section { padding-block: 110px; }
  .section--muster { padding-block: 110px 70px; }
  .muster { grid-template-columns: minmax(0, 1fr) 520px; align-items: center; gap: 80px; }
  .muster .panel { order: 2; }
  .rewards { order: 1; max-width: none; }
  .rewards__lead { font-size: 1.15rem; }
  .milestones { grid-template-columns: repeat(5, 1fr); margin-top: .5rem; }
  .milestones::before, .milestones::after { left: 0; top: 10px; height: 3px; width: auto; }
  .milestones::before { right: 0; bottom: auto; }
  .milestones::after { width: var(--progress); max-height: none; height: 3px; }
  .milestone { grid-template-columns: 1fr; padding: 38px .6rem 0 0; gap: .4rem; }
  .milestone::before { left: 0; top: 1px; margin-top: 0; }
  .milestone__reward { font-size: 1rem; line-height: 1.3; }

  .section--gate { padding-top: 80px; }
  .gate__main { padding: 4.2rem 2rem 3.8rem; }
  .gate__lead { font-size: 1.25rem; }
  .gate__main .btn { width: auto; }
  .versus { gap: 0 24px; max-width: 960px; }
  .balance { max-width: 960px; }
  .finale { padding-block: 140px; }
}

/* ---------- How to play / Good to know / FAQ ---------- */
.section--how { background: linear-gradient(180deg, var(--causeway), #0d1116); }
.how { max-width: 1080px; margin: 1.6rem auto 0; padding: 0; list-style: none; display: grid; gap: 1.1rem; }
.how__step, .know__card {
  position: relative; padding: 1.5rem 1.3rem 1.6rem;
  background: linear-gradient(180deg, #1a2028, #11151b);
  box-shadow: var(--frame);
  clip-path: polygon(12px 0, calc(100% - 12px) 0, 100% 12px, 100% calc(100% - 12px), calc(100% - 12px) 100%, 12px 100%, 0 calc(100% - 12px), 0 12px);
}
.how__step { padding-top: 3.1rem; }
.how__num {
  position: absolute; left: 1.2rem; top: -.1rem; width: 2.6rem; height: 2.6rem; display: grid; place-items: center;
  font: 800 1.4rem/1 var(--f-forge); color: #2a1a05; background: var(--gilt);
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
}
.how__title, .know__title { margin: 0 0 .35rem; font: 800 1.7rem/1.05 var(--f-display); color: var(--ember); }
.how__step p, .know__card p { margin: 0; }

.section--know { background: linear-gradient(180deg, #0d1116, var(--causeway)); }
.know { max-width: 1080px; margin: 1.6rem auto 0; display: grid; gap: 1.1rem; }
.know__icon { width: 34px; height: 34px; margin-bottom: .6rem; color: var(--gold); }

.section--faq { background: var(--causeway); padding-top: 24px; }
.faq { max-width: 780px; margin: 1.6rem auto 0; display: grid; gap: .75rem; }
.faq__item { background: linear-gradient(180deg, #1a2028, #11151b); box-shadow: var(--frame); }
.faq__item summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 56px; padding: .8rem 1.1rem; font: 800 1.2rem/1.25 var(--f-forge); color: var(--parchment);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: ""; flex: none; width: 12px; height: 12px; margin-right: 4px; border: solid var(--gold); border-width: 0 2px 2px 0;
  transform: rotate(45deg) translateY(-3px); transition: transform .25s ease;
}
.faq__item[open] summary { color: var(--ember); }
.faq__item[open] summary::after { transform: rotate(-135deg) translate(-2px, -2px); }
.faq__item p { margin: 0; padding: 0 1.1rem 1.2rem; }
.faq__help { margin: 1.6rem 0 0; text-align: center; }

.footer__langnote { margin: 0; max-width: 34rem; text-align: center; color: var(--silver); font-size: .95rem; }
.footer__lang { display: inline-flex; align-items: center; gap: .6rem; color: var(--silver); }
.footer__lang[hidden] { display: none; }
.footer__lang select {
  min-height: 44px; padding: 0 .8rem; color: var(--parchment); background: var(--slate);
  border: 1px solid var(--gold); border-radius: 0; font: 500 1rem var(--f-body);
}

@media (min-width: 700px) {
  .know { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .how { grid-template-columns: repeat(3, 1fr); }
  .how__step { padding: 3.2rem 1.5rem 1.8rem; }
}
@media (min-width: 1000px) {
  .know { grid-template-columns: repeat(4, 1fr); }
  .topbar__nav { gap: clamp(0rem, .6vw, 1.2rem); }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .eagle { opacity: 1; }
}

/* Live state: one "Play now" button is enough */
.is-live .hero__actions .btn--steel { display: none !important; }

/* Character grading: sit them into the storm light of the scene */
.cast { filter: drop-shadow(0 0 22px rgba(0,0,0,.6)) brightness(.94) contrast(1.06) saturate(.92); }
@media (min-aspect-ratio: 1/1) and (min-height: 521px) {
  .cast--mage { left: -5vw; }
  .cast--warrior { right: -14vw; }
  .clock { column-gap: 3vw; }
  .clock__num { font-size: min(14vw, 31cqh); }
}
@media (orientation: landscape) and (max-height: 520px) {
  .cast { height: 92cqh; }
}
@media (min-width: 1000px) and (min-height: 521px) {
  .versus { max-width: 1120px; gap: 0 28px; }
  .balance { max-width: 1120px; }
  .faction__art img { aspect-ratio: 4 / 5; }
}

/* ---------- Load-later backgrounds ----------
   Decorative pictures below the first screen wait until the visitor scrolls near them
   (js/main.js adds "bg-on"). This keeps the first screen light on slow phones. */
.lazy-bg:not(.bg-on), .lazy-bg:not(.bg-on)::before { background-image: none !important; }
.panel.lazy-bg:not(.bg-on) { background-color: #0d1014; box-shadow: var(--frame); }

/* ---------- Softer lightning on phones ---------- */
.hero.is-flash-soft .hero__lightning { animation: strikeSoft 2.4s ease-in-out 1; }
@keyframes strikeSoft { 0% { opacity: 0; } 18% { opacity: .3; } 34% { opacity: .12; } 44% { opacity: .2; } 100% { opacity: 0; } }
.hero.is-flash-soft .eagle__svg { filter: drop-shadow(0 0 4px rgba(220,235,255,.6)) brightness(1.2); }
.cast.cast-wait { opacity: 0; animation: none !important; }
.cast.cast-late { animation-delay: 0s !important; }

/* ---------- Register box: states for the real sign-up ---------- */
.trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.field input[aria-invalid="true"] { border-color: #c4574a; box-shadow: inset 0 2px 8px rgba(0,0,0,.85), 0 0 0 1px rgba(255,120,100,.45); }
.form__status.is-bad { color: #ff9a8a; }
.form__status.is-good { color: #b9e0b9; }
.btn.is-busy { filter: saturate(.6) brightness(.9); cursor: progress; }
.btn.is-busy .btn__label::before { content: ""; display: inline-block; width: .8em; height: .8em; margin-right: .5em; vertical-align: -.05em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.botcheck--live { border: 0; padding: 0; min-height: 65px; background: none; justify-content: center; }
.signup-done { display: grid; justify-items: center; gap: .8rem; text-align: center; padding: 1.5rem 0 .5rem; outline: none; }
.signup-done[hidden] { display: none; }
.signup-done__seal { width: 76px; height: 76px; filter: drop-shadow(0 0 16px rgba(255,190,80,.45)); }
.signup-done__title { margin: 0; font: 800 clamp(1.8rem, 6vw, 2.3rem)/1.05 var(--f-display); color: var(--ember); }
.signup-done__text { margin: 0; color: var(--parchment); max-width: 26rem; }
.signup-done__text strong { color: var(--ember); }
.signup-done__pc { color: var(--silver); font-size: .95rem; }
@media (prefers-reduced-motion: no-preference) {
  .signup-done:not([hidden]) { animation: rise .8s cubic-bezier(.2,.8,.2,1) both; }
}
.form[hidden], .panel__lead[hidden] { display: none; }

/* ---------- Faction pledge in the Register box ---------- */
.side { margin: .2rem 0 0; padding: 0; border: 0; min-width: 0; display: grid; gap: .55rem; }
.side__legend { padding: 0; margin-bottom: .1rem; font: 600 1rem/1.2 var(--f-forge); color: #e7dcc2; letter-spacing: .02em; }
.side__legend em { font: 400 .875rem var(--f-body); color: var(--silver-dim); font-style: normal; margin-left: .3em; }
.side__options { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.side__opt, .side__later { position: relative; cursor: pointer; }
.side input[type="radio"] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.side__card {
  --tone: 108,196,255;
  position: relative; display: grid; justify-items: center; gap: .2rem; text-align: center;
  min-height: 92px; padding: .75rem .5rem .7rem;
  background: linear-gradient(180deg, #0b0e12, #12161b);
  border: 1px solid #3a3222;
  box-shadow: inset 0 2px 8px rgba(0,0,0,.8);
  clip-path: polygon(8px 0, calc(100% - 8px) 0, 100% 8px, 100% calc(100% - 8px), calc(100% - 8px) 100%, 8px 100%, 0 calc(100% - 8px), 0 8px);
  transition: border-color .2s ease, box-shadow .25s ease, background .25s ease;
}
.side__opt--fury .side__card { --tone: 208,70,90; }
.side__mark { width: 22px; height: 22px; fill: rgba(var(--tone), .55); transition: fill .2s ease, filter .2s ease; }
.side__name { font: 800 1.08rem/1.05 var(--f-display); color: var(--parchment); }
.side__races { font-size: .875rem; color: var(--silver-dim); }
.side__opt:hover .side__card { border-color: rgba(var(--tone), .6); }
.side__opt input:checked + .side__card {
  border-color: rgba(var(--tone), .95);
  background: radial-gradient(ellipse 90% 90% at 50% 100%, rgba(var(--tone), .22), transparent 70%), linear-gradient(180deg, #0b0e12, #141a21);
  box-shadow: inset 0 0 0 1px rgba(var(--tone), .5), inset 0 -24px 30px -20px rgba(var(--tone), .55);
}
.side__opt input:checked + .side__card .side__mark { fill: rgb(var(--tone)); filter: drop-shadow(0 0 6px rgba(var(--tone), .8)); }
.side__opt--light input:checked + .side__card .side__name { color: #d6eeff; }
.side__opt--fury input:checked + .side__card .side__name { color: #ffd6d4; }
.side input:focus-visible + .side__card, .side__later input:focus-visible + span { outline: 2px solid var(--ember); outline-offset: 2px; }
.side__later { justify-self: center; display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; padding: .35rem .8rem; font-size: .92rem; color: var(--silver); }
.side__later span::before { content: ""; display: inline-block; width: 14px; height: 14px; margin-right: .5rem; vertical-align: -2px; border: 1.5px solid var(--silver-dim); transform: rotate(45deg) scale(.85); transition: background .2s ease, border-color .2s ease; }
.side__later input:checked + span { color: var(--parchment); }
.side__later input:checked + span::before { background: var(--gold); border-color: #f6dc98; box-shadow: 0 0 8px rgba(255,190,80,.6); }
.side__note { font-size: .875rem; color: var(--silver-dim); text-align: center; line-height: 1.35; }
.signup-done__side { color: var(--silver); }
.signup-done__side strong.is-light { color: #cfeaff; }
.signup-done__side strong.is-fury { color: #ffd0cf; }
.side__note.is-bad { color: #ff9a8a; }

/* Keep focused fields and buttons clear of the fixed menu bar (top) and the phone dock (bottom) */
html { scroll-padding-top: 76px; }
@media (max-width: 999px), (max-height: 520px) { html { scroll-padding-bottom: 88px; } }

/* Play buttons while Open Beta is not live: greyed out */
a[data-play][aria-disabled="true"] { opacity: .45; filter: grayscale(1); cursor: not-allowed; box-shadow: none; }
.rewards__tba { margin: .25rem 0 0; font-size: 1.15rem; color: var(--gold, #e8c36a); text-align: center; }
