/* ═══════════════════════════════════════════════════════════════
   MidiVFX — Website Stylesheet
   Dark, premium, glassmorphism aesthetic
   ═══════════════════════════════════════════════════════════════ */

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

:root {
  --bg: #06080f;
  --bg-2: #0d1120;
  --bg-3: #131827;
  --surface: rgba(255,255,255,0.04);
  --surface-hover: rgba(255,255,255,0.07);
  --border: rgba(255,255,255,0.08);
  --border-strong: rgba(255,255,255,0.14);

  --text: #f1f5f9;
  --text-2: #94a3b8;
  --text-3: #64748b;

  --purple: #a78bfa;
  --blue: #60a5fa;
  --green: #34d399;
  --pink: #f472b6;
  --orange: #fb923c;
  --yellow: #fbbf24;

  --grad: linear-gradient(135deg, #a78bfa, #60a5fa, #34d399);
  --grad-glow: linear-gradient(135deg, rgba(167,139,250,0.3), rgba(96,165,250,0.3));

  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;

  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 40px rgba(167,139,250,0.2);

  --nav-h: 68px;
  --font: 'Inter', -apple-system, sans-serif;
  --font-display: 'Space Grotesk', sans-serif;
}

html { scroll-behavior: smooth; }

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

/* ─── TYPOGRAPHY ───────────────────────────────────────────────── */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  line-height: 1.2;
  font-weight: 700;
}
h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.15rem; }
h5 { font-size: 1rem; }
p { color: var(--text-2); }

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

.lead {
  font-size: 1.15rem;
  line-height: 1.7;
  margin-bottom: 2rem;
}

/* ─── LAYOUT ───────────────────────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 100px 0;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.two-col.reverse { direction: rtl; }
.two-col.reverse > * { direction: ltr; }

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 64px;
}
.section-header h2 { margin: 12px 0 16px; }
.section-header p { font-size: 1.1rem; }

.section-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--purple);
  background: rgba(167,139,250,0.12);
  border: 1px solid rgba(167,139,250,0.25);
  padding: 4px 14px;
  border-radius: 100px;
  margin-bottom: 4px;
}

/* ─── BUTTONS ──────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.btn-primary {
  background: var(--purple);
  color: #fff;
  box-shadow: 0 4px 20px rgba(167,139,250,0.35);
}
.btn-primary:hover {
  background: #b99df9;
  box-shadow: 0 6px 28px rgba(167,139,250,0.5);
  transform: translateY(-1px);
}

.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: var(--surface-hover);
  border-color: var(--border-strong);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-strong);
}
.btn-outline:hover {
  background: var(--surface);
  border-color: var(--purple);
  color: var(--purple);
}

.btn-lg { padding: 14px 28px; font-size: 1rem; }
.btn-xl { padding: 16px 36px; font-size: 1.05rem; border-radius: 12px; }

/* ─── NAV ──────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(6,8,15,0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}
.nav.scrolled {
  background: rgba(6,8,15,0.95);
  box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-logo { display: flex; align-items: center; text-decoration: none; }
.nav-logo-img { height: 36px; width: auto; }

.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
  margin-left: auto;
}
.nav-links a {
  color: var(--text-2);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.nav-cta { margin-left: 16px; }

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  margin-left: auto;
}
.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

.nav-mobile {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 16px 24px;
  background: rgba(6,8,15,0.98);
  border-top: 1px solid var(--border);
}
.nav-mobile a {
  color: var(--text-2);
  text-decoration: none;
  font-size: 1rem;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.nav-mobile a:last-child { border-bottom: none; }
.nav-mobile.open { display: flex; }

/* ─── HERO ─────────────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  padding-top: var(--nav-h);
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.15;
}
.hero-orb-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, #a78bfa, transparent 70%);
  top: -200px; left: -200px;
  animation: orb-float 8s ease-in-out infinite;
}
.hero-orb-2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, #60a5fa, transparent 70%);
  bottom: -100px; right: -100px;
  animation: orb-float 10s ease-in-out infinite reverse;
}
.hero-orb-3 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, #34d399, transparent 70%);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  animation: orb-float 12s ease-in-out infinite 2s;
}

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

@keyframes orb-float {
  0%, 100% { transform: translate(0,0) scale(1); }
  33% { transform: translate(30px,-20px) scale(1.05); }
  66% { transform: translate(-20px,15px) scale(0.95); }
}

.hero-content { padding: 60px 0; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--green);
  background: rgba(52,211,153,0.1);
  border: 1px solid rgba(52,211,153,0.25);
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 24px;
}

.hero-title {
  margin-bottom: 24px;
  color: var(--text);
}

.hero-subtitle {
  font-size: 1.15rem;
  line-height: 1.7;
  margin-bottom: 40px;
  max-width: 520px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 52px;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
  gap: 24px;
}

.stat { text-align: left; }
.stat-num {
  display: block;
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
}
.stat-label {
  display: block;
  font-size: 0.78rem;
  color: var(--text-3);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ─── HERO PIANO VISUAL ─────────────────────────────────────────── */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.piano-demo {
  width: 100%;
  max-width: 440px;
  background: rgba(13,17,32,0.8);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 0 1px var(--border);
  backdrop-filter: blur(20px);
}

.piano-screen {
  height: 260px;
  background: linear-gradient(to bottom, #0a0d18, #0f1422);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.piano-label {
  position: absolute;
  top: 12px;
  left: 14px;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  color: var(--green);
  opacity: 0.7;
}

.fx-particle {
  position: absolute;
  border-radius: 50%;
  animation: particle-float 3s ease-in-out infinite;
}
.p1 { width:60px;height:60px;background:radial-gradient(circle,rgba(167,139,250,0.6),transparent 70%);top:30%;left:20%;animation-delay:0s;animation-duration:3.5s; }
.p2 { width:40px;height:40px;background:radial-gradient(circle,rgba(96,165,250,0.6),transparent 70%);top:50%;left:55%;animation-delay:0.5s;animation-duration:4s; }
.p3 { width:80px;height:80px;background:radial-gradient(circle,rgba(52,211,153,0.4),transparent 70%);top:20%;left:65%;animation-delay:1s;animation-duration:3s; }
.p4 { width:35px;height:35px;background:radial-gradient(circle,rgba(244,114,182,0.7),transparent 70%);top:65%;left:35%;animation-delay:1.5s;animation-duration:4.5s; }
.p5 { width:50px;height:50px;background:radial-gradient(circle,rgba(251,191,36,0.5),transparent 70%);top:40%;left:80%;animation-delay:2s;animation-duration:3.8s; }
.p6 { width:45px;height:45px;background:radial-gradient(circle,rgba(251,146,60,0.5),transparent 70%);top:75%;left:70%;animation-delay:0.8s;animation-duration:4.2s; }

.fx-beam {
  position: absolute;
  height: 2px;
  border-radius: 2px;
  animation: beam-travel 2.5s ease-in-out infinite;
}
.b1 { width:120px;background:linear-gradient(90deg,transparent,rgba(167,139,250,0.8),transparent);top:35%;left:-120px;animation-delay:0s; }
.b2 { width:80px;background:linear-gradient(90deg,transparent,rgba(52,211,153,0.8),transparent);top:55%;left:-80px;animation-delay:1s; }
.b3 { width:100px;background:linear-gradient(90deg,transparent,rgba(244,114,182,0.8),transparent);top:70%;left:-100px;animation-delay:1.8s; }

@keyframes particle-float {
  0%,100% { transform: translate(0,0) scale(1); opacity:0.7; }
  50% { transform: translate(8px,-12px) scale(1.15); opacity:1; }
}

@keyframes beam-travel {
  0% { transform: translateX(0); opacity:0; }
  10% { opacity:1; }
  90% { opacity:1; }
  100% { transform: translateX(calc(440px + 120px)); opacity:0; }
}

.piano-keys {
  display: flex;
  height: 100px;
  position: relative;
  background: #111;
  padding: 0 8px;
}

.key {
  position: relative;
  border-radius: 0 0 6px 6px;
  cursor: pointer;
  transition: all 0.1s;
}

.key.white {
  flex: 1;
  background: linear-gradient(to bottom, #e8e8e8, #fff);
  border: 1px solid #999;
  border-top: none;
  height: 100%;
  margin: 0 1px;
}
.key.white.active {
  background: linear-gradient(to bottom, var(--purple), #c4b0fd);
  box-shadow: 0 0 12px rgba(167,139,250,0.6);
  border-color: var(--purple);
}

.key.black {
  position: absolute;
  width: 8%;
  height: 60%;
  background: linear-gradient(to bottom, #333, #111);
  border-radius: 0 0 4px 4px;
  z-index: 2;
  top: 0;
}
.key.black.active {
  background: linear-gradient(to bottom, var(--pink), #b23a7a);
  box-shadow: 0 0 10px rgba(244,114,182,0.6);
}

/* approximate black key positions for 13-key layout */
.bk1 { left: calc(7.7% - 4%); }
.bk2 { left: calc(7.7% * 2 + 7.7% - 4%); }
.bk3 { left: calc(7.7% * 5 - 4%); }
.bk4 { left: calc(7.7% * 6 - 4%); }
.bk5 { left: calc(7.7% * 7 - 4%); }

/* ─── OVERVIEW CARDS ────────────────────────────────────────────── */
.overview { background: var(--bg); }

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

.overview-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: all 0.3s ease;
}
.overview-card:hover {
  background: var(--surface-hover);
  border-color: var(--border-strong);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}
.overview-card.card-large {
  grid-column: span 1;
  background: linear-gradient(135deg, rgba(167,139,250,0.08), rgba(96,165,250,0.04));
  border-color: rgba(167,139,250,0.2);
}

.card-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: rgba(var(--c-rgb, 167,139,250), 0.12);
  border: 1px solid rgba(var(--c-rgb, 167,139,250), 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--c, var(--purple));
}

.overview-card h3 { margin-bottom: 12px; color: var(--text); }
.overview-card p { font-size: 0.9rem; margin-bottom: 16px; }

.card-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.card-list li {
  font-size: 0.85rem;
  color: var(--text-3);
  padding-left: 16px;
  position: relative;
}
.card-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--purple);
}

/* ─── VISUAL EFFECTS ────────────────────────────────────────────── */
.visuals-section { background: var(--bg-2); }

.fx-showcase {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 80px;
}

.fx-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.3s;
}
.fx-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow);
}
.fx-card h4 {
  padding: 16px 20px 4px;
  color: var(--text);
}
.fx-card p {
  padding: 0 20px 20px;
  font-size: 0.85rem;
}

.fx-preview {
  height: 140px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(to bottom, #0a0d18, #0f1422);
}

/* Note bars animation */
.fx-note-bar {
  position: absolute;
  height: 14px;
  width: var(--w, 70%);
  left: 4px;
  border-radius: 7px;
  background: var(--c, var(--purple));
  box-shadow: 0 0 12px var(--c, var(--purple));
  animation: note-expand 2s ease-in-out infinite var(--delay, 0s);
  opacity: 0;
}
.fx-note-bar:nth-child(1) { top: 20px; }
.fx-note-bar:nth-child(2) { top: 45px; }
.fx-note-bar:nth-child(3) { top: 70px; }
.fx-note-bar:nth-child(4) { top: 95px; }
.fx-note-bar:nth-child(5) { top: 118px; }

@keyframes note-expand {
  0% { width: 4px; opacity: 0; }
  20% { opacity: 1; }
  70% { width: var(--w, 70%); opacity: 1; }
  100% { width: var(--w, 70%); opacity: 0; }
}

/* Bounce animation */
.bounce-ball {
  position: absolute;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--c, var(--purple));
  box-shadow: 0 0 14px var(--c, var(--purple));
  left: var(--x, 30%);
  animation: bounce-anim 1.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) infinite var(--delay, 0s);
  bottom: 10px;
}
@keyframes bounce-anim {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-80px) scale(0.85); }
}

/* Creature animation */
.creature {
  position: absolute;
  width: 80%;
  height: 12px;
  left: 10%;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--c, var(--green)), transparent);
  box-shadow: 0 0 16px var(--c, var(--green));
  animation: creature-swim 3s ease-in-out infinite var(--delay, 0s);
  top: calc(20px + var(--delay, 0s) * 20px);
}
@keyframes creature-swim {
  0% { transform: translateX(-100%) scaleX(0.8); opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { transform: translateX(120%) scaleX(1.1); opacity: 0; }
}

/* Particles */
.micro-p {
  position: absolute;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--c, var(--pink));
  box-shadow: 0 0 8px var(--c, var(--pink));
  left: var(--x, 50%);
  top: var(--y, 50%);
  animation: micro-burst 2s ease-out infinite var(--delay, 0s);
}
@keyframes micro-burst {
  0% { transform: scale(0); opacity: 1; }
  60% { transform: scale(2.5); opacity: 0.6; }
  100% { transform: scale(3.5); opacity: 0; }
}

/* Path section */
.path-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding: 60px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.path-text h3 { margin-bottom: 16px; color: var(--text); }
.path-text p { margin-bottom: 24px; }

.path-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.path-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--text-2);
}
.path-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--c, var(--purple));
  box-shadow: 0 0 8px var(--c, var(--purple));
  flex-shrink: 0;
}

.bezier-svg { width: 100%; height: auto; }

.anim-dot {
  animation: dot-travel 3s ease-in-out infinite;
}
@keyframes dot-travel {
  0% { cx: 20; cy: 160; }
  100% { cx: 380; cy: 40; }
}

/* ─── COLORS SECTION ────────────────────────────────────────────── */
.colors-section { background: var(--bg); }

.color-modes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.color-mode {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  cursor: pointer;
  transition: all 0.3s;
}
.color-mode:hover, .color-mode.active {
  border-color: rgba(167,139,250,0.4);
  background: rgba(167,139,250,0.06);
  box-shadow: 0 0 24px rgba(167,139,250,0.1);
}

.color-mode-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.color-mode-icon {
  width: 32px; height: 32px;
  border-radius: 8px;
}
.color-mode-header h4 { color: var(--text); }
.color-mode p { font-size: 0.85rem; margin-bottom: 16px; }

.channel-bars {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ch-bar {
  height: 24px;
  border-radius: 4px;
  background: var(--c, var(--purple));
  display: flex;
  align-items: center;
  padding: 0 8px;
  font-size: 0.7rem;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
  box-shadow: 0 0 8px var(--c, var(--purple));
  opacity: 0.85;
}

.chromatic-pills, .degree-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.chromatic-pills span, .degree-pills span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 8px;
  background: var(--c, var(--purple));
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
  box-shadow: 0 0 8px var(--c, var(--purple));
}

.velocity-gradient {
  height: 20px;
  border-radius: 6px;
  background: linear-gradient(90deg, #3b82f6, #a78bfa, #ef4444);
  margin-bottom: 8px;
  box-shadow: 0 0 12px rgba(167,139,250,0.3);
}
.pitch-gradient {
  height: 20px;
  border-radius: 6px;
  background: linear-gradient(90deg, #818cf8, #c084fc, #f472b6, #fb923c, #fbbf24);
  margin-bottom: 8px;
  box-shadow: 0 0 12px rgba(167,139,250,0.3);
}
.velocity-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-3);
}

/* ─── MIDI SECTION ──────────────────────────────────────────────── */
.midi-section { background: var(--bg-2); }

.col-text .section-tag { display: inline-block; margin-bottom: 16px; }
.col-text h2 { margin-bottom: 16px; }

.feature-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.feature-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.fi-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(167,139,250,0.1);
  border: 1px solid rgba(167,139,250,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--c, var(--purple));
  flex-shrink: 0;
}
.feature-item h5 { color: var(--text); margin-bottom: 4px; }
.feature-item p { font-size: 0.85rem; }

/* MIDI Display widget */
.midi-display {
  background: rgba(13,17,32,0.9);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.5);
}

.midi-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
  font-size: 0.82rem;
  color: var(--text-2);
}
.midi-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--text-3);
}
.midi-dot.connected {
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%,100% { box-shadow: 0 0 4px var(--green); }
  50% { box-shadow: 0 0 12px var(--green); }
}

.midi-channels {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
}
.midi-ch {
  display: grid;
  grid-template-columns: 32px 1fr 60px;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: all 0.2s;
}
.midi-ch.active {
  background: rgba(var(--c-rgb, 167,139,250), 0.08);
  border-color: var(--c, var(--purple));
  box-shadow: 0 0 12px rgba(var(--c-rgb,167,139,250),0.15);
}
.ch-num {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--c, var(--purple));
  font-variant-numeric: tabular-nums;
}
.ch-activity {
  height: 6px;
  background: rgba(255,255,255,0.06);
  border-radius: 3px;
  overflow: hidden;
}
.ch-bar-fill {
  height: 100%;
  background: var(--c, var(--purple));
  border-radius: 3px;
  box-shadow: 0 0 6px var(--c, var(--purple));
}
.ch-name {
  font-size: 0.78rem;
  color: var(--text-3);
  text-align: right;
}

.midi-info-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.mi-stat {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  text-align: center;
}
.mi-val {
  display: block;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
}
.mi-lbl {
  display: block;
  font-size: 0.65rem;
  color: var(--text-3);
  margin-top: 2px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ─── STAGE SECTION ─────────────────────────────────────────────── */
.stage-section { background: var(--bg-3); }

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

.stage-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: all 0.3s;
}
.stage-card:hover {
  background: var(--surface-hover);
  border-color: var(--border-strong);
  transform: translateY(-3px);
}
.stage-icon { font-size: 2rem; margin-bottom: 16px; }
.stage-card h4 { color: var(--text); margin-bottom: 10px; }
.stage-card p { font-size: 0.88rem; }

/* ─── GAME MODE ─────────────────────────────────────────────────── */
.gamemode-section { background: var(--bg-2); }

.game-display {
  background: rgba(13,17,32,0.95);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0,0,0,0.5);
}
.game-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
}
.game-badge {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--pink);
  animation: badge-pulse 1.5s ease-in-out infinite;
}
@keyframes badge-pulse {
  0%,100% { opacity:1; }
  50% { opacity:0.5; }
}
.game-score { font-family: var(--font-display); font-size: 0.9rem; color: var(--yellow); }

.game-lanes {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 180px;
  padding: 0 16px;
  gap: 8px;
  position: relative;
}
.game-lane {
  position: relative;
  border-right: 1px solid rgba(255,255,255,0.04);
}
.game-lane:last-child { border-right: none; }

.game-note {
  position: absolute;
  width: 80%;
  left: 10%;
  height: 20px;
  border-radius: 6px;
  background: var(--c, var(--purple));
  box-shadow: 0 0 10px var(--c, var(--purple));
  top: var(--pos, 30%);
  animation: note-fall 2s linear infinite;
}
.game-note.gn-hit {
  background: var(--green);
  box-shadow: 0 0 14px var(--green);
}
.game-note.gn-miss { opacity: 0.3; }

@keyframes note-fall {
  from { transform: translateY(-20px); }
  to { transform: translateY(200px); }
}

.hit-zone {
  position: absolute;
  bottom: 16px;
  left: 5%; right: 5%;
  height: 3px;
  background: rgba(255,255,255,0.15);
  border-radius: 2px;
}

.game-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  gap: 8px;
}
.gs-item {
  text-align: center;
  padding: 10px;
  background: var(--surface);
  border-radius: 8px;
}
.gs-item.hit { border: 1px solid rgba(52,211,153,0.3); }
.gs-item.miss { border: 1px solid rgba(244,114,182,0.3); }
.gs-item.streak { border: 1px solid rgba(251,191,36,0.3); }
.gs-num {
  display: block;
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text);
}
.gs-lbl {
  font-size: 0.68rem;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.check-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}
.check-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-2);
  font-size: 0.95rem;
}
.check-list li::before {
  content: '✓';
  color: var(--green);
  font-weight: 700;
  flex-shrink: 0;
}

/* ─── THEORY SECTION ────────────────────────────────────────────── */
.theory-section { background: var(--bg); }

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

.theory-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}
.theory-card h4 { color: var(--text); margin-bottom: 20px; }

.scale-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.scale-list span {
  font-size: 0.78rem;
  background: rgba(167,139,250,0.1);
  border: 1px solid rgba(167,139,250,0.2);
  color: var(--text-2);
  padding: 4px 10px;
  border-radius: 6px;
}

.notation-table { display: flex; flex-direction: column; gap: 6px; }
.nt-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--text-2);
}
.nt-row.header { font-weight: 600; color: var(--text-3); font-size: 0.75rem; text-transform: uppercase; }
.nt-note { color: var(--purple); font-family: monospace; }

.chord-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chord-pills span {
  font-size: 0.78rem;
  background: rgba(96,165,250,0.1);
  border: 1px solid rgba(96,165,250,0.2);
  color: var(--blue);
  padding: 4px 10px;
  border-radius: 6px;
}

/* ─── RECORDING SECTION ─────────────────────────────────────────── */
.recording-section { background: var(--bg-3); }

.rec-modes {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}
.rec-mode {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}
.rec-icon {
  width: 48px; height: 48px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  flex-shrink: 0;
}
.midi-icon { background: rgba(52,211,153,0.15); color: var(--green); border: 1px solid rgba(52,211,153,0.3); }
.video-icon { background: rgba(244,114,182,0.15); color: var(--pink); border: 1px solid rgba(244,114,182,0.3); }
.both-icon { background: rgba(167,139,250,0.15); color: var(--purple); border: 1px solid rgba(167,139,250,0.3); }
.rec-mode h5 { color: var(--text); margin-bottom: 4px; }
.rec-mode p { font-size: 0.85rem; }

.rec-specs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.rs-item {
  text-align: center;
  padding: 16px 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}
.rs-val {
  display: block;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--purple);
}
.rs-lbl {
  font-size: 0.68rem;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Recording display */
.rec-display {
  background: rgba(13,17,32,0.95);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0,0,0,0.5);
}

.rec-indicator {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: rgba(239,68,68,0.1);
  border-bottom: 1px solid rgba(239,68,68,0.2);
}
.rec-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444;
  animation: rec-blink 1s steps(1) infinite;
}
@keyframes rec-blink {
  50% { opacity: 0; }
}
.rec-indicator span { color: #f87171; font-size: 0.8rem; font-weight: 600; }
.rec-time {
  margin-left: auto;
  font-family: monospace;
  font-size: 0.85rem;
  color: #f87171;
}

.rec-settings {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.rs-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.82rem;
}
.rs-row:last-child { border-bottom: none; }
.rs-label { color: var(--text-3); }
.rs-value { color: var(--text); font-weight: 500; }
.rs-on { color: var(--green); }
.rs-path { color: var(--text-3); font-family: monospace; font-size: 0.75rem; }

.rec-waveform {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  padding: 16px 20px;
  height: 60px;
  background: rgba(0,0,0,0.2);
}
.wf-bar {
  flex: 1;
  height: var(--h, 50%);
  background: #ef4444;
  border-radius: 2px;
  opacity: 0.7;
  animation: wf-animate 0.8s ease-in-out infinite alternate;
  animation-delay: calc(var(--h, 50%) * 0.1s);
}
@keyframes wf-animate {
  to { height: calc(var(--h, 50%) * 0.4); }
}

/* ─── AUDIO SECTION ─────────────────────────────────────────────── */
.audio-section { background: var(--bg-2); }

.audio-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.audio-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: all 0.3s;
}
.audio-card:hover {
  background: var(--surface-hover);
  transform: translateY(-3px);
  border-color: var(--border-strong);
}
.audio-icon { font-size: 2rem; margin-bottom: 16px; }
.audio-card h4 { color: var(--text); margin-bottom: 10px; }
.audio-card p { font-size: 0.88rem; }

/* ─── LANGUAGES ─────────────────────────────────────────────────── */
.languages-section { background: var(--bg); }

.lang-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  max-width: 700px;
  margin: 0 auto;
}
.lang-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 20px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  color: var(--text-2);
  transition: all 0.3s;
  text-align: center;
}
.lang-card:hover {
  background: var(--surface-hover);
  border-color: rgba(167,139,250,0.3);
  transform: translateY(-2px);
}
.lang-flag { font-size: 1.8rem; }

/* ─── DOWNLOAD SECTION ──────────────────────────────────────────── */
.download-section {
  position: relative;
  padding: 120px 0;
  overflow: hidden;
  text-align: center;
}
.download-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.dl-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.2;
}
.dl-orb-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, #a78bfa, transparent 70%);
  top: -200px; left: -100px;
}
.dl-orb-2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, #34d399, transparent 70%);
  bottom: -150px; right: -100px;
}

.download-content {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
}
.dl-logo {
  height: 60px;
  width: auto;
  margin-bottom: 32px;
  filter: drop-shadow(0 0 20px rgba(167,139,250,0.4));
}
.download-content h2 { margin-bottom: 16px; }
.download-content p { margin-bottom: 40px; font-size: 1.1rem; }

.dl-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.dl-platforms {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: 0.82rem;
  color: var(--text-3);
}

/* ─── FOOTER ────────────────────────────────────────────────────── */
.footer {
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 80px;
  margin-bottom: 48px;
}

.footer-brand .footer-logo {
  height: 36px;
  width: auto;
  margin-bottom: 16px;
}
.footer-brand p { font-size: 0.9rem; margin-bottom: 20px; }
.footer-unrez {
  height: 28px;
  width: auto;
  opacity: 0.5;
  filter: grayscale(1);
  transition: all 0.3s;
}
.footer-unrez:hover { opacity: 0.8; filter: none; }

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.fl-col h5 {
  color: var(--text);
  margin-bottom: 16px;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.fl-col a {
  display: block;
  color: var(--text-3);
  text-decoration: none;
  font-size: 0.88rem;
  margin-bottom: 10px;
  transition: color 0.2s;
}
.fl-col a:hover { color: var(--text-2); }

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 0.8rem;
  color: var(--text-3);
  text-align: center;
}

/* ─── RESPONSIVE ────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: calc(var(--nav-h) + 40px);
    padding-bottom: 60px;
    text-align: center;
  }
  .hero-visual { display: none; }
  .hero-actions, .hero-stats { justify-content: center; }
  .hero-subtitle { max-width: 600px; margin-left: auto; margin-right: auto; }

  .overview-grid { grid-template-columns: 1fr 1fr; }
  .fx-showcase { grid-template-columns: 1fr 1fr; }
  .two-col { grid-template-columns: 1fr; gap: 48px; }
  .two-col.reverse { direction: ltr; }
  .theory-grid { grid-template-columns: 1fr; }
  .audio-grid { grid-template-columns: 1fr 1fr; }
  .stage-grid { grid-template-columns: 1fr 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 48px; }
  .path-section { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  section { padding: 70px 0; }
  .nav-links, .nav-cta { display: none; }
  .nav-hamburger { display: flex; }
  .overview-grid { grid-template-columns: 1fr; }
  .fx-showcase { grid-template-columns: 1fr; }
  .color-modes { grid-template-columns: 1fr; }
  .lang-grid { grid-template-columns: repeat(3, 1fr); }
  .rec-specs { grid-template-columns: repeat(2, 1fr); }
  .theory-grid { grid-template-columns: 1fr; }
  .audio-grid { grid-template-columns: 1fr; }
  .stage-grid { grid-template-columns: 1fr; }
  .footer-links { grid-template-columns: 1fr 1fr; }
  .midi-info-row { grid-template-columns: 1fr 1fr; }
  h1 { font-size: 2.2rem; }
  h2 { font-size: 1.8rem; }
}

@media (max-width: 480px) {
  .hero-stats { flex-direction: column; align-items: center; gap: 16px; }
  .stat-divider { width: 40px; height: 1px; }
  .lang-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-links { grid-template-columns: 1fr; }
  .dl-buttons { flex-direction: column; align-items: center; }
}

/* ─── SCROLL ANIMATIONS ─────────────────────────────────────────── */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── SCROLLBAR ─────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

/* ─── SELECTION ─────────────────────────────────────────────────── */
::selection { background: rgba(167,139,250,0.3); color: var(--text); }
