/* Only the photograph moves; its Elementor placement stays intact. */
.jj-hero-motion-ready .jj-hero-portrait img {
    transform-origin: 50% 100%;
    opacity: 0;
}

.jj-hero-motion-ready .jj-hero-portrait.jj-hero-entering img {
    animation: jj-hero-pop-up 1.32s 0.16s both;
    will-change: transform, opacity;
}

.jj-hero-motion-ready .jj-hero-portrait.jj-hero-entered img {
    opacity: 1;
}

@keyframes jj-hero-pop-up {
    0% {
        opacity: 0;
        transform: translateY(110%) scale(1.1, .84) rotate(-2deg);
        animation-timing-function: cubic-bezier(.16, .7, .25, 1);
    }
    12% {
        opacity: 1;
    }
    46% {
        opacity: 1;
        transform: translateY(-5%) scale(.96, 1.07) rotate(1.2deg);
        animation-timing-function: cubic-bezier(.45, 0, .7, 1);
    }
    64% {
        transform: translateY(2%) scale(1.045, .955) rotate(-.65deg);
        animation-timing-function: cubic-bezier(.2, .65, .3, 1);
    }
    79% {
        transform: translateY(-1.7%) scale(.985, 1.025) rotate(.35deg);
        animation-timing-function: ease-in-out;
    }
    91% {
        transform: translateY(.5%) scale(1.008, .992) rotate(-.12deg);
        animation-timing-function: ease-out;
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1) rotate(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .jj-hero-motion-ready .jj-hero-portrait img,
    .jj-hero-motion-ready .jj-hero-portrait.jj-hero-entering img {
        animation: none;
        transform: none;
        opacity: 1;
        will-change: auto;
    }
}
