/* ==========================================================================
   Generic lead intake popup — blog-page "Find a Lawyer" CTAs.
   Same brand colors/modal conventions as profile-card.css (navy #1b2a4e, orange
   var(--p-color,#f7931e)), kept as its own file since the fields/layout are entirely
   different from the profile card itself.
   ========================================================================== */

.lp-glf-modal .modal-dialog {
    max-width: 420px;
    margin: 14px auto;
    display: flex;
    align-items: center;
    min-height: calc(100vh - 28px);
}

.lp-glf-modal .modal-content {
    position: relative; /* anchors .lp-glf-close - not relying on Bootstrap's own .modal-content rule for this */
    border-radius: 18px;
    border: none;
    padding: 16px 16px 14px;
    box-shadow: 0 20px 60px rgba(27, 42, 78, 0.25);
    max-height: calc(100vh - 28px);
    overflow-y: auto;
    width: 100%;
}

.lp-glf-modal .lp-glf-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f2f4f8;
    color: #1b2a4e;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    z-index: 2;
}

.lp-glf-title {
    color: #1b2a4e;
    font-size: 16px;
    font-weight: 800;
    line-height: 1.25;
    margin: 0 0 2px;
    padding-right: 24px;
}

.lp-glf-subtitle {
    color: #5a6478;
    font-size: 11.5px;
    line-height: 1.35;
    margin: 0 0 10px;
}

.lp-glf-row {
    display: flex;
    gap: 10px;
}

.lp-glf-row .lp-glf-field {
    flex: 1;
    min-width: 0; /* lets a select/input shrink below its content width inside the flex row instead of overflowing */
}

.lp-glf-field {
    margin-bottom: 8px;
    /* .lp-location-suggestions (main.css) positions absolutely relative to the nearest
       positioned ancestor — this is that ancestor, same role .lp-new-cat-wrape plays on
       the submit-listing form, so the dropdown lands directly under the input here too. */
    position: relative;
}

/* Restores the dropdown-arrow spacing main.css's .lp-location-typeahead rule sets
   (padding-right: 34px) — this file's own generic "padding: 10px 12px" on all
   input[type="text"] below is more specific and would otherwise win and crowd the icon. */
.lp-glf-field .lp-location-typeahead {
    padding-right: 34px;
}

.lp-glf-field label {
    display: block;
    color: #1b2a4e;
    font-size: 11.5px;
    font-weight: 700;
    margin-bottom: 3px;
}

.lp-glf-optional {
    font-weight: 400;
    color: #8892a6;
}

.lp-glf-field input[type="text"],
.lp-glf-field input[type="email"],
.lp-glf-field input[type="tel"],
.lp-glf-field select,
.lp-glf-field textarea {
    width: 100%;
    padding: 7px 10px;
    border: 1px solid #d8dfec;
    border-radius: 7px;
    font-size: 13px;
    color: #1b2a4e;
    background: #fff;
    box-sizing: border-box;
}

.lp-glf-field textarea {
    resize: vertical;
    min-height: 42px;
}

.lp-glf-field input:focus,
.lp-glf-field select:focus,
.lp-glf-field textarea:focus {
    outline: none;
    border-color: var(--p-color, #f7931e);
}

.lp-glf-field-error input,
.lp-glf-field-error select,
.lp-glf-field-error textarea {
    border-color: #e0554f;
    background: #fff6f5;
}

.lp-glf-honeypot {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.lp-glf-consent {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 2px 0 10px;
    font-size: 11px;
    color: #5a6478;
    line-height: 1.3;
    cursor: pointer;
}

.lp-glf-consent input {
    margin-top: 3px;
    flex: none;
}

.lp-glf-error {
    background: #fff0ef;
    border: 1px solid #f3c8c5;
    color: #b3352e;
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 7px;
    margin-bottom: 8px;
}

.lp-glf-submit-btn {
    width: 100%;
    padding: 10px 16px;
    border: none;
    border-radius: 9px;
    background: #1b2a4e;
    color: #fff !important;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.15s ease, transform 0.1s ease;
}

.lp-glf-submit-btn:hover {
    opacity: 0.92;
}

.lp-glf-submit-btn:active {
    transform: scale(0.98);
}

.lp-glf-submit-btn:disabled {
    opacity: 0.6;
    cursor: default;
}

@media (max-width: 480px) {
    .lp-glf-modal .modal-dialog {
        margin: 8px auto;
        max-width: none;
        min-height: calc(100vh - 16px);
        padding: 0 10px;
    }

    .lp-glf-modal .modal-content {
        padding: 14px 14px 12px;
        border-radius: 14px;
        max-height: calc(100vh - 16px);
    }
}

/* Very short viewports (landscape phones, small laptops) — shrink further rather than
   relying on internal scroll alone, same approach used for the profile card modal. */
@media (max-height: 700px) {
    .lp-glf-subtitle {
        margin-bottom: 6px;
    }

    .lp-glf-field {
        margin-bottom: 6px;
    }

    .lp-glf-field textarea {
        min-height: 34px;
    }
}
