/* ------------------------------
   Starfield & body
------------------------------ */
body, html {
  height: 100%;
  margin: 0;
  background: #000;
  color: #fff;
  font-family: Inter, system-ui, 'Segoe UI', Roboto, sans-serif;
}

#starfield-container {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

#starfield {
  width: 100%;
  height: 100%;
  display: block;
}



/* Bottom-middle button */
#starfield-anchor {
  position: fixed;
  left: 50%;
  bottom: 50%;
  transform: translateX(-50%);
  z-index: -3;
  width: 0;
  height: 0;
  background: transparent; /* optional, since size is 0 */
  color: #fff;
  border: 0;
  padding: 0;
  border-radius: 0;
  cursor: default;
  pointer-events: none; 
  backdrop-filter: blur(6px); /* optional, has no effect on 0px */
  opacity: 1;
}

/* Target the interests panel */
.interests-panel {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  max-height: 60vh;
  overflow-y: auto;
  width: 100%;

  /* For Firefox */
  scrollbar-width: thin; /* thin scrollbar */
  scrollbar-color: #9b59b6 #2c2c2c; /* thumb and track */
}

/* Chrome, Edge, Safari */
.interests-panel::-webkit-scrollbar {
  width: 12px; /* width of the scrollbar */
}

.interests-panel::-webkit-scrollbar-track {
  background: #2c2c2c; /* track color */
  border-radius: 8px;
}

/* Desktop interests grid */
.interests-panel {
  max-width: 700px;
}

/* Mobile interests grid */
@media (max-width: 768px) {
  .interests-panel {
    grid-template-columns: repeat(2, 1fr);
    max-height: 50vh;
  }
}

.interests-panel::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #a565c7, #9b59b6);
}


/* Centered panel container */
.center-panel {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5vh; /* 1vh * 1.5 */
  z-index: 10;
}

/* Image square (not clickable) */
.panel-image img {
  width: 9vw;   /* 7.5vw * 1.5 */
  height: 9vw;  /* keep square aspect */
  border-radius: 1.125vw; /* 0.75vw * 1.5 */
  object-fit: cover;
  opacity: 0.9;
}

/* Buttons */
.panel-btn {
  width: 28vw; /* 15vw * 1.5 */
  padding: 1vh 0; /* 0.6vh * 1.5 */
  background: rgba(0,0,0,0.5);
  color: #fff;
  font-weight: bold;
  font-size: 0.9vw;
  text-align: center;
  border: 2px solid; /* border width */
  border-image: linear-gradient(45deg, #03001e, #7303c0, #ec38bc, #fdeff9) 1; /* gradient border */
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background 0.2s, transform 0.1s;
}

.panel-btn:hover {
  background: rgba(0,0,0,0.7);
  transform: translateY(-0.15vh);
}

.panel-btn:active {
  transform: translateY(0.15vh);
}





/* ------------------------------
   YouTube Audio Panel
------------------------------ */
.yt-audio-panel {
  position: fixed;
  bottom: 40px;
  right: 20px; /* permanently in “hovered” position */
  width: 320px;
  max-width: 90vw; /* ensures it fits on small screens */
  height: 84px;
  background: rgba(10,14,20,0.45);
  color: #e6eef7;
  box-shadow: 0 8px 30px rgba(0,0,0,0.6), 0 1px 0 rgba(255,255,255,0.02) inset;
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
  z-index: 9999;
  overflow: hidden;
  display: flex;
  align-items: center;
  padding: 10px;
  gap: 10px;
  border: 1px solid white;
  border-radius: 15px;
  /* remove hover transition since it’s no longer sliding */
  transition: none;
}

/* Hide the hover tab, it’s no longer needed */
.yt-tab {
  display: none;
}

@media (max-width: 600px) {
  .yt-audio-panel {
    width: 240px;      /* smaller width */
    height: 64px;      /* smaller height */
    padding: 6px;      /* less padding */
    gap: 6px;          /* smaller spacing between items */
    bottom: 20px;      /* closer to bottom */
    right: 10px;       /* closer to edge */
    border-radius: 10px; /* slightly smaller rounded corners */
  }

  .yt-audio-panel * {
    font-size: 0.85em; /* optional: shrink text/icons */
  }
}



.yt-tab {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  border-radius: 12px 0 0 12px;
  cursor: pointer;
  color: #7fd1ff;
  font-size: 18px;
  pointer-events: auto;
  user-select: none;
}

.yt-cover {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(0,0,0,0.6);
}

.yt-info {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-right: 6px;
}

.yt-title {
  font-size: 13px;
  line-height: 1.1;
  font-weight: 600;
  color: #eaf6ff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.yt-times {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #b9d7e6;
  opacity: 0.9;
  margin-top: -2px;
}

.yt-progress {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 6px;
  background: rgba(255,255,255,0.08);
  outline: none;
  cursor: pointer;
  margin-top: 6px;
}

.yt-progress::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #7fd1ff;
  border: 2px solid rgba(255,255,255,0.15);
  margin-top: -3px;
}

.yt-controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 84px;
  flex: 0 0 84px;
}

.control-row {
  display: flex;
  gap: 4px;
  margin-left: -23px; /* adjust this value to taste */
  align-items: center;
}


.btn {
  background: transparent;
  border: none;
  color: #dff6ff;
  font-size: 16px;
  cursor: pointer;
  padding: 6px;
  border-radius: 8px;
}

/* Move volume slider down and stretch it */
.volume {
  width: 100%;
  margin-top: 6px;
}
.volume input[type=range] {
  width: 100%;
}

/* Single toggle play/pause button */
.btn.toggle-play {
  font-size: 18px;
  padding: 6px 10px;
}

@media (max-width: 768px) {

  /* Center panel should feel BIG on phones */
  .panel-image img {
    width: 120px;
    height: 120px;
  }

  .panel-btn {
    width: 85vw;
    max-width: 360px;
    font-size: 15px;
  }

  .center-panel {
    gap: 14px;
  }

}



.btn:active { transform: translateY(1px); }
.btn:focus { outline: 2px solid rgba(127,209,255,0.2); outline-offset: 2p
