/* =========================================
MODAL OVERLAY
========================================= */

.fd-modal-overlay {
    position: fixed;
    inset: 0;

    background: rgba(2, 6, 23, .72);

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 22px;

    z-index: 99999;

    backdrop-filter: blur(4px);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition: .35s ease;
}

/* ACTIVE */

.fd-modal-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

html.fd-modal-open,
body.fd-modal-open {
    overflow: hidden !important;

    padding-right: var(--fd-scrollbar-width);
}

/* =========================================
MODAL CONTAINER
========================================= */

.fd-modal {
    width: 100%;
    max-width: 1180px;

    height: 78vh;

    display: grid;
    grid-template-columns: .88fr 1fr;

    background: #ffffff;

    overflow: hidden;

    border-radius: 22px;

    box-shadow:
        0 25px 80px rgba(0, 0, 0, .45);

    border: 1px solid rgba(255, 255, 255, .06);
}

/* =========================================
LEFT PANEL
========================================= */

.fd-modal-left {
    position: relative;

    overflow: hidden;

    background: #020617;
}

/* =========================================
BACKGROUND IMAGE
========================================= */

.fd-modal-bg {
    position: absolute;
    inset: 0;

    background:
        url("https://4diagonal.com/wp-content/uploads/2026/05/4diagonal-form-modal-background-1-scaled.webp");

    background-size: cover;
    background-position: center top;

    opacity: .18;

    transform: scale(1.02);

    z-index: 1;
    filter: invert(1) grayscale(1) brightness(1.3);
}

/* =========================================
BLUE GLOW LAYERS
========================================= */
.fd-modal-left::before {
    content: "";

    position: absolute;
    inset: 0;

    background:

        radial-gradient(circle at top left,
            rgba(37, 99, 235, .42),
            transparent 34%),

        radial-gradient(circle at bottom center,
            rgba(37, 99, 235, .18),
            transparent 42%),

        linear-gradient(180deg,
            rgba(2, 6, 23, .18) 0%,
            rgba(2, 6, 23, .42) 52%,
            rgba(2, 6, 23, .84) 100%);

    z-index: 2;
}

/* =========================================
LEFT CONTENT
========================================= */

.fd-modal-content {
    position: relative;
    z-index: 4;

    height: 100%;

    padding: 44px 42px;

    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

/* =========================================
BADGE
========================================= */

.fd-modal-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;

    width: max-content;

    margin-bottom: 28px;

    padding: 12px 22px;

    background:
        rgba(37, 99, 235, .24);

    border:
        1px solid rgba(59, 130, 246, .28);

    backdrop-filter: blur(12px);

    border-radius: 999px;

    color: #ffffff;

    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .4px;
    text-transform: uppercase;
}

.fd-badge-dot {
    width: 8px;
    height: 8px;

    border-radius: 50%;

    background: #2563eb;
}

/* =========================================
HEADING
========================================= */

.fd-modal-content h2 {
    margin: 0 0 22px;

    color: #ffffff;

    font-size: 4.2rem;
    line-height: .93;
    font-weight: 800;

    letter-spacing: -2.8px;

    max-width: 500px;
}

/* BLUE WORD */

.fd-modal-content h2 span {
    color: #2563eb;
}

/* =========================================
PARAGRAPH
========================================= */

.fd-modal-content p {
    margin: 0 0 36px;

    max-width: 470px;

    color:
        rgba(255, 255, 255, .82);

    font-size: 1.06rem;
    line-height: 1.75;
}

/* =========================================
TRUST SECTION
========================================= */

.fd-modal-trust {
    display: flex;
    align-items: center;
    gap: 22px;

    color:
        rgba(255, 255, 255, .92);

    font-size: .95rem;
    font-weight: 500;
}

.fd-trust-divider {
    opacity: .4;
}

/* =========================================
RIGHT PANEL
========================================= */

.fd-modal-right {
    position: relative;

    background: #ffffff;

    padding: 44px 44px;

    overflow-y: auto;

    height: 78vh;
}


/* =========================================
SCROLLBAR
========================================= */

.fd-modal-right::-webkit-scrollbar {
    width: 7px;
}

.fd-modal-right::-webkit-scrollbar-track {
    background: #f8fafc;
}

.fd-modal-right::-webkit-scrollbar-thumb {
    background: #cbd5e1;

    border-radius: 999px;
}

/* =========================================
CLOSE BUTTON
========================================= */

.fd-modal-close {
    position: absolute;

    top: 20px;
    right: 20px;

    width: 56px;
    height: 56px;

    border: none;

    background: #f1f5f9;

    border-radius: 14px;

    color: #0f172a;

    font-size: 2rem;

    cursor: pointer;

    transition: .25s ease;
}

.fd-modal-close:hover {
    background: #e2e8f0;
}

/* =========================================
TITLE
========================================= */

.fd-modal-right h3 {
    margin: 0 0 14px;

    color: #0f172a;

    font-size: 3.4rem;
    line-height: .95;
    font-weight: 800;

    letter-spacing: -2px;

    max-width: 540px;
}

/* =========================================
SUBTITLE
========================================= */

.fd-modal-subtitle {
    margin-bottom: 36px;

    color: #64748b;

    font-size: 1.04rem;
    line-height: 1.8;

    max-width: 540px;
}

/* =========================================
FORM
========================================= */

.fd-form-group {
    margin-bottom: 16px;
}

/* =========================================
INPUTS
========================================= */

.fd-form-group input,
.fd-form-group select,
.fd-form-group textarea {
    width: 100%;

    padding: 17px 18px;

    border: 1px solid #dbe3ec;

    border-radius: 12px;

    background: #ffffff;

    color: #0f172a;

    font-size: 1rem;

    outline: none;

    transition: .25s ease;
}

/* =========================================
FOCUS
========================================= */

.fd-form-group input:focus,
.fd-form-group select:focus,
.fd-form-group textarea:focus {
    border-color: #2563eb;

    box-shadow:
        0 0 0 4px rgba(37, 99, 235, .08);
}

/* =========================================
TEXTAREA
========================================= */

.fd-form-group textarea {
    resize: none;
}

/* =========================================
BUTTON
========================================= */

.fd-submit-btn {
    width: 100%;

    height: 58px;

    border: none;

    border-radius: 12px;

    background: #2563eb;

    color: #ffffff;

    font-size: .92rem;
    font-weight: 700;
    letter-spacing: .3px;
    text-transform: uppercase;

    cursor: pointer;

    transition: .25s ease;
}

.fd-submit-btn:hover {
    background: #1d4ed8;
}

/* =========================================
SUCCESS
========================================= */

.fd-form-success {
    display: none;

    margin-top: 18px;

    color: #15803d;

    font-size: .92rem;
    font-weight: 600;
}

/* =========================================
HIDDEN FIELD
========================================= */

.fd-hidden-field {
    display: none;
}

/* =========================================
MOBILE
========================================= */

@media(max-width:991px) {

    .fd-modal-overlay {
        padding: 12px;
    }

    .fd-modal {
        grid-template-columns: 1fr;

        max-width: 560px;

        height: auto;

        max-height: 94vh;

        border-radius: 18px;

        overflow-y: auto;
    }

    /* LEFT */

    .fd-modal-left {
        min-height: 480px;
    }

    .fd-modal-content {
        padding: 34px 24px;
    }

    .fd-modal-content h2 {
        font-size: 3rem;

        line-height: .96;

        letter-spacing: -1px;

        max-width: 100%;
    }

    .fd-modal-content p {
        font-size: .94rem;

        line-height: 1.7;

        margin-bottom: 28px;
    }

    .fd-modal-badge {
        font-size: .68rem;

        padding: 10px 16px;

        margin-bottom: 24px;
    }

    .fd-modal-trust {
        font-size: .84rem;

        gap: 12px;

        flex-wrap: wrap;
    }

    /* RIGHT */

    .fd-modal-right {
        height: auto;

        overflow: visible;

        padding: 34px 24px;
    }

    .fd-modal-right h3 {
        font-size: 2.5rem;

        letter-spacing: -1px;
    }

    .fd-modal-subtitle {
        font-size: .94rem;

        margin-bottom: 28px;
    }

    /* FORM */

    .fd-form-group {
        margin-bottom: 14px;
    }

    .fd-form-group input,
    .fd-form-group select,
    .fd-form-group textarea {
        padding: 15px 15px;

        font-size: .95rem;
    }

    .fd-submit-btn {
        height: 54px;
    }

    /* CLOSE */

    .fd-modal-close {
        width: 46px;
        height: 46px;

        border-radius: 12px;

        font-size: 1.5rem;
    }

}

@media(max-width:991px) {

    .fd-modal-close {

        position: fixed;

        top: 18px;
        right: 18px;

        width: 44px;
        height: 44px;

        display: flex;
        align-items: center;
        justify-content: center;

        background: rgba(255, 255, 255, 0.12);

        backdrop-filter: blur(12px);

        -webkit-backdrop-filter: blur(12px);

        color: #ffffff;

        z-index: 999999;

    }

}

@media(max-width:991px) {

    .fd-modal-left {
        position: relative;
    }

}