/* Galaxy War - all UI styles. Everything scales with rem / em; safe-area insets and 100dvh keep phones tidy.
   Sections: base, top bar, HUD, bomb button, banner, overlays (menu, sector map, briefing, hangar, settings, how-to, cards), responsive */
:root { --acc: #9B7BFF; --sat: env(safe-area-inset-top, 0px); --sar: env(safe-area-inset-right, 0px); --sab: env(safe-area-inset-bottom, 0px); --sal: env(safe-area-inset-left, 0px); }
html { font-size: clamp(15px, calc(11px + .38vw), 27px); height: 100%; }
html, body { margin: 0; height: 100%; height: 100dvh; overflow: hidden; background: #070520; overscroll-behavior: none; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; }
body { font-family: var(--font-b); color: var(--paper); }
button { font-family: inherit; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
svg { fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
svg.fill, .fill svg { fill: currentColor; stroke: none; }
#app, .gw { position: fixed; inset: 0; width: 100%; height: 100dvh; overflow: hidden; background: #070520; }
.gw-cv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; image-rendering: auto; }
body.playing .gw-cv { cursor: none; }

/* ---------- buttons (extends brand .btn) ---------- */
.btn { gap: .5em; white-space: nowrap; touch-action: manipulation; min-height: 2.9em; }
.btn svg { width: 1.2em; height: 1.2em; flex: none; }
.btn svg.fill { fill: currentColor; stroke: none; }
.btn em { font-style: normal; opacity: .75; font-size: .8em; }
.btn--violet { --bg: var(--violet); --fg: #120a33; --sh: #5a3fc4; }
.btn--ghost { --bg: rgba(255, 255, 255, .08); --sh: rgba(0, 0, 0, .35); font-size: .9rem; }
.btn--ico { padding: .85em 1em; }
.btn--off { filter: grayscale(.75) brightness(.7); }
.btn--sm { min-height: 0; }
.shake { animation: gwshake .35s; }
@keyframes gwshake { 20% { transform: translateX(-6px); } 40% { transform: translateX(6px); } 60% { transform: translateX(-4px); } 80% { transform: translateX(3px); } }

/* ---------- top bar ---------- */
.gw-top { position: absolute; z-index: 45; top: 0; left: 0; right: 0; display: flex; justify-content: space-between; align-items: flex-start; padding: calc(var(--sat) + 10px) calc(var(--sar) + 12px) 0 calc(var(--sal) + 12px); pointer-events: none; }
.gw-top > * { pointer-events: auto; }
.gw-home { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; padding: 6px 14px 6px 6px; border-radius: 14px; background: rgba(15, 12, 34, .55); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .12) inset; }
.gw-home img { width: 34px; height: 34px; }
.gw-home b { font-family: var(--font-d); font-size: .95rem; font-weight: 400; line-height: 1; }
.gw-home b i { font-style: normal; color: var(--lime); }
.gw-tools { display: flex; gap: 8px; margin-left: auto; }
.gw-tool { width: 46px; height: 46px; border: 0; padding: 0; display: grid; place-items: center; border-radius: 13px; background: rgba(15, 12, 34, .55); color: #fff; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .12) inset; }
.gw-tool svg { width: 21px; height: 21px; }
.gw-top.tb-menu .tool-pause { display: none; }
.gw-top.tb-play .gw-home { display: none; }

/* ---------- HUD ---------- */
.gw-hud { position: absolute; inset: 0; z-index: 10; pointer-events: none; font-size: 1rem; }
.gw-hud[hidden], .hud-boss[hidden] { display: none; }
.hud-l { position: absolute; left: calc(var(--sal) + 14px); top: calc(var(--sat) + 12px); display: grid; gap: .45em; justify-items: start; }
.hud-hp { display: flex; gap: .2em; filter: drop-shadow(0 .12em 0 rgba(0, 0, 0, .4)); }
.hp svg { width: 1.55em; height: 1.55em; color: rgba(255, 255, 255, .18); }
.hp.on svg { color: var(--lime); filter: drop-shadow(0 0 .35em rgba(198, 255, 61, .6)); }
.hp.on.low svg { color: #FF3D5A; animation: gwlow .6s infinite; }
@keyframes gwlow { 50% { opacity: .35; } }
.hud-score { line-height: 1; text-shadow: 0 .1em 0 rgba(0, 0, 0, .5); }
.hud-score small, .hud-chain small, .pw small { font-size: max(12px, .6em); font-weight: 800; letter-spacing: .14em; color: var(--mute); }
.hud-score b { display: block; font-family: var(--font-d); font-weight: 400; font-size: 1.75em; letter-spacing: .02em; font-variant-numeric: tabular-nums; margin-top: .1em; }
.hud-chain { display: grid; grid-template-columns: auto 5.5em; align-items: center; gap: .2em .5em; opacity: .55; transition: opacity .2s; }
.hud-chain.hot { opacity: 1; }
.hud-chain b { font-family: var(--font-d); font-weight: 400; font-size: 1.3em; color: var(--sun); text-shadow: 0 .08em 0 rgba(0, 0, 0, .5); }
.hud-chain.pop b { animation: gwpop .35s var(--ease); }
@keyframes gwpop { 0% { transform: scale(1.7); } 100% { transform: none; } }
.hud-chain i { display: block; height: .5em; border-radius: 9px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.hud-chain u { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #FFD23F, #FF5B2E); border-radius: inherit; box-shadow: 0 0 .8em rgba(255, 210, 63, .7); transition: width .15s; }
.hud-chain small { grid-column: 1 / -1; display: none; }
.hud-c { position: absolute; left: 50%; top: calc(var(--sat) + 16px); transform: translateX(-50%); width: clamp(140px, 30vw, 520px); text-align: center; }
.hud-sec { font-size: max(12px, .72em); font-weight: 800; letter-spacing: .15em; color: #DCD7FF; text-shadow: 0 2px 4px rgba(0, 0, 0, .7); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: .35em; }
.hud-prog { position: relative; height: .55em; border-radius: 99px; background: rgba(15, 12, 34, .6); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .14) inset; overflow: hidden; }
.hud-prog i { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--acc, #9B7BFF), #fff); box-shadow: 0 0 .9em var(--acc, #9B7BFF); transition: width .25s linear; }
.hud-prog em { position: absolute; right: -1px; top: -1px; bottom: -1px; width: .9em; background: repeating-linear-gradient(45deg, #FF3D8B 0 4px, #0F0C22 4px 8px); border-radius: 0 99px 99px 0; opacity: .9; }
.hud-r { position: absolute; right: calc(var(--sar) + 12px); top: calc(var(--sat) + 62px); }
.hud-cred { display: inline-flex; align-items: center; gap: .4em; padding: .25em .8em .25em .45em; border-radius: 99px; background: rgba(15, 12, 34, .6); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .1) inset; font-family: var(--font-d); font-size: .95em; }
.hud-cred svg { width: 1.4em; height: 1.4em; }
.hud-boss { position: absolute; left: 50%; top: calc(var(--sat) + 3.6em); transform: translateX(-50%); width: min(52vw, 760px); animation: gwpopin .5s var(--ease); }
@keyframes gwpopin { from { opacity: 0; transform: translate(-50%, -14px); } }
.hb-name { display: flex; align-items: baseline; justify-content: center; gap: .8em; text-shadow: 0 2px 6px rgba(0, 0, 0, .8); margin-bottom: .3em; }
.hb-name b { font-family: var(--font-d); font-weight: 400; font-size: 1.15em; letter-spacing: .06em; color: #FF6B8E; }
.hb-name span { font-size: max(12px, .72em); font-weight: 700; color: #DCD7FF; letter-spacing: .1em; text-transform: uppercase; }
.hb-bar { position: relative; height: .95em; border-radius: 99px; background: rgba(15, 12, 34, .7); box-shadow: 0 0 0 2px rgba(255, 255, 255, .16) inset, 0 .3em 1em rgba(0, 0, 0, .4); overflow: hidden; }
.hb-bar i { position: absolute; inset: 0 auto 0 0; width: 100%; border-radius: inherit; background: linear-gradient(90deg, #FF3D8B, #FF5B2E 55%, #FFD23F); box-shadow: 0 0 1em rgba(255, 61, 139, .6); transition: width .12s linear; }
.hb-bar u { position: absolute; top: 0; bottom: 0; width: 3px; margin-left: -1px; background: rgba(15, 12, 34, .9); }
.hud-boss.inv .hb-bar i { filter: grayscale(.8) brightness(1.3); }
.hud-pow { position: absolute; left: calc(var(--sal) + 12px); bottom: calc(var(--sab) + 12px); display: flex; flex-wrap: wrap; gap: .4em; max-width: 60vw; }
.pw { display: inline-flex; align-items: center; gap: .4em; padding: .2em .7em .2em .25em; border-radius: 99px; background: rgba(15, 12, 34, .62); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .1) inset; font-family: var(--font-d); font-size: .85em; line-height: 1; }
.pw img { width: 2em; height: 2em; display: block; }
.pw b { font-weight: 400; }
.pw-w b { display: block; font-size: .8em; letter-spacing: .06em; }
.pips { display: inline-flex; gap: 3px; margin-top: .25em; }
.pips u { display: block; width: .75em; height: .4em; border-radius: 3px; background: rgba(255, 255, 255, .16); }
.pips u.on { background: linear-gradient(90deg, #2FD6FF, #C6FF3D); box-shadow: 0 0 .5em rgba(47, 214, 255, .6); }
.pw i { display: block; width: 3.2em; height: .4em; border-radius: 3px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.pw i u { display: block; height: 100%; background: var(--cyan); width: 100%; }
.pw-g i u { background: #B58CFF; }

/* ---------- bomb button ---------- */
.gw-bomb { display: none; position: absolute; z-index: 30; right: calc(var(--sar) + 16px); bottom: calc(var(--sab) + 18px); width: 4.3em; height: 4.3em; border-radius: 50%; border: 0; padding: 0; color: #fff; touch-action: none; user-select: none;
  background: radial-gradient(circle at 35% 28%, #FFB07A, #FF5B2E 55%, #A02A08); box-shadow: 0 .3em 0 #6a1a04, 0 0 0 .18em rgba(255, 255, 255, .28) inset, 0 0 1.4em rgba(255, 91, 46, .5); }
.gw-bomb.show { display: grid; place-items: center; }
.gw-bomb img { width: 54%; height: 54%; margin-top: -.2em; pointer-events: none; }
.gw-bomb b { position: absolute; right: -.15em; top: -.15em; min-width: 1.5em; height: 1.5em; line-height: 1.5em; border-radius: 99px; background: #0F0C22; font-family: var(--font-d); font-weight: 400; font-size: .85em; box-shadow: 0 0 0 .14em #FF5B2E; text-align: center; padding: 0 .3em; }
.gw-bomb span { position: absolute; bottom: .25em; font-family: var(--font-d); font-size: .5em; letter-spacing: .06em; text-shadow: 0 1px 2px rgba(0, 0, 0, .7); }
.gw-bomb:active { transform: translateY(.18em); }
.gw-bomb.cd { filter: brightness(.65); }
.gw-bomb.empty { filter: grayscale(1) brightness(.5); }
@media (pointer: coarse) { .gw-bomb { width: 5.4em; height: 5.4em; font-size: 1rem; } }

/* ---------- banner ---------- */
.gw-banner { position: absolute; z-index: 25; left: 0; right: 0; top: 24%; text-align: center; pointer-events: none; opacity: 0; padding: 0 1em; }
.gw-banner h2 { margin: 0; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: clamp(1.8rem, 1rem + 3.4vw, 4.4rem); line-height: 1; color: #fff; text-shadow: 0 .06em 0 rgba(0, 0, 0, .5), 0 0 .5em var(--acc); }
.gw-banner p { margin: .35em 0 0; font-weight: 800; font-size: clamp(.9rem, .6rem + .6vw, 1.5rem); letter-spacing: .16em; text-transform: uppercase; color: #DCD7FF; text-shadow: 0 2px 6px rgba(0, 0, 0, .8); }
.gw-banner.sector h2 { font-size: clamp(2rem, 1rem + 4vw, 5rem); }
.gw-banner.sector p { color: var(--sun); }
.gw-banner.warn h2 { color: #FF3D5A; text-shadow: 0 .06em 0 rgba(0, 0, 0, .5), 0 0 .6em #FF3D5A; animation: gwblink .45s steps(2) infinite; }
.gw-banner.clear h2 { color: var(--lime); }
.gw-banner.toast { top: 12%; } .gw-banner.toast h2 { font-size: clamp(1.1rem, .8rem + 1vw, 2rem); color: var(--sun); }
.gw-banner.show { animation: gwbanner 2.6s var(--ease) forwards; }
.gw-banner.warn.show { animation: gwbannerw 3.3s var(--ease) forwards; }
.gw-banner.toast.show { animation: gwbanner 1.1s var(--ease) forwards; }
@keyframes gwbanner { 0% { opacity: 0; transform: translateY(24px) scale(.85); } 14% { opacity: 1; transform: none; } 75% { opacity: 1; } 100% { opacity: 0; transform: translateY(-20px); } }
@keyframes gwbannerw { 0% { opacity: 0; transform: scale(1.4); } 8% { opacity: 1; transform: none; } 88% { opacity: 1; } 100% { opacity: 0; } }
@keyframes gwblink { 50% { opacity: .35; } }

.gw-hint { position: absolute; z-index: 24; left: 50%; bottom: calc(var(--sab) + 22%); transform: translateX(-50%); max-width: 90vw; padding: .6em 1.2em; border-radius: 99px; background: rgba(15, 12, 34, .78); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .16) inset; font-weight: 700; font-size: max(13px, .95rem); text-align: center; color: #E2DEFF; opacity: 0; pointer-events: none; transition: opacity .5s; }
.gw-hint.show { opacity: 1; } .gw-hint b { color: var(--lime); }
@media (max-width: 760px) { .gw-hint { border-radius: 18px; bottom: calc(var(--sab) + 17%); } }

/* ---------- overlays ---------- */
.gw-ov { position: absolute; inset: 0; z-index: 40; display: none; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; touch-action: pan-y; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.gw-ov::-webkit-scrollbar { display: none; }
.gw-ov.show { display: block; animation: gwfade .25s ease; }
@keyframes gwfade { from { opacity: 0; } }
@keyframes gwrise { from { opacity: 0; transform: translateY(14px) scale(.97); } }
.ov--menu.show { background: linear-gradient(90deg, rgba(10, 6, 34, .9) 0%, rgba(10, 6, 34, .62) 34%, rgba(10, 6, 34, 0) 62%), linear-gradient(0deg, rgba(10, 6, 34, .5), rgba(10, 6, 34, 0) 28%); }
.ov--screen.show { background: rgba(9, 6, 30, .8); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.ov--center.show { background: rgba(9, 6, 30, .62); backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); }
.ov--final.show { background: rgba(20, 6, 50, .3); backdrop-filter: none; -webkit-backdrop-filter: none; }
.screen { min-height: 100%; padding: calc(var(--sat) + 4.3rem) calc(var(--sar) + 1.2rem) calc(var(--sab) + 1.4rem) calc(var(--sal) + 1.2rem); }
.screen--c { display: grid; place-items: center; }
.head { display: flex; align-items: center; gap: 1rem; width: min(110rem, 100%); margin: 0 auto 1.2rem; }
.head h2 { margin: 0; flex: 1; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: clamp(1.5rem, 1rem + 1.6vw, 3rem); text-shadow: 0 4px 0 rgba(0, 0, 0, .4); }
.head-r { display: flex; gap: .6rem; }

/* main menu */
.menu { min-height: 100%; display: grid; align-items: center; padding: calc(var(--sat) + 4.5rem) calc(var(--sar) + clamp(1.2rem, 5vw, 6rem)) calc(var(--sab) + 1.4rem) calc(var(--sal) + clamp(1.2rem, 5vw, 6rem)); }
.menu-l { width: min(40rem, 100%); animation: gwrise .55s var(--ease); }
.kick { display: flex; flex-wrap: wrap; align-items: center; gap: .5em; font-weight: 800; font-size: max(12px, .78rem); letter-spacing: .16em; text-transform: uppercase; color: var(--violet); }
.kick::before { content: ""; width: 1.8em; height: 3px; border-radius: 3px; background: currentColor; }
.kick i { font-style: normal; color: #CFC9F5; letter-spacing: .1em; padding: .15em .7em; border-radius: 99px; background: rgba(255, 255, 255, .09); }
.gtitle { margin: .12em 0 .16em; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; line-height: .84; font-size: clamp(3.2rem, min(10vw, 19vh), 10rem); display: grid; justify-items: start; }
.gtitle b { font-weight: 400; display: block; background: linear-gradient(100deg, #9B7BFF 0%, #2FD6FF 34%, #FF3D8B 66%, #9B7BFF 100%); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; animation: gwslide 7s linear infinite; filter: drop-shadow(0 .05em 0 rgba(0, 0, 0, .5)) drop-shadow(0 0 .45em rgba(155, 123, 255, .35)); }
.gtitle b.b2 { margin-left: 1.05em; animation-delay: -1.5s; }
.gtitle.sm { font-size: clamp(2.2rem, 1rem + 5vw, 5.2rem); justify-items: center; }
.gtitle.sm b { margin: 0; }
@keyframes gwslide { to { background-position: -220% 0; } }
.tag { margin: 0 0 1.5rem; font-size: clamp(.95rem, .5vw + .75rem, 1.35rem); font-weight: 600; color: #DCD7FF; max-width: 30em; line-height: 1.45; }
.cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .6rem; }
.cta .btn--big { font-size: clamp(1.1rem, .5vw + .9rem, 1.6rem); }
.cta2 { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1rem; }
.chips { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.4rem; }
.chip { display: inline-flex; align-items: center; gap: .5em; padding: .5em 1em; border-radius: 14px; background: rgba(255, 255, 255, .07); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .1) inset; line-height: 1.05; }
.chip svg { width: 1.7em; height: 1.7em; flex: none; }
.chip small { display: block; font-size: max(12px, .62rem); font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.chip b { font-family: var(--font-d); font-weight: 400; font-size: 1.2rem; } .chip b i { font-style: normal; font-size: .65em; color: var(--mute); }
.chip-s b { color: var(--sun); } .chip-s svg { color: var(--sun); } .chip-e b { color: var(--violet); } .chip-w b { color: var(--lime); } .chip-b b { color: #FF6B8E; }

/* sector map */
.secgrid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(.7rem, 1.2vw, 1.5rem); width: min(110rem, 100%); margin: 0 auto; }
.sec { --acc: #9B7BFF; position: relative; min-height: clamp(15rem, 34vh, 24rem); border: 0; padding: 1em; border-radius: 22px; overflow: hidden; display: grid; align-content: end; justify-items: start; gap: .15em; text-align: left; color: #fff; isolation: isolate; box-shadow: 0 0 0 2px rgba(255, 255, 255, .12) inset, 0 16px 40px rgba(0, 0, 0, .4); transition: transform .2s var(--ease), box-shadow .2s; animation: gwrise .5s calc(var(--i) * .04s) both var(--ease); }
.sec:nth-child(5n+2), .sec:nth-child(5n+4) { transform: translateY(1.2rem); }
.sec:hover { transform: translateY(-5px) scale(1.02); box-shadow: 0 0 0 2.5px var(--acc) inset, 0 22px 50px rgba(0, 0, 0, .5), 0 0 50px color-mix(in srgb, var(--acc) 35%, transparent); }
.sec-bg { position: absolute; inset: 0; z-index: -2; }
.sec::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(10, 6, 30, .1) 30%, rgba(10, 6, 30, .88)); }
.sec-pl { position: absolute; z-index: -1; right: -14%; top: -6%; width: 78%; max-width: 15rem; height: auto; aspect-ratio: 1; object-fit: contain; filter: drop-shadow(0 .6rem 1rem rgba(0, 0, 0, .45)); transition: transform .4s var(--ease); }
.sec:hover .sec-pl { transform: scale(1.1) rotate(6deg); }
.sec-n { position: absolute; left: .8em; top: .6em; font-family: var(--font-d); font-size: 1.7rem; color: var(--acc); text-shadow: 0 3px 0 rgba(0, 0, 0, .45); }
.sec-nm { font-family: var(--font-d); text-transform: uppercase; font-size: clamp(1.05rem, .6rem + .7vw, 1.7rem); line-height: 1; text-shadow: 0 3px 0 rgba(0, 0, 0, .5); }
.sec-tag { font-size: max(12px, .78rem); font-weight: 600; color: #DCD7FF; line-height: 1.3; text-shadow: 0 2px 4px rgba(0, 0, 0, .7); }
.sec-st { display: flex; gap: 2px; margin-top: .4em; min-height: 1.5em; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .6)); }
.sec-st svg { width: 1.5em; height: 1.5em; }
.st svg { width: 1.5em; height: 1.5em; color: rgba(255, 255, 255, .2); fill: currentColor; stroke: none; } .st.on svg { color: var(--sun); filter: drop-shadow(0 0 .3em rgba(255, 210, 63, .7)); }
.sec-boss { position: absolute; right: .8em; bottom: 1em; padding: .15em .7em; border-radius: 99px; background: #FF3D8B; color: #fff; font-family: var(--font-d); font-size: max(12px, .72rem); letter-spacing: .06em; box-shadow: 0 3px 0 #8f1c4d; transform: rotate(-4deg); }
.sec.lock { filter: grayscale(.85) brightness(.7); cursor: not-allowed; }
.sec.lock .sec-st svg { width: 1.6em; height: 1.6em; color: #fff; }
.sec.cur { box-shadow: 0 0 0 3px var(--acc) inset, 0 0 40px color-mix(in srgb, var(--acc) 50%, transparent); animation: gwrise .5s calc(var(--i) * .04s) both var(--ease), gwcur 1.8s 1s ease-in-out infinite; }
@keyframes gwcur { 50% { box-shadow: 0 0 0 3px var(--acc) inset, 0 0 70px color-mix(in srgb, var(--acc) 80%, transparent); } }

/* briefing */
.brief { --acc: #9B7BFF; width: min(60rem, 100%); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 1.6rem; align-items: center; padding: 1.6rem; border-radius: 28px; background: linear-gradient(180deg, #2A2260, #1B1540); box-shadow: 0 0 0 2px color-mix(in srgb, var(--acc) 50%, transparent) inset, 0 30px 80px rgba(0, 0, 0, .55); animation: gwrise .35s var(--ease); }
.brief-pl { position: relative; aspect-ratio: 1; border-radius: 22px; overflow: hidden; display: grid; place-items: center; }
.brief-pl span { position: absolute; inset: 0; } .brief-pl img { position: relative; width: 92%; filter: drop-shadow(0 1rem 1.4rem rgba(0, 0, 0, .5)); }
.brief-b small { font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--acc); font-size: max(12px, .75rem); }
.brief-b h2 { margin: .1em 0 .2em; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: clamp(1.6rem, 1rem + 1.8vw, 3rem); line-height: 1; }
.brief-b p { margin: 0 0 .8rem; color: #CFC9F5; font-weight: 600; }
.objs { list-style: none; padding: 0; margin: 0 0 .9rem; display: grid; gap: .4rem; }
.objs li { display: flex; align-items: center; gap: .6em; padding: .45em .8em; border-radius: 12px; background: rgba(255, 255, 255, .06); font-weight: 700; font-size: .95rem; color: #CFC9F5; }
.objs li i { display: block; } .objs li .st svg { width: 1.3em; height: 1.3em; }
.objs li.ok { background: rgba(198, 255, 61, .13); color: #fff; } .objs li.ok .st svg { color: var(--sun); }
.objs em { font-style: normal; color: var(--mute); font-size: .85em; }

/* hangar */
.hangar { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 1.6rem; width: min(100rem, 100%); margin: 0 auto; align-items: start; }
.hg-l { --acc: #2FD6FF; }
.hg-stage { position: relative; height: clamp(15rem, 44vh, 32rem); border-radius: 28px; overflow: hidden; background: radial-gradient(ellipse at 50% 55%, color-mix(in srgb, var(--acc) 30%, transparent), rgba(15, 12, 34, .55) 70%), rgba(15, 12, 34, .5); box-shadow: 0 0 0 2px rgba(255, 255, 255, .13) inset, 0 30px 80px rgba(0, 0, 0, .5), 0 0 80px color-mix(in srgb, var(--acc) 25%, transparent); }
.hg-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.arrow { position: absolute; top: 50%; width: 3em; height: 3em; margin-top: -1.5em; border: 0; padding: 0; border-radius: 50%; display: grid; place-items: center; background: rgba(15, 12, 34, .6); color: #fff; box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .18) inset; z-index: 2; }
.arrow.l { left: 12px; } .arrow.r { right: 12px; } .arrow svg { width: 1.3em; height: 1.3em; stroke-width: 3.2; } .arrow:hover { background: var(--acc); color: #0F0C22; }
.hg-lock { position: absolute; left: 14px; top: 14px; display: inline-flex; align-items: center; gap: .5em; padding: .3em .9em; border-radius: 99px; background: rgba(255, 91, 46, .2); box-shadow: 0 0 0 1.5px rgba(255, 91, 46, .5) inset; font-weight: 800; z-index: 2; } .hg-lock svg { width: 1.2em; height: 1.2em; }
.hg-info { padding: 1rem .4rem 0; }
.hg-nm { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.hg-nm h3 { margin: 0; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: clamp(1.7rem, 1rem + 1.5vw, 2.8rem); line-height: 1; color: var(--acc); text-shadow: 0 4px 0 rgba(0, 0, 0, .4); }
.hg-nm span { font-weight: 800; font-size: .8rem; letter-spacing: .1em; color: var(--mute); }
.hg-info p { margin: .3em 0 .8em; font-weight: 600; color: #E2DEFF; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .6rem; margin-bottom: 1rem; }
.stats div { padding: .5em .7em; border-radius: 12px; background: rgba(255, 255, 255, .06); }
.stats small { display: block; font-size: max(12px, .65rem); font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--mute); margin-bottom: .3em; }
.stats .pips u.on, .up .pips u.on { background: linear-gradient(90deg, var(--acc, #2FD6FF), #fff); box-shadow: 0 0 .5em var(--acc, #2FD6FF); }
.hg-act { display: flex; align-items: center; gap: .8rem; }
.eqd { display: inline-flex; align-items: center; gap: .5em; padding: .6em 1.4em; border-radius: 14px; background: rgba(198, 255, 61, .16); box-shadow: 0 0 0 1.5px rgba(198, 255, 61, .5) inset; color: var(--lime); font-family: var(--font-d); text-transform: uppercase; } .eqd svg { width: 1.2em; height: 1.2em; stroke-width: 3; }
.strip { display: grid; grid-template-columns: repeat(6, 1fr); gap: .5rem; margin-bottom: 1.2rem; }
.th { --acc: #2FD6FF; position: relative; padding: 0; border: 0; aspect-ratio: 1; border-radius: 16px; background: rgba(255, 255, 255, .07); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .1) inset; overflow: hidden; transition: transform .12s, background .15s; }
.th img { width: 100%; height: 100%; object-fit: contain; display: block; padding: 6%; }
.th:hover { transform: translateY(-3px); background: rgba(255, 255, 255, .13); }
.th.sel { box-shadow: 0 0 0 3px var(--acc) inset, 0 0 1.2rem color-mix(in srgb, var(--acc) 50%, transparent); background: color-mix(in srgb, var(--acc) 20%, transparent); }
.th.eq::after { content: ""; position: absolute; right: 6px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 8px var(--lime); }
.th.lk img { opacity: .55; filter: grayscale(.6); } .th s { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); text-decoration: none; display: grid; place-items: center; width: 1.8em; height: 1.8em; border-radius: 50%; background: rgba(15, 12, 34, .75); } .th s svg { width: 1em; height: 1em; }
.hg-r h4 { margin: 0 0 .6rem; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: 1.1rem; color: var(--sun); }
.ups { display: grid; gap: .6rem; }
.up { display: grid; grid-template-columns: 1fr auto auto; gap: .8rem; align-items: center; padding: .7em 1em; border-radius: 16px; background: rgba(255, 255, 255, .06); }
.up-h b { display: block; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: .95rem; } .up-h span { font-size: max(12px, .78rem); color: var(--mute); font-weight: 600; }
.up .pips u { width: .9em; height: .5em; } .maxed { font-family: var(--font-d); color: var(--lime); font-size: .85rem; padding: 0 .6em; }

/* cards */
.card { width: min(34rem, 100%); text-align: center; padding: 1.8rem 1.8rem 1.5rem; border-radius: 28px; background: linear-gradient(180deg, #2A2260, #1B1540); box-shadow: 0 0 0 2px rgba(255, 255, 255, .12) inset, 0 30px 80px rgba(0, 0, 0, .55); animation: gwrise .35s var(--ease); margin: auto; }
.card h2 { font-family: var(--font-d); font-weight: 400; font-size: clamp(1.8rem, 1rem + 2.2vw, 3rem); line-height: 1; margin: 0 0 .3em; text-transform: uppercase; text-shadow: 0 4px 0 rgba(0, 0, 0, .35); }
.card .k { display: block; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; font-size: max(12px, .75rem); color: var(--acc, var(--violet)); margin-bottom: .4em; }
.card .sub { margin: 0 0 1rem; color: #CFC9F5; font-weight: 600; }
.card .acts { display: grid; gap: .6rem; margin-top: 1.1rem; } .card .acts .row { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.card .acts .btn { width: 100%; }
.card .rec { display: inline-block; margin: .4rem 0; padding: .3em 1em; border-radius: 99px; background: var(--sun); color: var(--ink); font-family: var(--font-d); font-size: .9rem; transform: rotate(-3deg); box-shadow: 0 3px 0 #B68A00; }
.score-big { font-family: var(--font-d); font-size: clamp(2.6rem, 1.4rem + 4vw, 4.8rem); line-height: 1; color: var(--acc, var(--violet)); text-shadow: 0 5px 0 rgba(0, 0, 0, .4); font-variant-numeric: tabular-nums; margin: .15em 0; }
.biglab { font-size: max(12px, .7rem); font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--mute); }
.grid, .mini { display: grid; grid-template-columns: repeat(auto-fit, minmax(6.4rem, 1fr)); gap: .5rem; margin: 1rem 0; }
.grid div, .mini div { padding: .6em .4em; border-radius: 14px; background: rgba(255, 255, 255, .06); line-height: 1.1; }
.grid small, .mini small { display: block; font-size: max(12px, .62rem); font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--mute); margin-bottom: .3em; }
.grid b, .mini b { font-family: var(--font-d); font-weight: 400; font-size: 1.25rem; } .grid b i { font-style: normal; font-size: .6em; color: var(--mute); }
.bigstars { display: flex; justify-content: center; gap: .5rem; margin: .5rem 0 .8rem; }
.bst { display: inline-block; transform: scale(0); animation: gwstar .55s var(--d) forwards cubic-bezier(.3, 1.6, .5, 1); filter: drop-shadow(0 6px 0 rgba(0, 0, 0, .35)); }
.bst:nth-child(2) { margin-top: -.7rem; } .bst svg { width: 4.2rem; height: 4.2rem; fill: rgba(255, 255, 255, .2); stroke: none; } .bst.on svg { fill: var(--sun); filter: drop-shadow(0 0 .6rem rgba(255, 210, 63, .7)); }
@keyframes gwstar { 0% { transform: scale(0) rotate(-50deg); } 100% { transform: scale(1) rotate(0); } }
.card--clear .objs { text-align: left; } .card--clear .objs li { animation: gwrise .4s var(--d) both; }
.objs li.no { color: #8F89BE; } .objs li i svg { width: 1.2em; height: 1.2em; stroke-width: 3; } .objs li.ok i svg { color: var(--lime); } .objs li.no i svg { color: #FF5B2E; }
.bonus { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; padding: 0; margin: 0 0 .5rem; }
.bonus li { display: flex; align-items: center; gap: .5em; padding: .3em .9em; border-radius: 99px; background: rgba(255, 255, 255, .07); font-weight: 700; font-size: .85rem; color: #CFC9F5; }
.bonus li b { font-family: var(--font-d); font-weight: 400; color: #fff; } .bonus li.good { background: rgba(198, 255, 61, .16); } .bonus li.good b { color: var(--lime); } .bonus li.gold b { color: var(--sun); } .bonus svg { width: 1.3em; height: 1.3em; }
.unl { margin: .6rem 0 0; padding: .45em 1em; border-radius: 14px; background: color-mix(in srgb, var(--acc, #9B7BFF) 22%, transparent); box-shadow: 0 0 0 2px var(--acc, #9B7BFF) inset; font-family: var(--font-d); text-transform: uppercase; font-size: .9rem; animation: gwrise .5s 1.2s both var(--ease); }
.bar { position: relative; height: 1.6em; border-radius: 99px; background: rgba(255, 255, 255, .1); overflow: hidden; margin: .8rem 0 .2rem; }
.bar i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #FF5B2E, #FFD23F); border-radius: inherit; } .bar b { position: relative; font-family: var(--font-d); font-weight: 400; font-size: .85em; line-height: 1.9; text-shadow: 0 2px 0 rgba(0, 0, 0, .5); }
.card--set { width: min(36rem, 100%); text-align: left; } .card--set h2 { text-align: center; }
.opt { margin: .7rem 0; display: grid; gap: .35rem; } .opt small { font-size: max(12px, .66rem); font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--mute); }
.seg { display: flex; gap: 6px; flex-wrap: wrap; } .seg button { flex: 1; min-width: 4.4em; min-height: 2.6em; padding: .5em .8em; border: 0; border-radius: 11px; background: rgba(255, 255, 255, .08); font-weight: 800; font-size: .9rem; color: #D6D1FA; box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .1) inset; }
.seg button:hover { background: rgba(255, 255, 255, .14); } .seg button.on { background: var(--violet); color: #120a33; box-shadow: none; }
input[type=range] { width: 100%; height: 2.2em; accent-color: var(--violet); touch-action: pan-y; }
.card--how { width: min(66rem, 100%); text-align: left; } .card--how h2 { text-align: center; }
.how { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem 2rem; } .how-w { grid-column: 1 / -1; }
.how h4 { margin: 0 0 .5rem; font-family: var(--font-d); font-weight: 400; text-transform: uppercase; font-size: 1.05rem; color: var(--violet); }
.how ul { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; gap: .45rem; font-weight: 600; font-size: .93rem; color: #DCD7FF; line-height: 1.35; }
.keys kbd, .how kbd { font-family: var(--font-d); font-size: .75rem; padding: .3em .55em; border-radius: 8px; background: #fff; color: var(--ink); box-shadow: 0 3px 0 #9992c2; white-space: nowrap; margin-right: .35em; }
.plain li { padding-left: 1.1em; position: relative; } .plain li::before { content: ""; position: absolute; left: 0; top: .55em; width: .45em; height: .45em; border-radius: 50%; background: var(--violet); }
.pk li { display: grid; grid-template-columns: 2.6rem 1fr; gap: .7rem; align-items: center; } .pk img { width: 2.6rem; height: 2.6rem; } .pk b { display: block; color: #fff; } .pk span { font-size: .82rem; color: #B9B3E6; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .secgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .sec:nth-child(5n+2), .sec:nth-child(5n+4) { transform: none; }
  .hangar { grid-template-columns: 1fr; } .hud-boss { width: min(70vw, 760px); }
}
@media (max-width: 760px) {
  html { font-size: 15px; }
  .gw-home b { display: none; } .gw-home { padding: 6px; }
  .secgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sec { min-height: 13.5rem; }
  .brief { grid-template-columns: 1fr; text-align: center; padding: 1.2rem; } .brief-pl { max-width: 11rem; margin: 0 auto; } .brief .chips, .brief .cta { justify-content: center; } .objs { text-align: left; }
  .how { grid-template-columns: 1fr; } .stats { grid-template-columns: repeat(2, 1fr); } .strip { grid-template-columns: repeat(6, 1fr); gap: .3rem; }
  .up { grid-template-columns: 1fr auto; } .up .pips { grid-column: 1; } .up > .btn, .up .maxed { grid-column: 2; grid-row: 1 / 3; }
  .menu { align-items: end; text-align: center; padding-bottom: calc(var(--sab) + 1rem); } .menu-l { margin: 0 auto; } .gtitle { justify-items: center; font-size: clamp(3rem, 17vw, 5rem); } .gtitle b.b2 { margin-left: 0; }
  .kick { justify-content: center; } .kick::before { display: none; } .tag { margin-inline: auto; font-size: .95rem; margin-bottom: 1rem; } .cta, .cta2, .chips { justify-content: center; } .ov--menu.show { background: linear-gradient(0deg, rgba(10, 6, 34, .92) 0%, rgba(10, 6, 34, .6) 55%, rgba(10, 6, 34, .1) 100%); }
  .hide-s { display: none; } .chip { padding: .4em .8em; } .chip b { font-size: 1rem; }
  .hud-c { left: 0; right: 0; width: auto; transform: none; top: calc(var(--sat) + 3px); padding: 0 calc(var(--sar) + 12px) 0 calc(var(--sal) + 12px); }
  .hud-sec { display: none; } .hud-prog { height: .4em; }
  .hud-l { top: calc(var(--sat) + 16px); gap: .3em; } .hp svg { width: 1.3em; height: 1.3em; } .hud-score b { font-size: 1.5em; }
  .hud-r { top: calc(var(--sat) + 62px); } .hud-boss { top: calc(var(--sat) + 9.2em); width: 86vw; }
  .gw-tools { gap: 6px; } .gw-tool { width: 44px; height: 44px; } .gw-tool[data-a=full] { display: none; }
  .hud-pow { max-width: 62vw; font-size: .9em; } .card { padding: 1.3rem 1.1rem 1.1rem; } .bst svg { width: 3.4rem; height: 3.4rem; }
}
@media (max-height: 560px) {
  .hide-s { display: none; } .chips .chip:nth-child(n+3) { display: none; } .cta2 { margin-top: .6rem; } .cta { margin-top: .2rem; }
  .screen { padding-top: calc(var(--sat) + 3.6rem); } .gtitle { font-size: clamp(2.4rem, 14vh, 5rem); } .tag { display: none; } .chips { margin-top: .8rem; } .kick i { display: none; }
  .card { padding: 1rem 1.2rem; } .card h2 { font-size: 1.7rem; } .bst svg { width: 2.6rem; height: 2.6rem; } .score-big { font-size: 2.2rem; } .grid, .mini { margin: .5rem 0; }
  .objs li { padding: .25em .7em; } .card .acts { margin-top: .6rem; } .bonus { margin-bottom: 0; } .hg-stage { height: 52vh; }
}
@media (max-height: 560px) and (orientation: landscape) {
  .menu { padding-top: calc(var(--sat) + 3.4rem); } .menu-l { width: min(34rem, 60%); } .secgrid { grid-template-columns: repeat(5, minmax(0, 1fr)); } .sec { min-height: 10.5rem; padding: .6em; } .sec-tag { display: none; } .sec-n { font-size: 1.2rem; }
  .hud-l { top: calc(var(--sat) + 10px); } .hud-boss { top: calc(var(--sat) + 3.4em); width: 46vw; } .hud-r { top: calc(var(--sat) + 8px); right: calc(var(--sar) + 110px); }
  .hangar { grid-template-columns: 1fr 1fr; } .gw-bomb { bottom: calc(var(--sab) + 10px); }
  .card--clear .objs li { font-size: .8rem; } .brief { grid-template-columns: 1fr 1.6fr; padding: 1rem; } .brief-pl { max-width: 9rem; }
}
@media (prefers-reduced-motion: reduce) { .gtitle b, .sec.cur { animation: none; } .gw-banner.warn h2 { animation: none; } }
