/* TatAI: Front page, HUD and menus (owner: front-core). Team colours: --t0 legion red, --t1 union blue. */
:root { --t0: #d8392b; --t1: #3d7be0; --ink: #ece6da; --dim: rgba(236,230,218,.6); --bg: rgba(10,9,8,.72); }
html, body { margin: 0; height: 100%; overflow: hidden; background: #0b0a09; color: var(--ink);
  font-family: "Bahnschrift", "Segoe UI", system-ui, sans-serif; user-select: none; -webkit-user-select: none; touch-action: none;
  overscroll-behavior: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
/* mob: <body> is the size container (client/ui/screen.js): on a phone held sideways with its lock on, the page is
   upright and the body is drawn turned, so sizes are cqw / cqh / @container, never vw / vh / @media. The safe areas in
   game space (the Dynamic Island on the game's left, the home indicator on its right): --safe-l/r/t/b. */
body { container-type: size; }
input, textarea { user-select: text; -webkit-user-select: text; }
:root { --safe-l: env(safe-area-inset-left, 0px); --safe-r: env(safe-area-inset-right, 0px); --safe-t: env(safe-area-inset-top, 0px); --safe-b: env(safe-area-inset-bottom, 0px); }
html.gk-rot { --safe-l: env(safe-area-inset-top, 0px); --safe-r: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-right, 0px); --safe-b: env(safe-area-inset-left, 0px); }
#view { position: fixed; inset: 0; width: 100cqw; height: 100cqh; display: block; }
#hud { position: fixed; inset: 0; pointer-events: none; z-index: 10; overflow: hidden; }
#ui { position: fixed; inset: 0; pointer-events: none; z-index: 20; }
#ui > * { pointer-events: auto; }
#overlay { position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at center, rgba(20,14,10,.7), rgba(0,0,0,.94)); }
#overlay.hidden { display: none; }
#overlay .boot { text-align: center; max-width: 900px; padding: 16px; }
#overlay h1 { font-size: clamp(36px, 7cqw, 76px); letter-spacing: .1em; margin: 0 0 6px; }
#overlay h1 span { display: block; font-size: .3em; letter-spacing: .6em; opacity: .8; }
#overlay p { opacity: .85; white-space: pre-line; }

/* menus: team pick, respawn */
.menu { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(0,0,0,.55); gap: 18px; padding: 16px; box-sizing: border-box; }
.menu.hidden { display: none; }
.menu h2 { margin: 0; font-size: clamp(22px, 4cqw, 38px); letter-spacing: .06em; text-align: center; }
.menu .sub { color: var(--dim); text-align: center; }
.teams { display: flex; gap: 18px; flex-wrap: wrap; justify-content: center; }
.team-card { width: min(340px, 86cqw); padding: 18px; border: 2px solid currentColor; background: var(--bg); cursor: pointer;
  text-align: left; font: inherit; color: var(--ink); }
.team-card.t0 { border-color: var(--t0); } .team-card.t1 { border-color: var(--t1); }
.team-card:hover, .team-card:focus { background: rgba(255,255,255,.08); outline: none; }
.team-card b { display: block; font-size: 24px; margin-bottom: 6px; }
.team-card.t0 b { color: var(--t0); } .team-card.t1 b { color: var(--t1); }
.team-card i { display: block; font-style: normal; color: var(--dim); margin-bottom: 10px; }
.menu input { font: inherit; font-size: 18px; padding: 8px 12px; background: var(--bg); color: var(--ink); border: 1px solid var(--dim); width: min(320px, 80cqw); }
.spawn-list { display: flex; flex-direction: column; gap: 8px; width: min(420px, 90cqw); max-height: 50cqh; overflow: auto; }
.spawn-list button { font: inherit; font-size: 18px; padding: 10px 14px; text-align: left; background: var(--bg); color: var(--ink);
  border: 1px solid var(--dim); cursor: pointer; }
.spawn-list button.sel { border-color: var(--ink); background: rgba(255,255,255,.12); }
.big-btn { font: inherit; font-size: 20px; letter-spacing: .1em; padding: 12px 34px; background: transparent; color: var(--ink);
  border: 2px solid var(--ink); cursor: pointer; }
.big-btn:disabled { opacity: .4; cursor: wait; }
.menu .row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

/* HUD */
.hud-cross { position: absolute; left: 50%; top: 50%; width: 0; height: 0; }
.hud-cross i { position: absolute; background: rgba(255,255,255,.9); box-shadow: 0 0 2px #000; }
.hud-cross .h { width: 8px; height: 2px; top: -1px; } .hud-cross .v { width: 2px; height: 8px; left: -1px; }
/* fp-view: the jetpack's fuel, a thin bar right of the crosshair */
.hud-fuel { position: absolute; left: calc(50% + 46px); top: calc(50% - 26px); width: 5px; height: 52px; background: rgba(0,0,0,.45); box-shadow: 0 0 0 1px rgba(255,255,255,.35); border-radius: 2px; overflow: hidden; }
.hud-fuel i { position: absolute; left: 0; right: 0; bottom: 0; height: 100%; background: linear-gradient(0deg, #ff8a2a, #ffe9a0); transform-origin: 50% 100%; }
.hud-fuel.low i { background: #ff4a30; }
.hud-hit { position: absolute; left: 50%; top: 50%; width: 0; height: 0; opacity: 0; }
.hud-hit i { position: absolute; width: 10px; height: 2px; left: -5px; top: -1px; background: #fff; box-shadow: 0 0 2px #000; }
.hud-hit.head i { background: #ffd04a; width: 13px; left: -6px; height: 3px; }
.hud-hit.limb i { background: rgba(220,220,220,.8); width: 7px; left: -3px; }
.hud-hit.kill i { background: #ff4b3a; width: 16px; left: -8px; height: 3px; box-shadow: 0 0 4px #000, 0 0 8px rgba(255,60,40,.8); }
.hud-bl { position: absolute; left: calc(22px + var(--safe-l)); bottom: calc(20px + var(--safe-b)); display: flex; flex-direction: column; gap: 6px; text-shadow: 0 1px 2px #000; }
.hud-hp { font-size: 34px; font-weight: 700; } .hud-hp small { font-size: 14px; color: var(--dim); margin-left: 6px; }
.hud-hpbar { width: 220px; height: 8px; background: rgba(0,0,0,.5); } .hud-hpbar i { display: block; height: 100%; background: var(--ink); }
.hud-money { font-size: 18px; color: #f0d070; }
.hud-br { position: absolute; right: calc(22px + var(--safe-r)); bottom: calc(20px + var(--safe-b)); text-align: right; text-shadow: 0 1px 2px #000; }
.hud-ammo { font-size: 38px; font-weight: 700; } .hud-ammo small { font-size: 18px; color: var(--dim); }
.hud-wname { color: var(--dim); font-size: 14px; } .hud-note { font-size: 16px; color: #ffcf60; min-height: 20px; }
.hud-top { position: absolute; top: calc(10px + var(--safe-t)); left: 50%; transform: translateX(-50%); display: flex; gap: 6px; }
.hud-top .vp { min-width: 26px; height: 26px; line-height: 26px; text-align: center; font-weight: 700; font-size: 13px; background: rgba(0,0,0,.5);
  border: 2px solid #888; padding: 0 4px; }
.hud-top .vp.o0 { border-color: var(--t0); background: rgba(216,57,43,.55); } .hud-top .vp.o1 { border-color: var(--t1); background: rgba(61,123,224,.55); }
.hud-top .vp.contested { animation: blink .6s infinite alternate; }
/* how many victory points each side holds, either side of the strip */
.hud-vpn { position: absolute; top: calc(10px + var(--safe-t)); min-width: 30px; height: 26px; line-height: 26px; text-align: center; font-weight: 800; font-size: 18px; text-shadow: 0 1px 2px #000; }
.hud-vpn:empty { display: none; }
.hud-vpn.n0 { right: calc(50% + 104px); color: #ff7a6c; } .hud-vpn.n1 { left: calc(50% + 104px); color: #86b2ff; }
@keyframes blink { to { opacity: .45; } }
.hud-tr { position: absolute; top: calc(10px + var(--safe-t)); right: calc(14px + var(--safe-r)); text-align: right; font-size: 13px; color: var(--dim); text-shadow: 0 1px 2px #000; }
.hud-feed { position: absolute; top: calc(44px + var(--safe-t)); right: calc(14px + var(--safe-r)); display: flex; flex-direction: column; gap: 3px; align-items: flex-end;
  max-width: min(420px, calc(50cqw - 150px)); } /* never under the capture pane in the top centre */
.hud-feed div { background: rgba(0,0,0,.5); padding: 3px 8px; font-size: 14px; max-width: 100%; overflow-wrap: anywhere; text-align: right; }
.hud-feed .t0 { color: #ff7a6c; } .hud-feed .t1 { color: #86b2ff; } .hud-feed .me { outline: 1px solid var(--ink); }
.hud-center { position: absolute; left: 50%; top: 26%; transform: translateX(-50%); text-align: center; font-size: 22px; text-shadow: 0 1px 3px #000; }
.hud-center big { display: block; font-size: 54px; font-weight: 800; letter-spacing: .1em; }
.hud-hurt { position: absolute; left: 50%; top: 50%; width: 0; height: 0; }
/* damage direction: an arc around the crosshair, on the side the hit came from */
.hud-hurt i { position: absolute; width: 260px; height: 260px; left: -130px; top: -130px; box-sizing: border-box; border-radius: 50%;
  border: 6px solid transparent; border-top-color: rgba(255,45,30,.9); filter: drop-shadow(0 0 6px rgba(255,20,0,.7)); }
.hud-vignette { position: absolute; inset: 0; }
.hud-click { position: absolute; left: 50%; top: 60%; transform: translateX(-50%); background: var(--bg); padding: 10px 18px; font-size: 18px; }
.hidden { display: none !important; }
.tag { position: absolute; left: 0; top: 0; font-size: 12px; font-weight: 700; white-space: nowrap; text-shadow: 0 1px 2px #000; will-change: transform; }
.tag.t0 { color: #ff8578; } .tag.t1 { color: #8fb7ff; }
.tag em { display: block; font-style: normal; font-weight: 400; color: #fff; background: rgba(0,0,0,.55); padding: 1px 5px; margin-bottom: 2px; }

/* touch: the touch HUD is client/touch/ (touch.css) */
