* {
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

body {
  background: #f2f2f2;
  padding: 20px;
}

.player-wrapper {
  display: flex;
  width: 100%;
  max-width: fullscreen;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 0 9px rgba(0,0,0,.3);
  overflow: hidden;
}

.artwork {
  width: 120px;
  height: 120px;
  background: #000;
}

.artwork img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.player-body {
  flex: 1;
  padding: 10px 15px;
  align-content: end;
}

.controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.controls button {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
}

.progress {
  flex: 1;
  height: 6px;
  background: #ddd;
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: #2d89ef;
}

#volume {
  width: 80px;
}

.nowplaying {
  margin-top: 8px;
  font-size: 14px;
  display: flex;
  gap: 6px;
  align-items: center;
}

.np-label {
  font-weight: bold;
}

.lyrics {
  margin-top: 6px;
  font-size: 13px;
  color: #555;
  max-height: 40px;
  overflow: hidden;
}

/* BOTÓN LETRA */
.lyrics-btn {
  margin-top: 8px;
  background: #f2f2f2;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}

.lyrics-btn:hover {
  background: #e0e0e0;
}

/* MODAL */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  inset: 0;
  background: rgba(0,0,0,.6);
}

.modal-content {
  background: #fff;
  max-width: 500px;
  margin: 8% auto;
  padding: 20px;
  border-radius: 12px;
  max-height: 70vh;
  overflow-y: auto;
}

.modal-content h3 {
  margin-bottom: 10px;
}

.close {
  float: right;
  font-size: 22px;
  cursor: pointer;
}

.np-marquee {
  position: relative;
  overflow: hidden;
  flex: 1;
}

#nowplaying {
  display: inline-block;
  white-space: nowrap;
}

@media (max-width: 768px) {
  body {
    padding: 10px;
  }

  .player-wrapper {
    max-width: 100%;
    border-radius: 8px;
  }

  .artwork {
    width: 100px;
    height: 100px;
  }
}

@media (max-width: 480px) {

  .player-wrapper {
    flex-direction: column;
    align-items: center;
    border-radius: 8px;
  }

  .artwork {
    width: 100%;
    height: auto;
  }

  .artwork img {
    height: auto;
  }

  .player-body {
    width: 100%;
    padding: 12px;
  }

  .controls {
    flex-wrap: wrap;
    justify-content: center;
  }

  .progress {
    width: 100%;
    order: 3;
  }

  .nowplaying {
    justify-content: center;
    text-align: center;
    flex-wrap: wrap;
  }

  #volume {
    width: 70px;
  }

  .np-marquee {
    width: 100%;
  }

  #nowplaying.marquee {
    animation: marquee-scroll 10s linear infinite;
  }

}

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