/* Video Play Button on Product Cards */
.product-video-play-btn {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 32px;
  height: 32px;
  background: rgba(0, 0, 0, 0.6);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: all 0.3s ease;
  padding: 0;
}

.product-video-play-btn svg {
  width: 16px;
  height: 16px;
  fill: white;
}

.product-video-play-btn:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.1);
}

/* Video Preview Overlay */
.video-hover-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

.video-hover-overlay.active {
  opacity: 1;
  visibility: visible;
}

.video-hover-overlay video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-hover-overlay iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* Loading spinner for video */
.video-loading-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 30px;
  height: 30px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: video-spin 1s linear infinite;
}

@keyframes video-spin {
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .product-video-play-btn {
    width: 28px;
    height: 28px;
  }

  .product-video-play-btn svg {
    width: 14px;
    height: 14px;
  }
}
