/* Searchable select — hides native <select>, shows filterable combobox synced to same value/name */

.ss-wrap {
    position: relative;
    width: 100%;
}

.ss-wrap > select.ss-native {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.ss-wrap .ss-control {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    padding-right: 6px !important;
    cursor: default;
}

.ss-wrap .ss-input {
    flex: 1;
    min-width: 0;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 4px !important;
    margin: 0 !important;
    height: auto !important;
    font: inherit !important;
    color: inherit !important;
    outline: none !important;
}

.ss-wrap .ss-input::placeholder {
    color: var(--text-secondary, #94a3b8);
    opacity: 0.85;
}

.ss-wrap .ss-toggle {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 8px;
    background: rgba(99, 102, 241, 0.12);
    color: var(--primary, #6366f1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
}

.ss-wrap .ss-toggle:hover {
    background: rgba(99, 102, 241, 0.2);
}

.ss-wrap.ss-open .ss-toggle {
    background: rgba(99, 102, 241, 0.22);
}

.ss-wrap.ss-open .ss-toggle i {
    transform: rotate(180deg);
}

.ss-wrap .ss-toggle i {
    transition: transform 0.18s ease;
    font-size: 0.7rem;
}

.ss-panel {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 1060;
    max-height: 260px;
    overflow: hidden;
    border-radius: 10px;
    border: 1px solid var(--surface-border, rgba(148, 163, 184, 0.35));
    background: var(--surface-card, #fff);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12);
}

.ss-wrap.ss-open .ss-panel {
    display: flex;
    flex-direction: column;
}

.ss-options {
    list-style: none;
    margin: 0;
    padding: 6px 0;
    overflow-y: auto;
    max-height: 228px;
    scrollbar-width: thin;
}

.ss-options::-webkit-scrollbar {
    width: 6px;
}

.ss-options::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.3);
    border-radius: 4px;
}

.ss-option {
    padding: 10px 14px;
    font-size: 0.875rem;
    cursor: pointer;
    color: var(--text-primary, #1e293b);
}

.ss-option:hover,
.ss-option.ss-highlight {
    background: rgba(99, 102, 241, 0.1);
}

.ss-option.ss-muted {
    color: var(--text-secondary, #64748b);
    font-weight: 500;
}

.ss-empty {
    padding: 14px;
    font-size: 0.82rem;
    color: var(--text-secondary);
    text-align: center;
}

.ss-wrap.ss-disabled .ss-control {
    opacity: 0.55;
    pointer-events: none;
}

/* Inside flex input-groups — match trip entry customer row */
.input-group.d-flex > .ss-wrap {
    flex: 1 1 auto;
    min-width: 0;
}
