/* Design Tokens & Theme Setup */
:root {
  /* Fonts */
  --font-serif: 'Cormorant Garamond', serif;
  --font-sans: 'Outfit', sans-serif;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* elastic */

  /* Global light scheme (Parchment theme) variables */
  --bg-primary: hsl(43, 44%, 95%);
  --bg-secondary: hsl(43, 46%, 90%);
  --text-primary: hsl(30, 48%, 12%);
  --text-secondary: hsl(30, 24%, 35%);
  --accent-gold: hsl(36, 75%, 42%);
  --accent-gold-hover: hsl(36, 85%, 35%);
  --accent-gold-glow: hsla(36, 75%, 42%, 0.15);
  --border-color: hsla(30, 48%, 12%, 0.08);
  
  --glass-bg: hsla(43, 44%, 95%, 0.75);
  --glass-border: hsla(30, 48%, 12%, 0.06);
  --shadow-color: hsla(30, 48%, 12%, 0.08);
  
  --color-success: hsl(120, 45%, 38%);
  --color-danger: hsl(0, 75%, 45%);
  --color-warning: hsl(38, 90%, 45%);

  --scrollbar-thumb: hsl(30, 24%, 70%);
  --scrollbar-track: hsl(43, 44%, 92%);
  
  color-scheme: light dark;
}

/* Dark mode theme overrides (Stage mode) */
[data-theme="dark"] {
  --bg-primary: hsl(0, 0%, 7%);
  --bg-secondary: hsl(0, 0%, 12%);
  --text-primary: hsl(38, 38%, 91%);
  --text-secondary: hsl(38, 14%, 65%);
  --accent-gold: hsl(46, 65%, 52%);
  --accent-gold-hover: hsl(46, 75%, 60%);
  --accent-gold-glow: hsla(46, 65%, 52%, 0.35);
  --border-color: hsla(38, 38%, 91%, 0.08);
  
  --glass-bg: hsla(0, 0%, 7%, 0.75);
  --glass-border: hsla(38, 38%, 91%, 0.05);
  --shadow-color: hsla(0, 0%, 0%, 0.5);

  --color-success: hsl(120, 60%, 50%);
  --color-danger: hsl(0, 85%, 55%);
  --color-warning: hsl(38, 95%, 50%);

  --scrollbar-thumb: hsl(0, 0%, 25%);
  --scrollbar-track: hsl(0, 0%, 10%);
}

/* Base resets & styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.25;
  color: var(--text-primary);
}

p {
  color: var(--text-secondary);
}

a {
  color: var(--accent-gold);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--accent-gold-hover);
}

/* Scrollbar styling */
@supports (scrollbar-color: auto) {
  * {
    scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
    scrollbar-width: thin;
  }
}

@supports not (scrollbar-color: auto) {
  *::-webkit-scrollbar {
    width: 8px;
    height: 8px;
  }
  *::-webkit-scrollbar-thumb {
    background-color: var(--scrollbar-thumb);
    border-radius: 4px;
  }
  *::-webkit-scrollbar-track {
    background-color: var(--scrollbar-track);
  }
}

/* Utility layout classes */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.6rem;
  border-radius: 30px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
}

.btn-sm {
  padding: 0.5rem 1.2rem;
  font-size: 0.85rem;
}

.btn-gold {
  background-color: var(--accent-gold);
  color: #fff !important;
  box-shadow: 0 4px 14px var(--accent-gold-glow);
}

.btn-gold:hover {
  background-color: var(--accent-gold-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--accent-gold-glow);
}

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

.btn-outline {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
}

.btn-outline:hover {
  background-color: var(--bg-secondary);
  border-color: var(--accent-gold);
  transform: translateY(-2px);
}

.section-header {
  margin-bottom: 4rem;
}

.section-header h2 {
  font-size: 2.8rem;
  margin-bottom: 1rem;
  letter-spacing: -0.5px;
}

.section-lead {
  font-size: 1.2rem;
  max-width: 600px;
  margin: 0 auto;
}

/* Header Navigation Bar */
.main-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: var(--glass-bg);
  border-bottom: 1px solid var(--glass-border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: background-color var(--transition-normal), border-color var(--transition-normal);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.logo-wrapper {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
}

.logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform var(--transition-slow), filter var(--transition-normal);
}

/* The brand mark is a dark navy line-art book; invert it in Stage (dark)
   mode so it reads as a warm cream against the near-black header. */
[data-theme="dark"] .logo-img {
  filter: invert(1) brightness(1.08) sepia(0.18) saturate(1.1) hue-rotate(2deg);
}

.logo-area:hover .logo-img {
  transform: rotate(-10deg) scale(1.08);
}

.logo-text {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0px;
  color: var(--text-primary);
  line-height: 1;
}

.main-nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.main-nav a {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.main-nav a:hover {
  color: var(--accent-gold);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Mobile hamburger toggle (hidden on desktop) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0 9px;
  background: none;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  cursor: pointer;
  transition: background-color var(--transition-fast);
}

.nav-toggle:hover {
  background-color: var(--bg-secondary);
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background-color: var(--text-primary);
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.main-header.nav-open .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.main-header.nav-open .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}
.main-header.nav-open .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Theme Toggle Button */
.theme-toggle-btn {
  background: none;
  border: 1px solid var(--border-color);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-primary);
  transition: all var(--transition-fast);
}

.theme-toggle-btn:hover {
  background-color: var(--bg-secondary);
  transform: scale(1.05);
}

.sun-icon {
  width: 20px;
  height: 20px;
  display: none;
}

.moon-icon {
  width: 18px;
  height: 18px;
  display: block;
}

[data-theme="dark"] .sun-icon {
  display: block;
}

[data-theme="dark"] .moon-icon {
  display: none;
}

/* Hero Section */
.hero-section {
  padding-top: 140px;
  padding-bottom: 80px;
  position: relative;
  overflow: hidden;
}

.hero-bg-accent {
  position: absolute;
  top: -200px;
  right: -200px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-gold-glow) 0%, transparent 70%);
  z-index: 0;
  pointer-events: none;
}

.hero-container {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 4rem;
}

.hero-content {
  max-width: 580px;
}

.hero-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--accent-gold);
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: 3.8rem;
  line-height: 1.15;
  letter-spacing: -1.5px;
  margin-bottom: 1.5rem;
}

.hero-lead {
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  line-height: 1.5;
}

.hero-cta-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Store Badge Buttons */
.store-btn {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background-color: #1a1a1a;
  border: 1px solid #333;
  color: #fff !important;
  padding: 0.6rem 1.4rem;
  border-radius: 10px;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.store-btn:hover {
  background-color: #000;
  transform: translateY(-3px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
}

.store-icon svg {
  width: 24px;
  height: 24px;
}

.store-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.store-sub {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.7;
}

.store-main {
  font-size: 1.05rem;
  font-weight: 600;
}

/* iPad-style frame for hero screenshot */
.ipad-frame-hero {
  border-radius: 22px;
  background-color: #1a1a1e;
  border: 6px solid #2d2d33;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.06),
    0 20px 60px rgba(0,0,0,0.4),
    0 8px 20px rgba(0,0,0,0.3);
  padding: 10px;
  position: relative;
  overflow: hidden;
}

.ipad-frame-hero::before {
  content: '';
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #0d0d10;
  z-index: 2;
}

.hero-screenshot-img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  display: block;
}

/* Hero Visual stack with gently floating mockups */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.visual-stack {
  position: relative;
  width: 100%;
  max-width: 440px;
  height: 440px;
}

.app-mockup-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 85%;
  z-index: 2;
  animation: floatApp 6s ease-in-out infinite;
}

.pedal-mockup-wrapper {
  position: absolute;
  bottom: -4%;
  right: -6%;
  width: 42%;
  max-width: 160px;
  z-index: 3;
  filter: drop-shadow(0 16px 26px rgba(0, 0, 0, 0.35));
  animation: floatPedal 6s ease-in-out infinite;
  animation-delay: 1s;
}

.pedal-mockup-wrapper .pedal-device-sm {
  max-width: 100%;
}

.mockup-img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 10px 30px var(--shadow-color);
  border: 1px solid var(--glass-border);
}

@keyframes floatApp {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-12px) rotate(1deg); }
}

@keyframes floatPedal {
  0%, 100% { transform: translateY(0) rotate(1deg); }
  50% { transform: translateY(-8px) rotate(-1deg); }
}

/* Problem & Solution Section */
.problem-solution-section {
  padding: 100px 0;
  background-color: var(--bg-secondary);
}

.comparison-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-top: 2rem;
}

.comparison-card {
  background-color: var(--bg-primary);
  border-radius: 20px;
  padding: 3rem;
  border: 1px solid var(--border-color);
  box-shadow: 0 10px 30px var(--shadow-color);
  position: relative;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.comparison-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px var(--shadow-color);
}

.card-badge {
  position: absolute;
  top: -16px;
  left: 3rem;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-problem {
  background-color: hsla(0, 75%, 45%, 0.1);
  color: var(--color-danger);
  border: 1px solid hsla(0, 75%, 45%, 0.2);
}

.badge-solution {
  background-color: hsla(46, 65%, 52%, 0.1);
  color: var(--accent-gold);
  border: 1px solid hsla(46, 65%, 52%, 0.25);
}

.comparison-card h3 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  margin-top: 0.5rem;
}

.comparison-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.8rem;
}

.comparison-list li {
  display: flex;
  gap: 1.2rem;
  align-items: flex-start;
}

.list-icon-wrapper {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-weight: bold;
  font-size: 0.9rem;
}

.list-icon-wrapper.red {
  background-color: hsla(0, 75%, 45%, 0.1);
  color: var(--color-danger);
}

.list-icon-wrapper.green {
  background-color: hsla(120, 45%, 38%, 0.1);
  color: var(--color-success);
}

[data-theme="dark"] .list-icon-wrapper.green {
  background-color: hsla(120, 60%, 50%, 0.15);
}

.comparison-list p {
  font-size: 1.05rem;
  line-height: 1.4;
}

/* Key Features Section */
.features-section {
  padding: 100px 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.feature-card {
  background-color: var(--bg-secondary);
  border-radius: 20px;
  padding: 2.5rem;
  border: 1px solid var(--border-color);
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
}

.feature-card:hover {
  background-color: var(--bg-primary);
  transform: translateY(-5px);
  box-shadow: 0 12px 30px var(--shadow-color);
  border-color: var(--accent-gold);
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background-color: var(--accent-gold-glow);
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.8rem;
  transition: transform var(--transition-slow);
}

.feature-card:hover .feature-icon {
  transform: scale(1.1) rotate(5deg);
}

.feature-icon svg {
  width: 26px;
  height: 26px;
}

.feature-card h3 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.feature-card p {
  font-size: 0.95rem;
  line-height: 1.5;
}

/* Interactive Simulator Section */
.simulator-section {
  padding: 100px 0;
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.simulator-layout {
  display: grid;
  grid-template-columns: minmax(300px, 420px) 1fr;
  gap: 4.5rem;
  align-items: center;
}

/* Tablet Frame Mockup — held upright (portrait), matching the app's
   real page layout so the sheet music fills the screen edge to edge. */
.tablet-simulator-frame {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
}

.tablet-bezel {
  background-color: #1e1e20;
  border: 4px solid #333336;
  border-radius: 30px;
  padding: 16px;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.05),
    0 30px 60px rgba(0, 0, 0, 0.45);
  position: relative;
  aspect-ratio: 3 / 4;
}

.tablet-camera {
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #0c0c0e;
  box-shadow: inset 0 0 2px rgba(255, 255, 255, 0.2);
}

.tablet-screen {
  background-color: #faf6eb; /* parchment default */
  width: 100%;
  height: 100%;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  user-select: none;
  transition: background-color var(--transition-normal);
}

/* Tablet screen inside theme override */
[data-tablet-theme="dark"] .tablet-screen {
  background-color: #0c0c0e;
}

/* App Bar inside Tablet */
.app-bar {
  background-color: #2b1f11;
  color: #ebdcb9;
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
  padding: 0.4rem 0.9rem;
  font-size: 0.8rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

[data-tablet-theme="dark"] .app-bar {
  background-color: #18181c;
  color: #b3a58e;
  border-bottom: 1px solid rgba(255,255,255,0.02);
}

.app-bar-title {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 0.85rem;
}

.app-bar-controls {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.sim-page-indicator {
  opacity: 0.8;
}

.sim-app-theme-btn {
  background-color: rgba(255,255,255,0.1);
  border: none;
  color: inherit;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  cursor: pointer;
  transition: background-color var(--transition-fast);
}

.sim-app-theme-btn:hover {
  background-color: rgba(255,255,255,0.2);
}

.sim-ble-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  background-color: rgba(255,255,255,0.05);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.ble-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--color-success);
}

.ble-dot.active {
  animation: pulseBleDot 1.5s infinite;
}

@keyframes pulseBleDot {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.3); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}

.ble-battery-pct {
  font-size: 0.7rem;
  font-weight: 500;
  opacity: 0.8;
}

/* Page Viewer Inside Tablet */
.sheet-music-container {
  flex: 1;
  position: relative;
  overflow: hidden;
}

.sheet-page {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 1.5rem;
  transition: transform 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  background-color: transparent;
}

.sheet-page.active {
  transform: translateX(0);
}

.sheet-page.prev-out {
  transform: translateX(-100%);
}

.sheet-page.next {
  transform: translateX(100%);
}

/* Real PDF page image inside the simulator */
.sheet-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  border-radius: 4px;
  background-color: #fff;
}

/* Stage Dark mode inverts the score (white notes on black), like the app */
[data-tablet-theme="dark"] .sheet-img {
  filter: invert(1) hue-rotate(180deg);
}

/* Annotation Canvas Layer */
.annotation-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
  cursor: crosshair;
}

/* Brush controls overlay inside tablet */
.canvas-controls {
  background-color: #2b1f11;
  color: #ebdcb9;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 0.8rem;
  padding: 0.5rem 0.9rem;
  z-index: 20;
  border-top: 1px solid rgba(255,255,255,0.05);
}

[data-tablet-theme="dark"] .canvas-controls {
  background-color: #18181c;
  color: #b3a58e;
  border-top: 1px solid rgba(255,255,255,0.02);
}

.control-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.tool-btn {
  background: none;
  border: 1px solid rgba(255,255,255,0.15);
  color: inherit;
  font-size: 0.75rem;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all var(--transition-fast);
}

.tool-btn:hover {
  background-color: rgba(255,255,255,0.1);
}

.tool-btn.active {
  background-color: var(--accent-gold);
  border-color: var(--accent-gold);
  color: #fff;
}

.tool-btn.danger:hover {
  background-color: var(--color-danger);
  border-color: var(--color-danger);
  color: #fff;
}

.color-picker {
  display: flex;
  gap: 6px;
}

.color-btn {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.color-btn:hover {
  transform: scale(1.15);
}

.color-btn.active {
  border-color: #fff;
  transform: scale(1.15);
}

.stroke-select {
  background-color: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  color: inherit;
  font-size: 0.7rem;
  padding: 0.25rem;
  border-radius: 4px;
  cursor: pointer;
  outline: none;
}

/* Right Side: Simulator Panel & Pedal Simulator Widget */
.simulator-panel h3 {
  font-size: 2.2rem;
  margin-bottom: 1.2rem;
}

.instructions-list {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  margin: 1.8rem 0;
}

.instruction-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.step-num {
  background-color: var(--accent-gold-glow);
  color: var(--accent-gold);
  font-weight: bold;
  font-size: 0.9rem;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.instruction-item p {
  font-size: 0.95rem;
  line-height: 1.4;
}

/* Stompbox Pedal Widget */
.pedal-widget {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 8px 25px var(--shadow-color);
  margin-top: 2rem;
}

.pedal-widget-title {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-secondary);
  margin-bottom: 1.2rem;
  text-align: center;
}

.pedal-hardware-box {
  background-color: #2b2b2f;
  border-radius: 12px;
  padding: 2rem 1.5rem 1.5rem;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 280px;
  margin: 0 auto;
  box-shadow: inset 0 2px 5px rgba(0,0,0,0.5), 0 5px 15px rgba(0,0,0,0.3);
  border: 1px solid #1a1a1c;
}

/* Stompbox status LED indicator */
.pedal-led-indicator {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background-color: #111;
  border: 2px solid #555;
  margin-bottom: 2rem;
  transition: all var(--transition-normal);
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.8);
}

/* LED glow states for simulated widget */
.pedal-led-indicator.led-advertising {
  background-color: #3b82f6;
  border-color: #93c5fd;
  box-shadow: 0 0 12px #3b82f6, inset 0 1px 2px rgba(255,255,255,0.5);
  animation: breathingBlue 2s infinite;
}

.pedal-led-indicator.led-connected {
  background-color: #22c55e;
  border-color: #86efac;
  box-shadow: 0 0 12px #22c55e, inset 0 1px 2px rgba(255,255,255,0.5);
}

.pedal-led-indicator.led-press {
  background-color: #ffffff;
  border-color: #e5e5e5;
  box-shadow: 0 0 16px #ffffff, inset 0 1px 2px rgba(255,255,255,0.8);
}

.pedal-led-indicator.led-warning {
  background-color: #f97316;
  border-color: #fdba74;
  box-shadow: 0 0 10px #f97316, inset 0 1px 2px rgba(255,255,255,0.5);
  animation: blinkOrange 1s infinite;
}

.pedal-led-indicator.led-critical {
  background-color: #ef4444;
  border-color: #fca5a5;
  box-shadow: 0 0 10px #ef4444, inset 0 1px 2px rgba(255,255,255,0.5);
  animation: blinkRed 0.5s infinite;
}

.pedal-led-indicator.led-ota {
  background-color: #a855f7;
  border-color: #d8b4fe;
  box-shadow: 0 0 12px #a855f7, inset 0 1px 2px rgba(255,255,255,0.5);
  animation: breathingPurple 1s infinite;
}

@keyframes breathingBlue {
  0%, 100% { opacity: 0.2; box-shadow: 0 0 2px #3b82f6; }
  50% { opacity: 1; box-shadow: 0 0 14px #3b82f6; }
}

@keyframes breathingPurple {
  0%, 100% { opacity: 0.3; box-shadow: 0 0 3px #a855f7; }
  50% { opacity: 1; box-shadow: 0 0 14px #a855f7; }
}

@keyframes blinkOrange {
  0%, 49% { background-color: #111; border-color: #555; box-shadow: none; }
  50%, 100% { background-color: #f97316; border-color: #fdba74; box-shadow: 0 0 10px #f97316; }
}

@keyframes blinkRed {
  0%, 49% { background-color: #111; border-color: #555; box-shadow: none; }
  50%, 100% { background-color: #ef4444; border-color: #fca5a5; box-shadow: 0 0 10px #ef4444; }
}

/* Dual stomp switches */
.pedal-switches-row {
  display: flex;
  justify-content: space-between;
  width: 100%;
  gap: 1.5rem;
}

.foot-switch-btn {
  flex: 1;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  outline: none;
}

.metal-switch {
  width: 44px;
  height: 44px;
  background: radial-gradient(circle, #dedede 0%, #8c8c90 70%, #555 100%);
  border-radius: 50%;
  border: 4px solid #1a1a1c;
  box-shadow: 0 4px 8px rgba(0,0,0,0.5), inset 0 2px 4px rgba(255,255,255,0.4);
  position: relative;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.metal-switch::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f5f5f5 0%, #aaaaaa 100%);
  box-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.foot-switch-btn:active .metal-switch {
  transform: scale(0.9) translateY(2px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.6), inset 0 1px 2px rgba(0,0,0,0.4);
}

.switch-label {
  margin-top: 0.8rem;
  font-family: var(--font-sans);
  color: #a3a3ac;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.3;
}

.switch-label small {
  color: #6b6b76;
}

.pedal-keyboard-cue {
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-align: center;
  margin-top: 1rem;
  opacity: 0.8;
}

/* Hardware / Pedal Specs Section */
.hardware-section {
  padding: 100px 0;
}

.hardware-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4.5rem;
  align-items: center;
}

.hardware-interactive {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.hardware-mockup-container {
  position: relative;
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
  padding: 0.5rem 0;
}

/* ==========================================================
   Reusable CSS foot-pedal device (replaces photo mockups)
   ========================================================== */
.pedal-device {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  margin: 0 auto;
  border-radius: 26px;
  background:
    /* four recessed corner screws (metallic head + dark well) */
    radial-gradient(circle 8px at 18px 18px, #c2c2c8 0%, #83838a 30%, #3a3a40 58%, #0b0b0d 78%, transparent 100%),
    radial-gradient(circle 8px at calc(100% - 18px) 18px, #c2c2c8 0%, #83838a 30%, #3a3a40 58%, #0b0b0d 78%, transparent 100%),
    radial-gradient(circle 8px at 18px calc(100% - 18px), #c2c2c8 0%, #83838a 30%, #3a3a40 58%, #0b0b0d 78%, transparent 100%),
    radial-gradient(circle 8px at calc(100% - 18px) calc(100% - 18px), #c2c2c8 0%, #83838a 30%, #3a3a40 58%, #0b0b0d 78%, transparent 100%),
    /* top light sheen */
    radial-gradient(150% 95% at 50% -20%, rgba(255, 255, 255, 0.17), transparent 55%),
    /* fine brushed-metal grain */
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.028) 0 1px, rgba(0, 0, 0, 0.05) 1px 3px),
    /* anodized body */
    linear-gradient(163deg, #3d3d44 0%, #2a2a30 30%, #1f1f24 62%, #131316 100%);
  border: 1px solid #0a0a0c;
  box-shadow:
    0 34px 60px rgba(0, 0, 0, 0.52),
    0 8px 18px rgba(0, 0, 0, 0.42),
    inset 0 2px 2px rgba(255, 255, 255, 0.16),
    inset 0 -8px 20px rgba(0, 0, 0, 0.64),
    inset 0 0 0 1px rgba(255, 255, 255, 0.035);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.7rem 1.2rem;
}

/* beveled top face — subtle inner plate that catches light */
.pedal-device::before {
  content: '';
  position: absolute;
  inset: 8px;
  border-radius: 20px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), transparent 22%, transparent 78%, rgba(0, 0, 0, 0.25));
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.09);
}

.pedal-brand {
  font-family: var(--font-serif);
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--accent-gold);
  font-size: 1rem;
  margin-top: 0.3rem;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}

.pedal-led-housing {
  position: relative;
  width: 22px;
  height: 22px;
  margin: 1.1rem 0 auto;
  border-radius: 50%;
  /* recessed lens well inside a chrome bezel */
  background: radial-gradient(circle at 50% 42%, #101012, #060608 75%);
  box-shadow:
    inset 0 3px 5px rgba(0, 0, 0, 0.95),
    inset 0 -1px 2px rgba(255, 255, 255, 0.05),
    0 0 0 2px #0c0c0e,
    0 0 0 3px rgba(160, 160, 168, 0.35),
    0 1px 2px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pedal-switches {
  display: flex;
  gap: 1.4rem;
  margin: auto 0 1.1rem;
}

.pedal-switch {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  /* chrome-plated switch body with off-axis highlight */
  background:
    radial-gradient(circle at 42% 26%, #ffffff 0%, #dfdfe4 22%, #a8a8af 48%, #6a6a71 72%, #3a3a40 90%, #1c1c20 100%);
  border: 2px solid #0d0d0f;
  box-shadow:
    0 10px 18px rgba(0, 0, 0, 0.62),
    0 3px 6px rgba(0, 0, 0, 0.5),
    inset 0 3px 6px rgba(255, 255, 255, 0.65),
    inset 0 -4px 8px rgba(0, 0, 0, 0.55),
    /* mounting collar / hex nut ring around the switch */
    0 0 0 5px #17171a,
    0 0 0 6px rgba(255, 255, 255, 0.06),
    0 0 0 7px rgba(0, 0, 0, 0.5);
  position: relative;
}
.pedal-switch::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  /* raised domed cap */
  background: radial-gradient(circle at 44% 30%, #ffffff 0%, #e2e2e7 38%, #adadb4 70%, #7c7c83 100%);
  box-shadow:
    inset 0 2px 3px rgba(255, 255, 255, 0.9),
    inset 0 -2px 4px rgba(0, 0, 0, 0.45),
    0 2px 4px rgba(0, 0, 0, 0.45);
}

.pedal-port {
  font-family: var(--font-sans);
  font-size: 0.6rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #8a8a93;
  padding: 0.22rem 0.65rem;
  border-radius: 4px;
  /* engraved recessed port plate */
  background: linear-gradient(180deg, #0e0e10, #17171a);
  box-shadow:
    inset 0 2px 3px rgba(0, 0, 0, 0.85),
    inset 0 -1px 1px rgba(255, 255, 255, 0.05),
    0 1px 0 rgba(255, 255, 255, 0.04);
  text-shadow: 0 -1px 1px rgba(0, 0, 0, 0.8);
}

/* Small variant — floating pedal in the hero visual stack */
.pedal-device-sm {
  max-width: 200px;
  padding: 1.1rem 0.9rem;
  border-radius: 18px;
}
.pedal-device-sm .pedal-brand { font-size: 0.72rem; }
.pedal-device-sm .pedal-led-housing { width: 16px; height: 16px; margin: 0.7rem 0 auto; }
.pedal-device-sm .pedal-switch {
  width: 40px;
  height: 40px;
  border-width: 2px;
  box-shadow:
    0 7px 12px rgba(0, 0, 0, 0.6),
    inset 0 2px 4px rgba(255, 255, 255, 0.6),
    inset 0 -3px 6px rgba(0, 0, 0, 0.5),
    0 0 0 3px #17171a,
    0 0 0 4px rgba(0, 0, 0, 0.5);
}
.pedal-device-sm .pedal-switch::after { width: 20px; height: 20px; }
.pedal-device-sm .pedal-switches { gap: 1rem; }

/* Large variant — hardware section, hosts the interactive LED spot */
.pedal-device-lg { max-width: 300px; }

/* Steady breathing LED for the static hero pedal */
.pedal-led-static {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: #22c55e;
  box-shadow: 0 0 10px #22c55e, inset 0 1px 1px rgba(255, 255, 255, 0.6);
  animation: breathingGreen 2.5s ease-in-out infinite;
}

@keyframes breathingGreen {
  0%, 100% { opacity: 0.55; box-shadow: 0 0 4px #22c55e; }
  50% { opacity: 1; box-shadow: 0 0 12px #22c55e; }
}

/* Interactive LED spot — centered inside the pedal's LED housing */
.glow-led-spot {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: transparent;
  pointer-events: none;
  transition: all var(--transition-normal);
}

/* Glow classes for the photo LED hotspot */
.glow-led-spot.active-blue {
  background-color: #60a5fa;
  box-shadow: 0 0 18px 6px #3b82f6;
  animation: breathingBlue 2s infinite;
}
.glow-led-spot.active-green {
  background-color: #4ade80;
  box-shadow: 0 0 18px 6px #22c55e;
}
.glow-led-spot.active-white {
  background-color: #ffffff;
  box-shadow: 0 0 24px 8px #ffffff;
}
.glow-led-spot.active-orange {
  background-color: #fb923c;
  box-shadow: 0 0 14px 4px #f97316;
  animation: blinkOrange 1s infinite;
}
.glow-led-spot.active-red {
  background-color: #f87171;
  box-shadow: 0 0 16px 6px #ef4444;
  animation: blinkRed 0.5s infinite;
}
.glow-led-spot.active-purple {
  background-color: #c084fc;
  box-shadow: 0 0 18px 6px #a855f7;
  animation: breathingPurple 1s infinite;
}

/* LED guide selectors styling */
.led-state-selector-card {
  background-color: var(--bg-secondary);
  border-radius: 16px;
  padding: 2rem;
  border: 1px solid var(--border-color);
  box-shadow: 0 8px 25px var(--shadow-color);
}

.led-state-selector-card h4 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}

.led-state-selector-card p {
  font-size: 0.9rem;
  margin-bottom: 1.2rem;
}

.led-states-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.led-state-btn {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.6rem 0.8rem;
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all var(--transition-fast);
  text-align: left;
}

.led-state-btn:hover {
  background-color: var(--bg-secondary);
  border-color: var(--accent-gold);
}

.led-state-btn.active {
  background-color: var(--accent-gold-glow);
  border-color: var(--accent-gold);
}

.color-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.color-dot.blue { background-color: #3b82f6; }
.color-dot.green { background-color: #22c55e; }
.color-dot.white { background-color: #fff; border: 0.5px solid #aaa; }
.color-dot.orange { background-color: #f97316; }
.color-dot.red { background-color: #ef4444; }
.color-dot.purple { background-color: #a855f7; }

.state-behavior-description {
  font-size: 0.9rem;
  background-color: var(--bg-primary);
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  min-height: 64px;
}

/* Specs Accordion list */
.hardware-details-panel h3 {
  font-size: 2.2rem;
  margin-bottom: 1.2rem;
}

.specs-accordion {
  display: flex;
  flex-direction: column;
  margin: 2rem 0;
  border-top: 1px solid var(--border-color);
}

.spec-row {
  display: flex;
  justify-content: space-between;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.95rem;
}

.spec-label {
  font-weight: 600;
  color: var(--text-primary);
}

.spec-value {
  color: var(--text-secondary);
  text-align: right;
  max-width: 60%;
}

/* FAQ Accordion Section */
.faq-section {
  padding: 100px 0;
}

.faq-accordion-container {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border-color);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 1.8rem 0.5rem;
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-question:hover {
  color: var(--accent-gold);
}

.faq-toggle-icon {
  font-family: var(--font-sans);
  font-size: 1.4rem;
  transition: transform var(--transition-normal);
  color: var(--accent-gold);
  font-weight: 300;
}

.faq-item.active .faq-toggle-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease-out, padding 0.35s ease-out;
  padding: 0 0.5rem;
}

.faq-item.active .faq-answer {
  padding-bottom: 1.8rem;
}

.faq-answer p {
  font-size: 0.98rem;
  line-height: 1.6;
}

/* Footer Section */
.main-footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 5rem 0 2rem;
}

.footer-container {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

.footer-brand .logo-area {
  margin-bottom: 1.2rem;
}

.brand-desc {
  font-size: 0.9rem;
  line-height: 1.5;
  max-width: 280px;
}

.footer-links h4 {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--accent-gold);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 2rem;
}

.footer-bottom p {
  font-size: 0.8rem;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 3rem;
    text-align: center;
  }
  .hero-content {
    max-width: 100%;
    margin: 0 auto;
  }
  .hero-cta-group {
    justify-content: center;
  }
  .hero-visual {
    margin-top: 2rem;
  }
  
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .simulator-layout {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .tablet-simulator-frame {
    max-width: 400px;
  }
  
  .hardware-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .hardware-interactive {
    max-width: 480px;
    margin: 0 auto;
    width: 100%;
  }
  
  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2.3rem;
  }
  .hero-lead {
    font-size: 1.1rem;
  }

  /* Collapse the primary nav into a hamburger dropdown */
  .nav-toggle {
    display: flex;
  }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: var(--bg-primary);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 14px 30px var(--shadow-color);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity var(--transition-fast), transform var(--transition-fast), visibility var(--transition-fast);
  }
  .main-header.nav-open .main-nav {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
  .main-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 0.5rem 1.75rem 1.25rem;
  }
  .main-nav li {
    border-bottom: 1px solid var(--border-color);
  }
  .main-nav li:last-child {
    border-bottom: none;
  }
  .main-nav a {
    display: block;
    padding: 0.95rem 0.25rem;
    font-size: 1.05rem;
  }

  .comparison-grid {
    grid-template-columns: 1fr;
  }
  .features-grid {
    grid-template-columns: 1fr;
  }
  .led-states-buttons {
    grid-template-columns: 1fr;
  }
  .footer-container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .visual-stack {
    max-width: 100%;
    height: auto;
    aspect-ratio: 1/1;
  }
  .tablet-bezel {
    padding: 10px;
    border-width: 2px;
  }
  .app-bar {
    height: auto;
    min-height: 42px;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0.5rem;
    gap: 0.5rem;
  }
  .canvas-controls {
    height: auto;
    min-height: 48px;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0.5rem;
    gap: 0.5rem;
  }
}

@media (max-width: 480px) {
  .section-header h2 {
    font-size: 1.8rem;
  }
  .hero-section {
    padding-top: 100px;
    padding-bottom: 50px;
  }
  .header-container {
    padding: 0 1rem;
  }
  .header-actions {
    gap: 0.6rem;
  }
  /* Header CTA is redundant on phones — the hero store badges cover it */
  .download-nav-btn {
    display: none;
  }
  .container {
    padding: 0 1rem;
  }
  .pedal-hardware-box {
    padding: 1.5rem 1rem 1rem;
  }
  .pedal-switches-row {
    gap: 0.5rem;
  }
  .metal-switch {
    width: 36px;
    height: 36px;
  }
  .metal-switch::after {
    width: 18px;
    height: 18px;
  }
}
