.sticky-navbar {
  position: sticky;
  top: 0; /* Фиксируем navbar к верхнему краю окна браузера */
  padding: 10px;
  z-index: 100; /* Чтобы navbar был над контентом */
}

/* Базовые стили для всех экранов */
.responsive-table .table {
  width: 100%;
  border-collapse: collapse;
}

.responsive-table .table th,
.responsive-table .table td {
  padding: 10px;
  text-align: left;
  border: 1px solid #ddd;
}

/* Медиазапрос для мобильных устройств */
@media only screen and (max-width: 600px) {
  .responsive-table .table,
  .responsive-table .table thead,
  .responsive-table .table tbody,
  .responsive-table .table th,
  .responsive-table .table td,
  .responsive-table .table tr {
    display: block;
  }

  /* Показываем заголовки как метки */
  .responsive-table .table th {
    position: absolute;
    top: -9999px;
    left: -9999px;
  }

  .responsive-table .table td {
    border: none;
    border-bottom: 1px solid #ddd;
    position: relative;
    padding-left: 50%; /* Оставляем место для меток */
  }

  .responsive-table .table td:before {
    content: attr(data-th);
    position: absolute;
    top: 0;
    left: 0;
    width: 45%; /* Ширина меток */
    padding-right: 10px; /* Отступ между меткой и значением */
    white-space: nowrap;
    text-align: right;
    font-weight: bold;
  }
}

.scrollable-table {
    overflow-y: auto;
    min-height: 150px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
}

.scrollable-table > table {
    flex-grow: 1;
    border-collapse: collapse; /* объединяем границы */
}

.scrollable-table th,
.scrollable-table td {
    padding: 8px;
    text-align: center;
    border: 1px solid #669bbc;
}

.scrollable-table th:first-child,
.scrollable-table td:first-child {
    position: sticky;
    left: 0;
    background-color: white;
    z-index: 30;
}

.scrollable-table thead th {
    position: sticky;
    top: 0;
    background-color: white;
    z-index: 20;
}

.scrollable-table thead th:first-child {
    top: 0;
    z-index: 40;
}

.scrollable-table-second-column-fixed tbody td:nth-child(2),
.scrollable-table-second-column-fixed thead th:nth-child(2) {
    position: sticky;
    left: 120px;
    background-color: white;
    z-index: 35;
}

.scrollable-table-second-column-fixed thead th:nth-child(2) {
    top: 0;
    z-index: 45;
}

body {
   font-family: FreeMono, monospace;
}

/* Общие стили для таблицы */
.table,
.table-sm {
  background-color: white;
  justify-content: center; /* Горизонтальное центрирование */
  align-items: center; /* Вертикальное центрирование */
}

/* Стилизация заголовков таблицы */
.table thead th,
.table-sm thead th {
  background-color: white;
  color: #003049;
  text-align: center; /* Горизонтальное выравнивание */
  vertical-align: middle; /* Вертикальное выравнивание */
}

/* Фон и цвет текста в теле таблицы */
.table tbody td,
.table-sm tbody td {
  background-color: white;
  color: #1F3745;
  text-align: center; /* Горизонтальное выравнивание */
  vertical-align: middle; /* Вертикальное выравнивание */
}

/* Внутренние границы слева в заголовках */
th + th {
        border-left: 1px solid #669bbc;
}

/* Внутренние границы сверху в заголовках */
thead th {
         border-bottom: 2px solid #669bbc;
}

/* Внутренние границы слева */
td + td {
         border-left: 1px solid #669bbc !important;
}

/* Внутренние границы сверху */
tr + tr td {
            border-top: 1px solid #669bbc important;
}

.left-aligned {
    text-align: left;
}

h1, h2, h3 {
    color: #001f54;
}

/* Основные стили навбара */
.navbar {
  background-color: #003049;
}

/* Основные стили для всех ссылок навбара */
.navbar-nav .nav-link {
  color: #669bbc !important;
  padding: 0.5rem 1rem;
  transition: color 0.2s ease;
}

/* Стили при наведении на ЛЮБУЮ ссылку */
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus,
.navbar-nav .nav-link.active {
  color: #fdf0d5 !important;
}

/* Специальные стили для выпадающего меню */
.navbar-nav .dropdown-toggle.nav-link {
  position: relative;
}

/* Определяет цвет границы для кнопки гамбургера (меню на мобильных устройствах) */
.navbar-toggler {
  border-color: #669bbc;
}

/* Определяет иконку гамбургера с белым цветом линий */
.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23efebe3' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Удаляет контур вокруг кнопки гамбургера при фокусировке или активации */
.navbar-toggler:focus,
.navbar-toggler:active {
  outline: none;
  box-shadow: none;
}

/* Когда меню открыто */
.navbar-nav .dropdown.show .nav-link,
.navbar-nav .dropdown.show .nav-link:hover,
.navbar-nav .dropdown.show .nav-link:focus {
  color: #fdf0d5 !important;
}

/* Стили самого выпадающего меню */
.dropdown-menu {
  background-color: white;
  border: 1px solid #669bbc;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
}

.dropdown-item {
  color: #003049 !important;
  padding: 0.5rem 1.5rem;
  transition: all 0.2s;
}

.dropdown-item:hover,
.dropdown-item:focus {
  background-color: #f0f8ff !important;
}

.custom-card-text {
            color: #003049; /* Цвет основного текста */
}

.button-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.custom-btn {
    margin-bottom: 0;
}

/* Синяя кнопка */
.info-button {
    background-color: #003049; /* Синий цвет фона */
    color: #669bbc;              /* Белый цвет текста */
    font-size: 17px;           /* Размер шрифта */
    padding: 10px 20px;        /* Отступы внутри кнопки */
    border-radius: 15px;        /* Закругленные углы */
    border: none;              /* Убираем рамку */
    cursor: pointer;           /* Указатель мыши в виде руки при наведении */
    transition: background-color 0.3s ease; /* Плавная анимация при наведении */
}

/* Изменение цвета фона при наведении */
.info-button:hover {
    background-color: #669bbc;
    color: #003049;
}

/* Красная кнока */
.danger-button {
    background-color: #ed0d0d; /* цвет фона */
    color: #fdf0d5;              /* Белый цвет текста */
    font-size: 17px;           /* Размер шрифта */
    padding: 10px 20px;        /* Отступы внутри кнопки */
    border-radius: 15px;        /* Закругленные углы */
    border: none;              /* Убираем рамку */
    cursor: pointer;           /* Указатель мыши в виде руки при наведении */
    transition: background-color 0.3s ease; /* Плавная анимация при наведении */
}

/* Изменение цвета фона при наведении */
.danger-button:hover {
    background-color: #780000;
    color: #fdf0d5;
}

/* Голубая кнопка */
.primary-button {
    background-color: #669bbc; /* цвет фона */
    color: #fdf0d5;              /* Белый цвет текста */
    font-size: 17px;           /* Размер шрифта */
    padding: 10px 20px;        /* Отступы внутри кнопки */
    border-radius: 15px;        /* Закругленные углы */
    border: none;              /* Убираем рамку */
    cursor: pointer;           /* Указатель мыши в виде руки при наведении */
    transition: background-color 0.3s ease; /* Плавная анимация при наведении */
}

.primary-button:hover {
    background-color: #fdf0d5;
    color: #669bbc;
}

/* Общие стили для обеих кнопок */
.custom-btn {
    width: 40px; /* Устанавливаем фиксированную ширину для кнопок */
    height: 40px; /* Устанавливаем фиксированную высоту для кнопок */
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: all 0.3s ease-in-out; /* Добавляем плавный переход при наведении */
    text-decoration: none; /* Убирает подчеркивание */
}

/* Кнопка удаления */
.delete-button {
    background-color: white;
    border: 1px solid #ed0d0d; /* Добавляем тонкую красную границу */
}

.delete-button span {
    font-size: 22px; /* Увеличенный размер крестика */
    color: #ed0d0d; /* Цвет крестика */
}

.delete-button:hover,
.delete-button:focus {
    background-color: #fcebeb; /* Легкий розовый оттенок при наведении */
    border-color: #c00; /* Темнее граница при наведении */
}

/* Кнопка редактирования */
.edit-button {
    background-color: white;
    border: 1px solid #003049; /* Тонкая темно-синяя граница */
}

.edit-button i {
    font-size: 18px; /* Размер иконки карандаша */
    color: #003049; /* Цвет иконки */
}

.edit-button:hover,
.edit-button:focus {
    background-color: #ebf7fe; /* Светло-голубой оттенок при наведении */
    border-color: #0074cc; /* Темнее граница при наведении */
}

/* Стили для кнопки шестерёнки */
.gear-button {
    width: 40px;             /* Фиксированная ширина */
    height: 40px;            /* Фиксированная высота */
    display: flex;
    justify-content: center; /* Центрируем контент по горизонтали */
    align-items: center;     /* Центрируем контент по вертикали */
    border-radius: 50%;      /* Круглая форма кнопки */
    background-color: white; /* Белый фон */
    border: 1px solid #003049; /* Синяя граница */
    transition: all 0.3s ease-in-out; /* Плавный переход */
    cursor: pointer;         /* Указатель мыши меняется на руку при наведении */
    position: relative;       /* Позиционирование для подсказки */
}

.gear-button i {
    font-size: 16px;         /* Размер иконки шестерёнки */
    color: #003049;          /* Цвет иконки */
    line-height: 1;          /* Устраняем лишние пробелы вокруг иконки */
}

.gear-button:hover,
.gear-button:focus {
    background-color: #ebf7fe; /* Светло-голубой фон при наведении */
    border-color: #0074cc;     /* Темнее граница при наведении */
}

/* Дополнительные стили для улучшения внешнего вида */
.gear-button:active {
    transform: scale(0.95);   /* Небольшое уменьшение масштаба при клике */
}

/* Кнопка возврата назад */
.back-button {
    background-color: white;
    border: 1px solid #ed0d0d; /* Используем тот же цвет границы, что и у кнопки редактирования */
}

.back-button span {
    font-size: 23px; /* Размер стрелки */
    color: #ed0d0d; /* Цвет стрелки */
}

.back-button:hover,
.back-button:focus {
    background-color: #fcebeb; /* Светло-голубой оттенок при наведении */
    border-color: #c00; /* Темнее граница при наведении */
}

/* Стили для всплывающей подсказки */
.tooltip-text {
    visibility: hidden;
    width: 150px;
    background-color: rgba(255, 255, 255, 0.85); /* Полупрозрачный белый фон */
    color: #003049;                              /* Темно-синий текст */
    text-align: center;
    padding: 5px;
    border-radius: 6px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);    /* Легкая тень */
    position: absolute;
    z-index: 1;
    bottom: 115%;                                 /* Размещение чуть ниже кнопки */
    left: 50%;
    margin-left: -75px;                           /* Центрирование подсказки */
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip-btn:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Проведение пар, зеленый и красный кружочек */
.fa-check-circle {
    font-size: 25px; /* Изменяй этот параметр для регулировки размера */
    color: green; /* Изменяй этот параметр для регулировки цвета */
}

.fa-minus-circle {
    font-size: 25px; /* Изменяй этот параметр для регулировки размера */
    color: red; /* Изменяй этот параметр для регулировки цвета */
}

.myButton {
    border: 2px solid #003049; /* Цвет границы */
    background-color: white; /* Цвет фона */
    color: #003049;             /* Цвет текста */
    text-decoration: none;     /* Убираем подчеркивание у ссылки */
    display: inline-block;     /* Чтобы кнопка вела себя как блочный элемент */
    font-size: 16px;           /* Размер шрифта */
    transition: all 0.3s ease; /* Плавный переход при наведении */
    border-radius: 10px;
  }

.myButton:hover {
    background-color: #fdf0d5; /* Изменение цвета фона при наведении */
    border-color: #669bbc;     /* Изменение цвета границы при наведении */
    color: #669bbc;
}

/* БЛОК "ТО ЧТО ДОБАВИЛ Я" */
td.cell-highlight {
    background-color: #fdf0d5 !important;
    }

/* Уменьшенные кнопки */
.btn-sm {
    font-size: 0.8rem; /* Меньший текст */
    padding: 5px 8px; /* Меньший отступ */
    white-space: nowrap; /* Запрещаем перенос */
}

.success {
    color: #006400 !important; /* Тёмно-зелёный */
    font-weight: bold;
}

.error {
    color: #8B0000 !important; /* Тёмно-красный */
    font-weight: bold;
}

table tr.red-highlight td {
    color: #ff0000; /* измените на нужный цвет */
}
/* "ТО ЧТО ДОБАВИЛ Я" КОНЕЦБЛОКА */

.normal-size {
    max-width: 100px; /* Фиксированная ширина */
    height: auto; /* Пропорциональная высота */
}

/* Стили для таблицы */
.custom-lesson-table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
}

.custom-lesson-table th,
.custom-lesson-table td {
    padding: 10px;
    text-align: center;
    border: 1px solid #669bbc;
}

.custom-lesson-table th {
    background-color: #003049;
    color: #fdf0d5;
    font-weight: bold;
}

.custom-lesson-table td {
    color: #1F3745;
}

/* Адаптация для мобильных устройств */
@media only screen and (max-width: 600px) {
    .custom-lesson-table,
    .custom-lesson-table thead,
    .custom-lesson-table tbody,
    .custom-lesson-table th,
    .custom-lesson-table td,
    .custom-lesson-table tr {
        display: block;
        width: 100%;
    }

    .custom-lesson-table thead {
        display: none; /* Скрываем заголовок на мобильных устройствах */
    }

    .custom-lesson-table tr {
        margin-bottom: 15px;
        border: 1px solid #669bbc;
        border-radius: 10px;
        padding: 10px;
        background-color: white;
    }

    .custom-lesson-table td {
        border: none;
        position: relative;
        padding-left: 50%;
        text-align: left;
    }

    .custom-lesson-table td:before {
        content: attr(data-th);
        position: absolute;
        left: 10px;
        width: 45%;
        padding-right: 10px;
        white-space: nowrap;
        text-align: left;
        font-weight: bold;
        color: #003049;
    }

    /* Стили для списка студентов */
    .student-list-toggle {
        cursor: pointer;
        color: #003049;
        font-weight: bold;
    }

    .student-list {
        padding-left: 20px;
        margin-top: 10px;
    }

    .student-list li {
        margin-bottom: 10px;
    }
}

.student-count {
    cursor: pointer; /* Меняем курсор на указатель */
    color: #003049; /* Подчеркиваем, что это кликабельный элемент */
    text-decoration: underline;
}

.student-count:hover {
    color: #669BBC; /* Изменяем цвет при наведении */
}

/* Общие стили для всех карточек */
.custom-card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.custom-card h3 {
    color: #001c2b;
    font-weight: 600;
    text-align: center;
    margin-bottom: 1.5rem;
}

.custom-card ul {
    list-style: none;
    padding: 0;
}

.custom-card ul li {
    margin-bottom: 1rem;
}

.custom-card a {
    display: flex;
    align-items: center;
    padding: 1rem;
    border-radius: 8px;
    background-color: #669bbc;
    color: #fdf0d5;
    text-decoration: none;
    transition: all 0.3s ease;
}

.custom-card a:hover {
    background-color: #5282a1;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.custom-card .fas {
    color: #fdf0d5;
    margin-right: 0.75rem;
    font-size: 1.25rem;
}

/* Уникальные стили для этой карточки */
.custom-report-card {
    /* background-color: #fdf0d5; Удаляем фон */
}

.custom-report-card h3 {
    color: #001c2b; /* Можно изменить, если нужно */
}

.custom-report-card a {
    background-color: #669bbc; /* Светло-синий */
    color: #fdf0d5; /* Светло-бежевый */
}

.custom-report-card a:hover {
    background-color: #5282a1; /* Темнее светло-синего */
}

/* Стили для страницы замены ======================== */
.lesson-card {
    background-color: #f8f9fa;
    transition: all 0.2s ease;
}
.lesson-card:hover {
    background-color: #e9ecef;
}
.lessons-container {
    max-height: 500px;
    overflow-y: auto;
    padding-right: 10px;
}
/* Конец блока ======================================== */

.table-sm td, .table-sm th {
            padding: 0.3rem;
        }

@media (max-width: 991.98px) {
    .col-lg-6 {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

.custom-table-border {
        border: 4px solid #dee2e6 !important; /* Жирная черная граница */
        border-collapse: separate !important;
        border-spacing: 0;
    }

.custom-table-border th,
.custom-table-border td {
    border: 1px solid #dee2e6; /* Внутренние границы остаются обычными */
}

/* Стили для заголовка с локацией */
table thead tr.location-header th {
  background-color: #345E77 !important;
  color: #fdf0d5 !important;
  border-radius: 4px;
}

/* Стили для ссылок преподавателей */
a.teacher-link {
  color: #006CAE !important;
}

/* Общие стили таблицы */
.schedule-table-wrapper {
  border: 3px solid #adb5bd;
  border-radius: 4px;
  overflow: hidden;
}