* { box-sizing: border-box; user-select: none; }
html, body {
  margin: 0; padding: 0; overflow: hidden;
  background: #030710;
  font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
  color: #e4f2ff;
}
canvas { display: block; }
input, select { user-select: text; font-family: inherit; }

/* ================= 通用毛玻璃弹窗与大厅 ================= */
.overlay-screen {
  position: absolute; inset: 0; z-index: 30;
  display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(circle at 50% 25%, rgba(28, 72, 125, 0.52), rgba(3, 8, 18, 0.94) 72%),
    repeating-linear-gradient(0deg, rgba(58, 209, 255, 0.03) 0px, rgba(58, 209, 255, 0.03) 1px, transparent 1px, transparent 4px);
  backdrop-filter: blur(8px);
  padding: 16px;
}
.glass-panel {
  width: min(960px, 95vw);
  max-height: 92vh;
  overflow-y: auto;
  padding: 26px 32px;
  border: 1px solid rgba(72, 202, 255, 0.4);
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(10, 20, 38, 0.9), rgba(5, 10, 20, 0.95));
  box-shadow: 0 0 50px rgba(0, 170, 255, 0.22), inset 0 0 25px rgba(58, 209, 255, 0.07);
}
.panel-header {
  display: flex; justify-content: space-between; align-items: flex-end;
  border-bottom: 1px solid rgba(72, 202, 255, 0.25);
  padding-bottom: 14px; margin-bottom: 16px; flex-wrap: wrap; gap: 10px;
}
.title-block h1 {
  font-size: 30px; margin: 0; letter-spacing: 3px;
  background: linear-gradient(90deg, #ffffff, #5ce1ff, #9d7aff);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.title-block p.sub, .sub { font-size: 12px; color: #8ab4d8; margin: 4px 0 0; letter-spacing: 1.5px; }

.conn-badge {
  display: flex; align-items: center; gap: 8px;
  background: rgba(12, 28, 52, 0.78);
  border: 1px solid rgba(92, 225, 255, 0.35);
  padding: 7px 14px; border-radius: 20px; font-size: 12px; color: #bfe2ff;
}
.conn-dot { width: 9px; height: 9px; border-radius: 50%; background: #ffd166; box-shadow: 0 0 8px #ffd166; }
.conn-badge.online .conn-dot { background: #4dff9a; box-shadow: 0 0 8px #4dff9a; }
.conn-badge.offline .conn-dot { background: #ff5252; box-shadow: 0 0 8px #ff5252; }

.identity-bar {
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center;
  background: rgba(14, 28, 50, 0.65);
  border: 1px solid rgba(92, 225, 255, 0.2);
  padding: 10px 16px; border-radius: 10px; margin-bottom: 14px;
}
.field-inline { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #9fc4e4; }
.field-inline input[type="text"] {
  background: rgba(5, 12, 24, 0.85); border: 1px solid rgba(92, 225, 255, 0.35);
  color: #fff; padding: 7px 10px; border-radius: 6px; width: 155px; font-size: 13px;
}
.sens-inline { flex: 1; min-width: 180px; }
.sens-inline input[type="range"] { flex: 1; accent-color: #3ad1ff; }

.section-title {
  font-size: 12px; color: #5ce1ff; letter-spacing: 1.8px;
  text-transform: uppercase; margin: 12px 0 8px;
  display: flex; align-items: center; gap: 8px;
}
.section-title::before {
  content: ''; width: 4px; height: 12px; background: #5ce1ff;
  box-shadow: 0 0 8px #5ce1ff; border-radius: 2px;
}
.section-title-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }

.quick-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
@media (max-width: 760px) { .quick-grid { grid-template-columns: 1fr; } }
.quick-card {
  text-align: left; cursor: pointer; padding: 12px 14px; border-radius: 10px;
  background: rgba(15, 30, 56, 0.72); border: 1px solid rgba(92, 225, 255, 0.28);
  color: #e4f2ff; transition: all 0.16s;
}
.quick-card:hover { transform: translateY(-3px); border-color: #5ce1ff; box-shadow: 0 6px 22px rgba(0, 170, 255, 0.28); }
.quick-card.q-ffa:hover { border-color: #ffb84d; box-shadow: 0 6px 22px rgba(255, 168, 34, 0.28); }
.quick-card.q-tdm:hover { border-color: #f43f5e; box-shadow: 0 6px 22px rgba(244, 63, 94, 0.28); }
.q-badge { display: inline-block; font-size: 10px; font-weight: 800; padding: 2px 7px; border-radius: 4px; background: rgba(92, 225, 255, 0.2); color: #5ce1ff; margin-bottom: 5px; }
.q-ffa .q-badge { background: rgba(255, 184, 77, 0.2); color: #ffd166; }
.q-tdm .q-badge { background: rgba(244, 63, 94, 0.22); color: #ff6b81; }
.q-title { font-size: 14px; font-weight: 800; color: #fff; margin-bottom: 4px; }
.q-desc { font-size: 11px; color: #8fa9c4; line-height: 1.4; }

.lobby-columns, .room-body-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 14px; }
@media (max-width: 760px) { .lobby-columns, .room-body-grid { grid-template-columns: 1fr; } }
.sub-card {
  background: rgba(11, 22, 40, 0.7);
  border: 1px solid rgba(92, 225, 255, 0.22);
  border-radius: 10px; padding: 14px 16px;
}
.form-row { display: flex; flex-direction: column; gap: 5px; margin-bottom: 11px; font-size: 12px; color: #a8c6e4; }
.form-row input[type="text"], .form-row select, .host-group select {
  background: rgba(5, 12, 24, 0.9); border: 1px solid rgba(92, 225, 255, 0.35);
  color: #fff; padding: 8px 10px; border-radius: 6px; font-size: 13px;
}

.join-code-row { display: flex; gap: 8px; margin-bottom: 10px; }
.join-code-row input {
  flex: 1; background: rgba(5, 12, 24, 0.9); border: 1px solid rgba(92, 225, 255, 0.35);
  color: #fff; padding: 7px 10px; border-radius: 6px; text-transform: uppercase;
}
.room-list { max-height: 195px; overflow-y: auto; display: flex; flex-direction: column; gap: 7px; }
.room-item {
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
  background: rgba(16, 34, 62, 0.72); border: 1px solid rgba(92, 225, 255, 0.22);
  padding: 8px 11px; border-radius: 8px; font-size: 12px;
}
.room-item b { color: #fff; font-size: 13px; }
.room-meta { font-size: 11px; color: #8ab4d8; margin-top: 2px; }
.empty-hint { color: #7090b0; font-size: 12px; text-align: center; padding: 26px 8px; }

/* 按钮体系 */
.btn-group { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.btn-primary {
  padding: 11px 28px; font-size: 15px; letter-spacing: 2px; cursor: pointer;
  background: linear-gradient(135deg, #42e8ff 0%, #0088ff 55%, #5b3dff 100%);
  color: #fff; border: none; border-radius: 8px; font-weight: bold;
  box-shadow: 0 0 22px rgba(58, 209, 255, 0.5); transition: all 0.15s;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 0 32px rgba(92, 225, 255, 0.85); }
.btn-secondary {
  padding: 8px 14px; font-size: 12px; cursor: pointer;
  background: rgba(25, 48, 80, 0.78); color: #bfe2ff;
  border: 1px solid rgba(92, 225, 255, 0.4); border-radius: 7px; font-weight: bold;
}
.btn-secondary:hover { background: rgba(40, 76, 124, 0.88); color: #fff; }
.btn-danger {
  padding: 8px 16px; font-size: 12px; cursor: pointer;
  background: rgba(255, 75, 95, 0.2); color: #ff8a9a;
  border: 1px solid rgba(255, 90, 110, 0.55); border-radius: 7px; font-weight: bold;
}
.btn-danger:hover { background: rgba(255, 75, 95, 0.42); color: #fff; }
.btn-mini {
  padding: 5px 11px; font-size: 11px; cursor: pointer;
  background: rgba(30, 62, 102, 0.8); color: #7ef9ff;
  border: 1px solid rgba(92, 225, 255, 0.4); border-radius: 5px; font-weight: bold;
}
.full-width { width: 100%; }

/* 房间备战区 */
.room-controls-bar {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px;
  background: rgba(14, 28, 52, 0.7); padding: 10px 14px; border-radius: 9px; margin-bottom: 14px;
}
.host-group { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; color: #9fc4e4; }
.roster-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; max-height: 240px; overflow-y: auto; }
.roster-slot {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 11px; border-radius: 7px; font-size: 12px;
  background: rgba(18, 34, 60, 0.78); border-left: 3px solid #5ce1ff;
}
.roster-slot.team-alpha { border-left-color: #38bdf8; }
.roster-slot.team-omega { border-left-color: #ff4d6d; }
.roster-slot.is-bot { border-left-color: #4dff9a; }
.team-pill { font-size: 10px; font-weight: 800; padding: 2px 6px; border-radius: 4px; background: rgba(92, 225, 255, 0.2); color: #5ce1ff; }
.team-pill.alpha { background: rgba(56, 189, 248, 0.22); color: #38bdf8; }
.team-pill.omega { background: rgba(255, 77, 109, 0.22); color: #ff6b81; }

.chat-card { display: flex; flex-direction: column; }
.chat-log {
  height: 195px; overflow-y: auto; background: rgba(4, 10, 20, 0.72);
  border: 1px solid rgba(92, 225, 255, 0.16); border-radius: 7px;
  padding: 8px 10px; font-size: 12px; margin-bottom: 8px;
}
.chat-line { margin-bottom: 5px; line-height: 1.4; }
.chat-line.sys { color: #ffd166; }
.chat-input-row { display: flex; gap: 8px; }
.chat-input-row input {
  flex: 1; background: rgba(5, 12, 24, 0.9); border: 1px solid rgba(92, 225, 255, 0.35);
  color: #fff; padding: 7px 10px; border-radius: 6px; font-size: 12px;
}
.room-footer {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 16px; padding-top: 14px; border-top: 1px solid rgba(92, 225, 255, 0.22);
}
.wait-hint { font-size: 13px; color: #9fc4e4; }

.controls-bar { margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(72, 202, 255, 0.2); }
.keys-list { display: flex; flex-wrap: wrap; gap: 7px; font-size: 11px; color: #b8d0e8; }
.key-badge { background: rgba(25, 48, 80, 0.75); border: 1px solid rgba(100, 190, 255, 0.3); padding: 4px 8px; border-radius: 5px; }
.key-badge b { color: #5ce1ff; margin-left: 4px; }
.error-msg { color: #ff6a6a; margin-top: 8px; font-size: 12px; text-align: center; min-height: 16px; }

.pause-modal { width: min(520px, 92vw); text-align: center; }

/* ================= Roguelike 强化三选一 ================= */
.upgrade-modal {
  width: min(980px, 95vw); max-height: 92vh; overflow-y: auto; padding: 24px 28px;
  border-radius: 16px; border: 1px solid rgba(92, 225, 255, 0.45);
  background: linear-gradient(165deg, rgba(10, 22, 42, 0.94), rgba(5, 10, 22, 0.97));
}
.upgrade-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; border-bottom: 1px solid rgba(92, 225, 255, 0.22); padding-bottom: 12px; }
.upgrade-title h2 { margin: 0; font-size: 23px; letter-spacing: 2px; background: linear-gradient(90deg, #fff, #5ce1ff, #ffd166); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.upgrade-title p { margin: 4px 0 0; font-size: 12px; color: #9fc4e4; }
.upgrade-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
@media (max-width: 780px) { .upgrade-cards { grid-template-columns: 1fr; } }
.upgrade-card {
  display: flex; flex-direction: column; justify-content: space-between; padding: 16px; border-radius: 12px;
  background: linear-gradient(160deg, rgba(16, 32, 58, 0.85), rgba(8, 16, 30, 0.92));
  border: 1.5px solid rgba(92, 225, 255, 0.42); cursor: pointer; text-align: left; color: #e4f2ff; transition: all 0.16s;
}
.upgrade-card:hover { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(0, 170, 255, 0.28); }
.upgrade-card.rarity-rare { border-color: rgba(192, 132, 252, 0.72); }
.upgrade-card.rarity-epic { border-color: rgba(255, 209, 102, 0.88); }
.u-card-top { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 10px; }
.u-tag { padding: 3px 8px; border-radius: 4px; background: rgba(92, 225, 255, 0.2); color: #5ce1ff; font-weight: bold; }
.u-icon-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.u-icon { font-size: 24px; width: 40px; height: 40px; border-radius: 9px; display: flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, 0.07); }
.u-name { font-size: 15px; font-weight: 800; color: #fff; }
.u-cat { font-size: 11px; color: #8ab4d8; }
.u-desc { font-size: 12px; color: #d2e6f8; line-height: 1.5; margin: 8px 0 12px; min-height: 50px; }
.u-footer { display: flex; justify-content: space-between; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, 0.08); font-size: 11px; color: #7fd4ff; font-weight: bold; }
.upgrade-wait-banner { margin-top: 14px; text-align: center; padding: 10px; border-radius: 8px; background: rgba(77, 255, 154, 0.14); border: 1px solid rgba(77, 255, 154, 0.45); color: #4dff9a; font-weight: bold; font-size: 13px; }
.upgrade-owned-bar { margin-top: 14px; padding-top: 10px; border-top: 1px solid rgba(92, 225, 255, 0.18); display: flex; flex-wrap: wrap; gap: 6px; font-size: 11px; color: #8ab4d8; }
.owned-chip { background: rgba(20, 42, 72, 0.78); border: 1px solid rgba(92, 225, 255, 0.3); color: #d8eeff; padding: 3px 8px; border-radius: 5px; }

/* ================= 战绩表 & 结算 ================= */
.gameover-box { width: min(740px, 94vw); text-align: center; }
.gameover-box h2 { color: #ffd166; font-size: 32px; letter-spacing: 4px; margin: 0 0 8px; }
.score-table { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 13px; }
.score-table th, .score-table td { padding: 8px 10px; border-bottom: 1px solid rgba(92, 225, 255, 0.16); text-align: center; }
.score-table th { color: #5ce1ff; font-size: 11px; letter-spacing: 1px; text-transform: uppercase; }
.score-table tr.me-row { background: rgba(58, 209, 255, 0.14); font-weight: bold; }

/* ================= 战斗 HUD ================= */
#hud { position: absolute; inset: 0; z-index: 10; pointer-events: none; display: none; font-variant-numeric: tabular-nums; }
#cineVignette { position: absolute; inset: 0; z-index: 1; background: radial-gradient(circle, rgba(0,0,0,0) 58%, rgba(2, 8, 20, 0.55) 100%); }
#adsScopeOverlay { position: absolute; inset: 0; z-index: 5; opacity: 0; background: radial-gradient(circle, transparent 34%, rgba(4, 12, 24, 0.4) 35%, rgba(2, 6, 14, 0.96) 54%); transition: opacity 0.14s; display: flex; align-items: center; justify-content: center; }
.scope-hud-ring { width: min(68vh, 68vw); height: min(68vh, 68vw); border-radius: 50%; border: 2px solid rgba(232, 121, 249, 0.65); box-shadow: 0 0 30px rgba(217, 70, 239, 0.35), inset 0 0 40px rgba(58, 209, 255, 0.2); position: relative; }
.scope-cross-h { position: absolute; top: 50%; left: 6%; right: 6%; height: 1px; background: linear-gradient(90deg, transparent, rgba(232, 121, 249, 0.85) 20%, rgba(92, 225, 255, 0.95) 50%, rgba(232, 121, 249, 0.85) 80%, transparent); }
.scope-cross-v { position: absolute; left: 50%; top: 6%; bottom: 6%; width: 1px; background: linear-gradient(180deg, transparent, rgba(232, 121, 249, 0.85) 20%, rgba(92, 225, 255, 0.95) 50%, rgba(232, 121, 249, 0.85) 80%, transparent); }
.scope-ticks { position: absolute; top: 50%; left: 50%; width: 220px; height: 220px; transform: translate(-50%, -50%); background: repeating-linear-gradient(90deg, transparent 0, transparent 18px, rgba(92, 225, 255, 0.65) 19px, transparent 20px), repeating-linear-gradient(0deg, transparent 0, transparent 18px, rgba(92, 225, 255, 0.65) 19px, transparent 20px); clip-path: polygon(0 48%, 48% 48%, 48% 0, 52% 0, 52% 48%, 100% 48%, 100% 52%, 52% 52%, 52% 100%, 48% 100%, 48% 52%, 0 52%); }
.scope-telemetry { position: absolute; top: 54%; left: 54%; font-size: 11px; color: #f0abfc; letter-spacing: 1.5px; text-shadow: 0 0 8px rgba(217, 70, 239, 0.9); line-height: 1.5; }

#overdriveVignette { position: absolute; inset: 0; z-index: 2; opacity: 0; background: radial-gradient(circle, rgba(0,0,0,0) 58%, rgba(255, 190, 40, 0.26) 100%); transition: opacity 0.25s; }
#sprintVignette { position: absolute; inset: 0; z-index: 2; opacity: 0; background: radial-gradient(circle, rgba(0,0,0,0) 55%, rgba(58, 209, 255, 0.24) 100%); transition: opacity 0.2s; }
#lowHpVignette { position: absolute; inset: 0; z-index: 3; opacity: 0; background: radial-gradient(circle, rgba(0,0,0,0) 42%, rgba(190, 0, 20, 0.62) 100%); transition: opacity 0.3s; }
#damageFlash { position: absolute; inset: 0; z-index: 4; opacity: 0; background: radial-gradient(circle, rgba(255, 50, 50, 0.08) 35%, rgba(255, 20, 20, 0.48) 100%); transition: opacity 0.12s; }

#respawnOverlay { position: absolute; inset: 0; z-index: 15; display: flex; align-items: center; justify-content: center; background: rgba(18, 4, 10, 0.52); }
.respawn-box { padding: 20px 40px; border-radius: 12px; background: rgba(12, 16, 28, 0.9); border: 1px solid rgba(255, 82, 82, 0.55); text-align: center; }
.respawn-title { font-size: 24px; font-weight: 800; color: #ff5252; letter-spacing: 3px; }
.respawn-timer { font-size: 14px; color: #ffd166; margin-top: 8px; }

#scoreboardOverlay { position: absolute; inset: 0; z-index: 16; display: flex; align-items: center; justify-content: center; background: rgba(3, 8, 18, 0.62); }
.scoreboard-box { width: min(680px, 92vw); padding: 20px 26px; border-radius: 12px; background: rgba(8, 18, 36, 0.94); border: 1px solid rgba(92, 225, 255, 0.45); }
.sb-header { display: flex; justify-content: space-between; font-size: 16px; font-weight: 800; color: #5ce1ff; border-bottom: 1px solid rgba(92, 225, 255, 0.25); padding-bottom: 10px; }

#crosshair { position: absolute; top: 50%; left: 50%; width: 34px; height: 34px; margin: -17px 0 0 -17px; z-index: 6; transition: transform 0.08s ease-out; }
.ch-line { position: absolute; background: #7ef9ff; box-shadow: 0 0 6px #3ad1ff; }
.ch-top { width: 2px; height: 8px; left: 16px; top: 2px; }
.ch-bottom { width: 2px; height: 8px; left: 16px; bottom: 2px; }
.ch-left { height: 2px; width: 8px; top: 16px; left: 2px; }
.ch-right { height: 2px; width: 8px; top: 16px; right: 2px; }
.ch-dot { position: absolute; top: 50%; left: 50%; width: 4px; height: 4px; margin: -2px 0 0 -2px; border-radius: 50%; background: #fff; }
.ch-ring { position: absolute; top: 50%; left: 50%; width: 26px; height: 26px; transform: translate(-50%, -50%); border-radius: 50%; border: 1.5px dashed rgba(255, 180, 60, 0.88); opacity: 0; }
#crosshair.mode-shotgun .ch-ring { opacity: 1; }
#crosshair.mode-shotgun .ch-line { opacity: 0.35; }
#crosshair.mode-sniper .ch-line { background: #e28eff; box-shadow: 0 0 8px #d946ef; }
#crosshair.mode-plasma .ch-ring { opacity: 1; width: 32px; height: 32px; border-style: solid; border-color: rgba(74, 255, 154, 0.8); }

#threatRing { position: absolute; top: 50%; left: 50%; width: 190px; height: 190px; margin: -95px 0 0 -95px; border-radius: 50%; z-index: 5; }
.threat-arc { position: absolute; inset: 0; border-radius: 50%; border: 5px solid transparent; border-top-color: rgba(255, 45, 70, 0.92); opacity: 0; transition: opacity 0.1s; }
#hitmarker { position: absolute; top: 50%; left: 50%; width: 28px; height: 28px; margin: -14px 0 0 -14px; opacity: 0; transform: rotate(45deg); z-index: 6; }
#hitmarker::before, #hitmarker::after { content: ''; position: absolute; background: var(--hm-color, #ff4d4d); box-shadow: 0 0 8px var(--hm-color, #ff4d4d); }
#hitmarker::before { width: 100%; height: 2.5px; top: 50%; left: 0; transform: translateY(-50%); }
#hitmarker::after { width: 2.5px; height: 100%; left: 50%; top: 0; transform: translateX(-50%); }

.top-hud-center { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; z-index: 7; }
#pvpScoreBanner { display: flex; align-items: center; gap: 14px; background: rgba(8, 18, 36, 0.85); border: 1px solid rgba(92, 225, 255, 0.35); padding: 6px 18px; border-radius: 20px; font-weight: 800; font-size: 14px; }
.pvp-team.alpha { color: #38bdf8; }
.pvp-team.omega { color: #ff6b81; }
.pvp-timer { color: #ffd166; font-size: 16px; letter-spacing: 2px; }
#compassWrap { width: 320px; height: 24px; background: linear-gradient(90deg, transparent, rgba(8, 18, 34, 0.78) 20%, rgba(8, 18, 34, 0.78) 80%, transparent); border-top: 1px solid rgba(92, 225, 255, 0.35); display: flex; align-items: center; justify-content: center; font-size: 11px; letter-spacing: 3px; color: #9fc4e4; }
#compassText { color: #5ce1ff; font-weight: bold; }
#bossHpWrap { width: 420px; display: none; background: rgba(12, 8, 18, 0.8); border: 1px solid rgba(255, 140, 40, 0.55); border-radius: 6px; padding: 6px 12px; }
#bossHpHeader { display: flex; justify-content: space-between; font-size: 11px; color: #ffb84d; margin-bottom: 4px; font-weight: bold; }
#bossHpTrack { width: 100%; height: 10px; background: rgba(255, 255, 255, 0.08); border-radius: 4px; overflow: hidden; }
#bossHpFill { height: 100%; width: 100%; background: linear-gradient(90deg, #ff3838, #ff9f1a, #ffe66d); transition: width 0.15s; }

.top-left { position: absolute; top: 18px; left: 20px; z-index: 7; background: linear-gradient(135deg, rgba(8, 20, 38, 0.8), rgba(8, 20, 38, 0.35)); border-left: 3px solid #3ad1ff; padding: 10px 16px; border-radius: 0 8px 8px 0; }
#scoreBox { font-size: 22px; font-weight: 800; color: #7fffb0; }
#comboTag { font-size: 12px; color: #ffd166; margin-left: 8px; font-weight: bold; }
#waveBox { font-size: 12px; color: #a8c6e4; margin-top: 3px; }
#hudAugmentSummary { margin-top: 4px; font-size: 11px; color: #ffd166; }
.squad-panel { margin-top: 8px; display: flex; flex-direction: column; gap: 4px; min-width: 170px; }
.squad-row { font-size: 11px; color: #d8eeff; }
.squad-bar { width: 100%; height: 4px; background: rgba(255, 255, 255, 0.12); border-radius: 2px; margin-top: 2px; overflow: hidden; }
.squad-bar-fill { height: 100%; background: #4dff9a; }

#hudChatWrap { position: absolute; bottom: 155px; left: 20px; width: 290px; z-index: 12; pointer-events: none; }
#hudChatMessages { display: flex; flex-direction: column; gap: 3px; font-size: 12px; text-shadow: 0 1px 3px #000; }
.hud-chat-item { background: rgba(5, 12, 24, 0.55); padding: 3px 8px; border-radius: 4px; }
#hudChatInput { pointer-events: auto; width: 100%; margin-top: 6px; padding: 6px 10px; border-radius: 6px; background: rgba(5, 14, 28, 0.92); border: 1px solid #5ce1ff; color: #fff; font-size: 12px; }

.bottom-left { position: absolute; bottom: 20px; left: 20px; width: 240px; z-index: 7; background: rgba(8, 18, 34, 0.82); border: 1px solid rgba(92, 225, 255, 0.28); border-left: 4px solid #3ad1ff; border-radius: 8px; padding: 11px 15px; display: flex; flex-direction: column; gap: 7px; }
.vital-row { display: flex; flex-direction: column; gap: 3px; }
.barLabel { display: flex; justify-content: space-between; font-size: 11px; color: #a8c6e4; font-weight: bold; }
.barTrack { width: 100%; height: 8px; background: rgba(255, 255, 255, 0.08); border-radius: 4px; overflow: hidden; }
#shieldFill { height: 100%; width: 50%; background: linear-gradient(90deg, #0088ff, #5ce1ff); transition: width 0.15s; }
#healthFill { height: 100%; width: 100%; background: linear-gradient(90deg, #ff3838, #ff8a3d); transition: width 0.15s; }
#staminaFill { height: 100%; width: 100%; background: linear-gradient(90deg, #3ad1ff, #7fffd4); transition: width 0.12s; }

#bottomCenterHud { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; z-index: 7; }
#abilityBar { display: flex; gap: 10px; align-items: center; }
.ability-pill { display: flex; align-items: center; gap: 8px; background: rgba(8, 18, 34, 0.84); border: 1px solid rgba(92, 225, 255, 0.35); padding: 4px 12px; border-radius: 20px; font-size: 11px; color: #bfe2ff; position: relative; overflow: hidden; }
.ability-pill b { color: #051322; background: #5ce1ff; padding: 1px 6px; border-radius: 4px; font-size: 10px; }
.ability-pill .cd-fill { position: absolute; left: 0; bottom: 0; height: 2.5px; width: 100%; background: linear-gradient(90deg, #3ad1ff, #a8ff78); }
#overdriveBadge { display: none; background: linear-gradient(90deg, #ff9f1a, #ffe042); color: #1a0f00; font-weight: 900; font-size: 11px; padding: 4px 12px; border-radius: 20px; }
#weaponDock { display: flex; gap: 8px; }
.dock-slot { width: 104px; padding: 6px 9px; background: rgba(8, 16, 30, 0.75); border: 1px solid rgba(120, 180, 255, 0.22); border-radius: 7px; transition: all 0.15s; }
.dock-slot.active { background: rgba(22, 52, 92, 0.88); border-color: #5ce1ff; box-shadow: 0 0 14px rgba(58, 209, 255, 0.45); transform: translateY(-4px); }
.dock-slot .slot-key { font-size: 10px; color: #5ce1ff; font-weight: bold; }
.dock-slot .slot-name { font-size: 12px; color: #fff; font-weight: bold; margin: 2px 0; }
.dock-slot .slot-ammo { font-size: 10px; color: #9ab8d4; }

.bottom-right { position: absolute; bottom: 20px; right: 20px; text-align: right; z-index: 7; background: rgba(8, 18, 34, 0.82); border: 1px solid rgba(92, 225, 255, 0.28); border-right: 4px solid #3ad1ff; border-radius: 8px; padding: 11px 16px; min-width: 185px; }
#weaponName { font-size: 13px; color: #5ce1ff; font-weight: bold; }
#weaponSub { font-size: 10px; color: #88a8c8; margin-bottom: 2px; }
#ammoBox { font-size: 34px; font-weight: 800; color: #fff; line-height: 1.05; }
#ammoBox .max { font-size: 15px; color: #9fb3c8; font-weight: normal; }
#reloadBarWrap { width: 100%; height: 5px; margin-top: 6px; background: rgba(255, 255, 255, 0.1); border-radius: 3px; overflow: hidden; opacity: 0; }
#reloadBarFill { height: 100%; width: 0%; background: linear-gradient(90deg, #3ad1ff, #9d7aff); }

#killfeed { position: absolute; top: 20px; right: 168px; display: flex; flex-direction: column; gap: 5px; align-items: flex-end; z-index: 7; }
.kill-entry { font-size: 12px; color: #ffe08a; background: linear-gradient(90deg, transparent, rgba(8, 18, 34, 0.85)); border-right: 3px solid #5ce1ff; padding: 4px 10px; border-radius: 4px; animation: fadeOut 3.2s forwards; }
@keyframes fadeOut { 0% { opacity: 1; } 80% { opacity: 1; } 100% { opacity: 0; } }

#radarWrap { position: absolute; top: 16px; right: 18px; width: 136px; height: 136px; border-radius: 50%; background: radial-gradient(circle, rgba(10, 28, 48, 0.78), rgba(4, 10, 20, 0.9)); border: 1.5px solid rgba(92, 225, 255, 0.48); z-index: 7; }
#radarCanvas { width: 100%; height: 100%; border-radius: 50%; }
#radarLabel { position: absolute; top: 156px; right: 18px; width: 136px; text-align: center; font-size: 10px; color: #7fd4ff; z-index: 7; }

#dmgLayer { position: absolute; inset: 0; z-index: 8; overflow: hidden; }
.dmg-num { position: absolute; transform: translate(-50%, -50%); font-weight: 800; font-size: 15px; text-shadow: 0 0 6px #000; animation: dmgFloat 0.8s ease-out forwards; }
.dmg-num.crit { font-size: 21px; color: #ffe042 !important; }
@keyframes dmgFloat { 0% { opacity: 1; transform: translate(-50%, -50%) translateY(0); } 100% { opacity: 0; transform: translate(-50%, -50%) translateY(-48px); } }
#centerMsg { position: absolute; top: 30%; left: 50%; transform: translate(-50%, -50%); text-align: center; color: #7fd4ff; font-size: 28px; font-weight: 800; letter-spacing: 4px; opacity: 0; transition: opacity 0.35s; z-index: 8; }
