.wesbank-popup[hidden] {
    display: none;
}

.wesbank-popup {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    background: rgba(13, 13, 33, 0.62);
}

html.wesbank-popup-open,
html.wesbank-popup-open body {
    overflow: hidden;
}

.wesbank-popup__dialog {
    position: relative;
    width: min(800px, 100%);
    max-height: calc(100vh - 48px);
    overflow: auto;
    background: transparent;
}

.wesbank-popup__sr {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.wesbank-popup__close,
.wesbank-ad__close {
    position: absolute;
    z-index: 2;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    background: #fff;
    color: #0d0d21;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(13, 13, 33, 0.16);
}

.wesbank-popup__close {
    top: 14px;
    right: 14px;
}

.wesbank-popup__close:hover,
.wesbank-ad__close:hover {
    background: #0d0d21;
    color: #fff;
}

.wesbank-popup__close:focus-visible,
.wesbank-popup__cta:focus-visible,
.wesbank-ad__close:focus-visible,
.wesbank-ad__link:focus-visible {
    outline: 3px solid #6a67ff;
    outline-offset: 2px;
}

.wesbank-popup__cta {
    display: block;
    line-height: 0;
}

.wesbank-popup__image {
    display: block;
    width: 100%;
    height: auto;
}

.wesbank-popup__image {
    aspect-ratio: 800 / 600;
}

.wesbank-ad {
    position: relative;
    align-self: start;
    margin: 0;
    background: #1710ff;
}

.wesbank-ad .card-insurance-icon {
    width: 72px;
    height: 72px;
    background: #fff;
}

.wesbank-ad__mark {
    display: block;
    width: 40px;
    height: 40px;
}

.wesbank-ad .card-insurance-button {
    line-height: 1.2;
    background: #fff;
    color: #1710ff;
    border-color: #fff;
}

.wesbank-ad__close {
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    font-size: 24px;
}

@media screen and (max-width: 720px) {
    .wesbank-popup {
        padding: 16px;
    }

    .wesbank-popup__dialog {
        width: min(360px, 100%);
    }

    .wesbank-popup__image {
        aspect-ratio: 1 / 1;
    }

    .wesbank-popup__close {
        top: 10px;
        right: 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .wesbank-popup__close,
    .wesbank-ad__close {
        transition: none;
    }
}

@media print {
    .wesbank-popup,
    .wesbank-ad {
        display: none !important;
    }
}
