/* Select2 Bootstrap 5 Theme Customization */
.select2-container--bootstrap-5 .select2-selection {
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  min-height: calc(1.5em + 0.75rem + 2px);
}

.select2-container--bootstrap-5 .select2-selection--single {
  padding: 0.375rem 0.75rem;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
  padding-left: 0;
  line-height: 1.5;
  color: #212529;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow {
  height: calc(1.5em + 0.75rem);
  right: 0.75rem;
}

.select2-container--bootstrap-5.select2-container--focus .select2-selection,
.select2-container--bootstrap-5.select2-container--open .select2-selection {
  border-color: #86b7fe;
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.select2-container--bootstrap-5 .select2-dropdown {
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
}

.select2-container--bootstrap-5 .select2-search--dropdown .select2-search__field {
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  padding: 0.375rem 0.75rem;
}

.select2-container--bootstrap-5 .select2-results__option {
  padding: 0.375rem 0.75rem;
}

.select2-container--bootstrap-5 .select2-results__option--highlighted[aria-selected] {
  background-color: #0d6efd;
  color: #fff;
}

.select2-container--bootstrap-5 .select2-results__option[aria-selected=true] {
  background-color: #e9ecef;
  color: #212529;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__placeholder {
  color: #6c757d;
}

/* Отступы для иерархических списков */
.select2-results__option[data-level] {
  padding-left: calc(0.75rem + var(--level, 0) * 1.5rem);
}
