/* ==========================================================================
   animations.css — keyframes + scroll-reveal utility classes
   ========================================================================== */

@keyframes float{
  0%, 100%{ transform: translateY(0px) rotateX(0deg); }
  50%{ transform: translateY(-14px) rotateX(1deg); }
}

@keyframes blink{
  0%, 100%{ opacity:1; }
  50%{ opacity:0; }
}

@keyframes pulse{
  0%{ box-shadow: 0 0 0 0 rgba(34,197,94,.55); }
  70%{ box-shadow: 0 0 0 8px rgba(34,197,94,0); }
  100%{ box-shadow: 0 0 0 0 rgba(34,197,94,0); }
}

@keyframes scrollcue{
  0%{ opacity:1; top:6px; }
  100%{ opacity:0; top:18px; }
}

@keyframes spin-in{
  from{ transform: rotate(-90deg) scale(0.7); opacity:0; }
  to{ transform: rotate(0) scale(1); opacity:1; }
}

/* Scroll reveal */
.reveal{
  opacity:0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.reveal.in-view{ opacity:1; transform: translateY(0); }

.reveal-left{ opacity:0; transform: translateX(-30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal-left.in-view{ opacity:1; transform: translateX(0); }

.reveal-right{ opacity:0; transform: translateX(30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal-right.in-view{ opacity:1; transform: translateX(0); }

.reveal-scale{ opacity:0; transform: scale(0.92); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal-scale.in-view{ opacity:1; transform: scale(1); }

/* Stagger children delays (used with data-stagger on parent + .reveal on children) */
.stagger > *:nth-child(1){ transition-delay: 0ms; }
.stagger > *:nth-child(2){ transition-delay: 90ms; }
.stagger > *:nth-child(3){ transition-delay: 180ms; }
.stagger > *:nth-child(4){ transition-delay: 270ms; }
.stagger > *:nth-child(5){ transition-delay: 360ms; }
.stagger > *:nth-child(6){ transition-delay: 450ms; }

/* Skill ring spin-in for icons */
.skill-cat-icon{ animation: none; }
.skill-cat.in-view .skill-cat-icon{ animation: spin-in 0.6s cubic-bezier(.4,0,.2,1) both; }

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .hero-card{ animation: none; }
}
