.engimov-area-modal[hidden] {
    display: none !important;
}

html.engimov-area-modal-open,
body.engimov-area-modal-open {
    overflow: hidden;
}

.engimov-area-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 180ms ease;
}

.engimov-area-modal.is-visible {
    opacity: 1;
}

.engimov-area-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3, 27, 49, 0.72);
    backdrop-filter: blur(3px);
}

.engimov-area-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 620px);
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    box-sizing: border-box;
    padding: 40px;
    border: 1px solid #d4e0ea;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 24px 70px rgba(1, 29, 53, 0.28);
    color: #132f48;
    font-family: inherit;
    transform: translateY(16px) scale(0.98);
    transition: transform 180ms ease;
    outline: none;
}

.engimov-area-modal.is-visible .engimov-area-modal__dialog {
    transform: translateY(0) scale(1);
}

.engimov-area-modal__close {
    position: absolute;
    top: 14px;
    right: 16px;
    width: 42px;
    height: 42px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #456079;
    font-size: 32px;
    line-height: 38px;
    cursor: pointer;
}

.engimov-area-modal__close:hover,
.engimov-area-modal__close:focus-visible {
    background: #edf4f8;
    color: #0b416b;
    outline: 2px solid #0b416b;
    outline-offset: 2px;
}

.engimov-area-modal__icon {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    margin-bottom: 20px;
    border-radius: 50%;
    background: #fff2d9;
    color: #a65b00;
    font-size: 32px;
    font-weight: 800;
}

.engimov-area-modal__dialog h2 {
    margin: 0 44px 14px 0;
    color: #063b64;
    font-size: clamp(24px, 4vw, 32px);
    line-height: 1.18;
}

.engimov-area-modal__dialog p {
    margin: 0;
    color: #3b5266;
    font-size: 17px;
    line-height: 1.7;
}

.engimov-area-modal__accept {
    width: 100%;
    margin-top: 26px;
    padding: 15px 20px;
    border: 0;
    border-radius: 12px;
    background: #123f64;
    color: #ffffff;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
}

.engimov-area-modal__accept:hover,
.engimov-area-modal__accept:focus-visible {
    background: #0a3151;
    outline: 3px solid rgba(18, 63, 100, 0.28);
    outline-offset: 3px;
}

@media (max-width: 600px) {
    .engimov-area-modal {
        align-items: flex-end;
        padding: 12px;
    }

    .engimov-area-modal__dialog {
        width: 100%;
        max-height: calc(100vh - 24px);
        padding: 30px 22px 24px;
        border-radius: 20px;
    }

    .engimov-area-modal__dialog p {
        font-size: 15px;
        line-height: 1.6;
    }
}

@media (prefers-reduced-motion: reduce) {
    .engimov-area-modal,
    .engimov-area-modal__dialog {
        transition: none;
    }
}
