/* =========================================================
   Article Gallery
========================================================= */

.sr-article-gallery {
    width: 100%;
    max-width: 100%;
    margin: 35px auto;
    position: relative;
    box-sizing: border-box;
}


/* =========================================================
   Main stage
========================================================= */

.sr-ag-stage {
    position: relative;
    overflow: hidden;

    background: #0b0b0b;

    border-radius: 18px;

    box-shadow:
        0 10px 35px
        rgba(0, 0, 0, 0.12);
}


.sr-ag-main {
    width: 100%;
    aspect-ratio: 16 / 10;
}


.sr-ag-main .swiper-wrapper {
    height: 100%;
}


.sr-ag-main .swiper-slide {
    height: 100%;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #090909;
}


.sr-ag-open {
    display: block;

    width: 100%;
    height: 100%;

    margin: 0;
    padding: 0;

    border: 0;
    outline: 0;

    background: transparent;

    cursor: zoom-in;
}


.sr-ag-main-image {
    width: 100% !important;
    height: 100% !important;

    display: block;

    object-fit: contain;

    margin: 0 !important;
}


/* =========================================================
   Navigation
========================================================= */

.sr-ag-nav {
    position: absolute;

    top: 50%;

    z-index: 20;

    width: 46px;
    height: 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border:
        1px solid
        rgba(255, 255, 255, .25);

    border-radius: 50%;

    background:
        rgba(0, 0, 0, .52);

    backdrop-filter:
        blur(8px);

    color: #fff;

    font-size: 24px;
    font-family: Arial, sans-serif;
    line-height: 1;

    cursor: pointer;

    transform:
        translateY(-50%);

    transition:
        background .2s ease,
        transform .2s ease;
}


.sr-ag-nav:hover {
    background:
        rgba(0, 0, 0, .8);

    transform:
        translateY(-50%)
        scale(1.06);
}


.sr-ag-prev {
    left: 16px;
}


.sr-ag-next {
    right: 16px;
}


/* =========================================================
   Counter
========================================================= */

.sr-ag-counter {
    position: absolute;

    right: 15px;
    bottom: 15px;

    z-index: 20;

    display: flex;
    align-items: center;
    gap: 5px;

    min-width: 64px;

    padding: 7px 12px;

    border-radius: 30px;

    background:
        rgba(0, 0, 0, .62);

    backdrop-filter:
        blur(8px);

    color: #fff;

    font-size: 13px;
    font-weight: 600;

    justify-content: center;

    pointer-events: none;
}


/* =========================================================
   Thumbnails
========================================================= */

.sr-ag-thumbs {
    width: 100%;

    margin-top: 10px;

    padding: 2px;
}


.sr-ag-thumbs .swiper-slide {
    height: 78px;

    overflow: hidden;

    border-radius: 9px;

    cursor: pointer;

    opacity: .5;

    border:
        2px solid
        transparent;

    transition:
        opacity .2s ease,
        border-color .2s ease,
        transform .2s ease;
}


.sr-ag-thumbs
.swiper-slide:hover {
    opacity: .85;
}


.sr-ag-thumbs
.swiper-slide-thumb-active {
    opacity: 1;

    border-color: #222;

    transform:
        translateY(-1px);
}


.sr-ag-thumb-image {
    width: 100% !important;
    height: 100% !important;

    display: block;

    object-fit: cover;

    margin: 0 !important;
}


/* =========================================================
   Lightbox
========================================================= */

html.sr-ag-lightbox-open,
html.sr-ag-lightbox-open body {
    overflow: hidden !important;
}


.sr-ag-lightbox {
    width: 100vw;
    height: 100dvh;

    max-width: none;
    max-height: none;

    margin: 0;
    padding: 0;

    border: 0;

    background:
        rgba(5, 5, 5, .98);

    color: #fff;

    overflow: hidden;

    z-index: 999999;
}


.sr-ag-lightbox::backdrop {
    background:
        rgba(0, 0, 0, .97);
}


.sr-ag-lightbox-swiper {
    width: 100%;
    height: 100%;
}


.sr-ag-lightbox-swiper
.swiper-slide {

    display: flex;

    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100%;
}


.sr-ag-lightbox
.swiper-zoom-container {
    width: 100%;
    height: 100%;

    display: flex;

    align-items: center;
    justify-content: center;
}


.sr-ag-lightbox-image {
    width: auto !important;
    height: auto !important;

    max-width:
        calc(100vw - 110px);

    max-height:
        calc(100dvh - 80px);

    object-fit: contain;

    margin: 0 !important;
}


/* =========================================================
   Lightbox Close
========================================================= */

.sr-ag-lightbox-close {
    position: fixed;

    top: 18px;
    right: 20px;

    z-index: 100;

    width: 45px;
    height: 45px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 0;

    border-radius: 50%;

    background:
        rgba(255, 255, 255, .13);

    color: #fff;

    font-size: 30px;
    line-height: 1;

    cursor: pointer;

    transition:
        background .2s ease;
}


.sr-ag-lightbox-close:hover {
    background:
        rgba(255, 255, 255, .25);
}


/* =========================================================
   Lightbox navigation
========================================================= */

.sr-ag-lightbox-nav {
    position: fixed;

    top: 50%;

    z-index: 80;

    width: 52px;
    height: 52px;

    padding: 0;

    display: flex;

    align-items: center;
    justify-content: center;

    border:
        1px solid
        rgba(255, 255, 255, .18);

    border-radius: 50%;

    background:
        rgba(255, 255, 255, .10);

    color: #fff;

    font-size: 38px;

    cursor: pointer;

    transform:
        translateY(-50%);
}


.sr-ag-lightbox-prev {
    left: 20px;
}


.sr-ag-lightbox-next {
    right: 20px;
}


/* =========================================================
   Lightbox Counter
========================================================= */

.sr-ag-lightbox-counter {
    position: fixed;

    top: 23px;
    left: 50%;

    z-index: 90;

    transform:
        translateX(-50%);

    display: flex;

    align-items: center;

    gap: 6px;

    padding:
        7px 15px;

    border-radius: 25px;

    background:
        rgba(255, 255, 255, .10);

    color: #fff;

    font-size: 14px;

    font-weight: 600;

    backdrop-filter:
        blur(10px);
}


/* =========================================================
   Tablet
========================================================= */

@media
(max-width: 767px) {

    .sr-article-gallery {
        margin:
            25px auto;
    }


    .sr-ag-stage {
        border-radius: 13px;
    }


    .sr-ag-main {
        aspect-ratio:
            4 / 3;
    }


    .sr-ag-nav {
        width: 39px;
        height: 39px;

        font-size: 29px;
    }


    .sr-ag-prev {
        left: 8px;
    }


    .sr-ag-next {
        right: 8px;
    }


    .sr-ag-thumbs
    .swiper-slide {
        height: 65px;
    }


    .sr-ag-lightbox-image {
        max-width:
            calc(100vw - 20px);

        max-height:
            calc(100dvh - 100px);
    }


    .sr-ag-lightbox-nav {
        width: 42px;
        height: 42px;

        font-size: 30px;

        background:
            rgba(0, 0, 0, .45);
    }


    .sr-ag-lightbox-prev {
        left: 8px;
    }


    .sr-ag-lightbox-next {
        right: 8px;
    }


    .sr-ag-lightbox-close {
        top: 12px;
        right: 12px;

        width: 40px;
        height: 40px;
    }


    .sr-ag-lightbox-counter {
        top: 15px;
    }

}


/* =========================================================
   Small phones
========================================================= */

@media
(max-width: 480px) {

    .sr-ag-main {
        aspect-ratio:
            1 / 1;
    }


    .sr-ag-thumbs
    .swiper-slide {
        height: 58px;
    }


    .sr-ag-counter {
        right: 9px;
        bottom: 9px;

        padding:
            5px 9px;

        font-size:
            12px;
    }

}