:root {
  --navy: #0b1630; --navy2: #13244a; --navy3: #1c3466; --line: rgba(233, 185, 73, .28);
  --gold: #e9b949; --gold-lit: #ffd978; --parch: #f4e7c8; --ink: #1a1206; --dim: #a9b4cf;
  --crimson: #c0382c; --crimson-lit: #ff7b6b; --green: #4fae6b; --bar: 60px;
  --display: 'Cinzel', Georgia, serif; --body: 'Manrope', system-ui, sans-serif;
}
* { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body { background: var(--navy); color: #e8ecf7; font: 500 16px/1.55 var(--body); overflow-x: hidden; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
h1, h2, h3 { font-family: var(--display); line-height: 1.1; letter-spacing: .01em; }
.kick { display: block; font: 800 12px/1.2 var(--body); letter-spacing: .16em; text-transform: uppercase; color: var(--gold); }
.dim { color: var(--dim); font-size: 14px; }

/* ---------- top bar ---------- */
.topbar { position: fixed; inset: 0 0 auto 0; height: var(--bar); z-index: 60; display: flex; align-items: center; gap: 18px; padding: 0 18px;
  background: linear-gradient(#0b1630f2, #0b1630cc); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; flex: none; }
.brand img { width: 40px; height: 40px; border-radius: 50%; }
.brand b { font: 800 16px/1 var(--display); color: var(--gold-lit); display: block; }
.brand small { font-size: 11px; color: var(--dim); }
.nav { display: flex; gap: 4px; margin-left: auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav button { padding: 8px 13px; border-radius: 999px; font-weight: 700; font-size: 14px; white-space: nowrap; color: var(--dim); transition: .2s; }
.nav button:hover { color: #fff; background: #ffffff12; }
.nav button.on { color: var(--ink); background: linear-gradient(var(--gold-lit), var(--gold)); }

/* ---------- buttons ---------- */
.door { display: inline-flex; align-items: center; justify-content: center; padding: 12px 22px; border-radius: 10px; font: 800 14px/1 var(--body); letter-spacing: .04em; text-transform: uppercase; text-decoration: none;
  color: var(--ink); background: linear-gradient(#ffe394, #e0a93a); box-shadow: 0 3px 0 #9a6d16, 0 10px 22px #0006; transition: transform .15s, filter .15s; }
.door:hover { transform: translateY(-2px); filter: brightness(1.08); }
.door.red { color: #fff; background: linear-gradient(#d9503f, #a52a20); box-shadow: 0 3px 0 #6b1711, 0 10px 22px #0006; }
.door.ghost { color: var(--gold-lit); background: #ffffff10; box-shadow: inset 0 0 0 1.5px var(--line); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- pages + curtain ---------- */
.page { display: none; padding-top: var(--bar); }
.page.on { display: block; }
#about { padding-top: 0; }
#wipe { position: fixed; inset: 0; z-index: 80; visibility: hidden; pointer-events: none; overflow: hidden; }
.wipe-panel { position: absolute; inset: 0 -14vw; display: flex; align-items: center; justify-content: center; gap: 3vw;
  background: radial-gradient(120% 90% at 50% 100%, #5a2a14, #26120a 60%, #120805); clip-path: polygon(7% 0, 100% 0, 93% 100%, 0 100%); }
.wipe-host { height: 62vh; width: auto; filter: drop-shadow(0 16px 20px #000a); }
.wipe-txt small { display: block; font: 800 13px var(--body); letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }
.wipe-txt b { font: 900 clamp(40px, 8vw, 110px)/1 var(--display); color: var(--parch); text-shadow: 0 5px 0 #000a; }
.wipe-run { position: absolute; left: 0; bottom: -2vh; display: flex; align-items: flex-end; gap: 1vw; }
.wipe-run img, .horde .run img { width: auto; max-width: none; filter: drop-shadow(0 10px 8px #0009); animation: run .34s infinite alternate ease-in-out; transform-origin: 50% 100%; }
@keyframes run { from { transform: translateY(0) rotate(-5deg); } to { transform: translateY(-3.2vh) rotate(6deg); } }

/* ================= STORY STAGE ================= */
.stage { position: sticky; top: 0; height: 100vh; height: 100dvh; overflow: hidden; background: #070d1e; --mx: 0; --my: 0; }
#embers { position: absolute; inset: 0; z-index: 25; pointer-events: none; mix-blend-mode: screen; }
#flash { position: absolute; inset: 0; z-index: 40; background: #fff7dc; opacity: 0; visibility: hidden; pointer-events: none; }
.scene { position: absolute; inset: 0; overflow: hidden; }
.scene .bg { position: absolute; inset: -4%; translate: calc(var(--mx) * 16px) calc(var(--my) * 10px); }
.scene .bg::before { content: ''; position: absolute; inset: 0; background: var(--sky); }
.scene .bg::after { content: ''; position: absolute; left: -10%; right: -10%; bottom: 0; height: 30%; border-radius: 50% 50% 0 0 / 34% 34% 0 0; background: var(--ground); box-shadow: 0 -30px 80px var(--haze, #0000); }
.art { position: absolute; right: 0; bottom: 0; width: 64vw; height: calc(100% - var(--bar) - 4vh - 84px); translate: calc(var(--mx) * -22px) calc(var(--my) * -10px); }
.art.wide { left: 0; width: 100%; }
.ch { position: absolute; width: auto; max-width: none; filter: drop-shadow(0 14px 10px #0008); user-select: none; -webkit-user-drag: none; }
.ch.foe { filter: brightness(.6) saturate(.6) sepia(.3) hue-rotate(-25deg) drop-shadow(0 14px 10px #000a) drop-shadow(0 0 14px #c0382c88); }
.ch.bld { filter: drop-shadow(0 10px 8px #0007); }

/* scene skies */
.s-hero { --sky: radial-gradient(90% 70% at 50% 34%, #2b4a8f 0, #14254d 45%, #070d1e 100%); --ground: linear-gradient(#152a55, #0a1430); }
.s-k1 { --sky: linear-gradient(#1c2350 0, #4a3a78 46%, #d0744a 82%, #f1b45c 100%); --ground: linear-gradient(#3b2a3f, #1b1426); --haze: #f1b45c55; }
.s-k2 { --sky: linear-gradient(#150a12 0, #4a1418 50%, #a8321f 88%, #e06a2c 100%); --ground: linear-gradient(#34100f, #150607); --haze: #e06a2c66; }
.s-k3 { --sky: linear-gradient(#1f4f6e 0, #5aa0a8 50%, #f3d98c 100%); --ground: linear-gradient(#3f7a45, #1d4428); --haze: #f3d98c55; }
.s-k4 { --sky: linear-gradient(#060b1c 0, #14285c 50%, #7a3a2c 92%, #d06a2a 100%); --ground: linear-gradient(#1c2238, #0a0d1a); --haze: #d06a2a66; }
.s-hist { --sky: linear-gradient(#0d1a3a, #1e3a70 60%, #3d5f9a); --ground: linear-gradient(#22386a, #0e1a38); }
.s-baul { --sky: linear-gradient(#0b1a14 0, #1d3d2c 50%, #5b6a2c 100%); --ground: linear-gradient(#2a3d1e, #111c0e); --haze: #9ab04a33; }
.s-awake { --sky: linear-gradient(#5db4e8 0, #a8dcf2 60%, #f6e7b0 100%); --ground: linear-gradient(#69a84f, #2f6a35); }
.s-ark { --sky: linear-gradient(#2a3f7a 0, #c9865a 62%, #f6cf7a 100%); --ground: linear-gradient(#d9a95a, #8a5e2c); --haze: #f6cf7a66; }
.s-who { --sky: linear-gradient(#17306a, #3f6fb5 60%, #9cc7e8); --ground: linear-gradient(#2f6a4a, #153a2a); }
.s-fin { --sky: radial-gradient(90% 70% at 50% 30%, #6b4a1c 0, #2a1c10 50%, #0c0806 100%); --ground: linear-gradient(#2a1c10, #0c0806); --haze: #e9b94944; }

/* scene title */
.ttl { position: absolute; left: 5vw; top: calc(var(--bar) + 4vh + 56px); width: min(34vw, 470px); z-index: 5; }
.ttl h2 { font-size: clamp(34px, 5.2vw, 78px); font-weight: 900; color: var(--parch); text-shadow: 0 4px 0 #0009, 0 0 40px #0008; margin: 8px 0 10px; }
.ttl p { font: 700 clamp(15px, 1.5vw, 20px)/1.35 var(--body); color: #fff; text-shadow: 0 2px 10px #000c; }
.s-hist .ttl h2, .s-baul .ttl h2, .s-awake .ttl h2 { font-size: clamp(28px, 3.5vw, 52px); }
.s-fin .ttl { left: 50%; top: calc(var(--bar) + 8vh); width: min(92vw, 900px); transform: translateX(-50%); text-align: center; }
.s-fin .ttl h2 { font-size: clamp(28px, min(5vw, 7.5vh), 68px); color: var(--gold-lit); } .s-fin .art { height: 50%; }
.s-fin .ttl p { font-weight: 500; max-width: 60ch; margin: auto; }
.fin-cta { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 2.4vh; }

/* chat: the speaker stands waist-up beside a bold speech bubble */
.chat { position: absolute; left: 3vw; bottom: calc(4vh + 12px); width: min(520px, 94vw); z-index: 20; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.msg { display: flex; align-items: flex-end; max-width: 100%; filter: drop-shadow(0 10px 18px #000a); }
.msg.r { flex-direction: row-reverse; align-self: flex-end; }
.msg p { position: relative; background: linear-gradient(#fffdf4, #f6e6bd); color: #23180a; font: 600 16px/1.42 var(--body); padding: 12px 18px 13px 22px; margin: 0 0 10px -10px; border-radius: 18px; border: 2.5px solid var(--gold); box-shadow: inset 0 -3px 0 #e3c779; }
.msg.r p { padding: 12px 22px 13px 18px; margin: 0 -10px 10px 0; }
.msg p::before { content: ''; position: absolute; left: -11px; bottom: 16px; width: 18px; height: 18px; background: #f9ecc9; border-left: 2.5px solid var(--gold); border-bottom: 2.5px solid var(--gold); transform: rotate(45deg); border-radius: 0 0 0 4px; }
.msg.r p::before { left: auto; right: -11px; transform: rotate(-135deg); }
.msg p > b { display: table; font: 900 12px/1 var(--body); letter-spacing: .1em; text-transform: uppercase; color: #fff; background: linear-gradient(#c0382c, #8a1f17); padding: 5px 10px; border-radius: 6px; margin: -24px 0 7px -4px; box-shadow: 0 3px 0 #5a120d; }
.msg p em { font-style: normal; font-weight: 800; color: #b3350f; }
.av { flex: none; position: relative; z-index: 1; width: 104px; height: 118px; overflow: hidden; -webkit-mask: linear-gradient(#000 82%, transparent); mask: linear-gradient(#000 82%, transparent); }
.av img { position: absolute; left: 50%; top: 2%; height: 215%; width: auto; max-width: none; transform: translateX(-50%); animation: breathe 3.2s ease-in-out infinite; transform-origin: 50% 60%; }
.msg.r .av img { animation-delay: -1.4s; }
@keyframes breathe { 50% { transform: translateX(-50%) translateY(-3px) scale(1.025); } }

/* HUD */
.hud { position: absolute; top: calc(var(--bar) + 4vh + 8px); left: 0; right: 0; margin: 0 auto; width: fit-content; z-index: 28; display: flex; gap: 8px; }
.rec { min-width: 92px; padding: 6px 10px 7px; border-radius: 10px; background: #0b1630cc; border: 1px solid var(--line); text-align: center; backdrop-filter: blur(4px); }
.rec small { display: block; font: 800 10px var(--body); letter-spacing: .14em; color: var(--dim); }
.rec b { display: block; font: 800 13px/1.2 var(--body); min-height: 16px; }
.win { color: var(--gold-lit); } .lose { color: var(--crimson-lit); } .live { color: #7be39a; }
.chapters { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); z-index: 28; display: flex; flex-direction: column; gap: 9px; align-items: flex-end; }
.chapters button { display: flex; align-items: center; gap: 8px; }
.chapters button::after { content: ''; width: 10px; height: 10px; border-radius: 50%; border: 2px solid #fff9; transition: .2s; }
.chapters span { font: 700 11px var(--body); background: #0b1630e6; padding: 3px 8px; border-radius: 6px; opacity: 0; transition: .2s; }
.chapters button:hover span { opacity: 1; }
.chapters button.on::after { background: var(--gold-lit); border-color: var(--gold-lit); transform: scale(1.35); }
.progress { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; z-index: 30; background: #0006; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold-lit)); transform: scaleX(0); transform-origin: 0 50%; }

/* hero */
.hero-mid { position: absolute; left: 50%; top: calc(var(--bar) + 3vh); width: min(92vw, 620px); transform: translateX(-50%); text-align: center; z-index: 6; }
.hero-logo { width: min(74vw, 46vh, 460px); margin: 0 auto .5vh; }
.hero-mid h1 { font-size: clamp(42px, 8.4vw, 104px); font-weight: 900; color: var(--parch); text-shadow: 0 5px 0 #000a; margin: 6px 0 12px; }
.hero-mid h1 em { font-style: normal; color: var(--gold-lit); }
.hero-mid p { color: #d5dcf0; max-width: 54ch; margin: 0 auto 18px; }
.hero-mid .hero-cta { justify-content: center; }
.hero-stats { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 3vh; }
.hero-stats li { background: #0b163099; border: 1px solid var(--line); border-radius: 12px; padding: 10px 8px; }
.hero-stats b { display: block; font: 900 clamp(20px, 2.6vw, 30px)/1.1 var(--display); color: var(--gold-lit); }
.hero-stats span { font-size: 12px; line-height: 1.3; color: var(--dim); display: block; }
.scroll-hint { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); font: 800 11px var(--body); letter-spacing: .22em; text-transform: uppercase; color: var(--gold); z-index: 6; text-align: center; }
.scroll-hint i { display: block; width: 2px; height: 26px; margin: 6px auto 0; background: var(--gold); animation: hint 1.4s infinite; transform-origin: 50% 0; }
@keyframes hint { 0% { transform: scaleY(0); } 60% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }

/* barbarian horde wipe between seasons */
.horde { position: absolute; top: 0; left: 0; width: 160vw; height: 100%; z-index: 35; pointer-events: none; overflow: hidden; }
.horde .dust { position: absolute; inset: 0; background: linear-gradient(90deg, transparent 0, #1c0f08 10%, #3a1d0e 50%, #1c0f08 90%, transparent 100%); }
.horde-lbl { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%); text-align: center; white-space: nowrap; }
.horde-lbl small { display: block; font: 800 13px var(--body); letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }
.horde-lbl b { font: 900 clamp(46px, 9vw, 130px)/1 var(--display); color: var(--parch); text-shadow: 0 6px 0 #000a; }
.horde .run { position: absolute; bottom: -2vh; height: 60vh; width: 40vw; }
.horde .run.front { left: 2vw; } .horde .run.tail { right: 0; }
.horde .run img { position: absolute; bottom: 0; }

/* props */
.stamp { position: absolute; left: 50%; top: 20%; z-index: 8; padding: 10px 26px 12px; border: 6px double currentColor; border-radius: 12px; text-align: center; background: #0b1630b8; backdrop-filter: blur(2px); box-shadow: 0 12px 40px #000a; }
.stamp b { display: block; font: 900 clamp(34px, 5vw, 72px)/1 var(--display); text-transform: uppercase; }
.stamp small { font: 800 clamp(11px, 1.1vw, 15px) var(--body); letter-spacing: .2em; text-transform: uppercase; }
.stamp.small { top: 46%; left: 62%; } .stamp.small b { font-size: clamp(26px, 3.4vw, 48px); }
.stamp.live b::before { content: ''; display: inline-block; width: .32em; height: .32em; border-radius: 50%; background: currentColor; margin-right: .25em; vertical-align: .18em; animation: pulse 1s infinite alternate; }
@keyframes pulse { to { opacity: .2; transform: scale(.7); } }
.flag { position: absolute; transform: translateX(-50%); padding: 7px 14px 16px; font: 900 clamp(15px, 1.7vw, 24px)/1 var(--display); color: #fff; background: linear-gradient(#b3261e, #6b1711); clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%); z-index: 4; }
.tally { position: absolute; left: 30%; top: 0; width: 44%; display: grid; gap: 8px; z-index: 6; }
.vs { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; background: #0b1630cc; border: 1px solid var(--line); border-radius: 12px; padding: 8px 16px; text-align: center; }
.vs b { font: 900 clamp(24px, 3vw, 44px)/1 var(--display); color: var(--gold-lit); }
.vs b.them { color: var(--crimson-lit); }
.vs span { font-size: clamp(11px, 1vw, 13px); line-height: 1.3; color: #d5dcf0; }
.burst { position: absolute; width: 22vh; height: 22vh; margin: 0 0 -11vh 0; z-index: 7; pointer-events: none;
  background: radial-gradient(circle, #fff 0 18%, #ffd978 19% 34%, #ff7b2c 35% 52%, transparent 54%);
  clip-path: polygon(50% 0, 60% 30%, 90% 12%, 72% 42%, 100% 50%, 72% 60%, 88% 90%, 58% 72%, 50% 100%, 40% 72%, 10% 90%, 28% 58%, 0 50%, 28% 40%, 12% 10%, 40% 30%); }
.pod { position: absolute; bottom: 6%; background: linear-gradient(#f1d27a, #b98524); border-radius: 8px 8px 0 0; box-shadow: inset 0 6px 0 #ffe9a8, 0 10px 20px #0006; display: flex; align-items: flex-end; justify-content: center; }
.pod b { font: 900 clamp(22px, 3vw, 44px) var(--display); color: #5a3a08; padding-bottom: 4px; }
.tag { position: absolute; z-index: 9; background: var(--gold-lit); color: var(--ink); font: 800 clamp(11px, 1.05vw, 14px)/1.25 var(--body); padding: 7px 12px; border-radius: 10px; text-align: center; white-space: nowrap; box-shadow: 0 6px 16px #0007; }
.seedline { position: absolute; left: 4%; top: 2%; display: flex; align-items: center; gap: 10px; z-index: 6; }
.seedline span, .ladder span { background: #0b1630cc; border: 1px solid var(--line); border-radius: 10px; padding: 7px 14px; font: 700 13px var(--body); }
.seedline b { font: 900 22px var(--display); color: var(--gold-lit); margin-left: 6px; }
.seedline i, .ladder i { font-style: normal; color: var(--gold-lit); font-size: 20px; }
.seedline i { transform: rotate(90deg); }
.hot { border-color: var(--crimson-lit) !important; color: #ffd2cb; }
.ladder { position: absolute; left: 39%; top: 0; display: grid; gap: 6px; width: 132px; text-align: center; z-index: 6; }
.ladder i { position: absolute; right: -26px; bottom: 4px; }
.bars { position: absolute; right: 9%; top: 0; width: 34%; display: grid; gap: 14px; z-index: 6; }
.bgrp { background: #0b1630cc; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px 14px; }
.bgrp small { font: 800 11px var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.bar { position: relative; height: 34px; margin-top: 8px; display: flex; align-items: center; justify-content: space-between; padding: 0 10px; }
.bar i { position: absolute; inset: 0; border-radius: 6px; }
.bar.us i { background: linear-gradient(90deg, #b98524, #ffd978); } .bar.them i { background: linear-gradient(90deg, #6b1711, #d9503f); }
.bar b, .bar em { position: relative; font: 800 15px var(--body); font-style: normal; color: #fff; text-shadow: 0 1px 3px #000a; }
.bar.us b, .bar.us em { color: var(--ink); text-shadow: none; } .bar em { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.shot { display: block; position: relative; border-radius: 10px; overflow: hidden; border: 2px solid var(--line); background: #000; transition: transform .2s; }
.shot:hover { transform: scale(1.03); }
.shot span { position: absolute; left: 6px; bottom: 6px; background: #0b1630e6; font: 800 10px var(--body); letter-spacing: .1em; text-transform: uppercase; padding: 3px 7px; border-radius: 5px; }
#k4shot { width: 62%; }
/* history */
.roster { position: absolute; left: 44%; right: 8%; top: 0; display: flex; flex-direction: column; gap: 12px; z-index: 6; } .roster > * { flex: none; }
.seeds { width: 100%; border-collapse: collapse; background: #0b1630cc; border-radius: 12px; overflow: hidden; font-size: clamp(11px, 1.05vw, 14px); }
.seeds th { font: 800 10px var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); text-align: left; padding: 7px 10px; }
.seeds td { padding: min(5px, .5vh) 10px; border-top: 1px solid #ffffff14; font-weight: 600; }
.count { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.count b { font: 900 clamp(36px, min(5.4vw, 8vh), 80px)/1 var(--display); color: var(--gold-lit); text-shadow: 0 4px 0 #0008; }
.count span { font-weight: 700; color: #d5dcf0; } .count em { font-style: normal; font-weight: 800; color: var(--ink); background: var(--gold-lit); padding: 4px 10px; border-radius: 8px; font-size: 13px; }
.dots { display: grid; grid-template-columns: repeat(20, 1fr); gap: 4px; align-content: start; width: min(100%, 44vh); }
.dots i { aspect-ratio: 1; border-radius: 50%; background: #c9d4ee; border: 1.5px solid transparent; max-width: 16px; width: 100%; }
.dots .keep { background: var(--gold); }
/* baulur */
.keepcard { position: absolute; left: 62%; width: 36%; bottom: 20%; border-radius: 16px; overflow: hidden; border: 4px solid #6b4a1c; box-shadow: 0 16px 40px #000a; z-index: 2; }
.keepcard img { width: 100%; }
.plate { position: absolute; z-index: 9; background: #0b1630e0; border: 1px solid var(--line); border-radius: 12px; padding: 9px 12px; text-align: center; white-space: nowrap; }
.plate > b { display: block; font: 900 clamp(14px, 1.5vw, 20px) var(--display); color: var(--parch); }
.plate > small { color: var(--dim); font-size: 12px; }
.plate > div { display: flex; gap: 6px; margin-top: 7px; justify-content: center; }
.utc { background: #ffffff14; border-radius: 8px; padding: 5px 9px; font-size: 12px; font-weight: 700; }
.utc b { font-size: 15px; } .utc small { display: block; font-size: 10px; opacity: .75; font-weight: 600; }
.dial { position: absolute; left: 47%; top: 4%; width: min(22vh, 15vw); transform: translateX(-50%); z-index: 6; overflow: visible; }
.dial .face { fill: #0b1630e0; stroke: var(--gold); stroke-width: 3; } .dial .tick { stroke: #fff8; stroke-width: 2; }
.dial .mk.b { fill: var(--crimson-lit); } .dial .mk.k { fill: var(--gold-lit); }
#dialHand { stroke: var(--gold-lit); stroke-width: 5; stroke-linecap: round; } .dial .hub { fill: #13244a; stroke: var(--gold); stroke-width: 2; }
.dial text { fill: #fff; font: 800 17px var(--body); text-anchor: middle; } .dial text.u { font-size: 9px; fill: var(--dim); letter-spacing: .2em; }
/* awake */
.night { position: absolute; inset: -30% -60% -10% -60%; background: linear-gradient(#050a1c, #0d1a44); pointer-events: none; z-index: 3; }
.sun { position: absolute; width: 9vh; height: 9vh; border-radius: 50%; background: radial-gradient(#fffbe0, #ffd35a); box-shadow: 0 0 60px 20px #ffd35a88; transform: translate(-50%, 50%); z-index: 1; }
.s-awake .bld { z-index: 2; } .s-awake .aTroop { z-index: 4; }
.clock { position: absolute; left: 8%; right: 8%; top: 0; z-index: 6; background: #0b1630d9; border: 1px solid var(--line); border-radius: 14px; padding: 12px 18px; }
.clock > b { font: 900 clamp(18px, 2vw, 28px) var(--display); color: var(--gold-lit); }
.clock-bar { position: relative; height: 22px; border-radius: 11px; background: #ffffff1c; margin: 8px 0 4px; }
.clock-win { position: absolute; left: 54.17%; width: 20.83%; top: 0; bottom: 0; border-radius: 11px; background: linear-gradient(90deg, var(--gold), var(--gold-lit)); }
.clock-peak { position: absolute; left: 62.5%; top: -4px; bottom: -4px; width: 3px; background: var(--crimson); }
.clock-peak span { position: absolute; bottom: 130%; left: 50%; transform: translateX(-50%); white-space: nowrap; font: 800 11px var(--body); background: var(--crimson); padding: 2px 7px; border-radius: 5px; }
#aCur { position: absolute; top: -6px; bottom: -6px; width: 4px; margin-left: -2px; border-radius: 2px; background: #fff; box-shadow: 0 0 10px #fff; }
.clock-ticks { display: flex; justify-content: space-between; font: 700 11px var(--body); color: var(--dim); }
/* ark */
.pyr { position: absolute; bottom: 14%; width: 34%; aspect-ratio: 1.5; background: linear-gradient(100deg, #e9c27a 50%, #b98a48 50%); clip-path: polygon(50% 0, 100% 100%, 0 100%); opacity: .8; }
.pyr.b { width: 24%; bottom: 16%; opacity: .6; }
.matches { position: absolute; left: 50%; right: 7%; top: 0; display: grid; gap: 9px; z-index: 6; }
.match { display: grid; grid-template-columns: 62px 1fr auto; gap: 10px; align-items: center; background: #0b1630d9; border: 1px solid var(--line); border-radius: 12px; padding: 8px 12px; }
.match small { font: 800 11px var(--body); color: var(--dim); text-transform: uppercase; letter-spacing: .06em; }
.mbar { display: flex; height: 28px; border-radius: 6px; overflow: hidden; font: 800 13px/28px var(--body); }
.mbar i { font-style: normal; padding: 0 8px; white-space: nowrap; } .mbar .us { background: linear-gradient(90deg, #2d6fd0, #6fb0ff); } .mbar .them { background: linear-gradient(90deg, #a52a20, #d9503f); text-align: right; }
.match em { font: 900 12px var(--body); font-style: normal; color: var(--ink); background: var(--gold-lit); padding: 4px 9px; border-radius: 6px; text-transform: uppercase; }
.match-foot { display: flex; gap: 12px; align-items: center; margin-top: 4px; } #arkShot { width: 46%; }
/* who */
.langs { position: absolute; left: 34%; right: 6%; top: 2%; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; z-index: 6; }
.langs span { background: #fff; color: #2a2114; font: 800 clamp(13px, 1.4vw, 19px) var(--body); padding: 9px 18px; border-radius: 999px; box-shadow: 0 6px 16px #0007; }
.langs span:nth-child(odd) { background: var(--gold-lit); }

/* ================= CONTENT PAGES ================= */
.wrap { max-width: 1280px; margin: 0 auto; padding: 56px 18px 80px; }
@media (min-width: 1700px) { .page .wrap { zoom: 1.12; } }   /* big monitors: the content grows with the screen instead of sitting in a narrow strip */
@media (min-width: 2300px) { .page .wrap { zoom: 1.3; } }
.reveal { opacity: 0; transform: translateY(40px); transition: opacity .5s, transform .6s cubic-bezier(.2, .8, .2, 1); }
.reveal.in { opacity: 1; transform: none; }
.sec-head { margin: 56px 0 22px; max-width: 70ch; }
.sec-head:first-child { margin-top: 0; }
.sec-head h2 { font-size: clamp(26px, 3.4vw, 42px); color: var(--parch); margin: 6px 0 8px; }
.sec-head p, .book header p { color: var(--dim); }
.page-head { position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: end; gap: 3vw; padding: 5vh 6vw 0; min-height: 52vh;
  background: radial-gradient(80% 90% at 30% 100%, #2b4a8f, #13244a 55%, #0b1630); border-bottom: 3px solid var(--gold); }
#penalties .page-head { background: radial-gradient(80% 90% at 30% 100%, #7a2418, #3a120c 55%, #150806); border-color: var(--crimson); }
.ph-art { position: relative; height: 46vh; display: flex; justify-content: center; align-items: flex-end; }
.ph-art img { height: 100%; width: auto; max-width: none; filter: drop-shadow(0 14px 12px #000a); animation: stepin .8s .75s both cubic-bezier(.2, 1.3, .4, 1); }
.ph-art .prop { position: absolute; right: 2%; bottom: 0; height: 48%; animation-delay: .95s; }
@keyframes stepin { from { transform: translateY(60%); opacity: 0; } }
.ph-txt { padding-bottom: 6vh; animation: stepin .7s .85s both; }
.ph-txt h1 { font-size: clamp(40px, 6.4vw, 92px); font-weight: 900; color: var(--parch); text-shadow: 0 5px 0 #0009; margin: 8px 0 14px; }
.ph-txt p { color: #d5dcf0; max-width: 56ch; font-size: 17px; }
.subnav { position: sticky; top: var(--bar); z-index: 20; display: flex; gap: 6px; overflow-x: auto; padding: 10px 0; margin-bottom: 26px; background: linear-gradient(var(--navy) 80%, transparent); scrollbar-width: none; }
.subnav a { flex: none; padding: 7px 13px; border-radius: 999px; font: 700 13px var(--body); color: var(--dim); text-decoration: none; border: 1px solid #ffffff1f; }
.subnav a:hover { color: var(--ink); background: var(--gold-lit); }
.book { background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-radius: 18px; padding: 22px; margin-bottom: 22px; scroll-margin-top: 130px; }
.book > header { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.book > header img { width: 84px; height: 84px; object-fit: contain; flex: none; filter: drop-shadow(0 6px 6px #0008); }
.book h2 { font-size: clamp(22px, 2.6vw, 32px); color: var(--parch); margin-bottom: 4px; }
.note { background: #e9b9491c; border-left: 4px solid var(--gold); border-radius: 0 10px 10px 0; padding: 10px 14px; margin: 0 0 14px; font-size: 15px; }
.note.red { background: #c0382c26; border-color: var(--crimson); }
.tbl { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
.tbl th { font: 800 11px var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); text-align: left; padding: 8px 10px; white-space: nowrap; }
.tbl th img { display: inline-block; width: 26px; vertical-align: middle; margin-right: 5px; }
.tbl td { padding: 10px; border-top: 1px solid #ffffff14; white-space: nowrap; }
.tbl tr.top1 td { background: #e9b94914; }
.rank { font: 800 16px var(--display); color: var(--parch); }
.num { font-weight: 800; font-variant-numeric: tabular-nums; }
.award { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; }
.award img { width: 40px; height: 30px; object-fit: contain; }
.a-legendary { color: var(--gold-lit); } .a-epic { color: #d4a5ff; } .a-elite { color: #8fc0ff; } .a-advanced { color: #9fe0a8; }
.extra { margin-left: 8px; font: 800 11px var(--body); background: var(--gold-lit); color: var(--ink); padding: 3px 8px; border-radius: 6px; }
.book.reveal tbody tr { opacity: 0; transform: translateX(-24px); transition: .5s; }
.book.reveal.in tbody tr { opacity: 1; transform: none; }
.book.in tbody tr:nth-child(2) { transition-delay: .08s; } .book.in tbody tr:nth-child(3) { transition-delay: .16s; } .book.in tbody tr:nth-child(4) { transition-delay: .24s; }
.book.in tbody tr:nth-child(5) { transition-delay: .32s; } .book.in tbody tr:nth-child(6) { transition-delay: .4s; } .book.in tbody tr:nth-child(7) { transition-delay: .48s; }
/* penalty ladders */
.pen { background: linear-gradient(#2a1614, #170c0c); border-color: #c0382c55; }
.ladder-steps { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.step { position: relative; background: #ffffff0d; border: 1px solid #ffffff1f; border-top: 4px solid var(--gold); border-radius: 12px; padding: 14px; opacity: 0; transform: translateY(26px) scale(.96); transition: .5s calc(var(--i) * .14s + .15s); }
.pen.in .step { opacity: 1; transform: none; }
.step:nth-child(2) { border-top-color: #f08a3c; } .step:nth-child(3) { border-top-color: #e2603a; }
.step.final { border-color: var(--crimson); border-top-color: var(--crimson); background: linear-gradient(#c0382c40, #c0382c14); }
.when { font: 800 11px var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.step.final .when { color: var(--crimson-lit); }
.step h3 { font-size: 19px; color: var(--parch); margin: 6px 0 10px; }
.step p { font-size: 14px; color: #d9cfcb; }
.fine { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 8px; }
.fine span { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--dim); }
.fine img { width: 24px; } .fine b { color: #fff; font-size: 15px; }
/* closers */
.closer { display: flex; align-items: center; gap: 26px; margin-top: 56px; padding: 26px; border-radius: 18px; background: linear-gradient(100deg, #1c3466, #13244a); border: 1px solid var(--line); }
.closer > img { height: 190px; width: auto; flex: none; filter: drop-shadow(0 10px 10px #0008); }
.closer h3 { font-size: clamp(22px, 2.8vw, 34px); color: var(--gold-lit); margin-bottom: 8px; }
.closer p { color: #d5dcf0; margin-bottom: 14px; max-width: 62ch; }
/* leadership */
.tagbtn { display: inline-flex; flex-direction: column; align-items: flex-start; padding: 6px 12px; border-radius: 8px; background: #ffffff12; border: 1px dashed #ffffff40; font: 800 15px var(--body); font-variant-numeric: tabular-nums; }
.tagbtn small { font: 700 10px var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.tagbtn:hover, .tagbtn.done { background: var(--gold-lit); color: var(--ink); } .tagbtn:hover small, .tagbtn.done small { color: #5a3a08; }
.tags { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tags li { font: 700 12px var(--body); padding: 4px 10px; border-radius: 999px; background: #e9b94922; color: var(--gold-lit); border: 1px solid var(--line); }
.king { position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 300px) 1fr; gap: 24px; align-items: center; padding: 24px; border-radius: 18px; background: linear-gradient(100deg, #4a3410, #1c2a52 60%); border: 2px solid var(--gold); margin-bottom: 22px; }
.king h2 { font-size: clamp(34px, 5vw, 60px); color: var(--gold-lit); margin: 4px 0 10px; }
.king-art { position: absolute; right: 2%; bottom: -8%; height: 118%; width: auto; max-width: none; opacity: .9; filter: drop-shadow(0 10px 10px #0008); }
.king > div { position: relative; z-index: 1; max-width: 60%; }
.lead-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.lead { position: relative; overflow: hidden; background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.lead .shot { margin-bottom: 12px; } .lead h3 { font: 800 19px var(--body); margin: 2px 0 8px; }
.lead-art { position: absolute; right: -14px; bottom: -10px; height: 130px; width: auto; max-width: none; opacity: .5; pointer-events: none; transition: .3s; }
.lead:hover .lead-art { opacity: 1; transform: scale(1.1); }
.lead .tags, .lead .dim { position: relative; max-width: 78%; }
.track { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.track article { background: #16284f; border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.track header { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; } .track header small { color: var(--gold); font-weight: 800; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.track button { display: block; width: 100%; text-align: left; padding: 10px; border-radius: 10px; background: #ffffff0d; margin-top: 6px; transition: .2s; }
.track button:hover { background: #ffffff1f; } .track button span { display: block; font-size: 13px; color: var(--dim); } .track button em { font: 800 11px var(--body); font-style: normal; color: var(--gold-lit); text-transform: uppercase; letter-spacing: .08em; }
/* migrations / farms / sellers */
.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.card, .req, .seller { background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-radius: 16px; padding: 20px; }
.card h3, .req h3, .seller h3, .farm h3 { font-size: 22px; color: var(--parch); margin-bottom: 8px; }
.card p { color: var(--dim); margin-bottom: 12px; } .card .door { margin-top: 10px; } .card .tagbtn { margin-right: 10px; }
.reqs { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.req { position: relative; overflow: hidden; padding-right: 110px; min-height: 150px; }
.req > img { position: absolute; right: -8px; bottom: -8px; width: 120px; height: 120px; object-fit: contain; filter: drop-shadow(0 6px 8px #0008); transition: .3s; }
.req:hover > img { transform: scale(1.12) rotate(-4deg); }
.req p { color: #d5dcf0; font-size: 15px; } .req p b { color: var(--gold-lit); font-size: 1.15em; } .req .door { margin-top: 14px; }
.farm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.farm { display: grid; grid-template-columns: 110px 1fr; gap: 14px; background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-left: 5px solid var(--dim); border-radius: 14px; padding: 14px; }
.farm.top { border-left-color: var(--gold-lit); } .farm.mid { border-left-color: #8fc0ff; }
.farm h3 { font-size: 19px; margin: 2px 0; } .tech { font-size: 13px; font-weight: 700; color: var(--gold-lit); margin-bottom: 8px; } .farm.low .tech { color: var(--dim); }
.farm dl { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; font-size: 13px; } .farm dt { color: var(--dim); font-size: 11px; } .farm dd { margin: 0; font-weight: 800; }
.sellers { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 16px; }
.ids { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; } .shots { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; align-items: start; }
.foot { text-align: center; padding: 30px 18px 40px; border-top: 1px solid var(--line); color: var(--dim); font-size: 14px; display: grid; gap: 4px; }
.foot b { color: var(--parch); font-family: var(--display); } .foot small { opacity: .7; }
#lightbox { position: fixed; inset: 0; z-index: 100; background: #000d; display: grid; place-items: center; padding: 20px; cursor: zoom-out; }
#lightbox[hidden] { display: none; } #lightbox img { max-height: 92vh; border-radius: 12px; }

/* ================= SMALL SCREENS ================= */
@media (max-width: 860px) {
  :root { --bar: 96px; }
  .topbar { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; padding: 8px 10px 6px; height: var(--bar); } .topbar .nav { grid-column: 1 / -1; grid-row: 2; }
  .brand img { width: 32px; height: 32px; } .nav { margin-left: 0; } .nav button { padding: 7px 11px; font-size: 13px; }
  .art { left: 0; width: 100%; height: 50%; bottom: 13%; }
  .art.wide { height: 46%; bottom: 0; } .s-who .art, .s-fin .art { bottom: 10%; }
  .ttl { left: 16px; right: 16px; width: auto; top: calc(var(--bar) + 4vh + 62px); }
  .ttl h2 { font-size: clamp(30px, 9vw, 44px); margin: 4px 0 4px; } .ttl p { font-size: 14px; }
  .s-hist .ttl h2, .s-baul .ttl h2, .s-awake .ttl h2 { font-size: 26px; }
  .chat { left: 4px; bottom: calc(4vh + 4px); width: calc(100% - 8px); gap: 2px; }
  .msg p { font-size: 13px; padding: 9px 12px 9px 16px; margin: 0 0 8px -8px; border-width: 2px; } .msg.r p { padding: 9px 16px 9px 12px; margin: 0 -8px 8px 0; }
  .msg p > b { font-size: 10px; margin-top: -19px; padding: 4px 8px; } .av { width: 66px; height: 78px; }
  .hud { gap: 4px; top: calc(var(--bar) + 4vh + 4px); width: calc(100% - 12px); } .rec small { font-size: 9px; } .rec b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .rec { min-width: 0; flex: 1; padding: 4px; } .rec b { font-size: 11px; }
  .chapters { display: none; }
  .hero-mid { top: calc(var(--bar) + 1vh); } .hero-logo { width: min(70vw, 30vh); } .hero-mid p { font-size: 14px; margin-bottom: 12px; }
  .hero-stats { margin-top: 2vh; gap: 6px; } .hero-stats span { font-size: 10.5px; }
  .s-hero .art { height: 34%; bottom: 0; } #h2, #h4 { display: none; } .hero-chat { display: none; }
  .door { padding: 11px 16px; font-size: 13px; }
  .stamp { top: 6%; padding: 6px 16px 8px; } .stamp.small { top: 34%; }
  .tally { left: 4%; width: 92%; top: -8%; grid-template-columns: 1fr 1fr; } .vs { padding: 6px 8px; gap: 6px; } .vs span { font-size: 10px; } .vs span br { display: none; }
  .bars { right: 3%; width: 54%; top: -6%; gap: 6px; } .bgrp { padding: 6px 8px 8px; } .bar { height: 24px; margin-top: 5px; } .bar b { font-size: 12px; } .bar em { font-size: 9px; } #k4shot { display: none; }
  .ladder { left: 3%; top: -4%; width: 96px; } .ladder span { padding: 4px 6px; font-size: 11px; } .ladder i { right: -18px; }
  .seedline { top: -8%; } .seedline span { padding: 5px 8px; font-size: 11px; } .seedline b { font-size: 16px; }
  .roster { left: 40%; right: 3%; top: -4%; gap: 6px; } .seeds th { padding: 4px 5px; font-size: 8px; } .seeds td { padding: 3px 5px; font-size: 10.5px; } .dots { gap: 2px; } .count { gap: 6px; } .count span { font-size: 11px; }
  .keepcard { left: 56%; width: 42%; bottom: 24%; } .plate { padding: 6px 8px; } .plate > div { flex-direction: column; gap: 4px; } .utc { padding: 3px 6px; font-size: 10px; } .utc b { font-size: 12px; }
  #plB { left: 23% !important; bottom: 68% !important; } #plK { left: 77% !important; bottom: 68% !important; } .dial { width: 12vh; left: 50%; top: 36%; }
  .clock { left: 3%; right: 3%; top: -12%; padding: 8px 12px; }
  .matches { left: 40%; right: 3%; top: -10%; gap: 5px; } .match { grid-template-columns: 1fr auto; padding: 5px 8px; gap: 5px; } .match small { display: none; } .mbar { height: 22px; font-size: 11px; line-height: 22px; } .match em { font-size: 9px; padding: 3px 5px; }
  .match-foot { flex-direction: column; align-items: stretch; gap: 6px; } #arkShot { display: none; }
  .langs { left: 3%; right: 3%; top: -30%; gap: 6px; } .langs span { padding: 6px 12px; font-size: 12px; }
  .s-fin .ttl p { font-size: 13px; } .fin-cta { gap: 6px; } .fin-cta .door { padding: 9px 12px; font-size: 11px; } #k4stamp { left: 70%; top: 50%; }
  .page-head { grid-template-columns: 1fr; padding: 3vh 18px 0; min-height: 0; } .ph-art { height: 30vh; order: 2; } .ph-txt { padding-bottom: 1vh; }
  .closer { flex-direction: column; text-align: center; } .closer > img { height: 150px; } .closer .hero-cta { justify-content: center; }
  .king { grid-template-columns: 1fr; } .king > div { max-width: 100%; } .king-art { opacity: .25; }
  .book { padding: 16px 14px; } .book > header img { width: 60px; height: 60px; }
}
@media (prefers-reduced-motion: reduce) { .wipe-run img, .horde .run img, .scroll-hint i { animation: none; } }
@media (min-width: 861px) { #k3stamp { left: 30%; top: 24%; } #k4stamp { left: 43%; top: 36%; } }

/* ================= GATE + LOGO ================= */
.logo { display: block; width: 100%; height: auto; overflow: visible; filter: drop-shadow(0 14px 22px #000a); }
body.gated { overflow: hidden; }
#gate { position: fixed; inset: 0; z-index: 90; overflow: hidden; text-align: center; background: linear-gradient(#050b1c 0, #0e2350 55%, #173a78 100%); cursor: pointer; }
#forest { position: absolute; inset: 0; }
.moon { position: absolute; left: 50%; top: 30%; width: 90vmin; height: 90vmin; margin: -45vmin 0 0 -45vmin; border-radius: 50%; background: radial-gradient(circle, #9fd0ff66 0, #4f8fe033 30%, transparent 65%); }
.fl { position: absolute; left: 0; bottom: 0; width: 100%; height: 100%; transform-origin: 50% 72%; }
.f1 { height: 62%; opacity: .85; } .f2 { height: 82%; }
.fog { position: absolute; left: -30%; right: -30%; bottom: 0; height: 46%; background: radial-gradient(60% 100% at 30% 100%, #bfe0ff40, transparent 70%), radial-gradient(50% 90% at 75% 100%, #bfe0ff33, transparent 70%); filter: blur(12px); animation: drift 14s ease-in-out infinite alternate; }
.fog.b { height: 30%; animation-duration: 9s; animation-direction: alternate-reverse; }
@keyframes drift { to { transform: translateX(8%); } }
.eyes { position: absolute; left: 50%; top: 56%; width: 46px; margin-left: -23px; display: flex; justify-content: space-between; }
.eyes i { width: 13px; height: 8px; border-radius: 60% 60% 50% 50%; background: #bfe6ff; box-shadow: 0 0 14px 5px #4fb0ff, 0 0 40px 12px #2f7fe0; }
.wolf { position: absolute; left: 50%; top: 50%; width: 46vmin; height: 46vmin; margin: -23vmin 0 0 -23vmin; border-radius: 50%; overflow: hidden; -webkit-mask: radial-gradient(circle, #000 50%, transparent 70%); mask: radial-gradient(circle, #000 50%, transparent 70%); }
.wolf img { position: absolute; width: 184%; max-width: none; left: -42%; top: -28%; }
#ice { position: absolute; inset: 0; pointer-events: none; z-index: 4; }
#gateFlash { position: absolute; inset: 0; background: radial-gradient(circle, #fff 0, #bfe6ff 40%, #6fb8ff 100%); pointer-events: none; z-index: 5; }
.lockup { position: absolute; left: 0; right: 0; top: 50%; display: grid; justify-items: center; gap: 1.2vmin; z-index: 3; pointer-events: none; }
.crest-wrap { position: relative; width: min(46vmin, 320px); aspect-ratio: 1; filter: drop-shadow(0 0 40px #4f9fffaa); }
.crest-wrap img { position: absolute; inset: 0; width: 100%; }
.crest-a { clip-path: polygon(0 0, 35% 0, 35% 20.5%, 65% 20.5%, 65% 0, 100% 0, 100% 100%, 0 100%); }
.crest-b { clip-path: inset(0 35% 79.5% 35%); filter: drop-shadow(0 0 14px #ffd978); }
.ring { position: absolute; inset: 0; border-radius: 50%; border: 5px solid #cfeaff; box-shadow: 0 0 40px 10px #6fb8ffaa, inset 0 0 30px #6fb8ffaa; }
.kd { font: 800 clamp(13px, 2.6vmin, 24px) 'Cinzel', serif; color: #cfe6ff; text-shadow: 0 0 18px #4f9fff; padding-left: .5em; }
.digits { display: flex; gap: .06em; font: 900 clamp(64px, 17vmin, 190px)/.95 'Cinzel', serif; direction: ltr; }
.digits b { display: block; background: linear-gradient(#ffffff 8%, #cfe6ff 38%, #6ea4e6 62%, #dff0ff 100%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 5px 0 #0a1a3c) drop-shadow(0 0 22px #4f9fff); }
.gate-in { position: absolute; left: 0; right: 0; margin: 0 auto; bottom: 9vh; width: min(94vw, 720px); display: grid; gap: 14px; justify-items: center; z-index: 6; cursor: default; }
.gate-sub { font: 800 13px var(--body); letter-spacing: .08em; color: #cfe6ff; }
.gate-langs { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.gate-langs button { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-radius: 14px; font: 800 17px 'Manrope', 'Cairo', sans-serif; color: #fff; background: #0b1630cc; border: 2px solid #6fb8ff88; backdrop-filter: blur(6px); transition: .15s; box-shadow: 0 8px 24px #0008; }
.gate-langs button:hover { background: #1c3466; border-color: var(--gold-lit); transform: translateY(-3px); }
.gate-langs .flag-ic { width: 36px; height: 24px; }
.lang-menu button { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; font: 700 14px var(--body); background: #ffffff12; border: 1.5px solid #ffffff26; transition: .15s; }
.lang-menu button:hover { background: #ffffff26; }
.gate-langs button.on, .lang-menu button.on { border-color: var(--gold-lit); color: var(--gold-lit); }
.cine-rays, .rays { position: absolute; left: 50%; top: 42%; width: 240vmax; height: 240vmax; margin: -120vmax 0 0 -120vmax; pointer-events: none;
  background: repeating-conic-gradient(from 0deg, #ffe9a800 0 7deg, #ffe9a822 9deg 12deg, #ffe9a800 14deg 20deg);
  -webkit-mask: radial-gradient(circle, #000 0, transparent 46%); mask: radial-gradient(circle, #000 0, transparent 46%); animation: spin 90s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.flag-ic { width: 27px; height: 18px; border-radius: 3px; flex: none; box-shadow: 0 0 0 1px #0006; }
.credit { font: 700 12px var(--body); letter-spacing: .12em; color: var(--gold); opacity: .85; }
#gate .credit { position: absolute; left: 0; right: 0; bottom: 18px; z-index: 6; }
/* top-bar tools */
.tools { display: flex; align-items: center; gap: 6px; flex: none; }
.lang { position: relative; }
.lang-btn, .snd { display: flex; align-items: center; gap: 7px; height: 36px; padding: 0 10px; border-radius: 10px; background: #ffffff12; border: 1px solid var(--line); font: 800 12px var(--body); }
.lang-btn:hover, .snd:hover { background: #ffffff26; }
.lang-menu { position: absolute; right: 0; top: 44px; display: none; gap: 6px; padding: 8px; border-radius: 12px; background: #0b1630f5; border: 1px solid var(--line); box-shadow: 0 16px 40px #000a; min-width: 170px; }
.lang.open .lang-menu { display: grid; }
.snd svg { width: 20px; height: 20px; } .snd { color: var(--dim); } .snd[aria-pressed="true"] { color: var(--gold-lit); border-color: var(--gold-lit); }
.snd[aria-pressed="true"] .x, .snd[aria-pressed="false"] .w { display: none; }

/* ================= CINEMA ================= */
.lb { position: absolute; left: 0; right: 0; height: 4vh; background: #000; z-index: 38; pointer-events: none; }
.lb.top { top: var(--bar); transform-origin: 50% 0; } .lb.bot { bottom: 0; transform-origin: 50% 100%; }
.fx-vig { position: absolute; inset: 0; z-index: 24; pointer-events: none; background: radial-gradient(120% 90% at 50% 45%, transparent 52%, #000b 100%); }
.fx-grain { position: absolute; inset: -50%; z-index: 26; pointer-events: none; opacity: .09; mix-blend-mode: overlay; animation: grain .6s steps(4) infinite;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E"); }
@keyframes grain { 0% { transform: translate(0, 0); } 25% { transform: translate(-4%, 3%); } 50% { transform: translate(3%, -5%); } 75% { transform: translate(-2%, -3%); } }
.scene .rays { left: 78%; top: 30%; opacity: .55; mix-blend-mode: screen; animation-duration: 140s; z-index: 1; }
.s-hist .rays, .s-baul .rays, .s-who .rays { opacity: .25; }
.army { position: absolute; inset: 0; z-index: 2; }
.army img { position: absolute; width: auto; max-width: none; filter: brightness(.12) saturate(.4) blur(.6px); opacity: .8; }
.s-k1 .army, .s-k4 .army { -webkit-mask: linear-gradient(90deg, transparent 30%, #000 60%); mask: linear-gradient(90deg, transparent 30%, #000 60%); }
.scene .bg::after { z-index: 3; }
.cine { position: absolute; inset: 0; z-index: 36; overflow: hidden; pointer-events: none;
  background: radial-gradient(60% 80% at 68% 46%, #f0b45a 0, #a8571f 28%, #3a1a0c 60%, #0b0605 100%); }
.cine-rays { left: 68%; top: 40%; mix-blend-mode: screen; opacity: .9; animation: none; }
.cine-hero { position: absolute; right: 4vw; top: 7vh; height: 150vh; width: auto; max-width: none; transform-origin: 50% 30%;
  filter: drop-shadow(-30px 0 50px #000c) drop-shadow(0 0 26px #ffd97855) contrast(1.08) saturate(1.1); }
.cine::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, #0b0605f0 0, #0b060580 34%, transparent 62%), linear-gradient(0deg, #0b0605 0, transparent 30%); }
.cine-txt { position: absolute; left: 7vw; top: 50%; transform: translateY(-50%); z-index: 2; }
.cine-txt small { display: block; font: 800 clamp(11px, 1.2vw, 16px) var(--body); letter-spacing: .34em; text-transform: uppercase; color: var(--gold); }
.cine-txt b { display: block; font: 900 clamp(54px, 11vw, 170px)/.95 var(--display); color: var(--parch); text-shadow: 0 8px 0 #000a, 0 0 60px #f0b45a66; margin: 10px 0; }
.cine-txt em { display: inline-block; font: 800 clamp(16px, 2vw, 28px) var(--display); font-style: normal; color: var(--ink); background: linear-gradient(#ffe394, #e0a93a); padding: 6px 18px; border-radius: 6px; }
.cine-slash { position: absolute; left: -10%; top: 46%; width: 120%; height: 10px; z-index: 3; transform: rotate(-14deg); background: linear-gradient(90deg, transparent, #fff 40%, #ffe9a8 60%, transparent); box-shadow: 0 0 40px 12px #ffe9a8aa; }

/* ================= LANGUAGES ================= */
html[lang="ar"] { --display: 'Cairo', sans-serif; --body: 'Cairo', sans-serif; }
html[lang="vi"] { --display: 'Playfair Display', Georgia, serif; }
.rtl .wrap, .rtl .page-head, .rtl .ttl, .rtl .msg p, .rtl .hero-fade, .rtl .closer, .rtl .foot, .rtl .gate-in, .rtl .cine-txt, .rtl .plate, .rtl .stamp, .rtl .tally, .rtl .bgrp, .rtl .clock, .rtl .tag, .rtl .wipe-txt { direction: rtl; }
.rtl .kick, .rtl .gate-sub, .rtl .cine-txt small, .rtl .stamp small, .rtl .when, .rtl .tbl th { letter-spacing: 0; }
.rtl .tbl th, .rtl .seeds th { text-align: right; } .rtl .note { border-left: 0; border-right: 4px solid var(--gold); border-radius: 10px 0 0 10px; } .rtl .note.red { border-right-color: var(--crimson); }
.rtl .tagbtn { direction: ltr; } .rtl .ttl { text-align: right; }
@media (max-width: 860px) {
  .lang-btn, .snd { height: 32px; padding: 0 8px; } .cine-hero { right: -34vw; height: 110vh; top: 26vh; } .cine-txt { left: 5vw; top: 34%; }
  .gate-langs button { padding: 11px 14px; font-size: 15px; } .gate-langs { display: grid; grid-template-columns: 1fr 1fr; width: 100%; } .gate-sub { font-size: 11px; }
}
@media (max-width: 860px) { .s-fin .ttl { top: calc(var(--bar) + 4vh + 62px); } }

/* intro: patrol in the mist, title cards, letterbox */
#gate { background: linear-gradient(#03070f 0, #08152f 50%, #10294f 100%); }
.walkers { position: absolute; inset: 0; transform-origin: 50% 80%; }
.wk { position: absolute; transform: translateX(-50%); animation: wkstep 1.1s ease-in-out infinite alternate; }
.wk img { height: 100%; width: auto; max-width: none; filter: brightness(.16) saturate(.4) sepia(1) hue-rotate(180deg) drop-shadow(0 0 10px #0a1730); }
@keyframes wkstep { to { transform: translateX(-50%) translateY(-1.1vh) rotate(1.2deg); } }
.torch { position: absolute; left: 82%; top: 4%; width: 1.3vh; height: 1.3vh; border-radius: 50%; background: #ffe9a8; box-shadow: 0 0 2.4vh 1.2vh #ff9a3c, 0 0 9vh 4vh #ff7a1a66; animation: flick .19s infinite alternate; }
@keyframes flick { to { opacity: .72; transform: scale(.82) translateY(-2px); } }
.redmist { position: absolute; left: -20%; right: -20%; bottom: 0; height: 40%; filter: blur(16px); animation: drift 11s ease-in-out infinite alternate;
  background: radial-gradient(55% 100% at 35% 100%, #a8243a99, transparent 70%), radial-gradient(50% 90% at 72% 100%, #8a1c3088, transparent 70%); }
.credits { position: absolute; left: 0; right: 0; top: 44%; z-index: 4; pointer-events: none; }
.credits span { position: absolute; left: 0; right: 0; font: 600 clamp(13px, 2.3vw, 30px) 'Cinzel', serif; letter-spacing: .62em; padding-left: .62em; color: #dfe9f7; text-shadow: 0 0 22px #000, 0 2px 8px #000; }
.glb { position: absolute; left: 0; right: 0; height: 10vh; background: #000; z-index: 5; pointer-events: none; }
.glb.top { top: 0; transform-origin: 50% 0; } .glb.bot { bottom: 0; transform-origin: 50% 100%; }
#gate .credit { z-index: 7; }

.yt-music { justify-self: center; margin: 10px 0 4px; border-radius: 8px; overflow: hidden; opacity: .8; line-height: 0; }
/* short landscape windows: everything a size smaller so nothing stacks */
@media (max-height: 640px) and (min-width: 861px) {
  .ttl { top: calc(var(--bar) + 4vh + 48px); } .ttl h2 { font-size: clamp(26px, 7vh, 44px); margin: 2px 0 4px; } .ttl p { font-size: 14px; }
  .s-hist .ttl h2, .s-baul .ttl h2, .s-awake .ttl h2 { font-size: clamp(20px, 5vh, 30px); }
  .chat { width: min(400px, 44vw); gap: 0; bottom: calc(4vh + 4px); }
  .msg p { font-size: 12.5px; line-height: 1.3; padding: 8px 12px 8px 16px; margin-bottom: 6px; } .msg.r p { padding: 8px 16px 8px 12px; margin-bottom: 6px; }
  .msg p > b { font-size: 9.5px; padding: 3px 7px; margin: -17px 0 4px -2px; } .av { width: 62px; height: 70px; }
  .rec { padding: 3px 8px 4px; min-width: 78px; } .rec b { font-size: 11px; }
  .vs { padding: 4px 12px; } .vs b { font-size: 24px; } .tally { gap: 4px; }
  .bgrp { padding: 6px 10px 8px; } .bar { height: 24px; margin-top: 5px; } .bars { gap: 6px; } #k4shot { display: none; }
  .seeds th { padding: 4px 8px; } .roster { gap: 6px; } .dots { width: min(100%, 36vh); gap: 3px; }
  .plate { padding: 5px 8px; } .utc small { display: none; } .dial { width: 18vh; }
  .match { padding: 4px 10px; } .matches { gap: 4px; } .mbar { height: 22px; line-height: 22px; font-size: 12px; } #arkShot { display: none; }
  .hero-logo { width: min(40vw, 30vh); } .hero-mid p { font-size: 13px; margin-bottom: 8px; } .hero-stats { margin-top: 1vh; } .hero-stats li { padding: 5px; } .hero-stats span { display: none; }
  .hero-chat, .scroll-hint { display: none; }
}

/* phones: drop the heavy layers (rotating light, grain, blurred armies, per-figure shadows) that exhaust mobile browser memory */
@media (max-width: 860px), (pointer: coarse) {
  .rays, .cine-rays, .fx-grain, .army { display: none !important; }
  .ch, .wk img, .cine-hero, .wipe-host, .wipe-run img, .horde .run img, .ph-art img, .closer > img { filter: none !important; }
  .ch.foe { filter: brightness(.55) saturate(.6) !important; }
  .wk img { filter: brightness(.16) !important; }
  .msg { filter: none; } .msg p { box-shadow: 0 6px 14px #0008, inset 0 -3px 0 #e3c779; }
  .fog, .redmist { filter: blur(8px); animation: none; }
  .av img { animation: none; }
  .scene .bg { translate: none; } .art { translate: none; }
}

/* ===== phones: three fixed bands — title, picture, one speech bubble — so nothing can overlap ===== */
@media (max-width: 860px) {
  .hud { top: calc(var(--bar) + 4vh + 4px); } .rec { padding: 3px 4px; } .rec small { font-size: 8.5px; } .rec b { font-size: 10.5px; }
  .ttl { top: calc(var(--bar) + 4vh + 46px); left: 12px; right: 12px; }
  .ttl .kick { font-size: 10px; letter-spacing: .1em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .ttl h2 { font-size: 26px !important; margin: 2px 0 2px; line-height: 1.05; }
  .ttl p { font-size: 12.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .s-hist .ttl h2, .s-baul .ttl h2, .s-awake .ttl h2 { font-size: 19px !important; } .s-hist .ttl p, .s-baul .ttl p, .s-awake .ttl p { display: none; }
  .scene:not(.s-hero):not(.s-fin) .art, .scene:not(.s-hero):not(.s-fin) .art.wide { left: 0; width: 100%; top: calc(var(--bar) + 4vh + 132px); bottom: calc(4vh + 112px); height: auto; }
  .chat { display: grid; left: 4px; width: calc(100% - 8px); bottom: calc(4vh + 4px); }
  .chat .msg { grid-area: 1 / 1; align-self: end; } .chat .msg.r { justify-self: end; }
  .msg p { font-size: 12.5px; line-height: 1.3; padding: 8px 11px 8px 14px; margin: 0 0 6px -6px; max-height: 92px; overflow: hidden; } .msg.r p { padding: 8px 14px 8px 11px; margin: 0 -6px 6px 0; }
  .msg p > b { font-size: 9.5px; margin: -17px 0 4px -2px; padding: 3px 7px; } .av { width: 58px; height: 68px; }
  /* widgets sit at the top of the picture band */
  .tally { left: 2%; width: 96%; top: 0; gap: 4px; } .vs { padding: 4px 6px; gap: 4px; } .vs b { font-size: 20px; } .vs span { font-size: 9.5px; line-height: 1.15; }
  .flag { font-size: 13px; padding: 4px 9px 11px; }
  .seedline { top: 0; left: 2%; } .tag { font-size: 10px; padding: 4px 7px; }
  .ladder { left: 2%; top: 0; width: 88px; gap: 3px; } .bars { right: 2%; width: 58%; top: 0; gap: 4px; } .bgrp { padding: 4px 7px 6px; } .bgrp small { font-size: 9px; } .bar { height: 20px; margin-top: 4px; } .bar b { font-size: 11px; }
  .stamp { top: 34%; padding: 4px 12px 6px; border-width: 4px; } .stamp b { font-size: 26px; } .stamp small { font-size: 9px; letter-spacing: .1em; } .stamp.small { top: 52%; left: 60%; } .stamp.small b { font-size: 20px; }
  #k4stamp { left: 72%; top: 62%; }
  .roster { left: 38%; right: 2%; top: 0; gap: 4px; } .seeds th { font-size: 7.5px; padding: 3px 4px; } .seeds td { font-size: 10px; padding: 2px 4px; }
  .count b { font-size: 26px; } .count span { font-size: 10px; } .count em { font-size: 10px; padding: 2px 6px; } .dots { width: min(100%, 26vh); gap: 2px; }
  #plB { left: 24% !important; top: 0; bottom: auto !important; } #plK { left: 76% !important; top: 0; bottom: auto !important; }
  .plate { padding: 4px 6px; } .plate > b { font-size: 12px; } .plate > small { font-size: 10px; } .plate > div { flex-direction: row; gap: 4px; margin-top: 4px; } .utc { padding: 2px 5px; font-size: 9px; } .utc b { font-size: 11px; } .utc small { display: none; }
  .dial { width: 10vh; left: 50%; top: 30%; } .keepcard { left: 58%; width: 40%; bottom: 14%; border-width: 2px; }
  .clock { left: 2%; right: 2%; top: 0; padding: 6px 10px; } .clock > b { font-size: 15px; } .clock-bar { height: 14px; margin: 14px 0 3px; } .clock-ticks { font-size: 9px; }
  .matches { left: 34%; right: 2%; top: 0; gap: 3px; } .match { padding: 3px 6px; } .mbar { height: 18px; line-height: 18px; font-size: 10.5px; } .match-foot .door { padding: 7px 8px; font-size: 10px; }
  .langs { left: 2%; right: 2%; top: 0; gap: 5px; } .langs span { padding: 5px 10px; font-size: 11.5px; }
  .pod b { font-size: 16px; }
  .s-fin .ttl { top: calc(var(--bar) + 4vh + 46px); width: calc(100% - 24px); } .s-fin .ttl p { -webkit-line-clamp: 4; }
  .s-fin .art { top: auto; height: 32%; bottom: 5%; }
}
@media (max-width: 860px) {
  .msg p { max-height: none; overflow: visible; }
  .chat { bottom: 66px; }   /* clears the host's badge in the corner */
  .scene:not(.s-hero):not(.s-fin) .art, .scene:not(.s-hero):not(.s-fin) .art.wide { bottom: 176px; }
}
.scene .bg { isolation: isolate; }   /* the ground must never stack above the figures */
@media (max-width: 860px) { .hero-chat { display: none !important; } }
.yt-music { position: absolute; left: -9999px; width: 200px; height: 113px; opacity: 0; pointer-events: none; margin: 0; }   /* music player kept off-screen */
/* KVK 3: the result stamp sits in the empty left half, clear of the podium labels */
@media (min-width: 861px) { #k3stamp { left: 20%; top: 44%; } #k3stamp b { font-size: clamp(30px, 4vw, 58px); } }
@media (max-width: 860px) { #k3stamp { left: 27%; top: 58%; } }
#k4stamp small { display: block; max-width: 20ch; margin: 2px auto 0; letter-spacing: .08em; line-height: 1.25; }
@media (min-width: 861px) { #k4stamp { left: 40%; top: 40%; } #k4stamp b { font-size: clamp(30px, 4vw, 58px); } }

/* live DKP table */
.dkp-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 16px; }
.dkp-stats div { background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.dkp-stats span { display: block; font: 800 11px var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); } .dkp-stats b { font: 900 24px var(--display); color: var(--gold-lit); }
.dkp-tools { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.dkp-tools input { flex: 1 1 220px; padding: 11px 14px; border-radius: 10px; border: 1.5px solid #ffffff30; background: #0b1630; color: #fff; font: inherit; }
.dkp-chips { display: flex; gap: 6px; flex-wrap: wrap; } .dkp-chips button { padding: 8px 13px; border-radius: 999px; font: 700 13px var(--body); color: var(--dim); border: 1px solid #ffffff26; }
.dkp-chips button.on { color: var(--ink); background: var(--gold-lit); border-color: var(--gold-lit); }
.dkp-wrap { max-height: 72vh; overflow: auto; border: 1px solid var(--line); border-radius: 14px; background: #101d3c; margin-bottom: 40px; }
.dkp-table th { position: sticky; top: 0; background: #0b1630; z-index: 1; } .dkp-table th.s { cursor: pointer; } .dkp-table th.s.on { color: #fff; } .dkp-table th.s.on::after { content: ' ↕'; }
.dkp-table td { padding: 8px 10px; } .dkp-table .gov b { display: block; font-weight: 800; } .dkp-table .gov small { color: var(--dim); font-size: 11px; }
.dkp-table td.dkp { color: var(--gold-lit); } .dkp-table tr.top td { background: #e9b94914; }
.meter { position: relative; width: 110px; height: 20px; border-radius: 6px; background: #ffffff1a; overflow: hidden; }
.meter i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #a52a20, #d9503f); } tr.ok .meter i { background: linear-gradient(90deg, #2f8f55, #7be39a); }
.meter span { position: relative; display: block; text-align: center; font: 800 12px/20px var(--body); text-shadow: 0 1px 2px #000; }
.admin-link { font: 700 12px var(--body); color: var(--dim); text-decoration: none; opacity: .7; } .admin-link:hover { color: var(--gold-lit); opacity: 1; }
.rtl .dkp-table th { text-align: right; }

/* ================= HOME ================= */
.home-hero { position: relative; overflow: hidden; display: grid; place-items: center; text-align: center; min-height: 46vh; padding: 3vh 16px 2vh; background: radial-gradient(80% 90% at 50% 100%, #2b4a8f, #13244a 55%, #0b1630); border-bottom: 3px solid var(--gold); }
.home-logo { width: min(78vw, 40vh, 420px); margin: 0 auto 6px; }
.home-hero > img { position: absolute; bottom: -4%; height: 92%; width: auto; max-width: none; filter: drop-shadow(0 14px 12px #000a); }
.hh-l { left: max(2vw, calc(50% - 560px)); } .hh-r { right: max(2vw, calc(50% - 560px)); }
.home-wrap { display: grid; gap: 20px; padding-top: 32px; }
.hcard { position: relative; background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-radius: 20px; padding: 24px; overflow: hidden; }
.hcard > header { margin-bottom: 16px; max-width: 70ch; } .hcard h2 { font-size: clamp(24px, 3.2vw, 38px); color: var(--parch); margin: 4px 0 8px; } .hcard header p { color: #d5dcf0; }
.hcard .hero-stats { margin: 0 0 18px; } .hcard .dim { margin-top: 14px; }
.hcard.baulur { background: linear-gradient(120deg, #2a3d1e, #13241a 60%); border: 2px solid var(--gold); }
.next { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 14px; padding: 14px 18px; border-radius: 14px; background: #0b1630cc; border: 1px solid var(--line); margin-bottom: 16px; }
.next span { font: 800 12px var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); } .next b { font: 900 clamp(18px, 2.4vw, 28px) var(--display); color: var(--parch); } .next em { font: 800 clamp(20px, 2.8vw, 32px) var(--body); font-style: normal; color: var(--gold-lit); font-variant-numeric: tabular-nums; margin-left: auto; direction: ltr; }
.bk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 14px; margin-bottom: 16px; }
.bk { display: flex; gap: 14px; align-items: center; background: #ffffff0d; border: 1px solid #ffffff22; border-radius: 16px; padding: 14px; }
.bk > img { height: 120px; width: auto; flex: none; filter: drop-shadow(0 8px 8px #0008); } .bk > img.sq { height: 96px; border-radius: 12px; border: 2px solid #6b4a1c; }
.bk h3 { font-size: 22px; color: var(--parch); } .bk small { color: var(--dim); }
.slots { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.slot { padding: 8px 12px; border-radius: 10px; background: #ffffff14; border: 1.5px solid transparent; } .slot b { display: block; font: 900 20px var(--body); } .slot small { color: var(--dim); font-size: 12px; }
.slot.on { background: var(--gold-lit); color: var(--ink); border-color: #fff; box-shadow: 0 0 22px #ffd97888; } .slot.on small { color: #5a3a08; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; } .chips span { background: #0b1630cc; border: 1px solid var(--line); border-radius: 10px; padding: 6px 12px; text-align: center; } .chips small { display: block; font: 800 10px var(--body); letter-spacing: .14em; color: var(--dim); } .chips b { font: 800 14px var(--body); }
.hcard.royal { background: linear-gradient(120deg, #4a3410, #1c2a52 60%); border: 2px solid var(--gold); }
.king-seal { position: absolute; right: -40px; top: -40px; width: 240px; opacity: .16; pointer-events: none; }
#kingForm { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; } #kingForm .wide { grid-column: 1 / -1; }
#kingForm label span { display: block; font: 800 12px var(--body); letter-spacing: .06em; color: var(--gold-lit); margin-bottom: 5px; }
#kingForm input, #kingForm textarea { width: 100%; padding: 12px 14px; border-radius: 10px; border: 1.5px solid #ffffff30; background: #0b1630; color: #fff; font: inherit; resize: vertical; }
#kingForm input:focus, #kingForm textarea:focus { outline: none; border-color: var(--gold-lit); }
.hp { position: absolute !important; left: -9999px; width: 1px !important; height: 1px; opacity: 0; }
.form-foot { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; } .form-msg { font-weight: 700; } .form-msg.ok { color: #7be39a; } .form-msg.err { color: var(--crimson-lit); }
.rtl .hcard, .rtl .home-hero { direction: rtl; }
@media (max-width: 860px) { .home-hero { min-height: 34vh; padding-top: calc(var(--bar) + 2vh); } .home-hero > img { height: 60%; opacity: .5; } .hh-l { left: -8vw; } .hh-r { right: -8vw; } .hcard { padding: 18px 14px; } #kingForm { grid-template-columns: 1fr; } .bk > img { height: 92px; } .next em { margin-left: 0; } }

/* ================= R4 cards: an element for each council member ================= */
@property --fxa { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
@keyframes fxspin { to { --fxa: 360deg; } }
.lead[class*="fx-"] { --c1: #e9b949; --c2: #ffd978; border-color: transparent; }
.lead[class*="fx-"]::before { content: ''; position: absolute; inset: 0; border-radius: 16px; padding: 2px; pointer-events: none; z-index: 2;
  background: conic-gradient(from var(--fxa), transparent 0 50%, var(--c1) 68%, var(--c2) 78%, transparent 92%), linear-gradient(#ffffff22, #ffffff22);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: fxspin 4.5s linear infinite; }
.lead[class*="fx-"]:hover { box-shadow: 0 0 34px -6px var(--c1); }
.fx-name { position: relative; isolation: isolate; overflow: hidden; margin: 2px -14px 12px; padding: 12px 14px 13px; }
.fx-name .kick { position: relative; z-index: 1; color: #fff; opacity: .85; text-shadow: 0 1px 4px #000; }
.fx-name h3 { position: relative; z-index: 1; margin: 2px 0 0; font: 900 21px/1.2 var(--body); color: #fff; text-shadow: 0 2px 5px #000d, 0 0 16px var(--c1), 0 0 30px var(--c1); }
.fx, .fx::before, .fx::after { content: ''; position: absolute; inset: 0; z-index: 0; }
/* fire */
.fx-fire { --c1: #ff7b2c; --c2: #ffd35a; } .fx-fire .fx { background: linear-gradient(0deg, #8a1f08, #2a0c06 80%); }
.fx-fire .fx::before { inset: 20% -10% -60%; filter: blur(7px); transform-origin: 50% 100%; animation: flame 1.1s ease-in-out infinite alternate;
  background: radial-gradient(30% 70% at 18% 100%, #ffd35a 0, #ff7b2c 40%, transparent 72%), radial-gradient(34% 90% at 46% 100%, #fff1a8 0, #ff9a3c 38%, transparent 72%), radial-gradient(30% 75% at 76% 100%, #ffd35a 0, #ff5a1c 42%, transparent 72%), radial-gradient(24% 60% at 96% 100%, #ffb347 0, #c0382c 45%, transparent 72%); }
.fx-fire .fx::after { background-image: radial-gradient(#ffe9a8 1.2px, transparent 2px), radial-gradient(#ff9a3c 1px, transparent 2px); background-size: 46px 60px, 70px 90px; background-position: 0 0, 20px 30px; animation: sparks 2.4s linear infinite; opacity: .9; }
@keyframes flame { 0% { transform: scaleY(.86) skewX(-5deg); } 50% { transform: scaleY(1.12) skewX(4deg); } 100% { transform: scaleY(.95) skewX(-2deg) scaleX(1.05); } }
@keyframes sparks { to { background-position: 14px -120px, 6px -150px; } }
/* water */
.fx-water { --c1: #3fa9f5; --c2: #9fe6ff; } .fx-water .fx { background: linear-gradient(#0b3a6b, #062247); }
.fx-water .fx::before { top: 34%; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 60' preserveAspectRatio='none'%3E%3Cpath d='M0 30 Q25 8 50 30 T100 30 T150 30 T200 30 V60 H0Z' fill='%233fa9f5aa'/%3E%3C/svg%3E") repeat-x 0 0 / 200px 100%; animation: tide 5s linear infinite; }
.fx-water .fx::after { top: 52%; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 60' preserveAspectRatio='none'%3E%3Cpath d='M0 30 Q25 8 50 30 T100 30 T150 30 T200 30 V60 H0Z' fill='%239fe6ff88'/%3E%3C/svg%3E") repeat-x 0 0 / 150px 100%; animation: tide 3.2s linear infinite reverse; }
@keyframes tide { to { background-position-x: 200px; } }
/* lightning */
.fx-lightning { --c1: #7fc4ff; --c2: #eaf6ff; } .fx-lightning .fx { background: radial-gradient(120% 140% at 50% 0, #1c3a7a, #070d22 70%); }
.fx-lightning .fx::before { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 70'%3E%3Cpath d='M70 0 L48 30 L64 32 L40 70 L58 38 L44 36 Z' fill='%23eaf6ff'/%3E%3Cpath d='M18 4 L8 26 L16 27 L4 52' fill='none' stroke='%239fd0ff' stroke-width='2'/%3E%3Cpath d='M108 10 L98 30 L106 32 L94 60' fill='none' stroke='%239fd0ff' stroke-width='2'/%3E%3C/svg%3E") repeat-x 10px 0 / 150px 100%; animation: strike 3.4s steps(1) infinite; opacity: 0; }
.fx-lightning .fx::after { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 70'%3E%3Cpath d='M70 0 L48 30 L64 32 L40 70 L58 38 L44 36 Z' fill='%23eaf6ff'/%3E%3Cpath d='M18 4 L8 26 L16 27 L4 52' fill='none' stroke='%239fd0ff' stroke-width='2'/%3E%3Cpath d='M108 10 L98 30 L106 32 L94 60' fill='none' stroke='%239fd0ff' stroke-width='2'/%3E%3C/svg%3E") repeat-x 90px 0 / 190px 100%; animation: strike 4.7s steps(1) -1.6s infinite; opacity: 0; transform: scaleX(-1); }
.fx-lightning .fx-name h3 { animation: surge 3.4s steps(1) infinite; }
@keyframes strike { 0% { opacity: 0; } 86% { opacity: 1; } 88% { opacity: .15; } 90% { opacity: 1; } 93% { opacity: .4; } 96% { opacity: 0; } }
@keyframes surge { 0% { text-shadow: 0 2px 5px #000d, 0 0 16px #7fc4ff; } 86% { text-shadow: 0 0 6px #fff, 0 0 26px #eaf6ff, 0 0 60px #7fc4ff; } 96% { text-shadow: 0 2px 5px #000d, 0 0 16px #7fc4ff; } }
/* lava */
.fx-lava { --c1: #ff5a1c; --c2: #ffc23a; } .fx-lava .fx { background: #1c0a06; }
.fx-lava .fx::before { background: linear-gradient(100deg, #ff7b2c, #ffd35a 20%, #c0382c 40%, #ff5a1c 60%, #ffc23a 80%, #ff7b2c) 0 0 / 300% 100%; animation: flow 6s linear infinite; }
.fx-lava .fx::after { background: repeating-linear-gradient(118deg, #1c0a06 0 16px, transparent 16px 19px), repeating-linear-gradient(28deg, #1c0a06 0 22px, transparent 22px 24px); opacity: .88; }
@keyframes flow { to { background-position-x: -300%; } }
/* poison */
.fx-poison { --c1: #7be33a; --c2: #d6ff8a; } .fx-poison .fx { background: linear-gradient(0deg, #2f6a12, #0c1f0a 85%); }
.fx-poison .fx::before { background-image: radial-gradient(circle, transparent 3px, #b6ff5a 3.5px 5px, transparent 5.5px), radial-gradient(circle, transparent 5px, #7be33a 5.5px 7px, transparent 7.5px), radial-gradient(circle, #d6ff8a 1.5px, transparent 2.5px); background-size: 64px 80px, 96px 110px, 40px 50px; animation: bubbles 4s linear infinite; }
.fx-poison .fx::after { background: radial-gradient(80% 90% at 50% 120%, #7be33a88, transparent 70%); animation: glow 2.2s ease-in-out infinite alternate; }
@keyframes bubbles { to { background-position: 10px -160px, -14px -220px, 6px -100px; } } @keyframes glow { to { opacity: .35; } }
/* ice */
.fx-ice { --c1: #9fe6ff; --c2: #ffffff; } .fx-ice .fx { background: linear-gradient(135deg, #1f5d8f, #0b2748 60%, #17406e); }
.fx-ice .fx::before { background: repeating-conic-gradient(from 20deg at 30% 120%, #ffffff14 0 9deg, transparent 9deg 18deg), repeating-conic-gradient(from 0deg at 85% -20%, #9fe6ff1f 0 7deg, transparent 7deg 16deg); }
.fx-ice .fx::after { inset: 0 -60%; background: linear-gradient(110deg, transparent 40%, #ffffffb0 50%, transparent 60%); animation: shine 3.2s ease-in-out infinite; }
@keyframes shine { 0% { transform: translateX(-60%); } 60%, 100% { transform: translateX(60%); } }
/* arcane */
.fx-arcane { --c1: #b57bff; --c2: #ffb3f5; } .fx-arcane .fx { background: #14072e; }
.fx-arcane .fx::before { inset: -120% -30%; background: conic-gradient(#7a3cff, #ff7bd5, #3ad6ff, #b57bff, #7a3cff); filter: blur(18px); opacity: .75; animation: whirl 7s linear infinite; }
.fx-arcane .fx::after { background-image: radial-gradient(#fff 1px, transparent 1.6px); background-size: 34px 34px; animation: twinkle 1.8s ease-in-out infinite alternate; }
@keyframes whirl { to { transform: rotate(360deg); } } @keyframes twinkle { to { opacity: .2; background-position: 6px 4px; } }
/* shadow */
.fx-shadow { --c1: #9a7bff; --c2: #d9d0ff; } .fx-shadow .fx { background: #07050f; }
.fx-shadow .fx::before { inset: -40% -20%; filter: blur(14px); background: radial-gradient(30% 50% at 25% 55%, #5a3ca8cc, transparent 70%), radial-gradient(34% 55% at 70% 45%, #2a1c5ecc, transparent 70%), radial-gradient(22% 40% at 50% 70%, #8a6be0aa, transparent 70%); animation: smoke 6s ease-in-out infinite alternate; }
.fx-shadow .fx::after { background: linear-gradient(90deg, #07050f 0, transparent 30% 70%, #07050f 100%); }
@keyframes smoke { 0% { transform: translate(-8%, 4%) scale(1); } 100% { transform: translate(8%, -6%) scale(1.25); } }
/* the King: a slow golden sweep */
.king::before { content: ''; position: absolute; inset: 0; border-radius: 18px; padding: 3px; pointer-events: none; background: conic-gradient(from var(--fxa), #e9b949, #fff6c8, #e9b949, #8a5a1c, #e9b949);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: fxspin 7s linear infinite; }
.king h2 { background: linear-gradient(100deg, #e9b949 20%, #fff8cf 40%, #e9b949 60%) 0 0 / 250% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: flow 5s linear infinite; }
@media (prefers-reduced-motion: reduce) { .fx, .fx::before, .fx::after, .lead[class*="fx-"]::before, .king::before, .king h2, .fx-name h3 { animation: none !important; } }
/* reward tables: icons must count toward column width (otherwise names run under the numbers); the rank column stays as narrow as its content */
.tbl img { max-width: none; }
.tbl th:first-child, .tbl td.rank { width: 1%; padding-right: 18px; }
.tbl td:nth-child(2), .tbl th:nth-child(2) { padding-right: 22px; }
@media (max-width: 860px) {
  .tbl th { font-size: 10px; letter-spacing: .04em; padding: 6px 6px; } .tbl th img { width: 20px; margin-right: 3px; }
  .tbl td { padding: 8px 6px; font-size: 14px; } .tbl th:first-child, .tbl td.rank { padding-right: 10px; white-space: normal; min-width: 44px; }
  .rank { font-size: 14px; } .award { gap: 5px; } .award img { width: 30px; height: 24px; } .extra { margin-left: 4px; padding: 2px 5px; font-size: 10px; }
}
/* canvas nameplates */
.fxc { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; display: block; }
.fx-name { padding: 20px 14px 18px; min-height: 86px; display: flex; flex-direction: column; justify-content: flex-end; background: #0a0f22; }
.fx-name::after { content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: linear-gradient(90deg, #000a 0, #0005 45%, transparent 80%), linear-gradient(0deg, #0008, transparent 60%); box-shadow: inset 0 1px 0 #ffffff2e, inset 0 -1px 0 #0009; }
.fx-name h3 { font: 900 23px/1.15 var(--body); letter-spacing: .01em; -webkit-text-stroke: .6px #000a; text-shadow: 0 2px 3px #000, 0 0 12px var(--c1), 0 0 28px var(--c1); }
.fx-name .kick { font-size: 11px; letter-spacing: .2em; }

/* speech-bubble busts: framed on the head that clean.js located in each render */
.av img { left: calc(50% + var(--fx, 0%)); top: var(--fy, 2%); }
/* the King's own hall */
.king { grid-template-columns: minmax(0, 320px) 1fr; padding: 34px 26px 26px; background: radial-gradient(90% 120% at 20% 0, #6b4a10, #2a1c0c 45%, #14203f 100%); box-shadow: 0 0 60px -10px #e9b94966, inset 0 0 0 1px #ffe39433; }
.throne { position: relative; padding-top: 74px; }
.crown { position: absolute; left: 50%; top: -18px; width: 150px; transform: translateX(-50%) rotate(-4deg); filter: drop-shadow(0 8px 10px #000a) drop-shadow(0 0 18px #ffd97866); animation: crownbob 3.4s ease-in-out infinite; z-index: 2; }
@keyframes crownbob { 50% { transform: translateX(-50%) rotate(-2deg) translateY(-5px); } }
.crown .glint { transform-origin: 120px 46px; animation: glint 2.6s ease-in-out infinite; } @keyframes glint { 0%, 60%, 100% { opacity: 0; transform: scale(.3); } 75% { opacity: 1; transform: scale(1.5) rotate(40deg); } }
.king h2 { font-size: clamp(40px, 6vw, 76px); }
@media (max-width: 860px) { .king { grid-template-columns: 1fr; } .crown { width: 120px; } .throne { padding-top: 60px; } }

.av img { height: 185%; }

/* a council member's own banner art sits on top of the card, edge to edge */
.lead .shot.banner { margin: -14px -14px 12px; border: 0; border-radius: 14px 14px 0 0; border-bottom: 2px solid var(--c1, var(--gold)); }
.lead .shot.banner img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: 50% 30%; }
.lead.has-banner .tags, .lead.has-banner .dim { max-width: 100%; }

/* ---------- event calendar ---------- */
.cal-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; margin-bottom: 26px; }
.cal-card { --c: var(--gold); display: grid; gap: 3px; padding: 14px 16px; border-radius: 14px; background: linear-gradient(#16284f, #101d3c); border: 1px solid var(--line); border-left: 5px solid var(--c); }
.cal-card b { font: 800 17px/1.2 var(--display); color: var(--parch); } .cal-card em, .cal-day i em { font-style: normal; font-weight: 800; font-size: .78em; letter-spacing: .06em; text-transform: uppercase; color: var(--c); }
.cal-card span { font-weight: 800; color: var(--gold-lit); } .cal-card small { color: var(--dim); }
.cal-cards.soon .cal-card { background: #ffffff08; }
.cal-bar { display: flex; align-items: center; gap: 10px; margin: 8px 0 12px; }
.cal-bar h2 { font: 900 clamp(22px, 3vw, 34px)/1 var(--display); color: var(--parch); min-width: 9ch; text-align: center; text-transform: capitalize; }
.cal-nav, .cal-today { height: 40px; min-width: 40px; padding: 0 12px; border-radius: 10px; font: 800 18px var(--body); color: var(--gold-lit); background: #ffffff10; box-shadow: inset 0 0 0 1.5px var(--line); }
.cal-today { font-size: 13px; margin-inline-start: auto; } .cal-nav:disabled { opacity: .3; cursor: default; }
.cal-keys { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.cal-keys button { --c: var(--gold); padding: 6px 11px 6px 9px; border-radius: 999px; font: 700 12.5px var(--body); color: #e8ecf7; background: #ffffff0d; border: 1px solid #ffffff22; }
.cal-keys button::before { content: ''; display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--c); margin-inline-end: 6px; }
.cal-keys button.off { opacity: .38; text-decoration: line-through; }
.cal-week, .cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal-week span { font: 800 11px var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--gold); padding: 0 6px 4px; }
.cal-day { min-height: 104px; padding: 7px; border-radius: 12px; background: #ffffff0a; border: 1px solid #ffffff14; display: flex; flex-direction: column; gap: 4px; }
.cal-day header { display: flex; align-items: baseline; gap: 6px; } .cal-day header b { font: 900 17px var(--display); color: var(--parch); } .cal-day header span { display: none; font: 700 12px var(--body); color: var(--dim); text-transform: capitalize; }
.cal-day.past { opacity: .5; } .cal-day.today { opacity: 1; border: 2px solid var(--gold-lit); background: #e9b9491c; box-shadow: 0 0 22px #e9b94940; }
.cal-day i { --c: var(--gold); font: 700 11.5px/1.25 var(--body); font-style: normal; color: #f2f5ff; padding: 3px 6px; border-radius: 6px; background: color-mix(in srgb, var(--c) 26%, transparent); border-inline-start: 3px solid var(--c); overflow-wrap: anywhere; }
.cal-day i:not(.start) { opacity: .72; }
.cal-src { margin-top: 18px; font-size: 13px; color: var(--dim); } .cal-src a { color: var(--gold-lit); }
.k-ark_battle { --c: #ff7b6b !important; } .k-ark_registration { --c: #f2a65a !important; } .k-mge { --c: #ffd978 !important; } .k-wof { --c: #c58cff !important; } .k-olympia { --c: #6fc3ff !important; }
.k-ceroli { --c: #7be39a !important; } .k-gk { --c: #e9b949 !important; } .k-goldhead { --c: #ffe08a !important; } .k-egg_hammer { --c: #ff9ecb !important; } .k-mtg { --c: #5fe0d6 !important; }
.k-rom { --c: #9aa8ff !important; } .k-arma { --c: #b9c2d6 !important; } .k-esm { --c: #e58bff !important; } .k-dhal { --c: #a3d977 !important; }
@media (max-width: 820px) {
  .cal-week, .cal-pad, .cal-day.empty { display: none; } .cal-grid { grid-template-columns: 1fr; }
  .cal-day { min-height: 0; flex-direction: row; flex-wrap: wrap; align-items: center; } .cal-day header { flex: 0 0 74px; } .cal-day header span { display: inline; } .cal-day i { font-size: 13px; padding: 5px 8px; }
  .cal-bar h2 { font-size: 22px; min-width: 0; flex: 1; }
}
.k-kingdom { --c: #ff5a4d !important; } .cal-day i.k-kingdom { font-weight: 800; }
.homecal h3 { font: 800 13px var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin: 14px 0 8px; } .homecal .cal-cards { margin-bottom: 8px; } .homecal .door { margin-top: 10px; }

/* ---------- guides ---------- */
.g-sub { font: 800 13px var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin: 22px 0 10px; }
.g-picks td { white-space: normal; vertical-align: top; } .g-picks .rank { white-space: nowrap; } .g-first { font: 800 17px var(--display); color: var(--gold-lit); white-space: nowrap; } .g-why { min-width: 240px; color: #d5dcf0; font-size: 14.5px; }
.g-chip { display: inline-block; padding: 3px 9px; margin: 2px 4px 2px 0; border-radius: 999px; background: #ffffff12; border: 1px solid #ffffff22; font-weight: 700; font-size: 13px; white-space: nowrap; }
.civ-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 12px; }
.civ { display: flex; gap: 12px; padding: 14px; border-radius: 14px; background: #ffffff0a; border: 1px solid #ffffff18; }
.civ > img, .civ-no { flex: 0 0 64px; width: 64px; height: 84px; object-fit: contain; object-position: 50% 100%; } .civ-no { display: grid; place-items: center; border-radius: 12px; background: #ffffff10; font: 900 30px var(--display); font-style: normal; color: var(--gold); }
.civ h4 { font: 800 19px var(--display); color: var(--parch); } .civ small { display: block; color: var(--dim); font-size: 12.5px; margin: 2px 0 8px; } .civ small b { color: #fff; }
.civ ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; } .civ li { display: flex; gap: 8px; font-size: 14px; } .civ li b { flex: 0 0 48px; color: var(--gold-lit); font-variant-numeric: tabular-nums; }
.g-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin: 6px 0; }
.g-steps article { padding: 14px 16px; border-radius: 14px; background: #ffffff0a; border: 1px solid #ffffff18; } .g-steps article > b { font: 900 26px var(--display); color: var(--gold); } .g-steps h4 { font: 800 17px var(--display); color: var(--parch); margin: 2px 0 6px; } .g-steps p { font-size: 14.5px; color: #d5dcf0; }
.g-forms { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; } .g-forms span { padding: 6px 12px; border-radius: 999px; background: #ffffff10; border: 1px solid var(--line); font-weight: 700; font-size: 13.5px; }
#g-arm .door { margin-top: 12px; }

/* guides, second pass: emblems, tier rows, formation diagrams */
.emb { --h: 46; flex: 0 0 auto; display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: radial-gradient(circle at 35% 28%, hsl(var(--h) 70% 52%), hsl(var(--h) 75% 22%)); box-shadow: 0 0 0 2px var(--gold), 0 0 0 3.5px #5c3a08, 0 4px 10px #0008; }
.emb img, .emb svg { width: 62%; height: 62%; object-fit: contain; filter: drop-shadow(0 1px 1px #0008); max-width: none; }
.emb.big { width: 58px; height: 58px; box-shadow: 0 0 0 2.5px var(--gold-lit), 0 0 0 4.5px #5c3a08, 0 0 22px hsl(var(--h) 80% 50% / .55); }
.tiers { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.tier { padding: 14px; border-radius: 14px; background: #ffffff0a; border: 1px solid #ffffff18; display: grid; gap: 8px; align-content: start; }
.tier h4 { font: 800 17px var(--display); color: var(--parch); } .tier p { font-size: 14px; color: #d5dcf0; }
.tier-row { display: flex; align-items: stretch; border-radius: 10px; overflow: hidden; background: #0b163099; }
.tier-row > b { flex: 0 0 38px; display: grid; place-items: center; font: 900 20px var(--display); color: #1a1206; }
.tier-row.s > b { background: linear-gradient(#ffe08a, #e9b949); } .tier-row.a > b { background: linear-gradient(#cfd6e6, #8f9bb8); }
.tier-row > div { display: flex; flex-wrap: wrap; gap: 8px 14px; padding: 9px 12px; } .tier-row.s { box-shadow: inset 0 0 0 1.5px #e9b94966; }
.pick { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; } .pick em { font-style: normal; } .tier-row.s .pick em { font: 800 18px var(--display); color: var(--gold-lit); }
.civ { --h: 46; position: relative; overflow: hidden; display: block; padding: 16px; background: linear-gradient(150deg, hsl(var(--h) 55% 22% / .55), #101d3c 62%); border: 1px solid hsl(var(--h) 60% 55% / .35); transition: transform .25s, box-shadow .25s; }
.civ:hover { transform: translateY(-4px); box-shadow: 0 14px 30px #0008, 0 0 26px hsl(var(--h) 80% 50% / .3); }
.civ header { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; position: relative; z-index: 1; } .civ small { margin: 1px 0 0; }
.civ-art { position: absolute; right: -6px; bottom: 0; height: 78%; width: auto; max-width: none; opacity: .92; filter: drop-shadow(0 8px 10px #000a); pointer-events: none; transition: transform .3s; } .civ:hover .civ-art { transform: scale(1.06); }
.civ ul { position: relative; z-index: 1; max-width: 68%; } .civ li span { text-shadow: 0 1px 3px #000c; }
.slots4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
.slots4 article { display: grid; justify-items: center; gap: 8px; padding: 16px 8px; border-radius: 14px; background: radial-gradient(circle at 50% 30%, #e9b94926, #ffffff08 70%); border: 1px solid var(--line); color: var(--gold-lit); }
.slots4 svg { width: 46px; height: 46px; filter: drop-shadow(0 0 10px #e9b94980); } .slots4 b { font: 800 15px var(--display); color: var(--parch); }
.forms { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.forms article { display: grid; justify-items: center; gap: 4px; padding: 12px 6px 10px; border-radius: 14px; background: #ffffff0a; border: 1px solid #ffffff18; transition: border-color .2s, transform .2s; }
.forms article:hover { border-color: var(--gold); transform: translateY(-3px); } .forms svg { width: 84px; height: 62px; fill: var(--gold-lit); filter: drop-shadow(0 0 5px #e9b94990); } .forms b { font: 700 13px var(--body); color: #e8ecf7; }
.forms circle { animation: rank 2.4s ease-in-out infinite; } .forms circle:nth-child(2n) { animation-delay: .3s; } .forms circle:nth-child(3n) { animation-delay: .6s; }
@keyframes rank { 50% { opacity: .45; } }
@media (max-width: 560px) { .slots4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .civ ul { max-width: 100%; } .civ-art { opacity: .28; } }
@media (prefers-reduced-motion: reduce) { .forms circle { animation: none; } }
.civ { min-height: 190px; } .civ-art { height: 92%; right: 2px; }

/* ---------- calculators ---------- */
#tools { min-height: 100vh; background: radial-gradient(90% 60% at 50% 0, #1b2f5c, #0b1630 70%); }
.calc-stage { max-width: 1040px; margin: 0 auto; padding: 22px 14px 80px; }
.calc-tabs { display: flex; gap: 8px; overflow-x: auto; padding: 6px 2px 14px; scrollbar-width: none; justify-content: safe center; }
.calc-tabs button { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; padding: 8px 14px 8px 8px; border-radius: 12px; font: 700 13.5px var(--body); color: var(--dim); background: #ffffff0a; border: 1px solid #ffffff1c; transition: .2s; }
.calc-tabs img { width: 30px; height: 30px; object-fit: contain; } .calc-tabs button.on { color: #fff; background: #e9b94922; border-color: var(--gold); box-shadow: 0 0 18px #e9b94933; }
.calc-head { text-align: center; margin: 10px 0 20px; } .calc-head h1 { display: inline-flex; align-items: center; gap: 12px; font: 900 clamp(26px, 4.4vw, 44px)/1.1 var(--display); color: var(--parch); text-shadow: 0 3px 0 #0008; }
.calc-head h1 img { width: 1.25em; height: 1.25em; object-fit: contain; filter: drop-shadow(0 4px 6px #0008); } .calc-head p { color: #d5dcf0; margin-top: 8px; }
.calc-row { display: grid; grid-template-columns: 56px minmax(0, 560px) 56px; justify-content: center; align-items: center; gap: 10px; }
.calc-arrow { height: 56px; border-radius: 50%; font: 400 44px/1 var(--body); color: #fff; opacity: .75; transition: .2s; } .calc-arrow:hover { opacity: 1; color: var(--gold-lit); transform: scale(1.12); }
.calc { display: none; padding: 26px; border-radius: 16px; background: linear-gradient(#1b2b52f2, #121e3df2); border: 1px solid #ffffff2e; box-shadow: 0 20px 50px #0009; }
.calc.on { display: block; animation: calcIn .35s ease-out; } @keyframes calcIn { from { opacity: 0; transform: translateY(14px) scale(.98); } }
.cf { display: block; margin-bottom: 16px; } .cf > span { display: flex; align-items: center; gap: 8px; font: 600 14px var(--body); color: #d5dcf0; margin-bottom: 8px; } .cf > span img { width: 24px; height: 24px; object-fit: contain; }
.calc input:not([type]), .calc input[type=date], .calc select, .calc input[inputmode] { width: 100%; height: 46px; padding: 0 14px; border-radius: 8px; border: 1px solid #ffffff38; background: #0b163099; color: #fff; font: 600 15px var(--body); color-scheme: dark; }
.calc input::placeholder { color: #ffffff55; font-weight: 500; } .calc input:focus, .calc select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px #e9b94933; }
.calc .two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.hint { font-size: 12.5px; font-style: italic; color: var(--dim); margin: -6px 0 14px; text-align: center; } .tip { font-size: 13.5px; color: #d5dcf0; padding: 12px 14px; border-radius: 10px; background: #e9b9491a; border: 1px solid #e9b94955; margin-bottom: 16px; }
.rar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; } .rar.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.rar label, .rates label, .vips label { position: relative; display: grid; justify-items: center; gap: 4px; padding: 10px 4px 8px; border-radius: 8px; background: #0b163099; border: 1px solid #ffffff2a; cursor: pointer; transition: .15s; }
.rar input, .rates input, .vips input, .tg input, .tier input { position: absolute; opacity: 0; pointer-events: none; }
.rar img { width: 38px; height: 38px; object-fit: contain; } .rar em, .rates em, .vips em { font: 700 12px var(--body); font-style: normal; color: #e8ecf7; text-align: center; }
.rar label:has(:checked), .rates label:has(:checked), .vips label:has(:checked) { background: linear-gradient(#e08a2e, #b9641a); border-color: #ffd08a; box-shadow: 0 0 16px #e08a2e66; }
.rar .r-epic:has(:checked) { background: linear-gradient(#9a5fd6, #6c3aa6); border-color: #d6b5ff; box-shadow: 0 0 16px #9a5fd666; } .rar .r-elite:has(:checked) { background: linear-gradient(#3f8fe0, #2463ab); border-color: #a9d3ff; box-shadow: 0 0 16px #3f8fe066; } .rar .r-advanced:has(:checked) { background: linear-gradient(#45b36b, #2a8048); border-color: #b0f0c6; box-shadow: 0 0 16px #45b36b66; }
.rates { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; } .rates b { font: 800 17px var(--body); color: #fff; }
.vips { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 5px; } .vips label { padding: 6px 2px 4px; } .vips img { width: 30px; height: 30px; object-fit: contain; } .vips em { font-size: 11px; }
.tg { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; cursor: pointer; font: 600 14.5px var(--body); color: #e8ecf7; } .tg i { flex: 0 0 46px; height: 26px; border-radius: 999px; background: #ffffff26; position: relative; transition: .2s; }
.tg i::after { content: ''; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: #cfd6e6; transition: .2s; } .tg input:checked + i { background: var(--gold); } .tg input:checked + i::after { left: 23px; background: #fff; }
.more { display: none; margin-bottom: 16px; } .more.on { display: block; animation: calcIn .25s; }
.cgrid { display: grid; gap: 8px; } .cgrid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); } .cgrid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cgrid label { display: grid; justify-items: center; gap: 4px; padding: 10px 6px 8px; border-radius: 8px; background: #1e4a3a55; border: 1px solid #5fd69a33; } .cgrid img { width: 46px; height: 46px; object-fit: contain; }
.cgrid em { font: 700 11.5px var(--body); font-style: normal; letter-spacing: .04em; text-transform: uppercase; color: #e8ecf7; } .cgrid small { font-size: 11px; color: var(--dim); } .cgrid input { height: 36px !important; text-align: center; padding: 0 6px !important; }
.with { display: flex; gap: 8px; } .tier { flex: 0 0 auto; display: flex; position: relative; border-radius: 8px; overflow: hidden; border: 1px solid #ffffff38; cursor: pointer; } .tier i { display: grid; place-items: center; width: 44px; font: 800 13px var(--body); font-style: normal; color: var(--dim); }
.tier input:not(:checked) + i, .tier input:checked + i + i { background: var(--gold); color: #1a1206; }
.calc-go { width: 100%; height: 50px; margin-top: 4px; border-radius: 8px; font: 800 15px var(--body); letter-spacing: .04em; color: #fff; background: linear-gradient(#3b4f86, #2a3964); border: 1px solid #8fa3d8; transition: .15s; } .calc-go:hover { filter: brightness(1.2); box-shadow: 0 0 20px #5d7bd066; }
.calc-out:empty { display: none; } .calc-out { margin-top: 16px; display: grid; gap: 8px; } .calc-out.pop { animation: calcIn .3s; }
.res { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 10px; background: #0b1630cc; border: 1px solid var(--line); } .res img { width: 40px; height: 40px; object-fit: contain; } .res span { flex: 1; color: #e8ecf7; } .res strong { font: 900 22px var(--body); color: var(--gold-lit); font-variant-numeric: tabular-nums; white-space: nowrap; }
.res.sm { padding: 8px 14px; font-size: 13.5px; background: #ffffff08; border-color: #ffffff18; } .res.sm strong { font-size: 14px; } .res.ok { border-color: #7be39a88; } .res.ok b { color: #7be39a; font-size: 20px; } .res.err { border-color: #ff7b6b88; background: #c0382c26; }
.srow { display: grid; grid-template-columns: 1fr auto; gap: 0 12px; padding: 10px 14px; border-radius: 10px; background: #ffffff08; border-left: 4px solid var(--gold); } .srow small { grid-column: 1; color: var(--dim); font-size: 12px; } .srow span { grid-row: 1 / 3; grid-column: 2; align-self: center; color: #e8ecf7; } .srow strong { font-size: 18px; color: var(--gold-lit); }
.srow.best { border-color: #7be39a; } .srow.worst { border-color: #ff7b6b; }
.break { display: grid; gap: 4px; padding: 12px 14px; border-radius: 10px; background: #ffffff08; font-size: 14px; } .break div { display: flex; justify-content: space-between; gap: 12px; } .break span { color: #d5dcf0; } .break b { font-variant-numeric: tabular-nums; } .break div:last-child { border-top: 1px solid #ffffff22; padding-top: 6px; margin-top: 2px; color: var(--gold-lit); }
@media (max-width: 720px) { .calc-row { grid-template-columns: minmax(0, 1fr); } .calc-arrow { display: none; } .calc { padding: 18px 14px; } .calc-tabs { justify-content: flex-start; } .calc-tabs span { display: none; } .calc-tabs button { padding: 8px; } .calc-tabs button.on span { display: inline; }
  .cgrid.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } .rates { grid-template-columns: repeat(3, minmax(0, 1fr)); } .vips { grid-template-columns: repeat(5, minmax(0, 1fr)); } .rar { grid-template-columns: repeat(2, minmax(0, 1fr)); } .rar.three { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 721px) { .calc-tabs { flex-wrap: wrap; justify-content: center; overflow: visible; } }

/* calculators, second batch: training, honour, crystal technology */
@media (min-width: 721px) { .calc-stage:has(.calc.wide.on) .calc-row { grid-template-columns: 56px minmax(0, 1fr) 56px; } .calc-stage:has(.calc.wide.on) { max-width: 1320px; } }
.dhm label { background: #ffffff0a; border-color: #ffffff22; } .resrow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; } .resrow span { display: flex; align-items: center; gap: 6px; padding: 8px; border-radius: 10px; background: #0b1630cc; border: 1px solid #ffffff1c; } .resrow img { width: 28px; height: 28px; object-fit: contain; } .resrow b { font: 800 14px var(--body); }
.calc input[type=range] { width: 100%; height: 8px; padding: 0; border: 0; border-radius: 999px; background: linear-gradient(90deg, var(--gold), #5aa0ff); accent-color: #fff; } .ro { margin-inline-start: auto; color: var(--gold-lit); font-variant-numeric: tabular-nums; }
.rates.three { grid-template-columns: repeat(3, minmax(0, 1fr)); } .rates.three b { font-size: 14px; } .rates.three em { font-weight: 500; font-size: 11px; opacity: .85; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-inline-end: 8px; } .break small { color: var(--dim); margin-inline-start: 6px; }
.ct-set { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; align-items: end; margin-bottom: 14px; } .ct-set label > span { display: flex; align-items: center; gap: 8px; font: 600 13.5px var(--body); color: #d5dcf0; margin-bottom: 6px; } .ct-set img { width: 26px; height: 26px; object-fit: contain; } .ct-set em { font-style: normal; } .ct-set .tg { margin: 0 0 10px; }
.ct-modes { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; } .ct-modes button { min-width: 64px; height: 38px; padding: 0 14px; border-radius: 8px; font: 800 14px var(--body); color: #e8ecf7; background: #0b163099; border: 1px solid #ffffff2a; } .ct-modes button.on { background: linear-gradient(var(--gold-lit), var(--gold)); color: #1a1206; border-color: var(--gold-lit); } .ct-modes .tg { margin: 0 0 0 6px; }
.ct-msg { display: none; padding: 10px 14px; margin-bottom: 10px; border-radius: 10px; background: #c0382c26; border: 1px solid #ff7b6b88; font-size: 14px; } .ct-msg.on { display: block; animation: calcIn .25s; }
.ct-scroll { overflow-x: auto; border-radius: 12px; background: radial-gradient(60% 80% at 50% 50%, #1d3566, #0b1630); border: 1px solid #ffffff22; cursor: grab; touch-action: pan-x pan-y; } .ct-scroll:active { cursor: grabbing; }
.ct-map { position: relative; } .ct-map svg { position: absolute; inset: 0; pointer-events: none; } .ct-map path { fill: none; stroke: #ffffff26; stroke-width: 3; } .ct-map path.on { stroke: var(--gold); filter: drop-shadow(0 0 4px #e9b949); }
.ct-node { --c: #9aa8ff; position: absolute; width: 176px; height: 96px; padding: 8px 8px 12px 62px; border-radius: 12px; text-align: start; background: linear-gradient(#17274c, #0f1b38); border: 1.5px solid #ffffff26; overflow: hidden; transition: transform .15s, box-shadow .2s, border-color .2s; display: grid; align-content: center; gap: 2px; }
.ct-node:hover { transform: translateY(-3px); border-color: var(--c); box-shadow: 0 8px 20px #0009; } .ct-node img { position: absolute; left: 6px; top: 50%; translate: 0 -56%; width: 52px; height: 52px; object-fit: contain; filter: drop-shadow(0 3px 5px #000a); }
.ct-node b { font: 800 12.5px/1.15 var(--body); color: #fff; } .ct-node span { font: 900 15px var(--body); color: var(--c); font-variant-numeric: tabular-nums; } .ct-node small { font-size: 10.5px; line-height: 1.15; color: var(--dim); }
.ct-node i { position: absolute; left: 0; bottom: 0; height: 5px; background: var(--c); box-shadow: 0 0 10px var(--c); transition: width .25s; } .ct-node.has { border-color: var(--c); box-shadow: inset 0 0 22px color-mix(in srgb, var(--c) 22%, transparent); } .ct-node.full { background: linear-gradient(color-mix(in srgb, var(--c) 30%, #17274c), #0f1b38); }
.ct-node.locked { opacity: .55; } .ct-node.locked img { filter: grayscale(.9); }
.c-infantry { --c: #ff7b6b; } .c-archer { --c: #7be39a; } .c-cavalry { --c: #ffd978; } .c-siege { --c: #c58cff; } .c-utility { --c: #6fc3ff; }
.ct-tot { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 6px; } .ct-tot div { display: grid; grid-template-columns: 44px 1fr; align-items: center; gap: 0 10px; padding: 12px 14px; border-radius: 12px; background: #0b1630cc; border: 1px solid var(--line); }
.ct-tot img { grid-row: 1 / 3; width: 44px; height: 44px; object-fit: contain; } .ct-tot span { font: 600 13px var(--body); color: #d5dcf0; } .ct-tot b { font: 900 22px var(--body); color: var(--gold-lit); font-variant-numeric: tabular-nums; } .ct-tot small { grid-column: 2; font-size: 11.5px; color: var(--dim); }
@media (max-width: 720px) { .ct-tot { grid-template-columns: 1fr; } .resrow { grid-template-columns: repeat(2, 1fr); } .rates.three { grid-template-columns: 1fr; } }
.cf > span em { font-style: normal; } .ct-node small { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; } .ct-node b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* civilization guide: banner icons, pick cards with in-game screens, tier rows */
.flagic { width: 44px; height: 44px; object-fit: contain; flex: 0 0 auto; filter: drop-shadow(0 3px 5px #0008); max-width: none; } .flagic.big { width: 72px; height: 72px; }
.picks { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; margin: 6px 0 4px; }
.pick-card { padding: 14px 16px; border-radius: 14px; background: #ffffff0a; border: 1px solid #ffffff18; } .pick-card.wide { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 6px 18px; align-items: center; }
.pick-card h3 { display: flex; align-items: center; gap: 10px; font: 800 22px var(--display); color: var(--parch); margin-bottom: 6px; } .pick-card h3 i { font-style: normal; color: var(--gold); } .pick-card p { color: #d5dcf0; font-size: 15px; }
.pick-card.wide h3, .pick-card.wide p { grid-column: 1; } .pick-card.wide .shot { grid-column: 2; grid-row: 1 / 3; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 10px 26px #0008; transition: transform .25s; } .pick-card.wide .shot:hover { transform: scale(1.02); } .pick-card .shot img { width: 100%; display: block; }
.tl { display: grid; gap: 6px; } .tl-row { display: flex; align-items: stretch; border-radius: 10px; overflow: hidden; background: #0b163099; border: 1px solid #ffffff14; }
.tl-row > b { flex: 0 0 112px; display: grid; place-items: center; padding: 6px 8px; text-align: center; font: 900 22px/1.1 var(--display); color: #1a1206; } .tl-row > div { display: flex; flex-wrap: wrap; gap: 6px 14px; padding: 8px 12px; }
.t-s > b { background: linear-gradient(#ff8f8f, #e05555); } .t-a > b { background: linear-gradient(#ffc48a, #e8963f); } .t-b > b { background: linear-gradient(#ffe58a, #e0bb3a); } .t-x > b { background: linear-gradient(#c9d1e4, #8f9bb8); font: 800 12.5px/1.2 var(--body); } .t-all > b { display: none; }
.tl-civ { display: inline-grid; justify-items: center; gap: 2px; width: 74px; transition: transform .2s; } .tl-civ:hover { transform: translateY(-4px) scale(1.08); } .tl-civ .flagic { width: 56px; height: 56px; } .tl-civ em { font: 700 12px var(--body); font-style: normal; color: #e8ecf7; text-align: center; }
@media (max-width: 720px) { .pick-card.wide { grid-template-columns: 1fr; } .pick-card.wide .shot { grid-column: 1; grid-row: auto; } .tl-row > b { flex-basis: 64px; font-size: 18px; } .t-x > b { font-size: 10.5px; } .tl-civ { width: 62px; } .tl-civ .flagic { width: 46px; height: 46px; } }
.rates.four { grid-template-columns: repeat(5, minmax(0, 1fr)); } .calc-tabs img, .calc-head h1 img { border-radius: 4px; }

/* crystal technology on phones: full-width card, compact controls, smaller tree, totals always in view */
@media (max-width: 720px) {
  .calc.wide { padding: 14px 10px; }
  .ct-set { grid-template-columns: 1fr 1fr; gap: 8px; } .ct-set label > span { font-size: 12px; min-height: 30px; } .ct-set img { width: 20px; height: 20px; } .ct-set .tg { grid-column: 1 / -1; margin: 2px 0 6px; font-size: 13px; }
  .ct-set label:nth-child(1) { grid-column: 1 / -1; }
  .ct-modes { gap: 6px; } .ct-modes button { flex: 1 1 0; min-width: 0; padding: 0 6px; height: 40px; } .ct-modes .tg { flex: 1 1 100%; margin: 4px 0 0; font-size: 13px; }
  .ct-scroll { margin-inline: -10px; border-radius: 0; border-inline: 0; -webkit-overflow-scrolling: touch; } .ct-map { zoom: .74; }
  .ct-tot { position: sticky; bottom: 8px; z-index: 4; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 10px; }
  .ct-tot div { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 8px 4px; gap: 1px; background: #0b1630f5; box-shadow: 0 6px 18px #000a; } .ct-tot img { grid-row: auto; width: 26px; height: 26px; } .ct-tot span { font-size: 11px; } .ct-tot b { font-size: 15px; } .ct-tot small { grid-column: 1; font-size: 9.5px; line-height: 1.15; }
  .ct-msg { font-size: 13px; position: sticky; top: 118px; z-index: 4; background: #5a1f1af2; }
}

/* ---------- meta commanders ---------- */
#meta { min-height: 100vh; background: radial-gradient(90% 50% at 50% 0, #1b2f5c, #0b1630 70%); } .mt-stage { max-width: 1240px; margin: 0 auto; padding: 22px 14px 80px; }
.mt-tiers { display: grid; gap: 14px; } .mt-tier { --c: #e7000b; display: flex; border-radius: 12px; overflow: hidden; background: #111827e6; border: 2px solid var(--c); }
.mt-tier > b { flex: 0 0 84px; display: grid; place-content: center; justify-items: center; background: #000; border-inline-end: 6px solid var(--c); font: 900 34px/1 var(--body); color: var(--c); } .mt-tier > b small { font: 600 12px var(--body); margin-top: 4px; }
.mt-tier > div { display: flex; flex-wrap: wrap; gap: 14px 18px; padding: 16px; flex: 1; } .t-Z { --c: #e7000b; } .t-S { --c: #7c3aed; } .t-A { --c: #2563eb; } .t-B { --c: #16a34a; } .t-C { --c: #9ca3af; }
.mt-pair { position: relative; display: grid; justify-items: center; gap: 4px; width: 104px; transition: transform .18s; } .mt-pair:hover { transform: translateY(-4px) scale(1.05); } .mt-pair em { font: 700 11.5px/1.2 var(--body); font-style: normal; color: #e8ecf7; text-align: center; grid-column: 1 / -1; }
.hx { display: inline-block; width: 64px; aspect-ratio: 1; filter: drop-shadow(0 4px 6px #000a); } .hx img { width: 100%; height: 100%; object-fit: contain; max-width: none; } .mt-pair .hx.main { grid-area: 1 / 1; justify-self: start; width: 72px; } .mt-pair .hx.sub { grid-area: 1 / 1; justify-self: end; align-self: end; width: 46px; }
.mt-back { margin-bottom: 12px; font: 700 14px var(--body); color: var(--dim); } .mt-back:hover { color: var(--gold-lit); }
.mt-title { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font: 800 clamp(20px, 3.4vw, 32px)/1.15 var(--body); color: #fff; margin-bottom: 16px; } .mt-title b { display: grid; place-items: center; width: 1.5em; height: 1.5em; border-radius: 6px; background: var(--c); font-weight: 900; } .mt-title small { font-weight: 600; color: var(--dim); font-size: .8em; }
.mt-grid { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 14px; align-items: start; } .mt-cmds, .mt-side { display: grid; gap: 14px; } .mt-two { display: grid; grid-template-columns: 1.4fr 1fr; gap: 14px; }
.mt-cmd { border-radius: 14px; overflow: hidden; background: #111827e6; border: 1px solid #ffffff1c; } .mt-face { position: relative; display: grid; place-items: center; height: 210px; background-size: cover; background-position: center; } .hx.big { width: 150px; }
.mt-type { position: absolute; bottom: 8px; display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 4px; border-radius: 999px; background: #000b; font: 700 13px var(--body); color: #fff; } .mt-type img { width: 22px; height: 22px; }
.mt-cmd h3 { padding: 8px 10px; text-align: center; background: #e7000b; font: 800 17px var(--body); color: #fff; } .mt-cmd h3 small { display: block; font-weight: 500; font-size: 12.5px; opacity: .92; }
.mt-box { padding: 14px; border-radius: 14px; background: #111827e6; border: 1px solid #ffffff1c; } .mt-cmd .mt-box { border: 0; border-radius: 0; background: none; }
.mt-box h4 { font: 800 12.5px var(--body); letter-spacing: .1em; text-transform: uppercase; color: #fff; padding-inline-start: 10px; border-inline-start: 4px solid #e7000b; margin-bottom: 12px; }
.mt-skills { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; } .mt-skills button { position: relative; display: grid; justify-items: center; gap: 3px; padding: 2px; border-radius: 8px; } .mt-skills button.on { background: #ffffff18; box-shadow: 0 0 0 1.5px var(--gold); }
.mt-skills img { width: 100%; max-width: 46px; aspect-ratio: 1; border-radius: 6px; } .mt-skills i { position: absolute; left: 0; top: -2px; z-index: 1; display: grid; place-items: center; width: 17px; height: 17px; border-radius: 50%; background: #e7000b; font: 800 10.5px var(--body); font-style: normal; color: #fff; }
.mt-skills em { font: 500 10.5px/1.15 var(--body); font-style: normal; color: #cbd5e1; text-align: center; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 24px; } .mt-skills b { width: 100%; padding: 2px 0; border-radius: 5px; background: #ffffff14; font: 800 13px var(--body); text-align: center; }
.mt-skinfo, .mt-einfo, .mt-ninfo { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: #0b1630cc; border: 1px solid var(--line); font-size: 13.5px; line-height: 1.45; color: #d5dcf0; } .mt-skinfo b, .mt-einfo b, .mt-ninfo b { display: block; color: var(--gold-lit); margin-bottom: 3px; } .mt-ninfo i { font-style: normal; color: #fff; margin-inline-start: 6px; } .mt-ninfo u { text-decoration: none; font-weight: 800; color: #7be39a; }
.mt-box dl { margin: 12px 0 0; display: grid; gap: 4px; font-size: 13px; } .mt-box dl div { display: flex; justify-content: space-between; gap: 10px; } .mt-box dt { color: var(--dim); } .mt-box dd { margin: 0; font-weight: 800; }
.mt-acc { display: flex; justify-content: center; gap: 18px; } .mt-acc > * { display: grid; justify-items: center; gap: 6px; width: 92px; } .mt-acc img { width: 62px; height: 62px; object-fit: contain; filter: drop-shadow(0 4px 6px #000a); } .mt-acc em { font: 600 12px/1.2 var(--body); font-style: normal; color: #cbd5e1; text-align: center; }
.mt-tree { border-radius: 12px; overflow: hidden; background-size: cover; background-position: center; border: 1px solid #ffffff1c; } .tt { position: relative; width: 100%; aspect-ratio: 1; container-type: size; }
.tt svg { position: absolute; inset: 0; width: 100%; height: 100%; } .tc { position: absolute; left: 50%; top: 50%; width: 8%; translate: -50% -50%; }
.tb { position: absolute; left: 50%; top: 50%; height: 9%; transform-origin: bottom center; } .tb img { height: 100%; width: auto; max-width: none; display: block; } .tb span { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; } .tb b { font: 800 2cqh/1 var(--body); color: #fff; } .tb em { font: 600 1.4cqh/1 var(--body); font-style: normal; color: #2a1206; }
.tn { position: absolute; width: 2.4%; translate: -50% -50%; z-index: 1; } .tn.big { width: 3.6%; } .tn img { width: 100%; display: block; max-width: none; } .tn.off img { filter: grayscale(1); opacity: .5; } .tn span { position: absolute; left: 50%; top: 100%; translate: -50% 0; font: 700 1.3cqh/1.2 var(--body); color: #fff; text-shadow: 0 0 3px #000, 0 0 3px #000; white-space: nowrap; }
.tn::after { content: ''; position: absolute; inset: -60%; } .tn.sel img { filter: drop-shadow(0 0 4px #fff) drop-shadow(0 0 8px var(--gold)); opacity: 1; } .tn:hover { z-index: 2; scale: 1.25; }
@media (max-width: 860px) {
  .mt-grid { grid-template-columns: 1fr; } .mt-cmds { grid-template-columns: 1fr 1fr; gap: 8px; } .mt-face { height: 130px; } .hx.big { width: 96px; } .mt-cmd h3 { font-size: 14px; } .mt-cmd h3 small { font-size: 11px; } .mt-cmd .mt-box { padding: 10px 8px; }
  .mt-skills { gap: 3px; } .mt-skills em { display: none; } .mt-skills i { width: 14px; height: 14px; font-size: 9px; } .mt-box dl { font-size: 11.5px; } .mt-box dl div { flex-direction: column; gap: 0; }
  .mt-two { grid-template-columns: 1.3fr 1fr; gap: 8px; } .mt-acc { gap: 8px; } .mt-acc > * { width: 76px; } .mt-acc img { width: 50px; height: 50px; }
  .mt-side > .mt-box:last-child { padding: 10px 0 12px; border-inline: 0; border-radius: 0; margin-inline: -14px; } .mt-side > .mt-box:last-child h4 { margin-inline-start: 12px; } .mt-tree { border-radius: 0; border-inline: 0; } .mt-ninfo { margin-inline: 10px; position: sticky; bottom: 8px; z-index: 3; background: #0b1630f5; box-shadow: 0 6px 18px #000a; }
  .tn { width: 3.4%; } .tn.big { width: 5%; } .tn span { font-size: 1.9cqh; } .tb b { font-size: 2.6cqh; } .tb em { font-size: 1.7cqh; } .tb { height: 11%; } .tc { width: 10%; }
  .mt-tier > b { flex-basis: 54px; font-size: 26px; border-inline-end-width: 4px; } .mt-tier > div { padding: 12px 8px; gap: 12px 6px; justify-content: space-around; } .mt-pair { width: 92px; } .mt-pair .hx.main { width: 62px; } .mt-pair .hx.sub { width: 40px; }
}

/* meta commanders, phone pass: one commander per row, zoomable talent tree */
.mt-zoom { display: none; } .mt-tree.zoom { overflow: auto; max-height: 82vh; -webkit-overflow-scrolling: touch; } .mt-tree.zoom .tt { width: 210%; }
@media (max-width: 860px) {
  .mt-cmds { grid-template-columns: 1fr; } .mt-cmd { display: grid; grid-template-columns: 118px minmax(0, 1fr); grid-template-rows: auto 1fr; } .mt-face { grid-row: 1 / 3; height: auto; min-height: 150px; } .hx.big { width: 92px; } .mt-type { font-size: 11.5px; bottom: 6px; } .mt-type img { width: 18px; height: 18px; }
  .mt-cmd h3 { text-align: start; padding: 7px 10px; } .mt-cmd .mt-box { padding: 8px 10px 10px; } .mt-cmd .mt-box h4 { display: none; } .mt-skills { gap: 5px; } .mt-skills img { max-width: 44px; } .mt-box dl { margin-top: 8px; } .mt-box dl div { flex-direction: row; }
  .mt-skinfo { grid-column: 1 / -1; font-size: 13px; }
  .mt-zoom { display: inline-flex; margin: 0 12px 8px; padding: 8px 14px; border-radius: 999px; font: 800 13px var(--body); color: #1a1206; background: linear-gradient(var(--gold-lit), var(--gold)); }
  .tn span { font-size: 2.1cqh; } .mt-tree.zoom .tn span { font-size: 1.5cqh; }
}

/* meta commanders: mode tabs, extra tiers, matchups, single-commander view */
.mt-tabs { display: flex; gap: 6px; padding: 5px; margin: 0 auto 18px; width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; border-radius: 12px; background: #111827e6; border: 1px solid #ffffff22; }
.mt-tabs button { flex: 0 0 auto; padding: 10px 16px; border-radius: 8px; font: 700 14px var(--body); color: #cbd5e1; white-space: nowrap; } .mt-tabs button.on { background: #b91c1c; color: #fff; }
.t-D { --c: #ca8a04; } .t-E { --c: #c2410c; } .t-F { --c: #78716c; } .mt-sub { font: 800 20px var(--display); color: var(--parch); margin: 22px 0 10px; }
.mt-pair.solo { width: 92px; } .mt-pair.solo .hx.main { justify-self: center; width: 70px; } .mt-solo { max-width: 420px; margin: 0 auto; }
.mt-vs > div { display: flex; flex-wrap: wrap; gap: 10px 14px; } .mt-vs.good h4 { border-color: #22c55e; } .mt-vs.bad h4 { border-color: #ef4444; } .mt-pair.mini { width: 84px; cursor: default; } .mt-pair.mini .hx.main { width: 56px; } .mt-pair.mini .hx.sub { width: 36px; } .mt-pair.mini:hover { transform: none; }
@media (max-width: 860px) { .mt-tabs { margin-inline: -6px; } .mt-tabs button { padding: 9px 12px; font-size: 13px; } .mt-pair.mini { width: 76px; } }

/* AOO sign-up */
.sign { margin-bottom: 34px; padding: 22px; border-radius: 18px; border: 1.5px solid var(--gold); background: radial-gradient(70% 90% at 0 0, #2b4a8f, #13244a 60%, #0b1630); }
#signForm { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; } #signForm .wide, .sign-slots { grid-column: 1 / -1; }
#signForm label span { display: block; font: 800 12px var(--body); letter-spacing: .06em; color: var(--gold-lit); margin-bottom: 5px; }
#signForm input:not([type=checkbox]):not([type=radio]) { width: 100%; padding: 12px 14px; border-radius: 10px; border: 1.5px solid #ffffff30; background: #0b1630; color: #fff; font: inherit; }
#signForm input:focus { outline: none; border-color: var(--gold-lit); }
.sign-slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.sign-slot { position: relative; display: grid; align-content: start; gap: 3px; padding: 16px 16px 14px 52px; border-radius: 14px; border: 1.5px solid #ffffff2a; background: #0b1630b3; cursor: pointer; transition: .15s; }
.sign-slot:hover { border-color: var(--gold); } .sign-slot input { position: absolute; left: 16px; top: 18px; width: 22px; height: 22px; accent-color: var(--gold); }
.sign-slot:has(input:checked) { border-color: var(--gold-lit); background: linear-gradient(#3a3416, #1c2a52); box-shadow: 0 0 0 1px var(--gold-lit); }
.sign-slot b { font: 900 20px var(--display); color: var(--parch); } .sign-slot span { font-weight: 800; color: var(--gold-lit); } .sign-slot span i { font-style: normal; }
.sign-slot small { color: var(--dim); font-size: 12px; } .sign-slot em { font-style: normal; font-size: 13px; color: #d5dcf0; } .sign-slot em b { font: 800 15px var(--body); color: #fff; }
.sign-who { margin-top: 16px; } .sign-who summary { cursor: pointer; font-weight: 800; color: var(--gold-lit); }
.sign-who > div { display: grid; gap: 10px; margin-top: 10px; } .sign-who h4 { font: 800 13px var(--body); color: var(--gold); } .sign-who h4 i { font-style: normal; } .sign-who p { font-size: 14px; color: #d5dcf0; }
@media (max-width: 760px) { .sign-slots, #signForm { grid-template-columns: 1fr; } .sign { padding: 16px; } }
.sign-slot.full { cursor: not-allowed; opacity: .55; } .sign-slot.full:hover { border-color: #ffffff2a; }
.sign-slot strong { position: absolute; top: 14px; right: 14px; padding: 3px 9px; border-radius: 6px; background: var(--crimson); color: #fff; font: 800 11px var(--body); letter-spacing: .08em; text-transform: uppercase; }
.sub-note { margin-top: 6px; padding: 7px 9px; border-radius: 8px; background: #a8571f33; border: 1px solid #e0a93a66; color: #ffd9a0; font-size: 12px; font-weight: 700; line-height: 1.35; }
.sub-note.me { background: #2f6f4a40; border-color: #7be39a66; color: #c9f5d6; } .sub-note b { font: inherit; color: #fff; }
.sub-note.lock { background: #ffffff10; border-color: #ffffff30; color: var(--dim); }
#signCancel[hidden] { display: none; }
#mgeForm { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; } #mgeForm .wide { grid-column: 1 / -1; }
#mgeForm label span { display: block; font: 800 12px var(--body); letter-spacing: .06em; color: var(--gold-lit); margin-bottom: 5px; }
#mgeForm input { width: 100%; padding: 12px 14px; border-radius: 10px; border: 1.5px solid #ffffff30; background: #0b1630; color: #fff; font: inherit; } #mgeForm input:focus { outline: none; border-color: var(--gold-lit); }
#mgeCancel[hidden] { display: none; } #mgeSign { margin-top: 34px; } .sign-who small { color: var(--dim); }
@media (max-width: 760px) { #mgeForm { grid-template-columns: 1fr; } }
/* MGE screenshots */
.shot-up { position: relative; cursor: pointer; } .shot-up input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.shot-up .ph { display: flex; align-items: center; gap: 12px; min-height: 92px; padding: 14px; border-radius: 12px; border: 2px dashed #ffffff40; background: #0b1630 center / cover no-repeat; font-style: normal; transition: .15s; }
.shot-up:hover .ph { border-color: var(--gold-lit); }
.shot-up .ph b { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(#ffe394, #e0a93a); color: #1a1206; font: 900 22px var(--body); }
.shot-up .ph em { font-style: normal; font-size: 13px; color: var(--dim); }
.shot-up.has .ph { min-height: 170px; border-style: solid; border-color: var(--gold-lit); } .shot-up.has .ph b, .shot-up.has .ph em { display: none; }
.shot-up .ph em.ok { display: none; color: #7be39a; font-weight: 700; } .shot-up.saved:not(.has) .ph { border-color: #7be39a; }
.shot-up.saved:not(.has) .ph em { display: none; } .shot-up.saved:not(.has) .ph em.ok { display: block; }
#mgeForm .hint { display: block; margin-top: 5px; font-size: 12px; color: var(--dim); }
#signForm .hint { display: block; margin-top: 5px; font-size: 12px; color: var(--dim); }
/* sign-up PIN */
#signForm .pin input, #mgeForm .pin input { letter-spacing: .5em; font-weight: 800; max-width: 180px; }
.pin-note { grid-column: 1 / -1; margin: -4px 0 2px; padding: 10px 12px; border-radius: 10px; background: #e9b9491a; border: 1px solid #e9b94955; color: #f4e7c8; font-size: 13px; line-height: 1.45; }
.pin-note b { color: var(--gold-lit); }
.id-check { display: block; margin-top: 5px; font-size: 12px; font-weight: 700; } .id-check.ok { color: #7be39a; } .id-check.err { color: var(--crimson-lit); }
#signForm input[readonly], #mgeForm input[readonly] { background: #13244a; color: var(--gold-lit); cursor: default; }
/* sign-up deadline */
.deadline { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 14px; margin: -4px 0 16px; padding: 12px 16px; border-radius: 12px; background: #0b1630cc; border: 1.5px solid var(--gold); }
.deadline span { font: 800 12px var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.deadline b { font: 900 clamp(22px, 3vw, 32px)/1 var(--display); color: var(--gold-lit); font-variant-numeric: tabular-nums; } .deadline small { color: var(--dim); font-size: 13px; }
.deadline.soon { border-color: var(--crimson-lit); } .deadline.soon b { color: var(--crimson-lit); }
.deadline.shut { border-color: var(--crimson); background: #5a120d55; } .deadline.shut b { font-size: 20px; color: #fff; }
.ev-map { margin: 6px 0 40px; } .ev-map .dkp-chips { margin-bottom: 12px; } .ev-map .dkp-chips i { font-style: normal; } .ev-map-box { max-width: 860px; margin: 0 auto; }
@media (max-width: 760px) { .ev-map-box { overflow-x: auto; border-radius: 14px; } .ev-map-box .am { width: 680px; } }   /* names stay readable on phones: swipe sideways */
.ev-phases { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 0 auto 10px; max-width: 860px; }
.ev-phases button { padding: 7px 12px; border-radius: 999px; font: 700 13px var(--body); color: var(--dim); border: 1px solid #ffffff26; }
.ev-phases button b { margin-right: 6px; color: var(--gold-lit); } .ev-phases button.on { color: var(--ink); background: var(--gold-lit); border-color: var(--gold-lit); } .ev-phases button.on b { color: var(--ink); }
.ev-phases button:disabled { opacity: .35; }
.deadline[hidden] { display: none; }
#rallyLive .meter { width: 120px; } #rallyLive .meter.full i { background: linear-gradient(90deg, #2f8f55, #7be39a); } #rallyLive tr.low td.gov b { color: var(--crimson-lit); }

/* ---------- reward & penalty lists ---------- */
.po-q { width: 100%; max-width: 420px; height: 46px; padding: 0 14px; margin: 4px 0 16px; border-radius: 10px; border: 1.5px solid #ffffff2e; background: #0b1630; color: #fff; font: 600 15px var(--body); }
.po-h { font: 800 13px var(--body); letter-spacing: .12em; text-transform: uppercase; margin: 14px 0 6px; } .po-h.reward { color: #7be39a; } .po-h.penalty { color: #ff7b6b; }
.po-t { width: 100%; border-collapse: collapse; } .po-t td.num { text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; } .po-t th:nth-child(n+3) { text-align: right; }
.po-t.reward tbody td.num { color: #b9f5c9; } .po-t.penalty tbody td.num { color: #ffb4aa; } .po-t tbody tr { border-inline-start: 3px solid transparent; } .po-t.reward tbody td:first-child { box-shadow: inset 3px 0 #2f8f55; } .po-t.penalty tbody td:first-child { box-shadow: inset 3px 0 #c0382c; }
.po-t .gov b { display: block; } .po-t .gov small { color: var(--dim); font-size: 12px; } .po-note { color: #d5dcf0; font-size: 13.5px; white-space: normal !important; min-width: 120px; }
.po-t tfoot td { border-top: 2px solid var(--line); font-weight: 800; color: var(--gold-lit); }
@media (max-width: 720px) { .po-t th img { width: 20px; } .po-t td, .po-t th { padding: 8px 6px; } .po-note { min-width: 90px; font-size: 12.5px; } }
.po-t .po-note { display: block; font-style: normal; color: #d5dcf0; font-size: 13px; white-space: normal; min-width: 0; } .po-t th:nth-child(n+2) { text-align: right; } .po-t .gov { white-space: normal; min-width: 120px; }
@media (max-width: 720px) { .po-t th { font-size: 0; } .po-t th img { width: 24px; margin: 0; } .po-t th:first-child { font-size: 11px; } .po-t td.num { font-size: 13.5px; } .po-t .gov { min-width: 0; } .po-t .gov b { font-size: 14px; } }

/* phones, entrance: no animated torch glow, no blurred fog layers (each repaints the whole screen every frame) */
@media (max-width: 860px), (pointer: coarse) { .torch { animation: none; box-shadow: 0 0 2vh 1vh #ff9a3c; } .fog, .redmist { filter: none !important; } }

/* AOO history — trophy stage + game-style match bars */
.hm-res { font: 800 11px 'Manrope', sans-serif; font-style: normal; letter-spacing: .08em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; }
.hm-res.win { background: #2f8f5533; color: #7be39a; border: 1px solid #7be39a66; } .hm-res.loss { background: #c0382c33; color: #ff8b7d; border: 1px solid #ff8b7d66; } .hm-res.draw { background: #ffffff14; color: #cfd6ea; }
.hm-empty { color: var(--dim, #a9b4cf); }
.hx-stage { position: relative; overflow: hidden; border-radius: 22px; margin-bottom: 18px; min-height: 360px; display: grid; grid-template-columns: 1.15fr .85fr; align-items: center;
  background: radial-gradient(60% 90% at 72% 40%, #8a5a12aa, transparent 70%), radial-gradient(120% 100% at 50% 110%, #3a2508, #120b04 70%); border: 1px solid #e9b94955; box-shadow: 0 20px 60px #0009, inset 0 0 80px #000a; }
.hx-rays { position: absolute; inset: -40%; left: 30%; background: repeating-conic-gradient(from 0deg at 50% 50%, #ffd97822 0deg 6deg, transparent 6deg 18deg); mask: radial-gradient(circle at 50% 50%, #000 0 22%, transparent 55%); -webkit-mask: radial-gradient(circle at 50% 50%, #000 0 22%, transparent 55%); animation: hxSpin 40s linear infinite; pointer-events: none; }
@keyframes hxSpin { to { transform: rotate(360deg); } }
.hx-stage::after { content: ''; position: absolute; right: 22%; top: 42%; width: 40px; height: 40px; margin: -20px; border-radius: 50%; pointer-events: none; z-index: 1; opacity: 0;
  background: radial-gradient(circle, #fff9e0 0 20%, #ffd24a88 45%, transparent 70%); }
.hx-stage.go::after { animation: hxFlash 1s ease-out .15s; } @keyframes hxFlash { 0% { opacity: 1; transform: scale(.5); } 100% { opacity: 0; transform: scale(18); } }
.hx-burst { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; }
.hx-copy { position: relative; z-index: 2; padding: 30px 34px; }
.hx-copy h2 { font: 900 clamp(30px, 4vw, 46px)/1 'Cinzel', serif; background: linear-gradient(#fff3c4, #e9b949 55%, #a8741c); -webkit-background-clip: text; background-clip: text; color: transparent; margin: 6px 0 14px; filter: drop-shadow(0 2px 0 #3a2508); }
.hx-streak { display: flex; align-items: baseline; gap: 12px; margin-bottom: 18px; }
.hx-streak b { font: 900 clamp(64px, 9vw, 110px)/.9 'Cinzel', serif; background: linear-gradient(#fffbe6, #ffd24a 45%, #c47f12); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 22px #ffb34766) drop-shadow(0 3px 0 #4a2c05); }
.hx-streak span { font: 800 clamp(14px, 1.6vw, 18px) 'Manrope', sans-serif; letter-spacing: .14em; text-transform: uppercase; color: #ffe394; max-width: 220px; line-height: 1.3; }
.hx-stats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.hx-stats div { background: #00000055; border: 1px solid #e9b94944; border-radius: 12px; padding: 8px 14px; min-width: 84px; }
.hx-stats b { display: block; font: 900 22px 'Cinzel', serif; color: #ffd978; } .hx-stats span { font: 800 10px 'Manrope', sans-serif; letter-spacing: .1em; text-transform: uppercase; color: #cdb98a; }
.hx-form { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; } .hx-form span { margin-left: 8px; font: 800 10px 'Manrope', sans-serif; letter-spacing: .1em; text-transform: uppercase; color: #cdb98a; }
.hx-form i { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; font: 900 12px 'Manrope', sans-serif; font-style: normal; }
.hx-form i.win { background: linear-gradient(#5fe08f, #2c9a55); color: #06210f; } .hx-form i.loss { background: linear-gradient(#ff8b7d, #c0382c); color: #2a0703; } .hx-form i.draw { background: #ffffff33; color: #fff; }
.hx-trophy { position: relative; z-index: 2; width: min(100%, 360px); justify-self: center; filter: drop-shadow(0 0 40px #ffb34788) drop-shadow(0 18px 30px #000c); cursor: pointer; transform-origin: 50% 80%; animation: hxFloat 4s ease-in-out infinite; }
@keyframes hxFloat { 50% { transform: translateY(-8px); } }
.hx-stage.go .hx-trophy { animation: hxPop 1.1s cubic-bezier(.2, 1.6, .4, 1) both, hxFloat 4s ease-in-out 1.1s infinite; }
@keyframes hxPop { 0% { transform: scale(.2) rotate(-12deg); opacity: 0; filter: brightness(3) drop-shadow(0 0 80px #fff); } 60% { opacity: 1; } 100% { transform: none; } }
.hx-stage.go .hx-copy > * { animation: hxRise .7s ease both; } .hx-stage.go .hx-copy > :nth-child(2) { animation-delay: .1s; } .hx-stage.go .hx-copy > :nth-child(3) { animation-delay: .25s; } .hx-stage.go .hx-copy > :nth-child(4) { animation-delay: .4s; } .hx-stage.go .hx-copy > :nth-child(5) { animation-delay: .55s; }
@keyframes hxRise { from { opacity: 0; transform: translateY(14px); } }
.hx-list { display: grid; gap: 8px; }
.hx-day { margin-top: 10px; padding: 10px 18px; border-radius: 10px; background: linear-gradient(90deg, #9a6a35, #6a4524); color: #f4dcb0; font: 900 18px 'Manrope', sans-serif; letter-spacing: .03em; box-shadow: inset 0 1px 0 #ffffff33, 0 2px 0 #00000055; }
.hx-m { border-radius: 12px; overflow: hidden; box-shadow: 0 3px 0 #0006, 0 10px 24px #0005; }
.hx-m summary { list-style: none; cursor: pointer; position: relative; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; padding: 10px 14px; min-height: 92px;
  background: linear-gradient(100deg, #5fb1c6 0%, #a9d7df 30%, #d9dde6 50%, #f0b1b0 70%, #e2686c 100%); }
.hx-m summary::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, #ffffff40, transparent 40%, #00000018); pointer-events: none; }
.hx-m summary::-webkit-details-marker { display: none; } .hx-m.flat summary { cursor: default; } .hx-m:not(.flat) summary:hover { filter: brightness(1.06); }
.hx-side { display: flex; align-items: center; gap: 12px; min-width: 0; position: relative; z-index: 1; } .hx-side.them { flex-direction: row-reverse; text-align: right; }
.hx-shield { position: relative; flex: none; width: 62px; display: grid; justify-items: center; } .hx-shield img { width: 58px; height: 64px; object-fit: contain; filter: drop-shadow(0 3px 4px #0006); }
.hx-side.us .hx-shield img { width: 60px; height: 60px; border-radius: 50%; }
.hx-shield em { margin-top: -6px; font: 800 10.5px 'Manrope', sans-serif; font-style: normal; padding: 1px 7px; border-radius: 999px; color: #fff; white-space: nowrap; }
.hx-side.us em { background: #1f5f9e; } .hx-side.them em { background: #a8331f; }
.hx-name { min-width: 0; display: grid; } .hx-name b, .hx-name > span { font: 700 17px/1.2 'Manrope', sans-serif; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hx-side.us .hx-name { color: #1d3f8a; } .hx-side.them .hx-name { color: #9c1c18; } .hx-name small { font: 700 11px 'Manrope', sans-serif; opacity: .7; }
.hx-mid { position: relative; z-index: 2; display: flex; align-items: center; gap: 12px; }
.hx-mid > b { font: 900 clamp(20px, 2.6vw, 30px) 'Manrope', sans-serif; font-variant-numeric: tabular-nums; } .hx-mid b.us { color: #163d8f; } .hx-mid b.them { color: #c42a24; }
.hx-sc { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; } .hx-sc img { width: 58px; height: 58px; filter: drop-shadow(0 0 8px #ffd24a); }
.hx-vic { width: 120px; height: auto; margin: -10px -6px; filter: drop-shadow(0 0 6px #ffd24a); }

.hx-m[open] summary { box-shadow: inset 0 -2px 0 #0003; } .hx-m .tbl { margin: 0; border-radius: 0; } .hx-note { margin: 0; padding: 10px 16px; background: #0b1630; color: var(--dim, #a9b4cf); }
@media (max-width: 860px) { .hx-stage { grid-template-columns: 1fr; } .hx-trophy { grid-row: 1; width: 220px; margin-top: 18px; } .hx-copy { padding: 6px 20px 24px; text-align: center; } .hx-streak, .hx-stats, .hx-form { justify-content: center; } }
.hx-arena { position: relative; display: grid; grid-template-columns: minmax(230px, 330px) 1fr; align-items: start; border-radius: 22px; overflow: clip; padding: 18px 18px 18px 0;
  background: linear-gradient(#081430, #050b1c 60%, #03060f); border: 1px solid #1b3a7255; }
.hx-scene { grid-column: 1 / -1; grid-row: 1; position: sticky; top: 0; height: 100vh; margin: -18px -18px 0 0; align-self: start; overflow: hidden; pointer-events: none; z-index: 0; }
.hx-scene .moon { top: 26%; left: 62%; } .hx-scene .fl { height: 70%; } .hx-scene .f1 { height: 48%; } .hx-scene .f2 { height: 60%; } .hx-scene .f3 { height: 34%; opacity: .95; }
.hx-glow { position: absolute; left: -10%; bottom: 0; width: 55%; height: 70%; background: radial-gradient(60% 70% at 40% 100%, #ff6a1a55, #c2310a22 45%, transparent 70%); filter: blur(10px); animation: hxFlicker 2.2s ease-in-out infinite alternate; }
.hx-flies { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 3; }
.hx-leo, .hx-main { grid-row: 1; } .hx-main { grid-column: 2; position: relative; z-index: 2; } .hx-leo { grid-column: 1; }
.hx-leo { position: sticky; top: 70px; height: min(84vh, 700px); margin-right: -26px; z-index: 1; pointer-events: none; }
.hx-leo video { position: absolute; right: 0; bottom: 0; height: 100%; width: auto; max-width: none; background: transparent;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 40%), linear-gradient(to bottom, transparent 0, #000 12%, #000 88%, transparent 100%); -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent 0, #000 40%), linear-gradient(to bottom, transparent 0, #000 12%, #000 88%, transparent 100%); mask-composite: intersect; }
.hx-fire { position: absolute; inset: -6% -14% -4% -40%; background: radial-gradient(55% 70% at 62% 100%, #ff8a1ff0, #d8400cb0 38%, #7a1a0660 62%, transparent 78%), radial-gradient(28% 50% at 48% 100%, #ffe08acc, transparent 72%), radial-gradient(22% 40% at 78% 92%, #ffb347aa, transparent 70%);
  filter: blur(16px); animation: hxFlicker 1.6s ease-in-out infinite alternate; }
@keyframes hxFlicker { 0% { opacity: .75; transform: scaleY(.96); } 50% { opacity: 1; } 100% { opacity: .85; transform: scaleY(1.05) translateX(4px); } }
.hx-flames { position: absolute; left: -10%; right: -6%; bottom: 0; height: 75%; filter: blur(10px); }
.hx-flames i { position: absolute; bottom: -6%; width: 34%; height: 70%; border-radius: 50% 50% 45% 45% / 70% 70% 30% 30%; transform-origin: 50% 100%;
  background: radial-gradient(60% 80% at 50% 85%, #fff2b0, #ffb02e 30%, #ff5a0a 60%, #b0200400 80%); opacity: .8; animation: hxLick 1.3s ease-in-out infinite alternate; }
.hx-flames i:nth-child(1) { left: 0; height: 55%; animation-duration: 1.1s; } .hx-flames i:nth-child(2) { left: 18%; height: 85%; animation-duration: 1.5s; animation-delay: -.4s; }
.hx-flames i:nth-child(3) { left: 38%; height: 100%; animation-duration: 1.2s; animation-delay: -.8s; } .hx-flames i:nth-child(4) { left: 58%; height: 80%; animation-duration: 1.4s; animation-delay: -.2s; }
.hx-flames i:nth-child(5) { left: 74%; height: 60%; animation-duration: 1s; animation-delay: -.6s; }
@keyframes hxLick { 0% { transform: scale(1, .85) skewX(-4deg); opacity: .65; } 100% { transform: scale(.9, 1.12) skewX(5deg); opacity: .95; } }
/* phones and tablets: Leonidas stands on the right, the match list slides past in the space in front of him */
@media (max-width: 1000px) {
  .hx-arena { grid-template-columns: 1fr; padding: 12px; } .hx-scene { margin: -12px; }
  .hx-main { grid-column: 1; grid-row: 1; width: 61%; }
  .hx-leo { grid-column: 1; grid-row: 1; justify-self: end; position: sticky; top: 58px; width: 64%; height: min(80vh, 640px); margin: 0 -12px 0 0; }
  .hx-leo video { right: -18%; left: auto; transform: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 30%), linear-gradient(to bottom, transparent 0, #000 6%, #000 90%, transparent 100%); -webkit-mask-composite: source-in;
    mask-image: linear-gradient(to right, transparent 0, #000 30%), linear-gradient(to bottom, transparent 0, #000 6%, #000 90%, transparent 100%); mask-composite: intersect; }
  .hx-fire { inset: 20% -20% 0 10%; }
  .hx-day { font-size: 13px; padding: 6px 10px; margin-top: 6px; }
  .hx-m summary { grid-template-columns: 1fr 1fr; grid-template-areas: 'mid mid' 'us them'; padding: 8px 8px 9px; gap: 6px; min-height: 0; }
  .hx-mid { grid-area: mid; flex-wrap: wrap; justify-content: center; gap: 2px 8px; } .hx-side.us { grid-area: us; } .hx-side.them { grid-area: them; }
  .hx-vic { order: -1; width: 100%; height: 26px; object-fit: contain; margin: 0; } .hx-m.win .hx-vic { object-position: 8% 50%; } .hx-m.loss .hx-vic { object-position: 92% 50%; }   /* over the winner's side */
  .hx-mid > b { font-size: 18px; } .hx-sc { width: 26px; height: 26px; } .hx-sc img { width: 32px; height: 32px; }
  .hx-side { gap: 5px; } .hx-shield { width: 34px; } .hx-shield img { width: 32px; height: 36px; } .hx-side.us .hx-shield img { width: 32px; height: 32px; }
  .hx-shield em { font-size: 8.5px; padding: 0 4px; margin-top: -4px; }
  .hx-name > span, .hx-name small { display: none; } .hx-name b { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) { .hx-fire, .hx-flames i, .hx-glow { animation: none; } }
@media (prefers-reduced-motion: reduce) { .hx-rays, .hx-trophy, .hx-m.win .hx-vic { animation: none !important; } }
.po-bar { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 16px; } .po-bar .po-q { margin: 0; flex: 1 1 220px; } #poW { max-width: 300px; cursor: pointer; }

/* AOO page header on phones: our Leonidas larger, leaning on the right edge of the screen */
@media (max-width: 860px) { #events .page-head { padding-right: 0; } #events .ph-art { height: 50vh; justify-content: flex-end; margin-right: -18px; } #events .ph-art img { height: 100%; } }

/* MGE hall of fame — throne hall in purple and gold */
.mx-stage { position: relative; overflow: hidden; border-radius: 22px; margin-bottom: 18px; padding: 28px 30px;
  background: radial-gradient(70% 90% at 80% 0%, #7a4bc255, transparent 60%), radial-gradient(60% 80% at 10% 100%, #e9b94933, transparent 60%), linear-gradient(#1d1033, #0e0820); border: 1px solid #e9b94955; box-shadow: 0 20px 60px #0009; }
.mx-stage h2 { font: 900 clamp(30px, 4vw, 46px)/1 'Cinzel', serif; background: linear-gradient(#fff3c4, #e9b949 55%, #a8741c); -webkit-background-clip: text; background-clip: text; color: transparent; margin: 6px 0 8px; }
.mx-stage > p { color: #cdbde6; max-width: 640px; }
.mx-champs { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin: 18px 0 14px; }
.mx-c { position: relative; display: grid; grid-template-columns: 44px 1fr; grid-template-rows: auto auto; gap: 0 10px; align-items: center; padding: 10px 12px; border-radius: 14px; background: #00000055; border: 1px solid #e9b94944; }
.mx-c.first { background: linear-gradient(135deg, #e9b94933, #00000055); border-color: #ffd978aa; box-shadow: 0 0 24px #ffd97833; }
.mx-c img { grid-row: 1 / 3; width: 44px; height: auto; } .mx-c b { position: absolute; right: 12px; top: 8px; font: 900 20px 'Cinzel', serif; color: #ffd978; }
.mx-c span { color: #f4e7c8; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 34px; } .mx-c span b { position: static; font: inherit; color: #e9b949; }
.mx-c small { color: #a99bc4; font-size: 11.5px; }
.mx-rec { display: inline-flex; gap: 10px; align-items: baseline; flex-wrap: wrap; padding: 8px 14px; border-radius: 12px; background: #00000055; border: 1px solid #e9b94944; }
.mx-rec span { font: 800 10px 'Manrope', sans-serif; letter-spacing: .12em; text-transform: uppercase; color: #cdb98a; } .mx-rec b { font: 900 20px 'Cinzel', serif; color: #ffd978; } .mx-rec small { color: #cdbde6; } .mx-rec small b { font: inherit; color: #e9b949; }
.mx-arena { background: linear-gradient(#1a0f2e, #0c0718); border-color: #7a4bc255; }
.mx-scene { background: radial-gradient(50% 40% at 25% 45%, #ff8a3a22, transparent 70%), radial-gradient(60% 50% at 70% 20%, #5b2a8a44, transparent 70%); }
.mx-list { display: grid; gap: 14px; }
.mx-s { border-radius: 14px; overflow: hidden; background: #f3e7cb; box-shadow: 0 4px 0 #0006, 0 14px 30px #0006; color: #2b1d0e; }
.mx-rib { position: relative; display: flex; align-items: center; justify-content: center; padding: 10px 16px; background: linear-gradient(#ffd27a, #e6a53a 55%, #c27f1c); box-shadow: inset 0 2px 0 #fff3, inset 0 -3px 0 #0002; }
.mx-rib b { font: 900 20px 'Manrope', sans-serif; letter-spacing: .04em; text-transform: uppercase; color: #fff; text-shadow: 0 2px 0 #9a5a10; }
.mx-rib small { position: absolute; right: 16px; font: 700 12px 'Manrope', sans-serif; color: #7a4a10; }
.mx-s ol { list-style: none; margin: 0; padding: 4px 14px; } .mx-s li { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 10px; padding: 7px 0; border-top: 1px solid #0000001a; }
.mx-s li:first-child { border-top: 0; } .mx-s li img { width: 38px; height: auto; justify-self: center; } .mx-s li em { font: 900 18px 'Manrope', sans-serif; font-style: normal; color: #e89a1a; text-align: center; }
.mx-s li span { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .mx-s li span b { font-weight: 900; }
.mx-s li i { font: 900 15px 'Manrope', sans-serif; font-style: normal; font-variant-numeric: tabular-nums; }
.mx-s li.r1 span, .mx-s li.r1 i { font-size: 16.5px; } .mx-s li.r1 { background: linear-gradient(90deg, #ffd97844, transparent); margin: 0 -14px; padding: 8px 14px; }
.mx-more summary { cursor: pointer; list-style: none; padding: 6px 14px 10px; color: #8a5a14; font: 800 12px 'Manrope', sans-serif; letter-spacing: .06em; text-transform: uppercase; } .mx-more summary::-webkit-details-marker { display: none; }
.mx-more summary::after { content: ' ▾'; } .mx-more[open] summary::after { content: ' ▴'; }
@media (max-width: 1000px) { .mx-leo video { right: -60%; }   /* he sits in the middle of his throne: slide him right so his face clears the cards */
  .mx-s li { grid-template-columns: 28px 1fr; } .mx-s li i { grid-column: 2; font-size: 13px; color: #7a5a2a; } .mx-s li img { width: 28px; } .mx-rib b { font-size: 15px; } .mx-rib small { position: static; margin-left: 8px; font-size: 10px; } .mx-rib { justify-content: flex-start; padding: 8px 10px; } .mx-s li span { font-size: 13px; } .mx-stage { padding: 20px 16px; } }
.mx-older { margin-top: 14px; } .mx-older > summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-radius: 14px;
  background: linear-gradient(#ffd27a, #e6a53a 55%, #c27f1c); color: #fff; font: 900 16px 'Manrope', sans-serif; letter-spacing: .04em; text-transform: uppercase; text-shadow: 0 2px 0 #9a5a10; box-shadow: 0 4px 0 #0006; }
.mx-older > summary::-webkit-details-marker { display: none; } .mx-older > summary b { font: 900 14px 'Manrope', sans-serif; background: #00000033; padding: 2px 10px; border-radius: 999px; }
.mx-older > summary::after { content: '▾'; } .mx-older[open] > summary::after { content: '▴'; } .mx-older > .mx-list { margin-top: 14px; }

/* static on purpose: the rotating rays and the blurred, animated glow/fog layers cost a repaint every frame on desktop */
.hx-rays, .hx-fire, .hx-glow, .hx-scene .fog { animation: none !important; }
