/* =============================================
   PRIVY — Animation System
   All keyframes & animation utilities
   ============================================= */

/* Scroll Reveal */
.reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity .55s var(--ease), transform .55s var(--ease);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Button Breathe */
.btn-pulse {
    animation: breathe 4.5s ease-in-out infinite;
}

.btn-gold.btn-pulse {
    animation: breatheGold 4.5s ease-in-out infinite;
}

@keyframes breathe {

    0%,
    100% {
        box-shadow: 0 2px 12px rgba(168, 85, 247, .18);
    }

    50% {
        box-shadow: 0 4px 18px rgba(168, 85, 247, .3);
    }
}

@keyframes breatheGold {

    0%,
    100% {
        box-shadow: 0 2px 12px rgba(251, 191, 36, .18);
    }

    50% {
        box-shadow: 0 4px 18px rgba(251, 191, 36, .32);
    }
}

/* Floating Card */
@keyframes floatCard {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-6px);
    }
}

.model-card.floating {
    animation: floatCard 6s ease-in-out infinite;
}

/* Subtle Float for Featured Pricing Card */
@keyframes floatSubtle {

    0%,
    100% {
        transform: translateY(0) scale(1.02);
    }

    50% {
        transform: translateY(6px) scale(1.02);
    }
}

.floating-subtle {
    animation: floatSubtle 5.5s ease-in-out infinite;
}

/* Pricing section entrance stagger */
@keyframes pricingEntrance {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.97);
        filter: blur(4px);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.reveal.active .p-card {
    animation: pricingEntrance 0.6s var(--ease-out) both;
}

.reveal.active .p-card:nth-child(1) {
    animation-delay: 0.05s;
}

.reveal.active .p-card:nth-child(2) {
    animation-delay: 0.15s;
}

.reveal.active .p-card:nth-child(3) {
    animation-delay: 0.25s;
}

/* Override entrance animation for featured to preserve floating */
.reveal.active .p-card.floating-subtle {
    animation: pricingEntrance 0.6s var(--ease-out) both, floatSubtle 5.5s ease-in-out 0.8s infinite;
}

/* Particle Drift */
@keyframes particleDrift {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
        opacity: 0;
    }

    20% {
        opacity: .28;
    }

    50% {
        transform: translate(-10px, -18px) scale(1.3);
        opacity: .22;
    }

    80% {
        opacity: .28;
    }
}

/* Bottom Bar Slide */
@keyframes barSlide {
    from {
        background-position: 0% 50%;
    }

    to {
        background-position: 200% 50%;
    }
}

/* Flow Arrow Drift */
@keyframes arrowDrift {

    0%,
    100% {
        transform: translateY(0);
        opacity: .4;
    }

    50% {
        transform: translateY(4px);
        opacity: .8;
    }
}

/* Quiz Card Reveal */
@keyframes cardReveal {
    from {
        opacity: 0;
        transform: translateY(14px) scale(.98);
        filter: blur(3px);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Results Icon Bounce */
@keyframes iconBounce {
    0% {
        transform: scale(0) rotate(-10deg);
    }

    60% {
        transform: scale(1.1) rotate(3deg);
    }

    100% {
        transform: scale(1) rotate(0);
    }
}

/* Confetti Fall */
@keyframes confettiFall {
    0% {
        transform: translate3d(0, 0, 0) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translate3d(var(--c-x-end), 105vh, 0) rotate(var(--c-rot-end));
        opacity: 0;
    }
}

/* Micro Confetti Pop */
@keyframes microPop {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }

    100% {
        transform: translate(var(--mc-tx), var(--mc-ty)) scale(0);
        opacity: 0;
    }
}

/* Shimmer Sweep */
@keyframes shimmerPass {
    100% {
        transform: translateX(100%);
    }
}

/* Pricing Unlock Sweep */
@keyframes unlockSweep {
    0% {
        left: -60%;
    }

    100% {
        left: 120%;
    }
}

/* Pulse Tap */
@keyframes pulseTap {
    0% {
        transform: scale(1);
    }

    40% {
        transform: scale(0.95);
    }

    100% {
        transform: scale(1);
    }
}

.pulse-tap {
    animation: pulseTap 0.3s var(--ease-out);
}