* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Courier New', Courier, monospace;
  user-select: none;
}

/* Hide scrollbar for Chrome, Safari and Opera */
*::-webkit-scrollbar {
  display: none;
}

/* Hide scrollbar for IE, Edge and Firefox */
* {
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

body {
  width: 100%;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgb(201, 92, 92);
}

.music-player {
  position: relative;
  border: 4px solid black;
  border-radius: 16px;
  box-shadow: 0 0 12px gray;
  width: 100%;
  max-width: 350px;
  height: 100%;
  max-height: 600px;
  padding: 15px;
  overflow: hidden;
}

.bg-image {
  position: absolute;
  z-index: 1;
  width: 105%;
  height: 105%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  filter: blur(5px);
}

.header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header img {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.volume-control {
  position: relative;
  z-index: 2;
  width: 100%;
  margin: 2rem 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.volume-control img {
  width: 15px;
  height: 15px;
  margin: 1rem;
  cursor: pointer;
}

input[type='range'].volume-slider {
  height: 2px;
}

input[type='range']::-moz-range-thumb {
  height: 12px;
  width: 12px;
  border-radius: 23px;
  background: #f85827;
  cursor: pointer;
  /* -moz-appearance: none; */
  margin-top: -7px;
}

.song-info {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.song-info img {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  border: 5px solid white;
  margin-bottom: 2rem;
  cursor: pointer;
  animation: rotate 15s linear infinite;
  transition: all 0.25s ease-in-out;
}
.song-info img:hover {
  box-shadow: 0 0 12px white;
}

.song-info h1 {
  font-weight: 900;
  font-size: 1.25rem;
  color: white;
  text-shadow: 0 0 12px gray;
  margin-bottom: 0.5rem;
}

.song-info p {
  color: white;
  font-weight: 700;
  font-size: 10px;
  text-shadow: 0 0 12px black;
}

.controls {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-top: 3rem;
}

.controls img {
  width: 22px;
  height: 22px;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
}

.song-progress {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  margin-top: 2rem;
}

.time {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.15rem;
  color: white;
  font-weight: bold;
}

.current-time {
  text-shadow: 0 0 12px black;
}

.duration {
  text-shadow: 0 0 12px black;
  color: #f85827;
}

.progress-bar {
  width: 100%;
  height: 3px;
  border-radius: 10000px;
  background: white;
  overflow: hidden;
}

.progress {
  width: 0%;
  height: 100%;
  background: #f85827;
  transition: width 50ms linear;
}

.buttons {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 2rem;
}

.buttons img {
  width: 30px;
  height: 30px;
  cursor: pointer;
}

.buttons img:first-child,
.buttons img:last-child {
  width: 15px;
  height: 15px;
}

.play-pause {
  width: 60px;
  height: 60px;
  background: #f85827;
  margin: 0 -25px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
}

body.shuffle #shuffle {
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: #f85827;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.shuffle #shuffle img {
  transform: scale(0.75);
}

.gallery {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 3;
  width: 100%;
  height: 100%;
  padding: 15px;
  background: white;
  transform: translateY(100%);
  transition: transform 0.25s ease-in-out;
}

.gallery-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.gallery-header h1 {
  font-size: 1.5rem;
  font-weight: 900;
}

.gallery-header button {
  border: 2px solid #f85827;
  background: transparent;
  outline: none;
  padding: 0 0.75rem;
  font-size: 2rem;
  color: black;
  cursor: pointer;
  border-radius: 5px;
  transition: all 0.25s ease-in-out;
}

.gallery-header button:hover {
  color: white;
  background: #f85827;
  box-shadow: 0 0 12px #f85827;
}

.gallery-content {
  width: 100%;
  max-height: 95%;
  overflow-y: auto;
}

.song-card {
  padding: 1rem;
  margin: 1rem 5px;
  border-radius: 5px;
  box-shadow: 0 0 5px lightgrey;
  display: flex;
  align-items: center;
}

.song-card img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  margin-right: 1rem;
}

.song-card div h1 {
  font-size: 0.95rem;
  margin-bottom: 5px;
}

.song-card div p {
  font-size: 0.7rem;
}

.current-song {
  background: #f85827;
  color: white;
}

body.show-gallery .gallery {
  transform: translateY(0);
}

body.paused .song-info img {
  animation-play-state: paused;
}

@media screen and (max-width: 500px) {
  .music-player {
    border-radius: 0px;
    max-width: 100%;
    max-height: 100%;
  }

  .song-info img {
    width: 30vh;
    height: 30vh;
    border-radius: 50%;
    border: 5px solid white;
    margin-bottom: 5vh;
  }

  .buttons {
    margin-top: 6vh;
  }
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
