/* =============================================================================
   ALVINAH PARTNERS — Composant multi-select recherchable (Sprint 4 NAF-E)
   multiselect.css · style Linear/Notion · Dark Navy
   ============================================================================= */

.multiselect {
    position: relative;
    width: 100%;
    background: var(--bg-input, #0a1219);
    border: 1px solid var(--border-base, #22304a);
    border-radius: var(--radius-sm, 4px);
    padding: 6px;
    transition: border-color var(--transition, 150ms ease-out);
}

.multiselect:focus-within {
    border-color: var(--accent, #2e75b6);
    outline: 2px solid var(--accent, #2e75b6);
    outline-offset: -1px;
}

/* ---------- Tags zone (chips sélectionnés) ----------------------------- */
.multiselect-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 4px;
}

.multiselect-tags:empty {
    display: none;
}

.multiselect-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 4px 3px 10px;
    background: rgba(46, 117, 182, 0.18);
    border: 1px solid var(--accent-dim, #1f4e7a);
    border-radius: 999px;
    font-size: 12px;
    color: var(--text-primary, #e8eef5);
    line-height: 1.4;
}

.multiselect-tag-remove {
    background: transparent;
    border: none;
    color: var(--text-secondary, #8fa0b4);
    cursor: pointer;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    line-height: 1;
    padding: 0;
    transition: background var(--transition, 150ms ease-out),
                color var(--transition, 150ms ease-out);
}

.multiselect-tag-remove:hover {
    background: var(--status-danger, #b36f6a);
    color: #fff;
}

.multiselect-tag-remove:focus-visible {
    outline: 2px solid var(--accent-strong, #7b9ec0);
    outline-offset: 1px;
}

/* ---------- Search input ----------------------------------------------- */
.multiselect-search-wrapper {
    display: flex;
    align-items: center;
}

.multiselect-search {
    flex: 1;
    border: none;
    background: transparent;
    color: var(--text-primary, #e8eef5);
    font-size: 14px;
    font-family: inherit;
    padding: 6px 8px;
    outline: none;
    min-width: 100px;
}

.multiselect-search::placeholder {
    color: var(--text-muted, #5a6b82);
}

/* ---------- Dropdown listbox ------------------------------------------ */
.multiselect-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 30;
    background: var(--bg-card, #162030);
    border: 1px solid var(--border-strong, #2e4264);
    border-radius: var(--radius-sm, 4px);
    list-style: none;
    margin: 0;
    padding: 4px 0;
    max-height: 280px;
    overflow-y: auto;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.32);
}

.multiselect-dropdown[hidden] {
    display: none;
}

.multiselect-option {
    padding: 6px 12px;
    cursor: pointer;
    color: var(--text-secondary, #8fa0b4);
    font-size: 13px;
    line-height: 1.4;
    transition: background var(--transition, 150ms ease-out),
                color var(--transition, 150ms ease-out);
}

.multiselect-option:hover,
.multiselect-option.is-active {
    background: var(--bg-card-hover, #1c2838);
    color: var(--text-primary, #e8eef5);
}

.multiselect-option.is-selected {
    color: var(--accent-strong, #7b9ec0);
    font-weight: 500;
}

.multiselect-option.is-selected.is-active {
    background: rgba(46, 117, 182, 0.18);
}

.multiselect-empty {
    padding: 10px 12px;
    color: var(--text-muted, #5a6b82);
    font-style: italic;
    font-size: 13px;
}

/* ---------- Banner alerte revue manuelle ------------------------------- */
.repreneur-banner-revue-manuelle {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    background: rgba(201, 144, 96, 0.12);
    border: 1px solid var(--status-warn, #c99060);
    border-left: 3px solid var(--status-warn, #c99060);
    border-radius: var(--radius-md, 8px);
    color: var(--text-primary, #e8eef5);
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 16px;
}

.repreneur-banner-revue-manuelle-icone {
    font-size: 18px;
    line-height: 1;
    flex-shrink: 0;
}

.repreneur-banner-revue-manuelle-libelle {
    flex: 1;
}

.repreneur-banner-revue-manuelle-libelle strong {
    color: var(--status-warn, #c99060);
    font-weight: 600;
}

/* ---------- Range budget (2 inputs côte à côte) ------------------------ */
.repreneur-budget-range {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.repreneur-budget-range-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.repreneur-budget-range-field label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted, #5a6b82);
}

.repreneur-budget-range-field input {
    padding: 8px 10px;
    background: var(--bg-input, #0a1219);
    border: 1px solid var(--border-base, #22304a);
    border-radius: var(--radius-sm, 4px);
    color: var(--text-primary, #e8eef5);
    font-size: 14px;
    font-family: inherit;
}

.repreneur-budget-range-field input:focus-visible {
    outline: 2px solid var(--accent, #2e75b6);
    outline-offset: 1px;
}

@media (max-width: 640px) {
    .repreneur-budget-range {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .multiselect,
    .multiselect-option,
    .multiselect-tag-remove {
        transition: none;
    }
}
