/*Contacts*/
.section.branches {
    padding: 60px 20px;
    padding-bottom: 0px !important;
}

.branches__content {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.branches__item {
    border-radius: 16px;
    padding: 30px 20px;
    width: 100%;
    max-width: 280px;
    box-sizing: border-box;
    display: block;
    flex-direction: column;
    justify-content: flex-start !important;
}

.branches__item.center {
    align-items: center;
    justify-content: center;
    text-align: center;
}

.branches__box {
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: space-between;
}

.branches__item.yellow {
    background-color: #ffed00;
}

.branches__item.light-grey {
    background-color: #e5dbdc;
}

.branches__item.purple-bg {
    background-color: #c3008f;
}

.branches__title {
    font-weight: 800;
    font-size: 20px;
    line-height: 1.4;
    letter-spacing: 2px !important;
    text-transform: uppercase;
    margin: 0 0 15px 0;
    text-align: left;
}

.branches__title.purple {
    color: #c3008f;
}

.branches__title.white {
    color: #ffffff;
}

.branches__item p {
    font-size: 16px;
    line-height: 1.5;
    color: #000;
    margin: 0;
    text-align: left;
}

.branches__contact {
    font-weight: bold;
    font-size: 16px;
    color: #BD1590 !important;
    margin-top: 10px;
}
/*Contacts2*/
/* CONTACTS */
.contacts {
    background-color: #fff;
    padding-bottom: 2rem;
}

.contacts .container-content {
    margin: 0 1rem 3rem;
}

.contacts .section__title {
    margin: 2rem auto 2.5rem;
}

/* Стили для нового общего блока */
.contacts__block-single {
    background-color: #ffed00; /* Цвет фона */
    padding: 3rem 1.5rem;
    border-radius: 2rem; /* Скругление углов */
    color: #756660;
    text-align: center;
    font-size: 1.4rem;
    display: flex;
    flex-direction: column; /* По умолчанию - колонки на мобильных */
    gap: 2.4rem;
}

.contacts__block-title {
    font-family: 'VerdanaBold', 'system-ui';
    font-weight: bold;
    text-transform: none;
    color: #bd1590; /* Цвет заголовка */
    margin: 0;
}

.contacts__block-text {
    font-size: 1.4rem;
    line-height: 2.2rem !important;
    color: #000;
}

.contacts__block-text a {
    color: #000;
    font-size: 1.4rem !important;
    text-decoration: none;
    font-family: 'VerdanaBold', 'system-ui';
    font-weight: bold;
}
.contacts__block-text a:hover {
    text-decoration: underline;
}

.contacts__map {
    width: 100%;
    height: 43rem;
}

@media screen and (max-width: 720px) {

    .branches__content {
        align-items: center !important;
    }
}

/* Медиа-запрос для широких экранов */
@media screen and (min-width: 720px) {

    .contacts .container-content {
        margin: 0 0 4rem;
    }

    .contacts .section__title {
        margin: 5rem auto 4rem;
    }

    .contacts__content {
        /* Убираем flex-direction: row отсюда, так как теперь есть contacts__block-single */
    }

    .contacts__block-single {
        padding: 3rem;
        flex-direction: row; /* Выстраиваем группы в ряд */
        flex-wrap: wrap; /* Разрешаем перенос на новую строку */
        justify-content: space-around; /* Равномерно распределяем группы */
        align-items: flex-start; /* Выравниваем по верху */
        gap: 2rem; /* Отступ между группами */
    }

    .contacts__group {
        width: calc(50% - 1rem); /* Делаем, чтобы на каждой строке было по две группы */
        text-align: left;
    }

    .contacts__block-title {
        min-height: 4rem; /* Обеспечиваем одинаковую высоту заголовков */
        line-height: 2.1rem;
    }

    .contacts__block-text a {
        font-size: 1.6rem;
    }

    .contacts__map {
        height: 56rem;
    }
}

@media screen and (min-width: 1220px) {
    .contacts .container-content {
        max-width: 120rem; /* Максимальная ширина, как у других блоков */
        margin: 0 auto 6rem;
    }

    .contacts .section__title {
        margin: 6rem auto 5rem;
    }

    .contacts__block-single {
        display: flex;
        flex-direction: row;
        justify-content: space-around;
        gap: 2rem;
        padding: 3rem 3rem;
    }

    .contacts__group {
        width: calc(25% - 1.5rem); /* Четыре группы в ряд */
        text-align: left;
    }

    .contacts__map {
        height: 76rem;
    }
}
