.evrika-crm-popup {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
}

.evrika-crm-popup.is-open {
    display: block;
}

.evrika-crm-popup-overlay {
    position: absolute;
    inset: 0;
    background: rgba(19, 25, 34, 0.72);
    backdrop-filter: blur(4px);
}

.evrika-crm-popup-dialog {
    position: relative;
    width: min(960px, calc(100vw - 32px));
    height: min(860px, calc(100vh - 32px));
    margin: 16px auto;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
    overflow: hidden;
}

.evrika-crm-popup-close {
    position: absolute;
    top: 14px;
    right: 24px;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    appearance: none;
    border: 1px solid rgba(17, 24, 39, 0.14);
    background: rgba(255, 255, 255, 0.96);
    color: transparent;
    width: 48px;
    height: 48px;
    padding: 0;
    border-radius: 999px;
    cursor: pointer;
    font-size: 0;
    line-height: 0;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
    backdrop-filter: blur(8px);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.evrika-crm-popup-close::before,
.evrika-crm-popup-close::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 22px;
    height: 3px;
    background: #111827;
    border-radius: 999px;
    transform-origin: center;
}

.evrika-crm-popup-close::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.evrika-crm-popup-close::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.evrika-crm-popup-close:hover,
.evrika-crm-popup-close:focus-visible {
    background: #ffffff;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.24);
    transform: scale(1.03);
    outline: none;
}

.evrika-crm-popup-body {
    flex: 1 1 auto;
    width: 100%;
    height: 100%;
    min-height: 0;
    background: #ffffff;
}

.evrika-crm-popup-frame {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #ffffff;
}

body.evrika-crm-popup-open {
    overflow: hidden;
}

@media (max-width: 767px) {
    .evrika-crm-popup-dialog {
        width: calc(100vw - 12px);
        height: calc(100vh - 12px);
        margin: 6px auto;
        border-radius: 14px;
    }

    .evrika-crm-popup-close {
        top: 10px;
        right: 16px;
        width: 44px;
        height: 44px;
    }

    .evrika-crm-popup-close::before,
    .evrika-crm-popup-close::after {
        width: 20px;
        height: 2.5px;
    }
}
