/* Motion layer (GSAP + Lenis). Initial hidden states apply only while html.esf-motion is set */

/* Lenis (desktop only). Theme sets body/html height 100% */
html.lenis, html.lenis body {height: auto;}
html.lenis {scroll-behavior: auto !important;}
.lenis:not(.lenis-autoToggle).lenis-stopped {overflow: clip;}
.lenis [data-lenis-prevent] {overscroll-behavior: contain;}
.lenis.lenis-smooth iframe {pointer-events: none;}

/* ScrollSmoother is gone: the page wrapper must not be one huge GPU layer or animate its transform */
#smooth-content {will-change: auto !important; transform: none !important; transition: none !important;}

/* Theme gives headings, .op and big images "transition: all 1s": it fights every GSAP frame. Keep only colour transitions */
.op, .esf-fx, .esf-fx > img {transition-property: color, background-color, border-color, box-shadow !important;}

/* Heroes: the old JS zoomed from a static CSS scale and kept the inner hero text at opacity 0 without JS */
.main-hero .hero-media, .hero-inner .hero-media {transform: none; overflow: hidden;}
.hero-inner .hero-info {opacity: 1;}
@media (prefers-reduced-motion: no-preference) {
	.esf-motion .main-hero .hero-media > *, .esf-motion .hero-inner .hero-media > * {animation: esf-hero-zoom 2.6s cubic-bezier(.16, 1, .3, 1) both;}
	.esf-motion .main-hero .hero-info h1, .esf-motion .main-hero .hero-info .h1-title, .esf-motion .main-hero .hero-info .anons,
	.esf-motion .hero-inner .hero-info h1, .esf-motion .hero-inner .hero-info .anons, .esf-motion .hero-inner .hero-logo {opacity: 0;}
}
@keyframes esf-hero-zoom {from {transform: scale(1.18);} to {transform: scale(1);}}

/* SplitText masks: room for descenders and the diaeresis in "Ї" */
.esf-line-mask {padding: .14em 0 .08em; margin: -.14em 0 -.08em;}

/* Scroll progress */
.esf-progress {position: fixed; left: 0; right: 0; top: 0; height: 2px; z-index: 300; background: var(--Brown-Akcent, #251A13); opacity: .55; transform: scaleX(0); transform-origin: 0 50%; pointer-events: none;}
.menu-open .esf-progress {opacity: 0;}

/* Image curtain reveal and inner parallax */
.esf-reveal {will-change: clip-path;}
.esf-plx {overflow: hidden;}
.esf-plx > img, .esf-plx > video {will-change: transform;}

/* Horizontal entrances must not widen the page */
main.content, .footer {overflow-x: clip;}

@media (prefers-reduced-motion: reduce) {
	.esf-progress {display: none;}
}
