/* =========================
   VIDEO POPUP
========================= */
.video-popup-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.7); /* semi-transparent dark overlay */
  backdrop-filter: blur(12px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  visibility: visible;
  transition: all 0.3s ease;
}

.video-popup-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.video-popup-container {
  background: #fff; /* white popup frame */
  border-radius: 20px;
  padding: 30px;
  max-width: 90vw;
  max-height: 90vh;
  width: 650px;
  box-shadow: 0 20px 60px rgba(217,115,13,0.4); /* keep orange shadow */
  transform: scale(1);
  transition: transform 0.3s ease;
  position: relative;
  overflow: hidden;
}

.video-popup-overlay.hidden .video-popup-container {
  transform: scale(0.8);
}

.video-popup-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #ccc;
}

.video-popup-header h2 {
  color: #000; /* black text */
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 8px 0;
  text-align: center;
}

.video-popup-header p {
  color: #333; /* dark text */
  font-size: var(--text-base);
  text-align: center;
  margin: 0;
}

.close-popup-btn {
  background: #fff; /* white button background */
  border: 2px solid #d9730d; /* orange border */
  color: #d9730d; /* orange X */
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: all 0.3s ease;
  position: absolute;
  top: 15px;
  right: 15px;
  z-index: 10001;
}

.close-popup-btn:hover {
  background: #d9730d; /* orange hover */
  color: #fff; /* white X */
  transform: scale(1.1);
}

.video-popup-content {
  text-align: center;
}

.video-popup-content video {
  width: 90%;
  max-width: 100%;
  border-radius: 12px;
  box-shadow: 
    0 0 15px rgba(217,115,13,0.4),
    0 0 30px rgba(217,115,13,0.4),
    0 10px 30px rgba(217,115,13,0.4); /* keep orange shadow */
  display: block;
  margin: 20px auto 0 auto;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.video-popup-content video:hover {
  box-shadow: 0 15px 35px rgba(255, 35, 0, 0.3); /* keep orange hover */
  transform: scale(1.02);
}

.video-popup-actions {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}

.video-popup-actions .btn {
  padding: 12px 24px;
  border-radius: 25px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
  min-width: 140px;
}

.video-popup-actions .btn-primary {
  background: linear-gradient(135deg, #d9730d 0%, #ff6700 100%); /* orange gradient */
  color: #fff; /* white text */
}

.video-popup-actions .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(255,35,0,0.5); /* keep orange hover shadow */
}

/* Responsive Design */
@media (max-width: 768px) {
  .video-popup-container {
    padding: 20px;
    width: 95vw;
    max-height: 95vh;
  }

  .video-popup-header h2 {
    font-size: 1.2rem;
  }

  .video-popup-content video {
    width: 90%;
    max-width: 90%;
  }

  .video-popup-actions {
    flex-direction: column;
    align-items: center;
  }

  .video-popup-actions .btn {
    width: 100%;
    max-width: 200px;
  }

  .close-popup-btn {
    width: 50px;
    height: 50px;
    font-size: 1.3rem;
  }
}

@media (max-width: 480px) {
  .video-popup-container {
    padding: 15px;
  }

  .video-popup-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
  }

  .video-popup-header h2 {
    font-size: 1.1rem;
  }

  .close-popup-btn {
    width: 45px;
    height: 45px;
    font-size: 1.2rem;
  }

  .video-popup-actions .btn {
    min-width: 140px;
    padding: 12px 24px;
    font-size: 1rem;
  }
}

/* Animation for popup appearance */
@keyframes popupFadeIn {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}

.video-popup-overlay:not(.hidden) .video-popup-container {
  animation: popupFadeIn 0.3s ease forwards;
}

/* Prevent body scroll when popup is open */
body.popup-open {
  overflow: hidden;
}
