/* ===========================
   NIEC Animations - animations.css
   Light Theme Adjustments
   =========================== */

/* --- Keyframe Animations --- */
@keyframes blobFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -20px) scale(1.05); }
    50% { transform: translate(-15px, 15px) scale(0.95); }
    75% { transform: translate(20px, 10px) scale(1.02); }
}

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

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

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

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-12px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

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

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-4px); }
    40% { transform: translateX(4px); }
    60% { transform: translateX(-4px); }
    80% { transform: translateX(4px); }
}

@keyframes successPop {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 2px 12px rgba(173,15,45,0.1); }
    50% { box-shadow: 0 4px 24px rgba(173,15,45,0.2); }
}

/* --- Apply Animations to Elements --- */
.hero-blob-1 { animation: blobFloat 10s ease-in-out infinite; }
.hero-blob-2 { animation: blobFloat 12s ease-in-out infinite 2s; }
.hero-blob-3 { animation: blobFloat 8s ease-in-out infinite 4s; }
.mockup-card { animation: floatY 6s ease-in-out infinite; }
.cta-banner-inner::before { animation: shimmer 10s ease-in-out infinite; }

/* --- Scroll Reveal Classes --- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.5s cubic-bezier(0.22, 1, 0.36, 1), transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.stagger-container .reveal:nth-child(1) { transition-delay: 0ms; }
.stagger-container .reveal:nth-child(2) { transition-delay: 80ms; }
.stagger-container .reveal:nth-child(3) { transition-delay: 160ms; }
.stagger-container .reveal:nth-child(4) { transition-delay: 240ms; }
.stagger-container .reveal:nth-child(5) { transition-delay: 320ms; }
.stagger-container .reveal:nth-child(6) { transition-delay: 400ms; }
.stagger-container .reveal:nth-child(7) { transition-delay: 480ms; }
.stagger-container .reveal:nth-child(8) { transition-delay: 560ms; }
.stagger-container .reveal:nth-child(9) { transition-delay: 640ms; }

/* --- Hero Stagger --- */
.hero-stagger > * {
    opacity: 0;
    transform: translateY(16px);
    animation: fadeInUp 0.5s ease-out forwards;
}
.hero-stagger > *:nth-child(1) { animation-delay: 0ms; }
.hero-stagger > *:nth-child(2) { animation-delay: 100ms; }
.hero-stagger > *:nth-child(3) { animation-delay: 200ms; }
.hero-stagger > *:nth-child(4) { animation-delay: 300ms; }
.hero-stagger > *:nth-child(5) { animation-delay: 400ms; }

/* --- Hover Micro-interactions --- */
.gradient-btn { transition: transform 200ms ease, filter 200ms ease, box-shadow 250ms ease; }
.ghost-btn { transition: border-color 250ms ease, color 200ms ease; }
.glass-card { transition: transform 250ms ease-out, border-color 250ms ease-out, box-shadow 250ms ease-out; }

/* Nav link underline grow */
.nav-link::after { transition: width 200ms ease, left 200ms ease; }

/* Form error shake */
.form-input.error,
.form-select.error,
.form-textarea.error {
    animation: shake 0.4s ease;
}

/* Accordion chevron */
.accordion-trigger .chevron { transition: transform 200ms ease; }

/* CTA banner gradient position */
.cta-banner-inner { background-size: 200% 100%; }

/* Page enter animation */
.page-enter {
    opacity: 0;
    transform: translateY(12px);
    animation: fadeInUp 0.4s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .hero-blob-1, .hero-blob-2, .hero-blob-3 { animation: none; opacity: 0.1; }
    .mockup-card { animation: none; }
    .marquee-track { animation: none; }
    .cta-banner-inner::before { animation: none; }
    .reveal { opacity: 1; transform: none; transition: none; }
    html { scroll-behavior: auto; }
}
