/* Animations */

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes pageUnroll {
  from { transform: translateX(12px); opacity: 0.8; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes pageTurnLeft {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes lightboxIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes coinFlip {
  0% {
    transform: rotateY(0deg) scale(1);
  }
  50% {
    transform: rotateY(180deg) scale(1.15);
  }
  100% {
    transform: rotateY(360deg) scale(1);
  }
}

/* Page turn animation on left page */
.page-turning #section-title,
.page-turning #section-illustration {
  animation: pageTurnLeft 0.35s ease-out forwards;
}

/* Reduced motion accessibility */
@media (prefers-reduced-motion: reduce) {
  .page-turning #section-title,
  .page-turning #section-illustration {
    animation: none;
    opacity: 1;
  }

  @keyframes pageUnroll {
    from { transform: none; opacity: 1; }
    to { transform: none; opacity: 1; }
  }

  @keyframes coinFlip {
    from { transform: none; }
    to { transform: none; }
  }
}

