/* ==========================================================================
   ANIMATIONS & SCROLL INTERACTIONS
   Smooth buttery scroll reveals, 3D card perspective, tactile motion
   Strictly NO Glow Effects
   ========================================================================== */

/* Smooth Scroll Reveal (Progressive Enhancement - Visible by default to eliminate any blank black voids) */
.reveal-on-scroll {
  opacity: 1;
  transform: none;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

/* Only when JavaScript actively activates scroll reveal, animate elements that are not yet revealed */
html.js-reveal-active .reveal-on-scroll:not(.is-revealed) {
  opacity: 0;
  transform: translateY(22px);
}

.reveal-on-scroll.is-revealed {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* Stagger delays */
.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }
.delay-400 { transition-delay: 0.4s; }

/* Subtle floating animation for 3D badges and markers */
@keyframes subtleFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-5px);
  }
}

.floating-subtle {
  animation: subtleFloat 5s ease-in-out infinite;
}



/* Delicate Steam Drift Simulation for Canvas Backgrounds */
@keyframes steamDrift {
  0% {
    opacity: 0.15;
    transform: translateY(0) scaleX(1);
  }
  50% {
    opacity: 0.3;
    transform: translateY(-12px) scaleX(1.08);
  }
  100% {
    opacity: 0.15;
    transform: translateY(0) scaleX(1);
  }
}

.steam-drift {
  animation: steamDrift 7s ease-in-out infinite;
}

/* Interactive Cursor / Magnetic Feedback */
@media (hover: hover) and (pointer: fine) {
  .btn-primary, .btn-outline, .menu-tab-btn, .brew-method-btn {
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease;
  }
}

/* Reduced Motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .reveal-on-scroll {
    opacity: 1 !important;
    transform: none !important;
  }
}
