/* Усиленные переопределения Bootstrap для компактных радиокнопок в таблице прав */
table.content-table.rights-table td.rights-radio-cell .form-check,
table.content-table.rights-table td.rights-radio-cell .form-check-inline {
    margin: 0 !important;
    padding: 0 !important;
    min-height: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
}

/* Контейнер RadioItems (родитель form-check элементов) */
table.content-table.rights-table td.rights-radio-cell .rights-radio-items {
    gap: 2px !important;
}

table.content-table.rights-table td.rights-radio-cell .form-check + .form-check {
    margin-left: 2px !important;
}

table.content-table.rights-table td.rights-radio-cell .form-check-input {
    margin: 0 !important;
}

table.content-table.rights-table td.rights-radio-cell .form-check-label {
    margin: 0 !important;
    padding: 0 !important;
}

/* Стили для системы управления контентом */


/* Специфичные стили для Bootstrap компонентов */
.card,
.card-body,
/* .btn, */
/* .btn-group, */
/* .btn-group > .btn, */
.form-control,
.form-select,
.dropdown-menu,
.modal-content,
.modal-header,
.modal-body,
.modal-footer,
.alert,
.badge,
/* .nav-tabs, */
/* .nav-tabs .nav-link, */
.tab-content,
.table,
.table th,
.table td,
.list-group,
.list-group-item {
    border-radius: 0 !important;
}

/* Определения шрифтов */
@font-face {
    font-family: 'IBM Plex Sans';
    src: url('Ibmplexsans.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'IBM Plex Sans';
    src: url('Ibmplexsans.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: 'IBM Plex Sans';
    src: url('Ibmplexsans.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
}

/* Унифицированные стили для фильтров */
.content-filter-dropdown {
    font-size: var(--font-size-body-lg) !important;
    height: 38px !important;
    min-height: 38px !important;
}

.content-filter-input {
    font-size: var(--font-size-body-lg) !important;
    height: 38px !important;
}

/* Компактные стили для карточек */
.content-card-compact .card-body {
    /* padding: 0.5rem !important; */
    margin: 2px !important;
}

.content-card-compact .card-title {
    /* margin-bottom: 0.5rem !important; Отладка1 */
}

.content-card-compact .card-text {
    /* margin-bottom: 0.25rem !important; Отладка1 */
}

/* Стили для статистики */
.content-stats-card {
    text-align: center;
    padding: 0.5rem !important;
}

.content-stats-number {
    font-size: 1.25rem;
    font-weight: bold;
    /* margin-bottom: 0.25rem !important; Отладка1 */
}

.content-stats-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    /* margin-bottom: 0 !important; Отладка1 */
}

/* Стили для таблиц */
.content-table-compact {
    font-size: 0.875rem;
}

.content-table-compact th,
.content-table-compact td {
    padding: 0.5rem !important;
    vertical-align: middle;
}

/* Убираем отступы у контейнеров таблиц */
#courses-table-container,
#stages-table-container,
#tasks-table-container {
    padding: 0 !important;
    margin: 0 !important;
}

/* Убираем отступы у table-responsive */
.table-responsive {
    padding: 0 !important;
    margin: 0 !important;
}

/* Убираем отступы у карточек с таблицами */
.content-card-compact .card-body {
    /* padding: 0 !important; */
    padding: 1px !important;
}

/* Убираем отступы у всех карточек в системе управления контентом */
.card {
    margin-bottom: 0 !important;
}

.card-body {
    /* padding: 0.5rem !important; */
    padding: 1px !important;
}

/* Специально для карточек с таблицами */
.card .table-responsive {
    padding: 0 !important;
    margin: 0 !important;
}

/* Убираем отступы у строк и колонок Bootstrap в контейнерах таблиц */
#courses-table-container .row,
#stages-table-container .row,
#tasks-table-container .row {
    margin: 0 !important;
}

#courses-table-container .col,
#stages-table-container .col,
#tasks-table-container .col {
    padding: 0 !important;
}

/* Улучшенные стили для таблиц контента */
.content-table {
    font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.9rem;
    font-weight: 400;
    line-height: 1.3;
    border-collapse: collapse;
    width: 100%;
    background-color: var(--background-color);
    border: 1px solid var(--border-color);
    /* border-radius: 8px; */
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    margin: 0;
    padding: 0;
}

/* Убираем стандартные отступы Bootstrap таблиц */
.table {
    margin-bottom: 0 !important;
}

.content-table thead {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--border-color) 100%);
    border-bottom: 2px solid var(--border-color);
}

.content-table th {
    font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.5rem 0.5rem !important;
    vertical-align: middle;
    border: none;
    white-space: nowrap;
    min-width: 80px;
}

.content-table td {
    font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--text-primary);
    padding: 0.1rem 0.1rem !important;
    vertical-align: middle;
    border-top: 1px solid var(--border-color);
    border-bottom: none;
    line-height: 1.3;
    word-wrap: break-word;
}

/* Стили для длинного текста в ячейках (кроме названия и описания) */
.content-table td .text-truncate:not(:first-child):not(:nth-child(2)) {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
}

/* Стили для первой колонки (название) */
.content-table td:first-child {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 0.9rem;
    min-width: 200px;
    max-width: 300px;
    word-wrap: break-word;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
}

/* Стили для второй колонки (описание) */
.content-table td:nth-child(2) {
    min-width: 250px;
    max-width: 400px;
    word-wrap: break-word;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
}

/* Минимальная ширина для колонок с фиксированным контентом */
.content-table th:nth-child(3):not([style*="width"]), /* Сложность */
.content-table td:nth-child(3):not([style*="width"]) {
    width: 120px;
    min-width: 120px;
    max-width: 120px;
    white-space: nowrap;
    text-align: center;
}

.content-table th:nth-child(4), /* Статус */
.content-table td:nth-child(4) {
    width: 100px;
    min-width: 100px;
    max-width: 100px;
    white-space: nowrap;
    text-align: center;
}

.content-table th:nth-child(5), /* Создан */
.content-table td:nth-child(5) {
    width: 90px;
    min-width: 90px;
    max-width: 90px;
    white-space: nowrap;
    text-align: center;
}

.content-table th:nth-child(6), /* Изменен */
.content-table td:nth-child(6) {
    width: 90px;
    min-width: 90px;
    max-width: 90px;
    white-space: nowrap;
    text-align: center;
}

.content-table th:nth-child(7), /* Действия */
.content-table td:nth-child(7) {
    width: 80px;
    min-width: 80px;
    max-width: 80px;
    white-space: nowrap;
    text-align: center;
}

/* Стили для таблицы этапов (6 колонок) */
.content-table.stages-table th:nth-child(4), /* Порядок */
.content-table.stages-table td:nth-child(4) {
    width: 80px;
    min-width: 80px;
    max-width: 80px;
    white-space: nowrap;
    text-align: center;
}

.content-table.stages-table th:nth-child(5), /* Статус */
.content-table.stages-table td:nth-child(5) {
    width: 100px;
    min-width: 100px;
    max-width: 100px;
    white-space: nowrap;
    text-align: center;
}

.content-table.stages-table th:nth-child(6), /* Действия */
.content-table.stages-table td:nth-child(6) {
    width: 80px;
    min-width: 80px;
    max-width: 80px;
    white-space: nowrap;
    text-align: center;
}

/* Стили для таблицы задач (7 колонок) */
.content-table.tasks-table th:nth-child(4), /* Сложность */
.content-table.tasks-table td:nth-child(4) {
    width: 100px;
    min-width: 100px;
    max-width: 100px;
    white-space: nowrap;
    text-align: center;
}

.content-table.tasks-table th:nth-child(5), /* Этап */
.content-table.tasks-table td:nth-child(5) {
    width: 100px;
    min-width: 100px;
    max-width: 100px;
    white-space: nowrap;
    text-align: center;
}

.content-table.tasks-table th:nth-child(6), /* Статус */
.content-table.tasks-table td:nth-child(6) {
    width: 100px;
    min-width: 100px;
    max-width: 100px;
    white-space: nowrap;
    text-align: center;
}

.content-table.tasks-table th:nth-child(7), /* Действия */
.content-table.tasks-table td:nth-child(7) {
    width: 80px;
    min-width: 80px;
    max-width: 80px;
    white-space: nowrap;
    text-align: center;
}

.content-table tbody tr:hover {
    background-color: var(--accent-color);
    transition: background-color 0.15s ease-in-out;
}

.content-table tbody tr:nth-child(even) {
    background-color: var(--background-color);
}

.content-table tbody tr:nth-child(even):hover {
    background-color: var(--border-color);
}

/* Стили для заголовков с сортировкой */
.content-table th .d-flex {
    min-width: 0;
    align-items: center;
}

.content-table th span {
    font-weight: 600;
    color: var(--text-secondary);
}

/* Стили для кнопок сортировки */
.content-table .sort-btn {
    font-size: 0.75rem !important;
    color: var(--text-secondary);
    transition: color 0.15s ease-in-out;
}

.content-table .sort-btn:hover {
    color: var(--text-primary);
}

.content-table .sort-btn i {
    font-size: 0.75rem !important;
    line-height: 1 !important;
}

/* Компактность таблиц по уровням */
.content-table-low table thead th,
.content-table-low table tbody td {
    padding: 0.5rem 0.5rem !important;
}

.content-table-medium table thead th,
.content-table-medium table tbody td {
    padding: 0.375rem 0.5rem !important;
    font-size: 0.9rem !important;
}

.content-table-high table thead th,
.content-table-high table tbody td {
    padding: 0.25rem 0.375rem !important;
    font-size: 0.85rem !important;
}

/* AG-Grid компактность - устанавливаем минимальную высоту строки */
.content-table-compact .ag-theme-alpine {
    --ag-row-height: 24px;
    --ag-header-height: 28px;
}

/* Стили для компактных чекбоксов в AG-Grid */
.ag-grid-checkbox-cell {
    padding: 0 !important;
    padding-left: 12px !important;
    margin: 0 !important;
    text-align: center !important;
    vertical-align: middle !important;
}

.ag-grid-checkbox-cell .ag-checkbox-input-wrapper {
    margin: 0 !important;
    padding: 0 !important;
    padding-left: 12px !important;
}

.ag-grid-checkbox-cell .ag-checkbox-input {
    margin: 0 !important;
    padding: 0 !important;
    padding-left: 12px !important;
}

/* Стили для заголовка колонки с чекбоксами в AG-Grid */
.ag-header-cell[col-id="ag-grid-checkbox"] {
    padding: 0 !important;
    padding-left: 12px !important;
    margin: 0 !important;
    text-align: center !important;
    vertical-align: middle !important;
}

.ag-header-cell[col-id="ag-grid-checkbox"] .ag-header-cell-comp-wrapper {
    padding: 0 !important;
    padding-left: 12px !important;
    margin: 0 !important;
    text-align: center !important;
    vertical-align: middle !important;
}

/* Пейджер таблицы и кнопки */
.content-table-low .datatable-pager { margin-bottom: 8px !important; }
.content-table-medium .datatable-pager { margin-bottom: 6px !important; }
.content-table-high .datatable-pager { margin-bottom: 4px !important; }

.content-table-medium .datatable-pager .btn,
.content-table-high .datatable-pager .btn {
    padding: 0.25rem 0.5rem !important;
}

.content-table-high .datatable-pager .btn {
    padding: 0.125rem 0.25rem !important;
    font-size: 0.8rem !important;
}

/* Стили для кнопок действий */
.content-action-btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Улучшенные стили для кнопок действий в таблицах */
.action-btn {
    font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
    border: 1px solid transparent;
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    /* border-radius: 6px; */
    padding: 0;
}

.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Стили для бейджей в таблицах */
.content-table .badge {
    font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.7rem;
    font-weight: 500;
    padding: 0.3rem 0.6rem;
    /* border-radius: 4px; */
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Специальные стили для бейджей сложности */
.content-table .badge.bg-primary {
    background-color: var(--accent-color) !important;
    color: var(--primary-color) !important;
    border: 1px solid var(--border-color);
}

.content-table .badge.bg-warning {
    background-color: var(--accent-color) !important;
    color: var(--warning-color) !important;
    border: 1px solid var(--border-color);
}

.content-table .badge.bg-danger {
    background-color: var(--accent-color) !important;
    color: var(--error-color) !important;
    border: 1px solid var(--border-color);
}

/* Специальные стили для бейджей статуса */
.content-table .badge.bg-secondary {
    background-color: var(--accent-color) !important;
    color: var(--text-secondary) !important;
    border: 1px solid var(--border-color);
}

.content-table .badge.bg-success {
    background-color: var(--accent-color) !important;
    color: var(--success-color) !important;
    border: 1px solid var(--border-color);
}

.content-table .badge.bg-dark {
    background-color: var(--text-primary) !important;
    color: var(--background-color) !important;
    border: 1px solid var(--text-primary);
}

.edit-btn {
    color: var(--secondary-color);
    border-color: var(--secondary-color);
    background-color: transparent;
    font-size: 0.75rem;
    margin-right: 4px;
}

.edit-btn:hover {
    color: var(--background-color);
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.delete-btn {
    color: var(--error-color);
    border-color: var(--error-color);
    background-color: transparent;
    font-size: 0.75rem;
}

.delete-btn:hover {
    color: var(--background-color);
    background-color: var(--error-color);
    border-color: var(--error-color);
}

/* Стили для иконок в кнопках */
.action-btn i {
    font-size: 16px;
    line-height: 1;
}

/* Специальные стили для Bootstrap Icons */
.action-btn .bi {
    font-size: 16px;
    line-height: 1;
}

/* Анимация при наведении */
.action-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Стили для кнопок в заголовке */
.action-btn-header {
    transition: all 0.2s ease-in-out;
    /* border-radius: 6px; */
    padding: 8px 16px;
    font-weight: 500;
}

.action-btn-header:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.action-btn-header:active {
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

/* Стили для компактных кнопок панели управления */
.action-btn-compact {
    transition: all 0.2s ease-in-out;
    /* border-radius: 6px; */
    padding: 8px 12px;
    min-width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 2px;
}

.action-btn-compact:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.action-btn-compact:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.action-btn-compact i {
    font-size: 16px;
    line-height: 1;
}

/* Стили для разделителя в кнопочной группе */
.vr {
    width: 1px;
    height: 24px;
    background-color: var(--border-color);
    margin: 0 8px;
}

/* Стили для динамических фильтров */
.dynamic-filter-row {
    animation: slideDown 0.3s ease-out;
}

/* Стили для строки поиска - полная ширина */
.dynamic-filter-row .content-filter-input {
    width: 100% !important;
    min-width: 200px;
}

/* Адаптивные стили для dropdown фильтров - расширяются по содержимому */
.dynamic-filter-row .content-filter-dropdown {
    min-width: 200px;
    max-width: 400px;
    width: auto !important;
}

/* Стили для Dash dropdown элементов */
.dynamic-filter-row .Select {
    min-width: 200px;
    max-width: 400px;
    width: auto !important;
}

.dynamic-filter-row .Select-control {
    min-width: 200px;
    max-width: 400px;
    width: auto !important;
}

.dynamic-filter-row .Select-menu-outer {
    min-width: 200px;
    max-width: 400px;
    width: auto !important;
}

/* Стили для контейнера с иконкой */
.dynamic-filter-row .d-flex.align-items-center {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Для строки поиска - полная ширина */
.dynamic-filter-row .d-flex.align-items-center .content-filter-input {
    flex: 1;
    width: 100% !important;
}

/* Для dropdown фильтров - адаптивная ширина */
.dynamic-filter-row .d-flex.align-items-center .content-filter-dropdown {
    flex: 0 1 auto;
    min-width: 200px;
    max-width: 400px;
}

/* Стили для кнопок сортировки в заголовках таблицы */
.sort-btn {
    min-width: 20px !important;
    width: 20px !important;
    height: 20px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    background: transparent !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.sort-btn:hover {
    background-color: rgba(0, 0, 0, 0.05) !important;
    /* border-radius: 3px !important; */
}

.sort-btn i {
    font-size: var(--font-size-secondary) !important;
    line-height: 1 !important;
}

/* Стили для заголовков таблицы с сортировкой */
.table th {
    white-space: nowrap;
    min-width: 80px;
}

.table th .d-flex {
    min-width: 0;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Стили для компактной панели управления */
.control-panel-compact {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--border-color) 100%);
    border: 1px solid var(--border-color);
    /* border-radius: 8px; */
}

.control-panel-compact .card-body {
    /* padding: 1rem; */
    padding: 1px !important;
}

/* Специальные стили для компактной панели с кнопками */
.control-panel-buttons .card-body {
    /* padding: 0.5rem !important; */
    padding: 1px !important;
}

.control-panel-buttons .row:first-child {
    margin-bottom: 2px !important;
    margin-top: 2px !important;
}

.control-panel-buttons .row:last-child {
    margin-top: 0.25rem !important;
}

/* Стили для подписей фильтров */
.content-filter-label {
    font-size: 0.875rem;
    /* margin-bottom: 0 !important; Отладка1 */
    text-align: right;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    height: 38px;
}

/* Стили для модальных окон */
.content-modal-compact .modal-body {
    padding: 1rem !important;
}

.content-modal-compact .modal-header {
    padding: 0.75rem 1rem !important;
}

.content-modal-compact .modal-footer {
    padding: 0.75rem 1rem !important;
}

/* Стили для форм */
.content-form-compact .form-label {
    font-size: 0.875rem;
    /* margin-bottom: 0.25rem !important; Отладка1 */
}

.content-form-compact .form-control {
    font-size: var(--font-size-body-lg);
    height: 38px;
}

.content-form-compact .form-select {
    font-size: var(--font-size-body-lg);
    height: 38px;
}

/* Система компактности форм */
.content-form-low .card-body {
    padding: 0.5rem !important;
}

/* Компактные таблицы - оставляем как есть, только убираем лишние отступы */

/* Простые стили для фиксированных контейнеров таблиц */
.content-table-fixed {
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
}

/* Content page: tables grow with content, one common page scroll */
.content-page .content-table-fixed {
    height: auto !important;
    min-height: 0 !important;
}

.content-page .content-table-fixed .card {
    height: auto !important;
}

.content-page .content-table-fixed .card-body,
.content-page .content-table-fixed .collapse {
    overflow: visible !important;
    flex: none !important;
}

.content-page .content-table-fixed .ag-theme-alpine {
    height: auto !important;
    min-height: 120px !important;
}

.content-table-fixed .card {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
}

.content-table-fixed .card-header {
    flex: 0 0 auto !important;
}

.content-table-fixed .card-body {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

.content-table-fixed .collapse {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

.content-table-fixed .d-flex {
    flex: 1 !important;
    overflow: hidden !important;
    height: 100% !important;
}

.content-table-fixed .flex-grow-1 {
    flex: 1 !important;
    overflow: hidden !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
}

/* AG-Grid в фиксированных контейнерах */
.content-table-fixed .ag-theme-alpine {
    width: 100% !important;
    height: 100% !important;
    min-height: 200px !important;
}

.content-table-fixed .ag-theme-alpine .ag-body-viewport {
    overflow-y: auto !important;
    height: 100% !important;
}

/* Стили для сплиттеров */
#splitter-1, #splitter-2 {
    transition: background-color 0.2s ease;
    user-select: none;
}

#splitter-1:hover, #splitter-2:hover {
    background-color: #bbb !important;
}

#splitter-1:active, #splitter-2:active {
    background-color: #999 !important;
}

/* Стили для тестовой страницы сплиттеров */
#test-splitter:hover {
    background-color: #555 !important;
}

#test-splitter:active {
    background-color: #333 !important;
}

/* Современные CSS свойства */
* {
    text-size-adjust: 100%;
}

/* Глобальные стили для сплиттеров */
.splitter-dragging {
    user-select: none !important;
    cursor: ns-resize !important;
}

.splitter-dragging * {
    pointer-events: none !important;
}

.splitter-dragging #test-splitter {
    pointer-events: auto !important;
}

/* Компактные CardBody для FormBuilderAPI */
.content-form-compact .card-body {
    padding: 0.25rem !important;
    /* Убираем фиксированную высоту - пусть размер зависит от содержимого */
}

.content-form-medium .card-body {
    padding: 0.125rem !important;
    /* Убираем фиксированную высоту - пусть размер зависит от содержимого */
}

/* Убираем лишние отступы в CardHeader */
.content-form-compact .card-header {
    padding: 0.25rem 0.5rem !important;
}

.content-form-medium .card-header {
    padding: 0.125rem 0.25rem !important;
}

/* Убираем лишние отступы в Collapse */
.content-form-compact .collapse {
    margin-bottom: 0.25rem !important;
}

.content-form-medium .collapse {
    margin-bottom: 0.125rem !important;
}

/* Убираем лишние отступы в div'ах таблиц */
.content-form-compact .d-flex {
    margin-bottom: 0.25rem !important;
}

.content-form-medium .d-flex {
    margin-bottom: 0.125rem !important;
}

.content-form-low .form-label,
.content-form-low label.form-label {
    font-size: 0.875rem !important;
    margin-bottom: 0.25rem !important;
}

.content-form-low .form-control,
.content-form-low .form-select {
    font-size: var(--font-size-body-lg) !important;
    height: 32px !important;
    margin-bottom: 0.125rem !important;
}

.content-form-low .btn {
    margin-left: 0.125rem !important;
}

/* Средняя компактность */
.content-form-medium .card-body {
    padding: 0.25rem !important;
}

.content-form-medium .form-label,
.content-form-medium label.form-label {
    font-size: 0.8rem !important;
    margin-bottom: 0.125rem !important;
}

.content-form-medium .form-control,
.content-form-medium .form-select {
    font-size: var(--font-size-body) !important;
    height: 28px !important;
    margin-bottom: 0.0625rem !important;
}

.content-form-medium .btn {
    margin-left: 0.0625rem !important;
    padding: 0.25rem 0.5rem !important;
}

.content-form-medium .row {
    margin-bottom: 0.0625rem !important;
}

/* Высокая компактность */
.content-form-high .card-body {
    padding: 0.125rem !important;
}

.content-form-high .form-label,
.content-form-high label.form-label {
    font-size: 0.75rem !important;
    margin-bottom: 0.0625rem !important;
}

.content-form-high .form-control,
.content-form-high .form-select {
    font-size: var(--font-size-secondary) !important;
    height: 24px !important;
    margin-bottom: 0.03125rem !important;
    padding: 0.125rem 0.25rem !important;
}

.content-form-high .btn {
    margin-left: 0.03125rem !important;
    padding: 0.125rem 0.25rem !important;
    font-size: 0.75rem !important;
}

.content-form-high .row {
    margin-bottom: 0.03125rem !important;
}

.content-form-high .card-header {
    padding: 0.25rem 0.5rem !important;
    font-size: 0.875rem !important;
}

.content-form-high .card-footer {
    padding: 0.25rem 0.5rem !important;
}

/* Стили для inline labels */
.content-form-medium .form-label[style*="textAlign: right"],
.content-form-high .form-label[style*="textAlign: right"] {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary);
}

/* Компактные textarea */
.content-form-medium .form-control[rows="2"],
.content-form-high .form-control[rows="2"] {
    min-height: 60px;
    resize: vertical;
}

/* Компактные радиокнопки */
.content-form-medium .dash-radioitems,
.content-form-high .dash-radioitems {
    gap: 4px !important;
}

.content-form-high .dash-radioitems {
    gap: 2px !important;
}

/* Компактные чекбоксы */
.content-form-medium .dash-checklist,
.content-form-high .dash-checklist {
    gap: 8px !important;
}

.content-form-high .dash-checklist {
    gap: 4px !important;
}

/* Flexbox стили для форм */
.content-form-low div[style*="display: flex"] {
    gap: 8px !important;
}

.content-form-medium div[style*="display: flex"] {
    gap: 4px !important;
}

.content-form-high div[style*="display: flex"] {
    gap: 2px !important;
}

/* Стили для групп полей */
.content-form-low div[style*="flexDirection: row"] {
    margin-bottom: 8px !important;
}

.content-form-medium div[style*="flexDirection: row"] {
    margin-bottom: 4px !important;
}

.content-form-high div[style*="flexDirection: row"] {
    margin-bottom: 2px !important;
}

/* Стили для секций форм */
.content-form-low div[style*="flexDirection: column"] {
    gap: 8px !important;
}

.content-form-medium div[style*="flexDirection: column"] {
    gap: 4px !important;
}

.content-form-high div[style*="flexDirection: column"] {
    gap: 2px !important;
}

/* Исправление отступов слева в компактных формах */
.content-form-medium div[style*="flexDirection: row"],
.content-form-high div[style*="flexDirection: row"] {
    margin-left: 0 !important;
    padding-left: 0 !important;
}

/* Исправление отступов у inline полей */
.content-form-medium div[style*="flex: 0 0 auto"],
.content-form-high div[style*="flex: 0 0 auto"] {
    margin-left: 0 !important;
    padding-left: 0 !important;
}

/* Исправление отступов у обычных полей */
.content-form-medium div[style*="flex: 1 1 auto"],
.content-form-high div[style*="flex: 1 1 auto"] {
    margin-left: 0 !important;
    padding-left: 0 !important;
}

/* Предотвращение сжатия inline labels */
.content-form-medium label[style*="textAlign: right"],
.content-form-high label[style*="textAlign: right"] {
    flex-shrink: 0 !important;
    min-width: 100px !important;
}

/* Стили для алертов */
.content-alert-compact {
    padding: 0.5rem 0.75rem !important;
    font-size: 0.875rem;
}

/* Стили для бейджей */
.content-badge-compact {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
}

/* Стили для заголовков */
.content-page-title {
    font-size: var(--font-size-page-title);
    /* margin-bottom: 0.75rem !important; Отладка1 */
}

.content-section-title {
    font-size: var(--font-size-section-title);
    /* margin-bottom: 0.5rem !important; Отладка1 */
}

.fb-section-title {
    font-size: var(--font-size-section-title);
    font-weight: 600;
    color: var(--text-primary);
}

/* Стили для навигации */
.content-nav-compact .nav-link {
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
}

/* Стили для пагинации */
.content-pagination-compact .page-link {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Стили для тултипов */
.content-tooltip {
    font-size: 0.75rem;
}

/* Стили для загрузчиков */
.content-loader {
    text-align: center;
    padding: 2rem;
}

/* Стили для пустых состояний */
.content-empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
}

/* Адаптивные стили */
@media (max-width: 768px) {
    .content-filter-label {
        text-align: left;
        justify-content: flex-start;
        /* margin-bottom: 0.25rem !important; Отладка1 */
    }
    
    .content-stats-card {
        /* margin-bottom: 1rem; Отладка1 */
    }
}

/* Стили для радиокнопок в таблице прав */
.rights-radio-group {
    display: flex;
    align-items: center;
}

.rights-radio-items {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 2px;
}

/* Стили для dbc.RadioItems с inline=True */
.rights-radio-items .form-check {
    display: inline-flex !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    min-height: 0 !important;
}

/* Переопределяем margin-right для form-check-inline */
.rights-radio-items .form-check-inline {
    margin-right: 0 !important;
}

.rights-radio-items .form-check-input {
    margin: 0 !important;
    padding: 0 !important;
}

.rights-radio-items .form-check-label {
    margin: 0 !important;
    padding: 0 !important;
}

.rights-radio-label {
    margin: 0;
    padding: 0;
}