/* LASER BEND — плавный скролл и производительность */

html.lenis,
html.lenis body {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

.lenis.lenis-stopped {
    overflow: hidden;
}

html {
    scroll-padding-top: calc(var(--header-h, 72px) + 16px);
}

@media (prefers-reduced-motion: no-preference) {
    html:not(.lenis) {
        scroll-behavior: smooth;
    }
}

/* Плавные переходы без лишней нагрузки на GPU */
@media (prefers-reduced-motion: no-preference) {
    .btn,
    .nav-links a,
    .bento-card,
    .feat-card,
    .why-us-item,
    .process-card,
    .service-block__body,
    .footer-premium__links a {
        transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    }
}

/* Ускорение отрисовки длинных страниц */
.page-content > section,
.services-premium .service-block,
.inner-premium .about-content,
.inner-premium .why-us-item,
.home-highlights,
.seo-section,
.cta-premium {
    content-visibility: auto;
    contain-intrinsic-size: auto 420px;
}

.hero-immersive,
.page-hero--inner,
.page-hero--clean,
#loader-portal {
    content-visibility: visible;
}

/* Скроллбар (десктоп) */
@media (min-width: 769px) {
    html {
        scrollbar-width: thin;
        scrollbar-color: rgba(255, 87, 34, 0.45) rgba(255, 255, 255, 0.06);
    }

    ::-webkit-scrollbar {
        width: 8px;
    }

    ::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.04);
    }

    ::-webkit-scrollbar-thumb {
        background: rgba(255, 87, 34, 0.4);
        border-radius: 8px;
    }

    ::-webkit-scrollbar-thumb:hover {
        background: rgba(255, 87, 34, 0.65);
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
