@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(18px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scale-in {
    from {
        opacity: 0;
        transform: scale(0.96);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

@keyframes pulse-ring {
    0% { box-shadow: 0 0 0 0 rgba(45, 212, 191, 0.45); }
    70% { box-shadow: 0 0 0 12px rgba(45, 212, 191, 0); }
    100% { box-shadow: 0 0 0 0 rgba(45, 212, 191, 0); }
}

@keyframes float-soft {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

/* Page load */
body {
    opacity: 0;
    transition: opacity 0.35s var(--ease-out);
}

body.is-ready {
    opacity: 1;
}

.animate-in {
    animation: fade-in-up 0.55s var(--ease-out) both;
}

.animate-in--delay-1 { animation-delay: 0.06s; }
.animate-in--delay-2 { animation-delay: 0.12s; }
.animate-in--delay-3 { animation-delay: 0.18s; }
.animate-in--delay-4 { animation-delay: 0.24s; }
.animate-in--delay-5 { animation-delay: 0.3s; }
.animate-in--delay-6 { animation-delay: 0.36s; }

/* Scroll reveal (JS adds .is-visible) */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.55s var(--ease-out), transform 0.55s var(--ease-out);
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Tab panel crossfade */
.tab-panel {
    animation: fade-in 0.35s var(--ease-out);
}

.tab-panel.is-exiting {
    animation: fade-in 0.2s var(--ease-out) reverse;
}

/* Stagger children when parent gets .is-visible */
.stagger-children > * {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out);
}

.stagger-children.is-visible > *:nth-child(1) { transition-delay: 0.04s; }
.stagger-children.is-visible > *:nth-child(2) { transition-delay: 0.08s; }
.stagger-children.is-visible > *:nth-child(3) { transition-delay: 0.12s; }
.stagger-children.is-visible > *:nth-child(4) { transition-delay: 0.16s; }
.stagger-children.is-visible > *:nth-child(5) { transition-delay: 0.2s; }
.stagger-children.is-visible > *:nth-child(6) { transition-delay: 0.24s; }
.stagger-children.is-visible > *:nth-child(n+7) { transition-delay: 0.28s; }

.stagger-children.is-visible > * {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    body {
        opacity: 1;
        transition: none;
    }

    .animate-in,
    .tab-panel,
    .reveal,
    .stagger-children > * {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}
