/* ===============================================
   CAROUSELS ET ÉLÉMENTS DYNAMIQUES - MENARA
   Style oriental avec animations fluides
   =============================================== */

/* Carousel principal */
.carousel-container {
  position: relative;
  overflow: hidden;
  border-radius: 0;
  border: 1px solid #e5e7eb;
  background: var(--background-card);
}

.carousel-wrapper {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.carousel-slide {
  min-width: 100%;
  position: relative;
}

.carousel-slide img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  display: block;
}

.carousel-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: white;
  padding: 40px 32px 32px;
}

.carousel-content h3 {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 12px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.carousel-content p {
  font-size: 16px;
  line-height: 1.5;
  margin: 0;
  opacity: 0.9;
}

/* Navigation du carousel */
.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: #d1d5db;
  transition: all 0.3s ease;
  z-index: 10;
  border-radius: 0;
}

.carousel-nav:hover {
  color: #9ca3af;
  transform: translateY(-50%) scale(1.1);
}

.carousel-nav.prev {
  left: 20px;
}

.carousel-nav.next {
  right: 20px;
}

.carousel-nav svg {
  width: 32px;
  height: 32px;
  transition: all 0.3s ease;
}

.carousel-nav:active {
  transform: translateY(-50%) scale(0.95);
}

.carousel-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: translateY(-50%);
}

/* Indicateurs du carousel */
.carousel-indicators {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.carousel-indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-indicator.active {
  background: var(--accent);
  transform: scale(1.2);
}

/* Grille d'articles avec carousels */
.articles-carousel {
  position: relative;
  margin: 40px 0;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 32px;
  margin-top: 32px;
}

/* Cartes d'articles dynamiques */
.article-card {
  background: var(--background-card);
  border-radius: 0;
  overflow: hidden;
  
  transition: all 0.3s ease;
  position: relative;
  height: 450px;
}

.article-card-image {
  position: relative;
  width: 100%;
  padding-top: 60%;
  overflow: hidden;
}

.article-card-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.article-card-category {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(255, 255, 255, 0.92);
  color: #0a276a;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow: 0 8px 20px rgba(10, 39, 106, 0.18);
}

.article-card-body {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  height: 100%;
}

.article-card-title {
  font-family: 'Inter', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0;
  color: #0a276a;
  line-height: 1.3;
}

.article-card-excerpt {
  color: #4b5563;
  line-height: 1.6;
  margin: 0;
  font-size: 0.97rem;
}

.article-card-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-top: auto;
  font-size: 0.85rem;
  color: #6b7280;
  border-top: none;
  padding-top: 0;
}

/* Carousel d'événements */
.events-carousel .event-card {
  background: var(--background-card);
  border-radius: 0;
  padding: 32px;
  margin: 16px;
  
  transition: all 0.3s ease;
  min-height: 300px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.events-carousel .event-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gray-300);
}

.events-carousel .event-card:hover {
  transform: translateY(-6px);
  
}

.event-date-big {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.event-date-circle {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: var(--gray-200);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--black);
  font-weight: 700;
}

.event-date-day {
  font-size: 24px;
  line-height: 1;
}

.event-date-month {
  font-size: 12px;
  text-transform: uppercase;
}

.event-title {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 600;
  margin: 0 0 16px;
  color: var(--text-primary);
}

.event-description {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.event-location {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 16px;
}

/* Carousel de podcasts */
.podcast-carousel {
  margin: 40px 0;
}

.podcast-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.podcast-card {
  background: var(--background-card);
  border-radius: 0;
  overflow: hidden;
  
  transition: all 0.3s ease;
  position: relative;
}

.podcast-card:hover {
  transform: translateY(-4px);
  
}

.podcast-artwork {
  position: relative;
  height: 200px;
  background: var(--gray-100);
  display: flex;
  align-items: center;
  justify-content: center;
}

.podcast-play-button {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.podcast-play-button:hover {
  background: rgba(0,0,0,0.9);
  transform: scale(1.1);
}

.podcast-info {
  padding: 24px;
}

.podcast-title {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--text-primary);
}

.podcast-description {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
  margin-bottom: 16px;
}

.podcast-duration {
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
}

/* Animations et effets */
@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.animate-slide-up {
  animation: slideInUp 0.6s ease-out;
}

.animate-fade-scale {
  animation: fadeInScale 0.5s ease-out;
}

/* Section "Articles en vedette" */
.featured-articles {
  background: #ffffff;
  padding: 80px 0;
  position: relative;
}

.featured-articles::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23f2b844' fill-opacity='0.02'%3E%3Ccircle cx='30' cy='30' r='4'/%3E%3Ccircle cx='10' cy='10' r='4'/%3E%3Ccircle cx='50' cy='10' r='4'/%3E%3Ccircle cx='10' cy='50' r='4'/%3E%3Ccircle cx='50' cy='50' r='4'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.featured-articles .container {
  position: relative;
  z-index: 1;
}

/* Responsive */
@media (max-width: 768px) {
  .carousel-nav {
    padding: 0.25rem;
  }
  
  .carousel-nav svg {
    width: 28px;
    height: 28px;
  }
  
  .carousel-nav.prev {
    left: 10px;
  }
  
  .carousel-nav.next {
    right: 10px;
  }
  
  .articles-grid {
    grid-template-columns: 1fr;
  }
  
  .article-card {
    height: auto;
  }
  
  .article-card-body {
    height: auto;
  }
  
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-ctas {
    justify-content: center;
  }
}