/* Video Modal Styles - Wistia-like experience */
/* Version: 1.0 */

/* Modal Overlay */
.video-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.92);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.video-modal-overlay.active {
  display: flex;
  opacity: 1;
}

/* Modal Content Container */
.video-modal-content {
  position: relative;
  width: 90%;
  max-width: 960px;
  aspect-ratio: 16/9;
  background: #000;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
  transform: scale(0.92);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.video-modal-overlay.active .video-modal-content {
  transform: scale(1);
}

/* Video Element */
.video-modal-content video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

/* Close Button */
.video-modal-close {
  position: absolute;
  top: -48px;
  right: 0;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 24px;
  font-weight: 300;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.video-modal-close:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.video-modal-close:focus {
  outline: 2px solid rgba(255, 255, 255, 0.5);
  outline-offset: 2px;
}

/* Thumbnail with play button overlay */
.video-thumbnail-wrapper {
  position: relative;
  cursor: pointer;
  display: block;
  overflow: hidden;
  border-radius: 4px;
}

.video-thumbnail-wrapper img {
  transition: transform 0.3s ease;
}

.video-thumbnail-wrapper:hover img {
  transform: scale(1.03);
}

/* Play button overlay */
.video-thumbnail-wrapper::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background-color: rgba(0, 0, 0, 0.65);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E");
  background-position: 55% center;
  background-repeat: no-repeat;
  background-size: 40%;
  border-radius: 50%;
  transition: transform 0.25s ease, background-color 0.25s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.video-thumbnail-wrapper:hover::after {
  transform: translate(-50%, -50%) scale(1.12);
  background-color: rgba(0, 0, 0, 0.8);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .video-modal-content {
    width: 95%;
    border-radius: 4px;
  }
  
  .video-modal-close {
    top: -44px;
    width: 36px;
    height: 36px;
    font-size: 22px;
  }
  
  .video-thumbnail-wrapper::after {
    width: 60px;
    height: 60px;
  }
}

@media (max-width: 480px) {
  .video-thumbnail-wrapper::after {
    width: 50px;
    height: 50px;
  }
}

/* Inline video player styles (for partner page) */
.inline-video-container {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 aspect ratio */
  background: #000;
  border-radius: 8px;
  overflow: hidden;
}

.inline-video-container video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Custom video controls styling (optional) */
.inline-video-container video::-webkit-media-controls-panel {
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.5));
}

