.gallery_page,
.gallery_tours {
    width: 100%;
    padding: 8.125rem 9.375rem;
    margin-bottom: 0;
    background: #fff;
}

.gallery_page .heading,
.gallery_tours .heading {
    padding-left: 8.625rem;
    margin-bottom: 5rem;
    color: #000;
}

.gallery_page .heading::before,
.gallery_tours .heading::before {
    border-color: #000;
}

.gallery_page .slider {
    display: grid;
    grid-template-columns: 4rem minmax(0, 1fr) 4rem;
    grid-template-areas:
        "prev slider next"
        ". counter .";
    align-items: center;
    column-gap: 2.5rem;
    padding: 0 8.625rem;
}

.gallery_page .wrapper {
    grid-area: slider;
    overflow: hidden;
    width: 100%;
}

.gallery_page .track {
    display: flex;
    width: 100%;
}

.gallery_page .image {
    min-width: 100%;
    padding-top: 56.25%;
    position: relative;
    overflow: hidden;
}

.gallery_page .image img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery_page .button {
    width: 4rem;
    height: 4rem;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery_page .button:disabled {
    opacity: 0.35;
    cursor: default;
}

.gallery_page .button_prev {
    grid-area: prev;
}

.gallery_page .button_next {
    grid-area: next;
}

.gallery_page .button span {
    width: 3.125rem;
    height: 0.75rem;
    display: block;
    position: relative;
}

.gallery_page .button span::before,
.gallery_page .button span::after {
    content: "";
    position: absolute;
    background: #383838;
}

.gallery_page .button span::before {
    width: 100%;
    height: 1px;
    top: 50%;
    left: 0;
}

.gallery_page .button span::after {
    width: 0.65rem;
    height: 0.65rem;
    border-top: 1px solid #383838;
    border-right: 1px solid #383838;
    background: transparent;
    top: 50%;
    right: 0;
    transform: translateY(-50%) rotate(45deg);
}

.gallery_page .button_prev span {
    transform: rotate(180deg);
}

.gallery_page .counter {
    grid-area: counter;
    justify-self: center;
    display: flex;
    gap: 0.45rem;
    margin-top: 2.5rem;
    font: 400 1rem "Open Sans";
    color: #000;
}

.gallery_tours {
    padding-top: 0;
}

.gallery_tours .tour_frames {
    padding: 0 8.625rem;
}

.gallery_tours .tour_frames > *:not(:last-child) {
    margin-bottom: 2rem;
}

@media screen and (max-width: 1200px) {
    .gallery_page,
    .gallery_tours {
        padding-left: 6rem;
        padding-right: 6rem;
    }

    .gallery_page .heading,
    .gallery_tours .heading,
    .gallery_page .slider,
    .gallery_tours .tour_frames {
        padding-left: 0;
        padding-right: 0;
    }
}

@media screen and (max-width: 900px) {
    .gallery_page,
    .gallery_tours {
        padding: 5.7rem 6.7rem;
    }

    .gallery_tours {
        padding-top: 0;
    }

    .gallery_page .heading,
    .gallery_tours .heading {
        padding-left: 0;
        margin-bottom: 4.3rem;
    }

    .gallery_page .slider {
        grid-template-columns: 3rem 1fr 3rem;
        column-gap: 1rem;
    }

    .gallery_page .button {
        width: 3rem;
        height: 3rem;
    }
}

@media screen and (max-width: 600px) {
    .gallery_page,
    .gallery_tours {
        padding-left: 1.7rem;
        padding-right: 1.7rem;
    }

    .gallery_page .slider {
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            "slider slider"
            "prev next"
            "counter counter";
        row-gap: 1.5rem;
    }

    .gallery_page .button_prev {
        justify-self: start;
    }

    .gallery_page .button_next {
        justify-self: end;
    }

    .gallery_tours .tour_frames script + div,
    .gallery_tours iframe {
        min-height: 420px;
    }
}

.contacts {
    padding-bottom: 1rem !important;
}

@media screen and (max-width: 900px) {
    .contacts {
        padding-bottom: 0.5rem !important;
    }
}
