/*
 * Lightning gallery video pop-up (gallery one, two, three and six), paired
 * with templates_frontend/lightning/gallery/video_dialog.html and
 * js/lightning/gallery/video-dialog.js. Looks like the old .modal.show.
 */
.lightning-video-dialog {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: rgba(23, 23, 23, 0.88);
  color: #fff;
}

.lightning-video-dialog::backdrop {
  background: transparent;
}

.lightning-video-dialog__header {
  position: relative;
  width: 90%;
  margin: auto;
}

.lightning-video-dialog__title {
  margin: 0.5em 2em;
  color: #fff;
  font-size: clamp(1.25rem, 2.5vw, 2rem);
  text-align: center;
}

.lightning-video-dialog__close {
  position: absolute;
  top: 0;
  right: 0;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 50px;
  line-height: 1;
  cursor: pointer;
}

.lightning-video-dialog__close:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.lightning-video-dialog__frame {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 70%;
  max-width: 1900px;
  aspect-ratio: 16 / 9;
  transform: translate(-50%, -50%);
}

@media only screen and (max-width: 767px) {
  .lightning-video-dialog__frame {
    width: 90%;
  }
}

.lightning-video-dialog__frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Thumbnail: the old link is now a button; strip the button chrome. */
.thumb-video .video-360 {
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}

/*
 * The thumbnail clips its overflow, so the ring goes on the figure:
 * white outline with a black edge, visible on any photo or background.
 */
.thumb-video:has(.video-360:focus-visible) {
  outline: 2px solid #fff;
  box-shadow: 0 0 0 4px #000;
}
