/* Weekend Raid outer site. Art direction: PS1-retro low-poly + Borderlands-style ink outlines and cel shading.
   Every color is a CSS custom property set from data/weekend.json "palette" (js/content.js applyPalette). */
@font-face { font-family: "Bangers"; src: url("../assets/fonts/bangers-latin.woff2") format("woff2"); font-display: swap; }

:root {
  --wr-bg: #120a12; --wr-surface: #1e121c; --wr-surface-2: #2b1a24; --wr-line: #4a2f33; --wr-ink: #050306;
  --wr-text: #fbeee2; --wr-muted: #cdb6a8; --wr-accent: #ff6a1a; --wr-on-accent: #1a0700; --wr-accent-2: #ffd34d;
  --wr-glow: #ff5a1f; --wr-danger: #ff7b6b; --wr-ok: #7dffa6;
  --display: "Bangers", "Impact", "Arial Narrow Bold", system-ui, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ink-w: 3px; --hard: 5px 5px 0 var(--wr-ink); --radius: 6px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--wr-bg); color: var(--wr-text); font: 16px/1.55 var(--body); }
img, svg { max-width: 100%; display: block; }
a { color: var(--wr-accent-2); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
strong { color: inherit; }
[hidden] { display: none !important; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--wr-muted); } .small { font-size: .9rem; }
:focus-visible { outline: 3px solid var(--wr-accent-2); outline-offset: 3px; border-radius: 2px; }
main:focus { outline: none; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--wr-accent); color: var(--wr-on-accent); padding: 10px 14px; font-weight: 800; border: var(--ink-w) solid var(--wr-ink); text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- demo bar ---------- */
.demo-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; max-height: 70vh; overflow: auto; border-top: 2px solid var(--wr-ink); background: repeating-linear-gradient(-45deg, #2a2200 0 14px, #231c00 14px 28px); color: #ffe9a6; font-size: .88rem; padding: 6px 16px; display: flex; flex-wrap: wrap; gap: 4px 16px; align-items: center; justify-content: center; }
.demo-bar p { margin: 0; }
.demo-bar a, .demo-bar .link { color: #ffe9a6; }
.demo-tools summary { cursor: pointer; font-weight: 700; text-decoration: underline; }
.demo-grid { display: grid; gap: 6px; padding: 8px 0 4px; }
.demo-grid > div { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.dt { font-weight: 800; min-width: 7.5em; }
.dt-src { margin: 4px 0 0; opacity: .9; }
button.link { background: none; border: 0; padding: 0; font: inherit; text-decoration: underline; cursor: pointer; }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 14px; padding: 10px clamp(12px, 3vw, 28px);
  background: color-mix(in srgb, var(--wr-bg) 92%, transparent); backdrop-filter: blur(6px); border-bottom: var(--ink-w) solid var(--wr-ink); box-shadow: 0 2px 0 var(--wr-line); }
.logo { font-family: var(--display); font-size: 1.7rem; letter-spacing: .04em; line-height: 1; text-decoration: none; color: var(--wr-text); display: flex; gap: .25em;
  text-shadow: 2px 2px 0 var(--wr-ink); white-space: nowrap; }
.logo-2 { color: var(--wr-accent); }
.site-header nav ul { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; }
.site-header nav a { color: var(--wr-text); text-decoration: none; font-weight: 700; padding: 8px 10px; border-radius: var(--radius); }
.site-header nav a:hover { background: var(--wr-surface-2); }
.gate-pill { margin: 0 0 0 auto; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border: 2px solid var(--wr-ink); border-radius: 99px;
  background: var(--wr-surface-2); font-weight: 800; font-size: .88rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.gate-pill .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--wr-danger); box-shadow: 0 0 0 2px var(--wr-ink); }
.gate-pill[data-state=open] .dot { background: var(--wr-ok); animation: pulse 1.6s ease-in-out infinite; }
.account { display: flex; align-items: center; gap: 8px; }
.whoami { font-size: .85rem; color: var(--wr-muted); max-width: 16ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@keyframes pulse { 50% { box-shadow: 0 0 0 2px var(--wr-ink), 0 0 0 6px color-mix(in srgb, var(--wr-ok) 35%, transparent); } }

/* ---------- buttons ---------- */
.btn { --bg: var(--wr-surface-2); --fg: var(--wr-text); display: inline-flex; align-items: center; justify-content: center; gap: .4em; min-height: 44px;
  padding: 10px 18px; background: var(--bg); color: var(--fg); border: var(--ink-w) solid var(--wr-ink); border-radius: var(--radius); box-shadow: 4px 4px 0 var(--wr-ink);
  font: 400 1.2rem/1 var(--display); letter-spacing: .06em; text-decoration: none; cursor: pointer; transition: transform .08s, box-shadow .08s; text-transform: uppercase; }
.btn:hover { transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--wr-ink); }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--wr-ink); }
.btn-primary { --bg: var(--wr-accent); --fg: var(--wr-on-accent); }
.btn-ghost { --bg: transparent; box-shadow: none; border-color: var(--wr-line); }
.btn-ghost:hover { box-shadow: none; border-color: var(--wr-text); }
.btn-sm { min-height: 36px; padding: 6px 12px; font-size: 1rem; box-shadow: 3px 3px 0 var(--wr-ink); }
.btn-lg { min-height: 54px; padding: 12px 26px; font-size: 1.45rem; }
.btn-xl { min-height: 68px; font-size: 2.2rem; letter-spacing: .14em; }
.btn-block { width: 100%; }
.btn:disabled, .btn.is-disabled { opacity: .5; cursor: not-allowed; transform: none; box-shadow: 2px 2px 0 var(--wr-ink); filter: grayscale(.5); }
.btn[aria-busy=true] { cursor: progress; }

/* ---------- hero ---------- */
.hero { position: relative; isolation: isolate; min-height: min(92vh, 860px); display: grid; align-items: end; overflow: hidden; border-bottom: var(--ink-w) solid var(--wr-ink); }
.hero-art { position: absolute; inset: 0; z-index: -1; background: var(--wr-surface); }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.hero-fx { position: absolute; inset: 0;
  background:
    repeating-linear-gradient(0deg, rgb(0 0 0 / .18) 0 1px, transparent 1px 3px),                        /* PS1 scanlines */
    linear-gradient(90deg, var(--wr-bg) 0%, color-mix(in srgb, var(--wr-bg) 82%, transparent) 34%, transparent 70%),
    linear-gradient(0deg, var(--wr-bg) 3%, color-mix(in srgb, var(--wr-bg) 78%, transparent) 30%, transparent 62%); }
.hero-inner { width: min(1200px, 100%); margin: 0 auto; padding: clamp(110px, 18vh, 200px) clamp(16px, 4vw, 40px) clamp(28px, 6vh, 64px); }
.kicker { margin: 0 0 6px; text-transform: uppercase; letter-spacing: .14em; font-weight: 800; font-size: .82rem; color: var(--wr-accent-2); text-shadow: 1px 1px 0 var(--wr-ink); }
.boss-name { margin: 0; font: 400 clamp(3.2rem, min(9vw, 15vh), 8.4rem)/.9 var(--display); letter-spacing: .02em; color: var(--wr-text);
  -webkit-text-stroke: 2px var(--wr-ink); paint-order: stroke fill; text-shadow: 4px 4px 0 var(--wr-ink), 0 0 40px color-mix(in srgb, var(--wr-glow) 55%, transparent); transform: rotate(-2deg); transform-origin: left bottom; max-width: 13ch; }
.boss-title { display: block; min-height: 1em; margin-left: .1em; font-size: .36em; letter-spacing: .06em; color: var(--wr-accent); -webkit-text-stroke: 1px var(--wr-ink); margin-top: .2em; }
.tagline { min-height: 3.1em; font-size: clamp(1.05rem, 2.2vw, 1.3rem); max-width: 40ch; margin: 18px 0 20px; text-shadow: 1px 1px 0 var(--wr-ink), 0 0 12px var(--wr-bg); }
.countdown { display: inline-block; background: color-mix(in srgb, var(--wr-surface) 92%, transparent); border: var(--ink-w) solid var(--wr-ink); box-shadow: var(--hard); border-radius: var(--radius); padding: 12px 16px 10px; max-width: 100%; }
.countdown[data-state=open] { border-color: var(--wr-ink); background: color-mix(in srgb, var(--wr-surface) 85%, var(--wr-ok) 8%); }
.cd-label { margin: 0 0 4px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; font-size: .8rem; color: var(--wr-muted); }
.countdown[data-state=open] .cd-label { color: var(--wr-ok); }
.cd-digits { display: flex; gap: 8px; }
.cd-digits > div { display: grid; justify-items: center; min-width: 64px; padding: 4px 8px 2px; background: var(--wr-bg); border: 2px solid var(--wr-ink); border-radius: 4px; box-shadow: inset 0 -10px 0 rgb(255 255 255 / .03); }
.cd-digits span { font: 400 clamp(2.2rem, 6vw, 3.2rem)/1 var(--display); color: var(--wr-accent-2); font-variant-numeric: tabular-nums; letter-spacing: .04em; text-shadow: 2px 2px 0 var(--wr-ink); }
.cd-digits small { font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; color: var(--wr-muted); font-weight: 700; }
.cd-when { margin: 8px 0 0; font-size: .88rem; color: var(--wr-muted); }
.free-note { margin: 6px 0 0; font-weight: 800; color: var(--wr-ok); font-size: .9rem; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.art-caption { margin: 18px 0 0; font-size: .78rem; color: var(--wr-muted); text-shadow: 1px 1px 0 var(--wr-ink); }

/* ---------- sections ---------- */
.section { padding: clamp(48px, 9vw, 96px) 0; position: relative; }
.section-alt { background:
  radial-gradient(color-mix(in srgb, var(--wr-ink) 70%, transparent) 1px, transparent 1.6px) 0 0 / 7px 7px,   /* halftone */
  var(--wr-surface); border-top: var(--ink-w) solid var(--wr-ink); border-bottom: var(--ink-w) solid var(--wr-ink); }
.wrap { width: min(1200px, 100%); margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.narrow { width: min(820px, 100%); }
.section-title { margin: 0 0 12px; font: 400 clamp(2.2rem, 5.5vw, 3.6rem)/1 var(--display); letter-spacing: .03em; text-shadow: 3px 3px 0 var(--wr-ink); }
.section-title span { color: var(--wr-accent); }
.lede { font-size: 1.12rem; max-width: 60ch; margin: 0 0 28px; color: var(--wr-text); }
.h-small { margin: 22px 0 10px; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--wr-accent-2); font-weight: 800; }

.pillars { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.pillar { background: var(--wr-surface); border: var(--ink-w) solid var(--wr-ink); box-shadow: var(--hard); border-radius: var(--radius); padding: 20px; position: relative; }
.pillar:nth-child(even) { transform: rotate(.6deg); } .pillar:nth-child(odd) { transform: rotate(-.6deg); }
.pillar svg { width: 46px; height: 46px; margin-bottom: 10px; fill: var(--wr-surface-2); stroke: var(--wr-text); stroke-width: 3; stroke-linejoin: round; }
.pillar svg .fill { fill: var(--wr-accent); stroke: var(--wr-ink); } .pillar svg .stroke-accent { fill: none; stroke: var(--wr-accent); stroke-width: 4; }
.pillar h3 { font: 400 1.55rem/1.05 var(--display); letter-spacing: .03em; margin: 0 0 8px; }
.pillar p { margin: 0; color: var(--wr-muted); }
.pillar p strong { color: var(--wr-text); }

.boss-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(24px, 5vw, 64px); }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 0; }
.facts div { background: var(--wr-bg); border: 2px solid var(--wr-ink); border-radius: var(--radius); padding: 10px 12px; }
.facts dt { font-size: .74rem; text-transform: uppercase; letter-spacing: .1em; color: var(--wr-muted); font-weight: 700; }
.facts dd { margin: 2px 0 0; font: 400 1.6rem/1.05 var(--display); letter-spacing: .03em; }
.facts dd small { display: block; font: 600 .76rem/1.3 var(--body); color: var(--wr-muted); letter-spacing: 0; }
.threats, .loot { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.threats li { background: var(--wr-bg); border-left: 5px solid var(--wr-accent); border-radius: 0 var(--radius) var(--radius) 0; padding: 10px 14px; }
.threats strong { display: block; font: 400 1.25rem/1.1 var(--display); letter-spacing: .04em; }
.threats span { color: var(--wr-muted); }
.phases { margin: 0; padding: 0; list-style: none; counter-reset: ph; display: grid; gap: 8px; }
.phases li { counter-increment: ph; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; background: var(--wr-bg); border: 2px solid var(--wr-ink); border-radius: var(--radius); padding: 10px 12px; }
.phases li::before { content: counter(ph); font: 400 1.4rem/1 var(--display); color: var(--wr-on-accent); background: var(--wr-accent); border: 2px solid var(--wr-ink); width: 1.6em; height: 1.6em; display: grid; place-items: center; border-radius: 4px; }
.phases strong { font: 400 1.3rem/1 var(--display); letter-spacing: .04em; }
.loot li { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; padding: 8px 12px; background: var(--wr-bg); border: 2px solid var(--wr-ink); border-left: 5px solid var(--rc); border-radius: var(--radius); }
.rar { text-transform: uppercase; font-size: .7rem; font-weight: 800; letter-spacing: .1em; color: var(--rc); }

/* ---------- join flow ---------- */
.steps { list-style: none; display: flex; gap: 8px; padding: 0; margin: 8px 0 28px; flex-wrap: wrap; }
.steps li { display: flex; align-items: center; gap: 8px; padding: 6px 14px 6px 6px; border: 2px solid var(--wr-line); border-radius: 99px; color: var(--wr-muted); font-weight: 700; }
.steps .n { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--wr-surface-2); font-weight: 800; color: var(--wr-text); border: 2px solid var(--wr-ink); }
.steps li.done { color: var(--wr-text); } .steps li.done .n { background: var(--wr-ok); color: #06210f; }
.steps li.current { border-color: var(--wr-accent); color: var(--wr-text); box-shadow: 3px 3px 0 var(--wr-ink); } .steps li.current .n { background: var(--wr-accent); color: var(--wr-on-accent); }

.panel { animation: rise .35s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
.card, .auth-card, .create { background: var(--wr-surface); border: var(--ink-w) solid var(--wr-ink); box-shadow: var(--hard); border-radius: var(--radius); padding: clamp(18px, 3vw, 28px); }
.auth-wrap { display: grid; grid-template-columns: minmax(0, 480px) 1fr; gap: clamp(20px, 4vw, 48px); align-items: start; }
.auth-side { padding-top: 8px; }
.howto { margin: 12px 0 0; padding: 0; list-style: none; counter-reset: hw; display: grid; gap: 14px; }
.howto li { counter-increment: hw; position: relative; padding-left: 48px; color: var(--wr-muted); min-height: 34px; }
.howto li strong { color: var(--wr-text); }
.howto li::before { content: counter(hw); position: absolute; left: 0; top: -2px; width: 34px; height: 34px; display: grid; place-items: center; font: 400 1.3rem/1 var(--display);
  background: var(--wr-surface-2); border: 2px solid var(--wr-ink); border-radius: 4px; box-shadow: 2px 2px 0 var(--wr-ink); color: var(--wr-accent-2); }
.panel-title { margin: 0 0 6px; font: 400 2rem/1.05 var(--display); letter-spacing: .03em; }
.tabs { display: flex; gap: 0; margin: -6px 0 18px; border-bottom: 2px solid var(--wr-line); }
.tabs [role=tab] { flex: 1; background: none; border: 0; color: var(--wr-muted); font: 700 1rem var(--body); padding: 10px 8px; cursor: pointer; border-bottom: 4px solid transparent; margin-bottom: -2px; min-height: 44px; }
.tabs [aria-selected=true] { color: var(--wr-text); border-bottom-color: var(--wr-accent); }
.field { margin: 0 0 16px; border: 0; padding: 0; min-width: 0; }
.field > label, legend { display: block; font-weight: 700; margin-bottom: 6px; padding: 0; }
input[type=email], input[type=password], input[type=text], input:not([type]) { width: 100%; min-height: 48px; padding: 10px 12px; font: 1rem var(--body); color: var(--wr-text);
  background: var(--wr-bg); border: 2px solid var(--wr-line); border-radius: var(--radius); }
input:hover { border-color: var(--wr-muted); }
input:focus-visible { border-color: var(--wr-accent-2); outline-offset: 1px; }
input[aria-invalid=true] { border-color: var(--wr-danger); }
.hint { margin: 6px 0 0; font-size: .85rem; color: var(--wr-muted); }
.form-msg { min-height: 1.2em; margin: 10px 0 0; color: var(--wr-danger); font-weight: 600; }
.form-msg:empty { margin: 0; min-height: 0; }
.form-msg.ok { color: var(--wr-ok); } #playMsg.notice { padding: 0; border: 0; background: none; color: var(--wr-muted); } .form-msg.notice { color: var(--wr-text); background: var(--wr-bg); border: 2px solid var(--wr-accent-2); border-radius: var(--radius); padding: 10px 12px; font-weight: 400; }

.create { display: grid; grid-template-columns: 1.25fr 1fr; gap: clamp(20px, 4vw, 40px); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.kits { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kit { position: relative; display: block; cursor: pointer; }
.kit input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.kit-body { display: grid; gap: 4px; height: 100%; padding: 12px 14px; background: var(--wr-bg); border: 2px solid var(--wr-line); border-radius: var(--radius); transition: border-color .1s, transform .1s; }
.kit:hover .kit-body { border-color: var(--wr-muted); }
.kit input:checked + .kit-body { border-color: var(--wr-accent); box-shadow: 4px 4px 0 var(--wr-ink), inset 0 0 0 1px var(--wr-accent); transform: translate(-2px, -2px); }
.kit input:focus-visible + .kit-body { outline: 3px solid var(--wr-accent-2); outline-offset: 2px; }
.kit-off { cursor: not-allowed; } .kit-off .kit-body { opacity: .62; border-style: dashed; }
.kit-name { font: 400 1.45rem/1 var(--display); letter-spacing: .04em; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.role { font: 800 .66rem/1 var(--body); letter-spacing: .1em; text-transform: uppercase; padding: 4px 6px; border-radius: 4px; background: var(--wr-surface-2); border: 1px solid var(--wr-line); color: var(--wr-text); }
.kit-desc { color: var(--wr-muted); font-size: .92rem; }
.kit-items { font-size: .8rem; color: var(--wr-text); opacity: .9; }

.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.sw { position: relative; width: 40px; height: 40px; border-radius: 6px; background: var(--c); border: 3px solid var(--wr-ink); cursor: pointer; box-shadow: 2px 2px 0 var(--wr-ink); }
.sw input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.sw:has(input:checked) { outline: 3px solid var(--wr-text); outline-offset: 2px; }
.sw:has(input:focus-visible) { outline: 3px solid var(--wr-accent-2); outline-offset: 4px; }
.seg { display: inline-flex; flex-wrap: wrap; border: 2px solid var(--wr-ink); border-radius: var(--radius); overflow: hidden; background: var(--wr-bg); }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.seg span { display: block; padding: 10px 14px; min-height: 44px; font-weight: 700; color: var(--wr-muted); border-right: 2px solid var(--wr-line); }
.seg label:last-child span { border-right: 0; }
.seg input:checked + span { background: var(--wr-accent); color: var(--wr-on-accent); }
.seg input:focus-visible + span { outline: 3px solid var(--wr-accent-2); outline-offset: -3px; }
.seg-sm span { padding: 8px 12px; min-height: 40px; font-size: .92rem; }

.create-preview { background: radial-gradient(circle at 50% 30%, color-mix(in srgb, var(--wr-glow) 22%, transparent), transparent 60%), var(--wr-bg); border: 2px solid var(--wr-ink); border-radius: var(--radius); padding: 16px; align-self: start; }
.create-preview .h-small { margin-top: 0; }
.avatar { width: 190px; margin: 0 auto 8px; filter: drop-shadow(4px 4px 0 rgb(0 0 0 / .35)); }
.avatar-sm { width: 110px; margin: 0; flex: none; }
.hero-bob { animation: bob 2.8s ease-in-out infinite; transform-origin: 50% 100%; }
@keyframes bob { 50% { transform: translateY(-3px); } }
.glow { animation: glow 2s ease-in-out infinite; }
@keyframes glow { 50% { opacity: .5; } }
.world-toggle { margin: 6px 0 12px; text-align: center; }
.world-toggle legend { font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--wr-muted); margin: 0 auto 6px; }

.gear-list { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 8px; }
.gi { display: grid; grid-template-columns: 74px 1fr auto; column-gap: 10px; align-items: baseline; padding: 8px 10px; background: var(--wr-surface); border: 2px solid var(--wr-ink); border-left: 5px solid var(--rc, var(--wr-line)); border-radius: var(--radius); }
.card .gi { background: var(--wr-bg); }
.gi .slot { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--wr-muted); font-weight: 800; grid-row: span 2; }
.gi-name { font-weight: 700; display: flex; align-items: center; gap: 6px; }
.chip { width: 12px; height: 12px; border-radius: 2px; background: var(--ac); border: 2px solid var(--wr-ink); flex: none; }
.gi-sub { grid-column: 2; font-size: .8rem; color: var(--wr-muted); font-style: italic; }
.gi-meta { grid-column: 3; grid-row: 1; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--rc); font-weight: 800; }
.gi .btn { grid-column: 3; grid-row: 2; }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; margin: 0; }
.stats div { display: flex; justify-content: space-between; gap: 8px; border-bottom: 1px dashed var(--wr-line); padding: 4px 0; }
.stats dt { color: var(--wr-muted); font-size: .9rem; } .stats dd { margin: 0; font-weight: 800; font-variant-numeric: tabular-nums; }
.stats .full { grid-column: 1 / -1; display: block; border: 0; }
.stats .full dd { font-weight: 400; margin-top: 2px; }

.dash { display: grid; grid-template-columns: 1.3fr 1fr; gap: 20px; align-items: start; }
.hero-card-top { display: flex; gap: 16px; align-items: center; }
.lvl { margin: 6px 0 4px; font-weight: 700; } .lvl strong { font: 400 1.6rem var(--display); color: var(--wr-accent-2); }
.xpbar { width: min(260px, 100%); height: 12px; background: var(--wr-bg); border: 2px solid var(--wr-ink); border-radius: 99px; overflow: hidden; }
.xpbar div { height: 100%; width: 0; background: linear-gradient(90deg, var(--wr-accent), var(--wr-accent-2)); }
.history { padding-left: 18px; margin: 0; }

/* ---------- pass ---------- */
.pass-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.ticks li { padding-left: 32px; position: relative; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .2em; width: 20px; height: 20px; background: var(--wr-accent); border: 2px solid var(--wr-ink); border-radius: 4px;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); box-shadow: inset -5px -5px 0 rgb(0 0 0 / .25); }
.pass-card { text-align: center; transform: rotate(1deg); }
.pass-kicker { margin: 0; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; font-size: .8rem; color: var(--wr-accent-2); }
.price { margin: 4px 0 6px; } .price .amt { font: 400 4.6rem/1 var(--display); text-shadow: 4px 4px 0 var(--wr-ink); } .price .per { color: var(--wr-muted); font-weight: 700; }
.pass-status { min-height: 1.4em; margin: 0 0 14px; } .pass-status.ok { color: var(--wr-ok); }
.fine { margin: 12px 0 0; }

/* ---------- faq / footer ---------- */
details { background: var(--wr-surface); border: 2px solid var(--wr-ink); border-radius: var(--radius); margin-bottom: 10px; box-shadow: 3px 3px 0 var(--wr-ink); }
summary { cursor: pointer; padding: 14px 16px; font-weight: 800; min-height: 44px; }
details p { margin: 0; padding: 0 16px 16px; color: var(--wr-muted); }
.demo-bar details { background: none; border: 0; box-shadow: none; margin: 0; }
.demo-bar summary { padding: 0; min-height: 0; display: inline; }
body:has(.demo-bar:not([hidden])) .site-footer { padding-bottom: 96px; }
.site-footer { text-align: center; padding: 32px 16px 40px; border-top: var(--ink-w) solid var(--wr-ink); background: var(--wr-surface); }
.site-footer p { margin: 4px 0; }
.fatal, .noscript { margin: 0; padding: 12px 16px; background: #5a0d0d; color: #fff; font-weight: 700; }

/* ---------- device notice ---------- */
.device-notice { display: flex; gap: 10px; align-items: flex-start; margin: 16px 0 0; max-width: 46ch; padding: 12px 14px; background: var(--wr-surface);
  border: 2px solid var(--wr-accent-2); border-radius: var(--radius); box-shadow: 3px 3px 0 var(--wr-ink); font-weight: 700; }
.device-notice::before { content: ""; flex: none; width: 22px; height: 16px; margin-top: 3px; border: 2px solid var(--wr-accent-2); border-radius: 2px; box-shadow: 0 5px 0 -2px var(--wr-accent-2); }
#raidCard .device-notice { max-width: none; }

/* ---------- how to play ---------- */
.controls { margin-top: clamp(36px, 5vw, 56px); }
.sub-title { margin: 0 0 6px; font: 400 2rem/1 var(--display); letter-spacing: .03em; text-shadow: 2px 2px 0 var(--wr-ink); }
.controls-grid { display: grid; grid-template-columns: 1fr; gap: 18px; margin-top: 14px; }
.ctl-card { background: var(--wr-surface); border: var(--ink-w) solid var(--wr-ink); box-shadow: var(--hard); border-radius: var(--radius); padding: 18px 20px; }
.ctl-card h4 { margin: 0 0 10px; font: 400 1.5rem/1 var(--display); letter-spacing: .04em; color: var(--wr-accent-2); }
.ctl-card p { margin: 0 0 8px; }
.controls-grid:has(> :nth-child(2)) { grid-template-columns: 1.4fr 1fr; }
.keys { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 8px 20px; margin: 0; }
.keys div { display: flex; justify-content: space-between; align-items: center; gap: 10px; border-bottom: 1px dashed var(--wr-line); padding: 4px 0; }
.keys dt { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; color: var(--wr-muted); font-size: .85rem; }
.keys dd { margin: 0; font-weight: 700; text-align: right; }
kbd { display: inline-block; min-width: 1.9em; padding: 2px 6px; font: 700 .82rem/1.3 var(--body); text-align: center; color: var(--wr-text);
  background: var(--wr-bg); border: 2px solid var(--wr-ink); border-bottom-width: 4px; border-radius: 4px; }

/* ---------- desktop range: 1280x720 laptops up to 2560x1440 ---------- */
@media (max-width: 1180px) { .site-header nav { display: none; } .pillars { grid-template-columns: 1fr 1fr; } }
@media (max-height: 820px) and (min-width: 1024px) {          /* 1280x720, 1366x768: keep the countdown + CTA above the fold */
  .hero { min-height: calc(100vh - 64px); }
  .hero-inner { padding-top: clamp(56px, 9vh, 96px); padding-bottom: 32px; }
  .boss-name { font-size: clamp(3.2rem, 13.5vh, 6.4rem); }
  .tagline { margin: 12px 0 14px; }
  .cd-digits span { font-size: 2.4rem; }
  .hero-ctas { margin-top: 16px; }
}
@media (min-width: 1680px) {
  html { font-size: 17px; }
  .wrap, .hero-inner { width: min(1400px, 100%); }
  .hero { min-height: min(88vh, 1040px); }
}
@media (min-width: 2200px) {
  html { font-size: 19px; }
  .wrap, .hero-inner { width: min(1560px, 100%); }
}

/* ---------- small screens: not a designed experience, just readable (play is blocked there) ---------- */
@media (max-width: 1023px) {
  .boss-grid, .pass-grid, .create, .dash, .auth-wrap, .controls-grid, .keys, .pillars, .kits, .two { grid-template-columns: 1fr; }
  .site-header { flex-wrap: wrap; }
  .whoami { display: none; }
  .cd-digits { flex-wrap: wrap; }
  .pillar:nth-child(n), .pass-card { transform: none; }
}

/* ---------- motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .btn:hover, .btn:active { transform: none; }
}
@media (forced-colors: active) { .btn, .card, .countdown, .pillar { border: 2px solid CanvasText; } }

/* ---------- QoL pass: feedback, dialogs, loading, legal ---------- */
button.link { background: none; border: 0; padding: 0; color: var(--wr-accent-2); font: inherit; text-decoration: underline; cursor: pointer; }
.field-err { margin: 6px 0 0; color: var(--wr-danger); font-weight: 700; font-size: .9rem; }
.field-err::before { content: "⚠ "; }
.label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.label-row .link { font-size: .85rem; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 76px; }
.pw-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); min-height: 32px; padding: 0 10px; background: var(--wr-surface-2);
  color: var(--wr-text); border: 2px solid var(--wr-line); border-radius: var(--radius); font-weight: 700; cursor: pointer; }
.fine a { color: inherit; }
.toast { pointer-events: none; position: fixed; z-index: 90; left: 50%; bottom: 72px; transform: translateX(-50%); max-width: min(560px, 92vw); padding: 12px 18px;
  background: var(--wr-surface); color: var(--wr-text); border: var(--ink-w) solid var(--wr-ink); outline: 2px solid var(--wr-accent-2);
  border-radius: var(--radius); box-shadow: var(--hard); font-weight: 700; }
.net-banner { position: sticky; top: 0; z-index: 60; margin: 0; padding: 10px 16px; background: #3a2a05; color: #fff3c4; border-bottom: 2px solid var(--wr-accent-2); font-weight: 700; text-align: center; }
.spinner { display: inline-block; width: 1em; height: 1em; vertical-align: -0.15em; border: 3px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn[aria-busy=true]::before { content: ""; width: 1em; height: 1em; border: 3px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
.skel-wrap { display: grid; gap: 14px; padding: 20px; font-weight: 700; color: var(--wr-muted); }
.skel { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; }
.skel i { display: block; height: 120px; border-radius: var(--radius); background: linear-gradient(90deg, var(--wr-surface) 0%, var(--wr-surface-2) 50%, var(--wr-surface) 100%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
.skel i:first-child { grid-row: span 2; height: 256px; }
@keyframes shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .spinner, .btn[aria-busy=true]::before, .skel i { animation: none; } }
.next-teaser { margin: 12px 0 0; max-width: 56ch; padding: 10px 14px; background: color-mix(in srgb, var(--wr-surface) 88%, transparent); border-left: 4px solid var(--wr-accent-2); }
.meanwhile { margin-top: 14px; }
.name-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.name-row .btn { min-height: 32px; padding: 2px 10px; }
.placeholder { font-family: ui-monospace, monospace; background: #fff3c4; color: #2a1d00; padding: 0 4px; border-radius: 3px; }
.foot-links { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; padding: 0; margin: 8px 0; }
.foot-links a { color: var(--wr-text); }
.dlg { width: min(460px, 94vw); padding: 22px; background: var(--wr-surface); color: var(--wr-text); border: var(--ink-w) solid var(--wr-ink);
  outline: 2px solid var(--wr-line); border-radius: var(--radius); box-shadow: var(--hard); }
.dlg-wide { width: min(620px, 94vw); }
.dlg::backdrop { background: rgb(0 0 0 / .7); }
.dlg-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.dlg-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }
.dlg-sec { border-top: 2px solid var(--wr-line); padding-top: 12px; margin-top: 14px; }
.dlg-sec.danger h3 { color: var(--wr-danger); }
.inline-form { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.inline-form input { flex: 1; min-width: 0; }
.btn-danger { --bg: #8d1b12; --fg: #fff; }
.demo-only { display: block; margin-top: 6px; color: var(--wr-text); }
/* Legal / error pages */
.doc { max-width: 760px; margin: 0 auto; padding: 32px 20px 64px; line-height: 1.6; }
.doc h1 { font-family: var(--display); letter-spacing: .02em; font-size: clamp(2rem, 4vw, 2.8rem); margin: 0 0 8px; }
.doc h2 { margin-top: 28px; }
.doc a { color: var(--wr-accent-2); }
.draft-banner { margin: 0 0 20px; padding: 12px 16px; background: #fff3c4; color: #2a1d00; border: 3px solid var(--wr-ink); border-radius: var(--radius); font-weight: 800; }
.doc-nav { display: flex; gap: 16px; flex-wrap: wrap; padding: 14px 20px; border-bottom: 2px solid var(--wr-line); }
.doc-nav a { color: var(--wr-text); font-weight: 700; }
.dlg .btn:hover, .dlg .btn:active { transform: none; }
.doc a.btn { color: var(--fg); }
.tbc { color: var(--wr-muted); font-style: italic; }
.draft-banner { font-size: 1.05rem; }
/* Countdown before the gate state is known: same box size, no "0 days"/"open in" guess, digits muted placeholders. */
.countdown[data-state=pending] .cd-digits span { color: var(--wr-muted); opacity: .5; }
.countdown[data-state=pending] .cd-label { color: var(--wr-muted); }
.gate-pill[data-state=pending] .dot { background: var(--wr-muted); }
