.webfus-shadow {
    display: block;
    background: rgba(58, 63, 68, 0.7);
    overflow: hidden;
    width: 100dvw;
    height: 100dvh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: -10;
    opacity: 0;
    cursor: auto;
    transition: opacity 0.3s linear,
                z-index 0s linear 0.3s;
}

.webfus-shadow--active {
    opacity: 1;
    z-index: 999;
    transition: opacity 0.3s linear;
}

.webfus-popup {
    background: #fff;
    border-radius: 0;
    width: min(calc(100vw - 30px), 420px);
    max-height: calc(100dvh - 30px);
    overflow: scroll;
    position: fixed;
    top: 50%;
    left: 50%;
    z-index: -10;
    opacity: 0;
    transform: translate(-50%, -50%);
    transition: opacity 0.3s linear,
                z-index 0s linear 0.3s;
}

.webfus-popup::-webkit-scrollbar {
    display: none;
}

.webfus-popup::-webkit-scrollbar-track {
    display: none;
}

.webfus-popup::-webkit-scrollbar-thumb {
    display: none;
}

.webfus-popup--active {
    opacity: 1;
    z-index: 999;
    transition: opacity 0.3s linear;
}

.webfus-popup__close {
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 1;
}

.webfus-popup__close[class*="j-"] {
    cursor: pointer;
}

.webfus-popup__close svg {
    fill: #888888;
    transition: fill 0.3s ease-out;
}

.webfus-popup__head {
    border-bottom: 2px solid #8c010a;
    padding: 35px 40px 35px 35px;
}

.webfus-popup__head > *:last-child {
    margin-bottom: 0;
}

.webfus-popup__title {
    font-size: 1.866em;
    line-height: 1.2;
    color: #383838;
    font-weight: 700;
    margin: 0 0 15px 0;
}

.webfus-popup__head:has(.webfus-popup__subtitle:empty) .webfus-popup__title {
    margin-bottom: 0;
}

.webfus-popup__subtitle {
    font-size: 15px;
    line-height: 1.6;
    color: #383838;
    margin: 0;
}

.webfus-popup__body {
    padding: 35px;
}

.webfus-popup__body:has(.webfus-form--success) {
    display: none;
}

.webfus-popup_result {
    padding: 35px;
    font-size: 15px;
    line-height: 1.6;
    color: #383838;
    display: none;
}

.webfus-popup:has(.webfus-form--success) .webfus-popup_result {
    display: block;
}

.webfus-popup_result p {
    font-size: 15px;
    line-height: 1.6;
    color: #383838;
    margin: 0;
}

@media (hover: hover) and (pointer: fine) {
    .webfus-popup__close:hover svg {
        fill: #9a0202;
    }
}

@media (max-width: 767px) {
    .webfus-popup {
        width: min(calc(100vw - 30px), 520px);
    }
}

@media (max-width: 400px) {
    .webfus-popup__head,
    .webfus-popup__body,
    .webfus-popup_result {
        padding-inline: 15px;
    }
}