/* ================================================= */
/* ===== VIRALPICS — SECTION FAQ ================ */
/* ===== Vidéo sticky + accordéons cascade ====== */
/* ===== Panneau liquid glass arrondi ============ */
/* ================================================= */

@import url('https://fonts.googleapis.com/css2?family=League+Spartan:wght@400;500;600;700;800;900&display=swap');

.faq-section {
  position: relative;
  z-index: 20;
  padding: 80px 24px 120px;
  margin: 0 auto;
  max-width: 1320px;

  /* Panneau liquid glass d'origine — arrondi sur les 4 coins */
  border-radius: 44px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  box-shadow: var(--liquid-glass-shadow);
  overflow: hidden;
}

/* ============================== */
/* ===== ÉTATS INITIAUX (cascade) */
/* ============================== */
.reveal-enabled .faq-heading,
.reveal-enabled .faq-video-sticky,
.reveal-enabled .faq-item {
  opacity: 0;
  transform: translateY(26px);
  transition:
  opacity 0.6s cubic-bezier(0.16, 0.84, 0.44, 1),
  transform 0.6s cubic-bezier(0.16, 0.84, 0.44, 1);
  will-change: opacity, transform;
}

/* Index des items pour décalage progressif */
.faq-item:nth-child(1) { --item-i: 0; }
.faq-item:nth-child(2) { --item-i: 1; }
.faq-item:nth-child(3) { --item-i: 2; }
.faq-item:nth-child(4) { --item-i: 3; }
.faq-item:nth-child(5) { --item-i: 4; }
.faq-item:nth-child(6) { --item-i: 5; }

/* Séquence de révélation */
.faq-section.is-visible .faq-heading {
  opacity: 1;
  transform: none;
  transition-delay: 0s;
}

.faq-section.is-visible .faq-video-sticky {
  opacity: 1;
  transform: none;
  transition-delay: 0.12s;
}

.faq-section.is-visible .faq-item {
  opacity: 1;
  transform: none;
  transition-delay: calc(0.34s + var(--item-i, 0) * 0.08s);
}

@media (prefers-reduced-motion: reduce) {
  .faq-heading,
  .faq-video-sticky,
  .faq-item {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ============================== */
/* ===== TITRE =================== */
/* ============================== */
.faq-heading {
  position: relative;
  z-index: 1;
  text-align: left;
  margin-bottom: 48px;
}

.faq-heading h2 {
  font-family: 'League Spartan', sans-serif;
  font-size: clamp(3.2rem, 7vw, 5.6rem);
  font-weight: 900;
  color: var(--ink);
  margin: 0;
  line-height: 1.05;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.faq-gradient {
  background: linear-gradient(95deg, #ff0b9e 4%, #c22bd4 48%, #7e69ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ============================== */
/* ===== CONTENEUR DEUX COLONNES = */
/* ============================== */
.faq-container {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
}

/* COLONNE VIDÉO (gauche) */
.faq-video-column {
  display: flex;
  align-items: flex-start;
}

.faq-video-sticky {
  position: sticky;
  top: 80px;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: var(--liquid-glass-shadow);
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
}

.faq-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* COLONNE ACCORDÉONS (droite) */
.faq-accordion-column {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* ============================== */
/* ===== ITEM & TRIGGER ========== */
/* ============================== */
.faq-item {
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, 0.03);
  box-shadow: var(--liquid-glass-shadow-compact);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
}

.faq-item:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: var(--liquid-glass-shadow-compact);
}

.faq-item[open] {
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.06);
}

.faq-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 18px 24px;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-family: 'Poppins', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
  transition: color 0.2s ease;
  min-height: 56px;
}

.faq-trigger:hover {
  color: var(--ink);
}

.faq-trigger__text {
  flex: 1;
  text-align: left;
}

.faq-trigger__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  margin-left: 16px;
  flex-shrink: 0;
  transition: transform 0.3s cubic-bezier(0.16, 0.84, 0.44, 1);
  position: relative;
}

.faq-trigger__icon::before,
.faq-trigger__icon::after {
  content: '';
  position: absolute;
  background: currentColor;
}

.faq-trigger__icon::before {
  width: 12px;
  height: 2px;
}

.faq-trigger__icon::after {
  width: 2px;
  height: 12px;
}

.faq-item[open] .faq-trigger__icon {
  transform: rotate(45deg);
}

/* ============================== */
/* ===== CONTENU ================= */
/* ============================== */
.faq-content {
  overflow: hidden;
  padding: 0 24px 20px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted);
  animation: faqReveal 0.3s ease forwards;
}

@keyframes faqReveal {
  from {
    opacity: 0;
    max-height: 0;
  }
  to {
    opacity: 1;
    max-height: 500px;
  }
}

.faq-content p {
  margin: 0;
}

/* ============================== */
/* ===== RESPONSIVE ============== */
/* ============================== */
@media (max-width: 1024px) {
  .faq-container {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .faq-video-sticky {
    position: relative;
    top: auto;
  }
}

@media (max-width: 768px) {
  .faq-section {
    padding: 56px 16px 84px;
    border-radius: 32px;
  }

  .faq-heading {
    margin-bottom: 32px;
  }

  .faq-heading h2 {
    font-size: clamp(2.2rem, 9vw, 2.8rem);
  }

  .faq-container {
    gap: 24px;
  }

  .faq-trigger {
    padding: 16px 18px;
    font-size: 0.95rem;
    min-height: 52px;
  }

  .faq-trigger__icon {
    width: 20px;
    height: 20px;
  }

  .faq-trigger__icon::before {
    width: 10px;
  }

  .faq-trigger__icon::after {
    width: 2px;
    height: 10px;
  }

  .faq-content {
    padding: 0 18px 16px;
    font-size: 0.9rem;
  }

  .faq-item {
    margin-bottom: 10px;
  }
}