/* ============================================================
   Green Line — Animations
   Каскадное появление, scroll-reveal, микро-взаимодействия.
   ============================================================ */

@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes msg-in {
  from { opacity: 0; transform: translateY(10px) scale(.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes blink {
  0%, 80%, 100% { opacity: .25; transform: scale(.8); }
  40% { opacity: 1; transform: scale(1); }
}
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34,197,94,.4); }
  50%      { box-shadow: 0 0 0 6px rgba(34,197,94,0); }
}

/* Каскадное появление при загрузке: ставим .reveal на элементы,
   JS (IntersectionObserver) добавит .in когда элемент войдёт во вьюпорт. */
.reveal { opacity: 0; transform: translateY(16px); }
.reveal.in { animation: fade-up .6s var(--ease) forwards; }

/* Staggered задержки для группы карточек */
.stagger > * { opacity: 0; }
.stagger > *.in { animation: fade-up .55s var(--ease) forwards; }
.stagger > *:nth-child(1).in { animation-delay: .03s; }
.stagger > *:nth-child(2).in { animation-delay: .09s; }
.stagger > *:nth-child(3).in { animation-delay: .15s; }
.stagger > *:nth-child(4).in { animation-delay: .21s; }
.stagger > *:nth-child(5).in { animation-delay: .27s; }
.stagger > *:nth-child(6).in { animation-delay: .33s; }
.stagger > *:nth-child(7).in { animation-delay: .39s; }
.stagger > *:nth-child(8).in { animation-delay: .45s; }
.stagger > *:nth-child(n+9).in { animation-delay: .5s; }

/* hover-glow на интерактивных карточках уже задан в components;
   тут — общий «дышащий» индикатор для онлайн-точек и т.п. */
.live-dot { animation: pulse-glow 2.4s infinite; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .reveal, .stagger > * { opacity: 1 !important; transform: none !important; }
}
