/* Общие стили */
body {
    font-family: Arial, sans-serif;
    background-color: #FCFCFC;
    color: #333;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Позволяет увеличиваться */
    height: auto;
}


.wrapper {
    margin-top: 80px;
    margin-bottom: 80px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.content-container {
    background-color: #fff;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    transition: all 0.3s ease-in-out;
    box-sizing: border-box; /* Добавляем, чтобы padding не увеличивал размеры */
}

.profile-header {
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.tabs {
    display: flex;
    justify-content: center;
    background-color: #fff;
    padding: 12px;
    border-radius: 12px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    color: #666;
    border-bottom: 3px solid transparent;
    transition: all 0.2s ease;
    outline: none;
}

.tab-btn:hover {
    color: #000;
    border-bottom: 3px solid #aaa;
}

.tab-btn.active {
    color: #000;
    font-weight: bold;
    border-bottom: 3px solid #8C0014; /* красивый синий */
}

.tab-content {
    text-align: left;
}

#stats-tab ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

#stats-tab li {
    padding: 5px 0;
}

#editProfileForm {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.4s ease;
}

#editProfileForm.show {
    margin-top: 20px;
    padding-top: 20px;
    display: block;
    max-height: 1800px; /* подстраивай под высоту формы */
    opacity: 1;
}

/* Заголовок */
.formTitle {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
}

/* Поля ввода */
.form-group {
    position: relative;
    margin-bottom: 20px;
    text-align: left;
}

.form-label {
    display: block;
    font-size: 14px;
    margin-bottom: 5px;
    color: #666;
}

.form-control {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
    outline: none;
    transition: all 0.3s ease-in-out;
    box-sizing: border-box; /* Исправляет выход за границы */
}

.form-control:hover {
    border-color: #555;
}

.form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 8px rgba(0, 123, 255, 0.4);
}

.error-message {
    color: red;
    font-size: 14px;
    margin-top: 5px;
}


/* Кнопки */
.button-group {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    gap: 20px;
}

/* Ссылка "Забыли пароль?" */
.forgot-password {
    margin-top: 15px;
}

.forgot-password a {
    color: #423b38;
    text-decoration: none;
    transition: all 0.3s ease-in-out;
}

.forgot-password a:hover {
    text-decoration: underline;
    color: #8C0014;
}

a {
	text-decoration: none;
}

/* Общие стили */

.container-title {
    width: 30%;
    max-width: 800px;
    margin: 20px auto;
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px 2px rgba(0, 0, 0, 0.1);
}

/* Стили для списка категорий и курсов */

.category-item {
    margin-bottom: 5px;
}

.category-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: #FFF;
    color: #2d2d2d;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    box-shadow: 0 0 3px 1px rgba(0, 0, 0, .1);
    transition: all 0.3s ease;
}

.category-title:hover {
    background: rgba(0, 0, 0, .1);
}

.category-title.selected {
    background: #8C0014;
    color: #fff;
    font-weight: bold;
    box-shadow: 0 0 10px 2px rgba(0, 0, 0, 0.1);
}

.category-title.open:hover {
    transition: all 0s; /* Отключаем плавность при открытии */
}



/* Иконка раскрытия */
.toggle-icon {
    width: 24px;
    height: 24px;
    background: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23abbac4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") no-repeat center;
    pointer-events: none;
    transform: rotate(-90deg);
    transition: all 0.3s ease;
}

.open .toggle-icon {
    transform: rotate(0deg);
}

/* Вложенные категории */
.subcategories {
    list-style: none;
    padding-left: 20px;
    margin-top: 5px;
}

.courses-container {
    width: 100%; /* Увеличена ширина для лучшего использования пространства */
    height: 100%;
    max-height: 65vh; /* Ограничиваем высоту контейнера */
    overflow-y: auto; /* Добавляем вертикальную прокрутку */
    padding-right: 16px; /* Чтобы прокрутка не перекрывала контент */
}
.courses-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding-bottom: 5px;
    list-style: none;
}

/* Курс */
.course {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 0 3px 1px rgba(0, 0, 0, .1);;
    margin: 5px 0;
    padding: 20px 25px;
    text-decoration: none;
    color: #2C1A1A;
    cursor: pointer;
    transition: all 0.3s ease;
}

.course:hover {
    background: rgba(0, 0, 0, .1);
    transform: translateY(-2px);
}

.course h2 {
    font-size: 20px;
    margin: 0;
    font-weight: 600;
    color: #2C1A1A;
}



/* Прогресс курса */
.progress-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px; /* Увеличение размера кружка */
    height: 64px; /* Увеличение размера кружка */
    border-radius: 50%;
    background: conic-gradient(#4caf50 calc(var(--progress) * 1%), #ddd 0%);
    position: relative;
}
.progress-container::after {
    content: attr(data-progress) '%';
    position: absolute;
    font-size: 18px; /* Увеличение размера текста */
    font-weight: bold;
}


.course-content {
    background-color: #fff;
    background-repeat: no-repeat;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    text-align: center;
    max-width: 500px;
    width: 100%;
}

.course-img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 20px;
}

.button-group {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.btn {
    flex: 1;
    padding: 12px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    text-align: center;
    text-decoration: none;
    display: inline-block;
}

.btn:disabled {
    color: #a1a1a1;
    background: #fff;
}

.btn:hover:disabled {
    transform: none;
    color: #a1a1a1;
    background: #fff;
}

/* Стили для слайдера */
.course-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-color: #FCFCFC;
    padding: 0 20px;
}

.slide-navigation {
    background: transparent;
    font-size: 18px;
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    /* display: none; <- Crashes Chrome on hover */
    -webkit-appearance: none;
    margin: 0; /* <-- Apparently some margin are still there even though it's hidden */
}

#slide-number {
    background: transparent;
    font-size: 18px;
    width: 30px;
    padding: 8px 0;
    text-align: right;
    border: none;
    outline: none;
    margin-top: 10px;
    margin-bottom: 10px;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    75% { transform: translateX(-5px); }
}

.shake {
    animation: shake 0.5s ease-in-out;
}


.slider-container {
    width: 100%;
    max-width: 1200px;
    max-height: 70vh;
    height: auto;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 0 10px 2px rgba(0, 0, 0, 0.1);
    text-align: center;
    position: relative;
}

.question-image {  
    height: 300px;
    max-width: 100%; /* Ограничивает размер по ширине */
    width: auto; /* Автоматическая ширина */
    background-size: contain; /* Вписываем картинку без обрезки */
    background-repeat: no-repeat; /* Отключаем повторение */
    background-position: center; /* Центрирование */
    display: block; /* Чтобы работало центрирование */
    margin: 0 auto 10px auto; /* Центрируем */
}


/* Слайды */

.slick-initialized .slick-slide {
    display: flex;
}

.slider {
    display: flex !important;
    flex-direction: row !important;
    overflow: hidden;
    width: 100%;
    height: 100%;
}

.slide {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}
.test-slide .slide-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    text-align: center;
    min-height: 200px; /* или подбери нужное значение */
}
.test-slide form {
    margin-top: 20px;
}

.slick-list, .slick-track {
    height: 100%;
}

.slide-header, .slide-footer {
    padding: 15px;
    text-align: center;
    color: white;
}

.slide-header h3 {
    padding: 0 50px;
}

.slide-footer-test {
    display: flex;
    margin-top: 20px;
    padding: 15px 20px;
    justify-content: space-between;
}

.next-question {
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    text-shadow: 0 0 50px rgba(255, 255, 225, .4);
    padding: 25px 35px 25px 30px;
    border: none;
    border-radius: 4px 10px 10px 4px;
    box-shadow: -5px 8px 10px rgba(140, 0, 20, .2);
    background: linear-gradient(90deg, #8C0014, #c2001d, #f50025);
    transition: all 0.3s ease; /* Плавные переходы */
}

.prev-question {
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    text-shadow: 0 0 50px rgba(255, 255, 225, .4);
    padding: 25px 30px 25px 35px;
    border: none;
    border-radius: 10px 4px 4px 10px;
    box-shadow: 5px 8px 10px rgba(140, 0, 20, .2);
    background: linear-gradient(90deg, #f50025, #c2001d, #8C0014);    
    transition: all 0.3s ease; /* Плавные переходы */
}

/* Эффект при наведении */
.next-question:hover {
    box-shadow: 0 0 10px rgba(140, 0, 20, .5); /* Яркая тень при наведении */
    text-shadow: 0 0 20px rgba(255, 255, 255, 1); /* Увеличиваем тень текста */
}

.prev-question:hover {
    box-shadow: 0 0 10px rgba(140, 0, 20, .5); /* Яркая тень при наведении */
    text-shadow: 0 0 20px rgba(255, 255, 255, 1); /* Увеличиваем тень текста */
}


.slide-content {
    flex-grow: 1;
    display: flex;
    justify-content: left;
    align-items: center;
    text-align: center;
    height: 100%;
}

.slide-content-test {
    max-height: 25vh;  /* Ограничиваем максимальную высоту */
    background-size: contain;  /* Фон будет уменьшаться, чтобы поместиться в контейнер */
    background-position: center;  /* Центрируем изображение */
    background-repeat: no-repeat;  /* Запрещаем повторение изображения */
    object-fit: contain;  /* Это можно оставить, если вы хотите контролировать изображения в контейнерах типа <img> */
}

.slide-content-test img {
    max-width: 10vw;
}

.presentation-image-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    overflow: hidden;
    flex-direction: column; /* кнопка будет над/под изображением */
}

.image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.presentation-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.overlay-button {
    margin-top: -14%; /* сдвигаем кнопку наверх поверх изображения */
    z-index: 1;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

.slick-dotted.slick-slider {
    margin-bottom: 0;
}


.slide:last-child {
    border-bottom: none;
}

.slide h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #333;
}

.slide p {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
}



.test-slider {
    display: flex !important;
    flex-direction: row !important;
    overflow: hidden;
    width: 100%;
    height: 100%;
}

.test-slide {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

/* Кнопки слайдера */
.slick-prev, .slick-next {
    border: none;
    border-radius: 50%;
    padding: 40px; /* Увеличиваем размер кнопок */
    transition: transform 0.3s ease;
    position: absolute;
    top: 50%;
    transform: translateY(-50%) scale(1); /* Устанавливаем начальный масштаб */
    z-index: 1;    
}

.slick-prev:before,
.slick-next:before {
    font-family: 'slick';
    font-size: 60px;
    line-height: 1;
    opacity: .75;
    color: #8C0014;
}

.slick-prev {
    left: -120px;
}

.slick-next {
    right: -60px;
}

/* Увеличиваем кнопку при наведении, но не смещаем её */
.slick-next:hover {
    transform: translateY(-54%) scale(1.2); /* Увеличиваем, сохраняя положение */
}
.slick-prev:hover {
    transform: translateY(-54%) translateX(-20%) scale(1.2); /* Увеличиваем, сохраняя положение */
}

/* Точки */
.slick-dots {
    display: flex !important;
    justify-content: center;
    align-items: center;
}

.slick-dots li button:before {
    font-size: 12px;
    color: #999;
    transition: color 0.3s ease;
}

.slick-dots li.slick-active button:before {
    color: #8C0014;
}

.slick-dots li {
    margin: 0 5px;
}

/* Кнопки "Начать курс" и "Тест" */
.btn.choice {
    margin-top: 10px;
    padding: 15px 30px;
    font-size: 18px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
    text-align: center;
    display: inline-block;
}

.primary {
    background-color: rgba(140, 0, 20, 1.0);
    color: #fff;
}

.primary:hover {
    transform: scale(1.05);
}

.secondary {
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ccc;
    padding-inline: 10px;
}

.secondary:hover {
    background-color: #e0e0e0;
    transform: scale(1.05);
}

.start_test {
    position: absolute;
    top: 70%;
    text-decoration: none;
    color: #8C0014;
    background-color: #fff;
    border: none;
}


.answer-options {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 500px;
    margin: 50px auto;
}
.answer-options label {
    display: block;
    background: #f8f9fa;
    padding: 10px;
    margin: 5px 0;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
    text-align: center;
}
.answer-options input[type="text"] {
    display: block;
    background: #f8f9fa;
    padding: 10px;
    margin: 5px 0;
    border-radius: 5px;
    width: 100%;
    font-size: 18px;
    text-align: center;
}
.answer-options input[type="radio"], .answer-options input[type="checkbox"] {
    display: none;
}
.answer-options label:hover {
    background: rgba(0, 0, 0, .1);
}
.answer-options input[type="radio"]:checked + label, .answer-options input[type="checkbox"]:checked + label {
    background: #8C0014;
    color: #fff;
}


.matching-question {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.matching-pair {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}
.matching-pair label {
    flex: 1;
    text-align: left;
    font-weight: bold;
    background: #fff;
    max-width: 200px;
    word-wrap: break-word;
}
.matching-pair label:hover {
    background: #fff;
    color: #333;
}
.matching-pair select {
    font-size: 16px;
    flex: 1;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #ccc;
}
.matching-pair select:focus option:first-of-type {
    display: none;
}
option {
    white-space: wrap;
}

/* Шапка */
.main-header {
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    background-color: #FCFCFC;
    color: white;
    padding: 0;
    z-index: 1000;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between; /* Разделяет элементы по краям */
    border-bottom: 2px solid #e5e5e5;
}

.main-header .container {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 90%;
    max-width: 1520px;
    margin: 0 auto;
    padding: 0 20px;
    overflow-y: hidden;
}

/* Логотип */
.main-header .logo img {
    height: 40px;
    display: block;
}

/* Меню */
.nav-menu {
    height: 100%;
    display: flex;
    flex: 1; /* Это позволяет меню растягиваться на оставшееся пространство */
    justify-content: center; /* Центрирует пункты меню */
    margin-left: 100px; /* Добавляем отступ между логотипом и меню */
    text-wrap: nowrap;
}

.nav-items-center {
    height: 100%;
    display: flex;
    justify-content: center;
    gap: 20px; /* Расстояние между пунктами меню */
}

/* Профиль и Выйти справа */
.nav-items-right {
    display: flex;
    align-items: center;
    margin-left: auto; 
}

/* Каждый пункт меню */
.nav-item {
    display: flex;
    align-items: center;
    height: 100%;
}

/* Делаем ссылки во всю высоту */
.nav-item a {
    color: #5c5c5c;
    font-size: 16px;
    text-decoration: none;
    font-weight: 600;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 2px solid transparent;
    border-top: 0px solid transparent;
    transition: all .3s
}

/* Эффект наведения */
.nav-item a:hover {
    background: rgba(255, 255, 255, 0.4);
    color: #000;
    border-color: #8C0014;
}

/* Кнопки в хедере */
.nav-btn {
    height: 50%;
    padding: 10px 15px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

/* Кнопка Войти */
.nav-btn.login {
    background: #28a745;
    color: white;
}

/* Кнопка Регистрация */
.nav-btn.register {
    background: #ff5722;
    color: white;
}

/* Кнопка Выйти */
.logout-nav-btn .nav-btn.logout {
    background: #8C0014; /* Красный цвет */
    color: white;
    font-size: 16px;
    font-weight: bold;
    border-radius: 8px;
    border: none;
    transition: all 0.3s ease-in-out;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(220, 53, 69, 0.3);
}

/* Отступ для кнопок "Профиль" и "Выйти" */
.logout-nav-btn .nav-btn.logout:hover {
    background: #c82333;
    box-shadow: 0 6px 15px rgba(220, 53, 69, 0.5);
    transform: scale(1.05);
}


/* Футер */
.main-footer {
    width: 100%;
    position: fixed;
    bottom: 0;
    left: 0;
    background-color: #FCFCFC;
    color: #5c5c5c;
    text-align: center;
    padding: 15px 0;
    border-top: 2px solid #e5e5e5;
}

/* Результаты тестов  */

.correct {
    color: green;
    font-weight: bold;
}

.incorrect {
    color: red;
    font-weight: bold;
}

li {
    margin-top: 10px;
}
.result-selector {
    padding: 10px;
}
.result-selector h3 {
    margin-bottom: 10px;
}

.result-link-box {
    margin-bottom: 6px;
}

.result-link {
    display: block;
    padding: 8px 10px;
    margin-bottom: 5px;
    text-decoration: none;
    color: #333;
    border-radius: 4px;
    box-shadow: 0 0 3px 1px rgba(0, 0, 0, .1);
    transition: all 0.2s;
}
.result-link:hover {
    background: rgba(0, 0, 0, .1);
}
.result-link.selected {
    background: #8C0014;
    color: white;
    font-weight: bold;
}
.result-link.selected:hover {
    background: #8C0014;
    color: white;
    font-weight: bold;
}

.result-details {
    padding: 15px;
    line-height: 130%;
}

.user-result-summary {
    padding: 10px;
    background-color: #f0fff0;
    border: 1px solid #c0dec0;
    border-radius: 6px;
}

.result-container {
    display: flex;
    align-items: start;
    gap: 20px;
}

.result-content {
    flex: 1;
    flex-grow: 1;
    height: 660px; /* Минимальная высота, чтобы не было скачков */
    width: 800px;
    padding: 20px;
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 0 10px 2px rgba(0, 0, 0, 0.1);
    overflow: auto;
}

.result-menu {
    width: 220px;
    max-height: 700px;
    overflow: auto;
    background: #fff;
    padding: 15px;
    box-shadow: 0 0 10px 2px rgba(0, 0, 0, 0.1);
    border-radius: 5px;
}

.result-menu h3 {
    margin-top: 0;
}

.result-menu a {
    display: block;
    padding: 10px;
    text-decoration: none;
    color: #333;
}
.result-menu a:hover {
    background: rgba(0, 0, 0, .1);
}

.noselect {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}



.progress-wrapper {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.progress-svg {
    transform: rotate(-90deg);
}

.progress-bg, .progress-bar {
    fill: none;
    stroke-width: 8;
    cx: 50;
    cy: 50;
    r: 45;
}

.progress-bg {
    stroke: #ddd;
}

.progress-bar {
    stroke: #FF9F1E;
    stroke-dasharray: 282.7;
    stroke-dashoffset: 282.7;
    transition: stroke-dashoffset 1s linear, stroke 1s linear;
}

.progress-text {
    position: absolute;
    font-size: 18px;
    font-weight: bold;
    color: #3A2323;
}

.btn-toggleInfo {
    background: gray;
    border-radius: 50%;
    box-shadow: 2px 2px 4px white;
    width: 40px;
    height: 40px;
    color: #fff;
    font-size: 18px;
    font-weight: bold;
}

.info {
    display: none;
    height: auto;
}

.front-of-image {
    position: absolute;
    background-color: rgba(0, 0, 0, .7);
    top: 10%;
    left: 7%;
    align-content: center;
    text-decoration: none;
    border: none;
}

select {
  height: 32px;
  margin: 0 8px;
  padding: 3px 5px 3px 5px; /* Оставляем место для стрелки */
  border: 1px solid #304d69;
  border-radius: 5px;
  text-align: center;
  
  position: relative;
  cursor: pointer;
}

.cookie-consent {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 500px;
    background: #2c2c2c;
    color: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    text-align: center;
}

.cookie-consent.show {
    opacity: 1;
    visibility: visible;
}

.cookie-consent p {
    margin: 0 0 15px;
    font-size: 14px;
    line-height: 1.5;
}

.cookie-consent a {
    color: #00bfff;
    text-decoration: underline;
}

.cookie-btn {
    background-color: #00bfff;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.cookie-btn:hover {
    background-color: #009ad6;
}


/* Регламент */
.rules {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}
.rules-container {
    display: flex;
    margin-top: 100px;
    gap: 32px;
    padding: 0 20px;
}
.block {
    background: white;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    padding: 16px;
    box-sizing: border-box;
}
.left-side,
.right-side {
    font-size: 14px;
    width: 256px;
}

.left-side .department-link,
.right-side a {
    display: block;
    text-decoration: none;
    color: #333;
    padding: 8px;
    border-radius: 4px;
    transition: all 0.2s;
}

.left-side .department-link:hover:not(.selected):not(.inactive),
.right-side a:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.department-link.selected {
    background: #8C0014;
    color: white;
    font-weight: bold;
}

.center-side {
    flex-grow: 1;
    min-width: 400px;
    width: 860px;
    padding: 32px 64px;
    margin-bottom: 167px;
}

.left-side, .right-side {
    max-height: 70vh;
    height: fit-content;
    overflow-y: auto;
    position: sticky;
    top: 100px;
}

.right-side nav ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}
.right-side nav ul li {
    margin-left: 21px;
    margin-top: 5px;
}
.guidebox {
    background-color: rgba(0, 0, 0, .01);
    border-radius: 5px;
    padding: 20px;          
    align-items: center;
    box-shadow: 0 0 1px 1px rgba(0,0,0,0.1);
}
.guidebox-title {
    display: flex;
    gap: .75rem;
    font-weight: bold;
    font-size: 18px;
}
.guidebox li::marker{
    color: #bfbfbf;
    font-size: 16px;
}
.guidebox li {
    margin: 16px 0;
    padding-left: 10px;
}
.guidebox ul {
    padding-left: 24px;
}
kbd {
    border: 1px solid #bfbfbf;
    border-radius: .5rem;
    background-color: #fff;
    padding: .26rem .375rem;
}
center-side h1, section h1 {
    display: flex;
    margin-top: 48px;
    margin-bottom: 24px;
    align-items: center;
    font-size: 24px;
}
section ol {
    list-style: none;
    padding-left: 0;
    margin: 0;
    counter-reset: list;
    border-radius: 5px;
}

section ol > li {
    position: relative;
    margin: 12px 0;
    padding: 5px;
    line-height: 1.5;
    border-radius: 5px;
}

section ol > li > ol {
    margin-top: 8px;
    padding-left: 24px;
    border-left: 2px solid #e0e0e0;
}

section ol li::before {
    position: absolute;
    left: 0;
    color: #333;
    font-weight: bold;
}

section ol > li > div:first-child a.rule-link,
section ol > li > a.rule-link {
    font-weight: bold;
    color: #333;
    margin-right: 8px;
    text-decoration: none;
}

section ol > li > div:first-child a.rule-link:hover,
section ol > li > a.rule-link:hover {
    text-decoration: underline;
}

section ol li > div {
    display: flex;
}
.rule-link-title {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: .26rem .15rem;
    border-radius: 0.5rem;
    border: 1px solid #ccc;
    background-color: #fff;
    transition: background-color 0.3s;
    position: relative;
    cursor: pointer;
    margin-right: 10px;
}

.rule-link-title:hover {
    background-color: #f0f0f0;
}

.rule-icon {
    position: relative;
    width: 20px;
    height: 20px;
    display: inline-block;
}

.rule-num {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s;
    font-weight: bold;
    color: #333;
}

.rule-link-icon {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    width: 20px;
    height: 20px;
    opacity: 0;
    transition: opacity 0.3s;
    color: #666;
}

.rule-link-title:hover .rule-num {
    opacity: 0;
}

.rule-link-title:hover .rule-link-icon {
    opacity: 1;
}

.rule-link-title:active {
    background-color: #e0e0e0;
    box-shadow: 0 0 0 3px rgba(140, 0, 20, 0.3);
}
.example {
  display: inline-block;
  background: rgba(255, 235, 205, 0.4); /* нежный бежевый */
  color: #6b4c00;
  font-weight: 500;
  padding: 2px 6px;
  margin-left: 6px;
  border-radius: 4px;
  font-family: monospace;
}
.example.subtle {
  background-color: rgba(0, 0, 0, .01);
  color: #333;
  padding: 2px 6px;
  border-radius: 4px;
  font-style: italic;
  font-size: 12px;
  box-shadow: 2px 2px 2px 0 rgba(0, 0, 0, .1);
}
.example.subtle .icon {
  margin-right: 4px;
  opacity: 0.7;
}
u {
    text-underline-offset: 4px;
}
.penalty {
    background-color: rgba(255, 0, 0, .2);
    padding: 6px 8px;
    border-radius: 12px;
}

.nav-icon {
    fill: #5C5C5C;
    transition: all 0.3s;
}
.nav-icon:hover {
    fill: #8C0014;
}


.notification-icon-wrapper {
    display: inline-block;
    position: relative;
}

.notification-badge {
    position: absolute;
    top: 0px;
    right: 0px;
    width: 12px;
    height: 12px;
    background-color: red;
    border-radius: 50%;
    border: 2px solid white;
}
.notification-item.read {
    opacity: 0.6;
}

.notification-item.unread {
    background-color: #fff;
}

#notificationDropdown {
    display: none;
    position: absolute;
    top: 18px;
    right: -150px;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    width: 360px;
    max-height: 400px;
    overflow-y: auto;
    z-index: 2000; /* больше, чем у header */
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#notificationWrapper {
    position: relative;
    z-index: 2010;
}

#notificationDropdown .note {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s;
    text-wrap: wrap;
}

.note-clear-btn {
    background: none;
    border: none;
    color: #ea3323aa;
    font-size: 14px;
    cursor: pointer;
    font-weight: bold;
    transition: 0.2s ease;
}
.note-clear-btn:hover {
    background: none;
    color: #cf000f;
}

@media (max-width: 768px) {
    .product-card {
        width: 100%;
        max-width: 90vw;
    }
}
