/* Spotlight: an auto-rotating card of featured artists. Loaded alongside every
   map theme, so it only uses the tokens each theme already defines
   (--surface, --border, --text, --text-muted, --accent). */

#spotlight {
  pointer-events: auto;
  width: 300px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 8px 10px;
  color: var(--text);
  font-size: 0.85rem;
  text-align: left;
  transition: opacity 0.3s ease;
}

body.panel-open #spotlight {
  opacity: 0;
  pointer-events: none;
}

.spot-head {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-bottom: 6px;
}

.spot-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.spot-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.spot-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.spot-dot[aria-current="true"] {
  background: var(--accent);
  border-color: var(--accent);
}

#spotlight button:focus-visible,
#spotlight a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.spot-rail {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.spot-rail::-webkit-scrollbar {
  display: none;
}

.spot-slide {
  flex: 0 0 100%;
  scroll-snap-align: start;
  display: flex;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.spot-art {
  flex: 0 0 56px;
  width: 56px;
  height: 56px;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  object-fit: cover;
}

.spot-meta {
  min-width: 0;
  flex: 1;
}

.spot-city {
  display: inline-block;
  font-size: 0.6rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.spot-artist {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.spot-track {
  display: block;
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.spot-player {
  display: block;
  width: 100%;
  height: 42px;
  border: 0;
  margin-top: 6px;
  background: transparent;
}

.spot-link {
  display: inline-block;
  margin-top: 4px;
  font-size: 0.72rem;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px dashed var(--accent);
}


.spot-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  font: inherit;
  background: none;
  border: none;
  padding: 2px 2px;
  color: var(--text);
  cursor: pointer;
  text-align: left;
}

.spot-chev {
  margin-left: auto;
  font-size: 0.8rem;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

#spotlight[data-open="true"] .spot-chev {
  transform: rotate(90deg);
}

#spotlight.is-collapsed {
  width: auto;
  min-width: 150px;
  padding: 6px 10px;
}

#spot-body[hidden] {
  display: none;
}

.spot-next {
  font: inherit;
  font-size: 1rem;
  line-height: 1;
  width: 22px;
  height: 22px;
  background: var(--bg, transparent);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 50%;
  padding: 0 0 2px;
  cursor: pointer;
}

.spot-next:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* Wide screens: sit to the right of the title, which stays centered. */
@media (min-width: 1100px) {
  #spotlight {
    position: absolute;
    right: 24px;
    top: 16px;
  }
}

/* Narrower screens: centered under the title and its hint button. */
@media (max-width: 1099px) {
  #spotlight {
    margin: 12px auto 0;
  }
}

@media (max-width: 768px) {
  #spotlight {
    width: min(320px, 100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .spot-rail {
    scroll-behavior: auto;
  }
}
