/* ============================================================
   HEIST PLANNER — styles.css
   JH Games | Neon-Noir Aesthetic
   Fonts: Barlow Condensed (headers) + Share Tech Mono (body)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,300;0,400;0,600;0,700;0,800;0,900;1,700&family=Share+Tech+Mono&display=swap');

/* ============================================================
   CSS CUSTOM PROPERTIES
   ============================================================ */

:root {
  /* Core Palette */
  --bg-black:       #0A0A0F;
  --dark-charcoal:  #141420;
  --medium-gray:    #2A2A3A;
  --neon-red:       #FF2244;
  --neon-cyan:      #00FFDD;
  --neon-yellow:    #FFDD00;
  --neon-green:     #44FF88;
  --neon-purple:    #BB44FF;
  --blood-orange:   #FF6622;
  --white-dim:      #C8C8D8;
  --blueprint-blue: #1A3A5A;
  --blueprint-line: #00AAFF;

  /* Derived / Tints */
  --neon-cyan-dim:    rgba(0, 255, 221, 0.15);
  --neon-red-dim:     rgba(255, 34, 68, 0.15);
  --neon-green-dim:   rgba(68, 255, 136, 0.12);
  --neon-purple-dim:  rgba(187, 68, 255, 0.15);
  --neon-yellow-dim:  rgba(255, 221, 0, 0.12);
  --blueprint-dim:    rgba(0, 170, 255, 0.08);

  /* Glow Shadows */
  --glow-cyan:    0 0 6px #00FFDD, 0 0 20px rgba(0,255,221,0.5), 0 0 40px rgba(0,255,221,0.2);
  --glow-red:     0 0 6px #FF2244, 0 0 20px rgba(255,34,68,0.5),  0 0 40px rgba(255,34,68,0.2);
  --glow-yellow:  0 0 6px #FFDD00, 0 0 20px rgba(255,221,0,0.5),  0 0 40px rgba(255,221,0,0.2);
  --glow-green:   0 0 6px #44FF88, 0 0 20px rgba(68,255,136,0.5), 0 0 40px rgba(68,255,136,0.2);
  --glow-purple:  0 0 6px #BB44FF, 0 0 20px rgba(187,68,255,0.5), 0 0 40px rgba(187,68,255,0.2);
  --glow-orange:  0 0 6px #FF6622, 0 0 20px rgba(255,102,34,0.5), 0 0 40px rgba(255,102,34,0.2);
  --glow-blue:    0 0 6px #00AAFF, 0 0 20px rgba(0,170,255,0.5),  0 0 40px rgba(0,170,255,0.2);

  /* Text Glow */
  --text-glow-cyan:   0 0 8px rgba(0,255,221,0.9),   0 0 20px rgba(0,255,221,0.4);
  --text-glow-red:    0 0 8px rgba(255,34,68,0.9),    0 0 20px rgba(255,34,68,0.4);
  --text-glow-yellow: 0 0 8px rgba(255,221,0,0.9),    0 0 20px rgba(255,221,0,0.4);
  --text-glow-green:  0 0 8px rgba(68,255,136,0.9),   0 0 20px rgba(68,255,136,0.4);
  --text-glow-purple: 0 0 8px rgba(187,68,255,0.9),   0 0 20px rgba(187,68,255,0.4);
  --text-glow-orange: 0 0 8px rgba(255,102,34,0.9),   0 0 20px rgba(255,102,34,0.4);
  --text-glow-blue:   0 0 8px rgba(0,170,255,0.9),    0 0 20px rgba(0,170,255,0.4);

  /* Typography */
  --font-header: 'Barlow Condensed', sans-serif;
  --font-mono:   'Share Tech Mono', monospace;

  /* Radii */
  --radius-sm: 3px;
  --radius-md: 6px;
  --radius-lg: 10px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-med:  0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ============================================================
   GLOBAL RESET + BASE
   ============================================================ */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  height: 100%;
}

body {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--white-dim);
  background-color: var(--bg-black);
  min-height: 100%;
  overflow: hidden;
  position: relative;
  user-select: none;
}

/* Grain/noise texture overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  background-repeat: repeat;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.6;
  mix-blend-mode: overlay;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: var(--neon-cyan);
  text-decoration: none;
}

/* ============================================================
   CUSTOM SCROLLBAR
   ============================================================ */

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--dark-charcoal);
}
::-webkit-scrollbar-thumb {
  background: var(--medium-gray);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--neon-cyan);
  box-shadow: var(--glow-cyan);
}

/* ============================================================
   KEYFRAME ANIMATIONS
   ============================================================ */

/* Neon flicker */
@keyframes neon-flicker {
  0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% { opacity: 1; }
  20%, 24%, 55% { opacity: 0.4; }
}

/* Neon pulse (box-shadow) */
@keyframes neon-pulse {
  0%, 100% { box-shadow: var(--glow-cyan); }
  50%       { box-shadow: 0 0 4px #00FFDD, 0 0 10px rgba(0,255,221,0.3); }
}

/* Red alert pulse */
@keyframes red-pulse {
  0%, 100% { box-shadow: var(--glow-red); background-color: rgba(255,34,68,0.3); }
  50%       { box-shadow: 0 0 4px #FF2244, 0 0 10px rgba(255,34,68,0.2); background-color: rgba(255,34,68,0.1); }
}

/* Lockdown flash */
@keyframes lockdown-flash {
  0%, 49% { background-color: rgba(255,34,68,0.35); color: #FF2244; }
  50%, 100% { background-color: rgba(255,34,68,0.05); color: #FF6680; }
}

/* Rain drop fall */
@keyframes rain-fall {
  0%   { transform: translateY(-100vh) translateX(0); opacity: 0; }
  5%   { opacity: 0.6; }
  95%  { opacity: 0.3; }
  100% { transform: translateY(110vh) translateX(-60px); opacity: 0; }
}

/* News ticker scroll */
@keyframes ticker-scroll {
  0%   { transform: translateX(100%); }
  100% { transform: translateX(-200%); }
}

/* Slide in from left */
@keyframes slide-in-left {
  from { transform: translateX(-40px); opacity: 0; }
  to   { transform: translateX(0);     opacity: 1; }
}

/* Slide in from right */
@keyframes slide-in-right {
  from { transform: translateX(40px); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

/* Slide in from top */
@keyframes slide-in-top {
  from { transform: translateY(-30px); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}

/* Slide in from bottom */
@keyframes slide-in-bottom {
  from { transform: translateY(30px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

/* Fade in */
@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Static burst transition */
@keyframes static-burst {
  0%   { filter: brightness(1) contrast(1); }
  20%  { filter: brightness(3) contrast(2) saturate(0); }
  40%  { filter: brightness(0.2) contrast(5) saturate(0) invert(1); }
  60%  { filter: brightness(4) contrast(3) saturate(0); }
  80%  { filter: brightness(0.5) contrast(2) saturate(0) invert(0.5); }
  100% { filter: brightness(1) contrast(1); }
}

/* City silhouette rise */
@keyframes city-rise {
  from { transform: translateY(40px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

/* XP bar fill */
@keyframes xp-fill {
  from { width: 0%; }
}

/* Scan line sweep */
@keyframes scanline {
  0%   { top: -10%; }
  100% { top: 110%; }
}

/* Rotate slow */
@keyframes rotate-slow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* Cursor blink */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* Map pin bounce */
@keyframes pin-bounce {
  0%, 100% { transform: translateY(0) scale(1); }
  50%       { transform: translateY(-6px) scale(1.1); }
}

/* Heat segment ignite */
@keyframes heat-ignite {
  0%   { opacity: 0.4; }
  100% { opacity: 1; box-shadow: 0 0 8px #FF2244, 0 0 16px rgba(255,34,68,0.6); }
}

/* Glow border breathe */
@keyframes border-breathe {
  0%, 100% { border-color: rgba(0,255,221,0.4); }
  50%       { border-color: rgba(0,255,221,0.9); }
}

/* Modal appear */
@keyframes modal-appear {
  from { transform: scale(0.92) translateY(-20px); opacity: 0; }
  to   { transform: scale(1)    translateY(0);     opacity: 1; }
}

/* ============================================================
   SCREEN MANAGEMENT
   ============================================================ */

.screen {
  position: fixed;
  inset: 0;
  display: none;
  flex-direction: column;
  overflow: hidden;
}

.screen.active {
  display: flex;
  animation: fade-in 0.4s ease;
}

.screen.transitioning {
  animation: static-burst 0.35s ease forwards;
}

/* ============================================================
   SHARED PANEL / UI ATOMS
   ============================================================ */

.panel {
  background: var(--dark-charcoal);
  border: 1px solid rgba(0, 255, 221, 0.25);
  border-radius: var(--radius-md);
  position: relative;
  overflow: hidden;
}

.panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,255,221,0.03) 0%, transparent 60%);
  pointer-events: none;
}

.panel--cyan   { border-color: rgba(0, 255, 221, 0.4); }
.panel--red    { border-color: rgba(255, 34, 68, 0.4); }
.panel--yellow { border-color: rgba(255, 221, 0, 0.4); }
.panel--green  { border-color: rgba(68, 255, 136, 0.4); }
.panel--purple { border-color: rgba(187, 68, 255, 0.4); }
.panel--orange { border-color: rgba(255, 102, 34, 0.4); }
.panel--blue   { border-color: rgba(0, 170, 255, 0.4); }

/* Panel section label */
.panel-label {
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  padding: 6px 12px;
  border-bottom: 1px solid rgba(0,255,221,0.2);
  background: rgba(0,255,221,0.05);
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  border: none;
  border-radius: var(--radius-sm);
  padding: 10px 24px;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
  outline: none;
  background: transparent;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.05);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.btn:hover::before { opacity: 1; }

/* Primary — Cyan */
.btn-primary {
  color: var(--neon-cyan);
  border: 2px solid var(--neon-cyan);
  box-shadow: 0 0 8px rgba(0,255,221,0.3), inset 0 0 8px rgba(0,255,221,0.05);
}
.btn-primary:hover {
  background: rgba(0,255,221,0.1);
  box-shadow: var(--glow-cyan), inset 0 0 16px rgba(0,255,221,0.1);
  color: #fff;
  text-shadow: var(--text-glow-cyan);
}
.btn-primary:active { transform: scale(0.97); box-shadow: 0 0 4px var(--neon-cyan); }

/* Danger — Red */
.btn-danger {
  color: var(--neon-red);
  border: 2px solid var(--neon-red);
  box-shadow: 0 0 8px rgba(255,34,68,0.3), inset 0 0 8px rgba(255,34,68,0.05);
}
.btn-danger:hover {
  background: rgba(255,34,68,0.12);
  box-shadow: var(--glow-red), inset 0 0 16px rgba(255,34,68,0.1);
  color: #fff;
  text-shadow: var(--text-glow-red);
}
.btn-danger:active { transform: scale(0.97); }

/* Success — Green */
.btn-success {
  color: var(--neon-green);
  border: 2px solid var(--neon-green);
  box-shadow: 0 0 8px rgba(68,255,136,0.3);
}
.btn-success:hover {
  background: rgba(68,255,136,0.1);
  box-shadow: var(--glow-green);
  color: #fff;
  text-shadow: var(--text-glow-green);
}

/* Warning — Yellow */
.btn-warning {
  color: var(--neon-yellow);
  border: 2px solid var(--neon-yellow);
  box-shadow: 0 0 8px rgba(255,221,0,0.3);
}
.btn-warning:hover {
  background: rgba(255,221,0,0.1);
  box-shadow: var(--glow-yellow);
  color: #fff;
  text-shadow: var(--text-glow-yellow);
}

/* Ghost */
.btn-ghost {
  color: var(--white-dim);
  border: 1px solid rgba(200,200,216,0.3);
}
.btn-ghost:hover {
  border-color: var(--white-dim);
  color: #fff;
}

/* Orange */
.btn-orange {
  color: var(--blood-orange);
  border: 2px solid var(--blood-orange);
  box-shadow: 0 0 8px rgba(255,102,34,0.3);
}
.btn-orange:hover {
  background: rgba(255,102,34,0.1);
  box-shadow: var(--glow-orange);
  color: #fff;
  text-shadow: var(--text-glow-orange);
}

.btn:disabled,
.btn.disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}

/* ---- Badges ---- */
.badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 2px 7px;
  border-radius: 2px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.badge-cyan   { background: rgba(0,255,221,0.15);   color: var(--neon-cyan);    border: 1px solid rgba(0,255,221,0.4); }
.badge-red    { background: rgba(255,34,68,0.15);    color: var(--neon-red);     border: 1px solid rgba(255,34,68,0.4); }
.badge-yellow { background: rgba(255,221,0,0.12);    color: var(--neon-yellow);  border: 1px solid rgba(255,221,0,0.4); }
.badge-green  { background: rgba(68,255,136,0.12);   color: var(--neon-green);   border: 1px solid rgba(68,255,136,0.4); }
.badge-purple { background: rgba(187,68,255,0.12);   color: var(--neon-purple);  border: 1px solid rgba(187,68,255,0.4); }
.badge-orange { background: rgba(255,102,34,0.12);   color: var(--blood-orange); border: 1px solid rgba(255,102,34,0.4); }

/* ---- Divider ---- */
.divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,255,221,0.3), transparent);
  margin: 8px 0;
}

/* ---- Stat bar ---- */
.stat-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
}
.stat-bar__label {
  width: 70px;
  text-align: right;
  color: rgba(200,200,216,0.6);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
}
.stat-bar__track {
  flex: 1;
  height: 6px;
  background: var(--medium-gray);
  border-radius: 2px;
  overflow: hidden;
}
.stat-bar__fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.6s ease;
}
.stat-bar__fill--cyan   { background: linear-gradient(90deg, rgba(0,255,221,0.6), var(--neon-cyan)); }
.stat-bar__fill--green  { background: linear-gradient(90deg, rgba(68,255,136,0.6), var(--neon-green)); }
.stat-bar__fill--red    { background: linear-gradient(90deg, rgba(255,34,68,0.6), var(--neon-red)); }
.stat-bar__fill--purple { background: linear-gradient(90deg, rgba(187,68,255,0.6), var(--neon-purple)); }
.stat-bar__fill--yellow { background: linear-gradient(90deg, rgba(255,221,0,0.6), var(--neon-yellow)); }
.stat-bar__fill--orange { background: linear-gradient(90deg, rgba(255,102,34,0.6), var(--blood-orange)); }
.stat-bar__value {
  width: 28px;
  text-align: right;
  font-size: 0.65rem;
  color: var(--white-dim);
}

/* ---- Shared top bar ---- */
.top-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 8px 20px;
  background: var(--dark-charcoal);
  border-bottom: 1px solid rgba(0,255,221,0.2);
  flex-shrink: 0;
  position: relative;
  z-index: 10;
}

.top-bar__title {
  font-family: var(--font-header);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
}

.top-bar__spacer { flex: 1; }

/* ============================================================
   SCREEN 1 — MAIN MENU
   ============================================================ */

#screen-menu {
  background: var(--bg-black);
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

/* Rain container */
.rain-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

/* Rain drops — generated via JS, styled here */
.rain-drop {
  position: absolute;
  top: -10%;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(0,170,255,0.5), rgba(0,255,221,0.3));
  border-radius: 1px;
  animation: rain-fall linear infinite;
  opacity: 0;
}

/* Cityscape silhouette */
.cityscape {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 220px;
  z-index: 1;
  animation: city-rise 1.2s ease 0.3s both;
}

/* Layered CSS city shapes */
.city-layer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-black);
  clip-path: polygon(
    0% 100%,
    0% 60%,  2% 60%, 2% 30%, 4% 30%, 4% 60%, 5% 60%, 5% 20%, 6.5% 20%,
    6.5% 60%, 8% 60%, 8% 45%, 10% 45%, 10% 60%, 11% 60%, 11% 10%, 13% 10%,
    13% 60%, 14% 60%, 14% 35%, 16% 35%, 16% 60%, 18% 60%, 18% 50%, 20% 50%,
    20% 25%, 22% 25%, 22% 55%, 24% 55%, 24% 40%, 26% 40%, 26% 15%, 28% 15%,
    28% 50%, 30% 50%, 30% 60%, 32% 60%, 32% 30%, 34% 30%, 34% 55%, 36% 55%,
    36% 20%, 38% 20%, 38% 60%, 40% 60%, 40% 45%, 42% 45%, 42% 5%, 44% 5%,
    44% 60%, 46% 60%, 46% 35%, 48% 35%, 48% 55%, 50% 55%, 50% 22%, 52% 22%,
    52% 60%, 54% 60%, 54% 40%, 56% 40%, 56% 60%, 58% 60%, 58% 18%, 60% 18%,
    60% 50%, 62% 50%, 62% 35%, 64% 35%, 64% 60%, 66% 60%, 66% 28%, 68% 28%,
    68% 55%, 70% 55%, 70% 42%, 72% 42%, 72% 8%, 74% 8%, 74% 55%, 76% 55%,
    76% 38%, 78% 38%, 78% 60%, 80% 60%, 80% 25%, 82% 25%, 82% 50%, 84% 50%,
    84% 40%, 86% 40%, 86% 55%, 88% 55%, 88% 32%, 90% 32%, 90% 60%, 92% 60%,
    92% 48%, 94% 48%, 94% 22%, 96% 22%, 96% 58%, 98% 58%, 98% 38%,
    100% 38%, 100% 100%
  );
}

.city-layer--back {
  height: 200px;
  background: #0D0D18;
  opacity: 0.9;
}
.city-layer--mid {
  height: 160px;
  background: #0A0A14;
  clip-path: polygon(
    0% 100%, 0% 50%, 3% 50%, 3% 25%, 6% 25%, 6% 55%, 9% 55%, 9% 35%,
    12% 35%, 12% 50%, 15% 50%, 15% 12%, 18% 12%, 18% 50%, 21% 50%, 21% 38%,
    24% 38%, 24% 55%, 27% 55%, 27% 20%, 30% 20%, 30% 50%, 33% 50%, 33% 42%,
    36% 42%, 36% 50%, 39% 50%, 39% 8%, 42% 8%, 42% 50%, 45% 50%, 45% 30%,
    48% 30%, 48% 55%, 51% 55%, 51% 18%, 54% 18%, 54% 50%, 57% 50%, 57% 40%,
    60% 40%, 60% 55%, 63% 55%, 63% 22%, 66% 22%, 66% 50%, 69% 50%, 69% 35%,
    72% 35%, 72% 50%, 75% 50%, 75% 5%, 78% 5%, 78% 50%, 81% 50%, 81% 28%,
    84% 28%, 84% 55%, 87% 55%, 87% 15%, 90% 15%, 90% 50%, 93% 50%, 93% 35%,
    96% 35%, 96% 50%, 99% 50%, 99% 42%, 100% 42%, 100% 100%
  );
}

/* Glowing windows scattered on cityscape */
.city-windows {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background-image:
    radial-gradient(1px 2px at 5% 50%,   rgba(255,221,0,0.5)  0%, transparent 100%),
    radial-gradient(1px 2px at 12% 30%,  rgba(255,221,0,0.4)  0%, transparent 100%),
    radial-gradient(1px 2px at 20% 40%,  rgba(0,255,221,0.4)  0%, transparent 100%),
    radial-gradient(1px 2px at 27% 20%,  rgba(255,221,0,0.5)  0%, transparent 100%),
    radial-gradient(1px 2px at 35% 45%,  rgba(255,102,34,0.4) 0%, transparent 100%),
    radial-gradient(1px 2px at 42% 15%,  rgba(255,221,0,0.4)  0%, transparent 100%),
    radial-gradient(1px 2px at 50% 38%,  rgba(0,255,221,0.5)  0%, transparent 100%),
    radial-gradient(1px 2px at 58% 28%,  rgba(255,221,0,0.4)  0%, transparent 100%),
    radial-gradient(1px 2px at 66% 45%,  rgba(187,68,255,0.3) 0%, transparent 100%),
    radial-gradient(1px 2px at 74% 12%,  rgba(255,221,0,0.5)  0%, transparent 100%),
    radial-gradient(1px 2px at 82% 35%,  rgba(0,255,221,0.4)  0%, transparent 100%),
    radial-gradient(1px 2px at 90% 22%,  rgba(255,221,0,0.5)  0%, transparent 100%);
  z-index: 2;
  pointer-events: none;
}

/* Ground glow beneath city */
.city-ground-glow {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(180deg, transparent, rgba(0,255,221,0.04), rgba(255,34,68,0.03));
  z-index: 3;
}

/* Menu center content */
.menu-content {
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 160px;
}

/* Big logo */
.menu-logo {
  font-family: var(--font-header);
  font-weight: 900;
  font-size: clamp(4rem, 10vw, 8rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  line-height: 0.9;
  animation: fade-in 0.8s ease 0.2s both;
}

.menu-logo__line1 {
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan), 0 0 60px rgba(0,255,221,0.3);
  display: block;
  animation: neon-flicker 6s ease 3s infinite;
}

.menu-logo__line2 {
  color: var(--neon-red);
  text-shadow: var(--text-glow-red), 0 0 60px rgba(255,34,68,0.3);
  display: block;
  font-size: 0.55em;
  letter-spacing: 0.35em;
  margin-top: 4px;
  animation: neon-flicker 8s ease 5s infinite;
}

/* Tagline */
.menu-tagline {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  color: rgba(200,200,216,0.5);
  text-transform: uppercase;
  margin-top: 12px;
  margin-bottom: 48px;
  animation: fade-in 0.8s ease 0.5s both;
}

/* Main menu buttons */
.menu-buttons {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 280px;
  animation: slide-in-bottom 0.6s ease 0.7s both;
}

.menu-buttons .btn {
  font-size: 1.1rem;
  padding: 14px 32px;
  letter-spacing: 0.2em;
  width: 100%;
}

/* Version / branding */
.menu-branding {
  position: absolute;
  bottom: 230px;
  right: 24px;
  font-family: var(--font-header);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: rgba(200,200,216,0.2);
  text-transform: uppercase;
  z-index: 5;
}

/* ============================================================
   SCREEN 2 — HQ
   ============================================================ */

#screen-hq {
  background: var(--bg-black);
}

/* HQ top bar */
.hq-topbar {
  background: var(--dark-charcoal);
  border-bottom: 1px solid rgba(0,255,221,0.2);
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 20px;
  height: 54px;
  flex-shrink: 0;
}

.hq-topbar__logo {
  font-family: var(--font-header);
  font-weight: 900;
  font-size: 1.3rem;
  letter-spacing: 0.1em;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  text-transform: uppercase;
}

.hq-topbar__player {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
}
.hq-topbar__player-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--medium-gray);
  border: 1px solid rgba(0,255,221,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  color: var(--neon-cyan);
}
.hq-topbar__player-name { color: var(--white-dim); }

.hq-topbar__spacer { flex: 1; }

/* Cash display */
.hq-cash {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--neon-green);
  text-shadow: var(--text-glow-green);
}
.hq-cash__icon { font-size: 0.7rem; opacity: 0.7; }

/* Heat meter */
.heat-meter {
  display: flex;
  align-items: center;
  gap: 6px;
}
.heat-meter__label {
  font-family: var(--font-header);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(200,200,216,0.5);
  margin-right: 2px;
}
.heat-meter__segments {
  display: flex;
  gap: 3px;
}
.heat-meter__seg {
  width: 18px;
  height: 10px;
  border-radius: 2px;
  background: var(--medium-gray);
  border: 1px solid rgba(255,34,68,0.2);
  transition: all 0.3s ease;
}
.heat-meter__seg.active { animation: heat-ignite 0.4s ease forwards; }
.heat-meter__seg:nth-child(1).active { background: rgba(255,221,0,0.7); border-color: var(--neon-yellow); }
.heat-meter__seg:nth-child(2).active { background: rgba(255,153,0,0.7); border-color: #FF9900; }
.heat-meter__seg:nth-child(3).active { background: rgba(255,102,34,0.7); border-color: var(--blood-orange); }
.heat-meter__seg:nth-child(4).active { background: rgba(255,34,68,0.7);  border-color: var(--neon-red); }
.heat-meter__seg:nth-child(5).active { background: rgba(255,34,68,0.9);  border-color: var(--neon-red); box-shadow: var(--glow-red); animation: red-pulse 0.8s ease infinite; }

/* HQ station grid */
.hq-main {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 16px;
  padding: 16px;
  overflow: hidden;
}

/* Individual station card */
.hq-station {
  background: var(--dark-charcoal);
  border: 1px solid rgba(0,255,221,0.2);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  cursor: pointer;
  transition: all var(--transition-med);
  position: relative;
  overflow: hidden;
  padding: 24px;
  animation: fade-in 0.5s ease both;
}

.hq-station:nth-child(1) { animation-delay: 0.05s; }
.hq-station:nth-child(2) { animation-delay: 0.10s; }
.hq-station:nth-child(3) { animation-delay: 0.15s; }
.hq-station:nth-child(4) { animation-delay: 0.20s; }
.hq-station:nth-child(5) { animation-delay: 0.25s; }
.hq-station:nth-child(6) { animation-delay: 0.30s; }

.hq-station::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(0,255,221,0.04) 0%, transparent 70%);
  opacity: 0;
  transition: opacity var(--transition-med);
}

.hq-station:hover { transform: translateY(-2px); }
.hq-station:hover::before { opacity: 1; }

/* Per-station glow colors */
.hq-station--map:hover     { border-color: rgba(0,170,255,0.6);   box-shadow: var(--glow-blue); }
.hq-station--crew:hover    { border-color: rgba(68,255,136,0.6);  box-shadow: var(--glow-green); }
.hq-station--equip:hover   { border-color: rgba(255,102,34,0.6);  box-shadow: var(--glow-orange); }
.hq-station--plan:hover    { border-color: rgba(0,255,221,0.6);   box-shadow: var(--glow-cyan); }
.hq-station--safe:hover    { border-color: rgba(255,221,0,0.6);   box-shadow: var(--glow-yellow); }
.hq-station--scanner:hover { border-color: rgba(187,68,255,0.6);  box-shadow: var(--glow-purple); }

.hq-station__icon {
  font-size: 2.8rem;
  line-height: 1;
  filter: drop-shadow(0 0 8px currentColor);
  transition: transform var(--transition-med);
}
.hq-station:hover .hq-station__icon { transform: scale(1.12); }

.hq-station__name {
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-align: center;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
}
.hq-station--map .hq-station__name     { color: var(--blueprint-line); text-shadow: var(--text-glow-blue); }
.hq-station--crew .hq-station__name    { color: var(--neon-green);     text-shadow: var(--text-glow-green); }
.hq-station--equip .hq-station__name   { color: var(--blood-orange);   text-shadow: var(--text-glow-orange); }
.hq-station--plan .hq-station__name    { color: var(--neon-cyan);      text-shadow: var(--text-glow-cyan); }
.hq-station--safe .hq-station__name    { color: var(--neon-yellow);    text-shadow: var(--text-glow-yellow); }
.hq-station--scanner .hq-station__name { color: var(--neon-purple);    text-shadow: var(--text-glow-purple); }

.hq-station__sub {
  font-size: 0.65rem;
  color: rgba(200,200,216,0.45);
  letter-spacing: 0.1em;
  text-align: center;
}

/* Scanner ring decoration */
.hq-station--scanner .scanner-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 120px;
  height: 120px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1px solid rgba(187,68,255,0.1);
  pointer-events: none;
  transition: border-color var(--transition-med);
}
.hq-station--scanner:hover .scanner-ring {
  border-color: rgba(187,68,255,0.3);
  animation: rotate-slow 3s linear infinite;
}

/* News ticker */
.news-ticker {
  background: var(--dark-charcoal);
  border-top: 1px solid rgba(255,34,68,0.3);
  height: 30px;
  display: flex;
  align-items: center;
  overflow: hidden;
  flex-shrink: 0;
}

.news-ticker__label {
  flex-shrink: 0;
  background: var(--neon-red);
  color: #fff;
  font-family: var(--font-header);
  font-weight: 800;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0 12px;
  height: 100%;
  display: flex;
  align-items: center;
  z-index: 2;
}

.news-ticker__track {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.news-ticker__text {
  white-space: nowrap;
  font-size: 0.7rem;
  color: var(--white-dim);
  animation: ticker-scroll 40s linear infinite;
  display: inline-block;
  padding-left: 40px;
}

.news-ticker__text span        { margin-right: 60px; color: rgba(200,200,216,0.7); }
.news-ticker__text .ticker-highlight { color: var(--neon-yellow); }

/* ============================================================
   SCREEN 3 — HEIST SELECTION
   ============================================================ */

#screen-heist-select {
  background: var(--bg-black);
}

.heist-select-layout {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 16px;
  padding: 16px;
  overflow: hidden;
}

/* City map canvas area */
.city-map-area {
  background: var(--dark-charcoal);
  border: 1px solid rgba(0,170,255,0.3);
  border-radius: var(--radius-md);
  position: relative;
  overflow: hidden;
}

.city-map-area__canvas {
  width: 100%;
  height: 100%;
  display: block;
  background:
    repeating-linear-gradient(0deg,  rgba(0,100,50,0.04) 0px, rgba(0,100,50,0.04) 1px, transparent 1px, transparent 60px),
    repeating-linear-gradient(90deg, rgba(0,100,50,0.04) 0px, rgba(0,100,50,0.04) 1px, transparent 1px, transparent 60px),
    #0A110A;
}

.city-map-area__label {
  position: absolute;
  top: 12px;
  left: 12px;
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--neon-green);
  text-shadow: var(--text-glow-green);
  text-transform: uppercase;
}

/* Map pins */
.map-pin {
  position: absolute;
  cursor: pointer;
  transform: translate(-50%, -100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: all var(--transition-fast);
}
.map-pin:hover { z-index: 10; }

.map-pin__dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--neon-yellow);
  border: 2px solid rgba(255,221,0,0.6);
  box-shadow: var(--glow-yellow);
  animation: pin-bounce 2s ease infinite;
}
.map-pin--high .map-pin__dot { background: var(--neon-red);   border-color: rgba(255,34,68,0.6);  box-shadow: var(--glow-red); }
.map-pin--low  .map-pin__dot { background: var(--neon-green); border-color: rgba(68,255,136,0.6); box-shadow: var(--glow-green); }

.map-pin__label {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--neon-yellow);
  text-shadow: 0 0 6px rgba(255,221,0,0.8);
  white-space: nowrap;
  background: rgba(10,10,15,0.8);
  padding: 2px 5px;
  border-radius: 2px;
  border: 1px solid rgba(255,221,0,0.3);
}
.map-pin--high .map-pin__label { color: var(--neon-red);   text-shadow: 0 0 6px rgba(255,34,68,0.8);  border-color: rgba(255,34,68,0.3); }
.map-pin--low  .map-pin__label { color: var(--neon-green); text-shadow: 0 0 6px rgba(68,255,136,0.8); border-color: rgba(68,255,136,0.3); }

.map-pin.selected .map-pin__dot { transform: scale(1.4); animation: none; }

/* Heist info sidebar */
.heist-sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  animation: slide-in-right 0.4s ease both;
}

.heist-detail-card {
  background: var(--dark-charcoal);
  border: 1px solid rgba(0,255,221,0.25);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.heist-detail-card.empty {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
}
.heist-detail-card.empty p {
  font-size: 0.7rem;
  color: rgba(200,200,216,0.25);
  letter-spacing: 0.1em;
  text-align: center;
}

.heist-card__header {
  padding: 14px 16px;
  background: rgba(0,255,221,0.04);
  border-bottom: 1px solid rgba(0,255,221,0.15);
}
.heist-card__name {
  font-family: var(--font-header);
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
}
.heist-card__location {
  font-size: 0.65rem;
  color: rgba(200,200,216,0.5);
  margin-top: 2px;
}

.heist-card__body {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.heist-card__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
}
.heist-card__row-label { color: rgba(200,200,216,0.5); letter-spacing: 0.06em; }
.heist-card__row-value { color: var(--neon-yellow); text-shadow: var(--text-glow-yellow); }
.heist-card__desc {
  font-size: 0.7rem;
  color: rgba(200,200,216,0.6);
  line-height: 1.6;
  margin-top: 4px;
}

.heist-card__actions {
  padding: 12px 16px;
  border-top: 1px solid rgba(0,255,221,0.1);
  display: flex;
  gap: 8px;
}
.heist-card__actions .btn { flex: 1; font-size: 0.85rem; padding: 10px 16px; }

/* Difficulty stars */
.difficulty-stars { display: flex; gap: 3px; }
.difficulty-stars span { font-size: 0.75rem; color: rgba(200,200,216,0.2); }
.difficulty-stars span.active { color: var(--neon-yellow); text-shadow: var(--text-glow-yellow); }

/* ============================================================
   SCREEN 4 — CREW MANAGEMENT
   ============================================================ */

#screen-crew {
  background: var(--bg-black);
}

.crew-layout {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 16px;
  overflow: hidden;
}

.crew-panel {
  background: var(--dark-charcoal);
  border: 1px solid rgba(68,255,136,0.2);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.crew-panel--recruits { border-color: rgba(255,102,34,0.2); }

.crew-panel__header {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(68,255,136,0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  background: rgba(68,255,136,0.04);
}
.crew-panel--recruits .crew-panel__header {
  border-bottom-color: rgba(255,102,34,0.15);
  background: rgba(255,102,34,0.04);
}

.crew-panel__title {
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--neon-green);
  text-shadow: var(--text-glow-green);
}
.crew-panel--recruits .crew-panel__title {
  color: var(--blood-orange);
  text-shadow: var(--text-glow-orange);
}

.crew-panel__count {
  font-size: 0.65rem;
  color: rgba(200,200,216,0.4);
  letter-spacing: 0.06em;
}

.crew-panel__grid {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  align-content: start;
}

/* Crew card */
.crew-card {
  background: var(--bg-black);
  border: 1px solid rgba(0,255,221,0.15);
  border-radius: var(--radius-md);
  padding: 12px;
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.crew-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--neon-cyan);
  transition: all var(--transition-fast);
}

.crew-card--driver::before      { background: var(--neon-yellow); }
.crew-card--hacker::before      { background: var(--neon-cyan); }
.crew-card--gunner::before      { background: var(--neon-red); }
.crew-card--lookout::before     { background: var(--neon-green); }
.crew-card--safecracker::before { background: var(--neon-purple); }
.crew-card--infiltrator::before { background: var(--blood-orange); }

.crew-card:hover                { transform: translateY(-2px); border-color: rgba(0,255,221,0.4); box-shadow: 0 4px 20px rgba(0,0,0,0.4); }
.crew-card--driver:hover        { border-color: rgba(255,221,0,0.4); box-shadow: 0 0 14px rgba(255,221,0,0.15); }
.crew-card--hacker:hover        { border-color: rgba(0,255,221,0.4); box-shadow: 0 0 14px rgba(0,255,221,0.15); }
.crew-card--gunner:hover        { border-color: rgba(255,34,68,0.4); box-shadow: 0 0 14px rgba(255,34,68,0.15); }
.crew-card--lookout:hover       { border-color: rgba(68,255,136,0.4); box-shadow: 0 0 14px rgba(68,255,136,0.15); }
.crew-card--safecracker:hover   { border-color: rgba(187,68,255,0.4); box-shadow: 0 0 14px rgba(187,68,255,0.15); }
.crew-card--infiltrator:hover   { border-color: rgba(255,102,34,0.4); box-shadow: 0 0 14px rgba(255,102,34,0.15); }
.crew-card.selected             { border-color: rgba(0,255,221,0.7); box-shadow: 0 0 0 1px rgba(0,255,221,0.3); }

.crew-card__portrait {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: var(--medium-gray);
  margin-bottom: 10px;
  border: 1px solid rgba(0,255,221,0.2);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.crew-card__name {
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--white-dim);
  margin-bottom: 2px;
}

.crew-card__role {
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.crew-card--driver .crew-card__role      { color: var(--neon-yellow); }
.crew-card--hacker .crew-card__role      { color: var(--neon-cyan); }
.crew-card--gunner .crew-card__role      { color: var(--neon-red); }
.crew-card--lookout .crew-card__role     { color: var(--neon-green); }
.crew-card--safecracker .crew-card__role { color: var(--neon-purple); }
.crew-card--infiltrator .crew-card__role { color: var(--blood-orange); }

.crew-card__stats { display: flex; flex-direction: column; gap: 5px; }

.crew-card__hire-cost {
  font-size: 0.65rem;
  color: var(--neon-green);
  text-shadow: var(--text-glow-green);
  margin-top: 8px;
  text-align: right;
}

/* Mini skill tree dots */
.skill-tree { display: flex; gap: 3px; margin-top: 6px; flex-wrap: wrap; }
.skill-node {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--medium-gray);
  border: 1px solid rgba(200,200,216,0.1);
  transition: all var(--transition-fast);
}
.skill-node.unlocked                       { background: var(--neon-cyan);    border-color: rgba(0,255,221,0.6);   box-shadow: 0 0 4px rgba(0,255,221,0.5); }
.crew-card--driver .skill-node.unlocked    { background: var(--neon-yellow);  border-color: rgba(255,221,0,0.6);   box-shadow: 0 0 4px rgba(255,221,0,0.5); }
.crew-card--gunner .skill-node.unlocked    { background: var(--neon-red);     border-color: rgba(255,34,68,0.6);   box-shadow: 0 0 4px rgba(255,34,68,0.5); }
.crew-card--lookout .skill-node.unlocked   { background: var(--neon-green);   border-color: rgba(68,255,136,0.6);  box-shadow: 0 0 4px rgba(68,255,136,0.5); }
.crew-card--safecracker .skill-node.unlocked { background: var(--neon-purple);border-color: rgba(187,68,255,0.6); box-shadow: 0 0 4px rgba(187,68,255,0.5); }
.crew-card--infiltrator .skill-node.unlocked { background: var(--blood-orange);border-color: rgba(255,102,34,0.6);box-shadow: 0 0 4px rgba(255,102,34,0.5); }

/* ============================================================
   SCREEN 5 — EQUIPMENT SHOP
   ============================================================ */

#screen-equipment {
  background: var(--bg-black);
}

.equip-layout {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 16px;
  padding: 16px;
  overflow: hidden;
}

.equip-main {
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
}

/* Category tabs */
.category-tabs {
  display: flex;
  gap: 2px;
  flex-shrink: 0;
  background: var(--dark-charcoal);
  border: 1px solid rgba(255,102,34,0.2);
  border-radius: var(--radius-md);
  padding: 4px;
}

.category-tab {
  flex: 1;
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  color: rgba(200,200,216,0.4);
  background: transparent;
  transition: all var(--transition-fast);
  text-align: center;
}
.category-tab:hover { color: var(--white-dim); background: rgba(255,102,34,0.08); }
.category-tab.active {
  color: var(--blood-orange);
  background: rgba(255,102,34,0.12);
  border-color: rgba(255,102,34,0.4);
  text-shadow: var(--text-glow-orange);
}

/* Item grid */
.item-grid {
  flex: 1;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  align-content: start;
  padding-right: 4px;
}

/* Item card */
.item-card {
  background: var(--dark-charcoal);
  border: 1px solid rgba(255,102,34,0.15);
  border-radius: var(--radius-md);
  padding: 14px;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  overflow: hidden;
}
.item-card:hover {
  border-color: rgba(255,102,34,0.5);
  box-shadow: 0 0 16px rgba(255,102,34,0.1);
  transform: translateY(-1px);
}

.item-card.owned { border-color: rgba(68,255,136,0.35); }
.item-card.owned::after {
  content: 'OWNED';
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 0.55rem;
  letter-spacing: 0.12em;
  color: var(--neon-green);
  background: rgba(68,255,136,0.1);
  border: 1px solid rgba(68,255,136,0.3);
  padding: 2px 5px;
  border-radius: 2px;
}
.item-card.in-loadout { border-color: rgba(0,255,221,0.4); box-shadow: 0 0 10px rgba(0,255,221,0.08); }

.item-card__icon { font-size: 1.8rem; line-height: 1; }
.item-card__name {
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--white-dim);
}
.item-card__type {
  font-size: 0.6rem;
  color: var(--blood-orange);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.item-card__cost {
  font-size: 0.75rem;
  color: var(--neon-yellow);
  text-shadow: var(--text-glow-yellow);
  margin-top: auto;
  font-family: var(--font-mono);
}

/* Tier corner marker */
.item-card__tier {
  position: absolute;
  top: 0; right: 0;
  width: 0; height: 0;
  border-left: 20px solid transparent;
  border-top: 20px solid rgba(255,221,0,0.4);
}

/* Loadout sidebar */
.loadout-sidebar {
  background: var(--dark-charcoal);
  border: 1px solid rgba(0,255,221,0.2);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: slide-in-right 0.4s ease both;
}

.loadout-list {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.loadout-item {
  background: var(--bg-black);
  border: 1px solid rgba(0,255,221,0.15);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
}
.loadout-item__icon { font-size: 1rem; }
.loadout-item__name { flex: 1; color: var(--white-dim); }
.loadout-item__remove {
  cursor: pointer;
  color: rgba(255,34,68,0.5);
  font-size: 0.65rem;
  padding: 2px;
  transition: color var(--transition-fast);
}
.loadout-item__remove:hover { color: var(--neon-red); text-shadow: var(--text-glow-red); }

.loadout-total {
  padding: 12px;
  border-top: 1px solid rgba(0,255,221,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
}
.loadout-total__label { color: rgba(200,200,216,0.5); }
.loadout-total__value { color: var(--neon-yellow); text-shadow: var(--text-glow-yellow); }

/* ============================================================
   SCREEN 6 — PLANNING
   ============================================================ */

#screen-planning {
  background: var(--blueprint-blue);
}

.planning-topbar {
  background: rgba(10, 20, 40, 0.95);
  border-bottom: 2px solid rgba(0,170,255,0.3);
  padding: 8px 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.planning-topbar__title {
  font-family: var(--font-header);
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--blueprint-line);
  text-shadow: var(--text-glow-blue);
}

.planning-layout {
  flex: 1;
  display: grid;
  grid-template-columns: 260px 1fr 260px;
  overflow: hidden;
}

/* Left crew assignment panel */
.planning-crew-panel {
  background: rgba(10, 20, 40, 0.92);
  border-right: 1px solid rgba(0,170,255,0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: slide-in-left 0.4s ease both;
}
.planning-crew-panel .panel-label {
  border-bottom-color: rgba(0,170,255,0.2);
  background: rgba(0,170,255,0.05);
  color: var(--blueprint-line);
  text-shadow: var(--text-glow-blue);
}

.crew-slot {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(0,170,255,0.08);
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: background var(--transition-fast);
}
.crew-slot:hover { background: rgba(0,170,255,0.06); }
.crew-slot.empty {
  opacity: 0.4;
  border: 1px dashed rgba(0,170,255,0.2);
  border-radius: var(--radius-sm);
  margin: 4px 10px;
  justify-content: center;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  color: rgba(0,170,255,0.5);
}

.crew-slot__portrait {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: var(--medium-gray);
  border: 1px solid rgba(0,170,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.crew-slot__info { flex: 1; min-width: 0; }
.crew-slot__name {
  font-family: var(--font-header);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--white-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.crew-slot__role {
  font-size: 0.6rem;
  color: rgba(0,170,255,0.6);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Approach toggle */
.approach-toggle {
  margin: 10px 12px;
  display: flex;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid rgba(0,170,255,0.2);
}
.approach-btn {
  flex: 1;
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  background: transparent;
  color: rgba(200,200,216,0.4);
  border: none;
}
.approach-btn--stealth { border-right: 1px solid rgba(0,170,255,0.2); }
.approach-btn--stealth.active { background: rgba(0,170,255,0.15); color: var(--blueprint-line); text-shadow: var(--text-glow-blue); }
.approach-btn--loud.active    { background: rgba(255,34,68,0.15);  color: var(--neon-red);       text-shadow: var(--text-glow-red); }

/* Blueprint canvas — center */
.blueprint-canvas {
  position: relative;
  overflow: hidden;
  background:
    repeating-linear-gradient(0deg,   rgba(0,170,255,0.08) 0px, rgba(0,170,255,0.08) 1px, transparent 1px, transparent 40px),
    repeating-linear-gradient(90deg,  rgba(0,170,255,0.08) 0px, rgba(0,170,255,0.08) 1px, transparent 1px, transparent 40px),
    repeating-linear-gradient(0deg,   rgba(0,170,255,0.04) 0px, rgba(0,170,255,0.04) 1px, transparent 1px, transparent 8px),
    repeating-linear-gradient(90deg,  rgba(0,170,255,0.04) 0px, rgba(0,170,255,0.04) 1px, transparent 1px, transparent 8px),
    var(--blueprint-blue);
}
.blueprint-canvas canvas { width: 100%; height: 100%; display: block; }

/* Blueprint corner marks */
.blueprint-corner {
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: rgba(0,170,255,0.6);
  border-style: solid;
}
.blueprint-corner--tl { top: 12px;    left: 12px;   border-width: 2px 0 0 2px; }
.blueprint-corner--tr { top: 12px;    right: 12px;  border-width: 2px 2px 0 0; }
.blueprint-corner--bl { bottom: 12px; left: 12px;   border-width: 0 0 2px 2px; }
.blueprint-corner--br { bottom: 12px; right: 12px;  border-width: 0 2px 2px 0; }

.blueprint-title {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(0,170,255,0.4);
}

/* Right intel panel */
.planning-intel-panel {
  background: rgba(10, 20, 40, 0.92);
  border-left: 1px solid rgba(0,170,255,0.3);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  animation: slide-in-right 0.4s ease both;
}

.intel-item {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(0,170,255,0.08);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.intel-item__label {
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(0,170,255,0.5);
}
.intel-item__value { font-size: 0.75rem; color: var(--white-dim); }
.intel-item__value--good { color: var(--neon-green);  text-shadow: var(--text-glow-green); }
.intel-item__value--warn { color: var(--neon-yellow); text-shadow: var(--text-glow-yellow); }
.intel-item__value--bad  { color: var(--neon-red);    text-shadow: var(--text-glow-red); }

.planning-actions {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid rgba(0,170,255,0.15);
  flex-shrink: 0;
}

/* ============================================================
   SCREEN 7 — EXECUTION
   ============================================================ */

#screen-execution {
  background: #060608;
}

/* Execution top bar */
.exec-topbar {
  background: var(--dark-charcoal);
  border-bottom: 1px solid rgba(0,255,221,0.2);
  padding: 6px 16px;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
  height: 50px;
}

/* Timer */
.exec-timer {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  letter-spacing: 0.06em;
  min-width: 80px;
}
.exec-timer.warning {
  color: var(--neon-yellow);
  text-shadow: var(--text-glow-yellow);
  animation: neon-flicker 1s ease infinite;
}
.exec-timer.critical {
  color: var(--neon-red);
  text-shadow: var(--text-glow-red);
  animation: neon-flicker 0.4s ease infinite;
}

/* Alert status badge */
.alert-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid;
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transition: all var(--transition-med);
}
.alert-status__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* — CLEAR — */
.alert-status--clear {
  color: var(--neon-green);
  border-color: rgba(68,255,136,0.4);
  background: rgba(68,255,136,0.06);
}
.alert-status--clear .alert-status__dot {
  background: var(--neon-green);
  box-shadow: 0 0 6px var(--neon-green);
}

/* — SUSPICIOUS — */
.alert-status--suspicious {
  color: var(--neon-yellow);
  border-color: rgba(255,221,0,0.4);
  background: rgba(255,221,0,0.06);
}
.alert-status--suspicious .alert-status__dot {
  background: var(--neon-yellow);
  box-shadow: 0 0 6px var(--neon-yellow);
  animation: neon-pulse 1.2s ease infinite;
}

/* — ALARMED — */
.alert-status--alarmed {
  color: var(--blood-orange);
  border-color: rgba(255,102,34,0.4);
  background: rgba(255,102,34,0.08);
}
.alert-status--alarmed .alert-status__dot {
  background: var(--blood-orange);
  box-shadow: var(--glow-orange);
  animation: neon-pulse 0.9s ease infinite;
}

/* — POLICE CALLED — */
.alert-status--police {
  color: var(--neon-red);
  border-color: rgba(255,34,68,0.5);
  background: rgba(255,34,68,0.1);
  animation: red-pulse 1s ease infinite;
}
.alert-status--police .alert-status__dot {
  background: var(--neon-red);
  box-shadow: var(--glow-red);
  animation: neon-pulse 0.6s ease infinite;
}

/* — LOCKDOWN — */
.alert-status--lockdown {
  color: var(--neon-red);
  border-color: var(--neon-red);
  font-size: 0.85rem;
  animation: lockdown-flash 0.5s ease infinite;
}
.alert-status--lockdown .alert-status__dot {
  background: var(--neon-red);
  box-shadow: var(--glow-red);
  animation: neon-flicker 0.3s ease infinite;
}

/* Cash secured */
.exec-cash {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--neon-green);
  text-shadow: var(--text-glow-green);
}

/* Crew HP row */
.crew-hp-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}
.crew-hp-icon {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  color: rgba(200,200,216,0.6);
}
.crew-hp-icon__portrait {
  width: 24px;
  height: 24px;
  border-radius: 3px;
  background: var(--medium-gray);
  border: 1px solid rgba(0,255,221,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
}
.crew-hp-icon__bar {
  width: 28px;
  height: 3px;
  background: var(--medium-gray);
  border-radius: 1px;
  overflow: hidden;
}
.crew-hp-icon__fill {
  height: 100%;
  background: var(--neon-green);
  border-radius: 1px;
  transition: width 0.3s ease;
}
.crew-hp-icon.downed .crew-hp-icon__portrait { opacity: 0.4; filter: grayscale(1); }
.crew-hp-icon.downed .crew-hp-icon__fill      { background: var(--neon-red); width: 0% !important; }

/* Execution body */
.exec-main {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 260px;
  overflow: hidden;
}

/* Top-down game map */
.game-map {
  position: relative;
  background: #060608;
  overflow: hidden;
}
.game-map canvas { display: block; width: 100%; height: 100%; }

/* Scanline on game map */
.game-map::after {
  content: '';
  position: absolute;
  top: -10%;
  left: 0; right: 0;
  height: 3px;
  background: linear-gradient(180deg, transparent, rgba(0,255,221,0.06), transparent);
  animation: scanline 4s linear infinite;
  pointer-events: none;
}

/* Right event log */
.event-log {
  background: var(--dark-charcoal);
  border-left: 1px solid rgba(0,255,221,0.15);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.event-log__entries {
  flex: 1;
  overflow-y: auto;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.event-entry {
  font-size: 0.68rem;
  line-height: 1.4;
  padding: 5px 8px;
  border-radius: var(--radius-sm);
  border-left: 2px solid;
  background: rgba(0,0,0,0.3);
  animation: slide-in-right 0.2s ease both;
}
.event-entry--info    { border-color: rgba(0,255,221,0.4);  color: rgba(200,200,216,0.7); }
.event-entry--success { border-color: rgba(68,255,136,0.5); color: var(--neon-green); }
.event-entry--warning { border-color: rgba(255,221,0,0.5);  color: var(--neon-yellow); }
.event-entry--danger  { border-color: rgba(255,34,68,0.6);  color: var(--neon-red); }
.event-entry--cash    { border-color: rgba(68,255,136,0.4); color: var(--neon-green); text-shadow: 0 0 6px rgba(68,255,136,0.4); }
.event-entry__time    { font-size: 0.58rem; color: rgba(200,200,216,0.3); margin-bottom: 1px; }

/* Bottom action panel */
.exec-actions {
  background: var(--dark-charcoal);
  border-top: 1px solid rgba(0,255,221,0.15);
  padding: 8px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  height: 58px;
}

.action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  cursor: pointer;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(0,255,221,0.2);
  background: rgba(0,255,221,0.03);
  transition: all var(--transition-fast);
}
.action-btn:hover {
  border-color: rgba(0,255,221,0.5);
  background: rgba(0,255,221,0.08);
  box-shadow: 0 0 10px rgba(0,255,221,0.1);
}
.action-btn:active { transform: scale(0.96); }

.action-btn__icon  { font-size: 1.1rem; line-height: 1; }
.action-btn__label {
  font-family: var(--font-header);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(200,200,216,0.5);
}
.action-btn:hover .action-btn__label { color: var(--neon-cyan); }
.action-btn.keybind::after {
  content: attr(data-key);
  font-size: 0.5rem;
  color: rgba(200,200,216,0.25);
  letter-spacing: 0.05em;
}

/* ============================================================
   SCREEN 8 — POST-HEIST RESULTS
   ============================================================ */

#screen-results {
  background: var(--bg-black);
  justify-content: center;
  align-items: center;
}

.results-dossier {
  width: 600px;
  max-width: 95vw;
  background: var(--dark-charcoal);
  border: 1px solid rgba(0,255,221,0.3);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 0 60px rgba(0,0,0,0.8), 0 0 30px rgba(0,255,221,0.05);
  animation: modal-appear 0.5s ease both;
}

/* Dossier top header */
.dossier-header {
  background: rgba(0,255,221,0.06);
  border-bottom: 1px solid rgba(0,255,221,0.2);
  padding: 20px 28px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  position: relative;
}

/* Rubber-stamp overlay */
.dossier-stamp {
  position: absolute;
  top: 16px;
  right: 24px;
  font-family: var(--font-header);
  font-weight: 900;
  font-size: 1.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transform: rotate(-12deg);
  opacity: 0.85;
  border: 3px solid;
  padding: 4px 10px;
  border-radius: 3px;
  pointer-events: none;
}
.dossier-stamp--success { color: var(--neon-green);  border-color: var(--neon-green);  text-shadow: var(--text-glow-green);  box-shadow: 0 0 12px rgba(68,255,136,0.2); }
.dossier-stamp--fail    { color: var(--neon-red);    border-color: var(--neon-red);    text-shadow: var(--text-glow-red);    box-shadow: 0 0 12px rgba(255,34,68,0.2); }

.dossier-header__icon { font-size: 3rem; line-height: 1; }
.dossier-header__info { flex: 1; }

.dossier-title {
  font-family: var(--font-header);
  font-weight: 900;
  font-size: 2rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  line-height: 1;
}
.dossier-heist-name {
  font-size: 0.75rem;
  color: rgba(200,200,216,0.5);
  margin-top: 4px;
  letter-spacing: 0.1em;
}

/* Star rating */
.dossier-rating { display: flex; gap: 4px; margin-top: 10px; }
.dossier-rating span { font-size: 1.3rem; color: rgba(200,200,216,0.15); transition: color var(--transition-med); }
.dossier-rating span.active { color: var(--neon-yellow); text-shadow: var(--text-glow-yellow); }

/* Dossier body */
.dossier-body {
  padding: 20px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Stats grid */
.dossier-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.dossier-stat {
  background: var(--bg-black);
  border: 1px solid rgba(0,255,221,0.12);
  border-radius: var(--radius-sm);
  padding: 12px;
  text-align: center;
}
.dossier-stat__value {
  font-family: var(--font-mono);
  font-size: 1.3rem;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  display: block;
  margin-bottom: 4px;
}
.dossier-stat__label {
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(200,200,216,0.4);
}

/* XP bars section */
.xp-section { display: flex; flex-direction: column; gap: 8px; }
.xp-row { display: flex; align-items: center; gap: 10px; }
.xp-row__portrait {
  width: 30px;
  height: 30px;
  border-radius: 3px;
  background: var(--medium-gray);
  border: 1px solid rgba(0,255,221,0.2);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}
.xp-row__info { flex: 1; }
.xp-row__name { font-size: 0.72rem; color: var(--white-dim); margin-bottom: 4px; }
.xp-bar-track {
  height: 8px;
  background: var(--medium-gray);
  border-radius: 3px;
  overflow: hidden;
}
.xp-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, rgba(0,255,221,0.5), var(--neon-cyan));
  border-radius: 3px;
  animation: xp-fill 1.2s cubic-bezier(0.4,0,0.2,1) both;
}
.xp-bar-fill--green  { background: linear-gradient(90deg, rgba(68,255,136,0.5),  var(--neon-green)); }
.xp-bar-fill--yellow { background: linear-gradient(90deg, rgba(255,221,0,0.5),   var(--neon-yellow)); }
.xp-bar-fill--purple { background: linear-gradient(90deg, rgba(187,68,255,0.5),  var(--neon-purple)); }
.xp-row__xp {
  font-size: 0.6rem;
  color: var(--neon-cyan);
  text-shadow: 0 0 6px rgba(0,255,221,0.5);
  white-space: nowrap;
}

/* Dossier footer */
.dossier-footer {
  padding: 16px 28px;
  border-top: 1px solid rgba(0,255,221,0.1);
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

/* ============================================================
   SCREEN 9 — MODAL OVERLAYS
   ============================================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 10, 0.85);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(3px);
}
.modal-overlay.active {
  display: flex;
  animation: fade-in 0.2s ease both;
}

.modal {
  background: var(--dark-charcoal);
  border: 1px solid rgba(0,255,221,0.35);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 0 80px rgba(0,0,0,0.9), 0 0 40px rgba(0,255,221,0.06);
  animation: modal-appear 0.3s ease both;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}
.modal--sm { width: 400px; max-width: 95vw; }
.modal--md { width: 580px; max-width: 95vw; }
.modal--lg { width: 780px; max-width: 95vw; }

.modal__header {
  padding: 16px 20px;
  background: rgba(0,255,221,0.04);
  border-bottom: 1px solid rgba(0,255,221,0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.modal__title {
  font-family: var(--font-header);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
}
.modal__close {
  cursor: pointer;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255,34,68,0.2);
  color: rgba(200,200,216,0.4);
  font-size: 0.85rem;
  transition: all var(--transition-fast);
  background: transparent;
}
.modal__close:hover {
  background: rgba(255,34,68,0.12);
  border-color: rgba(255,34,68,0.5);
  color: var(--neon-red);
}

.modal__body   { padding: 20px; overflow-y: auto; flex: 1; }
.modal__footer {
  padding: 14px 20px;
  border-top: 1px solid rgba(0,255,221,0.1);
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  flex-shrink: 0;
}

/* — Crew detail modal — */
.crew-detail-header { display: flex; gap: 16px; margin-bottom: 20px; }
.crew-detail-portrait {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-md);
  background: var(--medium-gray);
  border: 2px solid rgba(0,255,221,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  flex-shrink: 0;
}
.crew-detail-info { flex: 1; }
.crew-detail-name {
  font-family: var(--font-header);
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--white-dim);
}
.crew-detail-role {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-top: 2px;
  margin-bottom: 10px;
}
.crew-detail-bio {
  font-size: 0.7rem;
  color: rgba(200,200,216,0.55);
  line-height: 1.7;
  margin-bottom: 16px;
}

/* Full skill tree grid */
.skill-tree-full {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
}
.skill-node-full {
  background: var(--bg-black);
  border: 1px solid rgba(0,255,221,0.15);
  border-radius: var(--radius-sm);
  padding: 10px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}
.skill-node-full:hover          { border-color: rgba(0,255,221,0.4); background: rgba(0,255,221,0.04); }
.skill-node-full.unlocked       { border-color: rgba(0,255,221,0.5); background: rgba(0,255,221,0.08); }
.skill-node-full.locked         { opacity: 0.4; cursor: not-allowed; }
.skill-node-full__icon          { font-size: 1.2rem; margin-bottom: 4px; }
.skill-node-full__name          { font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--white-dim); }

/* — How to play modal — */
.how-to-play__section { margin-bottom: 18px; }
.how-to-play__section-title {
  font-family: var(--font-header);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  margin-bottom: 8px;
  padding-bottom: 5px;
  border-bottom: 1px solid rgba(0,255,221,0.15);
}
.how-to-play__text { font-size: 0.72rem; color: rgba(200,200,216,0.65); line-height: 1.75; }
.how-to-play__list { list-style: none; display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.how-to-play__list li {
  font-size: 0.7rem;
  color: rgba(200,200,216,0.6);
  padding-left: 16px;
  position: relative;
  line-height: 1.5;
}
.how-to-play__list li::before { content: '›'; position: absolute; left: 0; color: var(--neon-cyan); }

/* — Review plan modal — */
.plan-review-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.plan-review-section {
  background: var(--bg-black);
  border: 1px solid rgba(0,255,221,0.12);
  border-radius: var(--radius-sm);
  padding: 14px;
}
.plan-review-section__title {
  font-family: var(--font-header);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(0,255,221,0.6);
  margin-bottom: 10px;
}
.plan-review-list { display: flex; flex-direction: column; gap: 5px; }
.plan-review-item {
  font-size: 0.68rem;
  color: rgba(200,200,216,0.7);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.plan-review-item__key { color: rgba(200,200,216,0.4); }

/* ============================================================
   SCREEN 10 — GAME OVER / ESCAPE
   ============================================================ */

#screen-gameover {
  background: var(--bg-black);
  justify-content: center;
  align-items: center;
}

.gameover-container {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  animation: fade-in 0.6s ease both;
  position: relative;
}

/* Subtle red vignette */
.gameover-container::before {
  content: '';
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 30%, rgba(255,34,68,0.08) 100%);
  pointer-events: none;
  z-index: -1;
}

.gameover-icon {
  font-size: 5rem;
  line-height: 1;
  animation: neon-flicker 3s ease 1s infinite;
}

.gameover-title {
  font-family: var(--font-header);
  font-weight: 900;
  font-size: clamp(3rem, 8vw, 6rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--neon-red);
  text-shadow: var(--text-glow-red), 0 0 80px rgba(255,34,68,0.2);
  line-height: 1;
}
.gameover-title--escape {
  color: var(--neon-yellow);
  text-shadow: var(--text-glow-yellow), 0 0 80px rgba(255,221,0,0.2);
}

.gameover-sub {
  font-size: 0.85rem;
  color: rgba(200,200,216,0.4);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.gameover-stats {
  background: var(--dark-charcoal);
  border: 1px solid rgba(255,34,68,0.25);
  border-radius: var(--radius-md);
  padding: 20px 32px;
  display: flex;
  gap: 36px;
  text-align: center;
}
.gameover-stat__value {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  color: var(--neon-cyan);
  text-shadow: var(--text-glow-cyan);
  display: block;
}
.gameover-stat__label {
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(200,200,216,0.35);
  margin-top: 3px;
}

.gameover-actions { display: flex; gap: 12px; }

/* ============================================================
   TOOLTIP
   ============================================================ */

[data-tooltip] { position: relative; }

[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  background: rgba(10,10,20,0.95);
  border: 1px solid rgba(0,255,221,0.3);
  border-radius: var(--radius-sm);
  padding: 5px 10px;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--neon-cyan);
  text-shadow: none;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--transition-fast);
  z-index: 500;
}
[data-tooltip]:hover::after { opacity: 1; }

/* ============================================================
   INPUT ELEMENTS
   ============================================================ */

input[type="text"],
input[type="number"],
textarea,
select {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  background: var(--bg-black);
  color: var(--white-dim);
  border: 1px solid rgba(0,255,221,0.2);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  width: 100%;
}
input[type="text"]:focus,
input[type="number"]:focus,
textarea:focus,
select:focus {
  border-color: rgba(0,255,221,0.6);
  box-shadow: 0 0 0 2px rgba(0,255,221,0.08);
}

select {
  appearance: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%2300FFDD' opacity='0.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px;
}

input[type="range"] {
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--medium-gray);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
  border: none;
  padding: 0;
}
input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--neon-cyan);
  box-shadow: 0 0 6px rgba(0,255,221,0.6);
  cursor: pointer;
  transition: box-shadow var(--transition-fast);
}
input[type="range"]::-webkit-slider-thumb:hover { box-shadow: var(--glow-cyan); }

input[type="checkbox"] {
  appearance: none;
  width: 16px;
  height: 16px;
  border: 1px solid rgba(0,255,221,0.3);
  border-radius: 2px;
  background: transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}
input[type="checkbox"]:checked {
  background: rgba(0,255,221,0.2);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 6px rgba(0,255,221,0.4);
}
input[type="checkbox"]:checked::after {
  content: '✓';
  display: block;
  text-align: center;
  font-size: 0.7rem;
  color: var(--neon-cyan);
  line-height: 14px;
}

/* ============================================================
   LOADING OVERLAY + STATIC FLASH
   ============================================================ */

.loading-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-black);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.loading-overlay.active { opacity: 1; pointer-events: all; }

.loading-text {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: rgba(0,255,221,0.5);
  text-transform: uppercase;
}
.loading-text::after { content: '_'; animation: blink 1s step-end infinite; }

.loading-bar {
  width: 200px;
  height: 2px;
  background: rgba(0,255,221,0.1);
  border-radius: 1px;
  overflow: hidden;
}
.loading-bar__fill {
  height: 100%;
  background: var(--neon-cyan);
  box-shadow: 0 0 8px rgba(0,255,221,0.6);
  width: 0%;
  transition: width 0.3s ease;
}

.static-flash {
  position: fixed;
  inset: 0;
  z-index: 8999;
  pointer-events: none;
  opacity: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(255,255,255,0.03) 0px, rgba(255,255,255,0.03) 1px,
    transparent 1px, transparent 3px
  );
}
.static-flash.active { animation: static-burst 0.35s ease forwards; }

/* ============================================================
   UTILITY CLASSES
   ============================================================ */

/* Neon text colors */
.text-cyan   { color: var(--neon-cyan);    text-shadow: var(--text-glow-cyan); }
.text-red    { color: var(--neon-red);     text-shadow: var(--text-glow-red); }
.text-yellow { color: var(--neon-yellow);  text-shadow: var(--text-glow-yellow); }
.text-green  { color: var(--neon-green);   text-shadow: var(--text-glow-green); }
.text-purple { color: var(--neon-purple);  text-shadow: var(--text-glow-purple); }
.text-orange { color: var(--blood-orange); text-shadow: var(--text-glow-orange); }
.text-blue   { color: var(--blueprint-line); text-shadow: var(--text-glow-blue); }
.text-dim    { color: rgba(200,200,216,0.45); }
.text-muted  { color: rgba(200,200,216,0.25); }

/* Font families */
.text-mono   { font-family: var(--font-mono); }
.text-header { font-family: var(--font-header); text-transform: uppercase; letter-spacing: 0.1em; }

/* Animation helpers */
.anim-flicker    { animation: neon-flicker   4s ease infinite; }
.anim-pulse      { animation: neon-pulse     2s ease infinite; }
.anim-slide-left { animation: slide-in-left  0.4s ease both; }
.anim-slide-right{ animation: slide-in-right 0.4s ease both; }
.anim-slide-top  { animation: slide-in-top   0.4s ease both; }
.anim-slide-bot  { animation: slide-in-bottom 0.4s ease both; }
.anim-fade-in    { animation: fade-in        0.4s ease both; }

/* Spacing */
.mt-4  { margin-top:    4px; }
.mt-8  { margin-top:    8px; }
.mt-12 { margin-top:   12px; }
.mt-16 { margin-top:   16px; }
.mb-4  { margin-bottom: 4px; }
.mb-8  { margin-bottom: 8px; }
.mb-12 { margin-bottom:12px; }
.mb-16 { margin-bottom:16px; }
.p-8   { padding: 8px; }
.p-12  { padding: 12px; }
.p-16  { padding: 16px; }

/* Flexbox helpers */
.flex           { display: flex; }
.flex-col       { display: flex; flex-direction: column; }
.items-center   { align-items: center; }
.items-start    { align-items: flex-start; }
.justify-between{ justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end    { justify-content: flex-end; }
.gap-4          { gap: 4px; }
.gap-8          { gap: 8px; }
.gap-12         { gap: 12px; }
.gap-16         { gap: 16px; }
.flex-1         { flex: 1; }
.flex-shrink-0  { flex-shrink: 0; }
.overflow-auto  { overflow: auto; }
.overflow-y-auto{ overflow-y: auto; }
.w-full         { width: 100%; }

/* Visibility */
.hidden  { display: none !important; }
.visible { display: flex !important; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1280px) {
  .planning-layout { grid-template-columns: 220px 1fr 220px; }
}

@media (max-width: 1024px) {
  body { font-size: 0.8rem; }

  .hq-main { grid-template-columns: repeat(2, 1fr); grid-template-rows: repeat(3, 1fr); }

  .crew-layout { grid-template-columns: 1fr; grid-template-rows: 1fr 1fr; }

  .equip-layout { grid-template-columns: 1fr; }
  .loadout-sidebar { display: none; }

  .planning-layout { grid-template-columns: 1fr; grid-template-rows: auto 1fr auto; }
  .planning-crew-panel  { border-right: none; border-bottom: 1px solid rgba(0,170,255,0.3); }
  .planning-intel-panel { border-left: none;  border-top:    1px solid rgba(0,170,255,0.3); }

  .exec-main { grid-template-columns: 1fr; }
  .event-log { display: none; }

  .heist-select-layout { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .heist-sidebar       { max-height: 260px; }

  .results-dossier  { width: 95vw; }
  .dossier-stats    { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .menu-logo    { font-size: clamp(3rem, 12vw, 5rem); }
  .menu-buttons { width: 240px; }

  .hq-main { grid-template-columns: repeat(2, 1fr); padding: 10px; gap: 10px; }

  .exec-topbar { padding: 4px 10px; gap: 10px; height: auto; flex-wrap: wrap; }
  .crew-hp-bar { display: none; }

  .dossier-stats  { grid-template-columns: repeat(2, 1fr); }
  .plan-review-grid { grid-template-columns: 1fr; }

  .gameover-stats   { flex-direction: column; gap: 16px; }
  .gameover-actions { flex-direction: column; }
}

/* ============================================================
   PRINT — disabled
   ============================================================ */

@media print {
  * { display: none !important; }
}
