@media (max-width: 1800px) {
    .about-section__main-block {
        border-radius: 50px;
    }
}

@media (max-width: 992px) {
    .about-section__main-block {
        height: auto;
        flex-direction: column;
        padding: 30px;
        border-radius: 40px;
    }

    .about-section__text-block {
        width: 100%;
        height: auto;
        padding: 0;
        margin-bottom: 20px;
    }

    .about-section__text-block .about-section__description {
        flex-grow: 0;
        overflow-y: visible;
        margin-bottom: 20px;
    }

    .about-section__text-block .about-section__title,
    .about-section__text-block .about-section__link.button {
        align-self: center;
    }
}

@media (max-width: 991px) {
    .container {
        padding: 0 var(--container-padding-mobile);
    }

    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    .section__title {
        font-size: 36px;
    }

    .header {
        height: var(--header-height-mobile);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        background-color: var(--color-blue-dark);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    }

    .header .container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0 var(--container-padding-mobile);
    }

    .header__top-bar {
        border-bottom: none;
        padding: 0;
        flex-grow: 1;
        justify-content: flex-start;
        gap: 15px;
        height: 100%;
    }

    .header__logo img {
        height: calc(var(--header-height-mobile) - 20px);
    }

    .header__contacts {
        display: none;
    }

    .header__main-nav {
        display: none;
    }

    .header__burger {
        display: flex;
    }

    .header.header--scrolled {
        height: var(--header-height-mobile);
        background-color: var(--color-blue-dark);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    }

    .header.header--scrolled .container {
        flex-direction: row;
        justify-content: space-between;
        padding: 0 var(--container-padding-mobile);
    }

    .header.header--scrolled .header__top-bar {
        opacity: 1;
        pointer-events: auto;
        height: 100%;
        padding: 0;
        margin: 0;
        border-bottom: none;
        overflow: visible;
        transform: none;
        flex-grow: 1;
        justify-content: flex-start;
        gap: 15px;
    }

    .header.header--scrolled .header__logo img {
        height: calc(var(--header-height-mobile) - 20px);
    }

    .header.header--scrolled .header__main-nav {
        display: none;
    }

    .header.header--scrolled .header__burger {
        display: flex;
    }

    .contacts-section {
        padding: 50px 0;
    }

    .contacts__title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }

    .contacts__content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contacts__info {
        margin-bottom: 30px;
    }

    .contacts__map-block {
        min-height: 300px;
    }
}

@media (max-width: 768px) {
    .about-section {
        margin-top: 15px;
    }

    .about-section__main-block {
        height: auto;
        flex-direction: column;
        padding: 20px;
        border-radius: 20px;
    }

    .about-section__text-block {
        width: 100%;
        height: auto;
        padding: 0;
        margin-bottom: 20px;
    }

    .about-section__text-block .about-section__title {
        text-align: center;
        font-size: 2rem;
        margin-bottom: 15px;
    }

    .about-section__text-block .about-section__description {
        flex-grow: 0;
        overflow-y: visible;
        font-size: 1rem;
        margin-bottom: 15px;
    }

    .about-section__text-block .about-section__link.button,
    .about-section__text-block .about-section__link.link-more {
        align-self: center;
    }

    .advantages-section {
        padding: 50px 0;
    }

    .advantages__title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }

    .advantages__list {
        grid-template-columns: 1fr;
    }

    .advantage-item {
        padding: 15px;
    }

    .advantage-item__icon {
        width: 40px;
        height: 40px;
        margin-bottom: 10px;
    }

    .advantage-item__icon svg {
        width: 24px;
        height: 24px;
    }

    .advantage-item__title {
        font-size: 1.2em;
    }

    .advantage-item__text {
        font-size: 0.9em;
    }

    .gallery-preview-section {
        padding: 50px 0;
    }

    .gallery-preview__title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }

    .gallery-preview__grid {
        grid-template-columns: 1fr;
    }

    .gallery-preview__image {
        height: 250px;
    }

    .gallery-preview__button-wrapper {
        margin-top: 30px;
    }

    .testimonials-section {
        padding: 50px 0;
    }

    .testimonials__title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }

    .testimonial-item {
        padding: 30px 20px;
        min-height: auto;
    }

    .testimonial-item__text {
        font-size: 1em;
    }

    .testimonial-item__author {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .testimonial-item__author-info {
        align-items: center;
    }

    .testimonials-slider__navigation {
        bottom: 5px;
        padding: 0 10px;
    }

    .testimonials-slider__prev,
    .testimonials-slider__next {
        width: 30px;
        height: 30px;
        font-size: 1.2em;
    }

    .testimonials-slider__dots {
        gap: 5px;
    }

    .footer {
        padding: 40px 0 15px 0;
    }

    .footer__content {
        grid-template-columns: 1fr;
        gap: 30px;
        margin-bottom: 30px;
        text-align: center;
    }

    .footer__brand .footer__logo {
        margin: 0 auto 15px auto;
    }

    .footer__socials {
        justify-content: center;
    }

    .footer__nav-title,
    .footer__contacts-title {
        text-align: center;
        margin-bottom: 15px;
    }

    .footer__item {
        margin-bottom: 8px;
    }

    .footer__link {
        font-size: 1em;
    }

    .footer__contacts address,
    .footer__contacts p {
        margin-bottom: 8px;
    }

    .footer__bottom {
        flex-direction: column;
        gap: 15px;
    }

    .footer__legal-links {
        justify-content: center;
        gap: 15px;
    }

    .footer__copyright {
        margin-top: 0;
    }

    .bento-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .bento-grid__item {
        padding: 20px;
        border-radius: 20px;
    }

    .bento-grid__item--lg {
        grid-column: span 1;
        grid-row: span 1;
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 40px;
    }

    .bento-gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }

    .bento-gallery-grid__item,
    .bento-gallery-grid__item--lg,
    .bento-gallery-grid__item--wide {
        grid-column: span 1 !important;
        grid-row: span 1 !important;
        border-radius: 10px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    }
}

@media (max-width: 575px) {
    /* Стили для экранов <= 575px (например, маленькие телефоны в портретной ориентации) */
    /* Вы можете добавить сюда специфичные правила или перенести/адаптировать правила из брейкпоинта 768px */
}

@media (max-width: 375px) {
    /* Стили для экранов <= 375px (например, очень маленькие телефоны) */
    /* Вы можете добавить сюда наиболее специфичные правила для самых маленьких экранов */
}

@media (max-width: 480px) {

    /* Дополнительные стили для узких мобильных */
    .testimonials-section .section-title {
        font-size: 30px;
        margin-bottom: 30px;
    }

    .testimonial-item {
        padding: 15px;
        border-radius: 10px;
    }

    .testimonial-text {
        font-size: 0.95rem;
        line-height: 1.5;
    }

    .reviewer-avatar {
        width: 35px;
        height: 35px;
        margin-right: 8px;
    }

    .reviewer-info p {
        font-size: 0.85rem;
    }

    .reviewer-child-info {
        font-size: 0.75rem;
    }
}

/* --- Адаптивность --- */
@media (max-width: 768px) {
    .testimonials-section {
        padding: 50px 0;
        /* Уменьшаем отступы секции */
    }

    .testimonials-section .section-title {
        font-size: 36px;
        /* Уменьшаем размер заголовка */
        margin-bottom: 40px;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
        /* Одна колонка на мобильных */
        gap: 20px;
        /* Уменьшаем пространство между карточками */
        padding: 0 10px;
    }

    .testimonial-item {
        border-radius: 15px;
        /* Уменьшаем радиус углов */
        padding: 20px;
        /* Уменьшаем внутренние отступы */
        backdrop-filter: blur(8px);
        */
        /* Немного меньше размытие */
        -webkit-backdrop-filter: blur(8px);
    }

    .testimonial-item:hover {
        transform: none;
        /* Отключаем подъем при наведении на мобильных, если мешает */
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
        /* Меньшая тень при наведении */
    }

    .testimonial-text {
        font-size: 1rem;
        /* Уменьшаем размер текста отзыва */
        line-height: 1.6;
        margin-bottom: 15px;
    }

    .reviewer-avatar {
        width: 40px;
        /* Меньший размер аватара */
        height: 40px;
        margin-right: 10px;
    }

    .reviewer-info p {
        font-size: 0.9rem;
        /* Меньший размер текста автора */
    }

    .reviewer-child-info {
        font-size: 0.8rem;
    }

    .section-footer {
        margin-top: 30px;
    }
}

/* --- Адаптивность CTA --- */
@media (max-width: 768px) {
    .cta-section {
        padding: 50px 0;
        /* Уменьшаем отступы секции */
    }

    .cta-section .about-section__main-block {
        max-width: 95%;
        /* Уменьшаем макс. ширину на мобильных */
        padding: 30px;
        /* Уменьшаем внутренние отступы */
        border-radius: 30px;
        /* Уменьшаем радиус */
        backdrop-filter: blur(8px);
        /* Уменьшаем размытие */
        -webkit-backdrop-filter: blur(8px);
        box-shadow: 0 4px 20px rgba(var(--color-sea-blue-rgb), 0.1);
        /* Меньшая тень */
    }

    .cta-section .about-section__text-block {
        padding: 20px;
        /* Уменьшаем внутренние отступы */
        border-radius: 20px;
    }

    .cta-section .about-section__title {
        font-size: 2rem;
        /* Уменьшаем размер заголовка */
        margin-bottom: 15px;
    }

    .cta__subtitle {
        font-size: 1rem;
        /* Уменьшаем размер подзаголовка */
        line-height: 1.5;
        gap: 15px;
    }

    .cta__content {
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .cta-section .about-section__main-block {
        padding: 20px;
        border-radius: 20px;
    }

    .cta-section .about-section__text-block {
        padding: 15px;
        border-radius: 15px;
    }

    .cta-section .about-section__title {
        font-size: 1.6rem;
    }

    .cta__subtitle {
        font-size: 0.9rem;
    }

    .cta__content {
        gap: 10px;
    }
}

/* --- Адаптивность Контактов --- */
@media (max-width: 1023px) {

    /* Пример брейкпоинта для стекания колонок */
    .contacts-main-content {
        flex-direction: column;
        /* Колонки становятся строками */
        gap: 30px;
        /* Меньшее пространство между блоками */
        padding: 30px;
        /* Уменьшаем внутренние отступы */
        border-radius: 30px;
        /* Уменьшаем радиус */
        backdrop-filter: blur(12px);
        /* Сохраняем размытие */
    }

    .contacts-info-form {
        flex-basis: auto;
        /* Сбрасываем flex-basis */
        width: 100%;
        /* Занимает всю ширину */
        padding: 30px;
        /* Уменьшаем отступы */
        border-radius: 20px;
        gap: 20px;
        /* Меньшее пространство внутри левого блока */
    }

    .contacts-subtitle {
        font-size: 1.6rem;
    }

    .branches-list {
        gap: 15px;
        /* Меньшее пространство между филиалами */
    }

    .branches-list>h4 {
        font-size: 1.3rem;
        margin-bottom: 10px;
    }

    .branch-item {
        flex-basis: 200px;
        /* Меньшая базовая ширина для филиалов */
        padding: 15px;
        border-radius: 10px;
    }

    .branch-item .branch-name {
        font-size: 1.1rem;
        margin-bottom: 5px;
    }

    .branch-item p {
        font-size: 0.95rem;
        margin: 3px 0;
    }

    .branch-item p i {
        margin-right: 5px;
        font-size: 1em;
    }


    .contact-form {
        &>h4 {
            font-size: 1.3rem;
            margin-bottom: 15px;
        }

        input[type="text"],
        input[type="tel"],
        input[type="email"],
        textarea {
            padding: 12px;
            border-radius: 8px;
            font-size: 0.95rem;
        }

        .form-group {
            margin-bottom: 10px;
        }

        button[type="submit"] {
            margin-top: 15px auto 0 auto;
        }
    }


    .contacts-map {
        flex-basis: auto;
        /* Сбрасываем flex-basis */
        width: 100%;
        /* Карта занимает всю ширину */
        border-radius: 20px;
        min-height: 300px;
        /* Меньшая минимальная высота карты на мобильных */
    }
}

@media (max-width: 768px) {

    /* Дополнительные стили для маленьких экранов */
    .contacts-section {
        padding: 60px 0;
    }

    .contacts-section .section-title {
        font-size: 36px;
        margin-bottom: 40px;
    }

    .contacts-main-content {
        padding: 20px;
        border-radius: 25px;
        gap: 20px;
    }

    .contacts-info-form {
        padding: 20px;
        border-radius: 15px;
        gap: 15px;
    }

    .contacts-subtitle {
        font-size: 1.4rem;
    }

    .branches-list {
        gap: 10px;
    }

    .branches-list>h4 {
        font-size: 1.2rem;
        margin-bottom: 8px;
    }

    .branch-item {
        flex-basis: 180px;
        padding: 12px;
        border-radius: 8px;
    }

    /* Адаптивность филиалов */
    .branch-item .branch-name {
        font-size: 1rem;
    }

    .branch-item p {
        font-size: 0.9rem;
        margin: 2px 0;
    }


    .contact-form {
        &>h4 {
            font-size: 1.2rem;
            margin-bottom: 12px;
        }

        input[type="text"],
        input[type="tel"],
        input[type="email"],
        textarea {
            padding: 10px;
            font-size: 0.9rem;
        }

        .form-group {
            margin-bottom: 8px;
        }

        button[type="submit"] {
            margin-top: 10px auto 0 auto;
        }
    }

    .contacts-map {
        border-radius: 15px;
        min-height: 250px;
    }
}

.header__branch-select.is-open .header__branch-list {
    display: block;
}

.header__branch-list {
    position: absolute;
    z-index: 1000;
    background-color: white;
    border: 1px solid #ccc;
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
    max-height: 200px;
    overflow-y: auto;
}

.header__branch-list li {
    padding: 8px 12px;
    cursor: pointer;
}

.header__branch-list li:hover {
    background-color: #f0f0f0;
}