/* ============================================
   FLIPBOOK PROFESSIONNEL - STYLES
   ============================================ */

.flipbook-section {
  padding: 100px 0;
  background: linear-gradient(135deg, var(--ivoire) 0%, #faf8f3 100%);
}

.flipbook-header {
  text-align: center;
  margin-bottom: 80px;
}

.flipbook-header .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--or);
  font-weight: 600;
  margin-bottom: 18px;
}

.flipbook-header h2 {
  font-size: clamp(2rem, 3.6vw, 2.9rem);
  margin-bottom: 15px;
}

.flipbook-header p {
  color: var(--gris-douala);
  font-size: 16px;
}

/* Flipbook Container */
.flipbook-container {
  perspective: 1500px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin-bottom: 60px;
  flex-wrap: wrap;
}

/* Boutons Navigation */
.flipbook-nav-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid var(--or);
  background: var(--blanc);
  color: var(--or);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  font-weight: bold;
}

.flipbook-nav-btn:hover:not(:disabled) {
  background: var(--or);
  color: var(--noir);
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(176, 141, 87, 0.3);
}

.flipbook-nav-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Le Livre */
#flipbook-wrapper {
  width: 100%;
  max-width: 900px;
  perspective: 1500px;
  position: relative;
  display: flex;
  justify-content: center;
}

.flipbook-spine {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to right,
    rgba(0,0,0,0.4),
    rgba(0,0,0,0.15),
    rgba(0,0,0,0.15));
  z-index: 10;
  transform: translateX(-0.5px);
  box-shadow:
    -2px 0 8px rgba(0,0,0,0.1),
    2px 0 8px rgba(0,0,0,0.1);
}

.flipbook-pages {
  display: flex;
  gap: 0;
  justify-content: center;
  width: 100%;
}

.flipbook-page {
  width: 45%;
  aspect-ratio: 210/297;
  background: #fefdfb;
  position: relative;
  overflow: hidden;
  transition: transform 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  box-shadow:
    0 10px 40px rgba(0,0,0,0.2),
    inset 0 1px 0 rgba(255,255,255,0.8);
}

.flipbook-page img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Page Gauche */
#page-left {
  transform-origin: right center;
  box-shadow:
    -10px 5px 35px rgba(0,0,0,0.25),
    inset 2px 0 8px rgba(0,0,0,0.05),
    inset -40px 0 60px rgba(0,0,0,0.08);
}

#page-left::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: linear-gradient(to right, rgba(0,0,0,0.05), transparent 50%);
  pointer-events: none;
}

/* Page Droite */
#page-right {
  transform-origin: left center;
  box-shadow:
    10px 5px 35px rgba(0,0,0,0.25),
    inset -2px 0 8px rgba(0,0,0,0.05),
    inset 40px 0 60px rgba(0,0,0,0.08);
}

#page-right::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: linear-gradient(to left, rgba(0,0,0,0.05), transparent 50%);
  pointer-events: none;
}

/* Page Counter */
.flipbook-counter {
  text-align: center;
  display: inline-block;
  background: var(--noir);
  color: var(--blanc);
  padding: 12px 28px;
  border-radius: 30px;
  font-size: 13px;
  letter-spacing: 0.1em;
  font-weight: 600;
  margin: 0 auto;
  display: block;
}

/* ============================================
   RESPONSIVE - TABLET
   ============================================ */

@media (max-width: 1024px) {
  .flipbook-section {
    padding: 80px 0;
  }

  .flipbook-page {
    width: 50%;
  }

  .flipbook-nav-btn {
    width: 44px;
    height: 44px;
    font-size: 18px;
  }
}

/* ============================================
   RESPONSIVE - MOBILE
   ============================================ */

@media (max-width: 768px) {
  .flipbook-section {
    padding: 60px 0;
  }

  .flipbook-header {
    margin-bottom: 50px;
  }

  .flipbook-container {
    flex-direction: column;
    gap: 30px;
    margin-bottom: 40px;
  }

  #flipbook-wrapper {
    order: 2;
    max-width: 100%;
    width: 100%;
  }

  .flipbook-pages {
    flex-direction: column;
    gap: 30px;
    width: 100%;
  }

  /* Afficher les pages empilées verticalement en pleine largeur sur mobile */
  #page-left {
    display: block;
    width: 100%;
  }

  #page-right {
    width: 100%;
    box-shadow:
      0 15px 50px rgba(0,0,0,0.3),
      inset -2px 0 8px rgba(0,0,0,0.05);
  }

  /* Navigation en HAUT en mobile */
  .flipbook-nav-wrapper {
    order: 1;
    display: flex;
    justify-content: center;
    gap: 15px;
    width: 100%;
  }

  .flipbook-nav-btn {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }

  .flipbook-page {
    aspect-ratio: auto;
    max-height: 500px;
  }

  /* Cache la navigation sur les côtés en mobile */
  .flipbook-nav-btn.side-nav {
    display: none;
  }
}

/* ============================================
   RESPONSIVE - PETIT MOBILE
   ============================================ */

@media (max-width: 480px) {
  .flipbook-section {
    padding: 40px 0;
  }

  .flipbook-header {
    margin-bottom: 30px;
  }

  .flipbook-header h2 {
    font-size: 1.5rem;
  }

  .flipbook-page {
    max-height: 450px;
  }

  .flipbook-nav-btn {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }
}
