/* Foglio di stile per la personalizzazione select2 a colori scuri */

/* stili generici casella principale select2 */
.select2-selection {
    background-color: #394c57 !important;
    border: 2px solid rgba(238, 238, 238, 0.1) !important;
}

/* bordo tendina select2 sopra o sotto */
.select2-container--open .select2-dropdown--above {
    border: 2px solid rgba(238, 238, 238, 0.1) !important;
    border-bottom: 1px !important;
}

.select2-container--open .select2-dropdown--below {
    border: 2px solid rgba(238, 238, 238, 0.1) !important;
    border-top: 1px !important;
}

/* elenco opzioni select2 */
li.select2-results__option {
    color: #fff;
}

li.select2-results__option:not(.select2-results__option--highlighted)[aria-selected="true"],
li.select2-results__option:not(.select2-results__option--highlighted)[aria-selected="true"] * {
    background-color: #bbb !important;
}

li.select2-results__option:not(.select2-results__option--highlighted)[aria-selected="true"] span {
    color: #253138 !important;
    background-color: #bbb !important;
}

/* select2 disabilitata */
.select2-container--disabled .select2-selection {
    background-color: #394c57 !important;
    border-color: #394c57 !important;
    cursor: not-allowed !important;
}

/* select2 con focus */
.select2-container--focus:not(.select2-container--disabled) .select2-selection--multiple,
.select2-container--open:not(.select2-container--disabled) .select2-dropdown--below,
.select2-container--open:not(.select2-container--disabled) .select2-dropdown--above {
    border-color: rgba(238, 238, 238, 0.3) !important;
    background-color: #435966 !important;
}

.select2-container--bootstrap .select2-selection--multiple .select2-selection__rendered,
.select2-container--bootstrap .select2-selection--single .select2-selection__rendered {
    color: #FFFFFF;
}

/* casella di ricerca nei dropdown */
.select2-container--bootstrap .select2-search--dropdown .select2-search__field {
    background-color: #394c57;
    border: 2px solid rgba(238, 238, 238, 0.1);
    color: #FFF;
}

/* bordo in caso di errore */
.has-error .select2-container--bootstrap .select2-selection,
.has-error .select2-container--bootstrap.select2-container--focus .select2-selection,
.has-error .select2-container--bootstrap.select2-container--open .select2-selection {
    border-color: #ff5b5b !important;
}

.select2-container--bootstrap.select2-container--open:not(.select2-container--disabled) .select2-selection {
    border-color: rgba(238, 238, 238, 0.3) !important;
    background-color: #435966 !important;
}

.select2-container--bootstrap.select2-container--focus:not(.select2-container--disabled) .select2-selection {
    border-color: rgba(238, 238, 238, 0.3) !important;
    background-color: #435966 !important;
}

.select2-results__option, .select2-results__options,
.select2-results__options * {
    background-color: #435966 !important;
}

.select2-results__option--highlighted  ,
.select2-results__option--highlighted *   {
    background-color: #188ae2 !important;
}

.select2-results__option--highlighted[aria-selected="true"]
, .select2-results__option--highlighted[aria-selected="true"] * {
    background-color: #ddd !important;
}

.select2-results__option--highlighted[aria-selected="true"] {
    color: #262626 !important;
}

.select2-container li.select2-results__message,
.select2-results__option.loading-results {
    color: #bbb !important;
}

.select2-selection__placeholder {
    color: #bbb !important;
}

span.custom-select2-aside {
    color: #bbb;
}

/* tags nei multiselect2 */
.select2-selection--multiple li.select2-selection__choice {
    background-color: #188ae2  !important;
    border-color: #188ae2  !important;
    color: #fff !important;
}

.select2-selection--multiple li.select2-selection__choice .select2-selection__choice__remove {
    color: #fff !important;
}

li.select2-results__option[aria-disabled="true"] {
    color: #aaa !important;
    cursor: not-allowed !important;
}
