/* ============================================================
   ANIMATIONS — CSS-only, no animation libraries
   ============================================================ */

/* ── Scroll-triggered fade/slide base ── */
.anawim-animate {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}
.anawim-animate.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.anawim-animate--delay-1 { transition-delay: 100ms; }
.anawim-animate--delay-2 { transition-delay: 200ms; }
.anawim-animate--delay-3 { transition-delay: 300ms; }
.anawim-animate--delay-4 { transition-delay: 400ms; }
.anawim-animate--delay-5 { transition-delay: 500ms; }

.anawim-animate--left {
  transform: translateX(-24px);
}
.anawim-animate--left.is-visible {
  transform: translateX(0);
}
.anawim-animate--right {
  transform: translateX(24px);
}
.anawim-animate--right.is-visible {
  transform: translateX(0);
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .anawim-animate {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ── Hero scroll indicator bounce ── */
@keyframes scroll-bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); opacity: 0.5; }
  50% { transform: translateX(-50%) translateY(6px); opacity: 1; }
}

/* ── Counter number pulse on load ── */
@keyframes counter-pop {
  0% { transform: scale(0.85); opacity: 0; }
  70% { transform: scale(1.04); }
  100% { transform: scale(1); opacity: 1; }
}
.counter-visible {
  animation: counter-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* ── Card hover accent line ── */
.anawim-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-secondary), var(--color-accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-base);
}
.anawim-card:hover::after { transform: scaleX(1); }

/* ── Ripple on donate button click ── */
.btn-ripple {
  position: relative;
  overflow: hidden;
}
.btn-ripple::after {
  content: '';
  position: absolute;
  width: 120%;
  padding-top: 120%;
  border-radius: 50%;
  background-color: rgba(255,255,255,0.25);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  opacity: 0;
}
.btn-ripple.rippling::after {
  animation: ripple 0.4s ease-out forwards;
}
@keyframes ripple {
  0% { transform: translate(-50%, -50%) scale(0); opacity: 1; }
  100% { transform: translate(-50%, -50%) scale(1); opacity: 0; }
}

/* ── Gradient text utility ── */
.text-gradient {
  background: linear-gradient(135deg, var(--color-secondary), var(--color-accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── Stat item accent underline ── */
.anawim-stat-item {
  position: relative;
}
.anawim-stat-item::after {
  content: '';
  position: absolute;
  bottom: var(--space-5);
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 2rem;
  height: 2px;
  background-color: var(--color-secondary);
  transition: transform var(--transition-base);
  border-radius: var(--radius-full);
}
.anawim-stat-item.is-visible::after {
  transform: translateX(-50%) scaleX(1);
  transition-delay: 600ms;
}

/* ── Smooth image zoom on section load ── */
.anawim-hero__bg {
  animation: hero-zoom 12s ease-in-out infinite alternate;
}
@media (prefers-reduced-motion: reduce) {
  .anawim-hero__bg { animation: none; }
}
@keyframes hero-zoom {
  from { transform: scale(1); }
  to   { transform: scale(1.04); }
}

/* ── Focus ring (accessibility) ── */
:focus-visible {
  outline: 3px solid var(--color-secondary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}
