/* ==========================================================================
   DELTRON ZERO // 3030 CYBERPUNK HUD DESIGN SYSTEM
   ========================================================================== */

:root {
  --bg-deep: #05070d;
  --bg-surface: rgba(11, 17, 30, 0.75);
  --bg-card: rgba(16, 24, 44, 0.65);
  --bg-glass: rgba(20, 32, 58, 0.45);
  
  --neon-cyan: #00f0ff;
  --neon-cyan-glow: 0 0 15px rgba(0, 240, 255, 0.55), 0 0 30px rgba(0, 240, 255, 0.25);
  --neon-green: #00ff88;
  --neon-green-glow: 0 0 15px rgba(0, 255, 136, 0.55), 0 0 30px rgba(0, 255, 136, 0.25);
  --neon-amber: #ffaa00;
  --neon-amber-glow: 0 0 15px rgba(255, 170, 0, 0.55);
  --neon-magenta: #ff007f;
  --neon-magenta-glow: 0 0 15px rgba(255, 0, 127, 0.55);
  --neon-red: #ff3344;

  --border-cyan: rgba(0, 240, 255, 0.35);
  --border-green: rgba(0, 255, 136, 0.35);
  --border-amber: rgba(255, 170, 0, 0.35);
  --border-subtle: rgba(255, 255, 255, 0.08);

  --text-main: #e2e8f5;
  --text-muted: #7e8da8;
  --text-dim: #4d5b75;

  --font-display: 'Orbitron', -apple-system, sans-serif;
  --font-mono: 'Share Tech Mono', monospace;
  --font-body: 'Rajdhani', -apple-system, sans-serif;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
}

/* Reset & Base Setup */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  min-height: 100vh;
  background-color: var(--bg-deep);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}

/* Starfield / Grid Background */
.stars-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: 
    radial-gradient(ellipse at 50% 10%, rgba(0, 150, 255, 0.12), transparent 60%),
    radial-gradient(ellipse at 80% 80%, rgba(255, 0, 127, 0.08), transparent 50%),
    linear-gradient(rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.03) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 40px 40px, 40px 40px;
  pointer-events: none;
}

/* CRT Scanlines Overlay */
.crt-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.02), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.02));
  background-size: 100% 3px, 6px 100%;
  pointer-events: none;
  opacity: 0.75;
}

body.crt-off .crt-overlay {
  display: none;
}

/* HUD Master Container */
.hud-container {
  position: relative;
  z-index: 10;
  max-width: 1560px;
  margin: 0 auto;
  padding: 16px 20px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Top Telemetry Bar */
.hud-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding: 12px 20px;
  background: var(--bg-surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-md);
  box-shadow: var(--neon-cyan-glow);
}

.telemetry-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.glitch-text {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.25rem;
  letter-spacing: 2px;
  color: var(--neon-cyan);
  text-shadow: var(--neon-cyan-glow);
}

.sub-brand {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 1.5px;
  color: var(--neon-green);
}

.live-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 255, 136, 0.12);
  border: 1px solid var(--border-green);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}

.pulse-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--neon-green);
  box-shadow: 0 0 10px var(--neon-green);
  animation: livePulse 1.4s infinite ease-in-out;
}

@keyframes livePulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.4; }
}

.status-label {
  color: var(--neon-green);
  font-weight: 700;
  letter-spacing: 1px;
}

.meta-label {
  color: var(--text-muted);
}

.meta-val {
  color: var(--neon-cyan);
  font-weight: 700;
}

.crt-switch-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.crt-label {
  color: var(--text-muted);
  font-size: 0.8rem;
  cursor: pointer;
}

#crt-toggle {
  cursor: pointer;
  accent-color: var(--neon-cyan);
}

/* Main HUD Workspace */
.hud-main {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 16px;
  flex: 1;
}

@media (max-width: 1080px) {
  .hud-main {
    grid-template-columns: 1fr;
  }
}

.hud-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Track Info Card */
.track-info-card {
  padding: 16px 20px;
  background: var(--bg-surface);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-md);
}

.track-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 8px;
}

.badge-section {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 3px 8px;
  background: rgba(0, 240, 255, 0.15);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  color: var(--neon-cyan);
}

.badge-bpm {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 3px 8px;
  background: rgba(255, 170, 0, 0.15);
  border: 1px solid var(--border-amber);
  border-radius: var(--radius-sm);
  color: var(--neon-amber);
}

.badge-verses {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 3px 8px;
  background: rgba(0, 255, 136, 0.15);
  border: 1px solid var(--border-green);
  border-radius: var(--radius-sm);
  color: var(--neon-green);
}

.badge-engine {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 3px 10px;
  background: rgba(0, 255, 136, 0.12);
  border: 1px solid var(--border-green);
  border-radius: var(--radius-sm);
  color: var(--neon-green);
  letter-spacing: 0.5px;
  transition: all 0.3s;
}

.badge-engine.active-llm {
  background: rgba(255, 0, 127, 0.25);
  border-color: var(--neon-magenta);
  color: #ff55bb;
  box-shadow: 0 0 14px rgba(255, 0, 127, 0.6);
  font-weight: 800;
  animation: llmBadgePulse 2s infinite ease-in-out;
}

@keyframes llmBadgePulse {
  0%, 100% { box-shadow: 0 0 6px rgba(255, 0, 127, 0.4); }
  50% { box-shadow: 0 0 16px rgba(255, 0, 127, 0.9); }
}

.badge-history-ai {
  color: #ff55bb;
  background: rgba(255, 0, 127, 0.18);
  border: 1px solid var(--neon-magenta);
  font-size: 0.72rem;
  padding: 1px 6px;
  border-radius: 3px;
  margin-left: 6px;
  font-weight: 700;
  text-shadow: 0 0 6px rgba(255, 0, 127, 0.4);
}

.badge-history-offline {
  color: var(--neon-cyan);
  background: rgba(0, 240, 255, 0.12);
  border: 1px solid var(--border-cyan);
  font-size: 0.72rem;
  padding: 1px 6px;
  border-radius: 3px;
  margin-left: 6px;
}

.track-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: #fff;
  text-shadow: 0 0 10px rgba(0, 240, 255, 0.4);
}

/* Prominent Over-Rap AI Mode Banner */
.ai-mode-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: rgba(11, 24, 40, 0.85);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.15);
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.ai-mode-banner.llm-mode {
  background: linear-gradient(90deg, rgba(35, 10, 30, 0.9) 0%, rgba(20, 10, 35, 0.9) 100%);
  border: 1px solid var(--neon-magenta);
  box-shadow: 0 0 20px rgba(255, 0, 127, 0.35), inset 0 0 15px rgba(255, 0, 127, 0.15);
}

.banner-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.banner-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--neon-cyan);
  box-shadow: 0 0 8px var(--neon-cyan);
  display: inline-block;
  animation: pulseAiDot 1.5s infinite ease-in-out;
}

.ai-mode-banner.llm-mode .banner-dot {
  background: var(--neon-magenta);
  box-shadow: 0 0 12px var(--neon-magenta);
}

@keyframes pulseAiDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.5; }
}

.banner-title {
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--neon-cyan);
}

.ai-mode-banner.llm-mode .banner-title {
  color: #ff55aa;
  text-shadow: 0 0 10px rgba(255, 0, 127, 0.5);
}

.banner-meta {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.ai-mode-banner.llm-mode .banner-meta {
  color: #ff99cc;
}

/* Audio Deck & Turntable Platter */
.audio-deck {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 16px;
  padding: 16px;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  align-items: center;
}

@media (max-width: 580px) {
  .audio-deck {
    grid-template-columns: 1fr;
    justify-items: center;
  }
}

.deck-platter {
  position: relative;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: #020408;
  border: 3px solid #1e293b;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.8), inset 0 0 15px rgba(0, 240, 255, 0.15);
}

.turntable-vinyl {
  width: 144px;
  height: 144px;
  border-radius: 50%;
  background: radial-gradient(circle, #1a1a24 0%, #0d0e14 45%, #181922 75%, #050608 100%);
  position: relative;
  animation: spinRecord 1.8s linear infinite;
  box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.05);
}

@keyframes spinRecord {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.vinyl-grooves {
  position: absolute;
  inset: 10px;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.1);
}

.vinyl-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: radial-gradient(circle, #ff007f 0%, #7b003c 100%);
  border: 2px solid var(--neon-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
}

.center-label {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 0.75rem;
  color: #fff;
  letter-spacing: 1px;
}

.tonearm {
  position: absolute;
  top: 10px;
  right: -5px;
  width: 14px;
  height: 70px;
  background: linear-gradient(90deg, #94a3b8, #475569);
  transform: rotate(28deg);
  transform-origin: top center;
  border-radius: 3px;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.deck-visualizer-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.vis-header {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--neon-green);
  letter-spacing: 1px;
}

.vis-mode {
  color: var(--text-muted);
}

#visualizer-canvas {
  width: 100%;
  height: 120px;
  background: rgba(3, 7, 18, 0.95);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  box-shadow: inset 0 0 15px rgba(0, 240, 255, 0.1);
}

/* Master Teleprompter / Lyric Display */
.teleprompter-card {
  background: var(--bg-surface);
  backdrop-filter: blur(12px);
  border: 2px solid var(--neon-cyan);
  border-radius: var(--radius-md);
  box-shadow: var(--neon-cyan-glow);
  padding: 18px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 200px;
}

.teleprompter-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--neon-cyan);
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 8px;
}

.speaker-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  letter-spacing: 1px;
}

.teleprompter-status {
  color: var(--neon-green);
}

/* Master Stanza Teleprompter */
.verse-teleprompter {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 280px;
  overflow-y: auto;
  padding: 8px 12px;
  background: rgba(3, 7, 18, 0.9);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}

/* Custom Teleprompter Scrollbar */
.verse-teleprompter::-webkit-scrollbar {
  width: 6px;
}
.verse-teleprompter::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.4);
}
.verse-teleprompter::-webkit-scrollbar-thumb {
  background: var(--border-cyan);
  border-radius: 3px;
}

.intro-placeholder {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--text-muted);
  text-align: center;
  padding: 30px 10px;
}

.teleprompter-line {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border-left: 3px solid transparent;
  transition: all 0.2s ease;
  font-family: var(--font-body);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.4;
  color: #64748b;
}

.teleprompter-line .line-num {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: #475569;
  min-width: 32px;
  margin-top: 4px;
}

.teleprompter-line .line-content {
  flex: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
}

/* Active Spoken Line */
.teleprompter-line.active {
  color: #fff;
  background: rgba(0, 240, 255, 0.08);
  border-left: 3px solid var(--neon-cyan);
  box-shadow: inset 0 0 15px rgba(0, 240, 255, 0.12);
  transform: translateX(4px);
}

.teleprompter-line.active .line-num {
  color: var(--neon-cyan);
  font-weight: 700;
}

/* Active Word Karaoke Highlight */
.teleprompter-line.active .word.active {
  color: #000;
  background: var(--neon-green);
  box-shadow: 0 0 14px var(--neon-green), 0 0 24px var(--neon-green);
  border-radius: var(--radius-sm);
  padding: 2px 6px;
  transform: scale(1.08);
  font-weight: 900;
}

.teleprompter-line.active .word.passed {
  color: var(--neon-cyan);
}

.teleprompter-line.passed {
  color: #94a3b8;
  opacity: 0.75;
}

.teleprompter-line.passed .line-num {
  color: #334155;
}

/* Transport Controls */
.transport-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
  text-transform: uppercase;
}

.btn-primary {
  background: linear-gradient(135deg, #00f0ff 0%, #0088ff 100%);
  color: #000;
  box-shadow: var(--neon-cyan-glow);
  font-weight: 800;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.8);
}

.btn-secondary {
  background: var(--bg-surface);
  border: 1px solid var(--border-cyan);
  color: var(--neon-cyan);
}

.btn-secondary:hover {
  background: rgba(0, 240, 255, 0.15);
  transform: translateY(-2px);
}

.btn-accent {
  background: linear-gradient(135deg, #00ff88 0%, #00b359 100%);
  color: #000;
  font-weight: 800;
  box-shadow: var(--neon-green-glow);
}

.btn-accent:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(0, 255, 136, 0.8);
}

.btn-danger {
  background: linear-gradient(135deg, #ff007f 0%, #ff3344 100%);
  color: #fff;
  box-shadow: var(--neon-magenta-glow);
  width: 100%;
}

.btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(255, 0, 127, 0.8);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
}

.btn-outline:hover {
  border-color: var(--border-cyan);
  color: var(--text-main);
}

.btn-outline.active {
  background: rgba(255, 51, 68, 0.2);
  border-color: var(--neon-red);
  color: var(--neon-red);
}

/* AI Neural Core Box */
.ai-core-box {
  border: 1px solid var(--border-amber);
  background: rgba(25, 20, 10, 0.45);
}

.ai-status-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 750;
  padding: 2px 8px;
  background: rgba(0, 255, 136, 0.15);
  border: 1px solid var(--border-green);
  border-radius: var(--radius-sm);
  color: var(--neon-green);
  letter-spacing: 1px;
}

.ai-status-badge.active-llm {
  background: rgba(255, 0, 127, 0.2);
  border-color: var(--neon-magenta);
  color: var(--neon-magenta);
  box-shadow: 0 0 10px rgba(255, 0, 127, 0.4);
}

.ai-active-info {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: #00ff88;
  background: rgba(0, 255, 136, 0.12);
  border: 1px solid var(--border-green);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  line-height: 1.4;
  animation: fadeIn 0.3s ease;
}

.ai-diagnostic-box {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ai-diagnostic-box.success {
  border-color: var(--neon-green);
  background: rgba(0, 255, 136, 0.08);
}

.ai-diagnostic-box.error {
  border-color: var(--neon-red);
  background: rgba(255, 51, 68, 0.1);
}

.diag-label {
  color: var(--neon-amber);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.5px;
}

.diag-text {
  color: #e2e8f0;
  word-break: break-word;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.ai-hint {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Control Boxes (Right Column) */
.control-box {
  padding: 16px;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.box-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--neon-cyan);
  letter-spacing: 1px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 6px;
}

.box-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Freestyle Input Group */
.input-group {
  display: flex;
  gap: 8px;
}

.input-group input {
  flex: 1;
  background: rgba(3, 7, 18, 0.85);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: #fff;
  font-family: var(--font-body);
  font-size: 1.05rem;
  outline: none;
  transition: all 0.2s;
}

.input-group input:focus {
  border-color: var(--neon-green);
  box-shadow: 0 0 10px rgba(0, 255, 136, 0.4);
}

/* Synthesizer Matrix */
.matrix-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 500px) {
  .matrix-grid {
    grid-template-columns: 1fr;
  }
}

.matrix-field, .slider-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.matrix-field label, .slider-field label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

select {
  background: rgba(3, 7, 18, 0.9);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  color: var(--neon-cyan);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  outline: none;
  cursor: pointer;
}

select:focus {
  border-color: var(--neon-green);
}

.sliders-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
}

@media (max-width: 768px) {
  .sliders-grid {
    grid-template-columns: 1fr;
  }
}

.slider-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.slider-val-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--neon-cyan);
  font-weight: 700;
}

input[type="range"] {
  accent-color: var(--neon-green);
  cursor: pointer;
}

/* Scratch & FX Pads */
.hotkeys-hint {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--neon-amber);
}

.pads-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.pad-btn {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  padding: 10px 6px;
  color: #fff;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: all 0.1s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.pad-btn:hover {
  background: rgba(0, 240, 255, 0.15);
  border-color: var(--neon-green);
}

.pad-btn.pressed, .pad-btn:active {
  background: var(--neon-green);
  color: #000;
  box-shadow: 0 0 20px var(--neon-green);
  transform: translateY(2px) scale(0.96);
}

.pad-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--neon-amber);
}

.pad-btn.pressed .pad-num {
  color: #000;
}

.pad-label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

/* History Archive Log */
.archive-actions {
  display: flex;
  gap: 6px;
}

.btn-micro {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 2px 8px;
  background: transparent;
  border: 1px solid var(--border-cyan);
  color: var(--neon-cyan);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-micro:hover {
  background: rgba(0, 240, 255, 0.2);
}

.history-log {
  max-height: 180px;
  overflow-y: auto;
  padding: 10px 12px;
  background: rgba(2, 6, 18, 0.95);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Custom Scrollbar */
.history-log::-webkit-scrollbar {
  width: 6px;
}
.history-log::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.4);
}
.history-log::-webkit-scrollbar-thumb {
  background: var(--border-cyan);
  border-radius: 3px;
}

.history-track-header {
  color: var(--neon-amber);
  border-bottom: 1px dashed rgba(255, 170, 0, 0.3);
  padding-bottom: 4px;
  margin-top: 6px;
  display: flex;
  justify-content: space-between;
}

.history-track-header .time {
  color: var(--text-muted);
  font-size: 0.75rem;
}

.history-line {
  color: #cbd5e1;
  line-height: 1.4;
}

/* Footer */
.hud-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

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

.hud-footer a:hover {
  text-decoration: underline;
}

/* Boot Modal Backdrop */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(2, 6, 18, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.modal-backdrop.hidden {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  display: none !important;
}

.modal-card {
  max-width: 580px;
  width: 100%;
  background: rgba(10, 18, 35, 0.95);
  border: 2px solid var(--neon-cyan);
  border-radius: var(--radius-lg);
  box-shadow: 0 0 50px rgba(0, 240, 255, 0.35);
  padding: 36px 30px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.modal-logo {
  font-size: 2.5rem;
  letter-spacing: 4px;
}

.modal-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.8rem;
  letter-spacing: 2px;
  color: var(--neon-cyan);
  text-shadow: var(--neon-cyan-glow);
}

.modal-badge {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--neon-green);
  background: rgba(0, 255, 136, 0.15);
  border: 1px solid var(--border-green);
  padding: 4px 14px;
  border-radius: var(--radius-sm);
}

.modal-terminal-text {
  background: rgba(2, 6, 18, 0.9);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  text-align: left;
  width: 100%;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #94a3b8;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.modal-terminal-text .term-line.highlight {
  color: var(--neon-amber);
  font-weight: 700;
}

.modal-access-box {
  width: 100%;
  background: rgba(4, 9, 24, 0.85);
  border: 1px solid var(--border-amber);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.modal-access-label {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--neon-amber);
}

.modal-access-input-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-access-input-wrap input {
  flex: 1;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--border-cyan);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  color: var(--neon-cyan);
  font-family: var(--font-mono);
  font-size: 1rem;
  letter-spacing: 2px;
}

.modal-access-input-wrap input:focus {
  outline: none;
  border-color: var(--neon-green);
  box-shadow: 0 0 12px rgba(0, 255, 136, 0.4);
}

.access-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  background: rgba(0, 255, 136, 0.2);
  border: 1px solid var(--border-green);
  color: var(--neon-green);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.modal-access-hint {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

.btn-launch {
  width: 100%;
  padding: 16px 24px;
  font-size: 1.05rem;
  font-weight: 900;
  background: linear-gradient(135deg, #00f0ff 0%, #00ff88 100%);
  color: #000;
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.6);
  border: none;
  cursor: pointer;
  border-radius: var(--radius-sm);
  letter-spacing: 1.5px;
}

.btn-launch:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(0, 255, 136, 0.9);
}

.modal-hint {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}
