/* ============================================================
   DEAD RANGE — interface & atmosphere
   ============================================================ */
@font-face {
  font-family: 'Barlow Condensed';
  src: url('fonts/BarlowCondensed-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url('fonts/BarlowCondensed-600.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url('fonts/BarlowCondensed-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Chakra Petch';
  src: url('fonts/ChakraPetch-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Chakra Petch';
  src: url('fonts/ChakraPetch-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Chakra Petch';
  src: url('fonts/ChakraPetch-600.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Chakra Petch';
  src: url('fonts/ChakraPetch-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bone: #e6e4d8;
  --bone-dim: #a7a99e;
  --paper: #d8d5c6;
  --blood: #e12532;
  --blood-hot: #ff4650;
  --blood-deep: #7c0b14;
  --amber: #f4a340;
  --amber-hot: #ffc468;
  --cyan: #70d5cf;
  --ink: #050708;
  --panel: rgba(8, 12, 13, 0.78);
  --line: rgba(220, 224, 210, 0.16);
  --line-strong: rgba(220, 224, 210, 0.34);
  --display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --mono: 'Chakra Petch', 'Courier New', monospace;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  overflow: hidden;
  background: #030506;
  color: var(--bone);
  font-family: var(--mono);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  user-select: none;
}
body.is-locked { cursor: none; }
button { font: inherit; color: inherit; }
kbd {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  min-height: 20px;
  padding: 4px 6px 3px;
  border: 1px solid rgba(230, 228, 216, 0.3);
  border-bottom-color: rgba(230, 228, 216, 0.15);
  background: rgba(235, 236, 222, 0.06);
  color: var(--bone);
  border-radius: 2px;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.55);
}

#game {
  display: block;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  outline: none;
  z-index: 0;
  background: #050708;
}

/* ------------------------------ post fx ------------------------------ */
.post-fx {
  position: fixed;
  inset: 0;
  z-index: 5;
  overflow: hidden;
  pointer-events: none;
}
.fx-vignette {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 48%, transparent 36%, rgba(0, 0, 0, 0.2) 67%, rgba(0, 0, 0, 0.78) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.42), transparent 18%, transparent 79%, rgba(0, 0, 0, 0.55));
}
.fx-scan {
  position: absolute;
  inset: -20%;
  opacity: 0.13;
  background: repeating-linear-gradient(180deg, transparent 0px, transparent 3px, rgba(2, 7, 8, 0.55) 4px);
  animation: scan-drift 9s linear infinite;
}
.fx-noise {
  position: absolute;
  inset: -30%;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.92' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.9'/%3E%3C/svg%3E");
  animation: noise-jump 0.45s steps(2) infinite;
}
.blood-layer {
  position: absolute;
  inset: 0;
  opacity: 0;
  background-size: cover;
  background-position: center;
  filter: saturate(0.9) contrast(1.08) brightness(0.95);
  transform: scale(1.015);
  transition: opacity 0.6s ease;
}
.blood-layer.flash-a { animation: blood-pulse-a 1.7s cubic-bezier(0.15, 0.7, 0.25, 1) forwards; }
.blood-layer.flash-b { animation: blood-pulse-b 2.1s cubic-bezier(0.15, 0.7, 0.25, 1) forwards; }
.impact-flash {
  position: absolute;
  inset: 0;
  opacity: 0;
  background: radial-gradient(circle at 50% 52%, rgba(255, 234, 186, 0.38), rgba(255, 163, 64, 0.08) 37%, transparent 66%);
}
.impact-flash.flash { animation: muzzle-flash 100ms ease-out forwards; }

@keyframes scan-drift { from { transform: translateY(0); } to { transform: translateY(8px); } }
@keyframes noise-jump {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-2%, 1.5%); }
  50% { transform: translate(1.5%, -1%); }
  75% { transform: translate(-1%, -2%); }
  100% { transform: translate(2%, 1%); }
}
@keyframes blood-pulse-a {
  0% { opacity: 0; transform: scale(1.04); }
  9% { opacity: 0.86; }
  22% { opacity: 0.62; }
  100% { opacity: 0; transform: scale(1); }
}
@keyframes blood-pulse-b {
  0% { opacity: 0; transform: scale(1.03); }
  8% { opacity: 0.72; }
  30% { opacity: 0.48; }
  100% { opacity: 0; transform: scale(1); }
}
@keyframes muzzle-flash {
  0% { opacity: 0; }
  12% { opacity: 1; }
  100% { opacity: 0; }
}
.proximity-vignette {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.3s ease;
  background:
    radial-gradient(ellipse at 50% 52%, transparent 36%, rgba(116, 0, 7, 0.2) 68%, rgba(153, 0, 10, 0.65) 100%),
    linear-gradient(180deg, transparent 52%, rgba(120, 0, 6, 0.28));
  box-shadow: inset 0 0 140px rgba(150, 0, 9, 0.42);
}
.proximity-vignette.on { opacity: 1; animation: proximity-pulse 1.1s ease-in-out infinite; }
@keyframes proximity-pulse { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }
.danger-line-glow {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 31%;
  opacity: 0;
  transition: opacity 0.4s ease;
  background: linear-gradient(0deg, rgba(176, 6, 16, 0.24), transparent 82%);
}
.danger-line-glow.on { opacity: 1; }

/* ------------------------------ HUD ------------------------------ */
.hud {
  position: fixed;
  inset: 0;
  z-index: 10;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.55s ease, visibility 0.55s;
}
.hud.is-live { opacity: 1; visibility: visible; }
.hud-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) auto minmax(280px, 1fr);
  align-items: start;
  gap: 24px;
  padding: 20px clamp(20px, 3.3vw, 54px) 17px;
  background: linear-gradient(180deg, rgba(2, 5, 6, 0.88), rgba(2, 5, 6, 0.3) 65%, transparent);
}
.hud-bar::after {
  content: '';
  position: absolute;
  left: clamp(20px, 3.3vw, 54px);
  right: clamp(20px, 3.3vw, 54px);
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(221, 222, 208, 0.22) 2%, rgba(221, 222, 208, 0.22) 72%, rgba(225, 37, 50, 0.7) 98%, transparent);
}
.hud-brand { display: flex; align-items: center; gap: 12px; }
.brand-glyph {
  width: 32px;
  height: 32px;
  color: var(--blood-hot);
  filter: drop-shadow(0 0 8px rgba(225, 37, 50, 0.28));
  flex: 0 0 auto;
}
.brand-glyph svg { width: 100%; height: 100%; }
.brand-type { display: flex; flex-direction: column; line-height: 1; }
.brand-type strong {
  font-family: var(--display);
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0.16em;
}
.brand-type span {
  margin-top: 5px;
  color: var(--bone-dim);
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.22em;
}
.connection {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: 8px;
  padding: 4px 8px;
  border: 1px solid rgba(112, 213, 207, 0.22);
  color: rgba(130, 208, 203, 0.8);
  font-size: 8px;
  letter-spacing: 0.13em;
  white-space: nowrap;
}
.connection i { width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 6px var(--cyan); animation: status-pulse 2.1s infinite; }
@keyframes status-pulse { 0%, 100% { opacity: 1; } 45% { opacity: 0.3; } }

.hud-threat { text-align: center; padding-top: 1px; }
.micro-label { display: block; color: var(--bone-dim); font-size: 8px; font-weight: 600; letter-spacing: 0.24em; line-height: 1.2; }
.threat-row { display: flex; align-items: center; justify-content: center; gap: 9px; margin-top: 6px; }
.threat-row b { font-family: var(--display); color: var(--blood-hot); font-size: 16px; font-weight: 600; letter-spacing: 0.19em; }
.threat-dot { width: 6px; height: 6px; background: var(--blood); box-shadow: 0 0 10px var(--blood); animation: threat-blink 1.2s steps(2) infinite; }
@keyframes threat-blink { 50% { opacity: 0.2; } }

.hud-score { justify-self: end; text-align: right; display: flex; gap: 30px; align-items: flex-start; }
.score-main .micro-label { margin-bottom: 2px; }
.score-main strong {
  font-family: var(--display);
  display: block;
  font-size: 32px;
  line-height: 0.95;
  font-weight: 600;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 20px rgba(225, 224, 207, 0.16);
}
.score-meta { display: flex; gap: 22px; padding-top: 2px; }
.score-meta div { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.score-meta span { color: var(--bone-dim); font-size: 7px; letter-spacing: 0.16em; }
.score-meta b { font-family: var(--display); font-size: 19px; line-height: 1; font-weight: 600; letter-spacing: 0.08em; font-variant-numeric: tabular-nums; }

.hud-rail {
  position: absolute;
  top: 38%;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: rgba(220, 222, 210, 0.32);
  font-size: 7px;
  letter-spacing: 0.23em;
  writing-mode: vertical-rl;
}
.rail-left { left: 16px; transform: rotate(180deg); align-items: flex-start; }
.hud-rail i { width: 1px; height: 18px; background: rgba(220, 222, 210, 0.25); display: block; }
.hud-rail i:nth-of-type(2) { height: 34px; background: rgba(225, 37, 50, 0.55); }

.mission-block {
  position: absolute;
  left: clamp(34px, 4.3vw, 70px);
  bottom: clamp(76px, 10vh, 112px);
  width: 225px;
  padding-left: 14px;
  border-left: 2px solid var(--blood);
}
.mission-block p {
  margin: 5px 0 9px;
  font-family: var(--display);
  font-size: 23px;
  font-weight: 600;
  line-height: 0.92;
  letter-spacing: 0.06em;
}
.mission-line { display: flex; gap: 10px; align-items: center; font-size: 8px; letter-spacing: 0.12em; color: var(--bone-dim); }
.mission-line b { color: var(--amber); font-weight: 500; }

.level-meter {
  width: 246px;
  margin: 9px auto 0;
  text-align: left;
}
.level-meter-head {
  display: flex;
  align-items: baseline;
  gap: 7px;
  font-size: 8px;
  letter-spacing: 0.12em;
  color: var(--bone-dim);
}
.level-meter-head > span { font-size: 7px; letter-spacing: 0.2em; }
.level-meter-head > b {
  font-family: var(--display);
  color: var(--amber-hot);
  font-size: 23px;
  line-height: 0.8;
  font-weight: 600;
  letter-spacing: 0.06em;
}
.level-meter-head > em {
  flex: 1;
  padding-left: 3px;
  color: var(--bone);
  font-style: normal;
  font-size: 8px;
  letter-spacing: 0.15em;
  white-space: nowrap;
}
.level-meter-head > small {
  color: var(--amber);
  font-size: 8px;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
}
.level-meter-track {
  position: relative;
  height: 3px;
  margin-top: 7px;
  background: rgba(220, 222, 208, 0.14);
  overflow: hidden;
}
.level-meter-track::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent 0 19px, rgba(5, 8, 8, 0.9) 19px 21px);
  pointer-events: none;
}
.level-meter-track i {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--blood), var(--amber));
  box-shadow: 0 0 10px rgba(225, 37, 50, 0.45);
  transition: width 0.3s ease;
}
.level-meter-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 5px;
  color: rgba(218, 218, 204, 0.38);
  font-size: 6.5px;
  letter-spacing: 0.14em;
  white-space: nowrap;
}
.level-meter-foot b { color: rgba(218, 218, 204, 0.55); font-weight: 500; }
.hud-threat.danger .threat-row b { color: var(--amber-hot); }
.hud-threat.danger .threat-dot { background: var(--amber-hot); box-shadow: 0 0 12px var(--amber-hot); animation-duration: 0.35s; }
.hud-threat.danger .level-meter-track i { background: var(--blood-hot); }

.mission-level {
  display: flex;
  justify-content: space-between;
  width: 175px;
  margin: 0 0 9px;
  padding: 5px 7px 5px 0;
  border-top: 1px solid rgba(221, 220, 205, 0.12);
  border-bottom: 1px solid rgba(221, 220, 205, 0.12);
  color: rgba(218, 218, 204, 0.52);
  font-size: 8px;
  letter-spacing: 0.13em;
}
.mission-level b { color: var(--amber); font-weight: 500; }

.combo-block {
  position: absolute;
  right: clamp(28px, 4vw, 64px);
  top: 37%;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  opacity: 0;
  transform: translateX(16px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.combo-block.show { opacity: 1; transform: translateX(0); }
.combo-x { font-family: var(--display); font-size: 57px; line-height: 0.8; font-weight: 700; color: var(--blood-hot); text-shadow: 0 0 28px rgba(225, 37, 50, 0.38); }
.combo-x small { font-size: 24px; }
.combo-x b { font-weight: 700; }
.combo-label { margin-top: 6px; font-size: 8px; letter-spacing: 0.22em; color: var(--bone); }
.combo-timer { width: 88px; height: 2px; margin-top: 8px; background: rgba(225, 37, 50, 0.25); position: relative; overflow: hidden; }
.combo-timer::after { content: ''; position: absolute; inset: 0; background: var(--blood-hot); transform-origin: right center; transform: scaleX(var(--combo, 1)); transition: transform 0.08s linear; }

.hit-feed {
  position: absolute;
  right: clamp(28px, 4vw, 64px);
  top: calc(37% + 100px);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  width: 260px;
}
.feed-item {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 9px;
  line-height: 1.2;
  letter-spacing: 0.12em;
  color: var(--bone);
  text-shadow: 0 1px 8px #000;
  opacity: 0;
  transform: translateX(12px);
  animation: feed-in 2.6s ease forwards;
}
.feed-item::before { content: ''; width: 16px; height: 1px; background: var(--blood); }
.feed-item b { color: var(--amber); font-weight: 500; }
.feed-item.head strong { color: var(--amber-hot); }
@keyframes feed-in {
  0% { opacity: 0; transform: translateX(12px); }
  8%, 74% { opacity: 0.9; transform: translateX(0); }
  100% { opacity: 0; transform: translateX(4px); }
}

.crosshair {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  transform: translate(-50%, -50%);
  --ch-color: rgba(235, 235, 220, 0.85);
  color: var(--ch-color);
  transition: color 0.12s ease;
  filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.8));
}
.crosshair.on-target { --ch-color: var(--blood-hot); }
.crosshair.on-head { --ch-color: var(--amber-hot); }
.crosshair.fire { animation: ch-fire 150ms ease-out; }
@keyframes ch-fire {
  0% { transform: translate(-50%, -50%) scale(1); }
  35% { transform: translate(-50%, -50%) scale(1.32); }
  100% { transform: translate(-50%, -50%) scale(1); }
}
.ch {
  position: absolute;
  background: currentColor;
  transition: transform 120ms ease;
}
.ch-t, .ch-b { width: 1px; height: 9px; left: 50%; margin-left: -0.5px; }
.ch-l, .ch-r { width: 9px; height: 1px; top: 50%; margin-top: -0.5px; }
.ch-t { top: 3px; }
.ch-b { bottom: 3px; }
.ch-l { left: 3px; }
.ch-r { right: 3px; }
.crosshair.fire .ch-t { transform: translateY(-4px); }
.crosshair.fire .ch-b { transform: translateY(4px); }
.crosshair.fire .ch-l { transform: translateX(-4px); }
.crosshair.fire .ch-r { transform: translateX(4px); }
.ch-dot { position: absolute; left: 50%; top: 50%; width: 3px; height: 3px; margin: -1.5px 0 0 -1.5px; background: currentColor; border-radius: 50%; box-shadow: 0 0 5px currentColor; }
.ch-ring { position: absolute; inset: 18px; border: 1px solid currentColor; border-radius: 50%; opacity: 0.15; transform: scale(0.8); transition: opacity 0.15s ease, transform 0.15s ease; }
.crosshair.on-target .ch-ring { opacity: 0.5; transform: scale(1); }

.hitmarker {
  position: absolute;
  left: 50%; top: 50%;
  width: 34px; height: 34px;
  transform: translate(-50%, -50%) rotate(45deg);
  opacity: 0;
}
.hitmarker i { position: absolute; background: var(--bone); box-shadow: 0 0 4px rgba(0,0,0,0.7); }
.hitmarker i:nth-child(1), .hitmarker i:nth-child(2) { width: 8px; height: 1px; top: 50%; }
.hitmarker i:nth-child(3), .hitmarker i:nth-child(4) { width: 1px; height: 8px; left: 50%; }
.hitmarker i:nth-child(1) { left: 0; }
.hitmarker i:nth-child(2) { right: 0; }
.hitmarker i:nth-child(3) { top: 0; }
.hitmarker i:nth-child(4) { bottom: 0; }
.hitmarker.show { animation: hitmark 240ms ease-out; }
.hitmarker.head i { background: var(--amber-hot); }
.hitmarker.kill i { background: var(--blood-hot); width: 10px; height: 2px; }
.hitmarker.kill i:nth-child(3), .hitmarker.kill i:nth-child(4) { width: 2px; height: 10px; }
@keyframes hitmarkerFire { 0% { opacity: 1; transform: scale(0.7); } 100% { opacity: 0; transform: scale(1.3); } }
@keyframes hitmark {
  0% { opacity: 1; transform: translate(-50%, -50%) rotate(45deg) scale(0.65); }
  35% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -50%) rotate(45deg) scale(1.18); }
}

.reload-badge {
  position: absolute;
  left: 50%;
  top: calc(50% + 54px);
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 7px 16px 8px;
  background: rgba(4, 7, 8, 0.7);
  border-top: 1px solid rgba(225, 37, 50, 0.7);
  opacity: 0;
  transition: opacity 0.2s ease;
}
.reload-badge.show { opacity: 1; }
.reload-badge span { font-size: 8px; letter-spacing: 0.22em; color: var(--blood-hot); }
.reload-badge b { font-family: var(--display); font-size: 17px; font-weight: 600; letter-spacing: 0.1em; color: var(--bone); }
.reload-badge.reloading span { color: var(--amber); }
.reload-badge.reloading b { color: var(--bone-dim); }

.ammo-block {
  position: absolute;
  right: clamp(28px, 4vw, 64px);
  bottom: clamp(66px, 9vh, 102px);
  display: grid;
  grid-template-columns: auto auto;
  grid-template-rows: auto auto auto;
  column-gap: 28px;
  align-items: end;
  padding-left: 17px;
  border-left: 2px solid var(--blood);
}
.weapon-id { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.weapon-id strong { font-family: var(--display); font-size: 25px; font-weight: 600; letter-spacing: 0.08em; line-height: 0.9; }
.weapon-id em { color: var(--amber); font-style: normal; }
.ammo-count { display: flex; align-items: baseline; line-height: 0.8; }
.ammo-count b { font-family: var(--display); font-size: 62px; font-weight: 500; letter-spacing: 0.02em; font-variant-numeric: tabular-nums; }
.ammo-count .ammo-slash { margin: 0 5px 0 3px; color: var(--bone-dim); font-size: 20px; }
.ammo-count .ammo-reserve { color: var(--amber); font-family: var(--display); font-size: 25px; }
.ammo-pips { display: grid; grid-template-columns: repeat(6, 7px); gap: 5px; padding-bottom: 10px; align-self: end; }
.ammo-pips i { height: 17px; width: 4px; background: var(--bone); display: block; transform-origin: bottom; box-shadow: 0 0 5px rgba(232, 232, 218, 0.15); transition: background 0.12s, transform 0.15s, opacity 0.15s; }
.ammo-pips i.spent { background: rgba(225, 37, 50, 0.28); transform: scaleY(0.45); box-shadow: none; }
.ammo-state { grid-column: 1 / -1; text-align: right; margin-top: 7px; font-size: 8px; letter-spacing: 0.22em; color: var(--cyan); }
.ammo-state.low { color: var(--blood-hot); }
.ammo-state.reload { color: var(--amber); }

.controls-strip {
  position: absolute;
  left: 50%;
  bottom: 23px;
  transform: translateX(-50%);
  display: flex;
  gap: clamp(12px, 2vw, 26px);
  align-items: center;
  color: rgba(215, 217, 204, 0.55);
  font-size: 8px;
  letter-spacing: 0.13em;
  white-space: nowrap;
}
.controls-strip span { display: flex; align-items: center; gap: 6px; }
.controls-strip kbd { min-width: 19px; min-height: 17px; padding: 3px 4px 2px; font-size: 8px; color: rgba(231, 231, 216, 0.8); }

.hud-footer {
  position: absolute;
  left: clamp(20px, 3.3vw, 54px);
  right: clamp(20px, 3.3vw, 54px);
  bottom: 8px;
  display: flex;
  justify-content: space-between;
  color: rgba(215, 217, 204, 0.28);
  font-size: 7px;
  letter-spacing: 0.16em;
}

/* ------------------------------ overlays / menu ------------------------------ */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 30;
  transition: opacity 0.5s ease, visibility 0.5s;
}
.overlay.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.start-screen {
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(3, 6, 7, 0.95) 0%, rgba(3, 6, 7, 0.88) 33%, rgba(3, 6, 7, 0.46) 65%, rgba(3, 6, 7, 0.73) 100%),
    radial-gradient(ellipse at 65% 40%, rgba(121, 32, 16, 0.16), transparent 48%),
    linear-gradient(180deg, rgba(2, 5, 6, 0.68), transparent 28%, transparent 78%, rgba(2, 5, 6, 0.86));
  backdrop-filter: blur(1.5px);
  display: flex;
  flex-direction: column;
}
.start-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(115deg, transparent 0 69%, rgba(225, 37, 50, 0.06) 69.1% 69.4%, transparent 69.5%),
    linear-gradient(115deg, transparent 0 72%, rgba(225, 37, 50, 0.04) 72.1% 72.3%, transparent 72.4%);
}
.start-screen::after {
  content: '09';
  position: absolute;
  right: -2vw;
  bottom: -9vh;
  font-family: var(--display);
  font-size: 54vw;
  line-height: 0.7;
  font-weight: 700;
  color: rgba(228, 225, 209, 0.022);
  pointer-events: none;
  letter-spacing: -0.05em;
}
.menu-noise {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.22;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 220 220' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.17'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}
.hazard-edge {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 8px;
  opacity: 0.55;
  background: repeating-linear-gradient(-45deg, rgba(225, 37, 50, 0.8) 0 9px, transparent 9px 19px);
  filter: blur(0.2px);
}
.hazard-edge.left { left: 0; }
.hazard-edge.right { right: 0; }

.menu-topline {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px clamp(34px, 5.2vw, 84px) 0;
  font-size: 8px;
  letter-spacing: 0.19em;
  color: rgba(218, 219, 204, 0.55);
}
.menu-topline i { color: var(--blood); font-style: normal; padding: 0 5px; }
.breach-tag { display: flex; align-items: center; gap: 8px; color: var(--blood-hot); font-weight: 600; letter-spacing: 0.18em; }
.breach-tag i { width: 5px; height: 5px; border-radius: 50%; background: var(--blood); box-shadow: 0 0 9px var(--blood); animation: threat-blink 1.15s steps(2) infinite; padding: 0; }

.menu-main {
  position: relative;
  z-index: 2;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(310px, 388px);
  gap: clamp(32px, 5vw, 100px);
  align-items: center;
  padding: 14px clamp(34px, 7.2vw, 124px) 42px;
  min-height: 0;
}
.menu-copy { align-self: center; max-width: 880px; }
.eyebrow {
  display: flex;
  gap: 17px;
  align-items: center;
  margin: 0 0 17px;
  color: var(--amber);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.23em;
}
.eyebrow span + span { color: rgba(219, 219, 204, 0.42); letter-spacing: 0.16em; }
.eyebrow span:first-child::before { content: ''; display: inline-block; width: 23px; height: 1px; margin-right: 10px; vertical-align: middle; background: var(--blood); }
.mega-title {
  position: relative;
  display: flex;
  flex-direction: column;
  margin: 0;
  font-family: var(--display);
  font-size: clamp(112px, 14.9vw, 238px);
  line-height: 0.67;
  font-weight: 700;
  letter-spacing: -0.025em;
  text-transform: uppercase;
  filter: drop-shadow(0 14px 32px rgba(0, 0, 0, 0.55));
}
.title-dead {
  position: relative;
  color: transparent;
  -webkit-text-stroke: 1.4px rgba(230, 228, 214, 0.76);
  text-shadow: 0 0 50px rgba(230, 228, 214, 0.05);
}
.title-dead::after {
  content: 'DEAD';
  position: absolute;
  left: 3px;
  top: 2px;
  color: rgba(225, 37, 50, 0.19);
  -webkit-text-stroke: 0;
  clip-path: polygon(0 41%, 100% 41%, 100% 46%, 0 46%);
  pointer-events: none;
}
.title-range { color: var(--blood); text-shadow: 0 0 70px rgba(225, 37, 50, 0.17); position: relative; }
.title-range::before {
  content: 'RANGE';
  position: absolute;
  left: 0;
  top: 0;
  color: rgba(230, 228, 214, 0.11);
  clip-path: polygon(0 20%, 100% 20%, 100% 24%, 0 24%);
  transform: translateX(-4px);
}
.menu-lede {
  max-width: 445px;
  margin: 24px 0 30px;
  color: rgba(218, 217, 201, 0.68);
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.75;
  letter-spacing: 0.035em;
}
.menu-lede strong { color: var(--bone); font-weight: 500; }
.start-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 19px;
  width: min(420px, 100%);
  padding: 16px 19px 16px 16px;
  border: 1px solid rgba(230, 228, 214, 0.4);
  background: rgba(7, 10, 10, 0.38);
  color: var(--bone);
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 13px), calc(100% - 13px) 100%, 0 100%);
  transition: color 0.25s ease, border-color 0.25s ease;
}
.start-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--blood);
  transform: translateX(-102%);
  transition: transform 0.38s cubic-bezier(0.2, 0.75, 0.25, 1);
  z-index: -1;
}
.start-btn:hover::before, .start-btn:focus-visible::before { transform: translateX(0); }
.start-btn:hover, .start-btn:focus-visible { color: #0a0505; border-color: var(--blood); outline: none; }
.start-btn:active { transform: translateY(1px); }
.start-btn:disabled { opacity: 0.4; cursor: wait; }
.start-btn:disabled::before { transform: translateX(-102%); }
.btn-index { align-self: stretch; display: flex; align-items: center; padding-right: 16px; border-right: 1px solid currentColor; font-size: 9px; letter-spacing: 0.1em; opacity: 0.65; }
.btn-copy { flex: 1; display: flex; flex-direction: column; gap: 5px; z-index: 1; }
.btn-copy b { font-family: var(--display); font-size: 25px; font-weight: 600; letter-spacing: 0.11em; line-height: 0.9; }
.btn-copy small { font-size: 7px; letter-spacing: 0.2em; opacity: 0.62; }
.btn-arrow { font-family: var(--display); font-size: 30px; line-height: 0.7; transition: transform 0.25s; }
.start-btn:hover .btn-arrow { transform: translateX(6px); }
.system-status { display: flex; align-items: center; gap: 7px; margin-top: 12px; font-size: 8px; letter-spacing: 0.16em; color: rgba(218, 218, 202, 0.35); }
.system-status i { width: 4px; height: 4px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 7px var(--amber); }
.system-status.ready { color: rgba(112, 213, 207, 0.75); }
.system-status.ready i { background: var(--cyan); box-shadow: 0 0 7px var(--cyan); }

.briefing {
  position: relative;
  padding: 22px 22px 20px;
  border: 1px solid rgba(221, 220, 205, 0.16);
  background: linear-gradient(160deg, rgba(14, 19, 19, 0.72), rgba(7, 10, 10, 0.34));
  backdrop-filter: blur(5px);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%);
}
.briefing::before { content: ''; position: absolute; left: 0; top: 0; width: 58px; height: 2px; background: var(--blood); }
.briefing::after { content: ''; position: absolute; right: 20px; top: 0; width: 1px; height: 23px; background: rgba(225, 37, 50, 0.8); }
.briefing-head { display: flex; justify-content: space-between; align-items: center; padding-bottom: 13px; border-bottom: 1px solid var(--line); }
.briefing-head b { font-family: var(--display); color: var(--amber); font-size: 18px; font-weight: 500; letter-spacing: 0.15em; }
.briefing h2 { margin: 19px 0 11px; font-family: var(--display); font-size: 36px; line-height: 0.78; font-weight: 600; letter-spacing: 0.055em; color: var(--bone); }
.briefing > p { margin: 0 0 20px; color: rgba(218, 218, 204, 0.55); font-size: 10px; line-height: 1.7; }
.brief-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.brief-list li { display: flex; gap: 13px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.brief-list li > span { font-family: var(--display); color: var(--blood); font-size: 18px; line-height: 1; min-width: 23px; }
.brief-list li div { display: flex; flex-direction: column; gap: 3px; }
.brief-list b { font-family: var(--mono); color: var(--bone); font-size: 9px; font-weight: 600; letter-spacing: 0.12em; }
.brief-list small { color: rgba(218, 218, 204, 0.45); font-size: 9px; letter-spacing: 0.02em; }
.brief-controls { padding-top: 17px; }
.brief-controls dl { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 18px; margin: 11px 0 0; }
.brief-controls dl div { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.brief-controls dt { color: rgba(218, 218, 204, 0.54); font-size: 8px; letter-spacing: 0.12em; }
.brief-controls dd { margin: 0; }
.brief-controls kbd { min-width: 23px; min-height: 18px; font-size: 8px; }
.headphone-hint { display: flex; align-items: center; gap: 7px; margin: 20px 0 0 !important; padding-top: 13px; border-top: 1px solid var(--line); font-size: 7px !important; letter-spacing: 0.16em; color: rgba(112, 213, 207, 0.58) !important; }
.headphone-hint i { width: 5px; height: 5px; border: 1px solid var(--cyan); border-radius: 50%; display: block; }

.menu-footer {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 0 clamp(34px, 5.2vw, 84px) 17px;
  color: rgba(218, 218, 204, 0.26);
  font-size: 7px;
  letter-spacing: 0.16em;
}
.menu-footer i { font-style: normal; color: var(--blood); }

/* ------------------------------ pause ------------------------------ */
.pause-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(2, 5, 6, 0.74);
  backdrop-filter: blur(8px);
}
.pause-screen[hidden] { display: none; }
.pause-card {
  width: min(420px, calc(100vw - 44px));
  padding: 25px 27px 24px;
  border: 1px solid rgba(221, 220, 205, 0.2);
  background: linear-gradient(160deg, rgba(12, 17, 17, 0.94), rgba(5, 8, 8, 0.94));
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 22px), calc(100% - 22px) 100%, 0 100%);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  animation: pause-in 0.3s ease-out;
}
@keyframes pause-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.pause-topline { display: flex; justify-content: space-between; padding-bottom: 13px; border-bottom: 1px solid var(--line); color: var(--blood-hot); font-size: 8px; letter-spacing: 0.2em; }
.pause-topline span:last-child { color: var(--bone-dim); }
.pause-card h2 { margin: 22px 0 12px; font-family: var(--display); font-size: 84px; line-height: 0.67; font-weight: 700; letter-spacing: -0.01em; }
.pause-card h2 em { color: var(--blood); font-style: normal; }
.pause-card > p { margin: 0 0 23px; max-width: 300px; color: rgba(218, 218, 204, 0.52); font-size: 10px; line-height: 1.7; }
.start-btn.compact { width: 100%; padding: 13px; }
.start-btn.compact .btn-copy b { font-size: 21px; }
.text-btn { margin-top: 9px; width: 100%; padding: 11px; border: 1px solid var(--line); background: transparent; color: rgba(218, 218, 204, 0.5); font-size: 8px; letter-spacing: 0.18em; cursor: pointer; transition: color 0.2s, border-color 0.2s; }
.text-btn:hover { color: var(--bone); border-color: var(--line-strong); }
.exit-site-btn { display: flex; align-items: center; justify-content: center; gap: 7px; color: var(--amber); text-decoration: none; }
.exit-site-btn:hover { color: var(--bone); border-color: var(--amber); background: rgba(244, 163, 64, 0.06); }
.pause-keys { display: flex; justify-content: space-between; margin-top: 22px; padding-top: 14px; border-top: 1px solid var(--line); color: rgba(218, 218, 204, 0.38); font-size: 7px; letter-spacing: 0.12em; }
.pause-keys span { display: flex; align-items: center; gap: 7px; }
.pause-keys b { color: var(--amber); font-weight: 500; }
.pause-keys kbd { min-width: 18px; min-height: 16px; padding: 2px 4px; font-size: 7px; }

/* ------------------------------ level banner ------------------------------ */
.level-banner {
  position: fixed;
  left: 50%;
  top: 29%;
  z-index: 26;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(680px, calc(100vw - 44px));
  padding: 20px 26px 18px;
  transform: translate(-50%, -50%) scale(0.96);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  background:
    linear-gradient(90deg, transparent, rgba(3, 7, 8, 0.9) 19%, rgba(3, 7, 8, 0.9) 81%, transparent),
    radial-gradient(ellipse at center, rgba(138, 18, 13, 0.18), transparent 66%);
  border-top: 1px solid rgba(225, 37, 50, 0.48);
  border-bottom: 1px solid rgba(225, 37, 50, 0.48);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
}
.level-banner.show {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
  animation: level-in 0.45s cubic-bezier(0.15, 0.85, 0.2, 1);
}
@keyframes level-in {
  0% { clip-path: inset(0 50% 0 50%); }
  100% { clip-path: inset(0 0 0 0); }
}
.level-banner-kicker { color: var(--amber); font-size: 8px; font-weight: 600; letter-spacing: 0.31em; }
.level-banner-main { display: flex; align-items: baseline; gap: 15px; margin: 3px 0 4px; }
.level-banner-main span { color: rgba(230, 228, 214, 0.45); font-size: 9px; letter-spacing: 0.25em; }
.level-banner-main b {
  font-family: var(--display);
  color: var(--bone);
  font-size: 92px;
  line-height: 0.74;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-shadow: 0 0 46px rgba(225, 37, 50, 0.22);
}
.level-banner p { margin: 0; color: var(--blood-hot); font-size: 9px; letter-spacing: 0.2em; }

/* ------------------------------ game over ------------------------------ */
.gameover-screen {
  z-index: 40;
  display: flex;
  align-items: center;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 65% 42%, rgba(115, 4, 10, 0.3), transparent 51%),
    linear-gradient(90deg, rgba(2, 4, 4, 0.98) 0%, rgba(2, 4, 4, 0.91) 45%, rgba(2, 4, 4, 0.5) 100%);
  backdrop-filter: blur(3px);
}
.gameover-screen[hidden] { display: none; }
.overrun-art {
  position: absolute;
  right: 0;
  bottom: -7vh;
  width: min(64vw, 910px);
  height: 108%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
  opacity: 0.6;
  filter: grayscale(0.65) contrast(1.18) brightness(0.7) drop-shadow(-22px 0 44px rgba(0, 0, 0, 0.8));
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 26%, #000 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 26%, #000 100%);
}
.overrun-art img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: bottom right;
  animation: overrun-breathe 6s ease-in-out infinite;
}
@keyframes overrun-breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.018); } }
.overrun-wash {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(180deg, transparent 0 3px, rgba(0, 0, 0, 0.33) 4px),
    radial-gradient(ellipse at 50% 50%, transparent 36%, rgba(0, 0, 0, 0.75) 100%);
  opacity: 0.5;
}
.overrun-panel {
  position: relative;
  z-index: 2;
  width: min(520px, calc(100vw - 44px));
  margin: 0 0 0 clamp(22px, 7vw, 110px);
  max-height: calc(100vh - 38px);
  overflow-y: auto;
  padding: 25px 29px 25px;
  border: 1px solid rgba(221, 220, 205, 0.18);
  background: linear-gradient(160deg, rgba(9, 12, 12, 0.95), rgba(5, 7, 7, 0.94));
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 22px), calc(100% - 22px) 100%, 0 100%);
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.62);
  animation: pause-in 0.45s ease-out;
}
.overrun-top { display: flex; justify-content: space-between; padding-bottom: 13px; border-bottom: 1px solid var(--line); color: var(--blood-hot); font-size: 8px; letter-spacing: 0.18em; }
.overrun-top span:last-child { color: var(--bone-dim); }
.overrun-kicker { margin: 20px 0 5px; color: var(--amber); font-size: 8px; font-weight: 600; letter-spacing: 0.23em; }
.overrun-panel h2 {
  margin: 0 0 12px;
  font-family: var(--display);
  color: var(--bone);
  font-size: clamp(76px, 9.4vw, 122px);
  line-height: 0.62;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.overrun-panel h2 em { color: var(--blood); font-style: normal; }
.overrun-copy { max-width: 350px; margin: 0 0 21px; color: rgba(218, 218, 204, 0.56); font-size: 10px; line-height: 1.7; }
.overrun-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 14px 0 19px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.overrun-stats div { display: flex; flex-direction: column; gap: 5px; }
.overrun-stats span { color: rgba(218, 218, 204, 0.4); font-size: 7px; letter-spacing: 0.16em; }
.overrun-stats b { font-family: var(--display); color: var(--bone); font-size: 25px; line-height: 0.9; font-weight: 500; letter-spacing: 0.05em; font-variant-numeric: tabular-nums; }
.overrun-panel .start-btn { margin-top: 18px; }
.overrun-hint { display: flex; align-items: center; gap: 8px; margin-top: 16px; color: rgba(218, 218, 204, 0.35); font-size: 7px; letter-spacing: 0.17em; }
.overrun-hint span { width: 5px; height: 5px; border: 1px solid var(--blood); border-radius: 50%; box-shadow: 0 0 7px var(--blood); }
body.overrun .hud { opacity: 0.2; }

/* ------------------------------ toast ------------------------------ */
.toast {
  position: fixed;
  left: 50%;
  top: 20.5%;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 280px;
  justify-content: center;
  padding: 10px 24px;
  opacity: 0;
  transform: translate(-50%, -7px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  background: radial-gradient(ellipse at center, rgba(4, 8, 8, 0.85), transparent 72%);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast-line { width: 48px; height: 1px; background: linear-gradient(90deg, transparent, rgba(225, 37, 50, 0.75)); }
.toast-line:last-child { background: linear-gradient(90deg, rgba(225, 37, 50, 0.75), transparent); }
.toast div { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.toast strong { font-family: var(--display); font-size: 23px; font-weight: 600; letter-spacing: 0.13em; line-height: 1; color: var(--bone); text-shadow: 0 2px 10px #000; }
.toast small { font-size: 9px; letter-spacing: 0.18em; color: var(--amber); }
.toast.blood strong { color: var(--blood-hot); }

/* ------------------------------ error ------------------------------ */
.error-screen {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 32px;
  background: #050708;
  text-align: center;
}
.error-screen[hidden] { display: none; }
.error-screen h1 { margin: 0; font-family: var(--display); font-size: clamp(38px, 7vw, 76px); line-height: 0.9; letter-spacing: 0.08em; color: var(--blood); }
.error-screen p { max-width: 440px; color: var(--bone-dim); font-size: 12px; line-height: 1.7; }

/* ------------------------------ responsive ------------------------------ */
@media (max-width: 1180px) {
  .hud-bar { grid-template-columns: 1fr auto; }
  .hud-threat { display: none; }
  .hud-rail { display: none; }
  .menu-main { grid-template-columns: minmax(0, 1fr) 330px; gap: 36px; }
  .briefing { padding: 19px; }
}
@media (max-width: 900px) {
  .menu-main { grid-template-columns: 1fr; align-items: center; padding: 20px 32px 24px; }
  .briefing { display: none; }
  .menu-lede { max-width: 390px; margin: 20px 0 24px; }
  .menu-topline { padding: 17px 34px 0; font-size: 7px; }
  .menu-footer { padding: 0 34px 14px; font-size: 6px; }
  .mega-title { font-size: clamp(92px, 22vw, 180px); }
  .mission-block, .controls-strip { display: none; }
  .hud-bar { padding: 13px 20px 12px; }
  .brand-type strong { font-size: 17px; }
  .brand-type span { font-size: 7px; }
  .connection { display: none; }
  .score-main strong { font-size: 25px; }
  .score-meta { display: none; }
  .hud-score { gap: 0; }
  .ammo-block { bottom: 25px; right: 20px; }
  .ammo-count b { font-size: 47px; }
  .combo-block { right: 20px; top: 31%; }
  .hit-feed { right: 20px; top: calc(31% + 84px); }
  .hud-footer { left: 20px; right: 20px; }
}
@media (max-width: 560px) {
  .menu-copy .eyebrow span + span { display: none; }
  .menu-main { padding: 12px 22px 20px; }
  .menu-topline { padding: 15px 23px 0; }
  .menu-topline > span:first-child { max-width: 210px; line-height: 1.5; }
  .menu-footer { padding: 0 23px 12px; }
  .menu-footer span:last-child { display: none; }
  .menu-lede { font-size: 11px; }
  .start-btn { width: 100%; }
  .ammo-pips { display: none; }
  .hit-feed { display: none; }
  .reload-badge { top: calc(50% + 42px); }
  .hud-footer span:last-child { display: none; }
  .level-banner-main b { font-size: 66px; }
  .level-banner { padding: 15px 18px 14px; }
  .overrun-panel { margin-left: 22px; padding: 21px 20px; }
  .overrun-art { width: 95vw; opacity: 0.3; }
  .overrun-stats { gap: 8px; }
  .overrun-stats b { font-size: 20px; }
  .pause-card { padding: 21px; }
  .pause-card h2 { font-size: 67px; }
  .toast { min-width: 240px; padding: 9px 13px; }
  .toast strong { font-size: 20px; }
  .toast-line { width: 24px; }
}
@media (max-height: 730px) {
  .level-banner { top: 27%; }
  .level-banner-main b { font-size: 68px; }
  .overrun-panel { margin-top: 0; padding: 18px 22px; }
  .overrun-panel h2 { font-size: 78px; }
  .overrun-copy { margin-bottom: 13px; }
  .overrun-stats { padding: 10px 0 13px; }
  .menu-main { padding-top: 4px; padding-bottom: 18px; }
  .mega-title { font-size: clamp(86px, 13vw, 178px); }
  .menu-lede { margin: 16px 0 20px; line-height: 1.55; }
  .eyebrow { margin-bottom: 12px; }
  .briefing { padding: 16px 19px; }
  .briefing h2 { font-size: 29px; margin: 13px 0 9px; }
  .briefing > p { display: none; }
  .brief-list li { padding: 8px 0; }
  .brief-controls { padding-top: 12px; }
  .headphone-hint { margin-top: 12px !important; }
  .menu-footer { display: none; }
  .mission-block { bottom: 70px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}


/* Always leave a route back to the site from the entry screen. */
.start-exit {
  display: flex;
  align-items: center;
  gap: 17px;
  width: min(420px, 100%);
  min-height: 60px;
  margin-top: 13px;
  padding: 12px 19px 12px 16px;
  border: 1px solid rgba(230, 228, 214, 0.36);
  background: rgba(7, 10, 10, 0.3);
  color: var(--bone);
  text-decoration: none;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 13px), calc(100% - 13px) 100%, 0 100%);
  transition: color 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}
.start-exit-index {
  display: flex;
  align-items: center;
  align-self: stretch;
  padding-right: 16px;
  border-right: 1px solid rgba(230, 228, 214, 0.25);
  font-family: var(--mono);
  font-size: 18px;
  line-height: 1;
}
.start-exit-copy { display: flex; flex-direction: column; gap: 5px; }
.start-exit-copy b {
  font-family: var(--display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.11em;
  line-height: 0.95;
}
.start-exit-copy small {
  color: rgba(218, 218, 204, 0.55);
  font-family: var(--mono);
  font-size: 7px;
  letter-spacing: 0.18em;
}
.start-exit:hover, .start-exit:focus-visible {
  border-color: var(--blood);
  background: rgba(225, 37, 50, 0.12);
  color: #fff;
  outline: none;
}
.start-exit:hover .start-exit-copy small, .start-exit:focus-visible .start-exit-copy small { color: rgba(255, 255, 255, 0.7); }


/* ------------------------------ vault exploration ------------------------------ */
.vault-prompt {
  position: fixed;
  left: 50%;
  bottom: 74px;
  z-index: 35;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  min-width: min(470px, calc(100vw - 34px));
  padding: 14px 24px 15px;
  border: 1px solid rgba(112, 255, 194, 0.5);
  background: rgba(4, 12, 9, 0.86);
  box-shadow: 0 0 38px rgba(70, 255, 174, 0.1), inset 0 0 25px rgba(70, 255, 174, 0.035);
  color: var(--bone);
  text-align: center;
  pointer-events: none;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
}
.vault-prompt[hidden] { display: none; }
.vault-prompt-kicker {
  color: #73ffc4;
  font-family: var(--mono);
  font-size: 7px;
  font-weight: 600;
  letter-spacing: 0.22em;
}
.vault-prompt b {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.14em;
  line-height: 1;
}
.vault-prompt small {
  color: rgba(218, 218, 204, 0.56);
  font-family: var(--mono);
  font-size: 7px;
  letter-spacing: 0.12em;
}
.vault-prompt kbd {
  display: inline-block;
  padding: 1px 4px;
  border: 1px solid rgba(218, 218, 204, 0.22);
  color: rgba(218, 222, 208, 0.78);
  font-size: 7px;
}
.vault-fade {
  position: fixed;
  inset: 0;
  z-index: 70;
  background: #020403;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.32s ease, visibility 0.32s ease;
}
.vault-fade.is-on { opacity: 1; visibility: visible; }
body.is-exploring .crosshair,
body.is-exploring .ammo-block,
body.is-exploring .reload-badge,
body.is-exploring .hitmarker,
body.is-exploring .controls-strip {
  opacity: 0 !important;
  visibility: hidden !important;
}
body.is-exploring .mission-block p { color: #73ffc4; }
body.is-exploring .mission-level b { color: #73ffc4; }

.hud-threat.vault .threat-dot { background: #73ffc4; box-shadow: 0 0 12px rgba(115, 255, 196, 0.8); }


/* ------------------------------ TV lockdown ------------------------------ */
.tv-prompt {
  position: fixed;
  left: 50%;
  bottom: 74px;
  z-index: 35;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  min-width: min(540px, calc(100vw - 34px));
  padding: 14px 24px 15px;
  border: 1px solid rgba(255, 77, 63, 0.62);
  background: rgba(14, 5, 5, 0.9);
  box-shadow: 0 0 42px rgba(255, 55, 45, 0.13), inset 0 0 28px rgba(255, 55, 45, 0.05);
  color: var(--bone);
  text-align: center;
  pointer-events: none;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
  animation: tv-lock-pulse 2.4s ease-in-out infinite;
}
.tv-prompt[hidden] { display: none; }
.tv-prompt-kicker {
  color: #ff6655;
  font-family: var(--mono);
  font-size: 7px;
  font-weight: 600;
  letter-spacing: 0.22em;
}
.tv-prompt b {
  font-family: var(--display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 0.14em;
  line-height: 1;
}
.tv-prompt small {
  max-width: 490px;
  color: rgba(218, 218, 204, 0.58);
  font-family: var(--mono);
  font-size: 7px;
  letter-spacing: 0.12em;
  line-height: 1.6;
}
@keyframes tv-lock-pulse {
  0%, 100% { border-color: rgba(255, 77, 63, 0.55); }
  50% { border-color: rgba(255, 125, 80, 0.95); }
}


/* ------------------------------ asset loading / auto-start ------------------------------ */
.loading-screen {
  z-index: 95;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% 42%, rgba(92, 20, 17, 0.2), transparent 52%),
    linear-gradient(145deg, #050708 0%, #0b0c0c 55%, #130708 100%);
}
.loading-screen.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loading-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(154, 37, 31, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(154, 37, 31, 0.055) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(ellipse at 50% 48%, #000 20%, transparent 76%);
}
.loading-card {
  position: relative;
  z-index: 2;
  width: min(620px, calc(100vw - 46px));
  padding: 34px 38px 28px;
  border: 1px solid rgba(222, 218, 202, 0.18);
  background: linear-gradient(160deg, rgba(7, 11, 11, 0.92), rgba(5, 7, 7, 0.72));
  clip-path: polygon(0 0, calc(100% - 24px) 0, 100% 24px, 100% 100%, 24px 100%, 0 calc(100% - 24px));
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.6);
}
.loading-brand {
  display: flex;
  align-items: baseline;
  gap: 12px;
  color: var(--bone);
  font-family: var(--display);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.12em;
}
.loading-brand span { color: var(--blood-hot); font-family: var(--mono); font-size: 8px; letter-spacing: 0.2em; }
.loading-kicker { margin: 26px 0 8px; color: var(--amber); font-family: var(--mono); font-size: 8px; letter-spacing: 0.22em; }
.loading-card h1 {
  margin: 0 0 12px;
  color: var(--bone);
  font-family: var(--display);
  font-size: clamp(48px, 7vw, 82px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 0.78;
}
.loading-card h1 em { color: var(--blood); font-style: normal; }
.loading-sub { max-width: 420px; margin: 0 0 26px; color: rgba(218, 218, 204, 0.5); font-size: 10px; line-height: 1.7; }
.loading-track { height: 7px; overflow: hidden; border: 1px solid rgba(218, 218, 204, 0.16); background: rgba(0, 0, 0, 0.45); }
.loading-track i { display: block; width: 0; height: 100%; background: linear-gradient(90deg, var(--blood), var(--blood-hot)); box-shadow: 0 0 18px rgba(193, 59, 42, 0.4); transition: width 0.3s ease; }
.loading-readout { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 10px; color: rgba(218, 218, 204, 0.48); font-family: var(--mono); font-size: 8px; letter-spacing: 0.16em; }
.loading-readout b { color: var(--bone); font-family: var(--display); font-size: 22px; letter-spacing: 0.05em; }
.loading-detail { margin-top: 7px; color: rgba(218, 218, 204, 0.3); font-family: var(--mono); font-size: 7px; letter-spacing: 0.16em; }
.loading-hint { margin: 22px 0 0; color: rgba(218, 218, 204, 0.22); font-family: var(--mono); font-size: 7px; letter-spacing: 0.13em; line-height: 1.6; }
.loading-exit, .engage-exit { display: inline-block; margin-top: 18px; color: rgba(218, 218, 204, 0.4); font-family: var(--mono); font-size: 8px; letter-spacing: 0.12em; }
.loading-exit:hover, .engage-exit:hover { color: var(--blood-hot); }

.engage-overlay {
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at 50% 50%, rgba(4, 7, 7, 0.58), rgba(2, 4, 4, 0.9));
  backdrop-filter: blur(2px);
}
.engage-overlay[hidden] { display: none; }
.engage-card {
  width: min(450px, calc(100vw - 40px));
  padding: 27px 29px 23px;
  border: 1px solid rgba(222, 218, 202, 0.24);
  background: linear-gradient(160deg, rgba(8, 12, 12, 0.96), rgba(4, 7, 7, 0.92));
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 18px), calc(100% - 18px) 100%, 0 100%);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.7);
  text-align: left;
}
.engage-kicker { color: var(--amber); font-family: var(--mono); font-size: 8px; letter-spacing: 0.2em; }
.engage-card h2 { margin: 15px 0 10px; color: var(--bone); font-family: var(--display); font-size: clamp(44px, 6vw, 62px); font-weight: 700; line-height: 0.76; letter-spacing: -0.02em; }
.engage-card h2 em { color: var(--blood); font-style: normal; }
.engage-card p { margin: 0 0 19px; color: rgba(218, 218, 204, 0.55); font-size: 10px; line-height: 1.7; }
