html.vdm-bpc-lock,
body.vdm-bpc-lock {
    overflow: hidden !important;
    overscroll-behavior: none;
}

.vdm-bpc-overlay {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    z-index: 2147483000;
    display: none;
    align-items: stretch;
    justify-content: stretch;
    background: #000;
    opacity: 0;
    transition: opacity .22s ease;
    padding: 0;
    margin: 0;
}

.vdm-bpc-overlay.is-visible {
    opacity: 1;
}

.vdm-bpc-click-area {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    padding:
        max(12px, env(safe-area-inset-top))
        max(12px, env(safe-area-inset-right))
        max(12px, env(safe-area-inset-bottom))
        max(12px, env(safe-area-inset-left));
}

.vdm-bpc-click-area.is-clickable {
    cursor: pointer;
}

.vdm-bpc-image {
    display: block;
    width: auto;
    height: auto;
    max-width: 94vw;
    max-height: 94vh;
    max-height: 94dvh;
    object-fit: contain;
    object-position: center center;
    margin: auto;
    padding: 0;
    border: 0;
    user-select: none;
    -webkit-user-drag: none;
}

.vdm-bpc-close {
    position: absolute;
    top: max(14px, env(safe-area-inset-top));
    right: max(14px, env(safe-area-inset-right));
    z-index: 3;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: rgba(0, 0, 0, .58);
    color: #fff;
    font-size: 31px;
    font-weight: 300;
    line-height: 1;
    box-shadow: 0 2px 14px rgba(0,0,0,.28);
    cursor: pointer;
    padding: 0 0 4px;
    -webkit-tap-highlight-color: transparent;
}

@media (min-width: 1201px) {
    .vdm-bpc-overlay { display: none !important; }
}
