/* =========================================
  1. FONT FACES
  ========================================= */
@font-face {
  font-family: "SF Pro Display";
  src: url("Fonts/SF-Pro-Display-Bold.otf");
  font-weight: 900;
}

@font-face {
  font-family: "SF Pro Display";
  src: url("Fonts/SF-Pro-Display-Medium.otf");
  font-weight: 500;
}

@font-face {
  font-family: "SF Pro Display";
  src: url("Fonts/SF-Pro-Display-Regular.otf");
  font-weight: 300;
}

@font-face {
  font-family: "SF Pro Mono";
  src: url("Fonts/SFMono-Bold.otf");
  font-weight: 900;
}

@font-face {
  font-family: "SF Pro Mono";
  src: url("Fonts/SFMono-Medium.otf");
  font-weight: 300;
}

@font-face {
  font-family: "SF Pro Mono";
  src: url("Fonts/SFMono-Regular.otf");
  font-weight: 100;
}

/* =========================================
 2. GLOBAL RESET & BASE STYLES
 ========================================= */

* {
  font-family: "SF Pro Display";
  font-weight: 300;
  color: #000;
  padding: 0;
  margin: 0;
  user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
  -moz-user-select: none;
}

body {
  background-color: black;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 2rem 0;
  gap: 2rem;
}

/* =========================================
 3. LAYOUT STRUCTURE
 ========================================= */
#cards {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* =========================================
 4. CARD STYLES
 ========================================= */
.card {
  background-color: rgba(255, 255, 255, 0.33);
  width: calc(100vw - 8rem);
  padding: 2rem;
  border-radius: 4rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  height: fit-content;
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
  transition: all 0.2s ease-in-out;
}

#main.card {
  position: relative;
  z-index: 2;
}

#next.card {
  position: absolute;
  top: -3rem;
  scale: 0.9;
  z-index: 1;
}

.card > * {
  width: -webkit-fill-available;
}

.card > img {
  width: calc(100vw - 8rem);
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 2rem;
  margin-bottom: 1.5rem;
}

/* =========================================
 5. TYPOGRAPHY
 ========================================= */
.title {
  font-size: 2rem;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
}

.artist {
  font-size: 1.5rem;
  font-weight: 300;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.details {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

/* =========================================
 6. PLAYER CONTROLS
 ========================================= */
.playerContainer {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.playerContainer > svg {
  width: 4rem;
  display: none;
}

.playerContainer > svg.active {
  display: block;
}

.seekbar {
  accent-color: #000;
  background: transparent;
  width: -webkit-fill-available;
}

.seekbarLabels {
  display: flex;
  justify-content: space-between;
}

.seekbarLabels > span {
  font-family: "SF Pro Mono";
  font-size: 1rem;
}

/* Volume Controls */
.volumeContainer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 0.75rem;
}

.volumeContainer > svg {
  width: 1.5rem;
  stroke: #000;
}

.volume {
  accent-color: #000;
  background: transparent;
  width: -webkit-fill-available;
  margin: 0 0.25rem;
}

/* =========================================
 7. RANGE SLIDER STYLES
 ========================================= */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 0.25rem;
  background: #ccc;
  border-radius: 0.125rem;
  outline: none;
  overflow: hidden;
}

/* WebKit (Chrome, Safari, Edge) */
input[type="range"]::-webkit-slider-runnable-track {
  height: 0.25rem;
  background: #ccc;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 0.25rem;
  height: 0.25rem;
  background: #000;
  border-radius: 50%;
  box-shadow: -100vw 0 0 100vw #000; /* filled progress */
  cursor: pointer;
}

/* Firefox */
input[type="range"]::-moz-range-track {
  height: 0.25rem;
  background: #333;
}

input[type="range"]::-moz-range-progress {
  height: 0.25rem;
  background: #000;
}

input[type="range"]::-moz-range-thumb {
  width: 0.25rem;
  height: 0.25rem;
  background: #000;
  border: none;
  border-radius: 50%;
  cursor: pointer;
}

/* =========================================
 8. BUTTONS
 ========================================= */
/* Install Button */
#install-btn {
  display: none;
  position: relative;
  margin: 0.5rem auto 0;
  top: 0;
  padding: 0.5rem 0.75rem;
  border: none;
  border-radius: 1rem;
  background-color: #333;
  color: #fff;
}

/* Like Button */
#like-btn {
  background-color: rgba(255, 255, 255, 0.33);
  color: #000;
  border: none;
  border-radius: 2rem;
  padding: 0.75rem 1.5rem;
  font-size: 1.25rem;
  font-weight: 500;
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
}

#like-btn:hover {
  transform: scale(1.05);
  background-color: rgba(255, 255, 255, 0.5);
}

#like-btn.liked {
  background-color: rgba(255, 0, 0, 0.33);
  color: #fff;
}

/* Bottom Buttons (Like / Dislike Pair) */
.bottom-btns {
  width: calc(100vw - 4rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.dislike-btn,
.like-btn {
  width: 50%;
  border-radius: 4rem;
  padding: 1.5rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
  transition: all 0.25s ease-in-out;
}

/* Dislike */
.dislike-btn {
  background-color: rgba(255, 85, 85, 0.5);
}

.dislike-btn:active {
  background-color: rgba(255, 85, 85, 0.75);
}

/* Like */
.like-btn {
  background-color: rgba(85, 255, 85, 0.5);
}

.like-btn:active {
  background-color: rgba(85, 255, 85, 0.75);
}

/* Icons & Text inside bottom buttons */
.dislike-btn > svg,
.like-btn > svg {
  width: 2rem;
}

.dislike-btn > p,
.like-btn > p {
  font-size: 1.5rem;
  font-weight: 500;
}

/* =========================================
 9. MARQUEE ANIMATION
 ========================================= */
.marquee {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.marquee__inner {
  display: inline-flex;
  align-items: center;
  gap: 4rem;
  will-change: transform;
  animation: marquee-scroll 12s linear infinite;
}

.marquee__inner > span {
  white-space: nowrap;
  font-size: 2rem;
  font-weight: 900;
  font-family: "SF Pro Display";
}

@keyframes marquee-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-1 * var(--marquee-distance, 0px)));
  }
}

/* =========================================
 10. BROWSER-SPECIFIC FIXES (Old Edge / IE)
 ========================================= */
input[type="range"]::-ms-track {
  height: 0.25rem;
  background: transparent;
  border-color: transparent;
  color: transparent;
}

input[type="range"]::-ms-fill-lower {
  background: #000;
}

input[type="range"]::-ms-fill-upper {
  background: #333;
}

input[type="range"]::-ms-thumb {
  width: 0.25rem;
  height: 0.25rem;
  background: #000;
  border-radius: 50%;
  cursor: pointer;
}
