/* ================================================================
   DIGITAL TWIN EXPERIENCE — Landing Page Theme
   Configurable via landing-config.json per twin
   ================================================================ */

/* ── CUSTOM PROPERTIES ───────────────────────────────────────── */
:root {
  /* Core palette */
  --bg-deep:        #050208;
  --bg-dark:        #0a0514;
  --bg-card:        rgba(12, 6, 24, 0.85);
  --bg-glass:       rgba(255, 255, 255, 0.04);

  /* Brand accents — overridden per twin via landing-config.json */
  --accent-primary:    #D22026;          /* Twin brand color */
  --accent-secondary:  #FFD700;          /* Gold — secondary accent */
  --accent-neon:       #FF4D52;          /* Neon glow variant */
  --accent-cyan:       #22FFFF;          /* Tech/Digital Twin highlight */
  --accent-purple:     #8B5CF6;          /* Deep purple accent */
  --accent-magenta:    #E040FB;          /* Heritage magenta */

  /* Alpha variants of accent-primary (generated from brand color) */
  --accent-primary-10: rgba(210, 32, 38, 0.1);
  --accent-primary-15: rgba(210, 32, 38, 0.15);
  --accent-primary-20: rgba(210, 32, 38, 0.2);
  --accent-primary-25: rgba(210, 32, 38, 0.25);
  --accent-primary-30: rgba(210, 32, 38, 0.3);
  --accent-primary-35: rgba(210, 32, 38, 0.35);
  --accent-primary-40: rgba(210, 32, 38, 0.4);
  --accent-primary-50: rgba(210, 32, 38, 0.5);
  --accent-primary-70: rgba(210, 32, 38, 0.7);
  --accent-primary-90: rgba(210, 32, 38, 0.9);
  --accent-primary-dark: #8B1A1E;       /* Darker shade for gradients */
  --accent-primary-darker: #a8181d;     /* Mid-dark shade */

  /* Gradients */
  --grad-hero:      linear-gradient(135deg, #1a0a2e 0%, #0d0221 30%, #150a30 60%, #1a0520 100%);
  --grad-red:       linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-primary-dark) 50%, #4A0D10 100%);
  --grad-gold:      linear-gradient(135deg, #FFD700 0%, #FFA500 50%, #FF6B00 100%);
  --grad-glass:     linear-gradient(135deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.02) 100%);
  --grad-section:   linear-gradient(180deg, var(--bg-deep) 0%, #0f0625 50%, var(--bg-deep) 100%);

  /* Splash colors (decorative paint strokes) */
  --splash-red:     var(--accent-primary-30);
  --splash-gold:    rgba(255, 215, 0, 0.2);
  --splash-purple:  rgba(139, 92, 246, 0.25);
  --splash-magenta: rgba(224, 64, 251, 0.2);

  /* Text */
  --text-primary:   #FAFAFA;
  --text-secondary: rgba(255, 255, 255, 0.65);
  --text-muted:     rgba(255, 255, 255, 0.4);

  /* Fonts */
  --font-display:   'Bebas Neue', 'Oswald', sans-serif;
  --font-heading:   'Oswald', sans-serif;
  --font-body:      'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:      'Source Code Pro', 'Fira Code', monospace;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 5rem;

  /* Shadows */
  --shadow-glow-red:  0 0 40px var(--accent-primary-40), 0 0 80px var(--accent-primary-20);
  --shadow-glow-gold: 0 0 40px rgba(255, 215, 0, 0.3), 0 0 80px rgba(255, 215, 0, 0.15);
  --shadow-glow-cyan: 0 0 40px rgba(34, 255, 255, 0.3), 0 0 80px rgba(34, 255, 255, 0.15);
  --shadow-glass:     0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-widget:    0 4px 40px var(--accent-primary-35) inset,
                      0 4px 60px rgba(255, 255, 255, 0.15),
                      0 4px 80px var(--accent-primary-30),
                      0 60px 100px rgba(5, 2, 8, 0.8);

  /* Radius */
  --radius-sm: 0.5rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 2rem;
  --radius-full: 9999px;

  /* Transitions */
  --ease-out-expo: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-bounce:   cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
  scroll-padding-bottom: 44px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background: var(--bg-deep);
  color: var(--text-primary);
  overflow-x: hidden;
  line-height: 1.6;
  padding-bottom: 0;
}

a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }
img, video { display: block; max-width: 100%; }

/* ── SHADER CANVAS (full-page background) ────────────────────── */
#shader-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  opacity: 0.6;
}

/* ── SECTION BASE ────────────────────────────────────────────── */
.section {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3xl) var(--space-xl);
  scroll-snap-align: start;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-secondary);
  margin-bottom: var(--space-lg);
  opacity: 0.8;
}

.tag-center { text-align: center; display: block; }

.section-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 7rem);
  line-height: 0.95;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: var(--space-xl);
}

.section-title em {
  font-style: normal;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-title .title-small {
  font-size: 0.5em;
  letter-spacing: 0.15em;
  color: var(--text-muted);
}

.title-center { text-align: center; }

.section-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 580px;
  margin-bottom: var(--space-lg);
  line-height: 1.7;
}

/* ── NAV ─────────────────────────────────────────────────────── */
#main-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: var(--space-md) var(--space-xl);
  background: rgba(5, 2, 8, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background 0.4s ease, padding 0.4s ease;
}

#main-nav.scrolled {
  background: rgba(5, 2, 8, 0.95);
  padding: var(--space-sm) var(--space-xl);
}

.nav-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.logo-fdp { color: var(--accent-primary); }
.logo-sep { color: var(--text-muted); font-size: 0.6em; }
.logo-radio { color: var(--text-primary); }

.nav-links {
  display: flex;
  gap: var(--space-xl);
}

.nav-links a {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color 0.3s ease;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-primary);
  transition: width 0.3s var(--ease-out-expo);
}

.nav-links a:hover { color: var(--text-primary); }
.nav-links a:hover::after { width: 100%; }

.nav-lang {
  display: flex;
  gap: var(--space-xs);
}

.nav-lang button {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  padding: 0.3rem 0.6rem;
  border-radius: var(--radius-full);
  color: var(--text-muted);
  transition: all 0.3s ease;
}

.nav-lang .lang-active {
  background: var(--accent-primary);
  color: white;
}

/* ── HERO ────────────────────────────────────────────────────── */
.hero {
  min-height: calc(100vh - 44px); /* full viewport minus ticker height */
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-video-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5,2,8,0.4) 0%, rgba(5,2,8,0.2) 40%, rgba(5,2,8,0.7) 80%, var(--bg-deep) 100%),
    linear-gradient(90deg, rgba(26,10,46,0.6) 0%, transparent 50%, rgba(26,10,46,0.6) 100%);
}

.hero-shader-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  padding: 0 var(--space-xl);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  padding: 0.5rem 1.2rem;
  background: var(--accent-primary-15);
  border: 1px solid var(--accent-primary-30);
  border-radius: var(--radius-full);
  color: var(--accent-neon);
  margin-bottom: var(--space-xl);
}

.badge-dot {
  width: 8px;
  height: 8px;
  background: var(--accent-primary);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 var(--accent-primary-70); }
  50% { box-shadow: 0 0 0 8px transparent; }
}

/* Anti-FOUC: hero elements start hidden, GSAP reveals them */
.hero-badge,
.title-the,
.title-name,
.title-accent,
.hero-sub,
.hero-desc {
  opacity: 0;
}

/* Hero title — dramatic stacked display */
.hero-title {
  font-family: var(--font-display);
  line-height: 0.88;
  margin-bottom: var(--space-lg);
}

.title-line {
  display: block;
  overflow: hidden;
}

.title-the {
  font-size: clamp(2rem, 4vw, 3.5rem);
  color: var(--text-secondary);
  letter-spacing: 0.3em;
}

.title-name {
  font-size: clamp(5rem, 14vw, 12rem);
  color: var(--text-primary);
  letter-spacing: 0.02em;
  text-shadow: 0 0 60px var(--accent-primary-40);
  overflow: visible;
  padding-top: 0.1em; /* room for the Á accent */
}

.title-accent {
  font-size: clamp(2.5rem, 6vw, 5rem);
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.15em;
}

.hero-sub {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2vw, 1.4rem);
  letter-spacing: 0.3em;
  color: var(--accent-secondary);
  margin-bottom: var(--space-lg);
}

.hero-desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  line-height: 1.7;
  margin-bottom: var(--space-2xl);
}

/* CTA Buttons */
.hero-ctas {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0.9rem 2rem;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border-radius: var(--radius-full);
  transition: all 0.4s var(--ease-out-expo);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--accent-primary);
  color: white;
  border: 2px solid var(--accent-primary);
}

.btn-primary:hover {
  background: transparent;
  color: var(--accent-neon);
  box-shadow: var(--shadow-glow-red);
  transform: translateY(-2px);
}

.btn-glow::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  z-index: -1;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.btn-glow:hover::before { opacity: 0.7; }

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-ghost:hover {
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-2px);
}

.btn-icon {
  font-size: 0.7em;
}

/* Hero CTA buttons — own entrance, immune to GSAP hero fade */
#hero-talk-btn,
#hero-slides-btn {
  opacity: 0;
  animation: hero-btn-in 0.8s ease-out 1.8s forwards;
}
#hero-slides-btn {
  animation-delay: 1.95s;
}
@keyframes hero-btn-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Hero Talk Button — waveform bars */
.hero-talk-btn { cursor: pointer; }
.hero-talk-waves {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 16px;
}
.htw-bar {
  display: inline-block;
  width: 3px;
  height: 8px;
  background: currentColor;
  border-radius: 2px;
  animation: htw-pulse 1.2s ease-in-out infinite;
}
.htw-bar:nth-child(1) { animation-delay: 0s; }
.htw-bar:nth-child(2) { animation-delay: 0.15s; }
.htw-bar:nth-child(3) { animation-delay: 0.3s; }
.htw-bar:nth-child(4) { animation-delay: 0.45s; }
.htw-bar:nth-child(5) { animation-delay: 0.6s; }

@keyframes htw-pulse {
  0%, 100% { height: 4px; opacity: 0.6; }
  50% { height: 14px; opacity: 1; }
}

/* Hero Slides Button */
.hero-slides-btn { cursor: pointer; }
.hero-slides-icon { flex-shrink: 0; }

/* Decorative splashes */
.hero-splash {
  position: absolute;
  z-index: 1;
  pointer-events: none;
  border-radius: 50%;
  filter: blur(80px);
}

.splash-1 {
  width: 400px;
  height: 400px;
  background: var(--splash-red);
  top: -10%;
  right: -5%;
}

.splash-2 {
  width: 300px;
  height: 300px;
  background: var(--splash-purple);
  bottom: 10%;
  left: -5%;
}

.splash-3 {
  width: 250px;
  height: 250px;
  background: var(--splash-gold);
  top: 40%;
  right: 10%;
}

/* ── STATS BAR ───────────────────────────────────────────────── */
.stats-bar {
  min-height: auto;
  padding: var(--space-xl) var(--space-xl);
  background: linear-gradient(135deg,
    var(--accent-primary) 0%,
    var(--accent-primary-dark) 40%,
    var(--accent-purple) 100%
  );
  position: relative;
  z-index: 2;
}

.stats-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
  text-align: center;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.stat-icon {
  width: 48px;
  height: 48px;
  color: rgba(255, 255, 255, 0.8);
}

.stat-icon svg {
  width: 100%;
  height: 100%;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 3.5rem;
  color: white;
  line-height: 1;
}

.stat-label, .stat-label-only {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.4;
}

.stat-label-only {
  font-size: 1rem;
  margin-top: var(--space-sm);
}

/* ── EXPERIENCE + TWIN (inline inside hero — 2-section layout) ─ */
.experience-twin-inline {
  position: relative;
  width: 100%;
  padding-top: var(--space-xl);
}

.et-grid {
  flex: 1;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-xl);
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  align-items: center;
}

.stats-bar-inline {
  width: 100%;
  flex-shrink: 0;
  padding: var(--space-md) var(--space-xl) calc(var(--space-md) + 56px);
  background: linear-gradient(135deg,
    var(--accent-primary) 0%,
    var(--accent-primary-dark) 40%,
    var(--accent-purple) 100%
  );
}

.et-text {
  padding-top: 0;
}

.et-text .section-desc {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: var(--space-lg);
}

.et-widget {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
  border-radius: var(--radius-xl);
  padding: var(--space-xl) var(--space-md) var(--space-lg);
  background: radial-gradient(ellipse at center, rgba(26,10,46,0.4) 0%, transparent 70%);
}

.et-widget-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 0.95;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
  text-align: center;
}

.et-widget-title em {
  font-style: normal;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.et-widget-title .title-small {
  font-size: 0.5em;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  -webkit-text-fill-color: var(--text-muted);
}

/* Legacy classes kept for unused page variants */
.exp-content {
  max-width: 1200px;
  margin: 0 auto;
}

.exp-text-block {
  margin-bottom: var(--space-3xl);
}

.exp-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-lg);
}

.exp-card {
  background: var(--grad-glass);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl) var(--space-xl);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.4s var(--ease-out-expo);
  position: relative;
  overflow: hidden;
}

.exp-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--accent-primary-10) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.exp-card:hover {
  border-color: var(--accent-primary-30);
  transform: translateY(-4px);
  box-shadow: 0 20px 60px var(--accent-primary-15);
}

.exp-card:hover::before { opacity: 1; }

.card-number {
  font-family: var(--font-display);
  font-size: 3rem;
  color: var(--accent-primary-20);
  line-height: 1;
  margin-bottom: var(--space-md);
}

.card-icon {
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-md);
  border-radius: var(--radius-md);
  background: var(--accent-primary-15);
  border: 1px solid var(--accent-primary-20);
  position: relative;
}

/* Icon abstractions */
.card-icon::after {
  content: '';
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  background: var(--accent-primary);
  opacity: 0.6;
}

.card-icon-voice::after { border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; }
.card-icon-avatar::after { border-radius: 50%; }
.card-icon-knowledge::after { border-radius: 4px; }
.card-icon-tech::after { border-radius: 2px; transform: rotate(45deg); }

.exp-card h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.exp-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ── DIGITAL TWIN (inside et-widget) ─────────────────────────── */
.twin-bg-particles {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.twin-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* ── THE WIDGET ──────────────────────────────────────────────── */
.twin-widget {
  width: 100%;
  max-width: 700px;
  border-radius: var(--radius-xl);
  border: 2px solid var(--accent-primary);
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-widget);
  overflow: hidden;
  transition: all 0.6s var(--ease-out-expo);
}

.twin-widget:hover {
  border-color: var(--accent-neon);
  box-shadow:
    0 4px 40px rgba(255, 77, 82, 0.4) inset,
    0 4px 60px rgba(255, 255, 255, 0.2),
    0 4px 100px rgba(255, 77, 82, 0.35),
    0 60px 100px rgba(5, 2, 8, 0.8);
}

/* Portrait area — the "painting" canvas */
.widget-portrait {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #0a0514;
  overflow: hidden;
}

#portrait-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

#orb-container {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.portrait-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    transparent 60%,
    rgba(12, 6, 24, 0.6) 80%,
    rgba(12, 6, 24, 0.95) 100%
  );
  pointer-events: none;
}

/* Widget status */
.widget-status {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0.4rem 1rem;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-secondary);
  animation: pulse-dot 2s ease-in-out infinite;
}

/* Waveform (speaking indicator overlay) */
.widget-waveform {
  display: none;  /* Replaced by SiriWave visualizer in #orb-container */
}

.widget-waveform.active { opacity: 1; }

.wave-bar {
  width: 3px;
  height: 10px;
  background: var(--accent-primary);
  border-radius: 2px;
  animation: wave-speak 0.8s ease-in-out infinite;
  opacity: 0.7;
}

.wave-bar:nth-child(1)  { animation-delay: 0.0s; height: 12px; }
.wave-bar:nth-child(2)  { animation-delay: 0.05s; height: 18px; }
.wave-bar:nth-child(3)  { animation-delay: 0.1s; height: 24px; }
.wave-bar:nth-child(4)  { animation-delay: 0.15s; height: 30px; }
.wave-bar:nth-child(5)  { animation-delay: 0.2s; height: 36px; }
.wave-bar:nth-child(6)  { animation-delay: 0.25s; height: 40px; }
.wave-bar:nth-child(7)  { animation-delay: 0.3s; height: 36px; }
.wave-bar:nth-child(8)  { animation-delay: 0.35s; height: 30px; }
.wave-bar:nth-child(9)  { animation-delay: 0.4s; height: 36px; }
.wave-bar:nth-child(10) { animation-delay: 0.45s; height: 40px; }
.wave-bar:nth-child(11) { animation-delay: 0.5s; height: 36px; }
.wave-bar:nth-child(12) { animation-delay: 0.55s; height: 30px; }
.wave-bar:nth-child(13) { animation-delay: 0.6s; height: 24px; }
.wave-bar:nth-child(14) { animation-delay: 0.65s; height: 18px; }
.wave-bar:nth-child(15) { animation-delay: 0.7s; height: 12px; }
.wave-bar:nth-child(16) { animation-delay: 0.75s; height: 8px; }

@keyframes wave-speak {
  0%, 100% { transform: scaleY(0.4); opacity: 0.4; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* Widget controls */
.widget-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  padding: var(--space-lg) var(--space-xl);
  background: rgba(0, 0, 0, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.widget-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  transition: all 0.3s var(--ease-out-expo);
  backdrop-filter: blur(10px);
}

.widget-btn svg {
  width: 20px;
  height: 20px;
}

/* Mode selector buttons (voice / avatar) — left side */
.btn-mode {
  gap: var(--space-xs);
  padding: 0.5rem 1.2rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
}

.btn-mode:hover {
  background: var(--accent-primary-20);
  border-color: var(--accent-primary);
  color: var(--text-secondary);
}

.btn-mode.active {
  background: rgba(34, 197, 94, 0.2);
  border-color: #22c55e;
  color: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

.btn-mode:disabled,
.btn-mode[disabled] {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  box-shadow: none;
}

.btn-mode-label {
  pointer-events: none;
}

/* CONVERSAR / DETENER button — pushed to far right, shrinks to fit */
.btn-talk {
  gap: var(--space-sm);
  padding: 0.65rem 1.4rem;
  margin-left: auto;
  background: var(--accent-primary);
  border: 2px solid var(--accent-primary);
  font-family: var(--font-heading);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  color: white;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-talk:hover {
  background: transparent;
  color: var(--accent-neon);
  box-shadow: var(--shadow-glow-red);
  transform: scale(1.05);
}

.talk-icon { font-size: 0.7em; }

/* Transcript — collapsible, hidden by default */
.widget-transcript-wrap {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: none;
}
.widget-transcript-wrap.active { display: block; }

.transcript-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 5px var(--space-xl);
  background: rgba(0, 0, 0, 0.3);
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.3);
  text-transform: uppercase;
  transition: color 0.2s, background 0.2s;
}
.transcript-toggle:hover {
  color: rgba(255, 255, 255, 0.55);
  background: rgba(0, 0, 0, 0.4);
}
.transcript-toggle .toggle-arrow {
  font-size: 0.45rem;
  transition: transform 0.25s ease;
  line-height: 1;
}
.widget-transcript-wrap.expanded .transcript-toggle .toggle-arrow {
  transform: rotate(180deg);
}
.widget-transcript-wrap.expanded .transcript-toggle {
  color: rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.35);
}

.widget-transcript {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  background: rgba(0, 0, 0, 0.2);
}
.widget-transcript-wrap.expanded .widget-transcript {
  max-height: 150px;
  overflow-y: auto;
  padding: var(--space-sm) var(--space-xl);
}

.transcript-message {
  padding: 3px 0;
  font-size: 0.78rem;
  line-height: 1.4;
}

.msg-speaker {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--accent-secondary);
  margin-right: var(--space-xs);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.transcript-message.agent .msg-text {
  color: var(--text-secondary);
}

.transcript-message.user .msg-speaker {
  color: var(--accent-cyan);
}



/* ── MUNDIAL SECTION ─────────────────────────────────────────── */
.mundial {
  background: var(--grad-section);
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  padding: 0;
}

.mundial-content {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 0 var(--space-xl);
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
}

.footer-inline {
  width: 100%;
  flex-shrink: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: var(--space-md) var(--space-xl) calc(var(--space-md) + 56px);
  background: transparent;
}

.mundial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  align-items: stretch;
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.mundial-card {
  background: var(--grad-glass);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
  backdrop-filter: blur(10px);
  transition: all 0.4s var(--ease-out-expo);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.mundial-card:hover {
  border-color: rgba(255, 215, 0, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(255, 215, 0, 0.1);
}

.mundial-card.highlight {
  border-color: var(--accent-secondary);
  background: linear-gradient(135deg, rgba(255,215,0,0.1) 0%, rgba(255,215,0,0.02) 100%);
}

.mc-number {
  font-family: var(--font-display);
  font-size: 4rem;
  line-height: 1;
  color: var(--accent-secondary);
  margin-bottom: var(--space-xs);
}

.mc-label {
  font-family: var(--font-heading);
  font-size: 1rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.mc-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.mc-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  padding: 0.3rem 0.8rem;
  background: rgba(255, 215, 0, 0.15);
  border: 1px solid rgba(255, 215, 0, 0.3);
  border-radius: var(--radius-full);
  color: var(--accent-secondary);
  margin-bottom: var(--space-md);
}

.mc-team {
  font-family: var(--font-display);
  font-size: 2.5rem;
  line-height: 1;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

/* ── MUNDIAL PARTNERS (inside mundial section) ──────────────── */
.mundial-partners {
  margin-top: var(--space-3xl);
  text-align: center;
}

.mundial-partners .section-tag {
  margin-bottom: var(--space-lg);
}

/* ── Infinite logo ribbon ────────────────────────────────── */
.sponsors-ribbon {
  width: 100%;
  overflow: hidden;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.3);
  padding: var(--space-xl) 0;
}

.marquee-track {
  display: flex;
  align-items: center;
  gap: clamp(3rem, 6vw, 5rem);
  animation: marquee-scroll 20s linear infinite;
  width: max-content;
}

@keyframes marquee-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-33.333%); }
}

.sponsor-logo {
  height: 44px;
  width: auto;
  object-fit: contain;
  filter: brightness(0) invert(0.5);
  transition: filter 0.4s ease;
  flex-shrink: 0;
}

.sponsor-logo:hover {
  filter: brightness(0) invert(1);
}

/* ── FOOTER ──────────────────────────────────────────────────── */
.footer {
  background: var(--bg-deep);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: var(--space-3xl) var(--space-xl) var(--space-xl);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: var(--space-2xl);
  align-items: start;
}

.footer-brand .nav-logo { margin-bottom: var(--space-sm); }

.footer-tagline {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: var(--space-lg);
}

.footer-links a {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.3s ease;
}

.footer-links a:hover { color: var(--text-primary); }

.footer-tech {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  align-items: center;
}

.footer-tech span:first-child {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-right: var(--space-xs);
}

.tech-badge {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.6rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  color: var(--text-muted);
}

.footer-copy {
  grid-column: 1 / -1;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

/* ================================================================
   FDP BROADCAST TICKER (Fútbol de Primera lower-third)
   ================================================================ */
.fdp-ticker {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 180;
  height: 44px;
  display: flex;
  align-items: stretch;
  background: linear-gradient(90deg, #0a0514 0%, rgba(10, 5, 20, 0.97) 100%);
  border-top: 2px solid var(--accent-primary);
  box-shadow: 0 -4px 30px var(--accent-primary-25);
  overflow: hidden;
}

.ticker-logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0 1.2rem;
  background: var(--accent-primary);
  flex-shrink: 0;
  position: relative;
}

.ticker-logo::after {
  content: '';
  position: absolute;
  right: -20px;
  top: 0;
  bottom: 0;
  width: 40px;
  background: var(--accent-primary);
  transform: skewX(-15deg);
}

.ticker-fdp {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: white;
  letter-spacing: 0.1em;
  position: relative;
  z-index: 1;
}

.ticker-live {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.9);
  background: rgba(0, 0, 0, 0.3);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  position: relative;
  z-index: 1;
  animation: pulse-dot 2s ease-in-out infinite;
}

.ticker-scroll {
  flex: 1;
  overflow: hidden;
  display: flex;
  align-items: center;
  padding-left: 2rem;
}

.ticker-text {
  display: flex;
  white-space: nowrap;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-secondary);
  animation: ticker-scroll 40s linear infinite;
}

@keyframes ticker-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ================================================================
   FLOATING BUBBLE — Voice + Slides (stacked, top-right)
   ================================================================ */
.mode-bubble {
  position: fixed;
  top: 80px;
  right: 1.5rem;
  z-index: 160;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.bubble-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  cursor: pointer;
  position: relative;
  overflow: visible;
  transition: transform 0.3s var(--ease-bounce);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-primary-15);
  border: 2px solid var(--accent-primary);
  box-shadow: 0 2px 20px var(--accent-primary-40);
}

.bubble-avatar:hover { transform: scale(1.08); }

/* Sound-wave bars inside bubble */
.bubble-waves {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  height: 24px;
}

.bw-bar {
  display: block;
  width: 3px;
  border-radius: 2px;
  background: var(--accent-primary);
  animation: bw-pulse 1.2s ease-in-out infinite;
}
.bw-bar:nth-child(1) { height: 8px;  animation-delay: 0s;   }
.bw-bar:nth-child(2) { height: 14px; animation-delay: 0.15s; }
.bw-bar:nth-child(3) { height: 20px; animation-delay: 0.3s;  }
.bw-bar:nth-child(4) { height: 14px; animation-delay: 0.15s; }
.bw-bar:nth-child(5) { height: 8px;  animation-delay: 0s;    }

@keyframes bw-pulse {
  0%, 100% { transform: scaleY(1);   opacity: 0.7; }
  50%      { transform: scaleY(1.6); opacity: 1;   }
}

/* bubble-pulse ring removed — was the pulsing/spinning propeller */

/* FAB inside the bubble stack — override fixed positioning */
.mode-bubble .fab-presentation {
  position: relative;
  bottom: auto;
  right: auto;
  width: 52px;
  height: 52px;
}

.mode-bubble .fab-inner {
  width: 44px;
  height: 44px;
}

/* ================================================================
   HERO — Twin Cutout Image
   ================================================================ */
.hero-twin-img {
  position: absolute;
  right: 3%;
  bottom: 0;
  z-index: 2;
  width: clamp(280px, 30vw, 500px);
  pointer-events: none;
  opacity: 0.85;
  filter: drop-shadow(0 0 40px var(--accent-primary-30)) drop-shadow(0 0 80px rgba(5, 2, 8, 0.6));
  mask-image: linear-gradient(to top, transparent 0%, black 15%, black 100%);
  -webkit-mask-image: linear-gradient(to top, transparent 0%, black 15%, black 100%);
}

.hero-twin-img img {
  width: 100%;
  height: auto;
  display: block;
}

/* ── RESPONSIVE ──────────────────────────────────────────────── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; text-align: center; }
  .footer-links { justify-content: center; }
  .footer-tech { justify-content: center; }
  /* Hero: stack vertical en mobile (NO 2 columnas que se aprietan) */
  .hero { flex-direction: column; padding-top: var(--space-xl); padding-bottom: var(--space-xl); gap: var(--space-xl); }
  .hero-content { padding: 0 var(--space-md); width: 100%; max-width: 100%; }
  .experience-twin-inline { width: 100%; }
  .section { padding: var(--space-2xl) var(--space-md); }
  /* Twin widget — full width edge-to-edge on mobile */
  .twin-widget { max-width: 100%; border-radius: var(--radius-lg); }
  .et-grid { grid-template-columns: 1fr; gap: var(--space-lg); padding: 0 var(--space-xs, 0.5rem); }
  .et-widget { padding: 0; width: 100%; }
  .et-text { padding-top: 0; text-align: center; }
  .et-text .section-tag { display: block; text-align: center; }
  .et-text .section-title { text-align: center; }
  .widget-controls { padding: var(--space-md) var(--space-md); }
  .hero-twin-img { width: clamp(160px, 45vw, 280px); right: -2%; opacity: 0.5; }
  .mode-bubble { top: 70px; right: 0.8rem; }
  .bubble-avatar { width: 42px; height: 42px; }
  .mode-bubble .fab-presentation { width: 42px; height: 42px; }
  .mode-bubble .fab-inner { width: 36px; height: 36px; }
  .bw-bar { width: 2px; }
  .fdp-ticker { height: 38px; }
  .ticker-fdp { font-size: 1.1rem; }
  .ticker-text { font-size: 0.7rem; }
  body { padding-bottom: 0; }
}

@media (max-width: 480px) {
  .stats-inner { grid-template-columns: repeat(2, 1fr); gap: var(--space-md); }
  .stat-number { font-size: 2.5rem; }
  .hero-ctas { flex-direction: column; }
  .widget-controls { flex-wrap: wrap; gap: var(--space-sm); }
  .btn-talk { width: 100%; justify-content: center; margin-left: 0; padding: 0.7rem 1rem; font-size: 0.78rem; }
  /* Hero typography para mobile chico — entran sin desbordar */
  .title-the    { font-size: clamp(1rem, 5vw, 1.6rem); }
  .title-name   { font-size: clamp(2.5rem, 14vw, 4rem); }
  .title-accent { font-size: clamp(1.3rem, 6vw, 2.2rem); }
  .hero-desc    { font-size: 0.95rem; }
  /* Avatar Andrés solapaba con texto en mobile chico — ocultar */
  .hero-twin-img { display: none; }
}

@media (max-width: 768px) {
  .btn-talk { padding: 0.7rem 1.2rem; font-size: 0.8rem; }
}

/* ── UTILITY ANIMATIONS ──────────────────────────────────────── */
.anim-hidden {
  opacity: 0;
  transform: translateY(30px);
}

.anim-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--accent-primary-30); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-primary); }

/* Selection */
::selection {
  background: var(--accent-primary-40);
  color: white;
}

/* ================================================================
   SLIDE POPUP — Glassmorphism Modal (Slides.com-inspired)
   ================================================================ */

/* ── Overlay ─────────────────────────────────────────────────── */
.slide-popup {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.1s, visibility 0.1s;
}

.slide-popup.open {
  pointer-events: all;
  opacity: 1;
  visibility: visible;
}

.slide-popup-bg {
  position: absolute;
  inset: 0;
  background: rgba(5, 2, 8, 0.3);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* ── Inner modal ─────────────────────────────────────────────── */
.slide-popup-inner {
  position: relative;
  width: 90vw;
  max-width: 1100px;
  height: 70vh;
  max-height: 700px;
  border-radius: var(--radius-xl);
  border: 2px solid var(--accent-primary-40);
  background: rgba(10, 5, 20, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow:
    0 4px 60px var(--accent-primary-25) inset,
    0 4px 80px rgba(255, 255, 255, 0.1),
    0 8px 120px var(--accent-primary-20),
    0 40px 100px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ── Header ──────────────────────────────────────────────────── */
.slide-popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 1.2rem;
  background: rgba(0, 0, 0, 0.4);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.slide-popup-title {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.popup-badge {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  padding: 0.25rem 0.6rem;
  background: var(--accent-primary-20);
  border: 1px solid var(--accent-primary-40);
  border-radius: var(--radius-full);
  color: var(--accent-neon);
}

.slide-popup-header h3 {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Navigation */
.slide-popup-nav {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.slide-nav-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  transition: all 0.3s ease;
}

.slide-nav-btn:hover {
  background: var(--accent-primary-20);
  border-color: var(--accent-primary);
  color: white;
}

.slide-nav-btn svg { width: 18px; height: 18px; }

.slide-counter {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  min-width: 50px;
  text-align: center;
}

/* Actions */
.slide-popup-actions {
  display: flex;
  gap: var(--space-xs);
}

.slide-action-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  transition: all 0.3s ease;
}

.slide-action-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: white;
}

.slide-close-btn:hover {
  background: var(--accent-primary-30);
  border-color: var(--accent-primary);
}

.slide-action-btn svg { width: 18px; height: 18px; }

/* ── Deck tabs ───────────────────────────────────────────────── */
.deck-tabs {
  display: flex;
  gap: 2px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-full);
  padding: 2px;
}

.deck-tab {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.35rem 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  border-radius: var(--radius-full);
  color: var(--text-muted);
  transition: all 0.3s ease;
  white-space: nowrap;
}

.deck-tab:hover {
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.06);
}

.deck-tab.active {
  background: var(--accent-primary-20);
  color: var(--accent-neon);
  border: 1px solid var(--accent-primary-30);
}

.dt-icon { font-size: 0.8rem; }

/* ── Slide Voice Bar (inline voice narration control) ────────── */
.slide-voice-bar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.6rem 1.2rem;
  min-height: 48px;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.7) 0%, rgba(10, 5, 20, 0.9) 100%);
  border-top: 1px solid var(--accent-primary-20);
  position: relative;
  z-index: 5;
}

.svb-mic {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--accent-primary-15);
  border: 2px solid var(--accent-primary-40);
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.svb-mic svg {
  width: 20px;
  height: 20px;
}

.svb-mic:hover {
  background: var(--accent-primary-30);
  border-color: var(--accent-primary);
  box-shadow: 0 0 12px var(--accent-primary-30);
}

.svb-mic.active {
  background: var(--accent-primary-40);
  border-color: var(--accent-primary);
  color: white;
  animation: svb-pulse 1.5s ease-in-out infinite;
}

.svb-mic.interrupt-ready {
  background: rgba(255, 215, 0, 0.25);
  border-color: var(--accent-secondary);
  color: var(--accent-secondary);
  animation: svb-interrupt-glow 1s ease-in-out infinite;
  cursor: pointer;
}

.svb-mic.interrupt-ready:hover {
  background: rgba(255, 215, 0, 0.4);
  box-shadow: 0 0 16px rgba(255, 215, 0, 0.4);
}

@keyframes svb-pulse {
  0%, 100% { box-shadow: 0 0 0 0 var(--accent-primary-50); }
  50% { box-shadow: 0 0 0 8px transparent; }
}

@keyframes svb-interrupt-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.4); }
  50% { box-shadow: 0 0 0 6px rgba(255, 215, 0, 0); }
}

.svb-waveform {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 24px;
  opacity: 0.25;
  transition: opacity 0.3s ease;
}

.svb-waveform.active {
  opacity: 1;
}

.svb-bar {
  width: 3px;
  height: 4px;
  background: var(--accent-primary);
  border-radius: 2px;
  transition: height 0.1s ease;
}

.svb-waveform.active .svb-bar {
  animation: svb-wave 0.6s ease-in-out infinite alternate;
}

.svb-waveform.active .svb-bar:nth-child(1) { animation-delay: 0s; }
.svb-waveform.active .svb-bar:nth-child(2) { animation-delay: 0.08s; }
.svb-waveform.active .svb-bar:nth-child(3) { animation-delay: 0.16s; }
.svb-waveform.active .svb-bar:nth-child(4) { animation-delay: 0.24s; }
.svb-waveform.active .svb-bar:nth-child(5) { animation-delay: 0.16s; }
.svb-waveform.active .svb-bar:nth-child(6) { animation-delay: 0.08s; }
.svb-waveform.active .svb-bar:nth-child(7) { animation-delay: 0.12s; }
.svb-waveform.active .svb-bar:nth-child(8) { animation-delay: 0.2s; }

@keyframes svb-wave {
  0% { height: 4px; }
  100% { height: 20px; }
}

.svb-talk {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 1.2rem;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-primary-darker) 100%);
  color: white;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.svb-talk:hover {
  box-shadow: 0 0 20px var(--accent-primary-50);
  transform: translateY(-1px);
}

.svb-talk.active {
  background: linear-gradient(135deg, #444 0%, #333 100%);
  border-color: rgba(255, 255, 255, 0.25);
}

.svb-talk-icon { font-size: 0.7rem; }

.svb-status {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--accent-neon);
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.03em;
}

.svb-transcript {
  flex: 1;
  font-size: 0.72rem;
  color: var(--text-secondary);
  text-align: right;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  min-width: 0;
  line-height: 1.3;
}

.svb-transcript .svb-msg {
  opacity: 0;
  animation: svb-msg-in 0.3s ease forwards;
}

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

/* ── Text Input (always-available fallback) ───────────────── */
.svb-text-input {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 6px 10px 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.svb-text-input input {
  flex: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  padding: 6px 14px;
  color: #fff;
  font-size: 0.82rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}
.svb-text-input input:focus {
  border-color: rgba(34, 255, 255, 0.5);
}
.svb-text-input input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}
.svb-text-input button {
  background: none;
  border: none;
  color: rgba(34, 255, 255, 0.7);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 4px 6px;
  transition: color 0.2s;
}
.svb-text-input button:hover {
  color: #22FFFF;
}

/* ── Primary Press-to-Talk Button ─────────────────────────── */
.svb-ptt-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  width: 100%;
}

.svb-ptt-primary {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 24px;
  background: rgba(34, 255, 255, 0.12);
  border: 2px solid rgba(34, 255, 255, 0.5);
  border-radius: 40px;
  color: #22FFFF;
  font-family: var(--font-mono, monospace);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.25s ease;
  animation: svb-ptt-breathe 3s ease-in-out infinite;
  flex-shrink: 0;
}

.svb-ptt-primary:hover {
  background: rgba(34, 255, 255, 0.22);
  border-color: #22FFFF;
  transform: scale(1.04);
}

.svb-ptt-primary:active {
  transform: scale(0.96);
  background: rgba(34, 255, 255, 0.3);
}

.svb-ptt-primary.listening {
  background: rgba(34, 255, 255, 0.25);
  border-color: #22FFFF;
  animation: svb-ptt-pulse-active 1s ease-in-out infinite;
}

.svb-ptt-primary.speaking {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.4);
  cursor: default;
  animation: none;
}

.svb-ptt-mic-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

/* Mic icon breathes when listening */
.svb-ptt-primary.listening .svb-ptt-mic-icon {
  animation: mic-breathe 1.5s ease-in-out infinite;
}
.svb-ptt-primary.listening .svb-ptt-mic-icon .mic-arc {
  animation: mic-arc-pulse 1.5s ease-in-out infinite;
}

/* Mic icon dims and shrinks when speaking (Andrés talks) */
.svb-ptt-primary.speaking .svb-ptt-mic-icon {
  opacity: 0.4;
  transform: scale(0.9);
}

@keyframes mic-breathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}
@keyframes mic-arc-pulse {
  0%, 100% { stroke-dasharray: none; opacity: 1; }
  50% { opacity: 0.5; }
}

.svb-ptt-label {
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 600;
  font-size: 0.78rem;
  white-space: nowrap;
}

@keyframes svb-ptt-breathe {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34, 255, 255, 0.25); }
  50% { box-shadow: 0 0 20px 6px rgba(34, 255, 255, 0.15); }
}

@keyframes svb-ptt-pulse-active {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34, 255, 255, 0.5); }
  50% { box-shadow: 0 0 12px 4px rgba(34, 255, 255, 0.3); }
}

/* ── Stop / Restart buttons ───────────────────────────────── */
.svb-stop-btn,
.svb-restart-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.svb-stop-btn svg,
.svb-restart-btn svg {
  transition: transform 0.3s ease;
}
.svb-stop-btn:hover { background: rgba(255, 70, 70, 0.2); border-color: #ff4646; color: #ff4646; }
.svb-stop-btn:hover svg { transform: scale(1.1); }
.svb-restart-btn:hover { background: rgba(34, 255, 255, 0.15); border-color: #22FFFF; color: #22FFFF; }
.svb-restart-btn:hover svg { transform: rotate(-30deg); }
.svb-stop-btn:active,
.svb-restart-btn:active { transform: scale(0.9); }
.svb-restart-btn.spinning svg { animation: restart-spin 0.6s ease-in-out; }
@keyframes restart-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

/* Legacy PTT overlay (kept for JS compat) */
.svb-ptt-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.85);
  border-radius: inherit;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.svb-ptt-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}
.svb-ptt-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 28px;
  background: rgba(34, 255, 255, 0.15);
  border: 2px solid rgba(34, 255, 255, 0.6);
  border-radius: 40px;
  color: #22FFFF;
  font-family: var(--font-mono, monospace);
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.svb-ptt-btn:hover {
  background: rgba(34, 255, 255, 0.25);
  border-color: #22FFFF;
  transform: scale(1.05);
}
.svb-ptt-btn:active {
  transform: scale(0.97);
}
.svb-ptt-icon {
  font-size: 1.3rem;
}
.svb-ptt-text {
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 600;
  font-size: 0.8rem;
}

/* ── Voice Debug Panel ──────────────────────────────────────── */
.voice-debug-panel {
  position: absolute;
  bottom: 68px;
  left: 12px;
  width: 360px;
  max-height: 240px;
  background: rgba(0, 0, 0, 0.92);
  border: 1px solid rgba(34, 255, 255, 0.3);
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  z-index: 20;
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.voice-debug-panel.visible {
  display: flex;
}
.vdp-header {
  padding: 6px 10px;
  background: rgba(34, 255, 255, 0.1);
  color: var(--accent-neon);
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.6rem;
  letter-spacing: 0.05em;
}
.vdp-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-neon);
  animation: pulse 1.5s infinite;
}
.vdp-hint {
  margin-left: auto;
  opacity: 0.5;
  font-size: 0.55rem;
}
.voice-debug-log {
  flex: 1;
  overflow-y: auto;
  padding: 6px 10px;
  color: #8BFFA8;
  line-height: 1.5;
  max-height: 200px;
}
.voice-debug-log div {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 2px 0;
  word-break: break-word;
}

/* ── Slide body / Deck container ─────────────────────────────── */
.slide-popup-body.slide-deck {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  display: none;
}

.slide-popup-body.slide-deck.active {
  display: block;
}

/* Individual slides */
.slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateX(60px);
  pointer-events: none;
  transition: none;
  padding: 2rem 3rem;
}

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

.slide-inner { width: 100%; max-width: 960px; }

/* Slide layouts */
.slide-title-layout {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.slide-title-layout h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  line-height: 0.92;
  letter-spacing: 0.02em;
  overflow: visible;
}

.slide-accent {
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.slide-kicker {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  color: var(--accent-secondary);
  opacity: 0.7;
}

.slide-subtitle {
  font-size: 0.95rem;
  color: var(--text-secondary);
  max-width: 500px;
}

.slide-footer-bar {
  display: flex;
  gap: var(--space-xl);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-top: var(--space-md);
}

/* Split layout */
.slide-split-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
  align-items: center;
}

.slide-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--accent-secondary);
  margin-bottom: var(--space-md);
}

.slide-split-layout h2, .slide-center-layout h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 0.95;
  margin-bottom: var(--space-lg);
}

.slide-split-layout p, .slide-center-layout p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Center layout */
.slide-center-layout {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Stats grid inside slides */
.slide-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
}

.slide-stat {
  background: var(--grad-glass);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  text-align: center;
}

.ss-num {
  font-family: var(--font-display);
  font-size: 2.5rem;
  color: var(--accent-secondary);
  line-height: 1;
}

.ss-label {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-top: var(--space-xs);
  text-transform: uppercase;
}

/* Tech stack slide */
.slide-tech-stack {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: var(--space-md);
  margin-top: var(--space-lg);
  flex-wrap: wrap;
}

.slide-tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-md) var(--space-lg);
  background: var(--grad-glass);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  min-width: 140px;
  flex: 1;
  max-width: 220px;
}

.sti-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--accent-primary-15);
  border: 1px solid var(--accent-primary-30);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
}

.sti-icon svg {
  width: 22px;
  height: 22px;
}

.sti-label {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  color: var(--text-primary);
}

.sti-detail {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--accent-cyan);
  letter-spacing: 0.05em;
  text-align: center;
}

.slide-tech-arrow {
  font-size: 1.5rem;
  color: var(--accent-primary);
  opacity: 0.5;
}

/* Code block slide */
.slide-code-block {
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  overflow: hidden;
  font-family: var(--font-mono);
}

.code-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0.6rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.7rem;
  color: var(--text-muted);
}

.code-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.code-dot.red { background: #FF5F57; }
.code-dot.yellow { background: #FFBD2E; }
.code-dot.green { background: #28C840; }

.code-body {
  padding: 1.2rem;
  font-size: 0.8rem;
  line-height: 1.8;
  color: var(--text-secondary);
  white-space: pre;
  overflow-x: auto;
}

.code-kw { color: #C792EA; }
.code-fn { color: #82AAFF; }
.code-str { color: #C3E88D; }
.code-num { color: #F78C6C; }

/* Mundial slide */
.slide-mundial-grid {
  display: flex;
  gap: var(--space-xl);
  margin-top: var(--space-2xl);
  justify-content: center;
}

.smg-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-lg) var(--space-2xl);
  background: var(--grad-glass);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
}

.smg-flag { font-size: 2.5rem; }

.smg-name {
  font-family: var(--font-heading);
  font-size: 1rem;
  letter-spacing: 0.08em;
  color: var(--text-primary);
}

.smg-venue {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
}

.slide-note {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: var(--space-2xl);
  letter-spacing: 0.05em;
}

/* Slide CTA button */
.slide-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 1rem 2.5rem;
  background: var(--accent-primary);
  border: 2px solid var(--accent-primary);
  border-radius: var(--radius-full);
  font-family: var(--font-heading);
  font-size: 1rem;
  letter-spacing: 0.15em;
  color: white;
  transition: all 0.4s var(--ease-out-expo);
}

.slide-cta-btn:hover {
  background: transparent;
  color: var(--accent-neon);
  box-shadow: var(--shadow-glow-red);
  transform: scale(1.05);
}

/* ── Function call log ───────────────────────────────────────── */
.slide-fcall-log {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  width: 260px;
  max-height: 200px;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(34, 255, 255, 0.2);
  border-radius: var(--radius-md);
  backdrop-filter: blur(10px);
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.4s var(--ease-out-expo);
}

.slide-fcall-log.visible {
  opacity: 1;
  transform: translateY(0);
}

.fcall-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0.5rem 0.8rem;
  background: rgba(34, 255, 255, 0.05);
  border-bottom: 1px solid rgba(34, 255, 255, 0.1);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--accent-cyan);
  cursor: pointer;
  user-select: none;
}

.fcall-collapse-btn {
  margin-left: auto;
  background: none;
  border: none;
  color: var(--accent-cyan);
  font-size: 0.6rem;
  cursor: pointer;
  opacity: 0.6;
  transition: transform 0.3s ease, opacity 0.2s;
  line-height: 1;
  padding: 0 2px;
}
.fcall-collapse-btn:hover { opacity: 1; }

/* Collapsed: only header visible */
.slide-fcall-log.collapsed .fcall-entries { display: none; }
.slide-fcall-log.collapsed .fcall-collapse-btn { transform: rotate(180deg); }
.slide-fcall-log.collapsed { border-bottom: none; }

.fcall-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cyan);
  animation: pulse-dot 2s ease-in-out infinite;
}

.fcall-entries {
  padding: 0.5rem 0.8rem;
  overflow-y: auto;
  max-height: 150px;
}

.fcall-entry {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 0.2rem 0;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  animation: fadeInEntry 0.3s ease;
}

.fcall-entry .fcall-fn { color: #82AAFF; }
.fcall-entry .fcall-time { color: var(--text-muted); opacity: 0.5; margin-left: var(--space-sm); }

@keyframes fadeInEntry {
  from { opacity: 0; transform: translateX(10px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ================================================================
   FAB — Floating Presentation Button
   ================================================================ */
.fab-presentation {
  position: relative;
  z-index: 150;
  width: 64px;
  height: 64px;
  border-radius: var(--radius-full);
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.fab-inner {
  position: relative;
  z-index: 2;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent-primary-90);
  border: 2px solid var(--accent-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: all 0.4s var(--ease-out-expo);
  box-shadow: 0 4px 20px var(--accent-primary-40);
}

.fab-presentation:hover .fab-inner {
  transform: scale(1.1);
  box-shadow: 0 4px 40px var(--accent-primary-40);
}

.fab-icon {
  width: 22px;
  height: 22px;
  color: white;
}

.fab-label {
  font-family: var(--font-mono);
  font-size: 0.45rem;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.85);
}

/* Subtle hover shimmer — replaces old spinning ring + glow pulse */
.fab-presentation::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1.5px solid var(--accent-primary-25);
  transition: border-color 0.4s ease, box-shadow 0.4s ease;
  pointer-events: none;
}

.fab-presentation:hover::before {
  border-color: var(--accent-primary-50);
  box-shadow: 0 0 12px var(--accent-primary-30);
}

/* ── Responsive for popup ────────────────────────────────────── */
@media (max-width: 768px) {
  .slide-popup {
    align-items: stretch;
    padding:
      max(0.5rem, env(safe-area-inset-top))
      max(0.5rem, env(safe-area-inset-right))
      max(0.75rem, env(safe-area-inset-bottom))
      max(0.5rem, env(safe-area-inset-left));
  }

  .slide-popup-inner {
    width: 100%;
    max-width: none;
    height: calc(100dvh - 1rem - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    max-height: none;
    border-radius: calc(var(--radius-xl) - 0.25rem);
  }

  .slide-popup-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "title actions"
      "tabs tabs"
      "nav nav";
    gap: 0.75rem;
    padding: 0.85rem 0.9rem 0.95rem;
    align-items: center;
  }

  .slide-popup-title {
    grid-area: title;
    min-width: 0;
    gap: 0.5rem;
  }

  .slide-popup-title h3 {
    display: none;
  }

  .popup-badge {
    font-size: 0.58rem;
    letter-spacing: 0.12em;
  }

  .deck-tabs {
    grid-area: tabs;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.35rem;
    width: 100%;
  }

  .deck-tab {
    justify-content: center;
    min-width: 0;
    padding: 0.55rem 0.6rem;
    text-align: center;
    line-height: 1.2;
    white-space: normal;
  }

  .slide-popup-nav {
    grid-area: nav;
    width: 100%;
    justify-content: space-between;
    gap: 0.6rem;
  }

  .slide-nav-btn {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    color: var(--text-primary);
  }

  .slide-counter {
    min-width: 0;
    flex: 1;
    font-size: 0.78rem;
  }

  .slide-popup-actions {
    grid-area: actions;
    justify-self: end;
    gap: 0.45rem;
  }

  #slide-fullscreen {
    display: none;
  }

  .slide-close-btn {
    width: auto;
    min-width: 44px;
    padding: 0 0.8rem;
    border-color: var(--accent-primary);
    background: var(--accent-primary-20);
    color: white;
    box-shadow: 0 0 0 1px var(--accent-primary-25);
  }

  .slide-close-btn::after {
    content: attr(title);
    margin-left: 0.45rem;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .slide {
    align-items: stretch;
    justify-content: flex-start;
    padding: 1.25rem 1rem 1.5rem;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
  }

  .slide-inner {
    max-width: none;
  }

  .slide-title-layout,
  .slide-center-layout {
    min-height: 100%;
    justify-content: center;
  }

  .slide-title-layout h1 {
    font-size: clamp(2rem, 11vw, 3.2rem);
  }

  .slide-split-layout {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    align-items: start;
  }

  .slide-split-layout h2,
  .slide-center-layout h2 {
    font-size: clamp(1.8rem, 9vw, 2.6rem);
  }

  .slide-subtitle,
  .slide-split-layout p,
  .slide-center-layout p {
    font-size: 0.9rem;
  }

  .slide-footer-bar {
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
  }

  .slide-stats-grid {
    grid-template-columns: 1fr;
  }

  .slide-stat,
  .smg-item {
    padding: 0.95rem 1rem;
  }

  .slide-mundial-grid {
    flex-direction: column;
    align-items: stretch;
    gap: 0.85rem;
  }

  .slide-tech-stack {
    flex-direction: column;
    gap: 0.75rem;
    width: 100%;
  }

  .slide-tech-item {
    max-width: none;
    width: 100%;
  }

  .slide-tech-arrow {
    transform: rotate(90deg);
  }

  .code-body {
    padding: 1rem;
    font-size: 0.72rem;
  }

  .slide-note {
    margin-top: 1rem;
    text-align: center;
  }

  .slide-voice-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 0.6rem;
    padding: 0.75rem 0.9rem calc(0.85rem + env(safe-area-inset-bottom));
  }

  .svb-ptt-row {
    flex-wrap: wrap;
    gap: 0.55rem;
  }

  .svb-ptt-primary {
    flex: 1 1 100%;
    justify-content: center;
    min-height: 48px;
    padding: 0.8rem 1rem;
  }

  .svb-status {
    white-space: normal;
    min-width: 0;
    line-height: 1.4;
  }

  .svb-transcript {
    display: none;
  }

  .svb-text-input {
    width: 100%;
    padding: 0;
    border-top: none;
  }

  .slide-fcall-log {
    display: none;
  }
}

@media (max-width: 480px) {
  .slide-popup-header {
    gap: 0.65rem;
    padding-inline: 0.75rem;
  }

  .deck-tab {
    font-size: 0.55rem;
    letter-spacing: 0.08em;
  }

  .slide-close-btn {
    padding: 0 0.7rem;
  }

  .slide-close-btn::after {
    font-size: 0.62rem;
  }
}

/* ================================================================
   NNB DEBUG PANEL — Collapsible bottom bar (above ticker)
   Activated via ?debug=true or Ctrl+Shift+D
   ================================================================ */
.nnb-debug-panel {
  position: fixed;
  bottom: 44px; /* sits above the FDP ticker */
  left: 0;
  right: 0;
  z-index: 170;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  transition: transform 0.3s var(--ease-out-expo);
  transform: translateY(100%);
  pointer-events: none;
}

.nnb-debug-panel .nnb-dbg-bar {
  pointer-events: all;
  transform: translateY(-100%);
}

.nnb-debug-panel.open {
  transform: translateY(0);
  pointer-events: all;
}

.nnb-debug-panel.open .nnb-dbg-bar {
  transform: translateY(0);
}

/* ── Top bar (always visible via translate trick) ─────────────── */
.nnb-dbg-bar {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 1rem;
  background: rgba(0, 8, 12, 0.95);
  border-top: 1px solid rgba(34, 255, 255, 0.25);
  border-bottom: 1px solid rgba(34, 255, 255, 0.1);
  cursor: pointer;
  user-select: none;
}

.nnb-dbg-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cyan);
  animation: pulse-dot 2s ease-in-out infinite;
  flex-shrink: 0;
}

.nnb-dbg-title {
  font-weight: 700;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  color: var(--accent-cyan);
  flex-shrink: 0;
}

/* ── Tabs ─────────────────────────────────────────────────────── */
.nnb-dbg-tabs {
  display: flex;
  gap: 2px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-full);
  padding: 2px;
  margin-left: 0.5rem;
}

.nnb-dbg-tab {
  padding: 0.2rem 0.7rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  border-radius: var(--radius-full);
  color: var(--text-muted);
  background: none;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.nnb-dbg-tab:hover {
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.06);
}

.nnb-dbg-tab.active {
  background: rgba(34, 255, 255, 0.15);
  color: var(--accent-cyan);
  border: 1px solid rgba(34, 255, 255, 0.3);
}

.nnb-dbg-tab-settings {
  color: #F59E0B;
  border-color: rgba(245, 158, 11, 0.3);
  margin-left: auto;
}
.nnb-dbg-tab-settings:hover {
  background: rgba(245, 158, 11, 0.15);
  color: #F59E0B;
  border-color: rgba(245, 158, 11, 0.5);
}

.nnb-dbg-hint {
  margin-left: 0;
  font-size: 0.55rem;
  color: var(--text-muted);
  opacity: 0.5;
}

.nnb-dbg-clear {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.1em;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
}

.nnb-dbg-clear:hover {
  background: rgba(255, 77, 82, 0.2);
  border-color: var(--accent-neon);
  color: var(--accent-neon);
}

.nnb-dbg-toggle {
  font-size: 0.7rem;
  color: var(--accent-cyan);
  background: none;
  border: none;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s;
  padding: 0 4px;
}

.nnb-dbg-toggle:hover { opacity: 1; }

/* ── Body (collapsible) ───────────────────────────────────────── */
.nnb-dbg-body {
  background: rgba(0, 4, 8, 0.95);
  border-bottom: 1px solid rgba(34, 255, 255, 0.15);
  height: 220px;
  overflow: hidden;
}

.nnb-dbg-pane {
  display: none;
  height: 100%;
  overflow-y: auto;
  padding: 0.5rem 1rem;
}

.nnb-dbg-pane.active {
  display: block;
}

/* ── LOG entries ──────────────────────────────────────────────── */
.nnb-dbg-entry {
  padding: 2px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  line-height: 1.5;
  word-break: break-word;
}

.nnb-dbg-time {
  color: rgba(255, 255, 255, 0.25);
  margin-right: 0.4rem;
  font-size: 0.6rem;
}

.nnb-dbg-tag {
  color: var(--accent-cyan);
  font-weight: 600;
  margin-right: 0.3rem;
}

.nnb-dbg-msg {
  color: #8BFFA8;
}

.nnb-dbg-entry.warn .nnb-dbg-msg { color: #FFD700; }
.nnb-dbg-entry.error .nnb-dbg-msg { color: #FF6B6B; }
.nnb-dbg-entry.error .nnb-dbg-tag { color: #FF6B6B; }
.nnb-dbg-entry.mic .nnb-dbg-tag { color: #82AAFF; }
.nnb-dbg-entry.transcript .nnb-dbg-msg { color: var(--text-secondary); font-style: italic; }

/* ── SYSTEM variables ─────────────────────────────────────────── */
.nnb-dbg-section {
  margin-bottom: 0.8rem;
}

.nnb-dbg-section-title {
  font-weight: 700;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  color: var(--accent-cyan);
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(34, 255, 255, 0.15);
  margin-bottom: 0.3rem;
}

.nnb-dbg-var {
  display: flex;
  gap: 0.6rem;
  padding: 1px 0;
  line-height: 1.5;
}

.nnb-dbg-var-key {
  color: var(--text-muted);
  min-width: 200px;
  flex-shrink: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nnb-dbg-var-val {
  color: #C3E88D;
  word-break: break-all;
}

.nnb-dbg-var-val.secret {
  color: #FF6B6B;
  font-style: italic;
}

/* ── Provider check badges ─────────────────────────────────────── */
.nnb-dbg-check-pass {
  color: #4EC9B0;
  font-size: 0.72rem;
  font-weight: 600;
}

.nnb-dbg-check-fail {
  color: #FF6B6B;
  font-size: 0.72rem;
  font-weight: 600;
}

/* ── Session state bar ─────────────────────────────────────────── */
.nnb-dbg-session-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 3px 12px;
  background: rgba(0, 0, 0, 0.5);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.6);
}

.nnb-dbg-session-state {
  padding: 1px 6px;
  border-radius: 3px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.nnb-dbg-session-state.state-idle { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.5); }
.nnb-dbg-session-state.state-connecting { background: rgba(255,170,0,0.25); color: #FFAA00; }
.nnb-dbg-session-state.state-listening { background: rgba(78,201,176,0.25); color: #4EC9B0; }
.nnb-dbg-session-state.state-speaking { background: rgba(130,170,255,0.25); color: #82AAFF; }
.nnb-dbg-session-state.state-thinking { background: rgba(199,146,234,0.25); color: #C792EA; }
.nnb-dbg-session-state.state-avatar_active { background: rgba(255,203,107,0.25); color: #FFCB6B; }

.nnb-dbg-session-mode {
  color: rgba(255, 255, 255, 0.4);
}

.nnb-dbg-session-id {
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.65rem;
}

.nnb-dbg-session-timer {
  color: #4EC9B0;
  font-variant-numeric: tabular-nums;
}

/* ── Responsive debug panel ───────────────────────────────────── */
@media (max-width: 768px) {
  .nnb-dbg-body { height: 180px; }
  .nnb-dbg-hint { display: none; }
  .nnb-dbg-var-key { min-width: 140px; }
  .nnb-debug-panel { bottom: 38px; } /* smaller ticker on mobile */
}

/* ══════════════════════════════════════════════════════════════════
   CONFIG PANEL — runtime config editor (Ctrl+Shift+C)
   ══════════════════════════════════════════════════════════════════ */
.cfg-panel {
  position: fixed;
  bottom: 16px;
  left: 16px;
  width: 420px;
  max-height: 75vh;
  background: rgba(0, 0, 0, 0.94);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 10px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  z-index: 9999;
  display: none;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.1);
  backdrop-filter: blur(12px);
}
.cfg-panel.visible { display: flex; }

/* Header */
.cfg-header {
  padding: 8px 12px;
  background: rgba(245, 158, 11, 0.1);
  color: #F59E0B;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  user-select: none;
}
.cfg-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #F59E0B;
}
.cfg-version {
  background: rgba(245, 158, 11, 0.2);
  padding: 1px 6px;
  border-radius: 3px;
  font-size: 0.55rem;
  color: #F59E0B;
}
.cfg-hint {
  margin-left: auto;
  opacity: 0.45;
  font-size: 0.55rem;
}
.cfg-close {
  background: none; border: none;
  color: #F59E0B;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0 4px;
  opacity: 0.6;
  transition: opacity 0.2s;
  margin-left: 8px;
}
.cfg-close:hover { opacity: 1; }

/* Body */
.cfg-body {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
}

/* Table layout */
.cfg-table { width: 100%; border-collapse: collapse; }
.cfg-table tr { border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
.cfg-table tr:last-child { border-bottom: none; }
.cfg-label {
  padding: 6px 8px 6px 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.65rem;
  white-space: nowrap;
  vertical-align: middle;
  width: 38%;
}
.cfg-input-cell {
  padding: 4px 0;
  vertical-align: middle;
}
.cfg-input-cell input,
.cfg-input-cell select {
  width: 100%;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  color: #e2e8f0;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 5px 8px;
  outline: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.cfg-input-cell input:focus,
.cfg-input-cell select:focus {
  border-color: rgba(245, 158, 11, 0.6);
}
.cfg-input-cell select { cursor: pointer; }
.cfg-input-cell select option {
  background: #1a1a2e;
  color: #e2e8f0;
}

/* Footer */
.cfg-footer {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.03);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  gap: 8px;
  align-items: center;
}
.cfg-btn {
  padding: 5px 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: all 0.2s;
}
.cfg-btn-save {
  background: rgba(16, 185, 129, 0.2);
  color: #10B981;
  border-color: rgba(16, 185, 129, 0.4);
}
.cfg-btn-save:hover { background: rgba(16, 185, 129, 0.35); }
.cfg-btn-reset {
  background: rgba(239, 68, 68, 0.12);
  color: #EF4444;
  border-color: rgba(239, 68, 68, 0.25);
}
.cfg-btn-reset:hover { background: rgba(239, 68, 68, 0.28); }
.cfg-status {
  margin-left: auto;
  font-size: 0.6rem;
  color: rgba(255, 255, 255, 0.5);
}
.cfg-status.saving { color: #F59E0B; }
.cfg-status.success { color: #10B981; }
.cfg-status.error { color: #EF4444; }

/* Responsive */
@media (max-width: 768px) {
  .cfg-panel { width: calc(100vw - 32px); left: 16px; bottom: 38px; }
  .cfg-hint { display: none; }
}


/* Enforce [hidden] attr over .btn/.fab-* display rules */
[hidden] { display: none !important; }
