#vanita-gallery {
    overflow: visible;
    max-width: calc(100vw - 32px);
    max-height: calc(100dvh - 32px);
    padding: 12px;
    border: 0;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 4px 20px rgb(0 0 0 / 35%);
}

#vanita-gallery::backdrop {
    background: rgb(0 0 0 / 72%);
}

#vanita-gallery img {
    display: block;
    max-width: min(1120px, calc(100vw - 56px));
    max-height: calc(100dvh - 56px);
    min-width: 80px;
    min-height: 48px;
    object-fit: contain;
    touch-action: pan-y;
}

#vanita-gallery button {
    position: absolute;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid #fff;
    border-radius: 50%;
    background: #242424;
    color: #fff;
    font: 28px/1 Arial, sans-serif;
    cursor: pointer;
}

#vanita-gallery button[hidden] { display: none; }
#vanita-gallery button:focus-visible { outline: 2px solid #b38708; outline-offset: 2px; }
#vanita-gallery [data-gallery-close] { top: 4px; right: 4px; }
#vanita-gallery [data-gallery-step] { top: calc(50% - 22px); }
#vanita-gallery [data-gallery-step="-1"] { left: 4px; }
#vanita-gallery [data-gallery-step="1"] { right: 4px; }
