/* Дизайн‑токены для цветов статусов */
:root {
    /* Фоны строк */
    --row-color-white-bg: #ffffff;
    --row-color-gray-bg: #f0f0f0;
    --row-color-green-bg: #d4edda;
    --row-color-yellow-bg: #fff3cd;
    --row-color-red-bg: #f8d7da;
    --row-color-blue-bg: #cce5ff;
    --row-color-orange-bg: #ffe5cc;
    --row-color-turquoise-bg: #b2ebf2;

    /* Цвета текста для бейджей статусов */
    --status-text-default: #000000;
    --status-text-gray: #333333;
    --status-text-green: #155724;
    --status-text-yellow: #856404;
    --status-text-red: #721c24;
    --status-text-blue: #004085;
    --status-text-orange: #854d0e;

    /* Цвета границы для мобильных карточек */
    --card-border-white: #ffffff;
    --card-border-gray: #808080;
    --card-border-green: #28a745;
    --card-border-yellow: #ffc107;
    --card-border-red: #dc3545;
    --card-border-blue: #007bff;
    --card-border-orange: #fd7e14;
    --card-border-turquoise: #0097a7;
}

/* Цвета для строк таблицы: и tr, и td, чтобы фон не перебивался Bootstrap и style.css */
.table tbody tr.row-white,
.table tbody tr.row-white td,
.table-hover tbody tr.row-white:hover,
.table-hover tbody tr.row-white:hover td,
.table-responsive tbody tr.row-white,
.table-responsive tbody tr.row-white td { background-color: #ffffff !important; }

.table tbody tr.row-gray,
.table tbody tr.row-gray td,
.table-hover tbody tr.row-gray:hover,
.table-hover tbody tr.row-gray:hover td,
.table-responsive tbody tr.row-gray,
.table-responsive tbody tr.row-gray td { background-color: #f0f0f0 !important; }

.table tbody tr.row-green,
.table tbody tr.row-green td,
.table-hover tbody tr.row-green:hover,
.table-hover tbody tr.row-green:hover td,
.table-responsive tbody tr.row-green,
.table-responsive tbody tr.row-green td { background-color: #d4edda !important; }

.table tbody tr.row-yellow,
.table tbody tr.row-yellow td,
.table-hover tbody tr.row-yellow:hover,
.table-hover tbody tr.row-yellow:hover td,
.table-responsive tbody tr.row-yellow,
.table-responsive tbody tr.row-yellow td { background-color: #fff3cd !important; }

.table tbody tr.row-red,
.table tbody tr.row-red td,
.table-hover tbody tr.row-red:hover,
.table-hover tbody tr.row-red:hover td,
.table-responsive tbody tr.row-red,
.table-responsive tbody tr.row-red td { background-color: #f8d7da !important; }

.table tbody tr.row-blue,
.table tbody tr.row-blue td,
.table-hover tbody tr.row-blue:hover,
.table-hover tbody tr.row-blue:hover td,
.table-responsive tbody tr.row-blue,
.table-responsive tbody tr.row-blue td { background-color: #cce5ff !important; }

.table tbody tr.row-orange,
.table tbody tr.row-orange td,
.table-hover tbody tr.row-orange:hover,
.table-hover tbody tr.row-orange:hover td,
.table-responsive tbody tr.row-orange,
.table-responsive tbody tr.row-orange td { background-color: #ffe5cc !important; }

.table tbody tr.row-turquoise,
.table tbody tr.row-turquoise td,
.table-hover tbody tr.row-turquoise:hover,
.table-hover tbody tr.row-turquoise:hover td,
.table-responsive tbody tr.row-turquoise,
.table-responsive tbody tr.row-turquoise td { background-color: var(--row-color-turquoise-bg) !important; }

/* Ячейка «Дата выдачи по регламенту»: фон по срокам (перекрывает фон строки по статусу); текст — стандартный */
.table tbody tr td.cell-red,
.table-responsive tbody tr td.cell-red { background-color: var(--row-color-red-bg) !important; }
.table tbody tr td.cell-orange,
.table-responsive tbody tr td.cell-orange { background-color: var(--row-color-orange-bg) !important; }
.table tbody tr td.cell-yellow,
.table-responsive tbody tr td.cell-yellow { background-color: var(--row-color-yellow-bg) !important; }
.table tbody tr td.cell-gray,
.table-responsive tbody tr td.cell-gray { background-color: var(--row-color-gray-bg) !important; }

/* Для мобильных карточек */
.card-white { border-left: 4px solid var(--card-border-white); }
.card-gray { border-left: 4px solid var(--card-border-gray); }
.card-green { border-left: 4px solid var(--card-border-green); }
.card-yellow { border-left: 4px solid var(--card-border-yellow); }
.card-red { border-left: 4px solid var(--card-border-red); }
.card-blue { border-left: 4px solid var(--card-border-blue); }
.card-orange { border-left: 4px solid var(--card-border-orange); }
.card-turquoise { border-left: 4px solid var(--card-border-turquoise); }

/* Текст для статусов */
.status-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
}

.status-badge-white {
    background: var(--row-color-white-bg);
    color: var(--status-text-default);
    border: 1px solid #dddddd;
}

.status-badge-gray {
    background: var(--row-color-gray-bg);
    color: var(--status-text-gray);
}

.status-badge-green {
    background: var(--row-color-green-bg);
    color: var(--status-text-green);
}

.status-badge-yellow {
    background: var(--row-color-yellow-bg);
    color: var(--status-text-yellow);
}

.status-badge-red {
    background: var(--row-color-red-bg);
    color: var(--status-text-red);
}

.status-badge-blue {
    background: var(--row-color-blue-bg);
    color: var(--status-text-blue);
}

.status-badge-orange {
    background: var(--row-color-orange-bg);
    color: var(--status-text-orange);
}