/* ===== Chosen — проектные стили (liquid-glass) ===== */

/* --- Контейнер .chosen-choices (поле с баджами) --- */
.chosen-container-multi .chosen-choices {
    border: 1px solid #e9ecef !important;
    border-radius: 8px !important;
    background-color: #fff !important;
    background-image: none !important;
    padding: 4px 6px !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
    min-height: 38px !important;
}

/* Фокус */
.chosen-container-multi.chosen-container-active .chosen-choices {
    border-color: #667eea !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15) !important;
    outline: none !important;
}

/* --- Баджи выбранных элементов --- */
.chosen-container-multi .chosen-choices li.search-choice {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: #fff !important;
    border: 0 !important;
    border-radius: 6px !important;
    box-shadow: 0 2px 4px rgba(102, 126, 234, 0.3) !important;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    padding: 4px 20px 4px 8px !important;
    margin: 2px 4px 2px 0 !important;
    line-height: 1.4 !important;
}

.chosen-container-multi .chosen-choices li.search-choice:hover {
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.4) !important;
    transform: translateY(-1px);
}

/* Кнопка удаления баджа */
.chosen-container-multi .chosen-choices li.search-choice .search-choice-close {
    top: 50% !important;
    transform: translateY(-50%);
    right: 4px !important;
    filter: brightness(0) invert(1);
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.chosen-container-multi .chosen-choices li.search-choice .search-choice-close:hover {
    opacity: 1;
}

/* --- Поле ввода --- */
.chosen-container-multi .chosen-choices li.search-field input[type="text"] {
    color: #495057 !important;
    font-size: 0.875rem !important;
    margin: 0 !important;
    padding: 2px 0 !important;
    height: auto !important;
}

/* --- Выпадающий список .chosen-drop --- */
.chosen-container .chosen-drop {
    border: 1px solid #e9ecef !important;
    border-radius: 0 0 8px 8px !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1) !important;
    background: #fff !important;
    margin-top: -1px !important;
}

.chosen-container.chosen-container-active .chosen-choices {
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

/* --- Элементы результатов --- */
.chosen-container .chosen-results li {
    padding: 8px 12px !important;
    font-size: 0.875rem !important;
    color: #212529 !important;
    transition: background-color 0.15s ease !important;
    border-radius: 0 !important;
}

.chosen-container .chosen-results li.highlighted {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: #fff !important;
}

.chosen-container .chosen-results li.result-selected {
    background-color: #f0f0ff !important;
    color: #667eea !important;
    font-weight: 500 !important;
}

.chosen-container .chosen-results li.active-result:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%) !important;
    color: #667eea !important;
}

/* Последний элемент — скругление снизу */
.chosen-container .chosen-results li:last-child {
    border-radius: 0 0 8px 8px !important;
}

/* --- Single select --- */
.chosen-container-single .chosen-single {
    border: 1px solid #e9ecef !important;
    border-radius: 8px !important;
    background: #fff !important;
    background-image: none !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
    padding: 6px 12px !important;
    height: auto !important;
    line-height: 1.5 !important;
    color: #212529 !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.chosen-container-single.chosen-container-active .chosen-single {
    border-color: #667eea !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15) !important;
}

.chosen-container-single.chosen-container-active.chosen-with-drop .chosen-single {
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

/* ===== Тема dle_theme_dark ===== */
.dle_theme_dark .chosen-container-multi .chosen-choices {
    background-color: #353f53 !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
}

.dle_theme_dark .chosen-container-multi.chosen-container-active .chosen-choices {
    border-color: #64b5f6 !important;
    box-shadow: 0 0 0 3px rgba(100, 181, 246, 0.2) !important;
}

.dle_theme_dark .chosen-container .chosen-drop {
    background: #2a3345 !important;
    border-color: rgba(255, 255, 255, 0.15) !important;
}

.dle_theme_dark .chosen-container .chosen-results li {
    color: #e0e0e0 !important;
}

.dle_theme_dark .chosen-container .chosen-results li.result-selected {
    background-color: rgba(100, 181, 246, 0.15) !important;
    color: #64b5f6 !important;
}

.dle_theme_dark .chosen-container-single .chosen-single {
    background: #353f53 !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #e0e0e0 !important;
}

.dle_theme_dark .chosen-container-single.chosen-container-active .chosen-single {
    border-color: #64b5f6 !important;
    box-shadow: 0 0 0 3px rgba(100, 181, 246, 0.2) !important;
}

/* ===== Тема dle_theme_j ===== */
.dle_theme_j .chosen-container-multi .chosen-choices li.search-choice {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

.dle_theme_j .chosen-container-multi .chosen-choices {
    border-color: #e9ecef !important;
}

.dle_theme_j .chosen-container-multi.chosen-container-active .chosen-choices {
    border-color: #667eea !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15) !important;
}
