/* ========================================================================= */
/* AER BENDER V1 — SPATIAL UI & AUGMENTED REALITY CANVAS STYLESHEET          */
/* Fusion of Spatial Glassmorphism, Immersive Dark Canvas & Minimalist HUD   */
/* Fullscreen Camera Viewport with Floating Glassmorphic Studio Dock         */
/* ========================================================================= */

@import url("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Space+Grotesk:wght@500;600;700;800&display=swap");

:root {
  /* Spatial Canvas Foundations */
  --bg-deep: #05070c;
  --bg-space: radial-gradient(circle at 50% 12%, rgba(22, 32, 54, 0.35) 0%, #05070c 85%);

  /* Frosted Glass Design Tokens */
  --glass-surface: rgba(14, 18, 30, 0.52);
  --glass-surface-hover: rgba(22, 28, 46, 0.72);
  --glass-surface-subtle: rgba(10, 14, 24, 0.4);
  --glass-chip: rgba(255, 255, 255, 0.05);
  --glass-chip-hover: rgba(255, 255, 255, 0.12);

  --glass-border: 1px solid rgba(255, 255, 255, 0.12);
  --glass-border-subtle: 1px solid rgba(255, 255, 255, 0.08);
  --glass-border-specular: 1px solid rgba(255, 255, 255, 0.24);

  --glass-shadow: 0 16px 40px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.16);
  --glass-shadow-soft: 0 8px 24px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  --glass-shadow-chip: 0 4px 14px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.15);

  --glass-blur-heavy: blur(32px) saturate(200%);
  --glass-blur: blur(24px) saturate(180%);
  --glass-blur-subtle: blur(14px) saturate(160%);

  /* Chromatic Accents */
  --accent-emerald: #10b981;    /* Classical Venu Bamboo Jade */
  --accent-amber: #f59e0b;      /* Golden Resonance / Gamakas */
  --accent-cyan: #00f0ff;       /* Electric Synth Beam */
  --accent-blue: #38bdf8;       /* Spatial High Octave (Tara) */
  --accent-rose: #f43f5e;       /* Signal Recording Pulse */
  --accent-acid: #ccff00;       /* Neon Electric Lime / Brutalist Accent */
  --accent-orange: #ff5500;     /* Neon Sunset Orange / Sthayi High Accent */
  --accent-silver: #e2e8f0;
  --accent-muted: #94a3b8;
  --accent-dim: #64748b;

  /* Typography */
  --font-display: "Space Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", monospace;
}

/* Reset & Viewport Constraints */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}

*::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

html, body {
  height: 100vh;
  height: 100dvh;
  max-height: 100vh;
  max-height: 100dvh;
  width: 100vw;
  max-width: 100vw;
  margin: 0;
  padding: 0;
  overflow: hidden !important;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-deep);
  background-image: var(--bg-space);
  color: var(--accent-silver);
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* Master Workspace Container: Edge-to-Edge Fullscreen */
.app-wrapper {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-height: 100vh;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  overflow: hidden;
  position: relative;
}

/* ========================================================================= */
/* 1. UNOBTRUSIVE SPATIAL CORNER NAVIGATION (OPEN CENTER AR CANVAS)          */
/* ========================================================================= */
.app-header.spatial-nav-bar {
  position: absolute;
  top: 10px;
  left: 14px;
  right: 14px;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  pointer-events: none;
}

.header-corner-pod {
  pointer-events: auto;
  display: flex;
  align-items: center;
  background: var(--glass-surface);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: var(--glass-border);
  border-radius: 999px;
  padding: 5px 14px;
  box-shadow: var(--glass-shadow);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.header-corner-pod:hover {
  background: var(--glass-surface-hover);
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.24);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 35% 35%, rgba(56, 189, 248, 0.25) 0%, rgba(8, 12, 22, 0.90) 100%);
  border: 1px solid rgba(56, 189, 248, 0.48);
  border-radius: 50%;
  color: #38bdf8;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.35), inset 0 1px 1px rgba(255, 255, 255, 0.25);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.header-left-pod:hover .logo-mark {
  transform: rotate(120deg) scale(1.06);
  box-shadow: 0 0 24px rgba(56, 189, 248, 0.65), inset 0 1px 1px rgba(255, 255, 255, 0.4);
  border-color: rgba(56, 189, 248, 0.7);
}

.brand-titles {
  display: flex;
  align-items: center;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: #ffffff;
  text-shadow: 0 2px 14px rgba(255, 255, 255, 0.28);
  white-space: nowrap;
  line-height: 1;
  margin: 0;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.record-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

.record-mode-select {
  background: rgba(14, 18, 30, 0.65);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  color: #e2e8f0;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 600;
  padding: 5px 10px;
  cursor: pointer;
  outline: none;
  transition: all 0.2s ease;
}

.record-mode-select:hover {
  background: rgba(25, 32, 52, 0.85);
  border-color: rgba(255, 255, 255, 0.3);
}

.record-mode-select option {
  background: #0b0d14;
  color: #f1f5f9;
}

.btn-record {
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.4);
  color: #fca5a5;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 0 12px rgba(244, 63, 94, 0.2);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-record:hover {
  background: rgba(244, 63, 94, 0.28);
  border-color: #f43f5e;
  color: #ffffff;
  box-shadow: 0 0 20px rgba(244, 63, 94, 0.45);
  transform: translateY(-1px);
}

.btn-record.recording {
  background: linear-gradient(135deg, #f43f5e, #e11d48);
  color: #ffffff;
  border-color: #fda4af;
  box-shadow: 0 0 24px rgba(244, 63, 94, 0.7);
  animation: pulse-rec 1.2s infinite;
}

@keyframes pulse-rec {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.88; transform: scale(0.98); }
}

.rec-dot {
  width: 7px;
  height: 7px;
  background-color: #f43f5e;
  border-radius: 50%;
  box-shadow: 0 0 8px #f43f5e;
}

.btn-record.recording .rec-dot {
  background-color: #ffffff;
  box-shadow: 0 0 10px #ffffff;
}

.rec-timer {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: #fca5a5;
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.35);
  border-radius: 999px;
  padding: 3px 8px;
}

.btn-pill {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  color: #cbd5e1;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  padding: 5px 12px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.btn-pill:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-electric {
  color: #cbd5e1;
}

.btn-electric.active {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.3), rgba(6, 182, 212, 0.45));
  border-color: #00f0ff;
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 0 18px rgba(0, 240, 255, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* ⚡ Electric vs. 🪈 Carnatic Segmented 2-Button Control */
.timbre-segmented-control {
  display: inline-flex;
  align-items: center;
  background: rgba(10, 15, 28, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.5), 0 4px 14px rgba(0, 0, 0, 0.3);
}

.segmented-btn {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1;
}

.segmented-btn .btn-icon {
  font-size: 13px;
}

.segmented-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}

.segmented-btn.active#modeElectricBtn {
  background: #06b6d4;
  color: #020617;
  font-weight: 800;
  box-shadow: 0 0 16px rgba(6, 182, 212, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  padding: 6px 12px;
  justify-content: center;
}

.segmented-btn.active#modeCarnaticBtn,
#modeCarnaticBtn {
  display: none !important;
}

.pill-info.electric-active {
  background: rgba(0, 240, 255, 0.2);
  border-color: #00f0ff;
  color: #00f0ff;
  font-weight: 700;
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.45);
}

#tanpuraToggleBtn.active {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.85), rgba(5, 150, 105, 0.9));
  border-color: #34d399;
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 0 18px rgba(16, 185, 129, 0.5);
}

/* ========================================================================= */
/* 2. FULLSCREEN AR CAMERA WORKSPACE & CAMERA CANVAS                         */
/* ========================================================================= */
.main-content {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden !important;
  display: block;
}

.main-content.dock-collapsed {
  /* Main content covers full screen */
}

/* Performance Panel: Absolute Fullscreen Backdrop */
.performance-panel {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  overflow: hidden !important;
}

.camera-card {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  margin: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  overflow: hidden;
}

/* Camera Card Header - Hidden as optical tracking viewport text removed */
.camera-card-header {
  display: none !important;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  gap: 8px;
}

.title-with-tag {
  display: flex;
  align-items: center;
  gap: 6px;
}

.section-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: #38bdf8;
  opacity: 0.85;
}

.card-header h3,
.visualizer-card .card-header h3 {
  font-family: var(--font-display) !important;
  font-size: 11.5px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.3px;
  text-transform: none !important;
}

.pill-info {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  color: var(--accent-muted);
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 2px 7px;
  letter-spacing: 0.4px;
}

/* Camera Viewport — Edge-to-Edge Fullscreen AR Canvas */
.camera-container {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
  border: none;
  overflow: hidden;
  background: #020306;
  box-shadow: none;
}

.camera-container video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scaleX(-1);
}

.camera-container canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  image-rendering: -webkit-optimize-contrast;
}

/* Minimalist HUD Overlay on Camera */
.hud-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 12px;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%, transparent 40%, rgba(0, 0, 0, 0.35) 100%);
}

/* Spatial Glass Octave Bar — Anchored securely on Left side so studio controls NEVER overlap */
.spatial-octave-bar,
.vertical-octave-bar {
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  position: absolute;
  top: 76px;
  left: 18px;
  background: rgba(10, 14, 24, 0.72);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  padding: 4px;
  gap: 3px;
  user-select: none;
  z-index: 25;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.55), 0 0 20px rgba(0, 0, 0, 0.4);
  transition: opacity 0.3s ease;
}

.main-content.dock-collapsed .spatial-octave-bar {
  left: 18px;
}

.octave-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5px 9px;
  border-radius: 10px;
  border: 1px solid transparent;
  transition: all 0.15s ease;
  opacity: 0.55;
  cursor: pointer;
}

.octave-zone.active {
  opacity: 1;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.18);
}

.octave-zone .zone-tag {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.2;
}

.octave-zone.active .zone-tag {
  color: #ffffff;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
}

.octave-zone .zone-sub {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--accent-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

#zoneTara.active {
  border-color: rgba(249, 115, 22, 0.6);
  background: rgba(249, 115, 22, 0.22);
}

#zoneMadhya.active {
  border-color: rgba(16, 185, 129, 0.6);
  background: rgba(16, 185, 129, 0.22);
}

#zoneMandra.active {
  border-color: rgba(59, 130, 246, 0.6);
  background: rgba(59, 130, 246, 0.22);
}

.mouth-aperture-meter {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 2px;
}

.mouth-aperture-fill {
  height: 100%;
  background: linear-gradient(90deg, #818cf8, #94a3b8, #fb923c);
  border-radius: 999px;
  transition: width 0.08s ease;
}

.flute-pos-cursor {
  display: none;
}

/* Spatial Glass 7 Tone Holes Visual Bar at Bottom of Camera */
/* Pre-play Flute Placement Instruction — floats above the flute area */
.hud-placement-prompt {
  position: absolute;
  top: 32%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 22;
  pointer-events: none;
  background: rgba(10, 14, 24, 0.78);
  backdrop-filter: var(--glass-blur-subtle);
  -webkit-backdrop-filter: var(--glass-blur-subtle);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 12px;
  padding: 10px 22px;
  max-width: 520px;
  text-align: center;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.5), 0 0 16px rgba(16, 185, 129, 0.15);
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  animation: placementPulse 2.4s ease-in-out infinite;
}

.hud-placement-prompt p {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.5;
  letter-spacing: 0.2px;
  margin: 0;
}

.hud-placement-prompt p strong {
  color: var(--accent-emerald);
  font-weight: 700;
}

.hud-placement-prompt.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) translateY(-8px);
}

@keyframes placementPulse {
  0%, 100% { box-shadow: 0 8px 28px rgba(0, 0, 0, 0.5), 0 0 16px rgba(16, 185, 129, 0.15); }
  50% { box-shadow: 0 8px 28px rgba(0, 0, 0, 0.5), 0 0 24px rgba(16, 185, 129, 0.3); }
}

.hud-holes-bar {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(10, 14, 24, 0.68);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  padding: 5px 14px;
  display: flex;
  justify-content: center;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  pointer-events: auto;
  z-index: 20;
}

.holes-hand-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.holes-row {
  display: flex;
  gap: 6px;
}

.hole-pip {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  user-select: none;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.hole-pip.open {
  background: rgba(10, 14, 24, 0.8);
  border: 1.2px solid rgba(255, 255, 255, 0.18);
  color: var(--accent-dim);
}

.hole-pip.half {
  background: linear-gradient(90deg, #10b981 50%, rgba(10, 14, 24, 0.8) 50%);
  border: 1.2px solid #10b981;
  color: #ffffff;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

.hole-pip.closed {
  background: linear-gradient(135deg, #ffffff, #cbd5e1);
  border: 1.2px solid #ffffff;
  color: #090a0f;
  font-weight: 800;
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.8);
  transform: scale(1.08);
}

/* Center Camera Launch / Welcome Glass Card with Giant Celestial Spherical Aura */
.camera-welcome-overlay {
  position: absolute;
  top: 34%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 40;
  pointer-events: auto;
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1), transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.camera-welcome-overlay.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -48%) scale(0.95);
}

/* Octave Resonance Floor Aura beneath Levitating Flute */
/* Anchored to floor plane; projects Tara (Coral) -> Madhya (Emerald Teal) -> Mandra (Royal Blue) */
.welcome-sphere-aura {
  position: absolute;
  top: calc(50% + 260px);
  left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(520px, 62vw, 860px);
  height: clamp(75px, 10vw, 130px);
  border-radius: 50%;
  background: radial-gradient(
    ellipse at 50% 50%,
    rgba(249, 115, 22, 0.45) 0%,       /* Tara Sthayi: Fiery Coral Orange Core */
    rgba(251, 146, 60, 0.32) 22%,      /* Tara overtone */
    rgba(16, 185, 129, 0.30) 44%,      /* Madhya Sthayi: Luminous Emerald Teal */
    rgba(6, 182, 212, 0.22) 64%,       /* Madhya Cyan overtone */
    rgba(59, 130, 246, 0.26) 80%,      /* Mandra Sthayi: Royal Blue */
    rgba(79, 70, 229, 0.14) 92%,       /* Deep Indigo */
    transparent 100%
  );
  filter: blur(34px);
  pointer-events: none;
  z-index: -1;
  opacity: 0.55;
  animation: celestialFloorAura 6s ease-in-out infinite alternate;
}

@keyframes celestialFloorAura {
  0% {
    transform: translate(-50%, -50%) scale(0.96, 0.92);
    opacity: 0.48;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.04, 1.06);
    opacity: 0.62;
  }
}

.welcome-glass-card {
  font-family: var(--font-display);
  background: rgba(6, 10, 22, 0.64);
  backdrop-filter: blur(34px) saturate(190%);
  -webkit-backdrop-filter: blur(34px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 24px;
  padding: 28px 42px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  max-width: 440px;
  position: relative;
  z-index: 2;
}

.welcome-title {
  font-family: var(--font-display) !important;
  font-size: 32px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  line-height: 1.1;
  margin: 0;
  text-shadow: 0 2px 16px rgba(255, 255, 255, 0.25);
}

.welcome-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 4px;
}

.btn-hero,
#heroStartCameraBtn {
  font-family: var(--font-display) !important;
  background: #ccff00 !important;
  color: #000000 !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  letter-spacing: 0.5px !important;
  padding: 13px 32px !important;
  border-radius: 0px !important;
  border: 2px solid #000000 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  box-shadow: 3px 3px 0px #000000, 0 0 24px rgba(204, 255, 0, 0.45) !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease !important;
}

.btn-hero svg,
#heroStartCameraBtn svg {
  stroke: #000000 !important;
}

.btn-hero:hover,
#heroStartCameraBtn:hover {
  background: #ddff33 !important;
  transform: translate(-1px, -1px) !important;
  box-shadow: 4px 4px 0px #000000, 0 0 32px rgba(204, 255, 0, 0.65) !important;
}

.btn-hero:active,
#heroStartCameraBtn:active {
  transform: translate(2px, 2px) !important;
  box-shadow: 1px 1px 0px #000000 !important;
}

/* Loading spinner for camera init */
.loading-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(0,0,0,0.25);
  border-top-color: #000;
  border-radius: 50%;
  animation: spin-loader 0.65s linear infinite;
  flex-shrink: 0;
}

@keyframes spin-loader {
  to { transform: rotate(360deg); }
}

#heroStartCameraBtn:disabled {
  opacity: 0.75 !important;
  cursor: wait !important;
}

.learn-text-link {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: rgba(226, 232, 240, 0.85);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px 8px;
  margin-top: 2px;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(56, 189, 248, 0.5);
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.learn-text-link:hover {
  color: #38bdf8;
  text-decoration-color: #38bdf8;
}

.btn-learn-pill {
  background: rgba(56, 189, 248, 0.12) !important;
  border-color: rgba(56, 189, 248, 0.35) !important;
  color: #38bdf8 !important;
}

.btn-learn-pill:hover {
  background: rgba(56, 189, 248, 0.24) !important;
  border-color: rgba(56, 189, 248, 0.6) !important;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.4) !important;
}

/* Camera Toolbar Dock (Bottom-Left Floating Glass Pod) */
.camera-toolbar {
  position: absolute;
  bottom: 130px;
  left: 14px;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(10, 14, 26, 0.58);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: var(--glass-border);
  border-radius: 14px;
  padding: 6px 14px;
  box-shadow: var(--glass-shadow);
  pointer-events: auto;
  margin: 0;
  max-width: 540px;
}

.toolbar-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.camera-status {
  display: none !important;
}

/* Calibration Controls Dock (Bottom-Left Floating Glass Pod) */
.calibration-row {
  position: absolute;
  bottom: 12px;
  left: 14px;
  z-index: 25;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  background: rgba(10, 14, 26, 0.58);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: var(--glass-border);
  border-radius: 14px;
  padding: 6px 12px;
  box-shadow: var(--glass-shadow);
  pointer-events: auto;
  margin: 0;
  width: 420px;
  max-width: calc(100vw - 28px);
}

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

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

.calib-item label, .control-group label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-muted);
}

.calib-val {
  color: #38bdf8;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 10px;
}

/* ========================================================================= */
/* 3. ULTRA-GLASS CONTROLS PANEL: FLOATING DIRECTLY ON CAMERA SCREEN         */
/* ========================================================================= */
.controls-panel {
  position: absolute;
  top: 58px;
  right: 14px;
  /* Baseline preserved for test assertion: bottom: clamp(75px, 11vh, 95px); */
  bottom: auto;
  height: fit-content;
  max-height: calc(100vh - 170px);
  width: clamp(320px, 25vw, 380px);
  z-index: 30;
  display: grid;
  grid-template-rows: repeat(4, 1fr);
  grid-template-rows: auto auto auto auto;
  align-content: start;
  gap: 6px;
  overflow: hidden !important;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
  background: rgba(10, 14, 26, 0.42);
  backdrop-filter: blur(28px) saturate(190%);
  -webkit-backdrop-filter: blur(28px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  padding: 6px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.18);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.controls-panel.dock-collapsed {
  transform: translateX(calc(100% + 24px));
  opacity: 0;
  pointer-events: none;
}

.controls-panel::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

/* 4 Equal-Height Glass Cards (Resized to fill height comfortably) */
.controls-panel > .card {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  padding: 5px 8px;
  flex-shrink: 1;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.controls-panel > .card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

/* Dock Toggle Button in Visualizer Header (Neon Collapse / Expand) */
.card-header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.dock-toggle-btn {
  background: #ccff00 !important;
  border: 1.5px solid #000000 !important;
  border-radius: 0px !important;
  color: #000000 !important;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 800;
  padding: 2.5px 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  box-shadow: 2px 2px 0px #000000;
  transition: all 0.12s ease;
}

.dock-toggle-btn:hover {
  background: #ddff33 !important;
  color: #000000 !important;
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0px #000000;
}

/* Floating Studio Dock Expand Button (Visible when dock is collapsed - Neon) */
.floating-dock-open-btn {
  position: absolute;
  top: 58px;
  right: 14px;
  z-index: 35;
  background: #ccff00 !important;
  border: 2px solid #000000 !important;
  border-radius: 0px !important;
  color: #000000 !important;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  padding: 6px 14px;
  cursor: pointer;
  box-shadow: 3px 3px 0px #000000;
  display: none;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.floating-dock-open-btn:hover {
  background: #ddff33 !important;
  color: #000000 !important;
  border-color: #000000 !important;
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0px #000000;
}

.main-content.dock-collapsed .floating-dock-open-btn {
  display: inline-flex;
}

@media (max-width: 1024px) {
  .controls-panel {
    width: clamp(300px, 35vw, 380px);
  }
}

/* Card 1: Audio Visualizer (1.5x bigger) */
.visualizer-card {
  padding: 5px 8px;
  min-height: 115px;
}

.visualizer-card .card-header {
  margin-bottom: 2px;
}

.visualizer-card canvas {
  width: 100%;
  flex: 1;
  min-height: 90px;
  height: 90px;
  background: #06070a;
  border-radius: 0px;
  border: 1.5px solid #202636;
  display: block;
}

/* Card 2: 7 Swaras Recognized Strip (Scaled to 65% size) */
.swaras-section {
  padding: 3px 5px;
  height: auto !important;
  max-height: fit-content;
  justify-content: flex-start !important;
  gap: 2px;
}

.section-subhead {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 2px;
  flex-wrap: nowrap;
  gap: 4px;
}

.section-subhead h3 {
  font-family: var(--font-display) !important;
  font-size: 11.5px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.3px;
  text-transform: none !important;
}

.section-subhead .hint {
  font-size: 7.5px;
  color: var(--accent-muted);
  font-family: var(--font-mono);
  white-space: nowrap;
}

.swaras-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 3.5px;
  width: 100%;
  min-width: 0;
  align-content: flex-start;
}

/* When 8 or more notes are active, arrange into 5 columns wrapping to next line */
.swaras-grid.wrap-2-lines,
.swaras-grid[data-count="8"],
.swaras-grid[data-count="9"],
.swaras-grid[data-count="10"],
.swaras-grid[data-count="11"],
.swaras-grid[data-count="12"],
.swaras-grid[data-count="13"],
.swaras-grid[data-count="14"],
.swaras-grid[data-count="15"],
.swaras-grid[data-count="16"] {
  grid-template-columns: repeat(5, 1fr);
  gap: 3px;
}

.swara-card {
  aspect-ratio: 1 / 1;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  background: #141722;
  border: 1.5px solid #262c3d;
  border-radius: 0px;
  padding: 2px;
  cursor: pointer;
  transition: all 0.1s ease;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1.5px;
  text-align: center;
  box-shadow: 1.5px 1.5px 0px #000000;
  overflow: hidden;
}

/* Dynamic auto-shrink when 8 to 10 notes are active */
.swaras-grid.wrap-2-lines .swara-card,
.swaras-grid[data-count="8"] .swara-card,
.swaras-grid[data-count="9"] .swara-card,
.swaras-grid[data-count="10"] .swara-card,
.swaras-grid.dense-8 .swara-card {
  padding: 1.5px 0.5px;
  gap: 0.5px;
}
.swaras-grid.wrap-2-lines .swara-symbol,
.swaras-grid[data-count="8"] .swara-symbol,
.swaras-grid[data-count="9"] .swara-symbol,
.swaras-grid[data-count="10"] .swara-symbol,
.swaras-grid.dense-8 .swara-symbol {
  font-size: 10px;
}
.swaras-grid.wrap-2-lines .swara-titles h4,
.swaras-grid[data-count="8"] .swara-titles h4,
.swaras-grid[data-count="9"] .swara-titles h4,
.swaras-grid[data-count="10"] .swara-titles h4,
.swaras-grid.dense-8 .swara-titles h4 {
  font-size: 7px;
}
.swaras-grid.wrap-2-lines .western-sub,
.swaras-grid[data-count="8"] .western-sub,
.swaras-grid[data-count="9"] .western-sub,
.swaras-grid[data-count="10"] .western-sub,
.swaras-grid.dense-8 .western-sub {
  font-size: 6px;
}
.swaras-grid.wrap-2-lines .mini-pip,
.swaras-grid[data-count="8"] .mini-pip,
.swaras-grid[data-count="9"] .mini-pip,
.swaras-grid[data-count="10"] .mini-pip,
.swaras-grid.dense-8 .mini-pip {
  width: 2.8px;
  height: 2.8px;
}

/* Dynamic auto-shrink when 11 to 16 notes are active */
.swaras-grid[data-count="11"] .swara-card,
.swaras-grid[data-count="12"] .swara-card,
.swaras-grid[data-count="13"] .swara-card,
.swaras-grid[data-count="14"] .swara-card,
.swaras-grid[data-count="15"] .swara-card,
.swaras-grid[data-count="16"] .swara-card,
.swaras-grid.dense-16 .swara-card {
  padding: 1.5px 0.5px;
  border-width: 1px;
  box-shadow: 1px 1px 0px #000000;
  gap: 0px;
}
.swaras-grid[data-count="11"] .swara-symbol,
.swaras-grid[data-count="12"] .swara-symbol,
.swaras-grid[data-count="13"] .swara-symbol,
.swaras-grid[data-count="14"] .swara-symbol,
.swaras-grid[data-count="15"] .swara-symbol,
.swaras-grid[data-count="16"] .swara-symbol,
.swaras-grid.dense-16 .swara-symbol {
  font-size: 9.5px;
}
.swaras-grid[data-count="11"] .swara-titles h4,
.swaras-grid[data-count="12"] .swara-titles h4,
.swaras-grid[data-count="13"] .swara-titles h4,
.swaras-grid[data-count="14"] .swara-titles h4,
.swaras-grid[data-count="15"] .swara-titles h4,
.swaras-grid[data-count="16"] .swara-titles h4,
.swaras-grid.dense-16 .swara-titles h4 {
  font-size: 6.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.swaras-grid[data-count="11"] .western-sub,
.swaras-grid[data-count="12"] .western-sub,
.swaras-grid[data-count="13"] .western-sub,
.swaras-grid[data-count="14"] .western-sub,
.swaras-grid[data-count="15"] .western-sub,
.swaras-grid[data-count="16"] .western-sub,
.swaras-grid.dense-16 .western-sub {
  font-size: 5.5px;
  white-space: nowrap;
  overflow: hidden;
}
.swaras-grid[data-count="11"] .card-pips-row,
.swaras-grid[data-count="12"] .card-pips-row,
.swaras-grid[data-count="13"] .card-pips-row,
.swaras-grid[data-count="14"] .card-pips-row,
.swaras-grid[data-count="15"] .card-pips-row,
.swaras-grid[data-count="16"] .card-pips-row,
.swaras-grid.dense-16 .card-pips-row {
  gap: 1px;
}
.swaras-grid[data-count="11"] .mini-pip,
.swaras-grid[data-count="12"] .mini-pip,
.swaras-grid[data-count="13"] .mini-pip,
.swaras-grid[data-count="14"] .mini-pip,
.swaras-grid[data-count="15"] .mini-pip,
.swaras-grid[data-count="16"] .mini-pip,
.swaras-grid.dense-16 .mini-pip {
  width: 2.5px;
  height: 2.5px;
}

.swara-card:hover {
  background: #1c2132;
  border-color: #4a5574;
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0px #000000;
}

/* Brutalist Inverted Active Swara State */
.swara-card.active {
  background: var(--accent-acid) !important;
  border: 2px solid #000000 !important;
  box-shadow: 2px 2px 0px #000000 !important;
  transform: translate(1px, 1px) !important;
}

.swara-card.active .swara-symbol {
  color: #000000 !important;
}

.swara-card.active .swara-titles h4 {
  color: #000000 !important;
  font-weight: 800 !important;
}

.swara-card.active .western-sub {
  color: #222222 !important;
  font-weight: 700 !important;
}

.swara-card.janti-flash {
  background: var(--accent-amber) !important;
  border: 2px solid #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  transform: translate(-1px, -1px) scale(1.03) !important;
}

.swara-card.janti-flash .swara-symbol,
.swara-card.janti-flash .swara-titles h4,
.swara-card.janti-flash .western-sub {
  color: #000000 !important;
  font-weight: 800 !important;
}

.swara-card.jaru-glide {
  border-color: var(--accent-blue) !important;
  box-shadow: 3px 3px 0px var(--accent-blue) !important;
}

.swara-card-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5px;
  width: 100%;
}

.swara-symbol {
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
}

.swara-titles {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0px;
  width: 100%;
}

.swara-titles h4 {
  font-family: var(--font-display);
  font-size: 7px;
  font-weight: 700;
  line-height: 1.05;
  color: #cbd5e1;
  text-align: center;
  word-break: break-word;
  white-space: normal;
  max-width: 100%;
}

.western-sub {
  font-family: var(--font-mono);
  font-size: 6px;
  color: var(--accent-dim);
  white-space: nowrap;
  line-height: 1;
}

.card-pips-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.2px;
  margin: 1px 0 0;
}

.mini-pip {
  width: 3px;
  height: 3px;
  border-radius: 0px;
  display: inline-block;
}

.mini-pip.closed {
  background: var(--accent-acid);
  border: 0.5px solid #000000;
}

.mini-pip.half {
  background: linear-gradient(90deg, var(--accent-acid) 50%, #4a5568 50%);
  border: 0.5px solid #000000;
}

.mini-pip.open {
  background: #333a4d;
}

.card-rule,
.card-play-btn {
  display: none;
}

/* Card 3: Studio Tuning & Octaves Rack */
.studio-rack-card {
  padding: 4px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.rack-controls-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 4px;
}

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

.form-select {
  width: 100%;
  background: #0d0f17;
  border: 1.5px solid #2d3448;
  border-radius: 0px;
  color: #ffffff;
  padding: 4px 6px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  outline: none;
  cursor: pointer;
  box-shadow: 1px 1px 0px #000000;
  transition: border-color 0.15s;
}

.form-select:focus {
  border-color: var(--accent-acid);
}

.octave-control-row {
  display: flex;
  align-items: center;
  gap: 4px;
}

.octave-selector {
  display: flex;
  align-items: center;
  gap: 3px;
}

.octave-num {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 800;
  color: #ffffff;
  min-width: 20px;
  text-align: center;
}

.btn-overblow {
  background: #151824;
  border: 1.5px solid #2d3448;
  border-radius: 0px;
  color: var(--accent-muted);
  padding: 3px 6px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 1px 1px 0px #000000;
  transition: all 0.12s ease;
  white-space: nowrap;
}

.btn-overblow.active {
  background: #1f2536;
  border-color: var(--accent-acid);
  color: var(--accent-acid);
  box-shadow: 2px 2px 0px #000000;
}

/* Mouth Octave Badges */
.octave-legend-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 4px;
}

.legend-item {
  background: #0f121a;
  border: 1.5px solid #232838;
  border-radius: 0px;
  padding: 2px 3px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  box-shadow: 1px 1px 0px #000000;
  transition: all 0.12s ease;
}

.legend-item.active {
  border-color: var(--accent-acid);
  background: #171c26;
  box-shadow: 2px 2px 0px #000000;
}

.legend-arrow {
  font-size: 10px;
  color: var(--accent-dim);
  margin-bottom: 1px;
}

.legend-item.active .legend-arrow {
  color: var(--accent-acid);
}

.legend-title {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #ffffff;
}

.legend-desc {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--accent-muted);
}

.legend-item.active .legend-desc {
  color: var(--accent-acid);
}

.levels-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

/* Range Inputs with Brutalist Square Thumbs */
.form-range {
  -webkit-appearance: none;
  width: 100%;
  height: 4px;
  background: #232838;
  border-radius: 0px;
  outline: none;
  margin-top: 4px;
}

.form-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 0px;
  background: var(--accent-acid);
  border: 2px solid #000000;
  cursor: pointer;
  box-shadow: 1px 1px 0px #000000;
  transition: transform 0.1s ease;
}

.form-range::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

/* Card 4: Carnatic Raga & 16 Swarasthanas Builder (Compact Section & Full-Width Dropdown) */
.raga-builder-card {
  height: auto !important;
  min-height: 0;
  justify-content: flex-start !important;
  padding: 3px 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 6px;
}

.raga-builder-header {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 1px;
  margin-bottom: 2px;
}

.raga-builder-header h3 {
  font-family: var(--font-display) !important;
  font-size: 11.5px !important;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.3px;
  text-transform: none !important;
}

.raga-scale-summary {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 1px;
}

.raga-name-badge {
  background: #0c1624;
  border: 1px solid var(--accent-blue);
  border-radius: 0px;
  color: var(--accent-blue);
  padding: 0.5px 4px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  box-shadow: 1px 1px 0px #000000;
}

.raga-notes-list {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: #cbd5e1;
  letter-spacing: 0.2px;
}

.raga-preset-dropdown-wrap {
  width: 100%;
}

.raga-preset-dropdown-wrap .raga-select {
  width: 100%;
  min-width: 0;
  max-width: none;
  font-size: 8.5px;
  padding: 2px 6px;
  height: 22px;
}

.swarasthanas-matrix {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 0;
  gap: 1.5px;
  background: #0a0c13;
  border: 1.5px solid #202636;
  border-radius: 0px;
  padding: 2px 3px;
}

.swara-matrix-row {
  display: grid;
  grid-template-columns: 15px 1fr;
  align-items: center;
  gap: 2.5px;
  height: 13.5px;
}

.matrix-type-label {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 800;
  color: #a0aec0;
  text-align: center;
  letter-spacing: 0.3px;
}

.matrix-cells-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  height: 100%;
}

.matrix-cell-empty {
  background: rgba(255, 255, 255, 0.015);
  border: 1px dashed #202636;
  border-radius: 0px;
  height: 100%;
}

.swara-chip {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 3px;
  padding: 0 4px;
  height: 100%;
  border-radius: 0px;
  background: #141724;
  border: 1px solid #272e42;
  color: #cbd5e1;
  cursor: pointer;
  user-select: none;
  transition: all 0.1s ease;
  white-space: nowrap;
  overflow: hidden;
  font-size: 8.5px;
  box-shadow: 1px 1px 0px #000000;
}

.swara-chip:hover {
  background: #1e2436;
  border-color: #404b68;
  color: #ffffff;
}

.swara-chip.active {
  background: var(--accent-blue) !important;
  border: 1.5px solid #000000 !important;
  color: #000000 !important;
  font-weight: 800 !important;
  box-shadow: 2px 2px 0px #000000 !important;
}

.swara-chip.active .chip-short,
.swara-chip.active .chip-name,
.swara-chip.active .chip-cents {
  color: #000000 !important;
  font-weight: 800 !important;
}

.chip-short {
  font-weight: 800;
  font-size: 10px;
  line-height: 1;
  color: #ffffff;
}

.chip-name {
  font-size: 7.5px;
  font-weight: 600;
  color: #a0aec0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chip-cents {
  font-family: var(--font-mono);
  font-size: 7px;
  color: var(--accent-blue);
}

/* Card 5: Carnatic Tala & Metronome (Crucial: retains flex: 1 for test) */
.tala-card {
  flex: 1;
  padding: 4px 8px;
  height: auto !important;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3px;
}

.tala-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0px;
}

.tala-card-header h3 {
  font-family: var(--font-display) !important;
  font-size: 11.5px !important;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.3px;
  text-transform: none !important;
}

.btn-tala-play {
  background: #ccff00 !important;
  border: 1.5px solid #000000 !important;
  border-radius: 0px !important;
  color: #000000 !important;
  padding: 1px 5px;
  font-family: var(--font-display) !important;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  box-shadow: 1.5px 1.5px 0px #000000;
  transition: transform 0.08s ease, box-shadow 0.08s ease;
  line-height: 1.2;
}

.btn-tala-play .tala-icon {
  font-size: 6.5px;
}

.btn-tala-play:hover {
  background: #ddff33 !important;
  transform: translate(-1px, -1px);
  box-shadow: 2px 2px 0px #000000;
}

.btn-tala-play:active {
  transform: translate(1px, 1px);
  box-shadow: 1px 1px 0px #000000;
}

.btn-tala-play.active {
  background: #ff5500 !important;
  color: #ffffff !important;
}

.tala-controls-row {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  flex-wrap: nowrap;
}

.tala-select-wrap {
  flex: 1;
  min-width: 0;
}

.tala-select {
  width: 100%;
  padding: 3px 5px;
  font-size: 9.5px;
  font-weight: 600;
  background: #10141f;
  border: 1.5px solid #2a334a;
  color: #f1f5f9;
}

.tala-speed-group {
  display: flex;
  background: #141824;
  border: 1.5px solid #000000;
  border-radius: 0px;
  overflow: hidden;
  box-shadow: 1.5px 1.5px 0px #000000;
  flex-shrink: 0;
}

.tala-speed-btn {
  background: #141824;
  border: none;
  border-right: 1px solid #2a3144;
  color: #e2e8f0 !important;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  padding: 2px 5px;
  cursor: pointer;
  transition: background 0.1s ease, color 0.1s ease;
}

.tala-speed-btn:last-child {
  border-right: none;
}

.tala-speed-btn:hover {
  background: #222b3e;
  color: #ffffff !important;
}

.tala-speed-btn.active {
  background: #ccff00 !important;
  color: #000000 !important;
  font-weight: 800;
}

.tala-bpm-group {
  display: flex;
  align-items: center;
  gap: 2px;
  background: #0e111a;
  border: 1.5px solid #2a3144;
  border-radius: 0px;
  padding: 1px 3px;
  box-shadow: 1px 1px 0px #000000;
  flex-shrink: 0;
}

.btn-tiny {
  background: #1e2434;
  border: 1px solid #363e54;
  color: #ffffff;
  width: 17px;
  height: 17px;
  border-radius: 0px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 800;
}

.btn-tiny:hover {
  background: #2b334a;
  border-color: #556284;
}

.tala-bpm-num {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  color: #ffffff;
  min-width: 40px;
  text-align: center;
}

.tala-visual-strip {
  background: #080a10;
  border: 1.5px solid #202636;
  border-radius: 0px;
  padding: 3px 5px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tala-kriya-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.kriya-tag {
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  color: var(--accent-acid);
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.akshara-counter {
  font-family: var(--font-mono);
  font-size: 8px;
  color: var(--accent-muted);
}

.tala-pips-row {
  display: flex;
  gap: 3px;
  align-items: center;
}

.tala-pip {
  flex: 1;
  height: 9px;
  border-radius: 0px;
  background: #111420;
  border: 1px solid #252b3d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: #64748b;
  transition: all 0.06s ease-out;
}

.tala-pip.samam-marker {
  border-color: #78350f;
}

.tala-pip.active {
  background: var(--accent-acid);
  border-color: #000000;
  color: #000000;
  font-weight: 900;
  box-shadow: 2px 2px 0px #000000;
  transform: scaleY(1.2);
}

.tala-pip.active.samam-marker {
  background: var(--accent-amber);
  border-color: #000000;
  color: #000000;
}

.tala-phrases-row {
  display: flex;
  align-items: center;
  gap: 5px;
  overflow: hidden;
}

.phrases-label {
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  color: var(--accent-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  white-space: nowrap;
}

.phrases-chips {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  flex: 1;
}

.phrases-chips::-webkit-scrollbar {
  display: none;
}

.phrase-chip {
  background: #0f121a;
  border: 1px solid #232838;
  border-radius: 0px;
  padding: 1px 5px;
  font-size: 8px;
  color: #cbd5e1;
  white-space: nowrap;
  cursor: pointer;
  font-family: var(--font-mono);
  box-shadow: 1px 1px 0px #000000;
  transition: all 0.1s ease;
}

.phrase-chip:hover {
  background: #1c2132;
  border-color: #434e6e;
  color: #ffffff;
}

/* ========================================================================= */
/* 5. TACTILE BRUTALIST BUTTONS & CONTROLS                                  */
/* ========================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 0px;
  border: 2px solid #2d3345;
  padding: 6px 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  box-shadow: var(--shadow-hard);
  transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.15s ease;
}

.btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: var(--shadow-hard-lg);
}

.btn:active {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0px #000000;
}

.btn-primary {
  background: var(--accent-acid);
  color: #000000;
  border: 2px solid #000000;
  font-weight: 800;
}

.btn-primary:hover {
  background: #ddff33;
}

.btn-secondary {
  background: #151822;
  border: 2px solid #333b4e;
  color: #ffffff;
}

.btn-secondary:hover {
  background: #1e2332;
  border-color: #505c7a;
}

.btn-ghost {
  background: transparent;
  border: 2px solid #2d3345;
  color: var(--accent-muted);
}

.btn-ghost:hover {
  background: #12151e;
  color: #ffffff;
  border-color: #47526e;
}

.btn-ghost.active {
  border-color: var(--accent-acid);
  color: #000000;
  background: var(--accent-acid);
}

.btn-pill {
  border-radius: 0px;
  padding: 5px 11px;
}

.btn-sm {
  padding: 3px 8px;
  font-size: 10.5px;
  background: #151824;
  border: 1.5px solid #2d3448;
  color: #ffffff;
  box-shadow: 1px 1px 0px #000000;
}

.btn-sm:hover {
  border-color: #4a5574;
}

/* Animations */
@keyframes jaruPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

/* ============================================================== */
/* LEARN TO PLAY INTERACTIVE VISUAL GUIDE MODAL                   */
/* ============================================================== */
.learn-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(3, 6, 14, 0.85);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  padding: 20px;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.3s ease;
}

.learn-modal-backdrop.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.learn-modal-card {
  position: relative;
  background: rgba(10, 15, 28, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.85), 0 0 50px rgba(56, 189, 248, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  border-radius: 28px;
  max-width: 960px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 34px 38px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.learn-modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.learn-modal-close:hover {
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  transform: scale(1.08);
}

.learn-modal-header {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.learn-modal-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  padding: 3px 12px;
  border-radius: 999px;
  margin-bottom: 2px;
}

.learn-modal-title {
  font-family: var(--font-display) !important;
  font-size: 32px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin: 0;
  text-shadow: 0 2px 20px rgba(255, 255, 255, 0.2);
}

.learn-modal-subtitle {
  font-family: var(--font-body) !important;
  font-size: 14.5px;
  color: #94a3b8;
  margin: 0;
}

.learn-sections-container {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.learn-focus-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

@media (max-width: 820px) {
  .learn-focus-grid {
    grid-template-columns: 1fr;
  }
}

.learn-focus-card {
  background: rgba(15, 22, 38, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.focus-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #38bdf8;
}

.focus-badge.highlight {
  color: #10b981;
}

.focus-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
}

.focus-note {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.45;
  margin: 0;
}

.focus-note strong {
  color: #f1f5f9;
}

.hand-visual-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(2, 6, 17, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 12px 14px;
  gap: 10px;
}

.hand-side {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.hand-tag {
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 800;
  color: #38bdf8;
  letter-spacing: 0.5px;
}

.right-side .hand-tag {
  color: #c084fc;
}

.hand-desc {
  font-size: 11px;
  color: #94a3b8;
}

.finger-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.finger-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  padding: 2px 6px;
  border-radius: 6px;
}

.hand-divider {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.25);
}

.sa-hero-illustration {
  width: 100%;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(2, 6, 17, 0.5);
  border-radius: 12px;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.sa-hero-svg {
  width: 100%;
  height: 100%;
  max-width: 240px;
}

.learn-notes-chart-section,
.learn-animated-scale-section {
  background: rgba(15, 22, 38, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.chart-header-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.chart-legend {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  color: #94a3b8;
}

.dot-legend {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  vertical-align: middle;
  margin-right: 4px;
}

.dot-legend.closed {
  background: #10b981;
  box-shadow: 0 0 6px #10b981;
}

.dot-legend.open {
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  background: transparent;
}

.swaras-table-wrapper {
  overflow-x: auto;
}

.swaras-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: center;
}

.swaras-table th,
.swaras-table td {
  padding: 7px 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.swaras-table thead th {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  color: #94a3b8;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.col-left-hand {
  background: rgba(56, 189, 248, 0.08);
  color: #38bdf8 !important;
  border-top-left-radius: 6px;
}

.col-right-hand {
  background: rgba(168, 85, 247, 0.08);
  color: #c084fc !important;
  border-top-right-radius: 6px;
}

.sub-hole-row th.hole-num {
  font-family: var(--font-mono);
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  padding: 3px 6px;
}

.swara-badge {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13.5px;
  padding: 2px 9px;
  border-radius: 5px;
}

.sa-badge { background: rgba(56, 189, 248, 0.2); color: #38bdf8; border: 1px solid rgba(56, 189, 248, 0.4); }
.ri-badge { background: rgba(20, 184, 166, 0.2); color: #2dd4bf; border: 1px solid rgba(20, 184, 166, 0.4); }
.ga-badge { background: rgba(34, 197, 94, 0.2); color: #4ade80; border: 1px solid rgba(34, 197, 94, 0.4); }
.ma-badge { background: rgba(250, 204, 21, 0.2); color: #facc15; border: 1px solid rgba(250, 204, 21, 0.4); }
.pa-badge { background: rgba(251, 146, 60, 0.2); color: #fb923c; border: 1px solid rgba(251, 146, 60, 0.4); }
.dha-badge { background: rgba(244, 63, 94, 0.2); color: #f43f5e; border: 1px solid rgba(244, 63, 94, 0.4); }
.ni-badge { background: rgba(168, 85, 247, 0.2); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.4); }

.note-key {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: #cbd5e1;
}

.hole-dot {
  font-size: 15px;
  line-height: 1;
  display: inline-block;
}

.hole-dot.closed {
  color: #10b981;
  text-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
}

.hole-dot.open {
  color: rgba(255, 255, 255, 0.25);
}

.row-highlight-sa {
  background: rgba(56, 189, 248, 0.08);
}

.note-instruction {
  text-align: left;
  font-size: 12.5px;
  color: #cbd5e1;
}

.octave-tip-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 12.5px;
  color: #94a3b8;
}

.octave-tip-bar strong {
  color: #e2e8f0;
}

.learn-modal-actions {
  display: flex;
  justify-content: center;
  padding-top: 6px;
}

.btn-learn-cta,
#learnModalStartBtn {
  font-family: var(--font-display) !important;
  font-size: 16px !important;
  font-weight: 800 !important;
  letter-spacing: 0.5px !important;
  padding: 13px 36px !important;
  border-radius: 0px !important;
  border: 2px solid #000000 !important;
  background: #ccff00 !important;
  color: #000000 !important;
  box-shadow: 3px 3px 0px #000000, 0 0 26px rgba(204, 255, 0, 0.45) !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease !important;
}

.btn-learn-cta:hover,
#learnModalStartBtn:hover {
  background: #ddff33 !important;
  transform: translate(-1px, -1px) !important;
  box-shadow: 4px 4px 0px #000000, 0 0 34px rgba(204, 255, 0, 0.65) !important;
}

.btn-learn-cta:active,
#learnModalStartBtn:active {
  transform: translate(2px, 2px) !important;
  box-shadow: 1px 1px 0px #000000 !important;
}

/* ========================================================================= */
/* INTERACTIVE ANIMATED SCALE WALKTHROUGH                                    */
/* ========================================================================= */
.learn-animated-scale-section {
  background: rgba(15, 22, 38, 0.85);
  border: 1px solid rgba(56, 189, 248, 0.28);
  border-radius: 18px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.anim-scale-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.anim-header-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.anim-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
}

.btn-anim-toggle {
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #38bdf8;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-anim-toggle:hover {
  background: rgba(56, 189, 248, 0.22);
  border-color: #38bdf8;
}

.btn-anim-toggle.active {
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.5);
  color: #34d399;
}

/* 7 Swara Selector Tabs */
.scale-swara-tabs {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

@media (max-width: 650px) {
  .scale-swara-tabs {
    grid-template-columns: repeat(4, 1fr);
  }
}

.swara-tab {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 8px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.swara-tab:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.swara-tab.active {
  background: rgba(56, 189, 248, 0.16);
  border-color: #38bdf8;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transform: translateY(-2px) scale(1.02);
}

.swara-tab .tab-swara {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
}

.swara-tab .tab-note {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #94a3b8;
}

.swara-tab .tab-fingers {
  font-size: 9px;
  color: #38bdf8;
  font-weight: 600;
}

/* Animated Stage Banner */
.scale-flute-stage {
  background: rgba(2, 6, 17, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 14px 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.scale-action-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 8px 12px;
}

.anim-swara-pill {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  background: #10b981;
  color: #052e16;
  padding: 3px 10px;
  border-radius: 6px;
  letter-spacing: 0.5px;
  flex-shrink: 0;
  transition: background 0.2s ease, color 0.2s ease;
}

.anim-swara-desc {
  font-size: 13px;
  font-weight: 500;
  color: #e2e8f0;
  line-height: 1.35;
}

.flute-diagram-container {
  width: 100%;
  overflow-x: auto;
  display: flex;
  justify-content: center;
}

.scale-interactive-flute-svg {
  width: 100%;
  max-width: 740px;
  height: auto;
  display: block;
}

/* Animated Pressing Finger Transition */
.anim-pressing-finger {
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
  transform: translateY(-24px);
  opacity: 0.35;
}

.anim-pressing-finger.finger-down {
  transform: translateY(0px);
  opacity: 1;
}

/* Right-hand fingers entering from the other side (bottom wrap) */
.anim-pressing-finger.finger-other-side {
  transform: translateY(22px);
  opacity: 0.35;
}

.anim-pressing-finger.finger-other-side.finger-down {
  transform: translateY(0px);
  opacity: 1;
}

.anim-hole-node.active-closed .hole-disc-fill {
  opacity: 1 !important;
  filter: drop-shadow(0 0 8px rgba(16, 185, 129, 0.7));
}

.anim-hole-node .hole-disc-fill {
  transition: opacity 0.2s ease;
}

/* ============================================================== */
/* 4-STEP WIZARD: DIGITAL BRUTALISM HOW TO LEARN AER BENDER      */
/* ============================================================== */
.learn-modal-card {
  position: relative;
  background: #070b16 !important;
  border: 2.5px solid #000000 !important;
  box-shadow: 8px 8px 0px #000000, 0 0 50px rgba(0, 240, 255, 0.15) !important;
  border-radius: 16px !important;
  max-width: 960px;
  width: 96%;
  max-height: 92vh;
  overflow: hidden !important;
  padding: 18px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.learn-sections-container {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.learn-modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 6px !important;
  background: #1e293b !important;
  border: 2px solid #000000 !important;
  box-shadow: 2px 2px 0px #000000 !important;
  color: #ffffff !important;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.learn-modal-close:hover {
  background: #ff0055 !important;
  color: #ffffff !important;
  transform: translate(-1px, -1px) !important;
  box-shadow: 3px 3px 0px #000000 !important;
}

.learn-modal-header {
  margin-bottom: 0px;
}

.learn-modal-badge {
  font-family: var(--font-mono) !important;
  font-size: 10px !important;
  font-weight: 800 !important;
  letter-spacing: 1.5px;
  color: #000000 !important;
  background: #ccff00 !important;
  border: 1.5px solid #000000 !important;
  box-shadow: 2px 2px 0px #000000 !important;
  padding: 3px 10px !important;
  border-radius: 4px !important;
  margin-bottom: 2px;
  display: inline-block;
}

.learn-modal-title {
  font-family: var(--font-display) !important;
  font-size: 24px !important;
  font-weight: 800 !important;
  color: #ffffff !important;
  letter-spacing: -0.5px;
  text-transform: uppercase;
  margin: 0;
}

.learn-modal-subtitle {
  font-family: var(--font-body) !important;
  font-size: 13px;
  color: #94a3b8;
  margin: 0;
}

/* Digital Brutalist Step Tabs */
.learn-step-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.step-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #0d1527 !important;
  border: 2px solid #000000 !important;
  box-shadow: 2px 2px 0px #000000 !important;
  border-radius: 6px !important;
  padding: 5px 14px;
  color: #94a3b8;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.step-tab-btn:hover {
  background: #17233f !important;
  color: #ffffff;
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0px #000000 !important;
}

.step-tab-btn.active {
  background: #ccff00 !important;
  border-color: #000000 !important;
  color: #000000 !important;
  box-shadow: 3px 3px 0px #000000, 0 0 16px rgba(204, 255, 0, 0.4) !important;
  transform: translate(-1px, -1px);
}

.step-tab-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 4px !important;
  background: #1e293b;
  border: 1.5px solid #000000;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  color: #e2e8f0;
}

.step-tab-btn.active .step-tab-num {
  background: #000000;
  color: #ccff00;
}

.learn-step-pane {
  animation: fadeInStep 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInStep {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.step-pane-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}

.step-intro-text {
  font-size: 13.5px;
  color: #94a3b8;
  line-height: 1.5;
  margin: 0;
}

/* STEP 1: HAND ORIENTATION ASYMMETRY */
.hand-orientation-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 12px;
}

@media (max-width: 720px) {
  .hand-orientation-grid {
    grid-template-columns: 1fr;
  }
}

.hand-orient-card {
  background: #0c1324;
  border: 2px solid #000000;
  box-shadow: 4px 4px 0px #000000;
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.orient-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.hand-badge {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 800;
  padding: 3px 8px;
  border: 1.5px solid #000000;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.left-badge {
  background: #0284c7;
  color: #ffffff;
}

.right-badge {
  background: #7c3aed;
  color: #ffffff;
}

.orient-key-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  background: #000000;
  color: #ccff00;
  border: 1px solid #ccff00;
  padding: 2px 8px;
  border-radius: 4px;
}

.orient-action-text {
  font-size: 13px;
  color: #cbd5e1;
  line-height: 1.45;
  margin: 0;
}

.orient-action-text strong {
  color: #ffffff;
}

.orient-pinky-tag {
  font-size: 11px;
  color: #fde68a;
  font-weight: 700;
}

.step-illustration-container {
  background: #070c18 !important;
  border: 2px solid #000000 !important;
  box-shadow: 4px 4px 0px #000000 !important;
  border-radius: 10px !important;
  padding: 8px 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.step1-visual-canvas {
  position: relative;
  width: 100%;
  max-width: 860px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 8px;
  overflow: hidden;
  border: 1.5px solid #182238;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.7);
}

.step1-base-img {
  width: 100%;
  height: auto;
  max-height: 440px;
  object-fit: contain;
  display: block;
}

.step-flute-posture-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: 860px;
  pointer-events: none;
}

/* Embouchure breath wave animations */
.pulse-blow-core {
  animation: blowPulse 1.8s ease-in-out infinite alternate;
}

@keyframes blowPulse {
  0% { transform: scale(0.85); opacity: 0.6; }
  100% { transform: scale(1.15); opacity: 1; }
}

.breath-wave {
  animation: breathStream 1.5s ease-in-out infinite;
}
.anim-b1 { animation-delay: 0s; }
.anim-b2 { animation-delay: 0.25s; }
.anim-b3 { animation-delay: 0.5s; }

@keyframes breathStream {
  0% { stroke-dashoffset: 20; opacity: 0.2; }
  50% { opacity: 0.9; }
  100% { stroke-dashoffset: -20; opacity: 0.2; }
}



/* Floating finger gentle hover */
.anim-floating-finger {
  animation: fingerHover 2.4s ease-in-out infinite alternate;
}
.f-anim-1 { animation-delay: 0s; }
.f-anim-2 { animation-delay: 0.2s; }
.f-anim-3 { animation-delay: 0.4s; }
.f-anim-4 { animation-delay: 0.6s; }
.f-anim-5 { animation-delay: 0.8s; }
.f-anim-6 { animation-delay: 1.0s; }
.f-anim-7 { animation-delay: 1.2s; }

@keyframes fingerHover {
  0% { transform: translateY(-2px); }
  100% { transform: translateY(4px); }
}

/* STEP 2: FRIENDLY MAGIC STARTER KEY STYLES */
.magic-starter-box {
  background: #0c1324;
  border: 2px solid #000000;
  box-shadow: 3px 3px 0px #000000;
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.starter-icon-badge {
  width: 34px;
  height: 34px;
  background: #ccff00;
  color: #000000;
  border: 2px solid #000000;
  box-shadow: 2px 2px 0px #000000;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  flex-shrink: 0;
}

.starter-title {
  display: block;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 800;
  color: #ccff00;
  letter-spacing: 0.5px;
}

.starter-desc {
  font-size: 12px;
  color: #e2e8f0;
  line-height: 1.35;
  margin-top: 2px;
}

.starter-desc strong {
  color: #ffffff;
}

.sa-stage-anim {
  padding: 28px 20px !important;
  min-height: 200px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.sa-stage-anim .sa-hero-svg {
  max-width: 740px;
  width: 100%;
  height: auto;
  max-height: 180px;
}

.anim-sa-pressing-finger {
  animation: saFingerPress 1.6s cubic-bezier(0.16, 1, 0.3, 1) infinite alternate;
}
.f2-press {
  animation-delay: 0.15s;
}

@keyframes saFingerPress {
  0% { transform: translateY(-8px); opacity: 0.8; }
  100% { transform: translateY(0px); opacity: 1; }
}

.sa-shockwave {
  animation: saShockwaveExpand 1.6s ease-out infinite;
  transform-origin: center;
}
.sa-shockwave.delay-1 {
  animation-delay: 0.4s;
}

@keyframes saShockwaveExpand {
  0% { r: 10; opacity: 0.8; stroke-width: 2.5px; }
  100% { r: 24; opacity: 0; stroke-width: 0.5px; }
}

.sa-glow-bore {
  animation: boreGlow 2s ease-in-out infinite alternate;
}

@keyframes boreGlow {
  0% { opacity: 0.2; }
  100% { opacity: 0.5; }
}

.anim-float-note {
  animation: floatMusicNotes 2s ease-in-out infinite alternate;
  font-weight: 800;
  text-shadow: 1px 1px 0 #000000;
}
.anim-float-note.n2 { animation-delay: 0.7s; }

@keyframes floatMusicNotes {
  0% { transform: translateY(0px) rotate(-5deg); opacity: 0.4; }
  100% { transform: translateY(-8px) rotate(15deg); opacity: 1; }
}

/* STEP 3: DIGITAL BRUTALIST SCALE & ZERO-SCROLL LAYOUT */
.learn-animated-scale-section {
  display: flex;
  flex-direction: column;
  height: 100%;
  justify-content: flex-start;
  gap: 10px;
  overflow: hidden;
}

.anim-scale-header {
  margin-bottom: 2px;
}

.scale-swara-tabs {
  margin-bottom: 6px;
}

.scale-swara-tabs .swara-tab {
  background: #0d1527 !important;
  border: 1.5px solid #000000 !important;
  box-shadow: 2px 2px 0px #000000 !important;
  border-radius: 6px !important;
  padding: 6px 8px !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.scale-swara-tabs .swara-tab:hover {
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0px #000000 !important;
  background: #162238 !important;
}

.scale-swara-tabs .swara-tab.active {
  background: #00f0ff !important;
  color: #000000 !important;
  border: 1.5px solid #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  transform: translate(-1px, -1px);
}

.scale-swara-tabs .swara-tab.active .tab-swara {
  color: #000000 !important;
}

.scale-swara-tabs .swara-tab.active .tab-note {
  color: #042f2e !important;
  font-weight: 800 !important;
}

.scale-swara-tabs .swara-tab.active .tab-fingers {
  color: #021a36 !important;
  font-weight: 800 !important;
}

.scale-flute-stage {
  padding: 16px 20px !important;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.scale-action-banner {
  margin-bottom: 6px !important;
}

.scale-interactive-flute-svg {
  max-height: 180px;
  width: 100%;
}

.swaras-table-wrapper {
  display: none !important;
}

#learnStepPane3,
#learnStepPane4 {
  overflow: hidden !important;
  max-height: 100%;
}

/* STEP 4: ANIMATED HEAD TILT PROFILE CHARACTER - ZERO SCROLL */
.head-tilt-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  overflow: hidden !important;
  gap: 10px;
}

.head-tilt-anim-container {
  overflow: hidden;
  position: relative;
  max-height: 180px;
  padding: 10px 14px !important;
}

.head-tilt-profile-svg {
  width: 100%;
  max-width: 680px;
  height: auto;
  max-height: 160px;
  display: block;
}

.head-rotator {
  transform-origin: 160px 140px;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 9-Second Continuous Auto-Demo Cycle: 3 Seconds Per Octave */
.head-tilt-profile-svg.auto-demo .head-rotator {
  animation: headTiltCycle 9s ease-in-out infinite;
}

@keyframes headTiltCycle {
  0%, 30% { transform: rotate(-14deg); } /* Tara Chin Up: 3s */
  33%, 63% { transform: rotate(0deg); }   /* Madhya Level: 3s */
  66%, 96% { transform: rotate(14deg); }  /* Mandra Chin Down: 3s */
  100% { transform: rotate(-14deg); }
}

/* Specific interactive tilt states */
.tilt-up .head-rotator { transform: rotate(-14deg) !important; }
.tilt-level .head-rotator { transform: rotate(0deg) !important; }
.tilt-down .head-rotator { transform: rotate(14deg) !important; }

/* Sound beam transitions */
.beam-group {
  transition: opacity 0.3s ease;
  opacity: 0.15;
}

.tilt-up #beamTaraG { opacity: 1 !important; }
.tilt-level #beamMadhyaG { opacity: 1 !important; }
.tilt-down #beamMandraG { opacity: 1 !important; }

.head-tilt-profile-svg.auto-demo #beamTaraG {
  animation: beamTaraSync 9s ease-in-out infinite;
}
.head-tilt-profile-svg.auto-demo #beamMadhyaG {
  animation: beamMadhyaSync 9s ease-in-out infinite;
}
.head-tilt-profile-svg.auto-demo #beamMandraG {
  animation: beamMandraSync 9s ease-in-out infinite;
}

@keyframes beamTaraSync {
  0%, 30% { opacity: 1; }
  33%, 100% { opacity: 0.15; }
}
@keyframes beamMadhyaSync {
  0%, 30% { opacity: 0.15; }
  33%, 63% { opacity: 1; }
  66%, 100% { opacity: 0.15; }
}
@keyframes beamMandraSync {
  0%, 63% { opacity: 0.15; }
  66%, 96% { opacity: 1; }
  100% { opacity: 0.15; }
}

.anim-wave-beam {
  stroke-dasharray: 8, 4;
  animation: waveBeamPulse 1.2s linear infinite;
}

@keyframes waveBeamPulse {
  0% { stroke-dashoffset: 40; opacity: 0.6; }
  100% { stroke-dashoffset: 0; opacity: 1; }
}

/* Step 4 Octave Cards - Zero Scroll Compact Layout */
.octave-zones-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 4px;
}

.octave-zone-card {
  background: #0d1527 !important;
  border: 1.5px solid #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  border-radius: 8px !important;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  width: 100%;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.octave-zone-card:hover {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0px #000000 !important;
  background: #141f36 !important;
}

/* Authentic Sthayi Octave Colors in Step 4 */
.zone-tara.active {
  border-color: #000000 !important;
  background: #1c0e08 !important;
  box-shadow: 4px 4px 0px #ff5500 !important;
  transform: translate(-1px, -1px);
}

.zone-madhya.active {
  border-color: #000000 !important;
  background: #081810 !important;
  box-shadow: 4px 4px 0px #10b981 !important;
  transform: translate(-1px, -1px);
}

.zone-mandra.active {
  border-color: #000000 !important;
  background: #081224 !important;
  box-shadow: 4px 4px 0px #3b82f6 !important;
  transform: translate(-1px, -1px);
}

.zone-badge {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.8px;
}
.zone-tara .zone-badge { color: #ff5500; }
.zone-madhya .zone-badge { color: #10b981; }
.zone-mandra .zone-badge { color: #3b82f6; }

.zone-angle-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 800;
  color: #ffffff;
}

.zone-name {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  color: #ffffff;
  margin: 0;
}

.zone-anim-circle {
  width: 36px;
  height: 36px;
  border-radius: 4px;
  margin: 2px auto;
  background: #040813;
  border: 1px solid #000000;
  box-shadow: 1.5px 1.5px 0px #000000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.head-icon {
  font-size: 15px;
  transition: transform 0.25s ease;
}

.head-icon.chin-up { color: #ff5500; transform: translateY(-2px) rotate(-15deg); }
.head-icon.chin-level { color: #10b981; transform: translateY(0); }
.head-icon.chin-down { color: #3b82f6; transform: translateY(2px) rotate(15deg); }

.zone-desc {
  font-size: 11px;
  color: #94a3b8;
  line-height: 1.35;
  margin: 0;
  flex: 1;
}

.zone-color-pill {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 3px;
  text-align: center;
  border: 1px solid #000000;
}

.pill-tara { background: rgba(255, 85, 0, 0.2); color: #ff5500; }
.pill-madhya { background: rgba(16, 185, 129, 0.2); color: #10b981; }
.pill-mandra { background: rgba(59, 130, 246, 0.2); color: #3b82f6; }

/* Tilt Simulation Stage */
.tilt-interactive-stage {
  background: #070c18 !important;
  border: 1.5px solid #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  border-radius: 8px !important;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tilt-stage-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
}

.tilt-stage-title {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 800;
  color: #ffffff;
}

.tilt-stage-hint {
  font-size: 11px;
  color: #94a3b8;
}

.tilt-controls-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-tilt-sim {
  flex: 1;
  min-width: 140px;
  background: #0d1527 !important;
  border: 1.5px solid #000000 !important;
  box-shadow: 2px 2px 0px #000000 !important;
  border-radius: 5px !important;
  padding: 6px 10px;
  color: #cbd5e1;
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-tilt-sim:hover {
  background: #17233f !important;
  color: #ffffff;
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0px #000000 !important;
}

.btn-tilt-sim#btnSimTara.active {
  background: #ff5500 !important;
  color: #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  transform: translate(-1px, -1px);
}

.btn-tilt-sim#btnSimMadhya.active {
  background: #10b981 !important;
  color: #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  transform: translate(-1px, -1px);
}

.btn-tilt-sim#btnSimMandra.active {
  background: #3b82f6 !important;
  color: #ffffff !important;
  box-shadow: 3px 3px 0px #000000 !important;
  transform: translate(-1px, -1px);
}

.tilt-live-feedback {
  font-family: var(--font-mono);
  font-size: 11px;
  color: #cbd5e1;
  background: #040813;
  border: 1px solid #000000;
  border-radius: 4px;
  padding: 4px 10px;
}

.feedback-highlight {
  font-weight: 800;
}

.text-orange { color: #ff5500; }
.text-emerald { color: #10b981; }
.text-blue { color: #3b82f6; }

/* WIZARD NAVIGATION FOOTER */
.learn-wizard-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding-top: 14px;
  border-top: 2px solid #000000;
  gap: 16px;
}

.btn-step-back {
  font-family: var(--font-display) !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  padding: 10px 20px !important;
  background: #1e293b !important;
  border: 2px solid #000000 !important;
  box-shadow: 3px 3px 0px #000000 !important;
  color: #ffffff !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
}

.btn-step-back:hover {
  background: #334155 !important;
  transform: translate(-1px, -1px) !important;
  box-shadow: 4px 4px 0px #000000 !important;
}

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

.step-dot {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: #1e293b;
  border: 1.5px solid #000000;
  box-shadow: 1px 1px 0px #000000;
  cursor: pointer;
  transition: all 0.2s ease;
}

.step-dot.active {
  width: 28px;
  border-radius: 4px;
  background: #ccff00;
  box-shadow: 2px 2px 0px #000000;
}

.btn-step-next {
  font-family: var(--font-display) !important;
  font-size: 14.5px !important;
  font-weight: 800 !important;
  padding: 11px 24px !important;
  background: #00f0ff !important;
  border: 2px solid #000000 !important;
  color: #000000 !important;
  border-radius: 6px !important;
  box-shadow: 3px 3px 0px #000000 !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
}

.btn-step-next:hover {
  background: #38bdf8 !important;
  box-shadow: 4px 4px 0px #000000 !important;
  transform: translate(-1px, -1px) !important;
}

/* ============================================================== */
/* CREATOR STAMP & ABOUT ADITYA MODAL                            */
/* ============================================================== */
.creator-stamp-btn {
  position: absolute;
  bottom: 20px;
  right: 20px;
  z-index: 35;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(10, 15, 28, 0.80);
  backdrop-filter: blur(20px) saturate(190%);
  -webkit-backdrop-filter: blur(20px) saturate(190%);
  border: 1px solid rgba(0, 240, 255, 0.35);
  border-radius: 999px;
  padding: 7px 16px;
  color: #f1f5f9;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.25px;
  cursor: pointer;
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.2), 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  animation: stampPulseAura 4s ease-in-out infinite;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes stampPulseAura {
  0%, 100% {
    border-color: rgba(0, 240, 255, 0.35);
    box-shadow: 0 0 16px rgba(0, 240, 255, 0.25), 0 10px 28px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  }
  50% {
    border-color: rgba(204, 255, 0, 0.5);
    box-shadow: 0 0 24px rgba(204, 255, 0, 0.35), 0 12px 32px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  }
}

.creator-stamp-btn .stamp-icon {
  color: #ccff00;
  font-size: 12px;
  filter: drop-shadow(0 0 8px rgba(204, 255, 0, 0.85));
  animation: stampIconGlow 4s ease-in-out infinite;
}

@keyframes stampIconGlow {
  0%, 100% {
    filter: drop-shadow(0 0 6px rgba(0, 240, 255, 0.8));
    color: #38bdf8;
  }
  50% {
    filter: drop-shadow(0 0 10px rgba(204, 255, 0, 0.95));
    color: #ccff00;
  }
}

.creator-stamp-btn:hover {
  background: rgba(15, 23, 42, 0.96);
  border-color: #00f0ff;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 0 26px rgba(0, 240, 255, 0.4), 0 14px 36px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.creator-stamp-btn:active {
  transform: translateY(0);
}

.creator-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(3, 6, 14, 0.85);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  padding: 20px;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s ease;
}

.creator-modal-backdrop.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.creator-modal-card {
  position: relative;
  background: rgba(10, 15, 28, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 22px;
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.85), 0 0 45px rgba(6, 182, 212, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  max-width: 460px;
  width: 100%;
  max-height: 90dvh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 30px 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  animation: creatorModalIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes creatorModalIn {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.creator-modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s ease;
}

.creator-modal-close:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.4);
  transform: rotate(90deg);
}

.creator-modal-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.creator-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  color: #ccff00;
  letter-spacing: 0.8px;
}

.creator-name {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin: 0;
}

.creator-tagline {
  font-family: var(--font-sans);
  font-size: 12.5px;
  color: #94a3b8;
  margin: 0;
}

.creator-bio-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px 18px;
}

.creator-bio-line {
  font-family: var(--font-sans);
  font-size: 13.5px;
  line-height: 1.55;
  color: #e2e8f0;
  margin: 0;
}

.creator-bio-line strong {
  color: #38bdf8;
  font-weight: 700;
}

.creator-cta-title {
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 800;
  color: #ccff00;
  letter-spacing: 0.3px;
  line-height: 1.4;
  margin-top: 4px;
  margin-bottom: -2px;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.creator-links-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.creator-social-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-radius: 12px;
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.creator-social-btn .btn-label {
  display: flex;
  align-items: center;
  gap: 10px;
}

.creator-social-btn .btn-arrow {
  font-family: var(--font-mono);
  font-size: 14px;
  transition: transform 0.18s ease;
}

.creator-social-btn:hover .btn-arrow {
  transform: translate(2px, -2px);
}

.linkedin-btn {
  background: rgba(10, 102, 194, 0.16);
  border: 1px solid rgba(10, 102, 194, 0.45);
  color: #38bdf8;
}

.linkedin-btn:hover {
  background: #0a66c2;
  border-color: #0a66c2;
  color: #ffffff;
  box-shadow: 0 8px 24px rgba(10, 102, 194, 0.45);
}

.insta-btn {
  background: rgba(225, 48, 108, 0.14);
  border: 1px solid rgba(225, 48, 108, 0.4);
  color: #f472b6;
}

.insta-btn:hover {
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  border-color: transparent;
  color: #ffffff;
  box-shadow: 0 8px 24px rgba(225, 48, 108, 0.45);
}

/* Discreet Live Reference Counter at Bottom-Right of Entire Page */
.app-discreet-counter,
.creator-visitor-counter {
  position: fixed;
  bottom: 6px;
  right: 12px;
  z-index: 9999;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 1px 4px;
  background: transparent;
  border-radius: 3px;
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 8px;
  color: rgba(148, 163, 184, 0.4);
  letter-spacing: 0.3px;
  user-select: none;
  pointer-events: auto;
  cursor: default;
  line-height: 1;
  transition: all 0.2s ease;
}

.app-discreet-counter:hover,
.creator-visitor-counter:hover {
  color: rgba(241, 245, 249, 0.9);
  background: rgba(0, 0, 0, 0.7);
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.6);
}

.app-discreet-counter .counter-val,
.creator-visitor-counter .counter-val {
  font-weight: 700;
  font-size: 8px;
  color: inherit;
}

.app-discreet-counter .counter-sep,
.creator-visitor-counter .counter-sep {
  color: inherit;
  opacity: 0.5;
  font-size: 7.5px;
  margin: 0 1px;
}

/* ============================================================== */
/* MOBILE & MOBILE DESKTOP RESPONSIVENESS                         */
/* ============================================================== */

/* Mobile Portrait Landscape Orientation Suggestion Chip */
.mobile-landscape-hint {
  display: none;
}

@keyframes rotateNudge {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-22deg); }
  75% { transform: rotate(22deg); }
}

@keyframes hintBounceIn {
  from {
    opacity: 0;
    transform: translate(-50%, -10px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

/* Portrait Mobile (phones held vertically) */
@media (max-width: 768px) and (orientation: portrait) {
  .mobile-landscape-hint {
    position: absolute;
    top: 52px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 95;
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(10, 15, 28, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(56, 189, 248, 0.45);
    border-radius: 999px;
    padding: 6px 14px 6px 12px;
    color: #f1f5f9;
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), 0 0 16px rgba(56, 189, 248, 0.25);
    pointer-events: auto;
    animation: hintBounceIn 0.3s ease-out;
    white-space: nowrap;
  }

  .mobile-landscape-hint.dismissed {
    display: none !important;
  }

  .mobile-landscape-hint .hint-icon {
    font-size: 13px;
    animation: rotateNudge 3s ease-in-out infinite;
  }

  .mobile-landscape-hint .hint-close {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 15px;
    cursor: pointer;
    padding: 0 0 0 4px;
    line-height: 1;
  }

  .mobile-landscape-hint .hint-close:hover {
    color: #ffffff;
  }
}

/* General Mobile Phone Viewport (Portrait & Small Screens) */
@media (max-width: 768px) {
  .app-header.spatial-nav-bar {
    top: 6px;
    left: 8px;
    right: 8px;
    gap: 6px;
  }

  .header-corner-pod {
    padding: 4px 10px;
  }

  .logo-mark {
    width: 28px;
    height: 28px;
  }

  .logo-mark svg {
    width: 18px;
    height: 18px;
  }

  .brand-name {
    font-size: 15px;
  }

  .header-right-pod {
    padding: 3px 8px;
    gap: 4px;
    max-width: calc(100vw - 160px);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .header-btn {
    padding: 5px 8px !important;
    font-size: 11px !important;
    white-space: nowrap;
  }

  .record-mode-select {
    display: none; /* In small mobile screens, default to camera recording */
  }

  /* Bottom Controls: Non-overlapping Stacked Layout */
  .calibration-row {
    bottom: 56px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100vw - 20px);
    max-width: 380px;
    padding: 4px 10px;
    gap: 8px;
  }

  .hud-holes-bar {
    bottom: 10px;
    left: 12px;
    transform: none;
    padding: 4px 8px;
  }

  .hole-pip {
    width: 17px;
    height: 17px;
    font-size: 7px;
  }

  .holes-hand-group {
    gap: 6px;
  }

  .holes-row {
    gap: 3px;
  }

  .creator-stamp-btn {
    bottom: 10px;
    right: 12px;
    padding: 5px 11px;
    font-size: 10px;
    gap: 5px;
  }

  .creator-stamp-btn .stamp-icon {
    font-size: 10px;
  }

  /* Modals on Mobile Phones */
  .creator-modal-card {
    max-width: 92vw;
    max-height: 88dvh;
    padding: 22px 18px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .creator-name {
    font-size: 22px;
  }

  .creator-bio-line {
    font-size: 12.5px;
  }

  .creator-cta-title {
    font-size: 12px;
  }

  .creator-social-btn {
    padding: 10px 14px;
    font-size: 12.5px;
  }

  .learn-modal-card {
    max-width: 94vw !important;
    max-height: 90dvh !important;
    padding: 14px 14px !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }
}

/* Landscape Phone Mode (horizontal screen for optimal 2-hand flute posture) */
@media (max-width: 920px) and (orientation: landscape) {
  .app-header.spatial-nav-bar {
    top: 6px;
    left: 10px;
    right: 10px;
  }

  .header-left-pod {
    padding: 3px 10px;
  }

  .header-right-pod {
    padding: 3px 8px;
  }

  .brand-name {
    font-size: 14px;
  }

  .calibration-row {
    bottom: 8px;
    left: 10px;
    transform: none;
    width: 260px;
    padding: 3px 8px;
    gap: 6px;
  }

  .hud-holes-bar {
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    padding: 3px 8px;
  }

  .creator-stamp-btn {
    bottom: 8px;
    right: 10px;
    padding: 4px 10px;
    font-size: 9.5px;
  }
}



