/* ==========================================================================
   DIVA VIRTUAL ANALOGUE SYNTHESIZER - DESIGN SYSTEM & HARDWARE STYLING
   ========================================================================== */

:root {
  /* Chassis & Metal Textures */
  --chassis-bg: #15181b;
  --chassis-metal: #202429;
  --panel-metal-dark: #1b1e22;
  --panel-metal-mid: #252a30;
  --panel-metal-light: #323842;
  --panel-border: #3b424d;
  --panel-bevel-light: rgba(255, 255, 255, 0.08);
  --panel-bevel-dark: rgba(0, 0, 0, 0.7);

  /* Walnut Wood Cheek Finishes */
  --wood-grain-dark: #2a1508;
  --wood-grain-mid: #4a2813;
  --wood-grain-light: #6a3d1f;
  --wood-border: #1a0c04;

  /* Vintage Analogue Display & LED Colors */
  --led-amber: #ff9d00;
  --led-amber-glow: rgba(255, 157, 0, 0.4);
  --led-green: #39e75f;
  --led-green-glow: rgba(57, 231, 95, 0.4);
  --led-red: #ff3344;
  --led-red-glow: rgba(255, 51, 68, 0.5);
  --led-blue: #00d4ff;
  --led-blue-glow: rgba(0, 212, 255, 0.4);

  /* Typography Colors */
  --text-main: #dce1e8;
  --text-dim: #8b95a5;
  --text-bright: #ffffff;
  --text-gold: #e2ba6a;
  --text-accent: #ffb833;

  /* Knobs & Hardware Controls */
  --knob-cap: #1b1d20;
  --knob-rim: #3f4550;
  --knob-indicator: #ff9d00;
  --knob-ring: #2a2f38;
  --knob-ring-fill: #ff9d00;

  /* Font Families */
  --font-display: 'Chakra Petch', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --font-ui: 'Outfit', sans-serif;

  /* Layout Constants */
  --border-radius-sm: 3px;
  --border-radius-md: 5px;
  --border-radius-lg: 8px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
}

body {
  background-color: #0b0d0f;
  color: var(--text-main);
  font-family: var(--font-ui);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 12px;
  background-image: 
    radial-gradient(ellipse at 50% 10%, rgba(45, 55, 72, 0.25) 0%, transparent 70%),
    linear-gradient(180deg, #0d0f12 0%, #060708 100%);
  overflow-x: auto;
}

/* ==========================================================================
   HARDWARE SYNTH WRAPPER & WOOD CHEEKS
   ========================================================================== */

.synth-wrapper {
  position: relative;
  width: 100%;
  max-width: 1380px;
  min-width: 1100px;
  background: var(--chassis-bg);
  border-radius: var(--border-radius-lg);
  box-shadow: 
    0 25px 50px -12px rgba(0, 0, 0, 0.85),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  border: 1px solid #1c2026;
  margin: 0 auto;
}

.wood-cheek {
  width: 24px;
  background: linear-gradient(90deg, 
    var(--wood-grain-dark) 0%, 
    var(--wood-grain-mid) 40%, 
    var(--wood-grain-light) 65%, 
    var(--wood-grain-dark) 100%);
  box-shadow: 
    inset 0 0 10px rgba(0,0,0,0.6),
    inset 1px 0 0 rgba(255,255,255,0.1);
  flex-shrink: 0;
}

.wood-left {
  border-top-left-radius: var(--border-radius-lg);
  border-right: 2px solid var(--wood-border);
}
.wood-right {
  border-top-right-radius: var(--border-radius-lg);
  border-left: 2px solid var(--wood-border);
}

.wood-left-body {
  border-right: 2px solid var(--wood-border);
}
.wood-right-body {
  border-left: 2px solid var(--wood-border);
}

.wood-left-footer {
  border-bottom-left-radius: var(--border-radius-lg);
  border-right: 2px solid var(--wood-border);
}
.wood-right-footer {
  border-bottom-right-radius: var(--border-radius-lg);
  border-left: 2px solid var(--wood-border);
}

/* ==========================================================================
   UNIFIED MASTER STUDIO HEADER & TRANSPORT
   ========================================================================== */

.synth-header.studio-master-header {
  display: flex;
  background: linear-gradient(180deg, #202630 0%, #12151b 100%);
  border-bottom: 2px solid #0a0c0f;
  border-top-left-radius: var(--border-radius-lg);
  border-top-right-radius: var(--border-radius-lg);
  box-shadow: 0 4px 16px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.unified-header-grid {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 14px;
  gap: 16px;
}

.header-section {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-view-section {
  gap: 12px;
}

.brand-view-section .brand-badge {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.brand-view-section .brand-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 3px;
  color: #fff;
  text-shadow: 0 0 10px rgba(255, 170, 0, 0.4);
}

.brand-view-section .brand-sub {
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 1.5px;
  color: var(--text-gold);
  font-weight: 700;
}

.transport-center-section {
  background: #090c10;
  padding: 4px 10px;
  border-radius: 4px;
  border: 1px solid #1c2430;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.7);
  gap: 8px;
}

.daw-transport-controls {
  display: flex;
  align-items: center;
  gap: 3px;
}

.preset-system-section {
  display: flex;
  align-items: center;
  gap: 8px;
}

.quick-history {
  display: flex;
  gap: 2px;
}

.action-btn.mini-icon {
  padding: 4px 6px;
  font-size: 11px;
  min-width: 26px;
}

/* File / Tools Dropdown */
.dropdown-wrap {
  position: relative;
}

.menu-btn {
  font-size: 10px;
  font-weight: 700;
  padding: 4px 8px;
  background: #19202a;
  border-color: #2b3648;
}

.menu-dropdown-content {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  background: #14181f;
  border: 1px solid #2a3547;
  border-radius: 4px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.8);
  min-width: 180px;
  padding: 4px 0;
  z-index: 1000;
}

.menu-item {
  display: block;
  width: 100%;
  padding: 6px 12px;
  text-align: left;
  background: transparent;
  border: none;
  color: #cbd5e1;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.1s ease;
}

.menu-item:hover {
  background: #0284c7;
  color: #fff;
}

.menu-item.file-item {
  margin: 0;
}

.menu-divider {
  height: 1px;
  background: #252e3e;
  margin: 4px 0;
}

.icon-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  filter: grayscale(1);
}

.preset-category-tabs {
  display: flex;
  gap: 3px;
}

.cat-btn {
  background: #1e232a;
  border: 1px solid #323a46;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  padding: 3px 6px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cat-btn:hover {
  background: #2b3340;
  color: var(--text-main);
}

.cat-btn.active {
  background: #ff9d00;
  border-color: #ffb43a;
  color: #111;
  font-weight: 800;
  box-shadow: 0 0 8px rgba(255, 157, 0, 0.4);
}

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

.nav-btn {
  background: linear-gradient(180deg, #323945 0%, #1f232b 100%);
  border: 1px solid #434c5b;
  color: var(--text-main);
  font-size: 10px;
  width: 22px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.1s;
}

.nav-btn:hover {
  background: #404958;
  color: #fff;
}
.nav-btn:active {
  transform: scale(0.95);
}

.preset-lcd {
  background: #080d08;
  border: 1px solid #1c2a1c;
  padding: 4px 10px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 220px;
  cursor: pointer;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.8), 0 0 4px rgba(57, 231, 95, 0.15);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.preset-lcd:hover {
  border-color: #39e75f;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.8), 0 0 10px rgba(57, 231, 95, 0.35);
}

.lcd-num {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--led-green);
  opacity: 0.8;
}

.lcd-name {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: #4fff7f;
  letter-spacing: 0.5px;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 0 6px rgba(79, 255, 127, 0.4);
}

.lcd-category {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  color: #111;
  background: var(--led-amber);
  padding: 1px 4px;
  border-radius: 2px;
}

.lcd-arrow {
  font-size: 8px;
  color: #4fff7f;
  opacity: 0.6;
}

.preset-actions {
  display: flex;
  gap: 4px;
}

.action-btn {
  background: #20252d;
  border: 1px solid #384250;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  padding: 4px 7px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  gap: 4px;
}

.action-btn:hover {
  background: #2d3440;
  color: #fff;
  border-color: #4c596b;
}

.action-btn:active {
  transform: translateY(1px);
}

/* Header Right: Master, Record, MIDI, CPU Profiler */
.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dsp-profiler-badge {
  background: #0d1014;
  border: 1px solid #28303b;
  border-radius: 3px;
  padding: 3px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.cpu-led-bar {
  width: 24px;
  height: 6px;
  background: #191e26;
  border-radius: 2px;
  overflow: hidden;
  border: 1px solid #2c3542;
}

.cpu-led-fill {
  height: 100%;
  width: 15%;
  background: var(--led-green);
  transition: width 0.2s ease, background-color 0.2s;
}

.cpu-led-fill.warning {
  background: var(--led-amber);
}
.cpu-led-fill.danger {
  background: var(--led-red);
}

.cpu-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.1;
}

.cpu-text {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  color: #4fff7f;
}

.cpu-voices {
  font-family: var(--font-mono);
  font-size: 7px;
  color: var(--text-dim);
}

.midi-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #111317;
  padding: 4px 8px;
  border-radius: 3px;
  border: 1px solid #272d36;
}

.midi-led {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #333;
  transition: background-color 0.1s, box-shadow 0.1s;
}

.midi-led.active {
  background: var(--led-amber);
  box-shadow: 0 0 8px var(--led-amber-glow);
}

.midi-text {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--text-dim);
  font-weight: 600;
}

.record-group .rec-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #251214;
  border: 1px solid #631c21;
  color: #ff9ca3;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  padding: 5px 9px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.rec-btn .rec-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--led-red);
  box-shadow: 0 0 4px var(--led-red-glow);
}

.rec-btn.recording {
  background: #631016;
  color: #fff;
  border-color: #ff3344;
  animation: pulse-rec 1.2s infinite ease-in-out;
}

@keyframes pulse-rec {
  0%, 100% { box-shadow: 0 0 4px rgba(255, 51, 68, 0.4); }
  50% { box-shadow: 0 0 14px rgba(255, 51, 68, 0.9); }
}

.master-vol-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.master-vol-group .knob-title {
  font-family: var(--font-mono);
  font-size: 8px;
  color: var(--text-gold);
  font-weight: 700;
  letter-spacing: 1px;
}

/* ==========================================================================
   MAIN SYNTHESIS MATRIX & HARDWARE PANELS
   ========================================================================== */

.synth-body {
  display: flex;
  background: #181b1f;
}

.synth-panel-matrix {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 14px;
  background: linear-gradient(180deg, #1f2329 0%, #171a1e 100%);
}

.panel-row {
  display: flex;
  gap: 8px;
  width: 100%;
}

.synth-section {
  background: linear-gradient(180deg, #282d36 0%, #1e2229 100%);
  border: 1px solid var(--panel-border);
  border-radius: var(--border-radius-md);
  box-shadow: 
    inset 0 1px 0 var(--panel-bevel-light),
    0 4px 10px rgba(0, 0, 0, 0.4);
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  position: relative;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 5px;
  margin-bottom: 8px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--text-gold);
  text-shadow: 0 1px 2px rgba(0,0,0,0.8);
}

/* Proportions */
.section-osc { flex: 3.2; }
.section-filter { flex: 2.2; }
.section-voice { flex: 1.2; }

.section-envelopes { flex: 2.5; }
.section-lfos { flex: 2.1; }
.section-arp { flex: 2; }

.section-fx { flex: 4; }
.section-meters { flex: 2.6; }

/* Model Toggle Pills */
.model-selector-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.selector-label {
  font-family: var(--font-mono);
  font-size: 8px;
  color: var(--text-dim);
  font-weight: 600;
  letter-spacing: 1px;
}

.toggle-group {
  display: flex;
  background: #121519;
  padding: 2px;
  border-radius: 3px;
  border: 1px solid #2f3744;
  gap: 2px;
}

.toggle-pill {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.15s;
}

.toggle-pill:hover {
  color: var(--text-main);
}

.toggle-pill.active {
  background: #ff9d00;
  color: #111;
  box-shadow: 0 0 6px rgba(255, 157, 0, 0.4);
}

/* ==========================================================================
   OSCILLATOR SECTION STYLES
   ========================================================================== */

.osc-models-container {
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.osc-model-view {
  display: none;
  gap: 8px;
  width: 100%;
}

.osc-model-view.active {
  display: flex;
}

.sub-module {
  background: rgba(18, 21, 26, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  padding: 6px 8px;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-around;
  position: relative;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
}

.sub-module.full-width {
  width: 100%;
}

.sub-module-title {
  position: absolute;
  top: -6px;
  left: 10px;
  background: #252a32;
  border: 1px solid #373f4c;
  padding: 0 5px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  color: var(--text-dim);
  border-radius: 2px;
  letter-spacing: 0.8px;
}

.ctrl-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}

.ctrl-col.mini {
  gap: 2px;
}

.ctrl-label {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 600;
  color: var(--text-dim);
  letter-spacing: 0.5px;
  text-align: center;
  white-space: nowrap;
}

.ctrl-label.highlight {
  color: var(--text-gold);
  font-weight: 700;
}

.osc-footer-strip {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  margin-top: 6px;
  padding-top: 5px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ==========================================================================
   FILTER SECTION STYLES & INTERACTIVE CANVAS
   ========================================================================== */

.filter-controls-grid {
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: 6px;
  padding: 4px 0;
}

.filter-visualizer-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #111417;
  border: 1px solid #29303b;
  border-radius: 3px;
  padding: 3px 6px;
  margin-top: 4px;
  cursor: crosshair;
}

.filter-canvas-container {
  position: relative;
  height: 32px;
  width: 150px;
}

#filter-curve-canvas {
  height: 32px;
  width: 150px;
  display: block;
}

.filter-drag-overlay {
  position: absolute;
  bottom: 1px;
  right: 2px;
  font-family: var(--font-mono);
  font-size: 6px;
  color: rgba(255, 157, 0, 0.5);
  pointer-events: none;
  font-weight: 700;
}

.filter-badge {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: var(--led-amber);
  font-weight: 700;
  letter-spacing: 0.5px;
}

/* ==========================================================================
   VOICE & TUNING SECTION STYLES
   ========================================================================== */

.voice-controls-grid {
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: 4px;
  padding: 4px 0;
}

.voice-leds-panel {
  background: #111316;
  border: 1px solid #272e38;
  border-radius: 3px;
  padding: 4px 6px;
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.voice-led-title {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  color: var(--text-dim);
  letter-spacing: 1px;
}

.led-array {
  display: flex;
  justify-content: space-between;
  gap: 2px;
}

.voice-led {
  flex: 1;
  height: 16px;
  background: #1c2026;
  border: 1px solid #2e3540;
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 8px;
  color: #555e6d;
  font-weight: 700;
  transition: all 0.08s;
}

.voice-led.active {
  background: var(--led-green);
  color: #000;
  box-shadow: 0 0 8px var(--led-green-glow);
  border-color: #6eff8f;
}

/* ==========================================================================
   ENVELOPE GENERATORS (FADERS)
   ========================================================================== */

.envelopes-wrapper {
  display: flex;
  gap: 10px;
}

.envelope-unit {
  flex: 1;
  background: rgba(18, 21, 26, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.env-unit-header {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  color: var(--text-gold);
}

.env-curve-badge {
  color: var(--text-dim);
  font-size: 7.5px;
}

.sliders-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  height: 90px;
}

.slider-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  justify-content: flex-end;
  gap: 4px;
}

/* Fader Styling */
.fader-container {
  position: relative;
  width: 14px;
  height: 70px;
  cursor: pointer;
  display: flex;
  justify-content: center;
}

.fader-track {
  position: relative;
  width: 4px;
  height: 100%;
  background: #0d0f12;
  border-radius: 2px;
  border: 1px solid #313742;
  box-shadow: inset 0 0 4px rgba(0,0,0,0.8);
}

.fader-thumb {
  position: absolute;
  left: 50%;
  bottom: 50%;
  transform: translate(-50%, 50%);
  width: 16px;
  height: 12px;
  background: linear-gradient(180deg, #444c59 0%, #20242b 50%, #15181c 100%);
  border: 1px solid #5a6475;
  border-radius: 2px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.7), inset 0 1px 0 rgba(255,255,255,0.2);
}

.fader-thumb::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 2px;
  right: 2px;
  height: 1.5px;
  background: #ff9d00;
  box-shadow: 0 0 3px rgba(255, 157, 0, 0.8);
  transform: translateY(-50%);
}

/* ==========================================================================
   LFOs & ARPEGGIATOR STYLES
   ========================================================================== */

.lfos-wrapper {
  display: flex;
  gap: 8px;
}

.lfo-unit {
  flex: 1;
  background: rgba(18, 21, 26, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  padding: 6px 8px;
  position: relative;
}

.lfo-controls {
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-top: 4px;
}

.arp-controls-grid {
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding-top: 6px;
}

.power-toggle-btn {
  background: #251214;
  border: 1px solid #571b20;
  color: #ff8c94;
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.15s;
}

.power-toggle-btn.active {
  background: #11361c;
  border-color: #278544;
  color: #4fff7f;
  box-shadow: 0 0 6px rgba(79, 255, 127, 0.3);
}

.power-toggle-btn.mini {
  font-size: 7.5px;
  padding: 1px 5px;
}

/* ==========================================================================
   EFFECTS PROCESSORS (CHORUS, DELAY, REVERB, SATURATION)
   ========================================================================== */

.fx-units-container {
  display: flex;
  gap: 8px;
}

.fx-box {
  flex: 1;
  background: rgba(16, 18, 22, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fx-box-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  color: var(--text-gold);
}

.juno-buttons {
  display: flex;
  gap: 2px;
}

.juno-btn {
  background: #22262d;
  border: 1px solid #3c4452;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  padding: 1px 4px;
  border-radius: 2px;
  cursor: pointer;
}

.juno-btn.active {
  background: #ff9d00;
  color: #111;
  border-color: #ffb43a;
  box-shadow: 0 0 6px rgba(255, 157, 0, 0.4);
}

.fx-knobs-row {
  display: flex;
  align-items: center;
  justify-content: space-around;
}

/* ==========================================================================
   MONITORING: PHOSPHOR SCOPE & VU METERS WITH CLIP LEDS
   ========================================================================== */

.scope-mode-tabs {
  display: flex;
  gap: 2px;
}

.scope-btn {
  background: #191d24;
  border: 1px solid #303744;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 2px;
  cursor: pointer;
}

.scope-btn.active {
  background: #39e75f;
  color: #0b150d;
}

.monitoring-grid {
  display: flex;
  gap: 8px;
  align-items: center;
}

.scope-container {
  flex: 1.5;
}

.scope-bezel {
  background: #070e09;
  border: 2px solid #1c261e;
  border-radius: 4px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 0 10px rgba(0,0,0,0.9), 0 0 6px rgba(57, 231, 95, 0.1);
}

#scope-canvas {
  display: block;
  width: 100%;
  height: 64px;
}

.scope-grid-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    linear-gradient(rgba(57, 231, 95, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(57, 231, 95, 0.08) 1px, transparent 1px);
  background-size: 16px 16px;
  pointer-events: none;
}

/* VU Meters */
.vu-meters-container {
  flex: 1;
  display: flex;
  gap: 6px;
}

.vu-meter {
  flex: 1;
  background: #121417;
  border: 1px solid #282f3a;
  border-radius: 3px;
  padding: 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.vu-clip-led {
  position: absolute;
  top: 3px;
  right: 5px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #331517;
  border: 1px solid #571b20;
  transition: all 0.06s;
  z-index: 10;
}

.vu-clip-led.active {
  background: var(--led-red);
  box-shadow: 0 0 8px var(--led-red-glow);
  border-color: #ff8899;
}

.vu-scale {
  width: 100%;
  height: 52px;
  background: #efe3be;
  background: linear-gradient(180deg, #faf3de 0%, #e6d5a7 100%);
  border-radius: 2px;
  border: 1px solid #706245;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.4);
}

.vu-scale::after {
  content: '';
  position: absolute;
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 30px;
  height: 30px;
  background: #222;
  border-radius: 50%;
}

.vu-needle {
  position: absolute;
  bottom: 0px;
  left: 50%;
  width: 1.5px;
  height: 48px;
  background: #e61919;
  transform-origin: bottom center;
  transform: rotate(-35deg);
  transition: transform 0.05s ease-out;
  box-shadow: 0 0 2px rgba(0,0,0,0.5);
  z-index: 2;
}

.vu-db-text {
  position: absolute;
  top: 4px;
  left: 2px;
  right: 2px;
  font-family: var(--font-mono);
  font-size: 6px;
  color: #332d20;
  text-align: center;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.vu-channel {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  color: var(--text-dim);
  margin-top: 2px;
}

/* ==========================================================================
   ROTARY KNOBS & SWITCH CONTROLS
   ========================================================================== */

.knob-container {
  position: relative;
  width: 40px;
  height: 40px;
  cursor: ns-resize;
  display: flex;
  align-items: center;
  justify-content: center;
}

.knob-container.large {
  width: 54px;
  height: 54px;
}

.knob-container.mini {
  width: 32px;
  height: 32px;
}

.knob-cap {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #424955 0%, #20242a 60%, #131518 100%);
  border: 1.5px solid #4a5463;
  box-shadow: 
    0 3px 6px rgba(0, 0, 0, 0.7),
    inset 0 1px 1px rgba(255, 255, 255, 0.2);
  position: relative;
  transform: rotate(0deg);
  transition: box-shadow 0.15s;
}

.knob-container.large .knob-cap {
  width: 48px;
  height: 48px;
  border: 2px solid #5a6577;
}

.knob-container.mini .knob-cap {
  width: 26px;
  height: 26px;
  border: 1px solid #424955;
}

.knob-cap::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 9px;
  background: #ff9d00;
  border-radius: 1px;
  box-shadow: 0 0 4px rgba(255, 157, 0, 0.9);
}

.knob-container.large .knob-cap::after {
  height: 14px;
  width: 2.5px;
}

.knob-container.mini .knob-cap::after {
  height: 6px;
  width: 1.5px;
}

.knob-container:hover .knob-cap {
  border-color: #ff9d00;
  box-shadow: 0 0 8px rgba(255, 157, 0, 0.3);
}

/* Rotary Step Switches */
.rotary-switch {
  position: relative;
  width: 34px;
  height: 34px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rotary-switch.mini {
  width: 28px;
  height: 28px;
}

.switch-dial {
  width: 26px;
  height: 26px;
  background: linear-gradient(135deg, #444c59 0%, #1d2127 100%);
  border: 1px solid #576172;
  border-radius: 50%;
  position: relative;
  box-shadow: 0 2px 5px rgba(0,0,0,0.6);
  transform: rotate(0deg);
}

.rotary-switch.mini .switch-dial {
  width: 22px;
  height: 22px;
}

.switch-dial::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 7px;
  background: #ffffff;
  border-radius: 1px;
}

/* Toggle Buttons */
.toggle-btn {
  background: #20242b;
  border: 1px solid #3a4250;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s;
}

.toggle-btn.active {
  background: #ff9d00;
  color: #111;
  border-color: #ffb43a;
  box-shadow: 0 0 6px rgba(255, 157, 0, 0.4);
}

.toggle-btn.mini {
  font-size: 7.5px;
  padding: 2px 4px;
}

/* ==========================================================================
   PERFORMANCE DECK & KEYBOARD
   ========================================================================== */

.synth-performance-deck {
  display: flex;
  background: linear-gradient(180deg, #181b1f 0%, #0d0f12 100%);
  border-top: 2px solid #0a0c0e;
  border-bottom-left-radius: var(--border-radius-lg);
  border-bottom-right-radius: var(--border-radius-lg);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.8);
}

.performance-controls-container {
  flex: 1;
  display: flex;
  padding: 10px 16px 14px 16px;
  gap: 16px;
  align-items: stretch;
}

/* Wheels */
.wheels-box {
  display: flex;
  gap: 10px;
  align-items: center;
  background: #111317;
  padding: 8px 12px;
  border-radius: var(--border-radius-md);
  border: 1px solid #282f3a;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.7);
}

.wheel-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.wheel-track {
  position: relative;
  width: 28px;
  height: 86px;
  background: #090a0c;
  border: 1.5px solid #2a313d;
  border-radius: 4px;
  overflow: hidden;
  cursor: ns-resize;
  box-shadow: inset 0 0 8px rgba(0,0,0,0.9);
}

.wheel-drum {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 24px;
  background: repeating-linear-gradient(
    180deg,
    #4a5260 0px,
    #4a5260 2px,
    #252b34 3px,
    #252b34 5px
  );
  border-top: 1px solid #717d91;
  border-bottom: 1px solid #14171d;
  transform: translateY(-50%);
  box-shadow: 0 2px 5px rgba(0,0,0,0.6);
}

.wheel-spring-center {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: rgba(255, 157, 0, 0.4);
}

.wheel-label {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  color: var(--text-dim);
  letter-spacing: 1px;
}

.transpose-box {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-left: 6px;
  border-left: 1px solid #232832;
}

.transpose-btns {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.oct-btn {
  background: #20252c;
  border: 1px solid #363e4c;
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 2px;
  cursor: pointer;
}

.oct-btn:hover {
  background: #2e3541;
}

.oct-display {
  font-family: var(--font-mono);
  font-size: 8.5px;
  color: var(--led-amber);
  font-weight: 700;
  text-align: center;
  background: #0b0d10;
  padding: 1px 0;
  border-radius: 2px;
}

.panic-btn {
  background: #381215;
  border: 1px solid #731e24;
  color: #ff9ca3;
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 2px;
  cursor: pointer;
}

.panic-btn:hover {
  background: #54171c;
}

.kb-hints-btn {
  background: #1c232a;
  border: 1px solid #344150;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  padding: 2px 4px;
  border-radius: 2px;
  cursor: pointer;
}

.kb-hints-btn.active {
  color: #ff9d00;
  border-color: #ff9d00;
}

/* ==========================================================================
   PIANO KEYBOARD
   ========================================================================== */

.keyboard-viewport {
  flex: 1;
  background: #090a0d;
  border-radius: 4px;
  padding: 4px;
  border: 2px solid #1a1e24;
  box-shadow: inset 0 4px 10px rgba(0,0,0,0.9);
  overflow-x: auto;
}

.piano-keys {
  position: relative;
  display: flex;
  height: 94px;
  min-width: 820px;
}

.key {
  position: relative;
  cursor: pointer;
  user-select: none;
  transition: background 0.05s, transform 0.05s, box-shadow 0.05s;
}

.key-white {
  flex: 1;
  background: linear-gradient(180deg, #eceff1 0%, #cfd8dc 85%, #b0bec5 100%);
  border: 1px solid #78909c;
  border-top: none;
  border-radius: 0 0 3px 3px;
  z-index: 1;
  box-shadow: 
    inset 0 -4px 4px rgba(0,0,0,0.15),
    inset 1px 0 0 rgba(255,255,255,0.8),
    1px 2px 3px rgba(0,0,0,0.4);
}

.key-white:hover {
  background: linear-gradient(180deg, #ffffff 0%, #e0e0e0 100%);
}

.key-white.active {
  background: linear-gradient(180deg, #ffca28 0%, #ffb300 100%);
  box-shadow: 
    inset 0 2px 6px rgba(0,0,0,0.4),
    0 0 10px rgba(255, 179, 0, 0.6);
  transform: translateY(2px);
}

.key-black {
  position: absolute;
  width: 2.2%;
  height: 60%;
  background: linear-gradient(180deg, #374151 0%, #181d24 60%, #0d1015 100%);
  border: 1px solid #111418;
  border-radius: 0 0 3px 3px;
  z-index: 2;
  box-shadow: 
    0 4px 6px rgba(0,0,0,0.7),
    inset 0 1px 0 rgba(255,255,255,0.25);
}

.key-black:hover {
  background: linear-gradient(180deg, #4b5563 0%, #222933 100%);
}

.key-black.active {
  background: linear-gradient(180deg, #e65100 0%, #ff8f00 100%);
  box-shadow: 
    0 1px 3px rgba(0,0,0,0.8),
    0 0 10px rgba(255, 143, 0, 0.7);
  transform: translateY(2px);
}

.key-label {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  color: #37474f;
  pointer-events: none;
}

.key-black .key-label {
  color: #aaa;
  bottom: 2px;
  font-size: 7px;
}

.key-hint {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 7px;
  font-weight: 800;
  color: #ff9d00;
  background: rgba(0,0,0,0.1);
  padding: 0 2px;
  border-radius: 2px;
  pointer-events: none;
}

.key-black .key-hint {
  bottom: 12px;
  color: #ffb833;
}

/* ==========================================================================
   PRESET BROWSER MODAL (NEW DEDICATED SEARCH & BROWSE UI)
   ========================================================================== */

.preset-browser-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(6, 9, 12, 0.82);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1200;
  animation: fadeIn 0.15s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.98); }
  to { opacity: 1; transform: scale(1); }
}

.browser-card {
  width: 90%;
  max-width: 780px;
  height: 520px;
  background: linear-gradient(180deg, #222832 0%, #151921 100%);
  border: 1px solid #3c4758;
  border-radius: var(--border-radius-lg);
  box-shadow: 0 25px 50px rgba(0,0,0,0.85), 0 0 20px rgba(0,0,0,0.5);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.browser-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: #181d24;
  border-bottom: 1px solid #2e3746;
  gap: 14px;
}

.browser-title-group {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.browser-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  color: var(--text-gold);
  letter-spacing: 2px;
}

.browser-count {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--text-dim);
}

.browser-search-box {
  flex: 1;
  display: flex;
  align-items: center;
  background: #0d1014;
  border: 1px solid #313b4a;
  border-radius: 4px;
  padding: 4px 10px;
  gap: 6px;
}

.browser-search-box input {
  flex: 1;
  background: transparent;
  border: none;
  color: #fff;
  font-family: var(--font-ui);
  font-size: 12px;
  outline: none;
}

.browser-search-box input::placeholder {
  color: #64748b;
}

.search-clear-btn {
  background: transparent;
  border: none;
  color: #64748b;
  cursor: pointer;
  font-size: 11px;
}
.search-clear-btn:hover { color: #fff; }

.browser-close-btn {
  background: #252c38;
  border: 1px solid #3d4758;
  color: #94a3b8;
  width: 26px;
  height: 26px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}
.browser-close-btn:hover {
  background: #3b4759;
  color: #fff;
}

.browser-filter-row {
  padding: 8px 18px;
  background: #151920;
  border-bottom: 1px solid #232a35;
}

.browser-cats {
  display: flex;
  gap: 4px;
}

.b-cat-btn {
  background: #1f2530;
  border: 1px solid #313a48;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.1s;
}

.b-cat-btn:hover {
  color: #fff;
  background: #2b3342;
}

.b-cat-btn.active {
  background: #ff9d00;
  color: #111;
  border-color: #ffb43a;
  box-shadow: 0 0 6px rgba(255, 157, 0, 0.4);
}

.browser-list-container {
  flex: 1;
  overflow-y: auto;
  padding: 10px 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.browser-preset-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #171b23;
  border: 1px solid #28303e;
  border-radius: 4px;
  padding: 8px 12px;
  cursor: pointer;
  transition: all 0.1s ease;
}

.browser-preset-item:hover {
  background: #242c3b;
  border-color: #4a576d;
  transform: translateX(2px);
}

.browser-preset-item.active {
  background: #2a3446;
  border-color: #ff9d00;
  box-shadow: 0 0 10px rgba(255, 157, 0, 0.25);
}

.b-preset-main {
  display: flex;
  align-items: center;
  gap: 10px;
}

.b-preset-num {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: #64748b;
  min-width: 26px;
}

.b-preset-name {
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  color: #f8fafc;
}

.b-preset-desc {
  font-size: 11px;
  color: #94a3b8;
  margin-left: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 320px;
}

.b-preset-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.b-preset-author {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #64748b;
}

.b-preset-cat-tag {
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
  background: #1f2836;
  color: var(--led-amber);
  border: 1px solid #364459;
}

.browser-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 18px;
  background: #12151c;
  border-top: 1px solid #232a35;
}

.browser-hint {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #64748b;
}

.browser-hint kbd {
  background: #1e2430;
  border: 1px solid #343e50;
  border-radius: 2px;
  padding: 1px 4px;
  color: #ff9d00;
}

/* ==========================================================================
   DIRECT NUMERICAL INPUT POPUP (PRO-AUDIO UI DESIGN SKILL)
   ========================================================================== */

.knob-num-input-popup {
  position: absolute;
  z-index: 1000;
  background: #0d1015;
  border: 1.5px solid #ff9d00;
  border-radius: 4px;
  padding: 4px 6px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.8), 0 0 10px rgba(255, 157, 0, 0.4);
  display: flex;
  flex-direction: column;
  gap: 2px;
  transform: translate(-50%, -100%);
}

.knob-num-input-popup input {
  background: #181d26;
  border: 1px solid #323b49;
  color: #4fff7f;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 2px 4px;
  border-radius: 2px;
  outline: none;
  width: 70px;
  text-align: center;
}

.knob-num-input-popup .input-label {
  font-family: var(--font-mono);
  font-size: 7px;
  color: var(--text-dim);
  text-align: center;
}

/* ==========================================================================
   AUDIO START MODAL OVERLAY
   ========================================================================== */

.audio-start-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(4, 6, 8, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  transition: opacity 0.3s ease;
}

.audio-start-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.start-card {
  background: linear-gradient(180deg, #252a33 0%, #15181f 100%);
  border: 2px solid #3e4757;
  border-radius: 12px;
  padding: 32px 40px;
  text-align: center;
  max-width: 480px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9), 0 0 30px rgba(255, 157, 0, 0.15);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.start-logo {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 800;
  letter-spacing: 8px;
  color: #fff;
  text-shadow: 0 0 20px rgba(255, 157, 0, 0.6);
}

.start-sub {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--text-gold);
  font-weight: 700;
}

.start-desc {
  font-family: var(--font-ui);
  font-size: 13px;
  color: var(--text-dim);
  line-height: 1.5;
  margin-top: 4px;
}

.power-on-btn {
  background: linear-gradient(180deg, #ffaa00 0%, #e67e00 100%);
  border: 1px solid #ffc24d;
  color: #0d0f12;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 1.5px;
  padding: 12px 28px;
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(255, 170, 0, 0.4);
  transition: all 0.15s ease;
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.power-on-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(255, 170, 0, 0.6);
  background: linear-gradient(180deg, #ffb82e 0%, #f08800 100%);
}

.power-on-btn:active {
  transform: translateY(1px);
}

.start-tips {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: #94a3b8;
  margin-top: 10px;
  text-align: left;
  background: #0f1216;
  padding: 10px 14px;
  border-radius: 6px;
  border: 1px solid #232832;
  width: 100%;
}

/* ==========================================================================
   TOOLTIPS FOR KNOB VALUES
   ========================================================================== */

.knob-tooltip {
  position: absolute;
  bottom: 105%;
  left: 50%;
  transform: translateX(-50%);
  background: #080a0c;
  color: #ff9d00;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
  border: 1px solid #333a46;
  white-space: nowrap;
  pointer-events: none;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.8);
}

/* ==========================================================================
   CHILL SYNTHWAVE PLAYER DOCK & RETROWAVE STYLING
   ========================================================================== */

.cat-btn.highlight-808,
.b-cat-btn.highlight-808 {
  background: linear-gradient(135deg, rgba(255, 42, 95, 0.25) 0%, rgba(153, 0, 34, 0.25) 100%);
  border-color: #ff2a5f;
  color: #ff7597;
  font-weight: 700;
  text-shadow: 0 0 6px rgba(255, 42, 95, 0.6);
}

.cat-btn.highlight-808.active,
.b-cat-btn.highlight-808.active {
  background: linear-gradient(135deg, #ff2a5f 0%, #990022 100%);
  color: #fff;
  border-color: #ff7597;
  box-shadow: 0 0 12px rgba(255, 42, 95, 0.7);
}

.cat-btn.highlight-cat,
.b-cat-btn.highlight-cat {
  background: linear-gradient(135deg, rgba(255, 0, 128, 0.25) 0%, rgba(0, 229, 255, 0.25) 100%);
  border-color: #ff007f;
  color: #ff80df;
  font-weight: 700;
  text-shadow: 0 0 6px rgba(255, 0, 128, 0.6);
}

.cat-btn.highlight-cat.active,
.b-cat-btn.highlight-cat.active {
  background: linear-gradient(135deg, #ff007f 0%, #00e5ff 100%);
  color: #0d0f12;
  border-color: #ff80df;
  box-shadow: 0 0 12px rgba(255, 0, 128, 0.7);
}

.chillwave-player-dock {
  display: flex;
  background: #111419;
  border-top: 1px solid #2d3340;
  border-bottom: 2px solid #000;
  position: relative;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.6);
}

.wood-left-dock, .wood-right-dock {
  width: 28px;
  min-height: 48px;
  background: linear-gradient(90deg, #3d2314 0%, #5c351e 50%, #2b180d 100%);
  border-left: 1px solid rgba(255,255,255,0.08);
  border-right: 1px solid rgba(0,0,0,0.8);
}

.wood-right-dock {
  background: linear-gradient(90deg, #2b180d 0%, #5c351e 50%, #3d2314 100%);
}

.chillwave-dock-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 18px;
  background: linear-gradient(180deg, #171b22 0%, #101318 100%);
  gap: 16px;
  flex-wrap: wrap;
}

.chill-play-section {
  display: flex;
  align-items: center;
  gap: 12px;
}

.chill-play-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(180deg, #ff007f 0%, #b80058 100%);
  border: 1px solid #ff4da6;
  border-radius: 4px;
  color: #fff;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 7px 16px;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(255, 0, 128, 0.4);
  transition: all 0.15s ease;
}

.chill-play-btn:hover {
  background: linear-gradient(180deg, #ff2a94 0%, #d10066 100%);
  box-shadow: 0 4px 14px rgba(255, 0, 128, 0.6);
  transform: translateY(-1px);
}

.chill-play-btn.playing {
  background: linear-gradient(180deg, #00e5ff 0%, #008fa0 100%);
  border-color: #66efff;
  color: #0a1118;
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.7);
  animation: pulse-retroglow 2s infinite alternate;
}

@keyframes pulse-retroglow {
  0% { box-shadow: 0 0 8px rgba(0, 229, 255, 0.5); }
  100% { box-shadow: 0 0 18px rgba(255, 0, 128, 0.8); }
}

.chill-play-icon {
  font-size: 11px;
}

.chill-track-selector {
  display: flex;
  align-items: center;
  gap: 6px;
}

.chill-track-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #64748b;
  font-weight: 700;
}

.chill-select-menu {
  background: #0b0d11;
  border: 1px solid #2e3746;
  border-radius: 3px;
  color: #38bdf8;
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 5px 10px;
  outline: none;
  cursor: pointer;
}

.chill-select-menu:focus {
  border-color: #00e5ff;
  box-shadow: 0 0 8px rgba(0, 229, 255, 0.3);
}

.chill-layers-section {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chill-layers-title {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #64748b;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.layer-pill {
  background: #1e2430;
  border: 1px solid #333d4f;
  border-radius: 3px;
  color: #64748b;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 4px 9px;
  cursor: pointer;
  transition: all 0.12s;
}

.layer-pill:hover {
  border-color: #4a576e;
  color: #cbd5e1;
}

.layer-pill.active {
  background: rgba(56, 189, 248, 0.15);
  border-color: #38bdf8;
  color: #38bdf8;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.3);
}

.layer-pill.muted {
  background: #14171d;
  border-color: #242a35;
  color: #475569;
  text-decoration: line-through;
}

.chill-status-section {
  display: flex;
  align-items: center;
}

.chill-status-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #080a0d;
  border: 1px solid #232936;
  border-radius: 3px;
  padding: 4px 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: #94a3b8;
}

.chill-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #334155;
  transition: all 0.2s;
}

.chill-status-dot.active {
  background: #00e5ff;
  box-shadow: 0 0 10px #00e5ff;
  animation: blink-dot 1.2s infinite;
}

@keyframes blink-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* ==========================================================================
   DAW MULTI-TRACK TIMELINE MATRIX STYLING
   ========================================================================== */

.timeline-toggle-btn {
  background: #1e2430;
  border: 1px solid #3d4a61;
  color: #38bdf8;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 3px;
  cursor: pointer;
  margin-right: 8px;
  transition: all 0.15s ease;
}

.timeline-toggle-btn:hover {
  background: #283244;
  border-color: #38bdf8;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.3);
}

.timeline-toggle-btn.active {
  background: #0284c7;
  color: #fff;
  border-color: #38bdf8;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.5);
}

.daw-timeline-drawer {
  background: #090c10;
  border-top: 1px solid #1f2530;
  border-bottom: 2px solid #000;
  padding: 10px 18px 14px;
  box-shadow: inset 0 4px 12px rgba(0,0,0,0.8);
}

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

.timeline-title-wrap {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.timeline-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #ff2a5f;
}

.timeline-info {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #94a3b8;
}

.timeline-legend {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 9px;
  color: #64748b;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.legend-dot {
  width: 7px;
  height: 7px;
  border-radius: 2px;
}

.dot-kick { background: #ff0055; box-shadow: 0 0 6px #ff0055; }
.dot-clap { background: #ffaa00; box-shadow: 0 0 6px #ffaa00; }
.dot-bass { background: #00e5ff; box-shadow: 0 0 6px #00e5ff; }
.dot-pad { background: #a855f7; box-shadow: 0 0 6px #a855f7; }
.dot-arp { background: #38bdf8; box-shadow: 0 0 6px #38bdf8; }

.timeline-scroll-wrap {
  overflow-x: auto;
  border: 1px solid #1e2430;
  border-radius: 4px;
  background: #0d1117;
  padding: 6px;
}

.timeline-grid-container {
  display: flex;
  flex-direction: column;
  gap: 3px;
  position: relative;
  min-width: 780px;
}

.timeline-bars-header {
  display: flex;
  margin-left: 90px;
  border-bottom: 1px solid #242c3b;
  padding-bottom: 4px;
  margin-bottom: 3px;
}

.bar-marker {
  flex: 1;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #ff9d00;
  border-right: 1px solid rgba(255,255,255,0.06);
  padding: 1px 0;
  position: relative;
}

.bar-chord-badge {
  position: absolute;
  top: -1px;
  right: 4px;
  font-size: 8px;
  color: #cbd5e1;
  background: #18202c;
  padding: 0 4px;
  border-radius: 2px;
}

.timeline-lane-row {
  display: flex;
  align-items: center;
  height: 24px;
  gap: 6px;
}

.lane-label-box {
  width: 84px;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 4px;
}

.lane-steps-wrap {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(64, 1fr);
  gap: 1px;
  height: 100%;
  background: #090c10;
  border: 1px solid #161b22;
  border-radius: 2px;
  position: relative;
}

.step-block {
  background: #111620;
  border-radius: 1px;
  height: 100%;
  position: relative;
  transition: all 0.08s ease;
}

.step-block.bar-divider {
  border-left: 1px solid rgba(255,255,255,0.12);
}

.step-block.hit-kick {
  background: #ff0055;
  box-shadow: 0 0 6px rgba(255, 0, 85, 0.7);
}

.step-block.hit-clap {
  background: #ffaa00;
  box-shadow: 0 0 6px rgba(255, 170, 0, 0.7);
}

.step-block.hit-hat {
  background: rgba(255, 255, 255, 0.4);
}

.step-block.hit-bass {
  background: #00e5ff;
  box-shadow: 0 0 6px rgba(0, 229, 255, 0.7);
}

.step-block.hit-pad {
  background: #a855f7;
  opacity: 0.85;
}

.step-block.hit-arp {
  background: #38bdf8;
  box-shadow: 0 0 6px rgba(56, 189, 248, 0.7);
}

/* Moving Playhead Cursor */
.timeline-playhead-cursor {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #ffaa00;
  box-shadow: 0 0 8px #ffaa00;
  pointer-events: none;
  z-index: 20;
  transition: left 0.04s linear;
}

/* STEM MIXER SLIDERS */
.timeline-mixer-strip {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  padding: 6px 12px;
  background: #06080b;
  border: 1px solid #1a222e;
  border-radius: 4px;
  flex-wrap: wrap;
}

.mixer-strip-title {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 800;
  color: #ffaa00;
  letter-spacing: 0.5px;
}

.stem-slider-group {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #10141c;
  padding: 3px 8px;
  border-radius: 3px;
  border: 1px solid #202836;
}

.stem-name {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #94a3b8;
}

.stem-range-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 55px;
  height: 4px;
  background: #252e3d;
  border-radius: 2px;
  outline: none;
  cursor: pointer;
}

.stem-range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #38bdf8;
  cursor: pointer;
  box-shadow: 0 0 4px #38bdf8;
}

.stem-val {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #38bdf8;
  width: 28px;
  text-align: right;
}

/* ==========================================================================
   DAW MASTER TRANSPORT BAR & WORKSPACE VIEW SWITCHER
   ========================================================================== */

.daw-transport-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(180deg, #13171f 0%, #0a0d12 100%);
  border-top: 1px solid #232a38;
  border-bottom: 2px solid #000;
  padding: 6px 18px;
  gap: 14px;
  flex-wrap: wrap;
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  position: relative;
  z-index: 10;
}

.daw-view-switcher {
  display: flex;
  background: #080a0e;
  padding: 3px;
  border-radius: 4px;
  border: 1px solid #1e2634;
  gap: 3px;
}

.view-tab-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 5px 12px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.view-tab-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.06);
}

.view-tab-btn.active {
  background: linear-gradient(180deg, #0284c7 0%, #0369a1 100%);
  color: #fff;
  box-shadow: 0 2px 8px rgba(2, 132, 199, 0.4);
}

.daw-transport-center {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #0c0f15;
  padding: 4px 10px;
  border-radius: 4px;
  border: 1px solid #1e2634;
}

.transport-btn {
  background: #181f2b;
  border: 1px solid #2e3b50;
  color: #cbd5e1;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.12s ease;
}

.transport-btn:hover {
  background: #243042;
  border-color: #38bdf8;
  color: #fff;
}

.transport-btn.play-btn.playing {
  background: #16a34a;
  border-color: #22c55e;
  color: #fff;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.5);
}

.transport-btn.rec-btn.recording {
  background: #dc2626;
  border-color: #ef4444;
  color: #fff;
  animation: rec-blink 1s infinite;
}

@keyframes rec-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.transport-btn.loop-btn.active {
  background: #0284c7;
  color: #fff;
  border-color: #38bdf8;
}

.transport-btn.metro-btn.active {
  background: #d97706;
  color: #fff;
  border-color: #f59e0b;
}

.transport-lcd-counter {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: #050608;
  border: 1px solid #1a222e;
  border-radius: 3px;
  padding: 2px 8px;
  min-width: 90px;
}

.lcd-pos-digits {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 800;
  color: #00e5ff;
  letter-spacing: 1px;
  text-shadow: 0 0 8px rgba(0, 229, 255, 0.6);
}

.lcd-time-display {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #64748b;
}

.tempo-control-box {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #050608;
  border: 1px solid #1a222e;
  border-radius: 3px;
  padding: 2px 6px;
}

.tempo-label {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #64748b;
}

.bpm-num-input {
  width: 42px;
  background: transparent;
  border: none;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 800;
  color: #ffaa00;
  text-align: center;
  outline: none;
}

.tempo-unit {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #64748b;
}

.sig-badge {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  color: #cbd5e1;
  background: #1e2634;
  padding: 1px 4px;
  border-radius: 2px;
  margin-left: 2px;
}

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

.project-btn {
  font-size: 10px;
  padding: 5px 10px;
}

.project-btn.highlight-btn {
  background: linear-gradient(180deg, #ff007f 0%, #b80058 100%);
  border-color: #ff4da6;
  color: #fff;
  box-shadow: 0 2px 8px rgba(255, 0, 128, 0.4);
}

/* ==========================================================================
   DAW WORKSPACE VIEW PANELS
   ========================================================================== */

.daw-view-panel {
  flex: 1;
  width: 100%;
  min-width: 0;
}

/* ==========================================================================
   ARRANGEMENT TIMELINE VIEW
   ========================================================================== */

.arrangement-studio-wrap {
  background: #090c10;
  border: 1px solid #1b222d;
  border-radius: 4px;
  padding: 12px;
  box-shadow: inset 0 2px 10px rgba(0,0,0,0.6);
  min-height: 480px;
}

.arrange-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid #1e2634;
}

.arrange-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  color: #38bdf8;
  letter-spacing: 1px;
}

.arrange-actions {
  display: flex;
  gap: 14px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: #94a3b8;
}

.arrange-timeline-viewport {
  display: flex;
  border: 1px solid #1f2736;
  border-radius: 4px;
  background: #07090d;
  overflow: hidden;
}

.arrange-track-headers-col {
  width: 150px;
  background: #0f131a;
  border-right: 1px solid #1f2736;
  display: flex;
  flex-direction: column;
}

.track-hdr {
  height: 56px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  gap: 8px;
  border-bottom: 1px solid #1a222e;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: #cbd5e1;
}

.track-hdr.hdr-bar-num {
  height: 28px;
  background: #0a0d12;
  color: #64748b;
  font-size: 9px;
}

.th-icon { font-size: 14px; }
.th-name { flex: 1; }
.th-badge {
  font-size: 8px;
  background: #1e2634;
  padding: 1px 4px;
  border-radius: 2px;
  color: #38bdf8;
}

.arrange-timeline-tracks-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-x: auto;
  position: relative;
}

.arrange-lane-row {
  height: 56px;
  border-bottom: 1px solid #151a24;
  display: flex;
  align-items: center;
  position: relative;
  background: #080a0f;
  padding: 4px;
}

.arrange-clip-box {
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.3) 0%, rgba(3, 105, 161, 0.5) 100%);
  border: 1px solid #38bdf8;
  border-radius: 3px;
  height: 100%;
  padding: 4px 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

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

.clip-waveform-sim {
  height: 16px;
  background: repeating-linear-gradient(90deg, #38bdf8, #38bdf8 2px, transparent 2px, transparent 4px);
  opacity: 0.6;
  border-radius: 1px;
}

/* ==========================================================================
   PIANO ROLL EDITOR STYLES
   ========================================================================== */

.piano-roll-wrapper {
  background: #080a0e;
  border: 1px solid #1a222e;
  border-radius: 4px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pr-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 6px;
  border-bottom: 1px solid #1a222e;
  flex-wrap: wrap;
  gap: 8px;
}

.pr-tool-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pr-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  color: #ffaa00;
  letter-spacing: 0.5px;
}

.pr-track-selects {
  display: flex;
  gap: 3px;
  background: #050608;
  padding: 2px;
  border-radius: 3px;
  border: 1px solid #161b24;
}

.pr-tab-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 2px;
  cursor: pointer;
}

.pr-tab-btn.active {
  background: #ffaa00;
  color: #000;
}

.pr-tool-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pr-hint {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #64748b;
}

.pr-body-wrap {
  display: flex;
  border: 1px solid #1a222e;
  border-radius: 3px;
  height: 440px;
  overflow: hidden;
}

.pr-keybed-col {
  width: 50px;
  background: #0d1117;
  border-right: 1px solid #1e2634;
  display: flex;
  flex-direction: column;
  overflow-y: hidden;
}

.pr-key {
  height: 12px;
  border-bottom: 1px solid rgba(0,0,0,0.5);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  display: flex;
  align-items: center;
  padding-left: 4px;
  cursor: pointer;
  user-select: none;
}

.pr-key.white-key {
  background: #cbd5e1;
  color: #0f172a;
}

.pr-key.black-key {
  background: #1e293b;
  color: #94a3b8;
}

.pr-key.root-c {
  background: #38bdf8;
  color: #000;
}

.pr-key.pressed {
  background: #ff007f !important;
  color: #fff !important;
}

.pr-grid-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-x: auto;
  overflow-y: hidden;
  background: #06080b;
}

.pr-grid-row {
  height: 12px;
  display: grid;
  grid-template-columns: repeat(64, 16px);
  border-bottom: 1px solid rgba(255,255,255,0.03);
}

.pr-grid-row.black-row {
  background: rgba(0, 0, 0, 0.4);
}

.pr-grid-row.root-row {
  background: rgba(56, 189, 248, 0.06);
}

.pr-grid-cell {
  border-right: 1px solid rgba(255,255,255,0.04);
  height: 100%;
  position: relative;
  cursor: crosshair;
}

.pr-grid-cell.bar-line {
  border-left: 1px solid rgba(255, 170, 0, 0.3);
}

.pr-grid-cell.beat-line {
  border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.pr-note-block {
  position: absolute;
  top: 1px;
  bottom: 1px;
  left: 1px;
  background: linear-gradient(90deg, #ffaa00 0%, #ff8800 100%);
  border: 1px solid #ffd580;
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 3px;
  color: #000;
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 800;
  box-shadow: 0 1px 4px rgba(255, 170, 0, 0.6);
  z-index: 10;
}

/* ==========================================================================
   STUDIO MIXING CONSOLE DESK STYLES (pro-audio-ui-design standard)
   ========================================================================== */

.studio-mixer-desk {
  background: #080b10;
  border: 1px solid #1c2432;
  border-radius: 6px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: inset 0 2px 14px rgba(0, 0, 0, 0.85), 0 8px 24px rgba(0, 0, 0, 0.6);
  user-select: none;
}

.mixer-top-deck {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: linear-gradient(180deg, #121824 0%, #0c1018 100%);
  border: 1px solid #1e293b;
  border-radius: 5px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.5);
  flex-wrap: wrap;
  gap: 12px;
}

.mixer-brand-block {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mixer-logo-icon {
  font-size: 20px;
  filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.4));
}

.mixer-brand-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.mixer-main-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  color: #f1f5f9;
  letter-spacing: 0.8px;
}

.mixer-sub-title {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #00e5ff;
  letter-spacing: 0.5px;
}

.mixer-toolbar-actions {
  display: flex;
  gap: 6px;
}

.mixer-tool-btn {
  background: #17202e;
  border: 1px solid #283548;
  color: #94a3b8;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.mixer-tool-btn:hover {
  background: #233044;
  color: #f8fafc;
  border-color: #38bdf8;
}

.mixer-tool-btn:active {
  transform: scale(0.96);
  background: #0f172a;
}

.mixer-master-readouts {
  display: flex;
  gap: 12px;
}

.readout-box {
  background: #06090e;
  border: 1px solid #1a222e;
  border-radius: 4px;
  padding: 4px 10px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  min-width: 90px;
}

.readout-label {
  font-family: var(--font-mono);
  font-size: 7px;
  color: #64748b;
}

.readout-val {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 800;
  color: #22c55e;
}

/* Strips Rack Layout */
.mixer-strips-rack {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.console-channel-strip {
  flex: 1;
  min-width: 135px;
  max-width: 180px;
  background: linear-gradient(180deg, #131822 0%, #0d1118 60%, #090c12 100%);
  border: 1px solid #212a3a;
  border-radius: 5px;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.6);
  position: relative;
}

.console-channel-strip.master-channel-strip {
  background: linear-gradient(180deg, #1c1822 0%, #130f18 60%, #0d0a12 100%);
  border-color: #58336d;
  min-width: 145px;
}

.strip-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 4px;
  padding-bottom: 6px;
  border-bottom: 1px solid #1e2838;
}

.ch-badge {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 800;
  color: #64748b;
  background: #0c1017;
  padding: 2px 4px;
  border-radius: 2px;
}

.ch-title {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 800;
  color: #f1f5f9;
  letter-spacing: 0.5px;
}

.bay-tag {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
  display: block;
}

/* EQ Bay & Rotary Controls */
.strip-eq-bay, .strip-sends-bay {
  background: #080c12;
  border: 1px solid #161e2b;
  border-radius: 4px;
  padding: 6px 4px;
}

.eq-rotary-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  align-items: center;
}

.sends-rotary-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
  align-items: center;
}

.rotary-control-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: ns-resize;
}

.rotary-dial {
  width: 32px;
  height: 32px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rotary-ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring-bg {
  fill: none;
  stroke: #1b2432;
  stroke-width: 2.5;
}

.ring-active {
  fill: none;
  stroke: var(--strip-accent, #38bdf8);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 0 100;
  transition: stroke-dasharray 0.05s ease;
}

.dial-cap {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2b3648 0%, #151c27 100%);
  border: 1px solid #3b4b64;
  box-shadow: 0 2px 4px rgba(0,0,0,0.6);
  position: relative;
  transition: transform 0.05s ease;
}

.dial-cap::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 5px;
  background: #ffffff;
  border-radius: 1px;
  box-shadow: 0 0 3px rgba(255,255,255,0.8);
}

.rotary-label {
  font-family: var(--font-mono);
  font-size: 7px;
  font-weight: 700;
  color: #94a3b8;
}

.rotary-val-txt {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 700;
  color: #ffaa00;
}

/* Master Processor Card */
.master-processor-card {
  background: #140d1c;
  border: 1px solid #3b1b4d;
  border-radius: 4px;
  padding: 8px 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.proc-title {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 800;
  color: #c084fc;
}

.proc-led-group {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
}

.proc-led {
  font-family: var(--font-mono);
  font-size: 6.5px;
  font-weight: 700;
  padding: 2px 0;
  background: #231430;
  border-radius: 2px;
  color: #e9d5ff;
  border: 1px solid #581c87;
}

.proc-led.on {
  color: #38bdf8;
  border-color: #0284c7;
  background: #0b1f33;
}

.master-insignia {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 6px;
  background: #08050c;
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: #a855f7;
}

/* Pan & Tactile Switches */
.strip-pan-switches {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pan-rotary-box {
  display: flex;
  justify-content: center;
}

.strip-tactile-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}

.tactile-sw-btn {
  background: #161e2a;
  border: 1px solid #283548;
  color: #94a3b8;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  padding: 4px 0;
  border-radius: 3px;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.5);
  transition: all 0.12s ease;
}

.tactile-sw-btn:hover {
  background: #233044;
  color: #ffffff;
}

.tactile-sw-btn.btn-mute.active {
  background: #dc2626;
  color: #ffffff;
  border-color: #ef4444;
  box-shadow: 0 0 8px rgba(220, 38, 38, 0.6);
}

.tactile-sw-btn.btn-solo.active {
  background: #d97706;
  color: #ffffff;
  border-color: #f59e0b;
  box-shadow: 0 0 8px rgba(217, 119, 6, 0.6);
}

.tactile-sw-btn.btn-arm.active {
  background: #dc2626;
  color: #ffffff;
  border-color: #ef4444;
  box-shadow: 0 0 8px rgba(220, 38, 38, 0.6);
}

.master-stereo-badge {
  background: #20132b;
  border: 1px solid #6b21a8;
  border-radius: 3px;
  padding: 6px 4px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.master-stereo-badge span {
  font-family: var(--font-mono);
  font-size: 7.5px;
  font-weight: 800;
  color: #f59e0b;
}

.master-sub-badge {
  font-size: 6.5px !important;
  color: #94a3b8 !important;
}

/* Fader & Real-Time Multi-Segment Peak Meters Stage */
.strip-fader-meter-bay {
  display: flex;
  gap: 6px;
  height: 180px;
  background: #06090e;
  border: 1px solid #18202d;
  border-radius: 4px;
  padding: 8px 6px;
  box-shadow: inset 0 2px 8px rgba(0,0,0,0.85);
}

.meter-ladder-ch {
  display: flex;
  gap: 2px;
  width: 14px;
  height: 100%;
}

.meter-channel-col {
  flex: 1;
  background: #0d121a;
  border: 1px solid #1a2332;
  border-radius: 1px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}

.meter-peak-segment {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: #334155;
  transition: background 0.1s ease;
}

.meter-peak-segment.clip {
  background: #ef4444;
  box-shadow: 0 0 6px #ef4444;
}

.meter-led-fill {
  width: 100%;
  height: 0%;
  background: linear-gradient(0deg, #10b981 0%, #22c55e 65%, #eab308 85%, #ef4444 100%);
  border-radius: 1px;
  transition: height 0.04s ease-out;
}

/* Motorized Fader Housing */
.motorized-fader-housing {
  flex: 1;
  display: flex;
  position: relative;
  height: 100%;
}

.fader-scale-laser {
  position: absolute;
  right: -2px;
  top: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 6.5px;
  color: #475569;
  pointer-events: none;
  line-height: 1;
}

.fader-track-groove {
  width: 100%;
  height: 100%;
  position: relative;
  background: repeating-linear-gradient(0deg, #101622, #101622 2px, transparent 2px, transparent 12px);
  cursor: pointer;
}

.fader-track-groove::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 4px;
  bottom: 4px;
  width: 4px;
  background: #04070a;
  border: 1px solid #1c2636;
  border-radius: 2px;
}

.fader-cap {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 75%; /* default 0 dB unity */
  width: 34px;
  height: 20px;
  background: linear-gradient(180deg, #475569 0%, #1e293b 50%, #0f172a 100%);
  border: 1px solid #64748b;
  border-radius: 3px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.8), inset 0 1px 0 rgba(255,255,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: ns-resize;
  z-index: 10;
  transition: border-color 0.15s ease;
}

.fader-cap:hover {
  border-color: var(--strip-accent, #38bdf8);
  box-shadow: 0 4px 12px rgba(0,0,0,0.9), 0 0 6px rgba(56, 189, 248, 0.4);
}

.fader-grip-line {
  width: 18px;
  height: 2px;
  background: var(--strip-accent, #38bdf8);
  border-radius: 1px;
  box-shadow: 0 0 4px var(--strip-accent, #38bdf8);
}

/* Footer LCD */
.strip-footer-lcd {
  background: #04070b;
  border: 1px solid #141b26;
  border-radius: 3px;
  padding: 4px 0;
  text-align: center;
}

.db-num-lcd {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 800;
  color: var(--strip-accent, #38bdf8);
  letter-spacing: 0.5px;
  cursor: pointer;
}




