:root { --a: #3cf2ff; --b: #ff3c8a; --bg: #07040f; --card: rgba(12, 8, 26, 0.92); --line: rgba(255,255,255,0.12); }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: #eef; font: 15px/1.4 system-ui, -apple-system, Segoe UI, sans-serif; overflow: hidden; }
canvas#view { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
[hidden] { display: none !important; }
a, .linky { color: var(--a); cursor: pointer; }
button, select, input { font: inherit; color: inherit; }
button { background: rgba(255,255,255,0.08); border: 1px solid var(--line); border-radius: 8px; padding: 8px 14px; cursor: pointer; }
button:hover { border-color: var(--a); }
button.big { background: linear-gradient(90deg, var(--a), var(--b)); color: #05010f; font-weight: 800; letter-spacing: 0.08em; border: 0; padding: 14px 22px; width: 100%; font-size: 17px; }
select, input[type=text], input:not([type]) { background: rgba(0,0,0,0.4); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; width: 100%; }
input[type=range] { width: 100%; accent-color: var(--a); }
label { display: block; margin: 10px 0 4px; font-size: 13px; color: #b9b6d6; }
.overlay { position: fixed; inset: 0; display: grid; place-items: center; background: radial-gradient(ellipse at center, rgba(20,5,40,0.55), rgba(0,0,0,0.85)); z-index: 10; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 24px 28px; box-shadow: 0 0 60px rgba(60,242,255,0.12); max-height: 92vh; overflow: auto; }
.lobby-card { width: min(460px, 94vw); }
.logo { margin: 0; font-size: 46px; font-weight: 900; letter-spacing: 0.06em; background: linear-gradient(90deg, var(--a), var(--b)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.logo span { margin-left: 10px; }
.tag { margin: 0 0 8px; color: #9c98c4; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.swatches button { width: 30px; height: 30px; border-radius: 50%; padding: 0; border: 2px solid transparent; }
.swatches button.on { border-color: #fff; box-shadow: 0 0 12px currentColor; }
.row { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 14px; }
.pill { display: inline-flex; gap: 6px; align-items: center; background: rgba(255,255,255,0.05); padding: 6px 10px; border-radius: 20px; margin: 0; color: #dde; }
.msg { color: #ffb23c; min-height: 1em; }
.hint { font-size: 12px; color: #8a86b0; }

#hud { position: fixed; inset: 0; pointer-events: none; z-index: 5; }
#crosshair { position: absolute; left: 50%; top: 50%; width: 22px; height: 22px; margin: -11px; border: 2px solid rgba(255,255,255,0.85); border-radius: 50%; box-shadow: 0 0 8px var(--a); }
#crosshair::after { content: ''; position: absolute; left: 50%; top: 50%; width: 3px; height: 3px; margin: -1.5px; background: #fff; border-radius: 50%; }
#hitmark { position: absolute; left: 50%; top: 50%; width: 34px; height: 34px; margin: -17px; opacity: 0; transition: opacity 0.12s;
  background: linear-gradient(45deg, transparent 46%, #fff 46%, #fff 54%, transparent 54%), linear-gradient(-45deg, transparent 46%, #fff 46%, #fff 54%, transparent 54%); }
#hitmark.on { opacity: 1; transition: none; }
#hitmark.kill { filter: drop-shadow(0 0 6px #ff3c3c) hue-rotate(-40deg); }
#scope { position: absolute; inset: 0; display: none; background: radial-gradient(circle at center, transparent 0 34vh, rgba(0,0,0,0.92) 34.3vh); }
#scope .ring { position: absolute; left: 50%; top: 50%; width: 68vh; height: 68vh; transform: translate(-50%, -50%); border-radius: 50%; border: 2px solid rgba(255,60,60,0.6);
  background: linear-gradient(transparent calc(50% - 1px), rgba(255,60,60,0.8) calc(50% - 1px), rgba(255,60,60,0.8) calc(50% + 1px), transparent calc(50% + 1px)),
              linear-gradient(90deg, transparent calc(50% - 1px), rgba(255,60,60,0.8) calc(50% - 1px), rgba(255,60,60,0.8) calc(50% + 1px), transparent calc(50% + 1px)); }
body.scoped #scope { display: block; }
body.scoped #crosshair { display: none; }
#vignette { position: absolute; inset: 0; box-shadow: inset 0 0 160px rgba(255,0,40,0.9); opacity: 0; transition: opacity 0.4s; }
#top { position: absolute; top: 12px; left: 14px; right: 14px; display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
#np { display: flex; gap: 10px; align-items: center; background: rgba(0,0,0,0.45); border: 1px solid var(--line); padding: 8px 12px; border-radius: 12px; max-width: 34vw; }
#np b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#np small { color: #9c98c4; display: block; }
#eq { display: flex; gap: 2px; align-items: flex-end; height: 26px; }
#eq i { width: 4px; background: linear-gradient(var(--b), var(--a)); border-radius: 2px; }
#matchbox { text-align: center; }
#timer { font-size: 26px; font-weight: 800; letter-spacing: 0.08em; text-shadow: 0 0 12px var(--a); }
#lead { font-size: 13px; color: #c9c6e8; }
#feed { text-align: right; min-width: 260px; font-size: 14px; }
#feed div { background: rgba(0,0,0,0.45); padding: 3px 10px; border-radius: 6px; margin-bottom: 4px; display: inline-block; }
#talkers { position: absolute; left: 14px; top: 80px; font-size: 13px; }
#talkers div { color: #7dff5c; text-shadow: 0 0 6px #7dff5c; }
#buffs { position: absolute; right: 14px; bottom: 120px; text-align: right; }
#buffs div { font-weight: 700; text-shadow: 0 0 8px currentColor; }
#center { position: absolute; left: 0; right: 0; top: 30%; text-align: center; font-size: 28px; font-weight: 900; letter-spacing: 0.05em; text-shadow: 0 0 18px var(--b); }
#center small { display: block; font-size: 15px; font-weight: 500; color: #ccc; }
#chatlog { position: absolute; left: 14px; bottom: 100px; width: min(440px, 50vw); font-size: 14px; }
#chatlog div { background: rgba(0,0,0,0.4); padding: 2px 8px; border-radius: 5px; margin-top: 3px; transition: opacity 1s; }
#chatlog div.sys { color: #9c98c4; font-style: italic; }
#chatin { position: absolute; left: 14px; bottom: 64px; width: min(440px, 60vw); pointer-events: auto; }
#bottom { position: absolute; left: 14px; right: 14px; bottom: 12px; display: flex; justify-content: space-between; align-items: flex-end; }
.vitals { display: flex; gap: 18px; }
.vitals div, .ammo { background: rgba(0,0,0,0.45); border: 1px solid var(--line); border-radius: 12px; padding: 6px 16px; }
.vitals small, .ammo small { display: block; color: #9c98c4; font-size: 11px; letter-spacing: 0.1em; }
.vitals b, .ammo b { font-size: 34px; font-weight: 900; }
#hp { color: #4dff88; } #armor { color: #ffd34d; }
.ammo { text-align: right; }
#weapons { display: flex; gap: 6px; }
#weapons div { min-width: 44px; padding: 4px 8px; border-radius: 8px; background: rgba(0,0,0,0.45); border: 1px solid var(--line); font-size: 11px; text-align: center; opacity: 0.35; }
#weapons div.have { opacity: 0.8; }
#weapons div.on { opacity: 1; border-color: currentColor; box-shadow: 0 0 10px currentColor; }
#weapons b { display: block; font-size: 15px; }
#micState { position: absolute; right: 14px; bottom: 90px; font-size: 12px; color: #9c98c4; }
#micState.live { color: #7dff5c; }

table { border-collapse: collapse; width: 100%; min-width: 380px; }
td, th { padding: 6px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.menu-card { width: min(760px, 96vw); min-height: 60vh; display: flex; flex-direction: column; }
#tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
#tabs button.on { background: linear-gradient(90deg, var(--a), var(--b)); color: #05010f; font-weight: 700; }
.tab { flex: 1; }
.menu-foot { display: flex; align-items: center; gap: 16px; margin-top: 16px; }
.menu-foot .big { width: auto; flex: 1; }
.drop { border: 2px dashed var(--a); border-radius: 12px; padding: 22px; text-align: center; background: rgba(60,242,255,0.05); }
.drop.over { background: rgba(60,242,255,0.18); }
.drop small { display: block; color: #9c98c4; margin-top: 6px; }
h3 { margin: 16px 0 6px; font-size: 14px; letter-spacing: 0.08em; color: #b9b6d6; text-transform: uppercase; }
.lib { list-style: none; padding: 0; max-height: 200px; overflow: auto; }
.lib li { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; border-bottom: 1px solid var(--line); }
.lib button { padding: 3px 10px; font-size: 12px; }
.maps { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.maps button { text-align: left; padding: 12px; }
.maps button.voted { border-color: var(--b); box-shadow: 0 0 12px var(--b); }
.maps small { display: block; color: #9c98c4; }
.keys li { margin-bottom: 6px; }
