/* "Watch Video" popup — CSS-only open/close via checkbox hack, matching
   monetize-drawer.css's convention. components/video-modal.html */
.hp-video-modal-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
}

.video-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 70;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

body:has(.hp-video-modal-input:checked) .video-modal {
  display: flex;
}

body:has(.hp-video-modal-input:checked) {
  overflow: hidden;
}

.video-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(8, 15, 26, 0.72);
  cursor: pointer;
  opacity: 0;
  animation: video-modal-fade-in 0.2s ease forwards;
}

@keyframes video-modal-fade-in {
  to {
    opacity: 1;
  }
}

.video-modal__panel {
  position: relative;
  width: 100%;
  max-width: 900px;
  opacity: 0;
  transform: scale(0.96) translateY(8px);
  animation: video-modal-pop-in 0.22s ease forwards;
}

@keyframes video-modal-pop-in {
  to {
    opacity: 1;
    transform: none;
  }
}

.video-modal__close {
  position: absolute;
  top: -44px;
  right: 0;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.15s ease;
}

.video-modal__close:hover {
  background: rgba(255, 255, 255, 0.22);
}

.video-modal__frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 1rem;
  overflow: hidden;
  background: #000;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
}

.video-modal__frame video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

@media (max-width: 576px) {
  .video-modal__close {
    top: -40px;
    width: 32px;
    height: 32px;
  }
}
