/* ═══════════════════════════════════════════════════════
   FLYGENIX — PRESENTATION STYLES
   Dark Neon-Tech / Retro-Futuristic Design System
═══════════════════════════════════════════════════════ */

/* ── Variables ── */
:root {
  --bg-deep:       #050A14;
  --bg-card:       #080F1E;
  --bg-surface:    #0D1628;
  --bg-elevated:   #111E35;

  --cyan:          #00D4FF;
  --cyan-dim:      #00D4FF40;
  --cyan-glow:     #00D4FF20;
  --violet:        #7B2FFF;
  --violet-dim:    #7B2FFF40;
  --violet-glow:   #7B2FFF20;
  --green:         #00FF95;
  --red:           #FF2D55;
  --orange:        #FF8C00;

  --text-primary:  #E8F4FF;
  --text-secondary:#8BA8C8;
  --text-muted:    #3D5A7A;

  --border:        #1A2E4A;
  --border-bright: #1E3A5F;

  --font-display:  'Syne', sans-serif;
  --font-body:     'Outfit', sans-serif;
  --font-mono:     'Space Mono', monospace;

  --slide-transition: 0.7s cubic-bezier(0.77, 0, 0.175, 1);
}

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

html, body {
  width: 100%; height: 100%;
  overflow: hidden;
  background: var(--bg-deep);
  color: var(--text-primary);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

/* ── Background Canvas ── */
#bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* ── HUD Top Bar ── */
.hud-bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  background: linear-gradient(180deg, #050A14f0 0%, #050A1400 100%);
  border-bottom: 1px solid var(--border);
}

.hud-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hud-icon {
  color: var(--cyan);
  font-size: 14px;
  animation: pulse-icon 2s ease-in-out infinite;
}

@keyframes pulse-icon {
  0%, 100% { opacity: 1; text-shadow: 0 0 8px var(--cyan); }
  50%       { opacity: 0.5; text-shadow: none; }
}

.hud-brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.2em;
  color: var(--text-primary);
}

.hud-sub {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.hud-right {
  display: flex;
  align-items: center;
  gap: 24px;
}

.hud-status {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--green);
  letter-spacing: 0.1em;
}

.status-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: blink 1.5s ease-in-out infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.3; }
}

.slide-counter {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
}

#current-slide-num {
  color: var(--cyan);
  font-weight: 700;
}

.counter-sep {
  margin: 0 4px;
  color: var(--text-muted);
}

/* ── Deck & Slides ── */
.deck {
  position: fixed;
  inset: 0;
  z-index: 10;
}

.slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 70px 40px 80px;
  opacity: 0;
  pointer-events: none;
  transform: translateX(60px);
  transition: opacity var(--slide-transition), transform var(--slide-transition);
}

.slide.active {
  opacity: 1;
  pointer-events: all;
  transform: translateX(0);
}

.slide.exit-left {
  opacity: 0;
  transform: translateX(-60px);
}

.slide-inner {
  width: 100%;
  max-width: 1280px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

/* ── Slide Content (Left) ── */
.slide-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.slide-tag {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.2em;
  color: var(--cyan);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 8px;
}

.slide-tag::before {
  content: '';
  display: inline-block;
  width: 24px; height: 1px;
  background: var(--cyan);
}

.slide-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(28px, 3.5vw, 46px);
  line-height: 1.1;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.gradient-text {
  background: linear-gradient(135deg, var(--cyan) 0%, var(--violet) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.slide-lead {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 480px;
}

.slide-lead strong {
  color: var(--cyan);
  font-weight: 600;
}

/* ── Problem Grid (Slide 1) ── */
.problem-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 4px;
}

.problem-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s, transform 0.3s;
}

.problem-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--red), transparent);
}

.problem-card:hover {
  border-color: var(--red);
  transform: translateY(-2px);
}

.problem-icon {
  font-size: 20px;
  margin-bottom: 8px;
}

.problem-label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 12px;
  color: var(--text-primary);
  letter-spacing: 0.05em;
  margin-bottom: 5px;
}

.problem-desc {
  font-size: 11px;
  line-height: 1.5;
  color: var(--text-muted);
}

/* ── Insight List (Slide 2) ── */
.insight-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 4px;
}

.insight-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 14px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.3s, transform 0.3s;
}

.insight-item:hover {
  border-color: var(--violet-dim);
  transform: translateX(4px);
}

.insight-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--violet);
  font-weight: 700;
  min-width: 24px;
  padding-top: 2px;
}

.insight-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.insight-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-secondary);
}

.insight-text em {
  color: var(--cyan);
  font-style: normal;
  font-weight: 500;
}

/* ── Feature Stack (Slide 3) ── */
.feature-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.feature-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.3s, transform 0.3s;
}

.feature-row:hover {
  border-color: var(--cyan-dim);
  transform: translateX(4px);
}

.feature-badge {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--bg-deep);
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  padding: 4px 8px;
  border-radius: 4px;
  min-width: 52px;
  text-align: center;
  flex-shrink: 0;
}

.feature-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-secondary);
}

/* ── Slide Visual (Right) ── */
.slide-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.visual-frame {
  width: 100%;
  max-width: 480px;
  background: var(--bg-card);
  border: 1px solid var(--border-bright);
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  box-shadow:
    0 0 0 1px var(--border),
    0 20px 60px #00000080,
    0 0 40px var(--cyan-glow);
}

.visual-frame::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), var(--violet), transparent);
  z-index: 2;
}

.visual-label {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.2em;
  color: var(--text-muted);
  padding: 10px 14px 6px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-surface);
}

.coverage-svg,
.world-svg,
.swarm-svg {
  width: 100%;
  height: auto;
  display: block;
}

/* ── Red Zone Pulse ── */
.red-zone {
  animation: red-pulse 2s ease-in-out infinite;
}

@keyframes red-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.5; }
}

/* ── Connection Lines ── */
.conn-line {
  animation: dash-flow 2s linear infinite;
}

@keyframes dash-flow {
  to { stroke-dashoffset: -20; }
}

/* ── Navigation ── */
.slide-nav {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-bright);
  border-radius: 50px;
  padding: 10px 20px;
  box-shadow: 0 8px 32px #00000060, 0 0 20px var(--cyan-glow);
}

.nav-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.15em;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 30px;
  transition: all 0.2s;
}

.nav-btn:hover:not(:disabled) {
  color: var(--cyan);
  background: var(--cyan-glow);
}

.nav-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.nav-dots {
  display: flex;
  gap: 8px;
  align-items: center;
}

.nav-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  border: 1px solid var(--text-muted);
  background: transparent;
  cursor: pointer;
  transition: all 0.3s;
  padding: 0;
}

.nav-dot.active {
  background: var(--cyan);
  border-color: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
  width: 24px;
  border-radius: 4px;
}

/* ── Progress Bar ── */
.progress-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: 2px;
  background: var(--border);
  z-index: 100;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  transition: width 0.6s cubic-bezier(0.77, 0, 0.175, 1);
  box-shadow: 0 0 8px var(--cyan);
}

/* ── Keyboard Hint ── */
.keyboard-hint {
  position: fixed;
  bottom: 10px;
  right: 24px;
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  z-index: 100;
}

/* ── Reveal Animations ── */
.reveal-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-right {
  opacity: 0;
  transform: translateX(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.slide.active .reveal-up,
.slide.active .reveal-right {
  opacity: 1;
  transform: translate(0, 0);
}

.delay-0 { transition-delay: 0.1s; }
.delay-1 { transition-delay: 0.25s; }
.delay-2 { transition-delay: 0.4s; }
.delay-3 { transition-delay: 0.55s; }

/* ── Slide-specific accent colors ── */
.slide-1 .slide-tag { color: var(--red); }
.slide-1 .slide-tag::before { background: var(--red); }
.slide-1 .visual-frame { box-shadow: 0 0 0 1px var(--border), 0 20px 60px #00000080, 0 0 40px #FF2D5515; }

.slide-2 .slide-tag { color: var(--violet); }
.slide-2 .slide-tag::before { background: var(--violet); }
.slide-2 .visual-frame { box-shadow: 0 0 0 1px var(--border), 0 20px 60px #00000080, 0 0 40px var(--violet-glow); }
.slide-2 .visual-frame::before { background: linear-gradient(90deg, var(--violet), var(--cyan), transparent); }

.slide-3 .slide-tag { color: var(--green); }
.slide-3 .slide-tag::before { background: var(--green); }
.slide-3 .visual-frame { box-shadow: 0 0 0 1px var(--border), 0 20px 60px #00000080, 0 0 40px #00FF9515; }
.slide-3 .visual-frame::before { background: linear-gradient(90deg, var(--cyan), var(--green), transparent); }

/* ── Slide number watermark ── */
.slide::after {
  content: attr(data-slide);
  position: absolute;
  bottom: 80px;
  right: 40px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 120px;
  color: #ffffff04;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--border-bright); border-radius: 2px; }