/**
 * VBedits — animations library.
 *
 * Reusable @keyframes + animation utility classes. Loaded non-blocking from
 * site_header.php so it doesn't delay first paint.
 *
 * Most site components have their own scoped animations in store.css. This
 * file is for the general-purpose ones (fade-in, scale-in, slide-up, etc.)
 * that any new feature can lean on without redeclaring keyframes.
 */

/* ── Keyframes (catalogue) ─────────────────────────────────────────────── */
@keyframes vbe-fade-in        { from { opacity: 0; }                          to { opacity: 1; } }
@keyframes vbe-fade-up        { from { opacity: 0; transform: translateY(8px); }   to { opacity: 1; transform: none; } }
@keyframes vbe-fade-down      { from { opacity: 0; transform: translateY(-8px); }  to { opacity: 1; transform: none; } }
@keyframes vbe-scale-in       { from { opacity: 0; transform: scale(.96); }   to { opacity: 1; transform: scale(1); } }
@keyframes vbe-slide-right    { from { transform: translateX(-12px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes vbe-pulse-accent   { 0%,100% { box-shadow: 0 0 0 0 rgba(249,115,22,.35); } 50% { box-shadow: 0 0 0 8px rgba(249,115,22,0); } }
@keyframes vbe-shimmer        { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }
@keyframes vbe-spin           { to { transform: rotate(360deg); } }

/* Floating subtle bob — for emojis, icons, anything that needs to "breathe" */
@keyframes vbe-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }

/* ── Utility classes (apply to any element to trigger the animation) ──── */
.an-fade-in     { animation: vbe-fade-in     .35s ease both; }
.an-fade-up     { animation: vbe-fade-up     .45s var(--ease-standard, ease) both; }
.an-fade-down   { animation: vbe-fade-down   .45s var(--ease-standard, ease) both; }
.an-scale-in    { animation: vbe-scale-in    .35s var(--ease-elastic,  ease-out) both; }
.an-slide-right { animation: vbe-slide-right .35s var(--ease-standard, ease) both; }
.an-pulse       { animation: vbe-pulse-accent 1.6s ease-out infinite; }
.an-spin        { animation: vbe-spin 1s linear infinite; }
.an-bob         { animation: vbe-bob 2.4s ease-in-out infinite; }

/* Delays — combine with the above for staggered reveals */
.an-delay-100 { animation-delay: .10s; }
.an-delay-200 { animation-delay: .20s; }
.an-delay-300 { animation-delay: .30s; }
.an-delay-400 { animation-delay: .40s; }
.an-delay-500 { animation-delay: .50s; }

/* Shimmer "skeleton" loader (apply on a placeholder element while data loads) */
.an-shimmer {
  background: linear-gradient(90deg,
    color-mix(in srgb, var(--text3, #888) 8%,  transparent) 0%,
    color-mix(in srgb, var(--text3, #888) 22%, transparent) 50%,
    color-mix(in srgb, var(--text3, #888) 8%,  transparent) 100%);
  background-size: 200% 100%;
  animation: vbe-shimmer 1.4s linear infinite;
  border-radius: 6px;
}

/* prefers-reduced-motion is handled centrally in transitions.css */
