/* Hero search filter — SellBuyPartnership theme (primary blue + accent gold) */

.hero-search-wrap {
    max-width: 920px;
    margin: 28px auto 20px;
    width: 100%;
    text-align: left;
}

.hero-search-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 0;
}

.hero-search-tab {
    flex: 1;
    min-width: 0;
    max-width: none;
    padding: 12px 18px;
    border: none;
    background: rgba(30, 32, 96, 0.82);
    color: #e2e8f0;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    font-family: inherit;
    text-align: center;
    white-space: nowrap;
    text-transform: capitalize;
}

.hero-search-tab:first-child {
    border-radius: 8px 0 0 0;
}

.hero-search-tab:last-child {
    border-radius: 0 8px 0 0;
}

.hero-search-tab:hover:not(.is-active) {
    background: rgba(46, 49, 146, 0.9);
    color: #fff;
}

.hero-search-tab.is-active {
    background: var(--accent-gold, #C8A15E);
    color: #fff;
}

.search-refine .hero-search-tab {
    background: #e8eaf6;
    color: var(--primary-dark, #1e2060);
}

.search-refine .hero-search-tab:hover:not(.is-active) {
    background: #dce0f5;
    color: var(--primary, #2E3192);
}

.search-refine .hero-search-tab.is-active {
    background: var(--primary, #2E3192);
    color: #fff;
}

.hero-search-panel {
    background: #fff;
    border-radius: 0 10px 10px 10px;
    box-shadow: 0 16px 40px rgba(30, 32, 96, 0.22);
    overflow: hidden;
    border: 1px solid rgba(200, 161, 94, 0.25);
    border-top: none;
}

.search-refine .hero-search-panel {
    box-shadow: 0 8px 24px rgba(46, 49, 146, 0.08);
    border: 1px solid var(--border-light, #e2e8f0);
    border-top: none;
}

.hero-search-fields {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr auto;
    align-items: stretch;
}

/* Litigation mode: only opportunity type on Categories tab — grid columns set via JS */
.hero-search-form--litigation .hero-search-field:not(.hero-search-field--business-only) {
    border-right: 1px solid #e2e8f0;
}

.hero-search-form--litigation .hero-search-fields .hero-search-field:last-of-type {
    border-right: none;
}

.hero-search-field--litigation-only.is-hidden {
    display: none !important;
}

.hero-search-field.is-hidden {
    display: none !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
}

.hero-search-field {
    border-right: 1px solid #e2e8f0;
    padding: 0;
    min-width: 0;
    text-align: left;
}

.hero-search-field:last-of-type {
    border-right: none;
}

.hero-search-field label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    text-transform: capitalize;
    letter-spacing: 0.02em;
    color: var(--primary, #2E3192);
    opacity: 0.95;
    padding: 10px 14px 0;
    margin: 0;
    text-align: left;
}

.hero-search-field select,
.hero-search-field input[type="text"] {
    width: 100%;
    border: none;
    padding: 8px 14px 14px;
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
    background: transparent;
    outline: none;
    appearance: none;
    text-align: left;
    text-transform: capitalize;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%232E3192' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
    cursor: pointer;
    font-family: inherit;
}

.hero-search-field input[type="text"] {
    background-image: none;
    padding-right: 14px;
    cursor: text;
}

.hero-search-submit {
    width: 64px;
    min-width: 64px;
    border: none;
    background: var(--primary, #2E3192);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 20px;
    transition: background 0.2s;
    font-family: inherit;
}

.hero-search-submit-label {
    display: none;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.hero-search-submit:hover {
    background: var(--primary-dark, #1e2060);
}

.hero-search-pane {
    display: none;
}

.hero-search-pane.is-active {
    display: block;
}

.hero-search-keyword-row {
    border-top: 1px solid #e2e8f0;
    padding: 10px 14px;
    background: linear-gradient(180deg, #faf9fc 0%, #f4f5fa 100%);
}

.hero-search-keyword-row input {
    width: 100%;
    border: 1px solid #d4d8eb;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 14px;
    outline: none;
    font-family: inherit;
    box-sizing: border-box;
}

.hero-search-keyword-row input:focus {
    border-color: var(--accent-gold, #C8A15E);
    box-shadow: 0 0 0 3px rgba(200, 161, 94, 0.28);
}

@media (max-width: 768px) {
    .hero-search-wrap {
        margin: 20px auto 16px;
    }

    .hero-search-tab {
        font-size: 12px;
        padding: 11px 6px;
        letter-spacing: -0.01em;
    }

    .hero-search-panel {
        border-radius: 0 0 10px 10px;
    }

    .hero-search-fields {
        grid-template-columns: 1fr !important;
    }

    .hero-search-form--litigation .hero-search-fields {
        grid-template-columns: 1fr !important;
    }

    .hero-search-field {
        border-right: none;
        border-bottom: 1px solid #e2e8f0;
    }

    .hero-search-field label {
        padding: 12px 16px 0;
        font-size: 10px;
    }

    .hero-search-field select,
    .hero-search-field input[type="text"] {
        padding: 6px 16px 12px;
        font-size: 15px;
        background-position: right 16px center;
    }

    .hero-search-submit {
        width: 100%;
        min-width: 0;
        min-height: 52px;
        border-radius: 0;
    }

    .hero-search-submit-label {
        display: inline;
    }
}

@media (max-width: 480px) {
    .hero-search-wrap {
        margin: 16px auto 12px;
    }

    .hero-search-tab {
        font-size: 11px;
        padding: 10px 4px;
    }

    .hero-search-tab:first-child {
        border-radius: 6px 0 0 0;
    }

    .hero-search-tab:last-child {
        border-radius: 0 6px 0 0;
    }

    .hero-search-panel {
        border-radius: 0 0 8px 8px;
        box-shadow: 0 10px 28px rgba(30, 32, 96, 0.18);
    }

    .hero-search-field label {
        padding: 10px 14px 0;
    }

    .hero-search-field select,
    .hero-search-field input[type="text"] {
        padding: 6px 14px 11px;
        font-size: 14px;
    }

    .hero-search-submit {
        min-height: 48px;
    }
}
