/* PageSpeed: CLS, LCP order, cookie banner, below-fold paint */

:root {
    --phone-select-gap: 56px;
}

.hero-product-wrap,
.section__inner-container:has(.product-image-1),
.section__column-container:has(.section__image.large) {
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-product-wrap img,
.product-image-1,
#start .section__image.large,
.sections__container.start .section__image.large {
    aspect-ratio: 520 / 480;
    width: auto;
    height: auto;
    max-width: min(100%, 520px);
}

#stats,
.stats-bar {
    min-height: 76px;
}

.section__form-input.phone {
    padding-left: var(--phone-select-gap) !important;
}

#cookie-popup {
    position: fixed;
    left: 0;
    bottom: 0;
    z-index: 9999;
    width: 100%;
    max-width: 100%;
    padding: 12px 14px;
    border-radius: 8px 8px 0 0;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.15);
    background: #fef5e2;
    color: #28261b;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    transform: translateY(110%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

#cookie-popup.cookie-popup--show {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

#cookie-popup p {
    margin-block: auto;
    font-size: 14px;
}

#cookie-popup .actions {
    display: flex;
    gap: 16px;
    align-items: center;
    margin-left: auto;
    flex-wrap: wrap;
}

.cookie-btn {
    border: 0;
    padding: 8px 12px;
    border-radius: 6px;
    background: #171e8d;
    font-size: 14px;
    color: #fef5e2;
    cursor: pointer;
    min-width: 120px;
}

.cookie-link {
    text-decoration: underline;
    color: #28261b;
    font-size: 14px;
}

.sections-wrapper:not(:first-of-type),
.sections__container:not(.start),
section:not(#start):not(.promo):not(.product),
.site-footer,
.footer-new,
footer {
    content-visibility: auto;
    contain-intrinsic-size: auto 640px;
}

@media (max-width: 767px) {
    .hero,
    .sections-wrapper.gradient-start,
    .sections__container.start {
        min-height: auto;
    }

    #stats,
    .stats-bar {
        min-height: 228px;
    }

    .product-image-1,
    .section__inner-container:has(.product-image-1) .product-image-1 {
        order: -1;
    }

    .section__column-container:has(.section__image.large) .section__image.large {
        order: -1;
    }

    .header,
    .topbar {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .section__swiper {
        min-height: 280px;
    }
}

@media (prefers-reduced-motion: reduce) {
    #cookie-popup {
        transition: none;
    }
}
