/* Gallery block */
.gallery-block {
    display: flex;
    flex-direction: column;
    gap: 30px;
    align-items: center;
}

.gallery-block__wrapper {
    position: relative;
    width: 100%;
}

.gallery-block__swiper {
    width: 100%;
    overflow: visible;
}

.gallery-block__track {
    align-items: center;
    will-change: transform;
}

.gallery-block__slide {
    width: 490px;
    height: 490px;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
}

.gallery-block__media,
.gallery-block__image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

/* Video styles */
.gallery-block__media--video {
    cursor: pointer;
}

.gallery-block__video-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-block__video-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gallery-block__play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.gallery-block__play-btn:hover {
    transform: translate(-50%, -50%) scale(1.1);
    opacity: 0.9;
}

.gallery-block__video-file {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px;
}

/* Near slides */
/* Smooth size via transform to avoid layout reflow */

/* Keep only essentials; coverflow will handle smoothness */
.gallery-block .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* white overlay for non-active slides */
.gallery-block .swiper-slide::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    opacity: .5;
    pointer-events: none;
    transition: opacity .4s ease;
    border-radius: 16px;
    z-index: 1;
}

.gallery-block .swiper-slide-active::before {
    opacity: 0;
}

/* keep slide transitions for coverflow */
.gallery-block .swiper-slide {
    transition: .4s ease;
}

/* optional: adjust if need spacing with coverflow stretch */

/* Controls container - you will style buttons yourself */
.gallery-block__controls {
    margin-top: 16px;
    display: flex;
    gap: 12px;
    justify-content: center;
}

.gallery-block__btn {
    cursor: pointer;
    transition: .3s ease-in;
    border: 1.50px solid var(--bg-alt-stroke);
    border-radius: 10px;
    /* padding: 20px; */
    width: 54px;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary-second);
}

.gallery-block__btn svg path {
    transition: .3s ease-in;
    stroke: var(--text-primary-head);
}

.gallery-block__btn:hover {
    background: var(--bg-alt-stroke);
    transition: .3s ease-in;
}

.gallery-block__btn:hover svg path {
    transition: .3s ease-in;
    stroke: var(--bg-primary-main);
}

@media (max-width: 1024px) {
    .gallery-block .swiper-slide-active {
        width: 420px;
        height: 420px;
    }

    .gallery-block .swiper-slide-prev,
    .gallery-block .swiper-slide-next {
        width: 360px;
        height: 360px;
    }
}

@media (max-width: 768px) {
    .gallery-block .swiper-slide-active {
        width: 360px;
        height: 360px;
    }

    .gallery-block .swiper-slide-prev,
    .gallery-block .swiper-slide-next {
        width: 300px;
        height: 300px;
    }

    .gallery-block__slide {
        width: 260px;
        height: 260px;
    }
}

#svg-milota {
    position: absolute;
    right: 80%;
    top: -25px;
}

@media (max-width: 1100px) {
    #svg-milota {
        display: none;
    }
}