/* ============================================================
   SocialAI Manager — Animations
   Keyframes + AOS orchestration. Loaded after style.css.
   ============================================================ */

/* ---------- Keyframes ---------- */
@keyframes floatBlob {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(30px, -30px) scale(1.05); }
  66%      { transform: translate(-20px, 20px) scale(.97); }
}

@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

@keyframes barGrow {
  from { height: 0; opacity: 0; }
  to   { opacity: .85; }
}

@keyframes shimmer {
  0%   { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

@keyframes toastIn {
  from { opacity: 0; transform: translateX(40px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes toastOut {
  to { opacity: 0; transform: translateX(40px); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes pulseRing {
  0%   { box-shadow: 0 0 0 0 rgba(99, 102, 241, .4); }
  70%  { box-shadow: 0 0 0 12px rgba(99, 102, 241, 0); }
  100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Utility animation classes ---------- */
.spin    { animation: spin 1s linear infinite; }
.float-y { animation: floatY 5s ease-in-out infinite; }
.pulse   { animation: pulseRing 2s infinite; }

/* Generic entrance fallback (used by JS reveal() when AOS isn't loaded) */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s var(--ease-out), transform .7s var(--ease-out);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ---------- AOS overrides / harmonization ---------- */
/* AOS injects opacity:0 on [data-aos]. We tune offsets & easing. */
[data-aos] { transition-property: transform, opacity; }
[data-aos="fade-up"]    { transform: translateY(28px); }
[data-aos="fade-down"]  { transform: translateY(-28px); }
[data-aos="fade-right"] { transform: translateX(-28px); }
[data-aos="fade-left"]  { transform: translateX(28px); }
[data-aos="zoom-in"]    { transform: scale(.92); }

/* Slightly snappier default duration */
body[data-aos-duration] [data-aos],
[aos-duration] { transition-duration: .7s; }

/* ---------- Interactive micro-animations ---------- */
.nav-link,
.feature-card,
.price-card,
.kpi-card,
.stat-card,
.testimonial,
.story {
  will-change: transform;
}

/* Theme toggle icon smooth swap */
.theme-toggle i { transition: transform var(--transition), opacity var(--transition); }

/* Underline grow on footer/foot links */
.foot-links a { position: relative; }
.foot-links a::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 1px; width: 0;
  background: var(--brand-500); transition: width var(--transition);
}
.foot-links a:hover::after { width: 100%; }

/* Network strip subtle hover lift */
.networks-row .net { transition: transform var(--transition), color var(--transition); }

/* Spinner used in buttons / loading states */
.btn-spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  display: inline-block;
}

/* Skeleton shimmer base (size set inline per use) */
.skeleton { min-height: 12px; }

/* Reduced motion: disable decorative animation, keep content visible */
@media (prefers-reduced-motion: reduce) {
  [data-aos] { opacity: 1 !important; transform: none !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .blob, .float-y, .pulse, .preview-badge { animation: none !important; }
}
