:root {
  color-scheme: dark;
  --bg: #070b10;
  --panel: rgba(10, 16, 23, .94);
  --panel-soft: rgba(11, 19, 28, .78);
  --line: rgba(255, 255, 255, .12);
  --cyan: #58d9ef;
  --cyan-soft: #b5f6ff;
  --amber: #f6b94f;
  --red: #ef5b67;
  --text: #f5f8fb;
  --muted: #8795a8;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body, #app { width: 100%; height: 100%; margin: 0; overflow: hidden; background: var(--bg); }
body { user-select: none; overscroll-behavior: none; }
button { font: inherit; }
.hidden { display: none !important; }
#game-canvas { position: fixed; inset: 0; width: 100%; height: 100%; background: #081019; outline: none; }
.screen { position: fixed; inset: 0; z-index: 30; display: none; overflow: auto; background: radial-gradient(circle at 20% 15%, rgba(56, 115, 132, .19), transparent 38%), linear-gradient(135deg, #06090e 0%, #0b121b 54%, #07090e 100%); }
.screen.active { display: block; }
.menu-backdrop { position: absolute; inset: 0; opacity: .18; background-image: linear-gradient(rgba(88,217,239,.12) 1px, transparent 1px), linear-gradient(90deg, rgba(88,217,239,.12) 1px, transparent 1px); background-size: 58px 58px; mask-image: linear-gradient(to bottom, #000, transparent 80%); }
.menu-shell { position: relative; z-index: 1; min-height: 100%; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(340px, 470px); align-items: center; gap: clamp(32px, 6vw, 90px); padding: clamp(28px, 6vw, 92px); }
.hero-copy { max-width: 820px; }
.kicker { display: flex; align-items: center; gap: 12px; margin: 0; color: var(--cyan); font-size: 11px; font-weight: 800; letter-spacing: .22em; }
.kicker span { width: 42px; height: 2px; background: var(--cyan); box-shadow: 0 0 12px rgba(88,217,239,.65); }
h1 { margin: 25px 0 18px; color: var(--text); font-size: clamp(72px, 8.5vw, 138px); line-height: .75; letter-spacing: -.055em; text-transform: uppercase; }
h1 strong { color: transparent; -webkit-text-stroke: 2px var(--amber); text-shadow: 0 0 28px rgba(246,185,79,.15); }
.lead { max-width: 670px; margin: 0 0 24px; color: #bac4d0; font-size: 17px; line-height: 1.65; }
.feature-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 30px; }
.feature-row span { padding: 8px 11px; color: #b8c6d4; border: 1px solid var(--line); background: rgba(255,255,255,.025); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.primary-button, .secondary-button { border: 0; cursor: pointer; text-transform: uppercase; font-weight: 900; letter-spacing: .09em; transition: transform .16s ease, filter .16s ease, border-color .16s ease; }
.primary-button { min-width: 300px; padding: 17px 22px; color: #061015; background: linear-gradient(110deg, var(--cyan), var(--cyan-soft)); box-shadow: 0 15px 40px rgba(88,217,239,.17); }
.primary-button span { float: right; font-size: 20px; }
.secondary-button { margin-left: 8px; padding: 16px 20px; color: #d1dae4; background: rgba(255,255,255,.025); border: 1px solid var(--line); }
.primary-button:hover, .secondary-button:hover { transform: translateY(-2px); filter: brightness(1.08); }
.compatibility { margin: 16px 0 0; color: #657386; font-size: 11px; }
.map-panel { padding: 26px; border: 1px solid var(--line); background: linear-gradient(155deg, rgba(15,23,33,.95), rgba(7,11,17,.86)); box-shadow: 0 28px 80px rgba(0,0,0,.36); backdrop-filter: blur(14px); }
.map-panel header { margin-bottom: 15px; }
.map-panel header p { margin: 0 0 5px; color: var(--amber); font-size: 9px; font-weight: 800; letter-spacing: .18em; }
.map-panel header strong { color: white; font-size: 23px; letter-spacing: .04em; }
.map-grid { display: grid; gap: 9px; }
.map-option { display: grid; grid-template-columns: 80px 1fr; gap: 12px; align-items: center; padding: 9px; color: white; text-align: left; border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.025); cursor: pointer; }
.map-option:hover, .map-option.selected { border-color: rgba(88,217,239,.65); background: rgba(88,217,239,.07); }
.map-thumb { height: 58px; border: 1px solid rgba(255,255,255,.12); background-color: #101b24; background-size: 18px 18px; }
.map-thumb.harbor { background-image: linear-gradient(30deg, rgba(58,126,143,.75) 12%, transparent 12.5%, transparent 87%, rgba(58,126,143,.75) 87.5%), linear-gradient(150deg, rgba(58,126,143,.5) 12%, transparent 12.5%, transparent 87%, rgba(58,126,143,.5) 87.5%); }
.map-thumb.foundry { background-image: radial-gradient(circle at 30% 40%, #9d6538 0 10%, transparent 11%), linear-gradient(135deg, transparent 42%, #83442d 43% 48%, transparent 49%); }
.map-thumb.district { background-image: linear-gradient(90deg, transparent 45%, rgba(228,191,100,.6) 46% 52%, transparent 53%), linear-gradient(rgba(94,120,139,.42) 46%, transparent 47%); }
.map-option span:last-child { display: grid; gap: 4px; }
.map-option b { font-size: 12px; }
.map-option small { color: #7f8da0; font-size: 9px; line-height: 1.4; }
.controls-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 7px 18px; margin-top: 18px; padding-top: 17px; border-top: 1px solid rgba(255,255,255,.07); }
.controls-summary p { display: flex; justify-content: space-between; gap: 10px; margin: 0; color: #8996a8; font-size: 9px; }
kbd { color: #e8faff; font-size: 9px; font-weight: 800; }

.hud { position: fixed; inset: 0; z-index: 12; pointer-events: none; color: white; }
.hud-top { position: absolute; inset: 0 0 auto; height: 84px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; padding: 15px 24px; background: linear-gradient(to bottom, rgba(2,5,8,.86), transparent); }
.brand { display: flex; gap: 10px; align-items: center; color: var(--cyan); font-size: 18px; font-weight: 900; }
.brand span { color: #7d8b9c; font-size: 9px; letter-spacing: .17em; }
.scoreboard { display: grid; grid-template-columns: 96px 132px 96px; gap: 3px; }
.team, .round-clock { height: 55px; display: flex; align-items: center; justify-content: center; gap: 10px; background: rgba(8,13,20,.88); border: 1px solid rgba(255,255,255,.09); }
.team b, .round-clock b { font-size: 25px; }
.team small, .round-clock small { color: #8290a3; font-size: 7px; letter-spacing: .13em; }
.team.blue { border-bottom: 2px solid var(--cyan); }
.team.red { border-bottom: 2px solid var(--red); }
.round-clock { display: grid; place-content: center; gap: 1px; border-bottom: 2px solid var(--amber); }
.round-clock small { color: var(--amber); text-align: center; }
.map-name { justify-self: end; display: grid; text-align: right; }
.map-name small { color: #728095; font-size: 7px; letter-spacing: .16em; }
.map-name b { color: var(--amber); font-size: 17px; }
.objective { position: absolute; top: 98px; left: 24px; display: flex; align-items: center; gap: 9px; padding: 10px 12px; border-left: 2px solid var(--amber); background: rgba(6,10,15,.72); }
.objective > span { width: 7px; height: 7px; border: 2px solid var(--amber); transform: rotate(45deg); }
.objective div { display: grid; gap: 2px; }
.objective small { color: #778599; font-size: 7px; letter-spacing: .14em; }
.objective b { font-size: 12px; letter-spacing: .04em; }
.kill-feed { position: absolute; right: 24px; top: 98px; width: 300px; display: grid; gap: 5px; }
.kill-entry { padding: 7px 10px; color: #aeb9c7; text-align: right; background: linear-gradient(90deg, transparent, rgba(3,7,11,.75)); font-size: 10px; animation: feedIn .2s ease; }
.kill-entry b { color: var(--cyan); }
.kill-entry em { color: var(--red); font-style: normal; }
@keyframes feedIn { from { opacity: 0; transform: translateX(14px); } }
.crosshair { position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; transform: translate(-50%, -50%); transition: transform .08s ease; }
.crosshair i { position: absolute; background: rgba(245,253,255,.95); box-shadow: 0 0 4px rgba(255,255,255,.45); }
.crosshair i:nth-child(1), .crosshair i:nth-child(2) { top: 22px; width: 10px; height: 2px; }
.crosshair i:nth-child(1) { left: 2px; } .crosshair i:nth-child(2) { right: 2px; }
.crosshair i:nth-child(3), .crosshair i:nth-child(4) { left: 22px; width: 2px; height: 10px; }
.crosshair i:nth-child(3) { top: 2px; } .crosshair i:nth-child(4) { bottom: 2px; }
.crosshair span { position: absolute; left: 20px; top: 20px; width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); }
.crosshair.firing { transform: translate(-50%, -50%) scale(1.24); }
.hitmarker { position: absolute; left: 50%; top: 50%; width: 36px; height: 36px; transform: translate(-50%,-50%); opacity: 0; }
.hitmarker.show { animation: hit .18s ease; }
.hitmarker i { position: absolute; width: 10px; height: 2px; background: white; }
.hitmarker i:nth-child(1) { left: 2px; top: 8px; transform: rotate(45deg); }
.hitmarker i:nth-child(2) { right: 2px; top: 8px; transform: rotate(-45deg); }
.hitmarker i:nth-child(3) { left: 2px; bottom: 8px; transform: rotate(-45deg); }
.hitmarker i:nth-child(4) { right: 2px; bottom: 8px; transform: rotate(45deg); }
@keyframes hit { 0% { opacity: 1; transform: translate(-50%,-50%) scale(.55); } 60% { opacity: 1; transform: translate(-50%,-50%) scale(1.15); } 100% { opacity: 0; } }
.damage-vignette { position: absolute; inset: 0; opacity: 0; background: radial-gradient(circle, transparent 47%, rgba(226,31,54,.68) 130%); transition: opacity .12s ease; }
.notice { position: absolute; left: 50%; top: 64%; transform: translateX(-50%); min-width: 210px; padding: 8px 13px; color: white; text-align: center; opacity: 0; background: rgba(4,8,12,.78); border: 1px solid rgba(255,255,255,.1); font-size: 10px; transition: opacity .18s ease; }
.notice.show { opacity: 1; }
.hud-bottom { position: absolute; inset: auto 24px 23px; display: flex; justify-content: space-between; align-items: end; gap: 18px; }
.vitals { width: 300px; display: grid; gap: 8px; padding: 11px 13px; border: 1px solid rgba(255,255,255,.1); border-left: 3px solid var(--cyan); background: linear-gradient(90deg, rgba(4,9,14,.86), rgba(4,9,14,.42)); backdrop-filter: blur(6px); }
.vitals > div { display: grid; grid-template-columns: 22px 38px 1fr; gap: 7px; align-items: center; }
.vitals span { font-size: 17px; } .vitals b { font-size: 21px; }
.vitals i { height: 5px; overflow: hidden; background: rgba(255,255,255,.11); transform: skewX(-18deg); }
.vitals em { display: block; width: 100%; height: 100%; background: #eefcf0; transition: width .15s ease; }
.vitals .armor span, .vitals .armor b { color: var(--cyan); }
.vitals .armor em { background: var(--cyan); }
.weapon-info { min-width: 230px; padding: 10px 13px; text-align: right; border: 1px solid rgba(255,255,255,.1); border-right: 3px solid var(--amber); background: linear-gradient(270deg, rgba(4,9,14,.86), rgba(4,9,14,.42)); backdrop-filter: blur(6px); }
.weapon-info div { display: flex; align-items: baseline; justify-content: end; gap: 7px; }
.weapon-info small { margin-right: 10px; color: #8190a4; font-size: 8px; letter-spacing: .14em; }
.weapon-info b { font-size: 44px; line-height: .9; }
.weapon-info span { color: #8895a7; font-size: 18px; }
.weapon-info em { font-style: normal; }
.weapon-info p { margin: 2px 0 0; color: #677486; font-size: 7px; letter-spacing: .08em; }
.round-banner { position: fixed; z-index: 24; left: 50%; top: 50%; transform: translate(-50%,-50%); min-width: min(520px, calc(100% - 36px)); padding: 30px; color: white; text-align: center; background: linear-gradient(90deg, transparent, rgba(6,11,17,.95) 15%, rgba(6,11,17,.95) 85%, transparent); }
.round-banner small { color: var(--amber); font-size: 8px; letter-spacing: .2em; }
.round-banner h2 { margin: 5px 0; font-size: 45px; }
.round-banner p { margin: 0; color: #8996a8; font-size: 11px; }
.pause-screen { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; background: rgba(3,6,9,.76); backdrop-filter: blur(8px); }
.pause-card { width: min(440px, calc(100% - 30px)); padding: 32px; color: white; text-align: center; border: 1px solid var(--line); background: #0b1119; }
.pause-card small { color: var(--cyan); font-size: 8px; letter-spacing: .18em; }
.pause-card h2 { margin: 8px 0; font-size: 34px; }
.pause-card p { color: #8995a6; }
.pause-card button { width: 100%; min-width: 0; margin: 8px 0 0; }
.loading { position: fixed; inset: 0; z-index: 80; display: grid; place-content: center; justify-items: center; color: white; background: #070b10; transition: opacity .3s ease; }
.loading.done { opacity: 0; pointer-events: none; }
.spinner { width: 42px; height: 42px; border: 3px solid rgba(255,255,255,.1); border-top-color: var(--cyan); border-radius: 50%; animation: spin .8s linear infinite; }
.loading p { color: #8c9bad; font-size: 11px; letter-spacing: .12em; }
@keyframes spin { to { transform: rotate(360deg); } }
.unsupported { position: fixed; z-index: 100; inset: auto 18px 18px; padding: 14px; color: white; background: #8f2d3b; }
.orientation-warning { position: fixed; inset: 0; z-index: 120; display: grid; place-content: center; justify-items: center; gap: 8px; padding: 28px; color: white; text-align: center; background: radial-gradient(circle at center, #152936, #06090e 72%); }
.phone-icon { width: 56px; height: 88px; display: grid; place-content: center; color: var(--cyan); border: 3px solid var(--cyan); border-radius: 10px; font-size: 38px; animation: phone 1.6s ease-in-out infinite; }
.orientation-warning h2 { margin: 14px 0 0; }
.orientation-warning p { margin: 0; color: #95a4b5; }
@keyframes phone { 0%,30% { transform: rotate(0deg); } 70%,100% { transform: rotate(90deg); } }
.mobile-controls { position: fixed; inset: 0; z-index: 16; pointer-events: none; touch-action: none; }
.move-zone { position: absolute; left: max(18px, env(safe-area-inset-left)); bottom: max(18px, env(safe-area-inset-bottom)); width: 145px; display: grid; justify-items: center; gap: 4px; pointer-events: auto; touch-action: none; }
.stick-ring { position: relative; width: 126px; height: 126px; border: 2px solid rgba(158,228,239,.34); border-radius: 50%; background: radial-gradient(circle, rgba(88,217,239,.13), rgba(5,10,15,.52) 68%); }
.stick-ring span { position: absolute; left: 50%; top: 50%; width: 54px; height: 54px; margin: -27px; border: 2px solid rgba(161,239,250,.75); border-radius: 50%; background: radial-gradient(circle at 35% 30%, rgba(201,251,255,.48), rgba(35,107,119,.75)); box-shadow: 0 0 18px rgba(88,217,239,.25); }
.move-zone small { color: rgba(220,244,249,.7); font-size: 7px; letter-spacing: .18em; }
.look-zone { position: absolute; inset: 60px 0 0 36%; pointer-events: auto; touch-action: none; }
.mobile-button { position: absolute; z-index: 2; display: grid; place-content: center; gap: 1px; width: 56px; height: 56px; padding: 0; color: white; border: 1px solid rgba(255,255,255,.23); border-radius: 50%; background: rgba(7,13,20,.64); pointer-events: auto; touch-action: none; }
.mobile-button:active, .mobile-button.active { transform: scale(.93); border-color: var(--cyan); background: rgba(30,105,116,.65); }
.mobile-button span { font-size: 20px; font-weight: 900; }.mobile-button small { font-size: 6px; font-weight: 900; }
.mobile-button.fire { right: max(22px, env(safe-area-inset-right)); bottom: max(22px, env(safe-area-inset-bottom)); width: 88px; height: 88px; color: #ffe4b1; border: 2px solid rgba(246,185,79,.75); background: radial-gradient(circle, rgba(246,185,79,.34), rgba(62,35,10,.72)); }
.mobile-button.fire span { font-size: 32px; }.mobile-button.fire small { font-size: 7px; }
.mobile-button.reload { right: max(100px, calc(env(safe-area-inset-right) + 100px)); bottom: max(100px, calc(env(safe-area-inset-bottom) + 100px)); }
.mobile-button.switch { right: max(38px, calc(env(safe-area-inset-right) + 38px)); bottom: max(128px, calc(env(safe-area-inset-bottom) + 128px)); }
.mobile-button.sprint { left: max(164px, calc(env(safe-area-inset-left) + 164px)); bottom: max(24px, env(safe-area-inset-bottom)); }
.mobile-button.pause { top: max(9px, env(safe-area-inset-top)); right: max(10px, env(safe-area-inset-right)); width: 40px; height: 40px; border-radius: 10px; }

@media (max-width: 980px) {
  .menu-shell { grid-template-columns: 1fr; align-items: start; }
  h1 { font-size: clamp(64px, 17vw, 105px); }
  .map-panel { max-width: 700px; }
  .scoreboard { transform: scale(.84); transform-origin: top center; }
  .brand span, .map-name small { display: none; }
}
@media (pointer: coarse) and (orientation: landscape) {
  .menu-shell { min-height: 100%; grid-template-columns: minmax(0, 1fr) 300px; align-items: center; gap: 22px; padding: max(16px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left)); }
  h1 { margin: 10px 0 8px; font-size: clamp(55px, 11vw, 88px); }
  .lead { margin-bottom: 10px; font-size: 11px; line-height: 1.35; }
  .feature-row { margin-bottom: 12px; }.feature-row span { padding: 5px 7px; font-size: 7px; }
  .primary-button { min-width: 210px; padding: 11px 13px; font-size: 10px; }.secondary-button { padding: 10px 12px; font-size: 9px; }
  .compatibility { margin-top: 7px; font-size: 8px; }.map-panel { padding: 12px; }.map-panel header { margin-bottom: 7px; }.map-panel header strong { font-size: 17px; }
  .map-grid { gap: 5px; }.map-option { grid-template-columns: 58px 1fr; padding: 5px; }.map-thumb { height: 39px; }.map-option b { font-size: 9px; }.map-option small { font-size: 6px; }
  .controls-summary { margin-top: 8px; padding-top: 8px; gap: 4px 10px; }.controls-summary p, kbd { font-size: 6px; }
  .hud-top { height: 58px; padding: max(6px, env(safe-area-inset-top)) max(55px, calc(env(safe-area-inset-right) + 48px)) 0 max(8px, env(safe-area-inset-left)); }
  .brand { font-size: 13px; }.scoreboard { grid-template-columns: 68px 92px 68px; transform: none; }.team, .round-clock { height: 40px; gap: 5px; }.team b, .round-clock b { font-size: 17px; }.team small, .round-clock small { font-size: 5px; }.map-name b { font-size: 11px; }
  .objective { top: max(53px, calc(env(safe-area-inset-top) + 45px)); left: max(8px, env(safe-area-inset-left)); padding: 5px 7px; }.objective small { font-size: 5px; }.objective b { font-size: 7px; }
  .kill-feed { top: 52px; right: max(55px, calc(env(safe-area-inset-right) + 48px)); width: 180px; }.kill-entry { padding: 4px 6px; font-size: 7px; }
  .hud-bottom { inset: auto max(120px, calc(env(safe-area-inset-right) + 112px)) max(6px, env(safe-area-inset-bottom)) max(226px, calc(env(safe-area-inset-left) + 226px)); gap: 6px; }.vitals { width: 160px; gap: 3px; padding: 5px 7px; }.vitals > div { grid-template-columns: 14px 25px 1fr; gap: 4px; }.vitals span { font-size: 11px; }.vitals b { font-size: 14px; }.weapon-info { min-width: 105px; padding: 5px 7px; }.weapon-info small { font-size: 5px; }.weapon-info b { font-size: 22px; }.weapon-info span { font-size: 11px; }.weapon-info p { display: none; }
  .notice { top: 70%; min-width: 160px; padding: 5px 8px; font-size: 7px; }.round-banner { min-width: 340px; padding: 16px; }.round-banner h2 { font-size: 30px; }
}
@media (pointer: coarse) and (orientation: portrait) {
  .orientation-warning:not(.hidden) { display: grid; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}
