/* =====================================================
   INQUIRY MODAL — 2-step lead-capture popup
   Scope: prefix everything with `iq-` to avoid collisions
   ===================================================== */

.iq-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    transition: opacity .25s ease;
}
.iq-modal.is-open {
    display: flex;
    opacity: 1;
}

.iq-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3, 7, 18, .72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.iq-modal__dialog {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: min(1100px, 100%);
    max-height: calc(100vh - 48px);
    background: #0b1220;
    color: #e5e7eb;
    border-radius: 22px;
    overflow: hidden;
    box-shadow:
        0 30px 80px -20px rgba(0, 0, 0, .65),
        0 0 0 1px rgba(255, 255, 255, .04);
    transform: translateY(20px) scale(.98);
    transition: transform .35s cubic-bezier(.2, .8, .2, 1), opacity .25s;
    opacity: 0;
}
.iq-modal.is-open .iq-modal__dialog {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* ----------------- LEFT HERO PANE ----------------- */
.iq-modal__hero {
    position: relative;
    min-height: 560px;
    background:
        linear-gradient(180deg, rgba(11, 18, 32, .15) 0%, rgba(11, 18, 32, .85) 100%),
        url('https://images.unsplash.com/photo-1469854523086-cc02fe5d8800?q=80&w=1400&auto=format&fit=crop') center / cover no-repeat;
    color: #fff;
    overflow: hidden;
}
.iq-modal__hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(620px 320px at 80% 20%, rgba(56, 189, 248, .15), transparent 60%),
        radial-gradient(420px 220px at 20% 90%, rgba(96, 165, 250, .12), transparent 60%);
    pointer-events: none;
}
.iq-modal__hero-inner {
    position: relative;
    padding: 48px 44px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    height: 100%;
}
.iq-modal__hero-title {
    font-size: 38px;
    line-height: 1.1;
    margin: 0;
    font-weight: 800;
    letter-spacing: -.02em;
    color: #fff;
}
.iq-modal__hero-sub {
    font-size: 15px;
    line-height: 1.6;
    color: rgba(255, 255, 255, .82);
    margin: 0;
    max-width: 420px;
}
.iq-modal__hero-list {
    list-style: none;
    margin: auto 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.iq-modal__hero-list li {
    display: flex;
    align-items: center;
    gap: 14px;
}
.iq-modal__hero-icon {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, .12);
    color: #93c5fd;
    backdrop-filter: blur(4px);
}
.iq-modal__hero-list li > div {
    display: flex;
    flex-direction: column;
}
.iq-modal__hero-list strong {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
}
.iq-modal__hero-list span {
    color: rgba(255, 255, 255, .68);
    font-size: 13px;
}

/* ----------------- RIGHT FORM PANE ----------------- */
.iq-modal__pane {
    position: relative;
    padding: 44px 44px 36px;
    overflow-y: auto;
    background:
        radial-gradient(900px 500px at 100% 0%, rgba(99, 102, 241, .08), transparent 60%),
        #0b1220;
}
.iq-modal__pane::-webkit-scrollbar {
    width: 6px;
}
.iq-modal__pane::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .12);
    border-radius: 6px;
}

.iq-modal__close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .18);
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .85);
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: background .2s, transform .2s, border-color .2s;
    z-index: 2;
}
.iq-modal__close:hover {
    background: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .35);
    transform: rotate(90deg);
}

.iq-step {
    animation: iqFadeIn .35s ease both;
}
.iq-step[hidden] {
    display: none;
}
@keyframes iqFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.iq-step__head {
    margin-bottom: 18px;
}
.iq-step__title {
    margin: 0 0 6px;
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    letter-spacing: -.01em;
}
.iq-step__sub {
    margin: 0;
    color: rgba(255, 255, 255, .62);
    font-size: 14px;
}

.iq-progress {
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .07);
    overflow: hidden;
    margin-bottom: 28px;
}
.iq-progress__bar {
    height: 100%;
    background: linear-gradient(90deg, #34d399 0%, #38bdf8 45%, #fbbf24 100%);
    border-radius: inherit;
    box-shadow: 0 0 12px rgba(56, 189, 248, .55);
    transition: width .35s ease;
}

/* ----------------- FORM FIELDS ----------------- */
.iq-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.iq-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.iq-field label {
    color: rgba(255, 255, 255, .82);
    font-size: 14px;
    font-weight: 500;
}
.iq-field label span {
    color: #f87171;
}
.iq-field input,
.iq-field textarea {
    width: 100%;
    background: rgba(255, 255, 255, .03);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 12px;
    padding: 13px 16px;
    color: #fff;
    font-size: 15px;
    font-family: inherit;
    transition: border-color .2s, background .2s, box-shadow .2s;
}
.iq-field textarea {
    resize: vertical;
    min-height: 88px;
}
.iq-field input::placeholder,
.iq-field textarea::placeholder {
    color: rgba(255, 255, 255, .35);
}
.iq-field input:focus,
.iq-field textarea:focus {
    outline: none;
    border-color: rgba(56, 189, 248, .55);
    background: rgba(255, 255, 255, .06);
    box-shadow: 0 0 0 4px rgba(56, 189, 248, .12);
}
.iq-field input[readonly] {
    color: rgba(255, 255, 255, .9);
    background: rgba(255, 255, 255, .05);
    cursor: default;
}
.iq-field__error {
    color: #fca5a5;
    font-size: 12px;
    min-height: 1em;
}
.iq-field.has-error input,
.iq-field.has-error textarea {
    border-color: rgba(248, 113, 113, .6);
    background: rgba(248, 113, 113, .06);
}

/* ----------------- COUNTER ----------------- */
.iq-counter {
    display: inline-flex;
    align-items: center;
    gap: 14px;
}
.iq-counter__btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .15);
    background: rgba(255, 255, 255, .04);
    color: #fff;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: background .15s, border-color .15s, transform .1s;
}
.iq-counter__btn:hover {
    background: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .35);
}
.iq-counter__btn:active {
    transform: scale(.95);
}
.iq-counter__value {
    min-width: 32px;
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    color: #fff;
}

/* ----------------- BUDGET CHIPS ----------------- */
.iq-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}
.iq-chip {
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .85);
    font-size: 13px;
    cursor: pointer;
    transition: background .15s, border-color .15s, color .15s;
}
.iq-chip:hover {
    background: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .35);
    color: #fff;
}
.iq-chip.is-active {
    background: linear-gradient(135deg, #38bdf8, #6366f1);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 6px 18px -6px rgba(56, 189, 248, .55);
}

/* ----------------- CHECKBOX ----------------- */
.iq-checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, .85);
    font-size: 14px;
    cursor: pointer;
    user-select: none;
}
.iq-checkbox input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.iq-checkbox__box {
    width: 20px;
    height: 20px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, .25);
    background: rgba(255, 255, 255, .04);
    display: grid;
    place-items: center;
    transition: background .15s, border-color .15s;
    flex: none;
}
.iq-checkbox__box::after {
    content: "";
    width: 6px;
    height: 11px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) scale(0);
    transition: transform .15s ease;
    margin-top: -2px;
}
.iq-checkbox input:checked + .iq-checkbox__box {
    background: linear-gradient(135deg, #38bdf8, #6366f1);
    border-color: transparent;
}
.iq-checkbox input:checked + .iq-checkbox__box::after {
    transform: rotate(45deg) scale(1);
}

.iq-step__legal {
    font-size: 12.5px;
    color: rgba(255, 255, 255, .55);
    margin: 4px 0 0;
}
.iq-step__legal a {
    color: #7dd3fc;
    text-decoration: none;
}
.iq-step__legal a:hover {
    text-decoration: underline;
}

/* ----------------- FOOTER / BUTTONS ----------------- */
.iq-step__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, .06);
}
.iq-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: 999px;
    border: 0;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform .15s, box-shadow .15s, opacity .15s;
}
.iq-btn:disabled {
    opacity: .55;
    cursor: not-allowed;
}
.iq-btn--ghost {
    background: transparent;
    color: rgba(255, 255, 255, .75);
    padding-left: 12px;
}
.iq-btn--ghost:hover {
    color: #fff;
}
.iq-btn--primary {
    background: linear-gradient(135deg, #7dd3fc, #38bdf8);
    color: #06223a;
    box-shadow: 0 10px 26px -10px rgba(56, 189, 248, .8);
}
.iq-btn--primary:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 14px 30px -10px rgba(56, 189, 248, .9);
}

/* ----------------- SUCCESS ----------------- */
.iq-step--done .iq-done {
    text-align: center;
    padding: 40px 10px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}
.iq-done__icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #34d399, #38bdf8);
    color: #fff;
    font-size: 30px;
    display: grid;
    place-items: center;
    margin-bottom: 4px;
    box-shadow: 0 12px 28px -10px rgba(52, 211, 153, .8);
}
.iq-done__title {
    margin: 0;
    color: #fff;
    font-size: 24px;
    font-weight: 700;
}
.iq-done__msg {
    color: rgba(255, 255, 255, .75);
    font-size: 14px;
    margin: 0;
    max-width: 320px;
}
.iq-done__ref {
    color: rgba(255, 255, 255, .55);
    font-size: 12px;
    margin: 4px 0 12px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.iq-done__next {
    width: 100%;
    margin: 6px 0 14px;
    padding: 12px 16px;
    background: rgba(251, 191, 36, .08);
    border: 1px solid rgba(251, 191, 36, .35);
    border-radius: 10px;
    color: #fde68a;
    font-size: 13.5px;
    line-height: 1.5;
    text-align: center;
}
.iq-done__next strong { color: #fcd34d; font-weight: 700; }
.iq-done__actions {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 6px;
}
.iq-btn--wa {
    background: #25d366;
    color: #fff;
    box-shadow: 0 10px 26px -10px rgba(37, 211, 102, .65);
}
.iq-btn--wa:hover:not(:disabled) {
    background: #1ebe5b;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 14px 30px -10px rgba(37, 211, 102, .8);
}

/* ----------------- RESPONSIVE ----------------- */
@media (max-width: 860px) {
    .iq-modal {
        padding: 0;
    }
    .iq-modal__dialog {
        grid-template-columns: 1fr;
        max-height: 100vh;
        height: 100vh;
        border-radius: 0;
    }
    .iq-modal__hero {
        display: none;
    }
    .iq-modal__pane {
        padding: 28px 22px 24px;
    }
    .iq-step__title {
        font-size: 24px;
    }
}

/* lock body scroll when modal is open */
body.iq-modal-open {
    overflow: hidden;
}
