/* Custom styles for Suno Music Platform */

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fade-in 0.3s ease-in-out;
}

/* Smooth transitions */
* {
  transition: all 0.2s ease-in-out;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* Loading spinner */
.spinner {
  border: 3px solid #f3f3f3;
  border-top: 3px solid #4f46e5;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Audio player custom styles */
audio::-webkit-media-controls-panel {
  background-color: #f3f4f6;
}

/* Card hover effects */
.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Button pulse animation */
@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

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

/* Music waveform animation */
@keyframes wave {
  0%, 100% { height: 10px; }
  50% { height: 30px; }
}

.wave-bar {
  display: inline-block;
  width: 3px;
  height: 10px;
  margin: 0 2px;
  background: currentColor;
  animation: wave 1s ease-in-out infinite;
}

.wave-bar:nth-child(2) { animation-delay: 0.1s; }
.wave-bar:nth-child(3) { animation-delay: 0.2s; }
.wave-bar:nth-child(4) { animation-delay: 0.3s; }
.wave-bar:nth-child(5) { animation-delay: 0.4s; }

/* Gradient text */
.gradient-text {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Glass morphism effect */
.glass {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Music card grid improvements */
.music-card {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.music-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(79, 70, 229, 0.2);
}

/* Custom checkbox and radio */
input[type="checkbox"],
input[type="radio"] {
  accent-color: #4f46e5;
}

/* Tooltip */
.tooltip {
  position: relative;
}

.tooltip:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 8px;
  background: #1f2937;
  color: white;
  font-size: 12px;
  border-radius: 4px;
  white-space: nowrap;
  margin-bottom: 4px;
}

/* Progress bar */
.progress-bar {
  height: 4px;
  background: #e5e7eb;
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
  transition: width 0.3s ease;
}

/* Tag styles */
.tag {
  display: inline-block;
  padding: 4px 12px;
  background: #e0e7ff;
  color: #4338ca;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 500;
}

/* Empty state */
.empty-state {
  padding: 60px 20px;
  text-align: center;
  color: #6b7280;
}

.empty-state i {
  font-size: 64px;
  color: #d1d5db;
  margin-bottom: 16px;
}

/* Range slider (audio player controls) */
input[type="range"].slider {
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

/* Slider track */
input[type="range"].slider::-webkit-slider-track {
  background: #e5e7eb;
  height: 8px;
  border-radius: 4px;
}

input[type="range"].slider::-moz-range-track {
  background: #e5e7eb;
  height: 8px;
  border-radius: 4px;
}

/* Slider thumb */
input[type="range"].slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  background: #4f46e5;
  border-radius: 50%;
  cursor: pointer;
  margin-top: -4px;
}

input[type="range"].slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  background: #4f46e5;
  border-radius: 50%;
  cursor: pointer;
  border: none;
}

/* Slider thumb hover */
input[type="range"].slider::-webkit-slider-thumb:hover {
  background: #4338ca;
  transform: scale(1.2);
}

input[type="range"].slider::-moz-range-thumb:hover {
  background: #4338ca;
  transform: scale(1.2);
}

/* Audio player bottom spacing */
body {
  padding-bottom: 100px;
}

#audioPlayer {
  transition: transform 0.3s ease-in-out;
}

#audioPlayer.hidden {
  transform: translateY(100%);
}
