.swiper-gallery-ctrls_custom {
    position: relative;
    margin: 32px 0;
}

.swiper-gallery-ctrls_custom .ctrls-line {
    background-color: rgba(41, 41, 37, 0.1);
    height: 1px;
    display: none;
}

.swiper-gallery-ctrls_custom .swiper-scrollbar-drag {
    background-color: rgba(41, 41, 37, 0.3411764706);
}


.swiper-gallery-ctrls_custom .swiper-slide.active-slide {
    background-color: rgb(41, 41, 37);
    color: rgb(249, 242, 235);
}
.swiper-gallery-ctrls_custom .swiper-slide {
    width: fit-content;
    font-size: 16px;
    font-family: "Riel", sans-serif;
    font-weight: 500;
    font-style: normal;
    line-height: normal;
    text-decoration: none;
    position: relative;
    color: rgb(41, 41, 37);
    padding-bottom: 20px;
    cursor: pointer;
    padding: 16px;
    transition: all 0.3s ease-in-out;
    border-radius: 4px;
    border: 1px solid rgba(41, 41, 37, 0.2);
}
.swiper-backface-hidden .swiper-slide {
    transform: translateZ(0);
    backface-visibility: hidden;
}

.gallery-title {
    font-family: Riel, sans-serif;
    font-weight: 700;
    font-style: normal;
    line-height: 100%;
    text-decoration: none;
    font-size: max(40px, 5vw);
    text-align: center;
    margin: 60px 0;
    color: #255599;
}

.section_location_map_bottom__wrapper .swiper-btns-wrap {display: none}

@media screen and (min-width: 768px) {
    .gallery-title {
        font-size: 6.3vw;
    }

    .swiper-gallery-ctrls_custom {
        flex: 1;
        /*margin-bottom: 64px;*/
    }

    .swiper-gallery-ctrls_custom .swiper-slide::before {
        content: "";
        position: absolute;
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 0%;
        background-color: #e4ded7;
        height: 2px;
        transition: width 0.25s ease-in-out;
    }

    .swiper-gallery-ctrls_custom .swiper-slide:hover::before {
        width: 100%;
    }

}


@media screen and (max-width: 768px) {
    .section_location_map_bottom_custom {
        margin-top: 10vw;
    }
}


/* Popup для location-map-bottom (аналогично construction, но с другим классом) */
.locationmap-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0.2s, opacity 0.2s;
}

.locationmap-popup--open {
    visibility: visible;
    opacity: 1;
}

.locationmap-popup__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.locationmap-popup__container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.locationmap-popup__slider {
    max-width: 90vw;
    max-height: 90vh;
    z-index: 1;
}

.locationmap-popup__image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.3);
}

.locationmap-popup__close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    font-weight: bold;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 2;
    transition: transform 0.2s;
}
.locationmap-popup__close:hover {
    transform: scale(1.1);
}

.locationmap-popup__prev,
.locationmap-popup__next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.5);
    color: white;
    font-size: 40px;
    border: none;
    width: 60px;
    height: 80px;
    cursor: pointer;
    z-index: 2;
    transition: background 0.2s;
}
.locationmap-popup__prev { left: 20px; }
.locationmap-popup__next { right: 20px; }
.locationmap-popup__prev:hover,
.locationmap-popup__next:hover {
    background: rgba(0,0,0,0.8);
}



/* Новый контейнер для табов и стрелок */
.tabs-and-arrows {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    /*margin: 32px 0;*/
}

/* Адаптив для мобильных: стрелки переносим под табы */
@media screen and (max-width: 767px) {
    .tabs-and-arrows {
        flex-wrap: wrap;
        gap: 12px;
    }
    .custom-tab-arrows {
        margin-left: auto;
    }
}

/* Стили для кастомных стрелок */
.custom-tab-arrows {
    display: flex;
    flex-shrink: 0;
}

.swiper-gallery .swiper-wrapper .swiper-slide {
    max-height: 277px;
    max-width: 277px;
}

.custom-tab-prev,
.custom-tab-next {
    background: transparent;
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
    border-radius: 4px;
    border: 1px solid #E4DED7;
}

.custom-tab-prev {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}
.custom-tab-next {
    border-left: 0;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* Поворачиваем левую стрелку */
.custom-tab-prev svg {
    transform: rotate(180deg);
}

.custom-tab-prev.disabled,
.custom-tab-next.disabled {
    pointer-events: none;
    cursor: default;
}

.custom-tab-prev.disabled svg,
.custom-tab-next.disabled svg{
    opacity: 0.3;
}