:root {
  --bg: #0a1018;
  --bg2: #0f1822;
  --panel: #131f2b;
  --panel2: #182736;
  --line: #24384a;
  --line2: #2f4a60;
  --text: #ece6d6;
  --muted: #94a3ad;
  --dim: #64757f;
  --gold: #f2c14e;
  --gold2: #c4912a;
  --grass: #6cc644;
  --grass2: #3f8f2a;
  --emerald: #2fd27a;
  --stone: #8a8f94;
  --red: #e2604c;
  --water: #1d6fa5;
  --civ: #2fd27a;
  --px: 4px;
  --r: 2px;
  --display: 'Pixelify Sans', 'VT323', system-ui, sans-serif;
  --mono: 'VT323', ui-monospace, monospace;
  --body: 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.6 var(--body); overflow-x: hidden; min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; outline: none; }
img { max-width: 100%; }
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; line-height: 1.1; margin: 0 0 .5em; letter-spacing: .01em; }
h1 { font-size: clamp(2.2rem, 6vw, 4.4rem); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.dim { color: var(--dim); }
.mono { font-family: var(--mono); font-size: 1.15em; letter-spacing: .02em; }
.skip { position: absolute; left: -999px; top: 0; background: var(--gold); color: #000; padding: 8px 12px; z-index: 99; }
.skip:focus { left: 8px; }
::selection { background: var(--gold); color: #1a1205; }
.pximg, canvas.px, img.px { image-rendering: pixelated; image-rendering: crisp-edges; }

/* ---------- pixel chrome ---------- */
.notch { clip-path: polygon(0 var(--px), var(--px) var(--px), var(--px) 0, calc(100% - var(--px)) 0, calc(100% - var(--px)) var(--px), 100% var(--px), 100% calc(100% - var(--px)), calc(100% - var(--px)) calc(100% - var(--px)), calc(100% - var(--px)) 100%, var(--px) 100%, var(--px) calc(100% - var(--px)), 0 calc(100% - var(--px))); }
.panel { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 2px solid var(--line); border-radius: var(--r); padding: 24px; position: relative; box-shadow: inset 0 2px 0 rgba(255,255,255,.04), 0 10px 30px -18px #000; }
.panel.tight { padding: 16px; }
.panel h3 { margin-bottom: .4em; }
.eyebrow { font-family: var(--mono); font-size: 1.2rem; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); display: inline-flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.eyebrow::before { content: ''; width: 10px; height: 10px; background: currentColor; box-shadow: 4px 4px 0 rgba(0,0,0,.4); }

.btn { --b: var(--panel2); --t: var(--text); --hl: rgba(255,255,255,.18); --sh: rgba(0,0,0,.45);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: 700 1rem/1 var(--display); letter-spacing: .03em;
  padding: 14px 22px; color: var(--t); background: var(--b); border: 2px solid #000; border-radius: 0; cursor: pointer; text-decoration: none !important;
  box-shadow: inset 0 3px 0 var(--hl), inset 0 -4px 0 var(--sh), 0 4px 0 #000; transition: transform .08s, filter .15s; position: relative; user-select: none; white-space: nowrap; }
.btn:hover { filter: brightness(1.12); }
.btn:active { transform: translateY(3px); box-shadow: inset 0 3px 0 var(--hl), inset 0 -2px 0 var(--sh), 0 1px 0 #000; }
.btn:disabled { opacity: .55; cursor: not-allowed; filter: grayscale(.4); }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.btn-gold { --b: var(--gold); --t: #2a1b03; --hl: #ffe39a; --sh: #a8761b; }
.btn-green { --b: #3fae4a; --t: #071a09; --hl: #8fe28c; --sh: #24702b; }
.btn-red { --b: #b53b2c; --t: #fff; --hl: #e57766; --sh: #6e1f15; }
.btn-ghost { --b: transparent; --hl: transparent; --sh: transparent; border-color: var(--line2); box-shadow: none; }
.btn-ghost:active { box-shadow: none; }
.btn-sm { padding: 9px 14px; font-size: .9rem; }
.btn-xs { padding: 6px 10px; font-size: .8rem; box-shadow: inset 0 2px 0 var(--hl), inset 0 -3px 0 var(--sh), 0 2px 0 #000; }
.btn-lg { padding: 18px 30px; font-size: 1.15rem; }
.btn-discord { --b: #4f63d9; --t: #fff; --hl: #8796ef; --sh: #2e3b8f; }
.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

/* ---------- nav ---------- */
.nav { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px clamp(16px, 4vw, 40px);
  background: rgba(10,16,24,.72); backdrop-filter: blur(12px) saturate(1.3); -webkit-backdrop-filter: blur(12px) saturate(1.3); border-bottom: 2px solid rgba(36,56,74,.6); }
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); text-decoration: none !important; }
.brand-mark { width: 38px; height: 38px; border-radius: 4px; flex: none; background: url(/img/logo-512.png) center/contain no-repeat; image-rendering: pixelated; filter: drop-shadow(0 3px 0 rgba(0,0,0,.5)); }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text b { font: 700 1.15rem var(--display); }
.brand-text small { font: 1rem var(--mono); color: var(--muted); letter-spacing: .1em; }
.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-links > a:not(.btn) { color: var(--text); font: 500 1.02rem var(--display); padding: 8px 12px; border-radius: 2px; text-decoration: none; }
.nav-links > a:not(.btn):hover, .nav-links > a.active { background: rgba(255,255,255,.06); color: var(--gold); }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 3px; background: var(--text); margin: 4px 0; }
@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .nav-links { position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; padding: 12px 16px 18px; background: #0b121b; border-bottom: 2px solid var(--line); display: none; }
  .nav-links.open { display: flex; }
  .nav-links .btn { margin-top: 8px; }
}

/* ---------- layout ---------- */
.wrap { width: min(1200px, 100% - 32px); margin: 0 auto; }
.wrap-narrow { width: min(820px, 100% - 32px); margin: 0 auto; }
.section { padding: clamp(60px, 9vw, 120px) 0; position: relative; }
.page-head { padding: 56px 0 28px; position: relative; }
.page-head p { color: var(--muted); max-width: 680px; font-size: 1.1rem; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 900px) { .grid3, .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid2, .grid3 { grid-template-columns: minmax(0, 1fr); } .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }

/* ---------- hero ---------- */
.hero { position: relative; min-height: min(92vh, 900px); display: flex; align-items: flex-end; overflow: hidden; isolation: isolate; margin-top: -64px; padding-top: 64px; }
.hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; image-rendering: pixelated; }
.hero::after { content: ''; position: absolute; inset: auto 0 0 0; height: 45%; background: linear-gradient(180deg, transparent, rgba(10,16,24,.75) 55%, var(--bg)); z-index: -1; pointer-events: none; }
.hero-inner { padding: 0 0 clamp(40px, 7vh, 80px); width: min(1200px, 100% - 32px); margin: 0 auto; }
.hero h1 { text-shadow: 0 4px 0 rgba(0,0,0,.55), 0 0 40px rgba(0,0,0,.4); max-width: 18ch; }
.hero-inner { position: relative; }
.hero-inner::before { content: ''; position: absolute; left: -10vw; top: -40px; bottom: 0; width: min(900px, 90vw); background: radial-gradient(60% 55% at 35% 55%, rgba(6,10,18,.55), transparent 75%); z-index: -1; pointer-events: none; }
@media (max-width: 700px) { .hero-status { top: auto; bottom: 18px; right: 16px; font-size: 1rem; } }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero-lede { font-size: clamp(1.05rem, 1.6vw, 1.3rem); max-width: 600px; color: #e6e1d3; text-shadow: 0 2px 10px rgba(0,0,0,.7); }
.hero-status { position: absolute; top: 88px; right: clamp(16px, 4vw, 40px); font: 1.25rem var(--mono); letter-spacing: .1em; background: rgba(5,9,14,.65); border: 2px solid rgba(255,255,255,.12); padding: 6px 12px; display: flex; gap: 10px; align-items: center; }
.hero-status i { width: 10px; height: 10px; background: var(--red); box-shadow: 0 0 10px var(--red); animation: blink 1.2s steps(2) infinite; }
.hero-status.down i { background: var(--emerald); box-shadow: 0 0 10px var(--emerald); }
@keyframes blink { 50% { opacity: .25; } }
.scroll-cue { margin-top: 28px; display: inline-flex; gap: 10px; align-items: center; font: 1.15rem var(--mono); color: var(--muted); letter-spacing: .12em; }
.scroll-cue span { width: 14px; height: 22px; border: 2px solid var(--muted); position: relative; }
.scroll-cue span::after { content: ''; position: absolute; left: 3px; top: 3px; width: 4px; height: 5px; background: var(--gold); animation: cue 1.6s infinite; }
@keyframes cue { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(9px); opacity: 0; } 100% { opacity: 0; } }

.countdown { display: inline-flex; gap: 8px; margin: 6px 0 22px; }
.countdown div { background: rgba(5,9,14,.7); border: 2px solid rgba(255,255,255,.14); padding: 6px 10px 4px; min-width: 62px; text-align: center; }
.countdown b { display: block; font: 700 1.7rem var(--display); color: var(--gold); line-height: 1; }
.countdown small { font: 1rem var(--mono); color: var(--muted); letter-spacing: .1em; }

/* ---------- ticker / marquee ---------- */
.ticker { border-block: 2px solid var(--line); background: #0c141d; overflow: hidden; white-space: nowrap; }
.ticker-track { display: inline-flex; gap: 48px; padding: 14px 0; animation: tick 40s linear infinite; font: 1.35rem var(--mono); letter-spacing: .08em; color: var(--muted); }
.ticker-track span { display: inline-flex; align-items: center; gap: 12px; }
.ticker-track img { width: 24px; height: 24px; }
@keyframes tick { to { transform: translateX(-50%); } }

/* ---------- story ---------- */
.story { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: start; }
.story-stage { position: sticky; top: 90px; aspect-ratio: 1 / 1; max-height: calc(100vh - 120px); width: 100%; background: radial-gradient(120% 90% at 50% 20%, #13314a, #0a1622 70%); border: 2px solid var(--line); overflow: hidden; }
.story-stage .scene { position: absolute; inset: 0; opacity: 0; transform: scale(1.04); transition: opacity .7s ease, transform .9s cubic-bezier(.2,.8,.2,1); }
.story-stage .scene.on { opacity: 1; transform: none; }
.story-stage svg { width: 100%; height: 100%; display: block; }
.story-stage .scene-label { position: absolute; left: 16px; top: 14px; font: 1.2rem var(--mono); letter-spacing: .14em; color: var(--muted); }
.story-steps { display: flex; flex-direction: column; gap: 0; }
.step { min-height: 78vh; display: flex; flex-direction: column; justify-content: center; padding: 20px 0; opacity: .35; transition: opacity .5s; }
.step.on { opacity: 1; }
.step .num { font: 700 4.5rem/1 var(--display); color: transparent; -webkit-text-stroke: 2px var(--line2); margin-bottom: 8px; }
.step.on .num { -webkit-text-stroke-color: var(--gold); }
.step p { color: #cfd6d6; font-size: 1.1rem; }
.step .mini { display: none; }
@media (max-width: 860px) {
  .story { grid-template-columns: minmax(0, 1fr); }
  .story-stage { display: none; }
  .step { min-height: 0; opacity: 1; padding: 0 0 48px; }
  .step .mini { display: block; aspect-ratio: 4 / 3; border: 2px solid var(--line); margin-bottom: 18px; background: radial-gradient(120% 90% at 50% 20%, #13314a, #0a1622 70%); overflow: hidden; }
  .step .mini svg { width: 100%; height: 100%; }
}

/* svg scene animations (only when .on) */
.wallseg { transition: transform 1.1s cubic-bezier(.6,-0.2,.7,1), opacity 1.1s; transform-box: fill-box; transform-origin: center bottom; }
.on .wallseg, .mini.on .wallseg { transform: translateY(18px) scaleY(.1); opacity: 0; }
.on .wallseg:nth-child(2n) { transition-delay: .15s; } .on .wallseg:nth-child(3n) { transition-delay: .3s; }
.chainpath { stroke-dasharray: 1000; stroke-dashoffset: 1000; }
.on .chainpath { animation: draw 4.5s ease-in-out .3s infinite; }
@keyframes draw { 0% { stroke-dashoffset: 1000; } 70%, 100% { stroke-dashoffset: 0; } }
.shrinenode { transform-box: fill-box; transform-origin: center; }
.on .shrinenode { animation: pop 4.5s ease infinite; }
@keyframes pop { 0%, 8% { transform: scale(0); } 14% { transform: scale(1.3); } 20%, 100% { transform: scale(1); } }
.agebar { transform-box: fill-box; transform-origin: bottom; transform: scaleY(0); transition: transform .9s cubic-bezier(.2,.9,.2,1.2); }
.on .agebar { transform: none; }
.on .agebar:nth-of-type(2) { transition-delay: .2s; } .on .agebar:nth-of-type(3) { transition-delay: .4s; } .on .agebar:nth-of-type(4) { transition-delay: .6s; }
.beam { animation: beam 2.4s ease-in-out infinite; transform-box: fill-box; transform-origin: bottom; }
@keyframes beam { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
.spark { animation: spark 2.2s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes spark { 0% { transform: translate(0, 40px) scale(.2); opacity: 0; } 30% { opacity: 1; } 100% { transform: translate(var(--dx, 0), var(--dy, -60px)) scale(1); opacity: 0; } }
.bob { animation: bob 3s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-6px); } }
.waves { animation: waves 6s linear infinite; }
@keyframes waves { to { transform: translateX(-40px); } }

/* ---------- cards ---------- */
.feature { display: flex; gap: 16px; align-items: flex-start; }
.feature .ico { width: 48px; height: 48px; flex: none; background: #0b131c; border: 2px solid var(--line); display: grid; place-items: center; }
.feature .ico img { width: 32px; height: 32px; }
.feature h3 { font-size: 1.15rem; margin-bottom: .25em; }
.feature p { color: var(--muted); margin: 0; font-size: .97rem; }
.tilt { transition: transform .3s cubic-bezier(.2,.8,.2,1), border-color .3s; }
.tilt:hover { transform: translateY(-4px); border-color: var(--line2); }

.ages-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; position: relative; }
.age { padding: 24px 18px 20px; border: 2px solid var(--line); margin-left: -2px; background: var(--panel); position: relative; overflow: hidden; }
.age::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, var(--age, #888) 0%, transparent 60%); opacity: .14; }
.age .ag-ico { width: 48px; height: 48px; margin-bottom: 12px; animation: bob 3.2s ease-in-out infinite; }
.age:nth-child(2) .ag-ico { animation-delay: .4s; } .age:nth-child(3) .ag-ico { animation-delay: .8s; } .age:nth-child(4) .ag-ico { animation-delay: 1.2s; }
.age h3 { color: var(--age); }
.age p { color: var(--muted); font-size: .95rem; margin: 0; position: relative; }
.age .tier { font: 1.1rem var(--mono); color: var(--dim); letter-spacing: .1em; }
@media (max-width: 760px) { .ages-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.civ-strip { display: flex; flex-wrap: wrap; gap: 12px; }
.civ-chip { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; background: var(--panel); border: 2px solid var(--line); color: var(--text); text-decoration: none !important; transition: transform .2s, border-color .2s; }
.civ-chip:hover { transform: translateY(-2px); border-color: var(--c, var(--line2)); }
.civ-chip .sw { width: 28px; height: 28px; background: var(--c); box-shadow: inset 0 -4px 0 rgba(0,0,0,.25), inset 0 3px 0 rgba(255,255,255,.25); display: grid; place-items: center; font: 700 .65rem var(--display); color: #000a; overflow: hidden; }
.civ-chip .sw img { width: 100%; height: 100%; object-fit: cover; }
.civ-chip b { font-family: var(--display); }
.civ-chip small { font: 1rem var(--mono); color: var(--muted); }

.cta-band { position: relative; overflow: hidden; border: 2px solid var(--line); background: linear-gradient(120deg, #13261a, #0e1b26 60%); padding: clamp(28px, 5vw, 56px); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center; }
.cta-band canvas { position: absolute; right: 0; top: 0; height: 100%; width: 45%; opacity: .5; pointer-events: none; }
.cta-band > * { position: relative; }
@media (max-width: 700px) { .cta-band { grid-template-columns: minmax(0, 1fr); } }

/* ---------- forms ---------- */
.form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field > label, .label { font: 600 .92rem var(--body); color: #d9d4c5; }
.field .hint { font-size: .85rem; color: var(--dim); }
input[type=text], input[type=email], input[type=number], input[type=password], input[type=url], input[type=datetime-local], input[type=search], select, textarea {
  width: 100%; font: 1rem var(--body); color: var(--text); background: #0a121a; border: 2px solid var(--line); border-radius: 0; padding: 12px 14px; box-shadow: inset 0 3px 0 rgba(0,0,0,.35); transition: border-color .15s; }
input:hover, select:hover, textarea:hover { border-color: var(--line2); }
textarea { min-height: 110px; resize: vertical; }
input[type=color] { width: 56px; height: 48px; border: 2px solid var(--line); background: #0a121a; padding: 4px; cursor: pointer; }
.check { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; user-select: none; }
.check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check .box { width: 24px; height: 24px; flex: none; background: #0a121a; border: 2px solid var(--line2); box-shadow: inset 0 3px 0 rgba(0,0,0,.4); display: grid; place-items: center; margin-top: 1px; transition: background .15s; }
.check input:checked + .box { background: var(--grass); border-color: #000; }
.check input:checked + .box::after { content: ''; width: 10px; height: 6px; border-left: 4px solid #0b2a07; border-bottom: 4px solid #0b2a07; transform: rotate(-45deg) translate(1px, -1px); }
.check input:focus-visible + .box { outline: 3px solid var(--gold); outline-offset: 2px; }
.swatches { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.swatches button { width: 30px; height: 30px; border: 2px solid #000; cursor: pointer; box-shadow: inset 0 -4px 0 rgba(0,0,0,.25), inset 0 3px 0 rgba(255,255,255,.25); padding: 0; }
.swatches button[aria-pressed=true] { outline: 3px solid var(--text); outline-offset: 2px; }
.err { color: #ffb3a6; background: rgba(226,96,76,.12); border: 2px solid rgba(226,96,76,.45); padding: 10px 14px; font-size: .95rem; }
.ok { color: #c9f7d6; background: rgba(47,210,122,.1); border: 2px solid rgba(47,210,122,.4); padding: 10px 14px; }
.warn { color: #ffe3a3; background: rgba(242,193,78,.1); border: 2px solid rgba(242,193,78,.45); padding: 12px 14px; }
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
.copyrow { display: flex; gap: 0; }
.copyrow input { font-family: var(--mono); font-size: 1.15rem; }
.copyrow .btn { box-shadow: none; border-left: 0; }
.dropzone { border: 2px dashed var(--line2); padding: 22px; text-align: center; color: var(--muted); cursor: pointer; transition: border-color .2s, background .2s; position: relative; }
.dropzone.over { border-color: var(--gold); background: rgba(242,193,78,.06); }
.dropzone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

/* banner preview */
.banner-preview { display: flex; gap: 18px; align-items: center; }
.banner { width: 72px; height: 112px; flex: none; position: relative; transform-origin: top center; animation: wave 3.5s ease-in-out infinite; filter: drop-shadow(0 6px 0 rgba(0,0,0,.35)); }
.banner::before { content: ''; position: absolute; top: -8px; left: -8px; right: -8px; height: 8px; background: #6b4423; box-shadow: inset 0 -3px 0 #4a2e17; }
.banner .cloth { position: absolute; inset: 0; background: var(--c); clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 86%, 0 100%); box-shadow: inset 0 -10px 0 rgba(0,0,0,.18); display: grid; place-items: center; overflow: hidden; }
.banner .cloth::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 8px, rgba(0,0,0,.07) 8px 16px); }
.banner .cloth b { font: 700 1.05rem var(--display); color: rgba(0,0,0,.6); text-shadow: 0 1px 0 rgba(255,255,255,.25); position: relative; z-index: 1; margin-top: -12px; }
.banner .cloth img { width: 70%; height: auto; position: relative; z-index: 1; margin-top: -12px; image-rendering: auto; }
@keyframes wave { 0%, 100% { transform: skewY(0) scaleX(1); } 30% { transform: skewY(2deg) scaleX(.97); } 70% { transform: skewY(-2deg) scaleX(1.02); } }

/* ---------- civ page ---------- */
.civ-hero { position: relative; overflow: hidden; padding: 64px 0 40px; border-bottom: 2px solid var(--line); isolation: isolate; }
.civ-hero::before { content: ''; position: absolute; inset: 0; z-index: -2; background: radial-gradient(80% 120% at 80% 0%, color-mix(in srgb, var(--civ) 55%, transparent), transparent 60%), radial-gradient(60% 80% at 0% 100%, color-mix(in srgb, var(--civ) 25%, transparent), transparent 70%), var(--bg); }
.civ-hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: .55; image-rendering: pixelated; }
.civ-hero-inner { display: flex; gap: clamp(20px, 4vw, 44px); align-items: center; }
.civ-hero .banner { width: clamp(84px, 12vw, 128px); height: clamp(132px, 19vw, 200px); }
.civ-hero .banner .cloth b { font-size: clamp(1.1rem, 2.4vw, 1.8rem); }
.civ-tag { display: inline-block; font: 1.4rem var(--mono); letter-spacing: .1em; background: var(--civ); color: #000c; padding: 0 10px; margin-bottom: 10px; box-shadow: 0 3px 0 rgba(0,0,0,.5); }
.status-pill { display: inline-flex; gap: 8px; align-items: center; font: 1.15rem var(--mono); letter-spacing: .08em; padding: 2px 10px; border: 2px solid var(--line2); color: var(--muted); margin-left: 8px; vertical-align: middle; }
.status-pill.approved { color: var(--emerald); border-color: rgba(47,210,122,.5); }
.status-pill.pending { color: var(--gold); border-color: rgba(242,193,78,.5); }
.status-pill.rejected { color: var(--red); border-color: rgba(226,96,76,.5); }
.stat { padding: 18px; background: var(--panel); border: 2px solid var(--line); position: relative; overflow: hidden; }
.stat small { display: block; font: 1.1rem var(--mono); letter-spacing: .1em; color: var(--muted); text-transform: uppercase; }
.stat b { display: block; font: 700 2rem/1.1 var(--display); color: var(--text); margin-top: 4px; }
.stat .bar { height: 10px; background: #0a121a; border: 2px solid #000; margin-top: 10px; position: relative; overflow: hidden; }
.stat .bar i { position: absolute; inset: 0 auto 0 0; background: var(--civ); box-shadow: inset 0 -3px 0 rgba(0,0,0,.3); transition: width 1s cubic-bezier(.2,.8,.2,1); }
.stat .live-dot { position: absolute; top: 14px; right: 14px; width: 10px; height: 10px; background: var(--emerald); box-shadow: 0 0 12px var(--emerald); animation: blink 1.6s steps(2) infinite; }
.chain { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.chain i { width: 18px; height: 18px; background: #0a121a; border: 2px solid var(--line2); position: relative; }
.chain i.done { background: var(--civ); border-color: #000; box-shadow: 0 0 10px color-mix(in srgb, var(--civ) 60%, transparent); }
.chain i.home { border-color: var(--gold); }
.heads { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.head { display: flex; align-items: center; gap: 10px; background: var(--panel); border: 2px solid var(--line); padding: 8px; min-width: 0; animation: rise .5s both; }
.head img { width: 32px; height: 32px; flex: none; image-rendering: pixelated; background: #000; }
.head span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .92rem; }
.head .be { font: .95rem var(--mono); color: var(--muted); margin-left: auto; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.ally-chip { display: inline-flex; gap: 8px; align-items: center; padding: 6px 12px; border: 2px solid var(--c); background: color-mix(in srgb, var(--c) 12%, transparent); color: var(--text); text-decoration: none !important; font-family: var(--display); }
.ally-chip i { width: 14px; height: 14px; background: var(--c); }

/* ---------- checklist ---------- */
.checklist { display: grid; gap: 10px; }
.ck-item { display: grid; grid-template-columns: auto 1fr; gap: 14px; padding: 14px 16px; background: #0c151e; border: 2px solid var(--line); transition: border-color .2s, background .2s; }
.ck-item.done { border-color: rgba(108,198,68,.55); background: rgba(108,198,68,.06); }
.ck-item h4 { font-family: var(--body); font-size: 1rem; font-weight: 600; margin: 0 0 4px; }
.ck-item p { margin: 0; font-size: .92rem; color: var(--muted); }
.ck-item .links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.ck-progress { height: 14px; background: #0a121a; border: 2px solid #000; position: relative; margin: 6px 0 16px; overflow: hidden; }
.ck-progress i { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(90deg, var(--grass) 0 12px, var(--grass2) 12px 14px); transition: width .5s; }

/* ---------- tabs ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 2px solid var(--line); margin-bottom: 22px; overflow-x: auto; scrollbar-width: none; }
.tabs button { background: none; border: 2px solid transparent; border-bottom: 0; color: var(--muted); font: 600 1rem var(--display); padding: 10px 16px; cursor: pointer; white-space: nowrap; margin-bottom: -2px; }
.tabs button[aria-selected=true] { color: var(--text); background: var(--panel); border-color: var(--line); border-bottom: 2px solid var(--panel); }
.tabs button .badge { display: inline-block; min-width: 20px; background: var(--gold); color: #000; font: 700 .75rem var(--body); padding: 1px 6px; margin-left: 6px; }

/* ---------- tables ---------- */
.tbl-wrap { overflow-x: auto; border: 2px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th { text-align: left; font: 1.1rem var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: #0c151e; padding: 10px 12px; border-bottom: 2px solid var(--line); white-space: nowrap; }
td { padding: 10px 12px; border-bottom: 1px solid #1b2a38; vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: rgba(255,255,255,.025); }
.rank { font: 700 1.3rem var(--display); color: var(--dim); width: 44px; }
tr:nth-child(1) .rank { color: var(--gold); } tr:nth-child(2) .rank { color: #cfd6db; } tr:nth-child(3) .rank { color: #d08a4c; }
.cell-civ { display: flex; gap: 10px; align-items: center; }
.cell-civ .sw { width: 22px; height: 22px; background: var(--c); flex: none; box-shadow: inset 0 -3px 0 rgba(0,0,0,.25); }
.progress { height: 12px; background: #0a121a; border: 2px solid #000; position: relative; min-width: 90px; overflow: hidden; }
.progress i { position: absolute; inset: 0 auto 0 0; background: var(--c, var(--emerald)); transition: width 1s; }

/* ---------- wiki ---------- */
.wiki { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 36px; padding: 36px 0 80px; }
.wiki-side { position: sticky; top: 84px; align-self: start; max-height: calc(100vh - 100px); overflow: auto; }
.wiki-side .search { position: relative; margin-bottom: 14px; }
.wiki-side .search input { padding-left: 40px; }
.wiki-side .search img { position: absolute; left: 12px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); }
.wiki-nav { display: flex; flex-direction: column; gap: 2px; }
.wiki-nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; color: var(--muted); text-decoration: none !important; border-left: 3px solid transparent; font-weight: 500; }
.wiki-nav a img { width: 22px; height: 22px; }
.wiki-nav a:hover { color: var(--text); background: rgba(255,255,255,.03); }
.wiki-nav a.active { color: var(--text); border-left-color: var(--gold); background: rgba(242,193,78,.06); }
.wiki-nav a mark { background: rgba(242,193,78,.25); color: inherit; }
.wiki-nav .hit { font-size: .82rem; color: var(--dim); padding: 0 10px 6px 45px; margin-top: -4px; }
.wiki-body { min-width: 0; }
.wiki-body > .wk-hero { display: flex; gap: 20px; align-items: center; padding-bottom: 20px; border-bottom: 2px solid var(--line); margin-bottom: 28px; }
.wk-hero .big { width: 72px; height: 72px; flex: none; background: #0b131c; border: 2px solid var(--line); display: grid; place-items: center; animation: bob 3s ease-in-out infinite; }
.wk-hero .big img { width: 48px; height: 48px; }
.wk-hero p { margin: 0; color: var(--muted); }
.wiki-body h2 { font-size: 1.6rem; margin-top: 1.6em; }
.wiki-body h3 { margin-top: 1.4em; }
.wiki-body p, .wiki-body li { color: #d3d8d6; }
.wiki-body ul { padding-left: 1.2em; }
.wiki-body li { margin-bottom: .4em; }
.wiki-body li::marker { color: var(--gold); }
.diagram { background: radial-gradient(120% 100% at 50% 0%, #142a3c, #0a141d 75%); border: 2px solid var(--line); margin: 20px 0 26px; position: relative; overflow: hidden; }
.diagram svg { display: block; width: 100%; height: auto; }
.diagram figcaption { font: 1.1rem var(--mono); color: var(--muted); letter-spacing: .06em; padding: 8px 14px; border-top: 2px solid var(--line); background: #0b131c; }
.diagram.reveal svg * { animation-play-state: paused; }
.diagram.reveal.in svg * { animation-play-state: running; }
.wk-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin: 18px 0; }
.wk-card { background: var(--panel); border: 2px solid var(--line); padding: 16px; position: relative; overflow: hidden; transition: transform .25s, border-color .25s; }
.wk-card:hover { transform: translateY(-3px); border-color: var(--line2); }
.wk-card .ic { width: 40px; height: 40px; margin-bottom: 8px; }
.wk-card h4 { margin: 0 0 4px; font-size: 1.1rem; }
.wk-card p { margin: 0; font-size: .92rem; color: var(--muted) !important; }
.wk-card .tagline { font: 1rem var(--mono); color: var(--gold); letter-spacing: .08em; }
.callout { border-left: 4px solid var(--gold); background: rgba(242,193,78,.06); padding: 12px 16px; margin: 18px 0; color: #e7dfc5; }
.callout.tbd { border-left-color: var(--stone); background: rgba(138,143,148,.08); color: var(--muted); font-size: .93rem; }
.cmd { font: 1.25rem var(--mono); color: #b8f5c8; background: #050b10; padding: 1px 8px; border: 1px solid #1b2a38; white-space: nowrap; }
.term { background: #050b10; border: 2px solid var(--line); padding: 16px 18px; font: 1.25rem/1.5 var(--mono); color: #b8f5c8; overflow-x: auto; }
.term .c { color: var(--dim); }
.hearts { display: flex; flex-wrap: wrap; gap: 4px; }
.hearts img { width: 26px; height: 26px; }
.hearts img.new { animation: heartin 2.4s ease infinite; }
@keyframes heartin { 0%, 20% { transform: scale(0); opacity: 0; } 35% { transform: scale(1.35); opacity: 1; } 50%, 100% { transform: scale(1); } }
.wiki-empty { color: var(--muted); padding: 30px 0; }
@media (max-width: 900px) {
  .wiki { grid-template-columns: minmax(0, 1fr); gap: 20px; padding-top: 20px; }
  .wiki-side { position: static; max-height: none; }
  .wiki-nav { flex-direction: row; overflow-x: auto; gap: 4px; padding-bottom: 6px; scrollbar-width: thin; }
  .wiki-nav a { border-left: 0; border-bottom: 3px solid transparent; white-space: nowrap; }
  .wiki-nav a.active { border-bottom-color: var(--gold); }
  .wiki-nav .hit { display: none; }
}

/* ---------- availability grid ---------- */
.avail { overflow-x: auto; border: 2px solid var(--line); background: #0a121a; touch-action: pan-x; user-select: none; -webkit-user-select: none; }
.avail.painting { touch-action: none; }
.avail table { border-collapse: separate; border-spacing: 2px; width: auto; min-width: 100%; font-size: .78rem; }
.avail th { background: none; border: 0; padding: 4px 2px; font-size: .95rem; text-align: center; color: var(--muted); }
.avail th.rowh { width: 1%; white-space: nowrap; text-align: right; padding-right: 8px; position: sticky; left: 0; background: #0a121a; z-index: 1; }
.avail th .dow { display: block; color: var(--dim); font-size: .85rem; }
.avail td { padding: 0; border: 0; width: 46px; min-width: 40px; height: 26px; background: #15222e; cursor: pointer; position: relative; transition: background .1s; }
.avail td.x { background: repeating-linear-gradient(135deg, #1a1414 0 4px, #241a1a 4px 8px); cursor: not-allowed; }
.avail td.none { background: transparent; cursor: default; }
.avail td.on { background: var(--grass); box-shadow: inset 0 -3px 0 var(--grass2); }
.avail.view td { cursor: crosshair; }
.avail th.xmas { color: var(--red); }
.avail-legend { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: .88rem; color: var(--muted); margin: 10px 0; }
.avail-legend .scale { display: flex; } .avail-legend .scale i { width: 22px; height: 14px; }
.avail-tip { position: fixed; z-index: 60; pointer-events: none; background: #050b10; border: 2px solid var(--line2); padding: 8px 10px; font-size: .85rem; max-width: 260px; display: none; }
.avail-tip b { font-family: var(--display); }

/* ---------- uploads ---------- */
.upl { display: grid; gap: 10px; margin-top: 14px; }
.upl-item { background: #0c151e; border: 2px solid var(--line); padding: 12px 14px; display: grid; gap: 8px; }
.upl-item .top { display: flex; justify-content: space-between; gap: 10px; align-items: center; flex-wrap: wrap; }
.upl-item .name { font-weight: 600; overflow-wrap: anywhere; }
.upl-bar { height: 12px; background: #050b10; border: 2px solid #000; position: relative; overflow: hidden; }
.upl-bar i { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(90deg, var(--gold) 0 10px, var(--gold2) 10px 12px); transition: width .3s; }
.upl-item.done .upl-bar i { background: var(--grass); }
.upl-item.err .upl-bar i { background: var(--red); }

/* ---------- admin ---------- */
.adm-civ { border: 2px solid var(--line); background: var(--panel); margin-bottom: 12px; }
.adm-civ > summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 16px; }
.adm-civ > summary::-webkit-details-marker { display: none; }
.adm-civ[open] > summary { border-bottom: 2px solid var(--line); }
.adm-civ .body { padding: 16px; display: grid; gap: 16px; }
.kv { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 6px 14px; font-size: .93rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.mini-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; align-items: end; }
.mini-form .field label { font-size: .82rem; }
.mini-form input, .mini-form select { padding: 8px 10px; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 200px); opacity: 0; background: #050b10; border: 2px solid var(--gold); padding: 12px 18px; z-index: 80; font-weight: 500; transition: transform .35s cubic-bezier(.2,.9,.3,1.3); max-width: calc(100% - 32px); }
.toast.show { transform: translate(-50%, 0); opacity: 1; }

/* ---------- live ---------- */
.event-banner { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; padding: 16px 20px; background: linear-gradient(90deg, rgba(242,193,78,.12), transparent); border: 2px solid rgba(242,193,78,.35); }
.event-banner b { font-family: var(--display); font-size: 1.3rem; }
.map-frame { aspect-ratio: 16 / 9; border: 2px solid var(--line); background: #071019; position: relative; overflow: hidden; }
.map-frame iframe { width: 100%; height: 100%; border: 0; }
.map-placeholder { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 20px; color: var(--muted); }

/* ---------- foot ---------- */
.foot { border-top: 2px solid var(--line); background: #080d14; margin-top: 60px; }
.foot-inner { width: min(1200px, 100% - 32px); margin: 0 auto; padding: 36px 0 28px; display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr) auto; }
.foot-brand { display: flex; gap: 14px; align-items: center; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; }
.foot-links a { color: var(--muted); }
.foot-fine { grid-column: 1 / -1; color: var(--dim); font-size: .82rem; margin: 0; }
@media (max-width: 700px) { .foot-inner { grid-template-columns: minmax(0, 1fr); } }

.reveal-up { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .8s cubic-bezier(.2,.8,.2,1); }
.reveal-up.in { opacity: 1; transform: none; }
.loading { padding: 80px 0; text-align: center; color: var(--muted); font: 1.4rem var(--mono); letter-spacing: .1em; }
.loading::after { content: '...'; display: inline-block; width: 1.5em; text-align: left; animation: dots 1.2s steps(4) infinite; overflow: hidden; vertical-align: bottom; }
@keyframes dots { from { width: 0; } to { width: 1.5em; } }
.sep { height: 2px; background: var(--line); margin: 24px 0; border: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal-up { opacity: 1; transform: none; }
  .chainpath { stroke-dashoffset: 0; }
  .ticker-track { animation: none; }
}
.score-bars { display: grid; gap: 10px; }
.sb { display: grid; grid-template-columns: minmax(130px, 200px) minmax(0, 1fr) 48px; gap: 12px; align-items: center; }
.sb-l { display: flex; align-items: center; gap: 8px; font-size: .93rem; }
.sb-l img { width: 22px; height: 22px; }
.sb-t { height: 16px; background: #0a121a; border: 2px solid #000; position: relative; overflow: hidden; }
.sb-t i { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(90deg, var(--gold) 0 10px, var(--gold2) 10px 12px); transform-origin: left; transform: scaleX(0); transition: transform 1s cubic-bezier(.2,.8,.2,1); }
.diagram.in .sb-t i { transform: none; }
.sb b { font-family: var(--display); color: var(--gold); text-align: right; }
@media (max-width: 520px) { .sb { grid-template-columns: minmax(0, 1fr) 40px; } .sb-t { grid-column: 1 / -1; grid-row: 2; } }

@media (max-width: 860px) { .grid2[style*='grid-template-columns'] { grid-template-columns: minmax(0, 1fr) !important; } #previewCard { position: static !important; } }
@media (max-width: 560px) { .copyrow { flex-direction: column; } .copyrow .btn { border-left: 2px solid #000; } }
/* ---------- onboarding ---------- */
.stepper { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.stp { display: flex; flex-direction: column; align-items: center; gap: 6px; background: none; border: 0; color: var(--dim); font: 600 .82rem var(--body); cursor: pointer; padding: 4px 2px; }
.stp:disabled { cursor: default; opacity: .5; }
.stp-ic { width: 44px; height: 44px; display: grid; place-items: center; background: #0b131c; border: 2px solid var(--line); transition: transform .35s cubic-bezier(.2,.9,.3,1.4), border-color .3s, background .3s; filter: grayscale(1) brightness(.8); }
.stp.done .stp-ic { border-color: rgba(108,198,68,.6); background: rgba(108,198,68,.12); filter: none; }
.stp.cur { color: var(--text); }
.stp.cur .stp-ic { border-color: var(--gold); background: rgba(242,193,78,.12); transform: translateY(-3px); filter: none; box-shadow: 0 6px 0 rgba(0,0,0,.35), 0 0 22px rgba(242,193,78,.18); }
.xp { height: 14px; margin: 14px 0 26px; background: #050b10; border: 2px solid #000; position: relative; overflow: hidden; }
.xp i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(180deg, #9be06a, #4fae37); box-shadow: inset 0 -3px 0 rgba(0,0,0,.25); transition: width .8s cubic-bezier(.2,.8,.2,1); }
.xp span { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font: 1rem var(--mono); color: #fff; text-shadow: 0 1px 0 #000; }
@media (max-width: 560px) { .stp-t { display: none; } .stp-ic { width: 38px; height: 38px; } }
.onb-stage.enter > * { animation: stageIn .55s cubic-bezier(.2,.8,.2,1) both; }
@keyframes stageIn { from { opacity: 0; transform: translateY(14px) scale(.99); } }
.onb-card { background: linear-gradient(180deg, var(--panel2), var(--panel)); border: 2px solid var(--line); padding: clamp(22px, 4vw, 40px); text-align: center; box-shadow: inset 0 2px 0 rgba(255,255,255,.04), 0 24px 60px -30px #000; }
.onb-h { font-size: clamp(1.8rem, 4.6vw, 2.8rem); }
.onb-h em { font-style: normal; color: var(--gold); }
.clerk-mount { display: flex; justify-content: center; margin-top: 18px; min-height: 380px; }
.mc-preview { display: flex; gap: 14px; align-items: flex-end; }
.mc-preview img { border: 3px solid #000; box-shadow: 0 5px 0 rgba(0,0,0,.4); background: #0a121a; }
.seg { display: grid; grid-template-columns: 1fr 1fr; border: 2px solid var(--line); }
.seg label { cursor: pointer; }
.seg input { position: absolute; opacity: 0; }
.seg span { display: block; text-align: center; padding: 12px; font: 600 1rem var(--display); color: var(--muted); transition: background .2s, color .2s; }
.seg input:checked + span { background: var(--gold); color: #2a1b03; }
.seg input:focus-visible + span { outline: 3px solid var(--gold); outline-offset: -3px; }
.choice2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 24px; }
@media (max-width: 560px) { .choice2 { grid-template-columns: 1fr; } }
.choice { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 26px 18px; background: #0c151e; border: 2px solid var(--line); color: var(--text); cursor: pointer; transition: transform .3s cubic-bezier(.2,.8,.2,1), border-color .3s, background .3s; font: inherit; }
.choice:hover, .choice:focus-visible { transform: translateY(-4px); border-color: var(--gold); background: rgba(242,193,78,.06); }
.choice b { font: 700 1.25rem var(--display); }
.choice small { color: var(--muted); }
.ch-ic { width: 72px; height: 72px; display: grid; place-items: center; background: #0a121a; border: 2px solid var(--line); transition: transform .4s cubic-bezier(.2,.9,.3,1.5); }
.choice:hover .ch-ic { transform: rotate(-6deg) scale(1.08); }
.civ-list { display: grid; gap: 8px; max-height: 420px; overflow: auto; }
.civ-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 12px; background: #0c151e; border: 2px solid var(--line); transition: border-color .2s; }
.civ-row:hover, .civ-row.hl { border-color: var(--c); }
.civ-row .sw { width: 36px; height: 36px; background: var(--c); display: grid; place-items: center; font: 700 .7rem var(--display); color: #000a; overflow: hidden; box-shadow: inset 0 -4px 0 rgba(0,0,0,.25); }
.civ-row .sw img { width: 100%; height: 100%; object-fit: cover; }
.civ-row .nm { display: flex; flex-direction: column; min-width: 0; }
.civ-row .nm b { font-family: var(--display); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.civ-row .nm small { color: var(--muted); }
.addr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 22px; text-align: left; }
@media (max-width: 560px) { .addr-grid { grid-template-columns: 1fr; } }
.addr { background: #050b10; border: 2px solid var(--line); padding: 12px 14px; display: grid; gap: 4px; }
.addr small { font: 1rem var(--mono); letter-spacing: .12em; color: var(--muted); }
.addr b { font: 700 1.35rem var(--display); color: var(--gold); overflow-wrap: anywhere; }
.addr .btn { justify-self: start; }
.done-card { position: relative; overflow: hidden; }
.done-card::before { content: ''; position: absolute; inset: -40% -10% auto; height: 80%; background: radial-gradient(closest-side, rgba(242,193,78,.18), transparent); pointer-events: none; }
/* ---------- motion polish ---------- */
.btn { transition: transform .18s cubic-bezier(.2,.8,.2,1), filter .2s, box-shadow .2s; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(3px); }
.panel.tilt:hover, .wk-card:hover { box-shadow: inset 0 2px 0 rgba(255,255,255,.05), 0 18px 40px -22px rgba(0,0,0,.9), 0 0 0 1px rgba(242,193,78,.12); }
.feature .ico { transition: transform .4s cubic-bezier(.2,.9,.3,1.5); }
.feature:hover .ico { transform: rotate(-6deg) scale(1.08); }
.hero-inner { will-change: transform, opacity; }
.shot { position: relative; overflow: hidden; border: 2px solid var(--line); background: #071019; }
.shot img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); transition: transform 1.6s cubic-bezier(.2,.8,.2,1); }
.shot:hover img { transform: scale(1.08); }
.shot figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 14px 10px; background: linear-gradient(transparent, rgba(5,9,14,.85)); font: 1.15rem var(--mono); color: #dfe6e6; letter-spacing: .06em; }
.shot .tag { position: absolute; top: 10px; left: 10px; font: 1rem var(--mono); letter-spacing: .12em; background: rgba(5,9,14,.75); border: 1px solid rgba(255,255,255,.15); padding: 1px 8px; color: var(--gold); }
.gallery { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; gap: 12px; aspect-ratio: 16 / 8; }
.gallery .shot:first-child { grid-row: 1 / 3; }
@media (max-width: 760px) { .gallery { grid-template-columns: 1fr; grid-template-rows: none; aspect-ratio: auto; } .gallery .shot { aspect-ratio: 16 / 9; } .gallery .shot:first-child { grid-row: auto; } }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .reveal-up { opacity: 1; transform: none; transition: none; animation: revealScroll linear both; animation-timeline: view(); animation-range: entry 0% cover 28%; }
    @keyframes revealScroll { from { opacity: 0; transform: translateY(36px) scale(.985); } to { opacity: 1; transform: none; } }
    .shot img { animation: shotZoom linear both; animation-timeline: view(); animation-range: cover 0% cover 100%; transition: none; }
    @keyframes shotZoom { from { transform: scale(1.12) translateY(-2%); } to { transform: scale(1.02) translateY(2%); } }
  }
}
.hero-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -3; transform: scale(1.08); animation: kenburns 40s ease-in-out infinite alternate; filter: saturate(1.1) brightness(.78); }
@keyframes kenburns { from { transform: scale(1.08) translate(0, 0); } to { transform: scale(1.18) translate(-2%, -1.5%); } }
.hero:has(.hero-photo)::before { content: ''; position: absolute; inset: 0; z-index: -2; background: linear-gradient(180deg, rgba(10,16,24,.55), rgba(10,16,24,.1) 35%, rgba(10,16,24,.15) 60%, rgba(10,16,24,.9)), radial-gradient(70% 60% at 25% 60%, rgba(6,10,18,.55), transparent 70%); pointer-events: none; }
.hero:has(.hero-photo) canvas { z-index: -1; }
.hero-logo { display: block; width: clamp(64px, 8vw, 96px); height: auto; image-rendering: pixelated; margin-bottom: 16px; filter: drop-shadow(0 6px 0 rgba(0,0,0,.45)); animation: logoIn .9s cubic-bezier(.2,.9,.3,1.3) both; }
@keyframes logoIn { from { opacity: 0; transform: translateY(-14px) scale(.9) rotate(-4deg); } }
.hero h1, .hero .eyebrow, .hero-lede, .hero .row { animation: heroIn .9s cubic-bezier(.2,.8,.2,1) both; }
.hero .eyebrow { animation-delay: .1s; } .hero h1 { animation-delay: .18s; } .hero-lede { animation-delay: .3s; } .hero .row { animation-delay: .42s; }
@keyframes heroIn { from { opacity: 0; transform: translateY(18px); } }
/* ---------- onboarding system ---------- */
.tick { width: 22px; height: 22px; background: var(--grass); position: relative; display: inline-block; box-shadow: inset 0 -3px 0 var(--grass2); animation: tickIn .45s cubic-bezier(.2,.9,.3,1.6) both; }
.tick::after { content: ''; position: absolute; left: 5px; top: 5px; width: 10px; height: 5px; border-left: 3px solid #0b2a07; border-bottom: 3px solid #0b2a07; transform: rotate(-45deg); }
.tick.sm { width: 18px; height: 18px; } .tick.sm::after { left: 4px; top: 4px; width: 8px; height: 4px; }
@keyframes tickIn { from { transform: scale(0) rotate(-30deg); } }
.stp.own .stp-ic { border-style: dashed; }
.stp:disabled { opacity: 1; }
@media (max-width: 760px) { .stepper .stp-t { display: none; } .stepper { gap: 3px; } .stp-ic { width: 32px; height: 32px; } .stp-ic img { width: 18px; height: 18px; } }
.onb-kicker { font: 1.1rem var(--mono); letter-spacing: .16em; color: var(--gold); margin-bottom: 6px; }
.onb-sub { max-width: 520px; margin: 0 auto; }
.onb-card.left { text-align: left; } .onb-card.left .onb-sub { margin: 0; }
.onb-form { max-width: 460px; margin: 22px auto 0; text-align: left; }
.big-input { font-size: 1.15rem !important; padding: 14px 16px !important; }
.big-action { display: flex; justify-content: center; margin-top: 24px; }
.onb-skip { color: var(--muted); }
.skin-stage { height: 190px; display: grid; place-items: center; position: relative; background: radial-gradient(closest-side, rgba(242,193,78,.14), transparent 70%); }
.skin-stage::after { content: ''; position: absolute; bottom: 8px; width: 90px; height: 10px; background: rgba(0,0,0,.45); border-radius: 50%; filter: blur(3px); }
.skin { height: 160px; width: auto; image-rendering: pixelated; position: relative; z-index: 1; animation: idle 3.2s ease-in-out infinite; }
.skin.pop { animation: skinPop .5s cubic-bezier(.2,.9,.3,1.5), idle 3.2s ease-in-out .5s infinite; }
@keyframes idle { 50% { transform: translateY(-4px); } }
@keyframes skinPop { from { transform: scale(.85) rotate(-4deg); opacity: .4; } }
.skin-name { position: absolute; top: 4px; font: 1.1rem var(--mono); background: rgba(0,0,0,.55); padding: 0 8px; color: #fff; }
.empty { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 22px; border: 2px dashed var(--line2); color: var(--muted); }
.empty p { margin: 0; } .empty.slim { padding: 10px; margin-bottom: 12px; }
.civ-row { animation: rise .45s both; }
.recruit { margin-top: 20px; text-align: left; }
.recruit-bar { height: 22px; background: #050b10; border: 2px solid #000; position: relative; margin-bottom: 6px; }
.recruit-bar i { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(90deg, var(--grass) 0 14px, var(--grass2) 14px 16px); transition: width 1s cubic-bezier(.2,.8,.2,1); }
.recruit-bar b { position: absolute; top: -6px; bottom: -6px; width: 3px; background: var(--gold); box-shadow: 0 0 10px var(--gold); }
.setup-widget { position: fixed; right: 16px; bottom: 16px; z-index: 50; display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: rgba(12,20,29,.94); backdrop-filter: blur(10px); border: 2px solid var(--line2); box-shadow: 0 18px 40px -16px #000, 0 0 0 1px rgba(242,193,78,.08); max-width: calc(100% - 32px); animation: widgetIn .5s cubic-bezier(.2,.9,.3,1.2) both; transition: opacity .3s, transform .3s; }
.setup-widget.out { opacity: 0; transform: translateY(20px); }
@keyframes widgetIn { from { opacity: 0; transform: translateY(24px) scale(.96); } }
.sw-ring { --p: 0; width: 44px; height: 44px; flex: none; border-radius: 50%; background: conic-gradient(var(--gold) calc(var(--p) * 1%), #1b2a38 0); display: grid; place-items: center; }
.sw-ring span { width: 34px; height: 34px; border-radius: 50%; background: #0c141d; display: grid; place-items: center; font: 700 .72rem var(--body); }
.sw-t { display: flex; flex-direction: column; min-width: 0; }
.sw-t small { font: 1rem var(--mono); letter-spacing: .12em; color: var(--muted); line-height: 1; }
.sw-t b { font: 600 .95rem var(--body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 220px; }
.sw-x { background: none; border: 0; color: var(--dim); font-size: 1.3rem; cursor: pointer; padding: 0 4px; }
.sw-x:hover { color: var(--text); }
@media (max-width: 560px) { .setup-widget { left: 12px; right: 12px; bottom: 12px; } .sw-t b { max-width: none; } }
.setup-list { display: grid; gap: 6px; }
.setup-item { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 12px; background: #0c151e; border: 2px solid var(--line); color: var(--text); text-decoration: none !important; font: 500 .97rem var(--body); cursor: pointer; text-align: left; transition: border-color .2s, transform .2s, background .2s; }
.setup-item:hover { border-color: var(--line2); transform: translateX(3px); }
.setup-item.done { color: var(--muted); } .setup-item.done span { text-decoration: line-through; text-decoration-color: rgba(148,163,173,.4); }
.setup-item.next { border-color: var(--gold); background: rgba(242,193,78,.06); }
.setup-item i { font-style: normal; color: var(--gold); }
.own-tag { font: .9rem var(--mono); letter-spacing: .1em; color: var(--gold); border: 1px solid rgba(242,193,78,.4); padding: 0 5px; margin-left: 4px; }
.next-action { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 16px; margin: 0 0 20px; background: linear-gradient(90deg, rgba(242,193,78,.12), rgba(242,193,78,.02)); border: 2px solid rgba(242,193,78,.4); animation: rise .5s both; }
.next-action small { display: block; font: 1rem var(--mono); letter-spacing: .14em; color: var(--gold); }
.next-action b { font: 600 1.05rem var(--body); }
.na-ic { width: 46px; height: 46px; display: grid; place-items: center; background: #0a121a; border: 2px solid var(--line); }
@media (max-width: 520px) { .next-action { grid-template-columns: auto minmax(0, 1fr); } .next-action .btn { grid-column: 1 / -1; } }
.tour-ov { position: fixed; left: var(--x, 0); top: var(--y, 0); width: var(--w, 0); height: var(--h, 0); z-index: 90; box-shadow: 0 0 0 9999px rgba(3,6,10,.72); border: 2px solid var(--gold); pointer-events: none; transition: left .35s cubic-bezier(.2,.8,.2,1), top .35s cubic-bezier(.2,.8,.2,1), width .35s, height .35s; }
.tour-tip { position: fixed; z-index: 91; width: min(320px, calc(100% - 24px)); background: #0c141d; border: 2px solid var(--gold); padding: 14px 16px; box-shadow: 0 20px 50px -20px #000; opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .3s, top .35s, left .35s; }
.tour-tip.in { opacity: 1; transform: none; }
.tour-tip small { font: 1rem var(--mono); color: var(--gold); letter-spacing: .12em; }
.tour-tip b { display: block; font: 700 1.15rem var(--display); margin: 2px 0 4px; }
.tour-tip p { color: var(--muted); font-size: .93rem; margin: 0 0 12px; }
.confetti { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.confetti i { position: absolute; top: -10px; width: 8px; height: 8px; animation: conf 2.6s cubic-bezier(.3,.6,.4,1) forwards; }
@keyframes conf { to { transform: translate(var(--dx), 520px) rotate(540deg); opacity: 0; } }
.addr.hl { border-color: var(--gold); }
