/* Track C (YouTube) slide styles — load after gallery shell CSS. */
.swiper-slide.is-video-slide {
  display: flex;
  align-items: center;
  /* center vertically within the main viewer */
  justify-content: center;
  padding: clamp(8px, 1vw, 20px);
  /* slight inset so it doesn't stick to the top */
}

.gallery-video-frame {
  position: relative;
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  /* keep 16:9 while letting it center vertically */
  height: auto;
  max-height: 90%;
  padding-top: 0;
}

@supports not (aspect-ratio: 16 / 9) {
  .gallery-video-frame {
    height: 0;
    padding-top: 56.25%;
    /* fallback for older browsers */
  }
}

.gallery-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Match track A/B active border for track C thumbs */
[data-track="c"].is-active-thumb,
.gallery-thumb-item[data-track="c"].is-active-thumb {
  outline: 0.7px solid #fafafa;
  outline-offset: 0;
  opacity: 1;
}

/* Track C thumbnail sizing (does not affect A/B)
   - Tweak width/max-width if you want the thumbs smaller/bigger */
.gallery-thumbs-trackC {
  display: flex;
  justify-content: flex-start;
}

.gallery-thumbs-trackC .gallery-yt-link {
  display: block;
  position: relative;
  aspect-ratio: 16 / 9;
  width: clamp(100px, 20vw, 140px) !important;
  /* 1개 썸네일일 때 덜 도드라지게 축소 */
  max-width: 140px;
  margin: 0 auto;
  justify-self: center;
  flex: 0 0 auto;
  /* flex 컨텍스트에서도 늘어나지 않도록 */
}

.gallery-thumbs-trackC .swiper-slide {
  /* 스와이퍼가 인라인 width를 박을 때 강제로 덮어써서 폭을 줄임 */
  width: clamp(100px, 20vw, 140px) !important;
  max-width: 140px;
}

.gallery-thumbs-trackC .yt-thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
