
html.imagesview-opened {
    overflow: hidden !important;
    overscroll-behavior: none;
}

#imagesview {
    position: fixed;
    height: 100vh;
    width: 100vw;
    max-width: unset;
    top: 100%;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2000;
    margin: 0;
    visibility: hidden;
    opacity: 0;

    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 420ms;
}

#imageslistview {
    position: relative;
    background: #fff;
    height: 100%;
    width: 100%;
    overflow-y: scroll !important;
    overscroll-behavior: contain;
    --webkit-overflow-scrolling: touch;
    touch-action: manipulation;
    -webkit-transform: translateZ(0px);
}
.imageslistview__header {
    position: sticky !important;
    width: 100%;
    padding: 8px;
    top: 0;
    display: flex;
    z-index: 20100;
    flex-direction: row-reverse;
    background: #ffffffef;
}

.imagesview__closebtn {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    column-gap: 9px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    background: transparent;

    border: 0;
    border-radius: 12px;
    padding: 12px 18px;
}

.carouselview__progress {
    display: flex;
    position: absolute;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    font-size: 15px;
    font-weight: 500;
    color: #fff;
    width: 100%;
    height: 100%;
    opacity: 0;
}

.imagesview__closebtn.imagesview__closebtn--white {
    color: #fff;
}

.imagesview__closebtn:hover,
.imagesview__closebtn:active {
    background: #4a4a4abb;
    color: #fff;
}

.imagesview__closebtn.imagesview__closebtn--white:hover,
.imagesview__closebtn.imagesview__closebtn--white:active {
    background: #4a4a4a;
    color: #fff;
}

.imagesview__closebtn > svg {
    width: 14px;
    height: auto;
}

.imagesview__body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    padding-bottom: 60px;
}

.imagesview__title {
    font-size: 24px;
    padding: 6px 18px;
    margin-top: 9px;
    margin-bottom: 36px;
    text-align: center;
}

.imageslistview__grid {
    display: grid;
    gap: 8px;
    grid-template-columns: 1fr;
}

.imageviewlist__grid > .imageviewlist__grid-row {
    display: grid;
    gap: 8px;
    grid-row: span 1;
}

.carousel__imagegrouplayout {
    display: grid;
    grid-auto-columns: 1fr;
    grid-auto-rows: 1fr;
    gap: 8px;
    grid-template-columns: 1fr 1fr;
}

.carousel__imagelayout-size {
    height: 100%;
    width: 100%;
    position: relative;
}

.carousel__imagelayout-position {
    height: 0px;
    min-height: 100%;
    min-width: 100%;
    overflow: hidden;
    padding-top: 67%;
}

.carousel__imagelayout-position--tall {
    padding-top: 133%;
}

.carousel__imagelayout-absolute {
    position: absolute;
    top: 0px;
    left: 0px;
    height: 100%;
    width: 100%;
}

.carousel__imagecontainer {
    cursor: pointer;
    background-image: url(data:image/png;base64,null);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: 50% 50%;
    min-height: 1px;
    width: 100%;
    height: 100%;
    vertical-align: bottom;
}

.carousel__image {
    width: 100%;
    height: 100%;
    position: absolute !important;
    overflow: clip;
    object-position: 50% 50%;
    object-fit: cover;
}

.imageslistview__group {
    display: grid;
    gap: 8px;
    grid-template-rows: 1fr 1fr;
    grid-template-columns: 1fr 1fr;
    grid-column: span 2;
}

.imageslistview__group > .imageslistview__group-row {
    display: grid;
    grid-auto-flow: column;
    grid-column: span 2;
}

.imageslistview__group > .imageslistview__group-col {
    display: grid;
    grid-auto-flow: row;
    grid-row: span 2;
}

.imageslistview__imagecontainer {
    cursor: pointer;
    background-image: url(data:image/png;base64,null);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: 50% 50%;
}

.imageslistview__imagecontainer > img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;

    grid-column-start: 2;
    max-height: 76vw;
    opacity: 0;
}

#carouselview {
    position: fixed;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    background: #000;
    visibility: hidden;
    height: 100vh;
    width: 100vw;
    max-width: 100vw;
    max-height: 100vh;
    z-index: 2001;
    top: 100%;
    bottom: 0;
    left: 0;
    right: 0;
    opacity: 0;

    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 420ms;
}

#imagesview.open,
#carouselview.open {
    visibility: visible;
    top: 0;
    opacity: 1;
}

.carouselview__header {
    display: flex;
    flex-direction: row;
    justify-content: center;
    position: relative;
    margin: 24px 24px 16px;
}

.carouselview__header .imagesview__closebtn {
    z-index: 2;
}

.carouselview__actions {
    display: none;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
}

.carouselview__action {
    display: flex;
    flex-direction: column;
    flex-basis: 80px;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 2;
}

.carouselview__previmage,
.carouselview__nextimage {
    border: 1px solid #fff;
    border-radius: 100%;
    background: #000000aa;
    width: 36px;
    height: 36px;
    padding-left: 8px;
}

.carouselview__action svg {
    display: block;
    fill: none;
    height: 16px;
    width: 16px;
    stroke: #fff;
    stroke-width: 4;
    overflow: visible;
}

.carouselview__content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    justify-content: center;
    align-items: center;
    top: 72px;
    margin: 0 auto;
    padding-bottom: 72px;
}

.carouselview__grid {
    display: grid;
    overflow-x: scroll;
    overflow-y: hidden;
    width: 102vw;
    height: auto;
    max-height: 60vh;
    scroll-snap-type: x mandatory;
    grid-auto-flow: column;
    grid-auto-columns: 102vw;
    grid-template-rows: 1fr;
    grid-gap: 32px;
}

.carouselview__grid::-webkit-scrollbar,
.carouselview__grid::-webkit-scrollbar-track,
.carouselview__grid::-webkit-scrollbar-thumb {
    display: none;
}

.carouselview__imagecontainer {
    width: 100%;
    min-width: 100%;
    text-align: center;
    margin-left: 16px;
    margin-right: 16px;
    scroll-snap-align: center;
    position: 'relative';

    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 420ms;
    background-color: #000 !important;
}

.carouselview__grid .carousel__imagecontainer > * {
    scroll-snap-align: center;
    position: relative;
    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 420ms;
    background-color: #000 !important;
}

.carouselview__grid > * {
    align-content: center;
}

.carouselview__caption {
    flex: none;
    display: block;
    max-width: 760px;
    margin: 0 auto;
    padding: 24px;
    text-align: center;
    color: #ffffffaa;
    letter-spacing: 1.2px;
    font-size: 14px;
    position: absolute;
    bottom: 24px;
    left: 0;
    right: 0;
}

#carouselview .carousel__image,
#carouselview .carousel__imagecontainer,
#carouselview .carousel__imagelayout-absolute {
    height: auto;
}

@media(min-width: 768px) {
    .imagesview__body {
        max-width: 768px;
        margin-left: auto;
        margin-right: auto;
    }

    .carouselview__actions {
        display: flex;
    }

    .carouselview__content {
        width: calc(100% - 160px);
        top: 104px;
        padding-bottom: 104px;
    }

    .carouselview__grid {
        overflow-x: hidden;
    }

    .carouselview__imagecontainer {
        margin-left: 0px;
        margin-right: 0px;
    }

    .carousel__imagecontainer {
        margin-left: 0px;
        margin-right: 0px;
    }
}

@media(min-width: 992px) {
    .imageslistview__header {
        padding-left: calc((100% - 768px) / 2);
        padding-right: calc((100% - 768px) / 2);
    }

    .carouselview__header {
        margin: 40px 64px 20px;
    }

    .carouselview__previmage,
    .carouselview__nextimage {
        width: 38px;
        height: 38px;
        padding-left: 9px;
        background: #000000aa;
    }

    .carouselview__action svg {
        height: 16px;
        width: 16px;
    }

    #carouselview .carousel__image {
        width: 100%;
    }

    .carousel__imagelayout-position {
        position: relative;
    }

    .carouselview__grid {
        max-height: unset;
    }
    #carouselview .carousel__image {
        object-fit: scale-down;
    }

    #carouselview .carousel__image,
    #carouselview .carousel__imagecontainer,
    #carouselview .carousel__imagelayout-absolute {
        height: 100%;
    }
}

@media (min-width: 1200px) {
    .carouselview__previmage,
    .carouselview__nextimage {
        width: 44px;
        height: 44px;
        padding-left: 11px;
    }

    .carouselview__action svg {
        height: 18px;
        width: 18px;
    }
}
@media (min-width: 1400px) {
    .carouselview__actions {
        padding-left: calc(50% - 660px);
        padding-right: calc(50% - 660px);
    }

    .carouselview__action {
        flex-basis: calc(50% - 660px);
        align-items: flex-start;
    }
}
