* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  background: #0A0A0C;
  overflow-x: hidden;
}

::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.1);
  border-radius: 3px;
}

.glass {
  background: rgba(30, 30, 38, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.glass-light {
  background: rgba(42, 42, 50, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.drop-zone {
  border: 2px dashed rgba(255, 255, 255, 0.15);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.drop-zone:hover,
.drop-zone.drag-over {
  border-color: #007AFF;
  background: rgba(0, 122, 255, 0.05);
  transform: scale(1.005);
}

.waveform-container {
  position: relative;
  cursor: crosshair;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
}

.handle {
  position: absolute;
  top: 0;
  width: 14px;
  height: 100%;
  cursor: ew-resize;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
}

.handle::before {
  content: '';
  width: 2px;
  height: 100%;
  background: #fff;
  border-radius: 1px;
  box-shadow: 0 0 8px rgba(255,255,255,0.4);
}

.handle-knob {
  position: absolute;
  width: 20px;
  height: 32px;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.5);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.handle-knob::after {
  content: '';
  width: 4px;
  height: 14px;
  border-left: 1px solid rgba(0,0,0,0.2);
  border-right: 1px solid rgba(0,0,0,0.2);
}

.playhead {
  position: absolute;
  top: 0;
  width: 2px;
  height: 100%;
  background: #FF6961;
  z-index: 15;
  pointer-events: none;
  box-shadow: 0 0 6px rgba(255, 105, 97, 0.6);
  transition: left 0.05s linear;
}

.playhead::before {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  width: 10px;
  height: 10px;
  background: #FF6961;
  border-radius: 50%;
}

.btn-primary {
  background: #007AFF;
  transition: all 0.2s ease;
}
.btn-primary:hover {
  background: #0066D6;
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(0, 122, 255, 0.3);
}
.btn-primary:active {
  transform: translateY(0);
}

.btn-glass {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.2s ease;
}
.btn-glass:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.2);
}
.btn-glass:active {
  background: rgba(255, 255, 255, 0.06);
}

.pill-btn {
  transition: all 0.2s ease;
}
.pill-btn:hover {
  transform: translateY(-1px);
}
.pill-btn.active {
  background: rgba(0, 122, 255, 0.2) !important;
  border-color: #007AFF !important;
  color: #007AFF !important;
}

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  cursor: pointer;
}
input[type="range"]::-webkit-slider-track {
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.1);
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  margin-top: -6px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}
input[type="range"]::-moz-range-track {
  height: 4px;
  border-radius: 2px;
  background: rgba(255,255,255,0.1);
}
input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: none;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

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

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.animate-in {
  animation: fadeInUp 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.animate-pulse-soft {
  animation: pulse 2s ease-in-out infinite;
}

.selection-overlay {
  position: absolute;
  top: 0;
  height: 100%;
  background: linear-gradient(135deg, rgba(175, 82, 222, 0.15), rgba(90, 200, 250, 0.15));
  border-left: none;
  border-right: none;
  pointer-events: none;
  z-index: 5;
}

.bg-noise {
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
}