/* About Section */
.about {
  background: var(--background-card);
}

.about .content-container {
  display: grid;
  gap: 1rem;
  margin: 0 auto;
}

.about img {
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.about .content-container > div {
  background: var(--background-card);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.about .content-container > div:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.about .content-container h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.about .content-container p {
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Programs Section */
.programs {
  background: var(--background-light);
}

.programs .content-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin: 0 auto;
}

.programs .content-container > div {
  background: var(--background-card);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.programs .content-container > div::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
}

.programs .content-container > div:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.programs .content-container h3 {
  color: var(--text-primary);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.programs .content-container p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.programs .content-container ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.programs .content-container ul li {
  padding: 0.5rem 1rem;
  background: var(--gradient-primary);
  color: var(--accent-color);
  border-radius: 25px;
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
}

/* CTA Section */
.cta {
  background: var(--gradient-primary);
  color: var(--accent-color);
  text-align: center;
}

.cta .heading h2 {
  color: var(--accent-color);
}

.cta .heading p {
  color: rgba(255, 255, 255, 0.9);
}

.cta .content-container {
  max-width: 600px;
  margin: 0 auto;
}

.cta .content-container p {
  font-size: 1.125rem;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2rem;
}

.cta a {
  display: inline-block;
  padding: 1rem 2rem;
  background: var(--accent-color);
  color: var(--primary-color);
  border-radius: 50px;
  font-weight: 700;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-lg);
}

.cta a:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-xl);
}

/* FAQ Section */
.faq {
  background: var(--background-card);
}

.faq .content-container {
  max-width: 800px;
  margin: 0 auto;
}

.faq ul {
  display: grid;
  gap: 1rem;
}

.faq ul li {
  background: var(--background-light);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.faq ul li::after {
  content: "+";
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color);
  transition: transform 0.3s ease;
}

.faq ul li:hover {
  background: var(--background-card);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.faq ul li:hover::after {
  transform: translateY(-50%) rotate(45deg);
}

/* Dialog/Modal */
dialog {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: none;
  border-radius: 16px;
  padding: 0;
  max-width: 500px;
  width: 90%;
  box-shadow: var(--shadow-xl);
  background: var(--background-card);
  animation: modalFadeIn 0.3s ease;
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

dialog p {
  padding: 2rem;
  margin: 0;
  color: var(--text-secondary);
  line-height: 1.7;
}

dialog button {
  width: 100%;
  padding: 1rem;
  background: var(--gradient-primary);
  color: var(--accent-color);
  border: none;
  border-radius: 0 0 16px 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  outline: none;
}

dialog button:hover {
  background: var(--primary-hover);
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

/* styles/video-testimonials.css */

.video-testimonials {
  background: var(--background-light);
  padding: 5rem 0;
}

.video-testimonials .heading {
  text-align: center;
  margin-bottom: 3rem;
}

.video-testimonials .heading h2 {
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.video-testimonials .heading p {
  color: var(--text-secondary);
  font-size: 1.125rem;
}

/* Videos Grid */
.videos-grid {
  column-width: 280px;
  column-gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* Video Card */
.video-card {
  position: relative;
  background: var(--background-card);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: all 0.3s ease;
  break-inside: avoid; /* Prevents card from splitting across columns */
  margin-bottom: 2rem; /* Vertical spacing between cards */
  display: inline-block; /* Helps with some browser rendering of columns */
  width: 100%; /* Ensures card takes full width of column */
}

.video-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

/* Video aspect ratio containers */
.video-card[data-ratio="16:9"] .video-thumbnail {
  aspect-ratio: 16 / 9;
}

.video-card[data-ratio="9:16"] .video-thumbnail {
  aspect-ratio: 9 / 16;
}

.video-card[data-ratio="4:3"] .video-thumbnail {
  aspect-ratio: 4 / 3;
}

.video-card[data-ratio="1:1"] .video-thumbnail {
  aspect-ratio: 1 / 1;
}

/* Default to 16:9 if no ratio specified */
.video-thumbnail {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  background: var(--background-light);
}

/* Play Overlay */
.play-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 2;
}

.video-card:hover .play-overlay {
  transform: translate(-50%, -50%) scale(1.1);
}

.play-overlay svg {
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.2));
}

/* Video Info */
.video-info {
  padding: 1.5rem;
  background: var(--background-card);
}

.video-info h4 {
  color: var(--text-primary);
  margin: 0 0 0.5rem 0;
  font-size: 1.125rem;
  font-weight: 600;
}

.video-info p {
  color: var(--text-secondary);
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Fullscreen Modal */
.fullscreen-video-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.fullscreen-video-modal.active {
  opacity: 1;
  visibility: visible;
}

.fullscreen-video-modal video {
  max-width: 90%;
  max-height: 90vh;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* Close Button */
#close-video-modal {
  position: absolute;
  top: 2rem;
  right: 2rem;
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10000;
}

#close-video-modal:hover {
  background: white;
  transform: scale(1.1);
}

#close-video-modal::before,
#close-video-modal::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 3px;
  background: var(--text-primary);
  border-radius: 2px;
}

#close-video-modal::before {
  transform: rotate(45deg);
}

#close-video-modal::after {
  transform: rotate(-45deg);
}

/* Error and No Videos Messages */
.error-message,
.no-videos-message {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem;
  background: var(--background-card);
  border-radius: 16px;
  border: 1px solid var(--border-color);
}

.error-message p,
.no-videos-message p {
  color: var(--text-secondary);
  font-size: 1.125rem;
  margin: 0;
}

/* Loading State */
.video-card.loading .video-thumbnail {
  background: linear-gradient(
    90deg,
    var(--background-light) 0%,
    #e5e7eb 50%,
    var(--background-light) 100%
  );
  background-size: 200% 100%;
  animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Responsive Design */
@media screen and (max-width: 640px) {
  .videos-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  #close-video-modal {
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
  }
  
  #close-video-modal::before,
  #close-video-modal::after {
    width: 20px;
  }
  
  .fullscreen-video-modal video {
    max-width: 95%;
    max-height: 85vh;
  }
}



/* Video Controls Hint */
.video-controls-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-size: 0.875rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 10001;
}

.fullscreen-video-modal.active .video-controls-hint {
  animation: fadeInOut 3s ease;
}

@keyframes fadeInOut {
  0%, 100% {
    opacity: 0;
  }
  10%, 90% {
    opacity: 1;
  }
}