body.product-video-open {
  overflow: hidden;
}

.product-video-overlay[hidden] {
  display: none !important;
}

.product-video-overlay {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(4, 14, 20, 0.84);
  backdrop-filter: blur(12px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 280ms ease, visibility 280ms ease;
}

.product-video-overlay.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.product-video-dialog {
  width: min(1120px, calc(100vw - 48px));
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  background: #071116;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.48);
  opacity: 0;
  transform: translateY(24px) scale(0.96);
  transform-origin: center;
  transition: opacity 360ms ease, transform 520ms cubic-bezier(0.22, 1, 0.36, 1);
}

.product-video-overlay.is-open .product-video-dialog {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.product-video-dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 80px;
  padding: 14px 18px 14px 24px;
  color: #fff;
  background: linear-gradient(90deg, #08161c, #0d2229);
}

.product-video-dialog-header > div {
  min-width: 0;
}

.product-video-dialog-header span {
  display: block;
  margin-bottom: 3px;
  color: #5ab6eb;
  font-size: 0.72rem;
  font-weight: 780;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.product-video-dialog-header h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.25rem, 2.2vw, 1.85rem);
  line-height: 1.15;
}

.product-video-stop {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 3px;
  padding: 9px 14px;
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 720;
  cursor: pointer;
  transition: border-color 180ms ease, background 180ms ease;
}

.product-video-stop:hover {
  border-color: #69c4f4;
  background: rgba(24, 132, 191, 0.24);
}

.product-video-stop > span {
  margin: 0;
  color: inherit;
  font-size: 1.35rem;
  line-height: 1;
}

.product-video-frame {
  position: relative;
  display: grid;
  place-items: center;
  background: #000;
}

.product-video-frame video {
  display: block;
  width: 100%;
  max-height: calc(100vh - 150px);
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #000;
}

.product-video-sound-gate {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  place-items: center;
  width: min(360px, calc(100% - 40px));
  min-height: 156px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 4px;
  padding: 24px;
  color: #fff;
  background: rgba(4, 18, 25, 0.9);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.38);
  font: inherit;
  cursor: pointer;
  transform: translate(-50%, -50%);
}

.product-video-sound-gate[hidden] {
  display: none !important;
}

.product-video-sound-gate-icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin-bottom: 10px;
  border-radius: 50%;
  color: #fff;
  background: #087bb6;
  font-size: 1.1rem;
}

.product-video-sound-gate strong {
  font-size: 1rem;
}

.product-video-sound-gate small {
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.75rem;
}

.product-video-preview-media {
  position: relative;
  display: block;
  width: 100%;
  height: 78px;
  overflow: hidden;
  background: #071116;
}

.product-video-preview-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.product-video-preview-media i {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 50%;
  color: #fff;
  background: rgba(3, 25, 34, 0.82);
  font-style: normal;
  font-size: 0.76rem;
  line-height: 1;
  transform: translate(-50%, -50%);
}

.product-video-preview-thumb:hover .product-video-preview-media i,
.mobile-video-preview-thumb:hover .product-video-preview-media i {
  background: #087bb6;
}

.mobile-video-preview-thumb .product-video-preview-media {
  height: 100%;
}

@media (max-width: 720px) {
  .product-video-overlay {
    padding: 0;
  }

  .product-video-dialog {
    width: 100vw;
    border-width: 0;
    border-radius: 0;
  }

  .product-video-dialog-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    min-height: 0;
    gap: 12px;
    padding: 16px;
  }

  .product-video-dialog-header h2 {
    font-size: 1.15rem;
  }

  .product-video-stop {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    min-height: 44px;
    justify-content: center;
    padding: 10px 14px;
    overflow: visible;
    font-size: 0.82rem;
    line-height: 1.35;
    text-align: center;
    white-space: normal;
  }

  .product-video-stop > span {
    flex: 0 0 auto;
    font-size: 1.25rem;
  }

  .product-video-frame video {
    max-height: calc(100vh - 154px);
    max-height: calc(100dvh - 154px);
  }

  .product-video-sound-gate {
    min-height: 142px;
    padding: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .product-video-overlay,
  .product-video-dialog {
    transition-duration: 1ms;
  }
}
