/* ========== Video Player ========== */
.video-player {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--bg-card);
}

.video-player video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-player--hero {
  aspect-ratio: 21 / 9;
}

/* ========== Image Carousel ========== */
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}

.carousel__track {
  display: flex;
  transition: transform 0.5s ease;
}

.carousel__slide {
  min-width: 100%;
}

.carousel__slide img {
  width: 100%;
  display: block;
}

.carousel__nav {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
}

.carousel__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(154, 217, 255, 0.35);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background var(--transition);
}

.carousel__dot.active {
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.carousel__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.65);
  color: var(--text-primary);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 1.25rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
  z-index: 2;
}

.carousel__arrow:hover {
  background: rgba(0, 0, 0, 0.85);
}

.carousel__arrow--prev {
  left: 0.75rem;
}

.carousel__arrow--next {
  right: 0.75rem;
}

/* ========== Lightbox ========== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  background: rgba(0, 0, 0, 0.95);
  display: none;
  flex-direction: column;
}

.lightbox.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  user-select: none;
}

.lightbox__close,
.lightbox__prev,
.lightbox__next {
  position: absolute;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text-primary);
  cursor: pointer;
  border-radius: 4px;
  line-height: 1;
  transition: background 0.15s;
}

.lightbox__close:hover,
.lightbox__prev:hover,
.lightbox__next:hover {
  background: rgba(212, 175, 55, 0.3);
}

.lightbox__close {
  top: 0.75rem;
  right: 0.75rem;
  font-size: 2.5rem;
  padding: 0.4rem 0.8rem;
}

.lightbox__prev {
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3rem;
  padding: 0.4rem 0.9rem;
}

.lightbox__next {
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3rem;
  padding: 0.4rem 0.9rem;
}

.lightbox__count {
  position: absolute;
  bottom: 0.75rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.8rem;
  pointer-events: none;
}

/* ========== Loading Skeleton ========== */
.media-loading {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-hover) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}