:root {
  --primary-purple: #7c3aed;
  --primary-cyan: #06b6d4;
  --primary-purple-rgb: 124, 58, 237;
  --primary-cyan-rgb: 6, 182, 212;
  --dark-900: #071427;
  --dark-800: #0b1220;
  --dark-700: #0f1a2e;
  --dark-600: #1a243a;
  --dark-500: #2a3655;
  --text-primary: #fff;
  --text-secondary: #9fb0c8;
  --text-muted: #6b7b95;
  --text-disabled: #4a5568;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --border-light: rgba(255, 255, 255, 0.1);
  --border-medium: rgba(255, 255, 255, 0.15);
  --border-heavy: rgba(255, 255, 255, 0.2);
  --shadow-soft: 0 4px 20px rgba(2, 6, 23, 0.4);
  --shadow-medium: 0 8px 30px rgba(2, 6, 23, 0.6);
  --shadow-heavy: 0 12px 40px rgba(2, 6, 23, 0.8);
  --gradient-primary: linear-gradient(135deg, var(--primary-purple), var(--primary-cyan));
  --gradient-primary-hover: linear-gradient(135deg, #8b5cf6, #22d3ee);
  --gradient-dark: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: 
    radial-gradient(1000px 360px at 8% 8%, rgba(var(--primary-purple-rgb), 0.04), transparent 8%),
    radial-gradient(800px 240px at 92% 92%, rgba(var(--primary-cyan-rgb), 0.03), transparent 8%),
    linear-gradient(180deg, #020417 0%, var(--dark-900) 50%, #020417 100%);
  color: white !important;
  min-height: 100vh;
  padding-top: 70px;
  overflow-x: hidden;
  line-height: 1.6;
}

/* Enhanced Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    width: 100%;
    box-sizing: border-box;
}

 .main-content {
    width: 100%;
    max-width: 100%;
}

/* Enhanced Hero Section */
.hero {
  text-align: center;
  margin-bottom: 4rem;
  padding: 0 1rem;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 900;
  margin-bottom: 1.5rem;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.hero p {
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.7;
  font-weight: 400;
}

/* Fix Grid Layout */
.grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
}

@media (min-width: 1024px) {
    .grid {
        grid-template-columns: 350px minmax(0, 1fr) 350px;
        gap: 1.5rem;
        max-width: 1400px;
    }
}

/* Ensure all grid items stay within bounds */
.sidebar-left,
.main-content,
.sidebar-right {
    width: 100%;
    min-width: 0; /* Critical: prevents overflow */
}

/* Specific sidebar fixes */
.sidebar-right {
    position: relative;
    right: 0;
}

/* Prevent content from pushing sidebar away */
.main-content {
    min-width: 0;
    overflow: hidden;
}

/* Card content should not overflow */
.card {
    max-width: 100%;
    overflow: hidden;
}

.card-body {
    max-width: 100%;
    overflow: hidden;
}

/* Enhanced Card Styles */
.card {
  background: var(--gradient-dark);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  margin-top:7px;
  box-shadow: var(--shadow-medium);
  backdrop-filter: blur(20px);
  overflow: hidden;
  transition: all 0.3s ease;
  position: relative;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.card:hover::before {
  opacity: 1;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-heavy);
  border-color: var(--border-medium);
}

.card-header {
  padding: 1.75rem 1.75rem 1.25rem;
  border-bottom: 1px solid var(--border-light);
  background: rgba(255, 255, 255, 0.02);
}

.card-title {
  font-size: 1.3rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.875rem;
  color: var(--text-primary);
}

.card-title i {
  color: var(--primary-purple);
  font-size: 1.1em;
  width: 24px;
  text-align: center;
}

.card-body {
  padding: 1.75rem;
}

/* Enhanced Button Styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  padding: 0.875rem 1.75rem;
  border-radius: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  font-family: inherit;
  font-size: 0.95rem;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
  transition: left 0.6s ease;
}

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 4px 15px rgba(var(--primary-purple-rgb), 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(var(--primary-purple-rgb), 0.5);
  background: var(--gradient-primary-hover);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: translateY(-2px);
  border-color: var(--primary-purple);
  box-shadow: 0 4px 15px rgba(var(--primary-purple-rgb), 0.2);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-heavy);
  backdrop-filter: blur(10px);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--primary-purple);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(var(--primary-purple-rgb), 0.15);
}

.btn-full {
  width: 100%;
}

.btn-sm {
  padding: 0.625rem 1.25rem;
  font-size: 0.875rem;
  border-radius: 12px;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* Enhanced Input Styles */
.input-group {
  margin-bottom: 1.5rem;
}

.input-label {
  display: block;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.input-field {
  width: 100%;
  padding: 0.875rem 1.25rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid var(--border-light);
  border-radius: 14px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.input-field:focus {
  outline: none;
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(var(--primary-purple-rgb), 0.15);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.input-field::placeholder {
  color: var(--text-muted);
}
    
    /* Compressor Grid Layout */
.compressor-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  width: 100%;
}

@media (min-width: 640px) {
  .compressor-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

/* Ensure input groups work properly in grid */
.compressor-grid .input-group {
  width: 100%;
  min-width: 0;
  margin-bottom: 0;
}

.compressor-grid .input-field {
  width: 100%;
  min-width: 0;
}

.compressor-grid .range-slider {
  width: 100%;
  min-width: 0;
}

/* Specific styling for number inputs in compressor */
.compressor-grid input[type="number"] {
  text-align: center;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 0.75rem;
  color: var(--text-primary);
}

.compressor-grid input[type="number"]:focus {
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.2);
}

/* Range slider labels */
.compressor-grid .input-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.compressor-grid .range-value {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary-cyan);
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
}

select.input-field {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%239fb0c8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1.25rem center;
  background-size: 1.1rem;
  padding-right: 3rem;
}

/* Enhanced Range Slider */
.range-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  outline: none;
  transition: all 0.3s ease;
}

.range-slider:hover {
  background: rgba(255, 255, 255, 0.15);
}

.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gradient-primary);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  border: 2px solid white;
  transition: all 0.2s ease;
}

.range-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 4px 12px rgba(var(--primary-purple-rgb), 0.5);
}

.range-slider::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gradient-primary);
  cursor: pointer;
  border: 2px solid white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  transition: all 0.2s ease;
}

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

.range-value {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-top: 0.75rem;
  text-align: center;
  font-weight: 600;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
}

/* Enhanced File Upload Area */
.file-upload {
  border: 2px dashed var(--border-medium);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
  margin-bottom: 1.75rem;
  background: rgba(255, 255, 255, 0.02);
  position: relative;
  overflow: hidden;
}

.file-upload::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(var(--primary-purple-rgb), 0.05), transparent);
  transition: left 0.6s ease;
}

.file-upload:hover::before {
  left: 100%;
}

.file-upload:hover {
  border-color: var(--primary-purple);
  background: rgba(var(--primary-purple-rgb), 0.03);
  transform: translateY(-2px);
}

.file-upload.dragover {
  border-color: var(--primary-purple);
  background: rgba(var(--primary-purple-rgb), 0.08);
  transform: scale(1.02);
}

.file-upload i {
  font-size: 2.5rem;
  color: var(--primary-purple);
  margin-bottom: 1.25rem;
  opacity: 0.8;
}

.file-upload p {
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  font-size: 1rem;
  font-weight: 500;
}

.file-name {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border: 1px solid var(--border-light);
}

/* Enhanced Waveform Container */
.waveform-container {
  background: var(--dark-800);
  border-radius: 16px;
  padding: 1.75rem;
  margin-bottom: 2rem;
  position: relative;
  border: 1px solid var(--border-light);
  overflow: hidden;
}

.waveform-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-primary);
  opacity: 0.7;
}

.waveform-header {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

@media (min-width: 640px) {
  .waveform-header {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

.waveform-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  text-align: center;
}

@media (min-width: 640px) {
  .waveform-title {
    text-align: left;
  }
}

.waveform-controls {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

@media (min-width: 640px) {
  .waveform-controls {
    justify-content: flex-end;
  }
}

.waveform-controls .btn {
  min-width: 80px;
  font-size: 0.85rem;
  padding: 0.75rem 1rem;
  border-radius: 12px;
}

.waveform {
  width: 100%;
  height: 140px;
  background: var(--dark-900);
  border-radius: 12px;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border-light);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.3);
}

.waveform-canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
  position: relative;
  z-index: 2;
}

.waveform-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, 
    rgba(var(--primary-purple-rgb), 0.25), 
    rgba(var(--primary-cyan-rgb), 0.25));
  pointer-events: none;
  transition: width 0.05s linear;
  z-index: 1;
  border-radius: 12px 0 0 12px;
}

.waveform-time {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  padding: 0 0.5rem;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
}

/* Enhanced EQ Bands */
.eq-bands {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
  padding: 1rem 0;
}

@media (min-width: 640px) {
  .eq-bands {
    grid-template-columns: repeat(5, 1fr);
  }
}

.eq-band {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  border: 1px solid var(--border-light);
  transition: all 0.3s ease;
}

.eq-band:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-medium);
  transform: translateY(-2px);
}

.eq-band-slider {
  height: 140px;
  margin-bottom: 0.75rem;
  position: relative;
  width: 100%;
  display: flex;
  justify-content: center;
}

.eq-band-slider input {
  width: 100%;
  height: 100%;
  writing-mode: bt-lr;
  -webkit-appearance: slider-vertical;
  cursor: pointer;
}

.eq-band-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-align: center;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.eq-band-value {
  font-size: 0.8rem;
  color: var(--text-primary);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  min-width: 50px;
  text-align: center;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
}

/* Enhanced Presets */
.presets-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.875rem;
  margin-bottom: 1.75rem;
}

.preset-chip {
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid var(--border-light);
  border-radius: 14px;
  padding: 1rem 0.75rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-size: 0.875rem;
  font-weight: 600;
  position: relative;
  overflow: hidden;
}

.preset-chip::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
  transition: left 0.6s ease;
}

.preset-chip:hover::before {
  left: 100%;
}

.preset-chip:hover {
  background: rgba(var(--primary-purple-rgb), 0.15);
  border-color: rgba(var(--primary-purple-rgb), 0.4);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(var(--primary-purple-rgb), 0.2);
}

.preset-chip.active {
  background: linear-gradient(135deg, 
    rgba(var(--primary-purple-rgb), 0.25), 
    rgba(var(--primary-cyan-rgb), 0.25));
  border: 1.5px solid rgba(var(--primary-purple-rgb), 0.6);
  color: var(--text-primary);
  box-shadow: 0 6px 20px rgba(var(--primary-purple-rgb), 0.3);
  transform: translateY(-1px);
}

/* Enhanced Visualizer */
.visualizer-container {
  background: var(--dark-800);
  border-radius: 16px;
  padding: 1.75rem;
  margin-bottom: 2rem;
  border: 1px solid var(--border-light);
  position: relative;
  overflow: hidden;
}

.visualizer-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-primary);
  opacity: 0.7;
}

.visualizer-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 120px;
    gap: 2px;
    padding: 0 8px;
    background: linear-gradient(180deg, 
        rgba(0, 0, 0, 0.3) 0%, 
        transparent 20%, 
        transparent 80%, 
        rgba(0, 0, 0, 0.3) 100%);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.visualizer-bar {
    flex: 1;
    border-radius: 2px 2px 0 0;
    min-height: 2px;
    transition: height 0.1s ease, background-color 0.3s ease, box-shadow 0.2s ease;
    background: linear-gradient(to top, var(--primary-purple), var(--primary-cyan));
    transform-origin: bottom;
}

.visualizer-bar {
  flex: 1;
  background: var(--gradient-primary);
  border-radius: 3px 3px 0 0;
  min-height: 2px;
  transition: height 0.08s ease-out;
  opacity: 0.85;
  position: relative;
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.3),
    0 2px 8px rgba(0,0,0,0.2);
}

.visualizer-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(180deg, rgba(255,255,255,0.4), transparent);
  border-radius: 3px 3px 0 0;
}

/* Enhanced Progress Bar */
.progress22 {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin: 1.25rem 0;
  position: relative;
}

.progress22::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, 
    transparent 0%, 
    rgba(255,255,255,0.1) 50%, 
    transparent 100%);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.progress-bar {
  height: 100%;
  background: var(--gradient-primary);
  border-radius: 4px;
  transition: width 0.3s ease;
  position: relative;
  box-shadow: 0 0 20px rgba(var(--primary-purple-rgb), 0.4);
}

/* Enhanced Toast Notifications */
.toast {
  position: fixed;
  top: 100px;
  right: 2rem;
  padding: 1.25rem 1.75rem;
  background: var(--dark-800);
  border-left: 4px solid var(--primary-purple);
  border-radius: 14px;
  box-shadow: var(--shadow-heavy);
  z-index: 1001;
  transform: translateX(120%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  max-width: 380px;
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-light);
}

.toast.show {
  transform: translateX(0);
}

.toast.success {
  border-left-color: var(--success);
}

.toast.error {
  border-left-color: var(--danger);
}

.toast.warning {
  border-left-color: var(--warning);
}

.toast-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.toast-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
}

.toast.success .toast-icon { color: var(--success); }
.toast.error .toast-icon { color: var(--danger); }
.toast.warning .toast-icon { color: var(--warning); }

.toast-message {
  flex: 1;
  font-size: 0.9rem;
  line-height: 1.5;
}

/* Enhanced Toggle Switch */
.toggle {
  position: relative;
  display: inline-block;
  width: 54px;
  height: 28px;
}

.toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.15);
  transition: .4s;
  border-radius: 34px;
  border: 1px solid var(--border-medium);
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background: white;
  transition: .4s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

input:checked + .toggle-slider {
  background: var(--gradient-primary);
  border-color: transparent;
}

input:checked + .toggle-slider:before {
  transform: translateX(26px);
}

/* Enhanced Tooltip */
.tooltip {
  position: relative;
  display: inline-block;
}

.tooltip .tooltip-text {
  visibility: hidden;
  width: 220px;
  background: rgba(15, 26, 46, 0.98);
  color: var(--text-primary);
  text-align: center;
  border-radius: 12px;
  padding: 12px;
  position: absolute;
  z-index: 1002;
  bottom: 125%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-size: 0.8rem;
  border: 1px solid var(--border-medium);
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow-heavy);
  line-height: 1.5;
}

.tooltip:hover .tooltip-text {
  visibility: visible;
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Enhanced Advanced Settings */
.advanced-settings {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.advanced-settings.show {
  max-height: 500px;
}

.toggle-advanced {
  width: 100%;
  margin-top: 1.25rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid var(--border-medium);
  border-radius: 12px;
  padding: 1rem 1.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.toggle-advanced:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--primary-purple);
  transform: translateY(-1px);
}

.toggle-advanced i {
  transition: transform 0.3s ease;
}

.toggle-advanced.active i {
  transform: rotate(180deg);
}

/* Mobile Recommendation Notice */
.mobile-notice {
  display: none;
  background: linear-gradient(135deg, 
    rgba(var(--primary-purple-rgb), 0.12), 
    rgba(var(--primary-cyan-rgb), 0.08));
  border: 1px solid rgba(var(--primary-purple-rgb), 0.3);
  border-radius: 16px;
  padding: 1.25rem;
  margin: 1.5rem 0;
  backdrop-filter: blur(20px);
  animation: slideInDown 0.5s ease-out;
  position: relative;
  overflow: hidden;
}

.mobile-notice::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-primary);
}

.mobile-notice-content {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.mobile-notice i.fa-desktop {
  font-size: 1.5rem;
  color: var(--primary-purple);
  flex-shrink: 0;
}

.mobile-notice-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.mobile-notice-text strong {
  color: var(--text-primary);
  font-size: 0.95rem;
  font-weight: 700;
}

.mobile-notice-text span {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.4;
}

.mobile-notice-close {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-notice-close:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text-primary);
}

/* Show only on mobile devices */
@media (max-width: 767px) {
  .mobile-notice {
    display: block;
  }
}

/* Enhanced Animations */
@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(var(--primary-purple-rgb), 0.4);
  }
  50% {
    box-shadow: 0 0 30px rgba(var(--primary-purple-rgb), 0.8);
  }
}

.pulse-glow {
  animation: pulseGlow 2s ease-in-out infinite;
}

/* Enhanced Loading States */
.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(255,255,255,0.1), 
    transparent);
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Enhanced Focus States */
.btn:focus-visible,
.input-field:focus-visible,
.range-slider:focus-visible {
  outline: 2px solid var(--primary-purple);
  outline-offset: 2px;
}

/* Enhanced Scrollbars */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--dark-800);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: var(--dark-500);
  border-radius: 4px;
  border: 2px solid var(--dark-800);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-purple);
}

/* Print Styles */
@media print {
  .header,
  .mobile-notice,
  .btn,
  .presets-grid,
  .visualizer-container {
    display: none !important;
  }
  
  .card {
    border: 1px solid #ccc;
    box-shadow: none;
    break-inside: avoid;
  }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
  :root {
    --border-light: rgba(255, 255, 255, 0.3);
    --border-medium: rgba(255, 255, 255, 0.5);
    --border-heavy: rgba(255, 255, 255, 0.7);
  }
  
  .card {
    border-width: 2px;
  }
  
  .btn {
    border-width: 2px;
  }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}