/*--------------------------------------*\
  AUDIO PLAYER COMPONENT - PHASE 3
\*--------------------------------------*/

/* Player container */
.audio-player-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 300px;
  background-color: white;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  padding: 15px;
  z-index: 1000;
  transition: all 0.3s ease;
  overflow: hidden;
}

.audio-player-container.minimized {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  padding: 0;
}

.audio-player-container.minimized .audio-controls,
.audio-player-container.minimized .song-info,
.audio-player-container.minimized .progress-container {
  display: none;
}

.audio-player-container.minimized .toggle-player {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bga-green);
  border-radius: 50%;
  color: white;
  cursor: pointer;
}

/* Song info */
.song-info {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.song-thumbnail {
  width: 50px;
  height: 50px;
  border-radius: 5px;
  margin-right: 10px;
  object-fit: cover;
}

.song-details {
  flex: 1;
}

.song-title {
  font-weight: 600;
  font-size: 14px;
  margin: 0 0 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-artist {
  font-size: 12px;
  color: var(--bga-gray);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Progress bar */
.progress-container {
  margin-bottom: 10px;
}

.progress-bar {
  height: 4px;
  background-color: #e0e0e0;
  border-radius: 2px;
  cursor: pointer;
  position: relative;
}

.progress {
  height: 100%;
  background-color: var(--bga-green);
  border-radius: 2px;
  width: 0;
  transition: width 0.1s linear;
}

.progress-dot {
  position: absolute;
  top: 50%;
  left: 0;
  width: 10px;
  height: 10px;
  background-color: var(--bga-green);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.2s;
}

.progress-bar:hover .progress-dot {
  opacity: 1;
}

.time-display {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--bga-gray);
  margin-top: 5px;
}

/* Controls */
.audio-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.control-buttons {
  display: flex;
  gap: 10px;
}

.audio-control {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: none;
  background-color: transparent;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--bga-gray-dark);
}

.audio-control:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: var(--bga-green);
}

.audio-control.play-pause {
  background-color: var(--bga-green);
  color: white;
}

.audio-control.play-pause:hover {
  background-color: var(--bga-green-dark);
  transform: scale(1.05);
}

.volume-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.volume-slider {
  width: 60px;
  height: 4px;
  background-color: #e0e0e0;
  border-radius: 2px;
  cursor: pointer;
  position: relative;
}

.volume-level {
  height: 100%;
  background-color: var(--bga-green);
  border-radius: 2px;
  width: 70%;
}

.volume-dot {
  position: absolute;
  top: 50%;
  left: 70%;
  width: 8px;
  height: 8px;
  background-color: var(--bga-green);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.2s;
}

.volume-slider:hover .volume-dot {
  opacity: 1;
}

/* Additional Player Elements */
.toggle-player {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 14px;
  color: var(--bga-gray);
  cursor: pointer;
  transition: color 0.2s;
}

.toggle-player:hover {
  color: var(--bga-dark);
}

.visualizer {
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  margin-top: 10px;
  margin-bottom: 5px;
}

.visualizer-bar {
  width: 4px;
  background-color: var(--bga-green);
  border-radius: 2px;
  transition: height 0.2s ease;
}

/* Mobile responsive design */
@media (max-width: 767.98px) {
  .audio-player-container {
    bottom: 10px;
    right: 10px;
    width: 250px;
  }
}

@media (max-width: 575.98px) {
  .audio-player-container {
    bottom: 0;
    right: 0;
    width: 100%;
    border-radius: 10px 10px 0 0;
  }
  
  .audio-player-container.minimized {
    bottom: 10px;
    right: 10px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
  }
}