html, body {
  background-color: black;
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  overflow-x: hidden; /* Prevent horizontal scroll */
}

#toggle-sidebar {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 20;
  background-color: #b06d37;
  border: none;
  color: white;
  padding: 10px;
  font-size: 24px;
  cursor: pointer;
}

#orange-sidebar {
  position: fixed;
  width: 5.5rem;
  height: 100%;
  background-color: #b06d37;
  border-radius: 9px;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10;
  transition: transform 0.3s ease;
}

#orange-sidebar.hidden {
  transform: translateX(-100%);
}

#profile > img {
  margin-top: 5px;
  height: 55px;
  width: 55px;
  border-radius: 50%;
}

.tags {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.tags button {
  background: none;
  border: none;
  color: black;
  padding: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  outline: none;
  margin: 5px 0;
}

/* Hover effect: background turns white */
#orange-sidebar .tags button:hover {
  background-color: white;
}

.tags button svg, .tags button img {
  fill: #ffffff;
  width: 32px;
  height: 32px;
  margin-bottom: 5px;
}
/* Change the color of the SVG icons on hover */
#orange-sidebar .tags button:not(#fav):hover svg {
  fill: black; /* This will change the SVG icon color to black */
}
/* Change the color of the images inside buttons to black on hover */
/* Change the color of the images inside buttons to black on hover, except for the trending button */
#orange-sidebar .tags button:not(#trending):hover img {
  filter: brightness(0) invert(1); /* This turns the image black for all buttons except #trending */
}
/* Prevent image color change for the trending button */
#fav:hover svg{
  fill:red;
}


.library-body {
  width: 94%;
  height: 90%;
  padding: 3%;
  display: flex;
  flex-wrap: wrap;
  overflow-y: auto;
  justify-content: space-between;
}

.playlist-card {
  position: relative;
  width: 15%;
  height: 35%;
  border-radius: 20px;
  background-color: rgb(30, 42, 62);
  border: 1px solid rgba(54, 69, 98, 0.18);
  padding: 1%;
  margin-bottom: 5.5%;
  background: rgb(30, 42, 62);
  background: linear-gradient(
    75deg,
    rgb(40, 58, 88) 0%,
    rgba(54, 69, 98, 0) 100%
  );
  transition: all 0.2s ease;
  cursor: pointer;
}

.play-button {
  position: absolute;
  top: 90%;
  left: 85%;
  transform: translate(-50%, -50%);
  background-color: rgba(255, 255, 255, 0.8);
  border: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: none;
  font-size: 24px;
  color: rgb(30, 42, 62);
  cursor: pointer;
}

.playlist-card:hover .play-button {
  display: block;
}

.playlist-card:hover {
  transform: scale(1.02);
}

.playlist-card:hover .playlist-fade {
  opacity: 1;
}

.playlist-image {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 15px;
}

.playlist-title {
  font-weight: 800;
  font-size: 16px;
  color: #c4d0e3;
  margin: 10px 0px 10px;
  display: -webkit-box;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.playlist-subtitle {
  font-weight: 400;
  font-size: 12px;
  margin: 0px;
  color: #c4d0e37c;
}

.playlist-fade {
  position: absolute;
  right: 0;
  bottom: 0;
  opacity: 0;
  width: 84%;
  height: 34%;
  border-radius: 20px;
  background: linear-gradient(
    180deg,
    rgba(54, 69, 98, 0) 10%,
    rgba(54, 69, 98, 1) 100%
  );
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 8%;
  transition: 0.5s ease;
}

.background {
  margin-left: 5.5rem;
  position: absolute;
  width: calc(100% - 5.5rem);
  height: 100%;
  background-color: #1E2A3E;
  opacity: 1;
  background-image: repeating-radial-gradient(circle at 0 0, transparent 0, #1E2A3E 40px), repeating-linear-gradient(#23365655, #233656);
  border-radius: 15px;
  padding: 20px;
  box-sizing: border-box;
  transition: margin-left 0.3s ease, width 0.3s ease;
}

.background.expanded {
  margin-left: 0;
  width: 100%;
}

.player {
  margin-top: 20px;
  width: 100%;
  max-width: 800px;
  height: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.text {
  text-align: center;
  color: white;
}

.progress-container {
  width: 100%;
  height: 20px;
  background-color: #ccc;
  border-radius: 10px;
  overflow: hidden;
  margin: 20px 0;
}

.progress-bar {
  height: 100%;
  background-color: #4CAF50;
  width: 0;
  transition: width 0.1s linear;
}

.button-container {
  display: flex;
  justify-content: center;
  gap: 15px;
}

.button-container button {
  background: none;
  border: none;
  cursor: pointer;
}

.disc {
  margin-top: 20px;
  width: 150px;
  height: 150px;
}

.album {
  margin-top: 20px;
  text-align: center;
  color: white;
}

.album img {
  width: 150px;
  height: 150px;
  border-radius: 75px;
}

.album h2,
.album h4 {
  margin: 10px 0;
}

.other {
  margin-top: 40px;
  text-align: center;
  color: white;
}

.up-next {
  margin-top: 40px;
  text-align: center;
  color: white;
}

@media (max-width: 768px) {
  .library-body {
    flex-direction: column;
    align-items: center;
  }

  .playlist-card {
    width: 90%;
    margin-bottom: 10px;
  }

  .player {
    width: 90%;
  }

  .background {
    margin-left: 0;
    width: 100%;
  }
}
