/* ═══════════════════════════════════════════════════════════
   ELEVENLABS AFFILIATE — WORLD CLASS LANDING PAGE
   "The Voice Dimension"
   ═══════════════════════════════════════════════════════════ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --black: #000000;
  --white: #ffffff;
  --off-white: #f5f4f0;
  --gold: #c8a84b;
  --gold-light: #f0d080;
  --teal: #00d4c8;
  --teal-dim: #00a89f;
  --purple: #9b6dff;
  --purple-dim: #7b4ddf;
  --blue: #3b82f6;
  --orange: #f97316;
  --grey-900: #0a0a0a;
  --grey-800: #141414;
  --grey-700: #1e1e1e;
  --grey-600: #2a2a2a;
  --grey-400: #666;
  --grey-300: #999;
  --grey-200: #ccc;

  --font-sans: 'Space Grotesk', 'Inter', sans-serif;
  --font-mono: 'Space Mono', monospace;
  --font-inter: 'Inter', sans-serif;

  --panel-w: 100vw;
  --panel-h: 100dvh;
  --nav-h: 64px;
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out-quint: cubic-bezier(0.83, 0, 0.17, 1);
}

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

html {
  scroll-behavior: auto;
  overflow: hidden;
  height: 100%;
}

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-sans);
  overflow: hidden;
  height: 100dvh;
  cursor: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
em { font-style: italic; }

/* ── Custom Cursor ──────────────────────────────────────────── */
#cursor-dot {
  width: 6px; height: 6px;
  background: var(--white);
  border-radius: 50%;
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: width 0.2s, height 0.2s, background 0.2s;
  will-change: transform;
}
#cursor-ring {
  width: 36px; height: 36px;
  border: 1.5px solid rgba(255,255,255,0.4);
  border-radius: 50%;
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.3s var(--ease-out-expo),
              height 0.3s var(--ease-out-expo),
              border-color 0.3s,
              transform 0.08s linear;
  will-change: transform;
}
body.cursor-hovering #cursor-dot { width: 10px; height: 10px; background: var(--teal); }
body.cursor-hovering #cursor-ring { width: 56px; height: 56px; border-color: var(--teal); opacity: 0.7; }
body.cursor-clicking #cursor-dot { transform: translate(-50%, -50%) scale(0.5); }

/* ── Preloader ──────────────────────────────────────────────── */
#preloader {
  position: fixed; inset: 0;
  z-index: 9000;
  background: var(--black);
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.8s var(--ease-out-expo), visibility 0.8s;
}
#preloader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.pre-inner {
  display: flex; flex-direction: column; align-items: center; gap: 32px;
  width: 280px;
}
#pre-canvas { width: 100px; height: 60px; }
.pre-text { display: flex; flex-direction: column; align-items: center; gap: 12px; width: 100%; }
.pre-label { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.2em; color: var(--grey-300); }
.pre-bar { width: 100%; height: 2px; background: var(--grey-700); border-radius: 2px; overflow: hidden; }
.pre-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--teal), var(--purple)); border-radius: 2px; transition: width 0.1s; }
.pre-pct { font-family: var(--font-mono); font-size: 12px; color: var(--grey-200); }

/* ── Nav ────────────────────────────────────────────────────── */
#main-nav {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 500;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 40px;
  background: rgba(0,0,0,0.0);
  backdrop-filter: blur(0px);
  transition: background 0.4s, backdrop-filter 0.4s;
}
#main-nav.scrolled {
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.nav-logo {
  display: flex; align-items: center; gap: 10px;
  font-size: 16px; font-weight: 600; letter-spacing: -0.02em;
}
.nav-logo svg { flex-shrink: 0; }
.nav-logo-text {
  display: flex; flex-direction: column; gap: 2px;
}
.nav-back-link {
  font-family: var(--font-mono);
  font-size: 9px; letter-spacing: 0.14em;
  color: rgba(255,255,255,0.22);
  text-decoration: none; text-transform: uppercase;
  transition: color 0.2s;
  cursor: none;
}
.nav-back-link:hover { color: rgba(255,255,255,0.55); }

.nav-progress {
  display: flex; align-items: center; gap: 12px;
  opacity: 0; transition: opacity 0.4s;
}
#main-nav.scrolled .nav-progress { opacity: 1; }
.np-track {
  width: 120px; height: 2px;
  background: rgba(255,255,255,0.1); border-radius: 2px; overflow: hidden;
}
#np-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--teal), var(--purple));
  border-radius: 2px; transition: width 0.4s var(--ease-out-expo);
}
#nav-section-name { font-size: 11px; letter-spacing: 0.12em; color: var(--grey-300); font-family: var(--font-mono); text-transform: uppercase; }

.nav-cta {
  display: flex; align-items: center; gap: 8px;
  background: var(--white); color: var(--black);
  font-size: 13px; font-weight: 600; letter-spacing: -0.01em;
  padding: 9px 18px; border-radius: 100px;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: 0 8px 30px rgba(255,255,255,0.2); }

/* ── Scroll Container ───────────────────────────────────────── */
#scroll-container {
  position: fixed; inset: 0;
  display: flex; flex-direction: row;
  width: calc(var(--panel-w) * 9);
  height: 100dvh;
  transform: translateX(0);
  transition: transform 0.85s var(--ease-in-out-quint);
  will-change: transform;
  perspective: 1200px;
}

/* ── Panels ─────────────────────────────────────────────────── */
.panel {
  position: relative;
  width: var(--panel-w);
  height: var(--panel-h);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}

/* Panel backgrounds */
#panel-0 { background: var(--black); }
#panel-1 { background: radial-gradient(ellipse at 20% 50%, #0a1628 0%, #000 60%); }
#panel-2 { background: radial-gradient(ellipse at 80% 20%, #0d0d1f 0%, #000 60%); }
#panel-3 { background: radial-gradient(ellipse at 50% 80%, #0a1a10 0%, #000 60%); }
#panel-4 { background: radial-gradient(ellipse at 30% 50%, #150a1f 0%, #000 60%); }
#panel-5 { background: radial-gradient(ellipse at 70% 30%, #1a0a0a 0%, #000 60%); }
#panel-6 { background: radial-gradient(ellipse at 50% 50%, #0a0a1f 0%, #000 60%); }
#panel-7 { background: radial-gradient(ellipse at 20% 80%, #0d1a0a 0%, #000 60%); }
#panel-8 { background: var(--black); }

/* Panel background effects */
.panel-bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  animation: orbFloat 8s ease-in-out infinite alternate;
}
.orb-1 { width: 400px; height: 400px; background: rgba(0,212,200,0.08); top: -100px; left: -100px; }
.orb-2 { width: 300px; height: 300px; background: rgba(155,109,255,0.08); bottom: -50px; right: 10%; animation-delay: -3s; }
.orb-3 { width: 500px; height: 500px; background: rgba(59,130,246,0.07); top: 50%; left: 50%; transform: translate(-50%,-50%); }

@keyframes orbFloat {
  from { transform: translateY(0) scale(1); }
  to { transform: translateY(30px) scale(1.05); }
}

.panel-bg-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
}

/* Canvas overlays */
#waveCanvas, #finale-canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}

/* ── Panel Content Layout ────────────────────────────────────── */
.panel-content {
  position: relative; z-index: 10;
  width: 100%; max-width: 1200px;
  padding: 0 60px;
  padding-top: var(--nav-h);
}

/* ── Typography System ──────────────────────────────────────── */
.section-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.25em;
  color: var(--teal);
  margin-bottom: 20px;
  display: flex; align-items: center; gap: 10px;
}
.section-tag::before {
  content: '';
  display: inline-block;
  width: 20px; height: 1px;
  background: var(--teal);
}
.section-tag.center {
  justify-content: center;
}
.section-tag.center::before { display: none; }

.section-headline {
  font-family: var(--font-sans);
  font-size: clamp(36px, 4.5vw, 64px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  color: var(--white);
}
.section-headline em {
  background: linear-gradient(135deg, var(--teal), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.section-headline.center { text-align: center; }

.section-body {
  font-size: 17px;
  line-height: 1.7;
  color: var(--grey-300);
  margin-bottom: 20px;
  font-weight: 400;
}
.section-body.center { text-align: center; }
.max-600 { max-width: 600px; margin-left: auto; margin-right: auto; }

/* ── Buttons ────────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--white); color: var(--black);
  font-size: 14px; font-weight: 700; letter-spacing: -0.01em;
  padding: 14px 28px; border-radius: 100px;
  position: relative; overflow: hidden;
  transition: transform 0.25s var(--ease-out-expo),
              box-shadow 0.25s var(--ease-out-expo);
  cursor: none;
}
.btn-primary:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 16px 48px rgba(255,255,255,0.25);
}
.btn-primary.btn-sm { font-size: 13px; padding: 11px 22px; margin-top: 32px; display: inline-flex; }
.btn-primary.btn-glow { box-shadow: 0 0 40px rgba(0,212,200,0.3); }
.btn-primary.btn-full { width: 100%; justify-content: center; }

.btn-ripple {
  position: absolute; inset: 0;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(0,212,200,0.3), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
}
.btn-primary:hover .btn-ripple { opacity: 1; }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  background: transparent; color: var(--white);
  font-size: 14px; font-weight: 500;
  padding: 13px 24px; border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.2);
  cursor: none;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}
.btn-ghost:hover { border-color: rgba(255,255,255,0.5); background: rgba(255,255,255,0.05); transform: translateY(-1px); }
.btn-ghost.btn-sm { font-size: 13px; padding: 10px 20px; }
.btn-ghost.btn-full { width: 100%; justify-content: center; }

/* ── Panel 0: Hero ──────────────────────────────────────────── */
.hero-content { display: flex; flex-direction: column; justify-content: center; height: 100%; max-width: 760px; }

.hero-eyebrow {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.2em;
  color: var(--grey-300); margin-bottom: 40px;
}
.dot-pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--teal);
  animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,212,200,0.4); transform: scale(1); }
  50% { box-shadow: 0 0 0 8px rgba(0,212,200,0); transform: scale(1.1); }
}

.hero-headline {
  font-size: clamp(60px, 9vw, 120px);
  font-weight: 800; line-height: 0.95;
  letter-spacing: -0.05em;
  margin-bottom: 32px;
}
.line-wrap { display: block; overflow: hidden; }
.animate-line {
  display: block;
  transform: translateY(110%);
  transition: transform 1s var(--ease-out-expo);
}
.panel-active .animate-line { transform: translateY(0); }
.animate-line:nth-child(1) { transition-delay: 0.1s; }
.line-wrap:nth-child(2) .animate-line { transition-delay: 0.2s; }
.line-wrap:nth-child(3) .animate-line { transition-delay: 0.35s; }

.accent-text {
  background: linear-gradient(135deg, var(--teal) 0%, var(--purple) 50%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  background-size: 200% 200%;
  animation: accentShift 4s ease infinite;
}
@keyframes accentShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.hero-sub {
  font-size: 18px; line-height: 1.7; color: var(--grey-300);
  max-width: 560px; margin-bottom: 40px;
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.8s 0.6s, transform 0.8s 0.6s var(--ease-out-expo);
}
.panel-active .hero-sub { opacity: 1; transform: translateY(0); }

.hero-actions {
  display: flex; align-items: center; gap: 16px; margin-bottom: 60px;
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.8s 0.75s, transform 0.8s 0.75s var(--ease-out-expo);
}
.panel-active .hero-actions { opacity: 1; transform: translateY(0); }

.hero-stats {
  display: flex; align-items: center; gap: 32px;
  opacity: 0;
  transition: opacity 0.8s 0.9s;
}
.panel-active .hero-stats { opacity: 1; }

.stat { display: flex; flex-direction: column; gap: 2px; }
.stat-n { font-size: 28px; font-weight: 800; letter-spacing: -0.04em; font-family: var(--font-sans); }
.stat-unit { font-size: 16px; font-weight: 700; }
.stat-n, .stat-unit { display: inline; }
.stat-label { font-size: 11px; color: var(--grey-400); letter-spacing: 0.08em; text-transform: uppercase; margin-top: 2px; }
.stat-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.1); }

.scroll-hint-arrow {
  position: absolute; bottom: 40px; left: 60px;
  opacity: 0; transform: translateY(10px);
  transition: opacity 0.8s 1.2s, transform 0.8s 1.2s;
  animation: bounceHint 2s 2s ease-in-out infinite;
}
.panel-active .scroll-hint-arrow { opacity: 1; transform: translateY(0); }
@keyframes bounceHint {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}
.sha-inner {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.15em; color: var(--grey-400);
}
.sha-line {
  width: 1px; height: 32px;
  background: linear-gradient(to bottom, transparent, var(--grey-400));
}

/* ── Panel 1: Split Layout ──────────────────────────────────── */
.split-content { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.split-left { display: flex; flex-direction: column; }

.model-badges { display: flex; flex-direction: column; gap: 8px; margin-top: 24px; }
.badge {
  display: flex; align-items: center; gap: 10px;
  font-size: 12px; font-family: var(--font-mono); color: var(--grey-300);
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
  padding: 8px 14px; border-radius: 8px;
  transition: border-color 0.2s, background 0.2s;
}
.badge:hover { background: rgba(255,255,255,0.07); border-color: rgba(255,255,255,0.15); }
.badge-dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.badge-dot.gold { background: var(--gold); box-shadow: 0 0 8px var(--gold); }
.badge-dot.teal { background: var(--teal); box-shadow: 0 0 8px var(--teal); }
.badge-dot.purple { background: var(--purple); box-shadow: 0 0 8px var(--purple); }

/* TTS Demo Card */
.tts-demo-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px; overflow: hidden;
  backdrop-filter: blur(20px);
  box-shadow: 0 40px 80px rgba(0,0,0,0.5);
}
.tdc-header {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.02);
}
.tdc-dots { display: flex; gap: 6px; }
.tdc-dots i { width: 10px; height: 10px; border-radius: 50%; display: block; }
.tdc-dots i:nth-child(1) { background: #ff5f57; }
.tdc-dots i:nth-child(2) { background: #febc2e; }
.tdc-dots i:nth-child(3) { background: #28c840; }
.tdc-header span { font-size: 11px; font-family: var(--font-mono); color: var(--grey-400); flex: 1; text-align: center; }

.tdc-body { padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.tts-textarea {
  width: 100%; background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px; padding: 14px;
  color: var(--white); font-family: var(--font-inter); font-size: 14px; line-height: 1.6;
  resize: none; height: 100px;
  transition: border-color 0.2s;
  cursor: none;
}
.tts-textarea:focus { outline: none; border-color: rgba(0,212,200,0.4); }
.tts-textarea::placeholder { color: var(--grey-400); }

.tdc-controls { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.voice-selector label { font-size: 10px; letter-spacing: 0.12em; color: var(--grey-400); font-family: var(--font-mono); margin-bottom: 8px; display: block; }
.vs-options { display: flex; gap: 6px; flex-wrap: wrap; }
.vs-btn {
  font-size: 12px; font-family: var(--font-mono);
  padding: 5px 12px; border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.1);
  background: transparent; color: var(--grey-300);
  cursor: none; transition: all 0.2s;
}
.vs-btn:hover { border-color: rgba(255,255,255,0.3); color: var(--white); }
.vs-btn.active { background: var(--teal); border-color: var(--teal); color: var(--black); font-weight: 700; }

.play-btn {
  display: flex; align-items: center; gap: 10px;
  background: var(--teal); color: var(--black);
  border: none; border-radius: 100px;
  padding: 10px 20px; font-size: 13px; font-weight: 700; font-family: var(--font-sans);
  cursor: none; flex-shrink: 0;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.play-btn:hover { transform: scale(1.04); box-shadow: 0 8px 24px rgba(0,212,200,0.4); }
.play-btn.playing { background: rgba(255,255,255,0.1); color: var(--white); }

.waveform-container {
  position: relative; background: rgba(0,0,0,0.3);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px; overflow: hidden; height: 64px;
}
#waveform-canvas { width: 100%; height: 100%; display: none; }
.wf-placeholder {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  color: var(--grey-400); font-size: 12px; font-family: var(--font-mono);
}

.tdc-note { font-size: 11px; color: var(--grey-400); font-family: var(--font-mono); text-align: center; }
.tdc-note a { color: var(--teal); }

/* ── Panel 2: Clone ─────────────────────────────────────────── */
.centered-content {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  max-width: 800px; margin: 0 auto;
}

.clone-visual {
  position: relative; width: 160px; height: 160px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 40px;
}
.cv-ring {
  position: absolute; border-radius: 50%;
  border: 1px solid rgba(0,212,200,0.3);
  animation: ringPulse 3s ease-in-out infinite;
}
.ring-1 { width: 80px; height: 80px; animation-delay: 0s; }
.ring-2 { width: 120px; height: 120px; animation-delay: 0.5s; opacity: 0.6; }
.ring-3 { width: 160px; height: 160px; animation-delay: 1s; opacity: 0.3; }
@keyframes ringPulse {
  0%, 100% { transform: scale(1); opacity: var(--o, 1); }
  50% { transform: scale(1.08); }
}
.cv-core {
  width: 64px; height: 64px; border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--purple));
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 40px rgba(0,212,200,0.4);
  animation: coreGlow 2s ease-in-out infinite;
}
@keyframes coreGlow {
  0%, 100% { box-shadow: 0 0 40px rgba(0,212,200,0.4); }
  50% { box-shadow: 0 0 70px rgba(0,212,200,0.7), 0 0 120px rgba(155,109,255,0.3); }
}

.clone-features { display: flex; flex-direction: column; gap: 16px; width: 100%; margin: 32px 0; text-align: left; }
.cf-item {
  display: flex; align-items: flex-start; gap: 20px;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px; padding: 20px;
  transition: border-color 0.2s, transform 0.2s;
}
.cf-item:hover { border-color: rgba(0,212,200,0.3); transform: translateX(4px); }
.cf-icon { font-size: 24px; width: 40px; flex-shrink: 0; }
.cf-text { display: flex; flex-direction: column; gap: 4px; }
.cf-text strong { font-size: 15px; font-weight: 600; color: var(--white); }
.cf-text span { font-size: 14px; color: var(--grey-300); line-height: 1.5; }

/* ── Panel 3: Agents ────────────────────────────────────────── */
.agents-content { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.agents-left { display: flex; flex-direction: column; }

.agent-numbers { display: flex; gap: 32px; margin: 32px 0; }
.an-item { display: flex; flex-direction: column; gap: 4px; }
.an-big { font-size: 40px; font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.an-label { font-size: 11px; color: var(--grey-400); letter-spacing: 0.08em; }

/* Chat Demo */
.chat-demo {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px; overflow: hidden;
  backdrop-filter: blur(20px);
  box-shadow: 0 40px 80px rgba(0,0,0,0.5);
  height: 480px; display: flex; flex-direction: column;
}
.cd-header {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.02);
}
.cd-avatar {
  position: relative; width: 40px; height: 40px;
  border-radius: 50%; background: linear-gradient(135deg, var(--teal), var(--purple));
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.avatar-pulse {
  position: absolute; inset: -4px;
  border-radius: 50%; border: 2px solid var(--teal);
  animation: avatarPulse 2s ease-in-out infinite;
}
@keyframes avatarPulse {
  0%, 100% { opacity: 0.6; transform: scale(1); }
  50% { opacity: 0; transform: scale(1.3); }
}
.cd-info { flex: 1; }
.cd-info strong { display: block; font-size: 14px; font-weight: 600; }
.cd-info span { font-size: 11px; color: var(--grey-400); }
.cd-live {
  display: flex; align-items: center; gap: 6px;
  font-size: 10px; font-family: var(--font-mono); letter-spacing: 0.1em; color: #4ade80;
}
.cd-live span {
  width: 6px; height: 6px; border-radius: 50%; background: #4ade80;
  animation: liveBlink 1.5s ease-in-out infinite;
}
@keyframes liveBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.cd-messages {
  flex: 1; overflow-y: auto; padding: 20px;
  display: flex; flex-direction: column; gap: 12px;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.cd-messages::-webkit-scrollbar { width: 4px; }
.cd-messages::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 2px; }

.chat-msg {
  max-width: 80%; padding: 10px 14px;
  border-radius: 14px; font-size: 13px; line-height: 1.5;
  animation: msgPop 0.3s var(--ease-out-expo);
}
@keyframes msgPop {
  from { transform: translateY(8px) scale(0.96); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}
.chat-msg.user {
  background: rgba(255,255,255,0.08); color: var(--white);
  align-self: flex-end; border-bottom-right-radius: 4px;
}
.chat-msg.agent {
  background: rgba(0,212,200,0.12); color: var(--white);
  border: 1px solid rgba(0,212,200,0.2);
  align-self: flex-start; border-bottom-left-radius: 4px;
}
.chat-msg.typing {
  display: flex; gap: 4px; align-items: center; height: 36px;
}
.typing-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--teal);
  animation: typingBounce 1.2s ease-in-out infinite;
}
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce {
  0%, 100% { transform: translateY(0); opacity: 0.4; }
  50% { transform: translateY(-4px); opacity: 1; }
}

.cd-input {
  padding: 16px 20px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex; gap: 10px; align-items: center;
}
.cd-input input {
  flex: 1; background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1); border-radius: 100px;
  padding: 10px 16px; color: var(--white); font-size: 13px; font-family: var(--font-sans);
  cursor: none;
}
.cd-input input:focus { outline: none; border-color: rgba(0,212,200,0.3); }
#chat-send {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--teal); border: none; color: var(--black);
  display: flex; align-items: center; justify-content: center;
  cursor: none; transition: transform 0.2s, box-shadow 0.2s;
}
#chat-send:hover { transform: scale(1.1); box-shadow: 0 4px 16px rgba(0,212,200,0.4); }

/* ── Panel 4: Dubbing / Globe ────────────────────────────────── */
.dubbing-content {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 80px; align-items: center;
}
.globe-container {
  display: flex; align-items: center; justify-content: center;
  width: 100%; aspect-ratio: 1;
}
#globe-canvas { width: 100%; height: 100%; }

.lang-ticker {
  overflow: hidden; white-space: nowrap;
  margin: 24px 0; padding: 10px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.lt-inner {
  display: inline-flex; gap: 24px;
  font-family: var(--font-mono); font-size: 12px; color: var(--grey-400); letter-spacing: 0.08em;
  animation: tickerScroll 30s linear infinite;
}
.lt-inner span { flex-shrink: 0; }
@keyframes tickerScroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ── Panel 5: Use Cards ─────────────────────────────────────── */
.uses-content { display: flex; flex-direction: column; align-items: center; }
.use-cards {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 48px; width: 100%;
}
.uc-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px; padding: 28px;
  opacity: 0; transform: translateY(30px);
  transition: opacity 0.6s var(--ease-out-expo),
              transform 0.6s var(--ease-out-expo),
              border-color 0.2s,
              background 0.2s;
}
.uc-card.visible { opacity: 1; transform: translateY(0); }
.uc-card:hover { border-color: rgba(255,255,255,0.15); background: rgba(255,255,255,0.05); }
.uc-icon { font-size: 32px; margin-bottom: 16px; }
.uc-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 10px; letter-spacing: -0.02em; }
.uc-card p { font-size: 13px; color: var(--grey-300); line-height: 1.6; margin-bottom: 16px; }
.uc-tag { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em; color: var(--teal); }

/* ── Panel 6: Testimonials ──────────────────────────────────── */
.proof-content { display: flex; flex-direction: column; align-items: center; }
.testimonials { position: relative; width: 100%; max-width: 700px; min-height: 180px; margin: 48px 0 24px; }
.testi-card {
  position: absolute; inset: 0;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px; padding: 40px;
  opacity: 0; transform: translateX(30px) scale(0.97);
  transition: opacity 0.5s var(--ease-out-expo), transform 0.5s var(--ease-out-expo);
  pointer-events: none;
}
.testi-card.active { opacity: 1; transform: translateX(0) scale(1); pointer-events: auto; }
.tc-quote { font-size: 20px; line-height: 1.55; font-style: italic; color: var(--white); margin-bottom: 24px; }
.tc-author { display: flex; align-items: center; gap: 14px; }
.tca-info strong { display: block; font-size: 14px; font-weight: 600; }
.tca-info span { font-size: 12px; color: var(--grey-400); }

.testi-dots { display: flex; gap: 8px; margin-bottom: 48px; }
.td {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,0.2); border: none;
  cursor: none; transition: background 0.2s, transform 0.2s;
}
.td.active { background: var(--teal); transform: scale(1.3); }

.logo-strip { width: 100%; text-align: center; }
.ls-label { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.2em; color: var(--grey-400); margin-bottom: 20px; }
.ls-logos { display: flex; align-items: center; justify-content: center; gap: 32px; flex-wrap: wrap; }
.ls-logo {
  font-size: 14px; font-weight: 700; letter-spacing: -0.01em;
  color: rgba(255,255,255,0.25);
  transition: color 0.2s;
}
.ls-logo:hover { color: rgba(255,255,255,0.7); }

/* ── Panel 7: Pricing ───────────────────────────────────────── */
.pricing-content { display: flex; flex-direction: column; align-items: center; }
.pricing-cards {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin: 48px 0 32px; width: 100%;
  align-items: start;
}
.price-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px; padding: 32px;
  display: flex; flex-direction: column; gap: 16px;
  position: relative; overflow: hidden;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.price-card:hover { transform: translateY(-4px); box-shadow: 0 20px 60px rgba(0,0,0,0.5); }
.price-card.featured {
  border-color: rgba(0,212,200,0.3);
  background: rgba(0,212,200,0.05);
  box-shadow: 0 0 60px rgba(0,212,200,0.1);
}
.price-card.featured:hover { box-shadow: 0 20px 80px rgba(0,212,200,0.2); }
.pc-badge {
  position: absolute; top: 0; right: 0;
  background: var(--teal); color: var(--black);
  font-size: 9px; font-weight: 800; letter-spacing: 0.12em; font-family: var(--font-mono);
  padding: 6px 14px; border-radius: 0 20px 0 12px;
}
.pc-tier { font-size: 13px; font-weight: 700; letter-spacing: 0.1em; color: var(--grey-300); text-transform: uppercase; font-family: var(--font-mono); }
.pc-price { font-size: 52px; font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.pc-price span { font-size: 16px; font-weight: 400; color: var(--grey-400); }
.pc-sub { font-size: 13px; color: var(--grey-400); }
.pc-features { list-style: none; display: flex; flex-direction: column; gap: 10px; margin: 8px 0; }
.pc-features li {
  font-size: 13px; color: var(--grey-200);
  display: flex; align-items: center; gap: 10px;
}
.pc-features li::before {
  content: '✓'; color: var(--teal);
  font-weight: 700; font-size: 12px; flex-shrink: 0;
}

.startup-banner {
  width: 100%;
  display: flex; align-items: center; gap: 20px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px; padding: 20px 24px;
  transition: border-color 0.2s;
}
.startup-banner:hover { border-color: rgba(200,168,75,0.3); }
.sb-icon { font-size: 28px; flex-shrink: 0; }
.sb-text { flex: 1; }
.sb-text strong { display: block; font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.sb-text span { font-size: 12px; color: var(--grey-400); }

/* ── Panel 8: Finale ────────────────────────────────────────── */
.finale-content {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  max-width: 700px; margin: 0 auto;
}
.finale-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(200,168,75,0.1); border: 1px solid rgba(200,168,75,0.3);
  color: var(--gold); font-size: 12px; font-family: var(--font-mono); letter-spacing: 0.1em;
  padding: 8px 18px; border-radius: 100px; margin-bottom: 40px;
}
.finale-headline {
  font-size: clamp(52px, 8vw, 100px);
  font-weight: 800; line-height: 1;
  letter-spacing: -0.04em; margin-bottom: 28px;
}
.finale-accent {
  background: linear-gradient(135deg, var(--teal), var(--purple), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  background-size: 200% 200%;
  animation: accentShift 3s ease infinite;
}
.finale-sub { font-size: 18px; color: var(--grey-300); line-height: 1.6; max-width: 480px; margin-bottom: 48px; }

.btn-finale {
  display: inline-flex; align-items: center; gap: 0;
  background: var(--white); color: var(--black);
  border-radius: 100px; overflow: hidden;
  font-weight: 700; font-size: 16px;
  box-shadow: 0 0 60px rgba(255,255,255,0.15);
  transition: transform 0.3s var(--ease-out-expo), box-shadow 0.3s;
  cursor: none;
}
.btn-finale:hover {
  transform: scale(1.04) translateY(-3px);
  box-shadow: 0 20px 60px rgba(255,255,255,0.35);
}
.bf-text { padding: 18px 32px; }
.bf-arrow {
  background: var(--black); color: var(--white);
  width: 56px; height: 56px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 0 100px 100px 0;
}

.finale-note { font-size: 12px; color: var(--grey-400); font-family: var(--font-mono); letter-spacing: 0.08em; margin-top: 20px; }

.finale-footer {
  display: flex; align-items: center; gap: 16px;
  margin-top: 60px; font-size: 12px; color: var(--grey-400);
}
.finale-footer a:hover { color: var(--white); }

/* ── Panel Nav Dots ─────────────────────────────────────────── */
#panel-dots {
  position: fixed; right: 32px; top: 50%;
  transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 10px;
  z-index: 200;
}
.pd {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,0.2); border: none;
  cursor: none;
  transition: background 0.3s, transform 0.3s, box-shadow 0.3s;
}
.pd:hover { background: rgba(255,255,255,0.5); transform: scale(1.3); }
.pd.active { background: var(--white); box-shadow: 0 0 12px rgba(255,255,255,0.5); transform: scale(1.2); }

/* ── Panel Entry Animations ─────────────────────────────────── */
.panel-content { opacity: 0; }
.panel.panel-active .panel-content { animation: panelEnter 0.75s var(--ease-out-expo) 0.1s forwards; }

@keyframes panelEnter {
  from { opacity: 0; transform: translateY(30px) scale(0.99); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* But hero panel content starts visible after preloader */
#panel-0 .panel-content { animation: none; }
#panel-0.panel-active .panel-content { opacity: 1; transform: none; }

/* Panel active slide text animations fire too */
.panel.panel-active .section-tag { animation: tagSlide 0.6s var(--ease-out-expo) 0.2s both; }
.panel.panel-active .section-headline { animation: headlineSlide 0.8s var(--ease-out-expo) 0.3s both; }
.panel.panel-active .section-body { animation: bodyFade 0.8s ease 0.5s both; }

@keyframes tagSlide {
  from { opacity: 0; transform: translateX(-16px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes headlineSlide {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes bodyFade {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Noise Texture Overlay ──────────────────────────────────── */
body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.025;
  pointer-events: none;
  z-index: 8000;
  mix-blend-mode: overlay;
}

/* ── Floating Audio Bar ─────────────────────────────────────── */
#audio-bar {
  position: fixed; bottom: 28px; left: 50%;
  transform: translateX(-50%);
  z-index: 300;
  display: flex; align-items: center; gap: 3px;
  background: rgba(0,0,0,0.6);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(20px);
  border-radius: 100px;
  padding: 10px 18px;
  pointer-events: none;
  opacity: 0.6;
  transition: opacity 0.4s;
}
#audio-bar:hover { opacity: 1; }
.ab-bar {
  width: 3px;
  background: var(--teal);
  border-radius: 2px;
  animation: abAnimate 1.2s ease-in-out infinite;
  transform-origin: bottom center;
}
.ab-bar:nth-child(1) { height: 8px; animation-delay: 0s; }
.ab-bar:nth-child(2) { height: 14px; animation-delay: 0.1s; }
.ab-bar:nth-child(3) { height: 20px; animation-delay: 0.2s; }
.ab-bar:nth-child(4) { height: 12px; animation-delay: 0.15s; }
.ab-bar:nth-child(5) { height: 18px; animation-delay: 0.05s; }
.ab-bar:nth-child(6) { height: 10px; animation-delay: 0.25s; }
.ab-bar:nth-child(7) { height: 16px; animation-delay: 0.3s; }
.ab-bar:nth-child(8) { height: 8px; animation-delay: 0.1s; }
@keyframes abAnimate {
  0%, 100% { transform: scaleY(0.4); opacity: 0.5; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* ── Transition Overlay ─────────────────────────────────────── */
#transition-overlay {
  position: fixed; inset: 0;
  background: var(--black);
  z-index: 400;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s;
}
#transition-overlay.flash { opacity: 0.15; }

/* ── Keyboard hint ──────────────────────────────────────────── */
.kb-hint {
  position: fixed; bottom: 28px; right: 60px;
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.12em;
  color: rgba(255,255,255,0.2);
  display: flex; align-items: center; gap: 8px;
  z-index: 200;
  transition: opacity 0.5s;
}
.kb-key {
  padding: 3px 7px;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 4px;
  font-size: 10px;
}
.kb-hint.hidden { opacity: 0; }

/* ── Glitch Text Effect ─────────────────────────────────────── */
.glitch {
  position: relative;
  animation: glitchMain 6s infinite;
}
.glitch::before, .glitch::after {
  content: attr(data-text);
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%;
  animation: glitchClip 6s infinite;
}
.glitch::before {
  color: var(--teal);
  animation-delay: 0.1s;
  clip-path: polygon(0 30%, 100% 30%, 100% 50%, 0 50%);
}
.glitch::after {
  color: var(--purple);
  animation-delay: -0.1s;
  clip-path: polygon(0 60%, 100% 60%, 100% 80%, 0 80%);
}
@keyframes glitchMain {
  0%, 90%, 100% { transform: translate(0); }
  92% { transform: translate(-2px, 1px); }
  94% { transform: translate(2px, -1px); }
  96% { transform: translate(-1px, 2px); }
}
@keyframes glitchClip {
  0%, 90%, 100% { transform: translate(0); opacity: 0; }
  92% { transform: translate(-3px); opacity: 0.8; }
  94% { transform: translate(3px); opacity: 0.8; }
  96% { transform: translate(0); opacity: 0; }
}

/* ── Scrollbar ──────────────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 2px; }

/* ── Panel overflow for tall content ────────────────────────── */
.panel-content.has-overflow {
  overflow-y: auto;
  padding-bottom: 40px;
}
.panel-content.has-overflow::-webkit-scrollbar { display: none; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .panel-content { padding: 0 40px; padding-top: var(--nav-h); }
  .split-content, .agents-content, .dubbing-content {
    grid-template-columns: 1fr; gap: 40px;
    overflow-y: auto; max-height: 100dvh;
    padding-bottom: 40px;
  }
  .split-right { max-width: 600px; }
  .use-cards { grid-template-columns: repeat(2, 1fr); }
  .pricing-cards { grid-template-columns: 1fr; max-width: 400px; }
  .hero-headline { font-size: clamp(42px, 10vw, 80px); }
  .chat-demo { height: 380px; }
  /* Tall-content panels: top-align so overflow scrolls from the top */
  #panel-2, #panel-5, #panel-6, #panel-7 { align-items: flex-start; }
  .pricing-content, .uses-content, .proof-content, .centered-content {
    overflow-y: auto;
    max-height: calc(100dvh - var(--nav-h) - 12px);
    padding-bottom: 32px;
    width: 100%;
  }
}

@media (max-width: 768px) {
  #main-nav { padding: 0 20px; }
  .nav-progress { display: none; }
  .kb-hint { display: none; }
  .panel-content { padding: 0 24px; padding-top: var(--nav-h); }
  .hero-headline { font-size: clamp(36px, 12vw, 64px); }
  .hero-stats { gap: 16px; flex-wrap: wrap; }
  .stat-n { font-size: 22px; }
  .use-cards { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; align-items: flex-start; gap: 12px; }
  .agent-numbers { flex-direction: column; gap: 12px; }
  .pricing-cards { max-width: 100%; grid-template-columns: 1fr; }
  .split-content { grid-template-columns: 1fr; gap: 24px; overflow-y: auto; }
  #panel-dots { right: 12px; }
  .pd { width: 6px; height: 6px; }
  .agents-content { grid-template-columns: 1fr; overflow-y: auto; }
  .dubbing-content { grid-template-columns: 1fr; }
  .globe-container { display: none; }
  .clone-visual { width: 120px; height: 120px; margin-bottom: 24px; }
  .finale-headline { font-size: clamp(40px, 14vw, 72px); }
  .logo-strip .ls-logos { gap: 16px; }
  #audio-bar { display: none; }
  .section-headline { font-size: clamp(28px, 7vw, 48px); }
  .chat-demo { height: 340px; }
  .tts-demo-card { margin-top: 0; }
  /* Ensure tall panels top-align on mobile so content is reachable from top */
  #panel-1, #panel-3, #panel-4 { align-items: flex-start; }
  .split-content, .agents-content, .dubbing-content {
    max-height: calc(100dvh - var(--nav-h) - 12px);
  }
  .finale-content {
    overflow-y: auto;
    max-height: calc(100dvh - var(--nav-h) - 12px);
    padding-bottom: 32px;
  }
  /* Show text cursor inside the TTS textarea on mobile */
  .tts-textarea { cursor: text; }
}
