.jg-news-gallery {
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

/* Static slider with < 3 images */
.jg-news-gallery--static {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    align-items: start !important;
}

.jg-news-gallery--static[data-count="1"] {
    grid-template-columns: minmax(0, 40%) !important;
    justify-content: center !important;
}

.jg-news-gallery--static[data-count="2"] {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.jg-news-gallery--static[data-count="3"] {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.jg-news-gallery__slide,
.jg-news-gallery .gallery-item,
.jg-news-gallery .gallery-item__img {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    position: relative !important;
    overflow: hidden !important;
}

.jg-news-gallery .gallery-item__img img,
.jg-news-gallery .gallery-item__img picture {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    object-fit: cover !important;
}

.jg-news-gallery .gallery-item__icon {
    position: absolute !important;
    right: 10px !important;
    bottom: 10px !important;
    width: 34px !important;
    height: 34px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 50% !important;
    background: rgba(0, 0, 0, .55) !important;
    color: #fff !important;
    font-size: 20px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .2s ease, transform .2s ease, background .2s ease;
    z-index: 2;
}

.jg-news-gallery .gallery-item__icon::before {
    content: "+";
    display: block;
    line-height: 1;
    transform: translateY(-1px);
}

.jg-news-gallery .gallery-item:hover .gallery-item__icon {
    opacity: 1;
    transform: translateY(0);
}

.jg-news-gallery .gallery-item__icon:hover {
    background: rgba(0, 0, 0, .85) !important;
}


/* Slider Gallery with > 3 images */
.jg-news-gallery--slider .owl-stage-outer,
.jg-news-gallery--slider .owl-stage,
.jg-news-gallery--slider .owl-item {
    display: block;
}

.jg-news-gallery--slider .owl-item {
    float: none !important;
    flex: 0 0 auto;
}

.jg-news-gallery--slider .owl-item > .jg-news-gallery__slide,
.jg-news-gallery--slider .owl-item .gallery-item {
    position: relative !important;
    overflow: hidden !important;
}

.jg-news-gallery--slider .owl-stage-outer {
    height: auto !important;
    overflow: hidden !important;
    position: relative;
}

.jg-news-gallery--slider .owl-stage {
    height: auto !important;
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
}

.jg-news-gallery--slider .owl-stage::after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;
}

.jg-news-gallery--slider .owl-item .gallery-item__img {
    position: relative !important;
    overflow: hidden !important;
}

.jg-news-gallery--slider .owl-item .gallery-item__img picture,
.jg-news-gallery--slider .owl-item .gallery-item__img img {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
}

.jg-news-gallery--slider .owl-item .gallery-item__img img {
    height: auto !important;
    aspect-ratio: 16 / 9 !important;
    object-fit: cover !important;
}

/* Arrows */
.jg-news-gallery--slider .owl-nav {
    position: static;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px 0 0;
    padding: 0;
    transform: none;
    line-height: 1;
}

.jg-news-gallery--slider .owl-nav button.owl-prev,
.jg-news-gallery--slider .owl-nav button.owl-next {
    display: inline-flex;
    justify-content: center;
    background: var(--medium-gray-color);
    color: #fff;
    border: 0;
    border-radius: 3px;
    padding: 4px 7px !important;
    margin: 5px;
    width: 26px;
    height: 34px;
    font-weight: 400;
    line-height: 1;
    cursor: pointer;
    transition: background .2s ease, opacity .2s ease;
    opacity: 1;
    text-align: center;
}

.jg-news-gallery--slider .owl-nav button.owl-prev:hover,
.jg-news-gallery--slider .owl-nav button.owl-next:hover {
    background: var(--font-default-color);
}

.jg-news-gallery--slider .owl-nav button.owl-prev.disabled,
.jg-news-gallery--slider .owl-nav button.owl-next.disabled {
    opacity: .35;
    cursor: default;
}

.jg-news-gallery--slider .owl-nav button.owl-prev span,
.jg-news-gallery--slider .owl-nav button.owl-next span {
    display: inline-block;
    line-height: 1;
    font-size: 20px;
    color: #fff;
    transform: none;
    margin: 0;
    padding: 0;
}

.jg-news-gallery--slider .owl-nav.disabled {
    display: none !important;
}

.jg-news-gallery[data-count="1"] .gallery-item__icon {
    display: none !important;
}


@media (max-width: 767px) {
    .jg-news-gallery .gallery-item__icon {
        display: none !important;
    }

    .jg-news-gallery .gallery-item__img,
    .jg-news-gallery .gallery-item__img img {
        cursor: default !important;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .jg-news-gallery .gallery-item__icon {
        opacity: .75 !important;
        transform: translateY(0) !important;
    }
}

@media (min-width: 992px) {
    .jg-news-gallery .gallery-item__icon {
        opacity: 0;
        transform: translateY(4px);
    }

    .jg-news-gallery .gallery-item:hover .gallery-item__icon,
    .jg-news-gallery .gallery-item:focus-within .gallery-item__icon {
        opacity: .75;
        transform: translateY(0);
    }
}

@media (max-width: 991px) {
    .jg-news-gallery--static,
    .jg-news-gallery--static[data-count="1"],
    .jg-news-gallery--static[data-count="2"],
    .jg-news-gallery--static[data-count="3"] {
        grid-template-columns: 1fr !important;
    }
}

/* Overlay */
.news-gallery-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    margin: 0;
    padding: 4vh 4vw;
    box-sizing: border-box;
    background: rgba(24, 33, 62, .94);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2147483647;
    cursor: pointer;
}

.news-gallery-overlay.is-open {
    display: flex;
}

.news-gallery-overlay__image {
    max-width: 92vw;
    max-height: 92vh;
    max-height: 92dvh;
    width: auto;
    height: auto;
    object-fit: contain;
    box-shadow: 0 10px 40px rgba(0, 0, 0, .55);
    display: block;
    cursor: default;
    animation: newsGalleryZoomIn .25s ease;
}

.news-gallery-overlay__close {
    position: fixed;
    top: 8px;
    right: 12px;
    width: 40px;
    height: 40px;
    padding: 0;
    margin: 0;
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 34px;
    font-weight: 300;
    line-height: 40px;
    text-align: center;
    cursor: pointer;
    z-index: 999;
    opacity: .9;
    transition: opacity .2s ease;
    font-family: 'Poppins', sans-serif;
}

.news-gallery-overlay__close:hover {
    opacity: 1;
}

.news-gallery-overlay [class*="zoom"],
.news-gallery-overlay [class*="magnif"],
.news-gallery-overlay [class*="fullscreen"] {
    display: none !important;
}

.news-gallery-overlay .jg-news-gallery-overlay-img,
.news-gallery-overlay__image {
    display: block !important;
}

html.news-gallery-locked,
body.news-gallery-locked {
    overflow: hidden !important;
    touch-action: none !important;
    overscroll-behavior: none !important;
    position: relative;
}

@keyframes newsGalleryZoomIn {
    from { 
        transform: scale(.94); 
        opacity: 0; 
    }

    to { 
        transform: scale(1);
        opacity: 1; 
    }
}