/* ====================================================================
   FLOVA AUDIO STUDIO - DESIGN SYSTEM & STYLES (FULL-WIDTH DAW)
   Ultra-modern Dark Glassmorphism DAW & Wide Audio Editor
   ==================================================================== */

:root {
  --bg-primary: #070913;
  --bg-secondary: #0c101d;
  --bg-card: rgba(14, 18, 32, 0.72);
  --bg-card-hover: rgba(22, 28, 48, 0.82);
  --bg-glass: rgba(12, 16, 28, 0.65);
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-glass-glow: rgba(99, 102, 241, 0.4);
  
  --accent-primary: #6366f1;
  --accent-glow: rgba(99, 102, 241, 0.4);
  --accent-cyan: #06b6d4;
  --accent-purple: #a855f7;
  --accent-emerald: #10b981;
  --accent-rose: #f43f5e;
  
  --waveform-bg: #05070d;
  --waveform-wave: #6366f1;
  --waveform-wave-sec: #06b6d4;
  --waveform-progress: #818cf8;
  --waveform-region: rgba(99, 102, 241, 0.22);
  --waveform-region-border: #818cf8;
  --waveform-handle: #ffffff;
  --waveform-playhead: #f43f5e;
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  --font-sans: 'Outfit', 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  
  --radius-sm: 7px;
  --radius-md: 11px;
  --radius-lg: 15px;
  --radius-xl: 20px;
  
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  --shadow-glow: 0 0 25px -4px var(--accent-glow);
  --shadow-glow-cyan: 0 0 25px -4px rgba(6, 182, 212, 0.45);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  background-image: 
    radial-gradient(circle at 15% 10%, rgba(99, 102, 241, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(6, 182, 212, 0.09) 0%, transparent 45%),
    radial-gradient(circle at 50% 50%, rgba(168, 85, 247, 0.05) 0%, transparent 60%);
  background-attachment: fixed;
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Scrollbars */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: rgba(6, 8, 14, 0.9);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(99, 102, 241, 0.5);
}

/* Full Width App Container */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
  max-width: 1720px;
  margin: 0 auto;
  padding: 12px 18px 28px;
  gap: 14px;
}

/* Header */
.studio-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px;
  background: var(--bg-card);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-card);
  flex-wrap: wrap;
  gap: 12px;
}

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

.brand-logo {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 3px 14px rgba(255, 107, 0, 0.3), 0 0 10px rgba(99, 102, 241, 0.2);
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s ease;
  flex-shrink: 0;
  user-select: none;
}

.brand-logo:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 20px rgba(255, 107, 0, 0.45), 0 0 15px rgba(99, 102, 241, 0.35);
}

.brand-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.brand-logo svg {
  width: 20px;
  height: 20px;
  color: #ffffff;
}

.brand-title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #ffffff 40%, #c7d2fe);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: flex;
  align-items: center;
  gap: 8px;
}

.badge-pro {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(99, 102, 241, 0.18);
  border: 1px solid rgba(99, 102, 241, 0.38);
  color: #c7d2fe;
  padding: 2px 7px;
  border-radius: 6px;
}

.header-modes {
  display: flex;
  background: rgba(5, 7, 13, 0.85);
  padding: 3px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5);
  gap: 2px;
}

.mode-tab-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.84rem;
  cursor: pointer;
  transition: all 0.18s ease;
  user-select: none;
}

.mode-tab-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
}

.mode-tab-btn.active {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(99, 102, 241, 0.45);
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 15px;
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.97) !important;
}

.btn-primary {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(99, 102, 241, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #4f46e5, #4338ca);
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.45);
  transform: translateY(-1px);
}

.btn-emerald {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.btn-emerald:hover {
  background: linear-gradient(135deg, #059669, #047857);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.45);
  transform: translateY(-1px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-main);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

.btn-danger {
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.3);
  color: #fb7185;
}
.btn-danger:hover {
  background: rgba(244, 63, 94, 0.3);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-sm {
  padding: 5px 11px;
  font-size: 0.78rem;
  border-radius: var(--radius-sm);
}

/* Full Width Main Studio Layout */
.studio-layout {
  display: flex;
  flex-direction: column;
  width: 100%;
  gap: 16px;
}

.studio-main-col {
  width: 100%;
}

/* Glass Card */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-card);
  padding: 18px 22px;
  width: 100%;
}

/* Empty Drop Zone */
.drop-zone {
  border: 2px dashed rgba(99, 102, 241, 0.35);
  border-radius: var(--radius-lg);
  padding: 70px 20px;
  text-align: center;
  background: rgba(15, 20, 35, 0.35);
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
}

.drop-zone:hover,
.drop-zone.dragover,
.drop-zone.drop-zone-drag {
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.12);
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.2);
}

.drop-zone * {
  pointer-events: none;
}

.drop-zone label,
.drop-zone button,
.drop-zone input {
  pointer-events: auto;
}

.drop-zone-icon {
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(6, 182, 212, 0.2));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
}

.drop-zone-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.drop-zone-sub {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 16px;
}

.drop-zone-badges {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.file-format-badge {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  background: rgba(255, 255, 255, 0.05);
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
}

/* Waveform Studio Workspace */
.waveform-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.track-meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-glass);
}

.track-info-pill {
  display: flex;
  align-items: center;
  gap: 10px;
}

.track-name {
  font-weight: 700;
  font-size: 1.1rem;
}

.track-specs {
  display: flex;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.spec-item {
  background: rgba(255, 255, 255, 0.05);
  padding: 3px 8px;
  border-radius: 4px;
}

/* Full Width Waveform Canvas Area */
.waveform-view-wrapper {
  position: relative;
  background: var(--waveform-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: inset 0 2px 12px rgba(0, 0, 0, 0.8);
  height: 580px;
  width: 100%;
  user-select: none;
}

#waveformCanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
}

#overlayCanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
}

/* Waveform Scrollbar & Zoom Bar */
.waveform-scrollbar-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(10, 14, 24, 0.95);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 6px 14px;
  margin-top: 6px;
  user-select: none;
}

.waveform-scrollbar-track {
  position: relative;
  flex: 1;
  height: 12px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  cursor: pointer;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.waveform-scrollbar-thumb {
  position: absolute;
  top: 1px;
  left: 0;
  height: 10px;
  width: 100%;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-cyan));
  border-radius: 5px;
  cursor: grab;
  transition: background 0.15s, box-shadow 0.15s;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

.waveform-scrollbar-thumb:hover,
.waveform-scrollbar-thumb.active {
  background: linear-gradient(90deg, #818cf8, #38bdf8);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
  cursor: grabbing;
}

.waveform-zoom-bar {
  display: flex;
  align-items: center;
  gap: 6px;
}

.zoom-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-main);
  width: 26px;
  height: 26px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.zoom-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

.zoom-btn-reset {
  font-size: 0.85rem;
}

.zoom-badge {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent-cyan);
  min-width: 44px;
  text-align: center;
  background: rgba(6, 182, 212, 0.12);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid rgba(6, 182, 212, 0.25);
}

/* Merger Track Scrollbar */
.merger-track-scrollbar-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 6px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 4px;
  margin-top: 4px;
}

.merger-track-scrollbar-track {
  position: relative;
  flex: 1;
  height: 8px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  cursor: pointer;
  overflow: hidden;
}

.merger-track-scrollbar-thumb {
  position: absolute;
  top: 1px;
  left: 0;
  height: 6px;
  width: 100%;
  background: var(--accent-cyan);
  border-radius: 3px;
  cursor: grab;
}

.merger-track-scrollbar-thumb.active {
  cursor: grabbing;
  background: #38bdf8;
}

.merger-zoom-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

/* Transport Controls & Time Display */
.transport-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding: 12px 18px;
  background: rgba(10, 14, 24, 0.85);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
}

.time-display-group {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-family: var(--font-mono);
}

.time-current {
  font-size: 1.6rem;
  font-weight: 700;
  color: #38bdf8;
  letter-spacing: -0.02em;
  text-shadow: 0 0 15px rgba(56, 189, 248, 0.4);
}

.time-total {
  font-size: 1.05rem;
  color: var(--text-dim);
}

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

.play-main-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #06b6d4);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(99, 102, 241, 0.45);
  transition: all 0.2s ease;
}

.play-main-btn:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 22px rgba(6, 182, 212, 0.55);
}

.control-circle-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.control-circle-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #38bdf8;
}

.control-circle-btn.active {
  background: rgba(99, 102, 241, 0.3);
  border-color: var(--accent-primary);
  color: #ffffff;
}

/* Selection Toolbar */
.selection-toolbar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
  padding: 10px 14px;
  background: rgba(10, 14, 24, 0.5);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
}

.time-input-box {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.time-input-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
}

.time-input-row {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
}

.time-input-row input {
  width: 100%;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
}

.time-input-row .btn-set {
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  padding: 2px;
}
.time-input-row .btn-set:hover {
  color: var(--accent-cyan);
}

/* Audio Action Buttons */
.audio-action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.fade-control-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(10, 14, 24, 0.7);
  border: 1px solid var(--border-glass);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.fade-control-pill:hover {
  border-color: rgba(56, 189, 248, 0.4);
  background: rgba(15, 23, 42, 0.85);
}

.fade-num-input {
  width: 50px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-glass);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.78rem;
  padding: 3px 4px;
  border-radius: 4px;
  text-align: center;
  outline: none;
  transition: border-color 0.15s ease;
}

.fade-num-input:focus {
  border-color: var(--accent-cyan);
}

.fade-num-in {
  color: #10b981;
}

.fade-num-out {
  color: #f43f5e;
}

.fade-unit {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* Studio Bottom Rack (Visualizer + Effects Full Width Strip) */
.studio-bottom-rack {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 16px;
  width: 100%;
}

@media (max-width: 1024px) {
  .studio-bottom-rack {
    grid-template-columns: 1fr;
  }
}

.visualizer-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.visualizer-wrapper {
  position: relative;
  flex: 1;
  min-height: 130px;
  background: #070912;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

#visualizerCanvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* Horizontal Effects Channel Strip */
.effects-horizontal-rack {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}

.effect-card {
  background: rgba(10, 14, 24, 0.65);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 12px;
}

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

.effect-name {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
}

.effect-val-pill {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent-cyan);
}

/* Sliders */
.slider-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 8px;
}

.slider-group:last-child {
  margin-bottom: 0;
}

.slider-label-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.74rem;
  color: var(--text-dim);
}

.studio-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.12);
  outline: none;
  cursor: pointer;
  transition: background 0.15s ease;
}

.studio-slider:hover {
  background: rgba(255, 255, 255, 0.22);
}

.studio-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid var(--accent-primary);
  box-shadow: 0 0 8px rgba(99, 102, 241, 0.65);
  cursor: pointer;
  transition: transform 0.1s ease, box-shadow 0.15s ease;
}

.studio-slider::-webkit-slider-thumb:hover {
  transform: scale(1.25);
  box-shadow: 0 0 12px rgba(6, 182, 212, 0.9);
}

.studio-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid var(--accent-primary);
  box-shadow: 0 0 8px rgba(99, 102, 241, 0.65);
  cursor: pointer;
  transition: transform 0.1s ease, box-shadow 0.15s ease;
}

.studio-slider::-moz-range-thumb:hover {
  transform: scale(1.25);
  box-shadow: 0 0 12px rgba(6, 182, 212, 0.9);
}

/* EQ */
.eq-bars-container {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  margin-top: 6px;
}

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

.eq-slider {
  writing-mode: bt-lr;
  -webkit-appearance: slider-vertical;
  width: 12px;
  height: 70px;
  padding: 0 3px;
}

.eq-band-label {
  font-size: 0.65rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
}

.eq-presets-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 8px;
}

.preset-chip {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  padding: 2px 7px;
  border-radius: 10px;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
}

.preset-chip:hover {
  background: rgba(99, 102, 241, 0.25);
  color: #ffffff;
}

/* Merger View */
.merger-section {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.merger-tracks-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.merger-track-card {
  display: flex;
  flex-direction: column;
  background: rgba(10, 14, 24, 0.75);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  width: 100%;
  transition: all 0.2s ease;
}

.merger-track-card:hover {
  border-color: rgba(99, 102, 241, 0.4);
}

.track-order-badge {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.2);
  border: 1px solid rgba(99, 102, 241, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.78rem;
  color: #a5b4fc;
}

.merger-track-title {
  font-weight: 700;
  font-size: 0.95rem;
}

.merger-track-meta {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

/* Merger Transition Connector between cards */
.merger-transition-connector {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin: 6px 0;
  z-index: 5;
  user-select: none;
  width: 100%;
}

.merger-transition-line {
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(56, 189, 248, 0.7), transparent);
}

.merger-transition-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 20px;
  background: #0b1120;
  border: 1.5px solid #38bdf8;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6), 0 0 16px rgba(56, 189, 248, 0.35);
  font-size: 0.8rem;
  font-weight: 600;
  color: #f8fafc;
  backdrop-filter: blur(8px);
  transition: all 0.2s ease;
}

.merger-transition-badge:hover {
  border-color: #67e8f9;
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.5);
  transform: scale(1.02);
}

.merger-mode-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 13px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid var(--border-glass);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  transition: all 0.2s ease;
  user-select: none;
}

.merger-mode-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.merger-mode-pill.active {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.2), rgba(99, 102, 241, 0.25));
  border-color: rgba(56, 189, 248, 0.6);
  color: #38bdf8;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.25);
}

.merger-add-track-card {
  border: 2px dashed rgba(56, 189, 248, 0.35);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  text-align: center;
  cursor: pointer;
  background: rgba(56, 189, 248, 0.03);
  transition: all 0.2s ease;
  user-select: none;
  width: 100%;
}

.merger-add-track-card:hover {
  border-color: rgba(56, 189, 248, 0.75);
  background: rgba(56, 189, 248, 0.08);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.merger-add-track-card.dragover {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.16);
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.35);
}


/* Modal */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.modal-backdrop.active {
  opacity: 1 !important;
  pointer-events: auto !important;
  display: flex !important;
}

.modal-card {
  background: #101424;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-xl);
  padding: 24px 28px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.9), 0 0 40px rgba(99, 102, 241, 0.25);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.modal-title {
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-close-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
}

.export-options-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}

.option-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.option-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
}

.radio-pills {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.radio-pill-label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  font-size: 0.85rem;
}

.radio-pill-label.checked {
  background: rgba(99, 102, 241, 0.25);
  border-color: var(--accent-primary);
  color: #ffffff;
}

.progress-container {
  display: none;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.progress-bar-bg {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #6366f1, #06b6d4);
  border-radius: 3px;
}

.progress-status-text {
  font-size: 0.78rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  text-align: center;
}

/* Toast */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 2000;
  pointer-events: none;
}

.toast {
  background: #1a2034;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  padding: 10px 16px;
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
  pointer-events: auto;
}

.toast-success {
  border-left: 4px solid var(--accent-emerald);
}
.toast-error {
  border-left: 4px solid var(--accent-rose);
}
.toast-info {
  border-left: 4px solid var(--accent-cyan);
}

/* Vocal Splitter Section Styles */
.vocal-splitter-section {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.stems-view-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.stem-card {
  transition: all 0.2s ease;
}

.stem-card:hover {
  border-color: rgba(99, 102, 241, 0.4);
}

.stem-waveform-wrapper {
  transition: border-color 0.2s ease;
}

.stem-waveform-wrapper:hover {
  border-color: rgba(255, 255, 255, 0.3) !important;
}

/* Spinner */
.loading-spinner {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(56, 189, 248, 0.2);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ====================================================================
   4-STEM INSTRUMENT SPLITTER STYLES
   ==================================================================== */
.stem-splitter-layout {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.stem-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 4px;
}

.stem-transport-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  flex-wrap: wrap;
  background: rgba(18, 23, 38, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.stem-lanes-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.stem-lane {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: all 0.18s ease;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(14, 18, 32, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.stem-lane:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(20, 26, 46, 0.82);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
}

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

.stem-lane-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.stem-lane-badge {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 5px;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.stem-lane-title {
  font-weight: 700;
  font-size: 0.88rem;
  color: #f8fafc;
  line-height: 1.2;
}

.stem-lane-controls {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.stem-btn-sm {
  width: 26px;
  height: 26px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.stem-btn-sm:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.stem-btn-sm.active-solo {
  background: #f59e0b !important;
  color: #000000 !important;
  border-color: #f59e0b !important;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.55);
}

.stem-btn-sm.active-mute {
  background: #f43f5e !important;
  color: #ffffff !important;
  border-color: #f43f5e !important;
  box-shadow: 0 0 10px rgba(244, 63, 94, 0.55);
}

.stem-fader-group {
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(0, 0, 0, 0.35);
  padding: 3px 7px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.stem-gain-val {
  font-size: 0.7rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  min-width: 30px;
  text-align: right;
}

.stem-slider {
  width: 70px !important;
  margin: 0 !important;
}

.stem-waveform-box {
  position: relative;
  width: 100%;
  height: 56px;
  background: #05070d;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  transition: border-color 0.18s ease;
}

.stem-waveform-box:hover {
  border-color: rgba(255, 255, 255, 0.22);
}

.stem-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.stem-overlay-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* A/B Comparison Toggle Active State */
.active-ab {
  background: var(--accent-cyan) !important;
  color: #080a10 !important;
  border-color: var(--accent-cyan) !important;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.5) !important;
}

/* ====================================================================
   YOUTUBE DOWNLOADER & INTEGRATION MODULE STYLES
   ==================================================================== */
.youtube-module-wrapper {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.youtube-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: var(--radius-md);
  padding: 14px 18px;
}

.youtube-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.youtube-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.youtube-backend-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  color: var(--text-muted);
}

.youtube-input-card {
  background: rgba(10, 14, 24, 0.85);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.youtube-search-group {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 0, 0, 0.5);
  border: 1.5px solid var(--border-glass);
  border-radius: var(--radius-sm);
  padding: 4px 8px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.youtube-search-group:focus-within {
  border-color: #ef4444;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.25);
}

.youtube-icon-addon {
  color: #ef4444;
  display: flex;
  align-items: center;
  padding: 0 4px;
}

.youtube-url-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: 0.92rem;
  padding: 6px 4px;
  font-family: inherit;
}

.youtube-url-input::placeholder {
  color: var(--text-dim);
  font-size: 0.86rem;
}

.yt-btn-inline {
  white-space: nowrap;
}

.youtube-hints {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.76rem;
}

.hint-label {
  color: var(--text-dim);
  font-weight: 600;
}

.hint-chip {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--accent-cyan);
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.hint-chip:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: var(--accent-cyan);
}

.youtube-loading-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  background: rgba(10, 14, 24, 0.6);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  text-align: center;
}

.youtube-result-card {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 24px rgba(239, 68, 68, 0.12);
}

.youtube-card-layout {
  display: flex;
  align-items: stretch;
  gap: 18px;
}

.youtube-thumb-wrapper {
  position: relative;
  width: 210px;
  height: 122px;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.12);
  flex-shrink: 0;
  align-self: center;
}

.youtube-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.youtube-duration-tag {
  position: absolute;
  bottom: 6px;
  right: 6px;
  background: rgba(0, 0, 0, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
}

.youtube-info-col {
  flex: 1;
  min-width: 250px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
}

.youtube-uploader-badge {
  font-size: 0.76rem;
  font-weight: 600;
  color: #38bdf8;
  display: flex;
  align-items: center;
  gap: 6px;
}

.youtube-video-title {
  font-size: 1.08rem;
  font-weight: 700;
  color: #f8fafc;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.youtube-format-switch-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 2px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.format-toggle-group {
  display: inline-flex;
  background: rgba(0, 0, 0, 0.4);
  padding: 3px;
  border-radius: 20px;
  border: 1px solid var(--border-glass);
}

.format-toggle-btn {
  padding: 4px 12px;
  border-radius: 16px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.format-toggle-btn.active {
  background: linear-gradient(135deg, #ef4444, #f97316);
  color: #fff;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.4);
}

.quality-selector-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.quality-label {
  font-size: 0.78rem;
  color: var(--text-dim);
  font-weight: 600;
}

.quality-pill {
  padding: 3px 9px;
  border-radius: 12px;
  border: 1px solid var(--border-glass);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.quality-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

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

/* Right Actions Column - Vertical stack */
.youtube-actions-col {
  width: 220px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding-left: 18px;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
}

.yt-col-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 6px;
  white-space: nowrap;
  transition: all 0.18s ease;
}

.yt-col-btn-primary {
  padding: 9px 12px;
  font-size: 0.82rem;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}

.yt-col-btn-primary:hover:not(:disabled) {
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.4);
  transform: translateY(-1px);
}

.youtube-progress-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.76rem;
  color: var(--accent-cyan);
  margin-top: 4px;
}

.spinner-sm {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(56, 189, 248, 0.2);
  border-top-color: #38bdf8;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: inline-block;
}

@media (max-width: 900px) {
  .youtube-card-layout {
    flex-direction: column;
  }
  .youtube-actions-col {
    width: 100%;
    border-left: none;
    padding-left: 0;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
}

@media (max-width: 520px) {
  .youtube-actions-col {
    grid-template-columns: 1fr;
  }
  .youtube-thumb-wrapper {
    width: 100%;
    height: 180px;
  }
}

/* ====================================================================
   YOUTUBE PLAYLIST & BATCH DOWNLOAD STYLES
   ==================================================================== */

.youtube-playlist-card {
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 24px rgba(239, 68, 68, 0.12);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.youtube-playlist-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.playlist-info-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 260px;
}

.playlist-tag-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.74rem;
  font-weight: 700;
  color: #ef4444;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.playlist-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #f8fafc;
  margin: 0;
  line-height: 1.3;
}

.playlist-stats-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.playlist-batch-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  background: rgba(0, 0, 0, 0.35);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.playlist-select-all {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  user-select: none;
}

.playlist-select-all input[type="checkbox"] {
  accent-color: var(--accent-cyan);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.playlist-batch-progress {
  background: rgba(0, 0, 0, 0.4);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  border: 1px solid rgba(56, 189, 248, 0.3);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.progress-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-cyan), #10b981);
  transition: width 0.25s ease;
  border-radius: 4px;
}

/* Playlist Scrollable Items List */
.youtube-playlist-items {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 520px;
  overflow-y: auto;
  padding-right: 4px;
}

.youtube-playlist-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
}

.youtube-playlist-item:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.12);
}

.playlist-item-check {
  accent-color: var(--accent-cyan);
  width: 16px;
  height: 16px;
  cursor: pointer;
  flex-shrink: 0;
}

.playlist-item-idx {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-dim);
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}

.playlist-item-thumb-box {
  position: relative;
  width: 76px;
  height: 44px;
  border-radius: 4px;
  overflow: hidden;
  background: #000;
  flex-shrink: 0;
}

.playlist-item-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.playlist-item-duration {
  position: absolute;
  bottom: 2px;
  right: 2px;
  background: rgba(0, 0, 0, 0.85);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 700;
  padding: 1px 4px;
  border-radius: 2px;
}

.playlist-item-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.playlist-item-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: #f1f5f9;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-item-artist {
  font-size: 0.74rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-item-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-playlist-action {
  padding: 5px 8px;
  font-size: 0.72rem;
  font-weight: 600;
  border-radius: 4px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* ====================================================================
   CREATIVE SUITE: SMART TOOLS, LYRICS & AUDIOGRAM STYLES
   ==================================================================== */
.spec-bpm, .spec-key {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: all 0.2s ease;
}

.spec-bpm:hover {
  filter: brightness(1.25);
  box-shadow: 0 0 10px rgba(0, 242, 254, 0.4);
}

.lyric-row:hover {
  background: rgba(255, 255, 255, 0.08) !important;
}

.ag-format-btn:hover, .ag-theme-btn:hover, .ag-viz-btn:hover {
  filter: brightness(1.2);
}

.smart-tools-dialog, .lyrics-dialog, .audiogram-dialog, .server-modal-card {
  animation: modalSlideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* AI Server Status Button & Modal */
.server-status-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.2s ease;
}

.server-status-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.22);
}

.server-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.server-status-dot.online {
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.server-status-dot.offline {
  background: #f43f5e;
  box-shadow: 0 0 6px #f43f5e;
}

.server-status-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid;
}

.server-status-banner.status-ok {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.3);
}

.server-status-banner.status-err {
  background: rgba(244, 63, 94, 0.08);
  border-color: rgba(244, 63, 94, 0.25);
}

.status-indicator-circle {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex-shrink: 0;
}

.pulse-green {
  background: #10b981;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulseGreen 2s infinite;
}

@keyframes pulseGreen {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.pulse-red {
  background: #f43f5e;
  box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.7);
  animation: pulseRed 2.5s infinite;
}

@keyframes pulseRed {
  0% { box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.7); }
  70% { box-shadow: 0 0 0 8px rgba(244, 63, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(244, 63, 94, 0); }
}

.server-info-box {
  background: rgba(99, 102, 241, 0.06);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 10px;
  padding: 12px 16px;
}
