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

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Courier New", Courier, monospace;
  background: radial-gradient(circle at 50% 30%, #2a1a3e 0%, #120a1f 70%);
  padding: 1rem;
  overflow-x: hidden;
}

/* --- Canvas de fondo (efecto animado) --- */
#bg {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;   /* no interfiere con los clics */
}

.player {
  position: relative;
  z-index: 1;             /* el reproductor queda por encima del canvas */
  width: 100%;
  max-width: 720px;
  background: rgba(18, 10, 31, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.cover {
  width: 100%;
  aspect-ratio: 1800 / 1029;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 1.5rem;
  filter: saturate(1.1) contrast(1.05);
}

/* --- Controles: botón (solo icono) + barra de tiempo --- */
.player-controls {
  --btn-w: 34px;
  --row-gap: 0.85rem;
}

.progress-row {
  display: flex;
  align-items: center;   /* alinea el icono con la LÍNEA de la barra */
  gap: var(--row-gap);
}

.seek {
  flex: 1;           /* la barra ocupa todo el espacio que deja el botón */
  min-width: 0;
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  border-radius: 999px;
  cursor: pointer;
  outline: none;
  background: linear-gradient(to right,
    #ff7eb3 0%,
    #b14aff var(--progress, 0%),
    rgba(255, 255, 255, 0.15) var(--progress, 0%),
    rgba(255, 255, 255, 0.15) 100%);
}

/* Selector (thumb) en Chrome/Safari/Edge */
.seek::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffd86b;
  border: 2px solid #fff;
  box-shadow: 0 0 10px rgba(255, 216, 107, 0.7);
  cursor: pointer;
}

/* Selector en Firefox */
.seek::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffd86b;
  border: 2px solid #fff;
  box-shadow: 0 0 10px rgba(255, 216, 107, 0.7);
  cursor: pointer;
}

/* Tiempos: indentados para quedar justo bajo la barra (no bajo el botón) */
.time-row {
  display: flex;
  justify-content: space-between;
  margin-top: 0.6rem;
  padding-left: calc(var(--btn-w) + var(--row-gap));
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.85rem;
  letter-spacing: 1px;
}

/* --- Botón: SOLO el icono, sin círculo --- */
.btn {
  flex-shrink: 0;
  width: var(--btn-w);       /* ancho fijo para no moverse al cambiar ▶ / ⏸ */
  background: none;
  border: none;
  padding: 0;
  line-height: 1;
  font-size: 1.7rem;
  color: #ffd86b;            /* dorado, combina con el selector de la barra */
  cursor: pointer;
  transition: color 0.2s ease, transform 0.12s ease;
}

.btn:hover {
  color: #ffffff;
}

.btn:active {
  transform: scale(0.9);
}

.btn:focus-visible {
  outline: 2px solid #ffd86b;
  outline-offset: 4px;
  border-radius: 4px;
}

/* --- Texto inferior con enlaces --- */
.footer-text {
  margin-top: 1.5rem;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.85rem;
  letter-spacing: 0.5px;
}

.footer-text a {
  color: #ffd86b;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-text a:hover {
  text-decoration: underline;
}
