.card {
  position: relative;
  border: none;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
}

.card-img-top {
  object-fit: cover;
  height: 250px;
  width: 100%;
}

.card-body {
  padding: 20px;
  text-align: center;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 600;
}

.card-description {
  font-size: 0.9rem;
  color: #555;
}

.play-icon {
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, #ff4e50, #f9d423);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 15px rgba(255, 78, 80, 0.6);
  animation: pulse 1.8s infinite;
  z-index: 10;
}

.play-icon i {
  font-size: 30px;
  color: white;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 78, 80, 0.4); }
  70% { box-shadow: 0 0 0 20px rgba(255, 78, 80, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 78, 80, 0); }
}

/* Video overlay */
.video-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.95);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  padding: 0;
}

.video-player-wrapper {
  position: relative;
  width: 100vw;
  max-width: 960px;
  height: 56.25vw; /* fallback for 16:9 ratio */
  max-height: 90vh;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
}

.video-player-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.video-logo-wrapper {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 70px;
  pointer-events: none;
}

.video-logo-wrapper img {
  width: 100%;
  opacity: 0.8;
}

.close-video {
  position: absolute;
  top: 20px;
  right: 30px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 45px;
  height: 45px;
  font-size: 26px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
  z-index: 10000;
}

.close-video:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ✅ Improved Mobile Support */
@media (max-width: 768px) {
  .video-player-wrapper {
    width: 100vw;
    height: 60vh;
    max-width: 100%;
    border-radius: 0;
  }

  .video-logo-wrapper {
    width: 40px;
  }

  .close-video {
    top: 10px;
    right: 15px;
    width: 35px;
    height: 35px;
    font-size: 20px;
  }
}
