/* Shared Select2 vehicle color: filled swatch + localized name */

.vehicle-color-option {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 0;
    max-width: 100%;
}

.vehicle-color-option__label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.vehicle-color-swatch {
    --vehicle-color: #9e9e9e;
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    border-radius: 2px;
    background: var(--vehicle-color);
    border: 1px solid rgba(15, 23, 42, 0.28);
    box-sizing: border-box;
}

.vehicle-color-swatch--light {
    border-color: rgba(15, 23, 42, 0.42);
}

.vehicle-color-swatch--unknown {
    background: #bdbdbd;
    border-color: rgba(15, 23, 42, 0.28);
    background-image: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0.35) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, 0.35) 50%,
        rgba(255, 255, 255, 0.35) 75%,
        transparent 75%,
        transparent
    );
    background-size: 6px 6px;
}

.vehicle-color-select2-dropdown .select2-results__option {
    padding-top: 0.4rem;
    padding-bottom: 0.4rem;
}

.vehicle-color-select2-selection.select2-selection--single {
    display: flex;
    align-items: center;
    min-width: 0;
    max-width: 100%;
    min-height: calc(1.5em + 0.75rem + 2px);
}

.vehicle-color-select2-selection .select2-selection__rendered {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    padding-left: 0.65rem;
}

.vehicle-color-select2-selection .select2-selection__arrow {
    flex-shrink: 0;
}

/* Body type: searchable Select2 (fixed enum list) */
.vehicle-bodytype-select2-selection.select2-selection--single {
    display: flex;
    align-items: center;
    min-width: 0;
    max-width: 100%;
    min-height: calc(1.5em + 0.75rem + 2px);
}

.vehicle-bodytype-select2-selection .select2-selection__rendered {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    padding-left: 0.65rem;
}

.vehicle-bodytype-select2-selection .select2-selection__arrow {
    flex-shrink: 0;
}
