.player {
  height: 72px;
  border-radius: 10px;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 5px 10px;
  background: #181818;
  color: white;
  font-family: "Segoe UI", sans-serif;
  border-radius: 12px;
  /* max-width: 600px; */
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
  /* flex: 1; */
  padding-bottom: 20px;
}

.cover-art img {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  object-fit: cover;
}

.track-info {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
}

.track-title a {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
}

.track-artists {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
}

.track-artists a {
  color: #b3b3b3;
  text-decoration: none;
  font-size: 14px;
}

.track-artists a:not(:last-child)::after {
  content: ",";
  margin-right: 4px;
}

.controls {
  /* position: relative; */
  display: flex;
  gap: 8px;
}

.controls button {
  background: transparent;
  border: none;
  color: white;
  font-size: 20px;
  cursor: pointer;
  transition: transform 0.2s;
  padding: 5px 15px;
  max-width: 48px;
  aspect-ratio: 1/1;
}

.controls button:hover svg {
  transform: scale(1.1);
  fill: #1db954;
}

.controls .play svg {
  fill: rgb(255, 255, 255);
}

.controls .play:hover svg {
  transform: scale(1.2);
}

.controls .shuffle:hover svg {
  fill: white !important;
}

.controls .repeat:hover svg {
  fill: white;
}

.seekbar-container {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  font-size: 12px;
  width: 100%;
}

.seekbar {
  flex: 1;
  -webkit-appearance: none;
  height: 4px;
  background: #535353;
  border-radius: 5px;
  cursor: pointer;
  position: relative;
  background-image: linear-gradient(
    to right,
    #ffffff var(--progress, 0%),
    #535353 0%
  );
  /* min-width: 400px; */
}

.seekbar:hover {
  background-image: linear-gradient(
    to right,
    #1db954 var(--progress, 0%),
    #535353 0%
  );
}

.seekbar::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 10px;
  height: 10px;
  background: #fff;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s;
}

.seekbar:hover::-webkit-slider-thumb {
  opacity: 1;
}

.seekbar::-moz-range-thumb {
  width: 10px;
  height: 10px;
  background: #fff;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s;
}

.seekbar:hover::-moz-range-thumb {
  opacity: 1;
}
.seekbar-track {
  display: flex;
  align-items: center;
  width: 100%;
}

@media (max-width: 768px) {
  .track-info {
    display: none;
  }
}

.volume-control {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  left: 0;
  bottom: 22px;
}

.volume-btn {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: white;
  transition: transform 0.2s ease;
  padding: 5px 0 !important;
}

.volume-btn:hover {
  transform: scale(1.2);
}

.volume-slider {
  -webkit-appearance: none;
  width: 100px;
  height: 4px;
  border-radius: 5px;
  outline: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  height: 12px;
  width: 12px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 3px rgba(0, 0, 0, 0.6);
  transition: transform 0.2s ease;
  /* margin-top: -5px; */
}

.volume-slider::-webkit-slider-thumb:hover {
  transform: scale(1.3);
}

.volume-slider::-moz-range-thumb {
  height: 14px;
  width: 14px;
  background: white;
  border-radius: 50%;
  border: none;
  cursor: pointer;
}

.volume-slider::-moz-range-track {
  background: transparent;
}

@container player (max-width: 555px) {
  .volume-slider {
    width: 0;
  }
  .volume-slider::-webkit-slider-thumb {
    display: none;
  }
  .volume-control {
    background-color: #181818;
  }
  .volume-control:hover .volume-slider {
    width: 100px !important;
  }
  .volume-control:hover .volume-slider::-webkit-slider-thumb {
    display: block;
  }
}
