.ggultv-ytm {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, .85);
}
.ggultv-ytm.is-open { display: flex; }

.ggultv-ytm__box {
  position: relative;
  width: min(960px, 94vw);
}
.ggultv-ytm__frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 12px 48px rgba(0, 0, 0, .5);
}
/* aspect-ratio 미지원 브라우저 폴백 */
@supports not (aspect-ratio: 16 / 9) {
  .ggultv-ytm__frame { height: 0; padding-bottom: 56.25%; }
}
.ggultv-ytm__frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.ggultv-ytm__close {
  position: absolute;
  top: -44px;
  right: 0;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .16);
  color: #fff;
  font-size: 26px;
  line-height: 38px;
  text-align: center;
  cursor: pointer;
  transition: background .15s;
}
.ggultv-ytm__close:hover { background: rgba(255, 255, 255, .32); }

@media (max-width: 600px) {
  .ggultv-ytm { padding: 12px; }
  .ggultv-ytm__close { top: -40px; }
}

/* ------------------------------------------------------------------ *
 *  Automatic YouTube Gallery(classic): 메인 인라인 플레이어 숨김.
 *  (썸네일 클릭 시 모달로 재생하므로 상단 인라인 플레이어는 불필요.)
 *  활성(첫) 썸네일도 다른 썸네일과 동일하게 — Now Playing 라벨 제거, 재생 아이콘 표시.
 * ------------------------------------------------------------------ */
.ayg-theme-classic .ayg-player { display: none !important; }
.ayg-active .ayg-thumbnail-now-playing { display: none !important; }
.ayg-active .ayg-thumbnail-icon-play { display: inline-block !important; }

/* ------------------------------------------------------------------ *
 *  [ggultv_highlights] 반응형 그리드: PC/패드 한 줄 4개, 모바일 한 줄 2개.
 *  (AYG 기본 반응형 열 대신 강제 적용)
 * ------------------------------------------------------------------ */
.ggultv-hl .ayg-videos .ayg-col { width: 25% !important; }   /* PC·패드: 4열 */
@media (max-width: 767px) {
  .ggultv-hl .ayg-videos .ayg-col { width: 50% !important; } /* 모바일: 2열 */
}
