/* 🌌 Estilos generales */
html, body {
  height: 100%;
  display: flex;
  flex-direction: column;
}

body {
  font-family: 'Segoe UI', sans-serif;
  text-align: center;
  background: url("https://i.imgur.com/aEJvEQq.png") no-repeat center center fixed !important;
  background-size: cover !important;
  color: white;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  user-select: none;
  pointer-events: none; /* evita modificar el fondo */
}

/* Reactiva controles */
header, .player-section, footer {
  pointer-events: auto;
}

/* 🟥 Header */
header {
  background: linear-gradient(90deg, #ff4b4b, #ff9f45);
  color: white;
  padding: 20px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

header h1 {
  margin: 0;
  font-size: 2rem;
}

header p {
  margin: 5px 0 0;
  font-size: 1.1rem;
}

/* 💿 Sección del reproductor */
.player-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 50px;
}

/* 💽 Disco con ondas */
.disc-wrapper {
  position: relative;
  width: 320px;  /* ligeramente más grande para que entre el espectro */
  height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 🌊 Ondas animadas */
.disc-wrapper::before,
.disc-wrapper::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 220px;
  height: 220px;
  border-radius: 80%;
  transform: translate(-50%, -50%);
  border: 8px solid rgba(255, 75, 75, 0.4);
  animation: pulse 2.5s ease-out infinite;
  z-index: 0;
}

.disc-wrapper::after {
  animation-delay: 1.25s;
}

@keyframes pulse {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.8);
    opacity: 0;
  }
}

/* 💿 Imagen del disco */
.disc-wrapper img {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  z-index: 2;
}

.spinning {
  animation: spin 3s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* 🎵 Canción actual */
#currentSong {
  font-size: 1.2rem;
  background: rgba(255,255,255,0.1);
  padding: 10px 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(255,255,255,0.2);
  margin-bottom: 20px;
}

/* 🎚️ Control de volumen */
.volume-control {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #ff9f43;
  font-weight: bold;
  margin-top: 10px;
}

.volume-control label {
  font-size: 1rem;
}

#volumeSlider {
  -webkit-appearance: none;
  width: 200px;
  height: 6px;
  border-radius: 5px;
  background: linear-gradient(90deg, #ff4b4b 80%, #555 80%);
  outline: none;
  cursor: pointer;
  transition: background 0.3s;
}

#volumeSlider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #ff4b4b;
  transition: transform 0.2s;
}

#volumeSlider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

/* 📊 Visualizador */
#audioVisualizer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none; /* no bloquea clics */
}

/* 📌 Footer */
footer {
  background: #181818;
  padding: 15px;
  font-size: 0.9rem;
  color: #ccc;
  text-align: center;
  margin-top: auto;
  width: 100%;
}
