/* =============================================
   Select2 — Bootstrap-compatible styling
   ============================================= */

/* Single select */
.select2-container .select2-selection--single {
    height: calc(2.25rem + 2px);
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 0.88rem;
    padding: 0;
    display: flex;
    align-items: center;
}
.select2-container .select2-selection--single .select2-selection__rendered {
    line-height: 1;
    padding-left: 0.75rem;
    color: #495057;
}
.select2-container .select2-selection--single .select2-selection__arrow {
    height: calc(2.25rem + 2px);
}
.select2-container--focus .select2-selection--single,
.select2-container--open .select2-selection--single {
    border-color: #319F1C;
    box-shadow: 0 0 0 0.18rem rgba(49, 159, 28, 0.18);
    outline: none;
}

/* Multi select */
.select2-container .select2-selection--multiple {
    min-height: calc(2.25rem + 2px);
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 0.88rem;
    padding: 2px 4px;
    background-color: #fff;
}
.select2-container--focus .select2-selection--multiple,
.select2-container--open .select2-selection--multiple {
    border-color: #319F1C;
    box-shadow: 0 0 0 0.18rem rgba(49, 159, 28, 0.18);
    outline: none;
}
.select2-container .select2-selection--multiple .select2-selection__choice {
    font-size: 0.82rem;
    background-color: #e8f5e9;
    border: 1px solid #c8e6c9;
    border-radius: 4px;
    color: #2c3e50;
    margin-top: 2px;
    margin-left: 2px;
    padding: 1px 4px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    max-width: 100%;
}
.select2-container .select2-selection--multiple .select2-selection__choice__remove {
    position: static;
    left: auto;
    top: auto;
    float: none;
    flex-shrink: 0;
    color: #999;
    font-size: 1em;
    font-weight: 700;
    border: none;
    background: none;
    margin: 0;
    padding: 0;
    width: 14px;
    height: 14px;
    line-height: 14px;
    text-align: center;
    order: 1;
}
.select2-container .select2-selection--multiple .select2-selection__choice__remove:hover {
    color: #e74c3c;
    background: none;
}
.select2-container .select2-selection--multiple .select2-selection__choice__display {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.select2-container .select2-selection--multiple .select2-search__field {
    font-size: 0.88rem;
    font-family: inherit;
    color: #495057;
    margin-top: 0;
}

/* Dropdown panel */
.select2-dropdown {
    border: 1px solid #ced4da;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-top: 2px;
}
.select2-results__option {
    font-size: 0.85rem;
    padding: 6px 12px;
}
.select2-results__option--highlighted {
    background-color: #e8f5e9 !important;
    color: #2c3e50 !important;
}
.select2-results__option[aria-selected="true"] {
    background-color: #319F1C !important;
    color: white !important;
}
.select2-results__group {
    font-size: 0.75rem;
    font-weight: 700;
    color: #319F1C;
    padding: 8px 12px 4px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.select2-search--dropdown .select2-search__field {
    border: 1px solid #ced4da;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 0.85rem;
}
.select2-search--dropdown .select2-search__field:focus {
    border-color: #319F1C;
    box-shadow: 0 0 0 0.18rem rgba(49, 159, 28, 0.18);
    outline: none;
}
