/* /var/www/e3/website/css/animations.css — keyframes + [data-animate] states */

@keyframes fadeUp {
  from { opacity: 0; transform: translate3d(0, 24px, 0); }
  to   { opacity: 1; transform: translate3d(0, 0, 0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes slideInLeft {
  from { opacity: 0; transform: translate3d(-40px, 0, 0); }
  to   { opacity: 1; transform: translate3d(0, 0, 0); }
}
@keyframes slideInRight {
  from { opacity: 0; transform: translate3d(40px, 0, 0); }
  to   { opacity: 1; transform: translate3d(0, 0, 0); }
}
@keyframes popIn {
  0%   { opacity: 0; transform: scale(.85); }
  60%  { opacity: 1; transform: scale(1.04); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes pulseGlow {
  0%, 100% { box-shadow: var(--glow-soft); }
  50%      { box-shadow: var(--glow); }
}
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}
@keyframes spinSlow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes textGlow {
  0%, 100% { text-shadow: 0 0 12px rgba(110,240,160,.3); }
  50%      { text-shadow: 0 0 24px rgba(110,240,160,.6); }
}

/* [data-animate] — initial state, JS adds .in-view to trigger */
[data-animate]              { opacity: 0; will-change: opacity, transform; }
[data-animate="fade-up"]    { transform: translate3d(0, 24px, 0); }
[data-animate="fade-in"]    { transform: none; }
[data-animate="slide-left"] { transform: translate3d(-40px, 0, 0); }
[data-animate="slide-right"]{ transform: translate3d(40px, 0, 0); }
[data-animate="pop"]        { transform: scale(.9); }

[data-animate].in-view {
  opacity: 1;
  transform: none;
  transition:
    opacity var(--slow) var(--ease),
    transform var(--slow) var(--ease);
}

[data-animate-delay="100"].in-view { transition-delay: 100ms; }
[data-animate-delay="200"].in-view { transition-delay: 200ms; }
[data-animate-delay="300"].in-view { transition-delay: 300ms; }
[data-animate-delay="400"].in-view { transition-delay: 400ms; }
[data-animate-delay="500"].in-view { transition-delay: 500ms; }

.float  { animation: floatY 6s ease-in-out infinite; }
.spin-slow { animation: spinSlow 24s linear infinite; }
.pulse  { animation: pulseGlow 3.2s ease-in-out infinite; }
.glow-text { animation: textGlow 4s ease-in-out infinite; }

.shimmer-text {
  background: linear-gradient(90deg,
    var(--green-300) 0%,
    var(--green-50)  50%,
    var(--green-300) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shimmer 6s linear infinite;
}

@media (prefers-reduced-motion: reduce) {
  .float, .spin-slow, .pulse, .glow-text, .shimmer-text { animation: none !important; }
  [data-animate] { opacity: 1 !important; transform: none !important; }
}
