html[lang="zh-Hant"] .fw-semibold,
html[lang="zh-Hans"] .fw-semibold {
    font-weight: 500 !important; /* Умеренная жирность, которая не дает штрихам слиться */
}
body {font-size: 1.1rem; /* ~17.6px */
    line-height: 1.6;}
.text-shadow {
    text-shadow: 1px 1px 2px #000000;
}
@media (min-width: 768px) {
    .border-md-none {
        border: none !important;
    }
}
strong {font-weight: 600;}
.a-flags {color: #7EC7ED;text-align: center;text-decoration: none !important;display: block;font-size:0.8rem;margin-top: 0;}
article p {
    line-height: 1.45;
}
header.bg-header {
    background-color: #2E5B89 !important;
}
.bg-otazky {
    background-color: #CFDFEF !important;
    border-radius: 4px !important;
    padding-top: 4px;
    padding-bottom: 4px;
}
header h1, header h2 {
    /*text-shadow: 1px 1px 2px #000000;*/
}
nav ul li a {color: #0645ad !important;}
.breadcrumb-item a {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem; /* чуть больше отступ между иконкой и текстом */
}
.breadcrumb-item a img {
    height: 25px;
    width: 25px;
    object-fit: contain;
}
.breadcrumb {
    --bs-breadcrumb-divider: '➝';
    display: flex;
    flex-wrap: wrap; /* ✅ разрешаем перенос всей цепочки */
    align-items: center;
    gap: 0.25rem;
}
ol li::marker {
    font-weight: 700;
}
.justify {
    text-align: left;
}
@media (max-width: 768px) {
    .breadcrumb {
        font-size: 0.95rem; /* уменьшает весь текст внутри хлебных крошек */
        line-height: 1.4;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
    .breadcrumb-item a {
        gap: 0.2rem;
    }
    .breadcrumb-item a img {
        height: 20px;
        width: 20px;
    }
}
@media (min-width: 576px) {
    .justify {
        text-align: justify;
    }
}
/* Общий стиль для всех иконок языков */
.flag-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px !important; /* Фиксируем ширину */
    height: 24px !important; /* Фиксируем высоту */
    object-fit: cover; /* Чтобы флаги не искажались */
    border-radius: 0 !important; /* Убираем скругления */
}
/* Специфический стиль для текстовой заглушки */
.lang-ru {
    background-color: #495057; /* Темно-серый, нейтральный */
    color: #ffffff;
    font-size: 10px;
    font-weight: bold;
    text-transform: uppercase;
    border: 1px solid #343a40;
    vertical-align: middle;
}
/* Убираем тень при наведении, если нужно */
.flag-icon:hover {
    filter: brightness(1.1);
    transition: 0.2s;
}
.label-circle {width: 60px !important;height: 60px !important;padding: 0 !important;display: flex !important;justify-content: center !important;align-items: center !important;border-radius: 50% !important;border: 2px solid #6c757d !important;}
.label-circle:hover {color: white !important;background-color: #A3A9AF !important;text-shadow: 1px 1px 1px #000000 !important;}
.label-nz {width: 105px !important;height: 60px !important;padding: 0 !important;display: flex !important;justify-content: center !important;align-items: center !important;border: 2px solid #6c757d !important;}
.label-nz:hover {color: white !important;background-color: #A3A9AF !important;text-shadow: 1px 1px 1px #000000 !important;}
.label-nz-long {width: 150px !important;height: 60px !important;padding: 0 !important;display: flex !important;justify-content: center !important;align-items: center !important;border: 2px solid #6c757d !important;}
.label-nz-long:hover {color: white !important;background-color: #A3A9AF !important;text-shadow: 1px 1px 1px #000000 !important;}
.label-circle-middle {width: 30px !important;height: 30px !important;padding: 0 !important;display: flex !important;justify-content: center !important;align-items: center !important;border-radius: 50% !important;border: 2px solid #6c757d !important;font-weight:600!important}
.label-circle-middle:hover {color: white !important;background-color: #A3A9AF !important;text-shadow: 1px 1px 1px #000000 !important;}
/* Цвет для пустых ячеек (фон шкалы) */
.sds-empty {
    background-color: #EBEBEB;
}
/* Цвета для закрашенной части в зависимости от результата */
.sds-filled-norm {
    background-color: #1A83BB; /* Синий */
}
.sds-filled-light {
    background-color: #005C00; /* Зеленый */
}
.sds-filled-medium {
    background-color: #AF7800; /* Оранжевый */
}
.sds-filled-severe {
    background-color: #E05160; /* Темно-красный */
}
.sds-filled-heavy {
    background-color: darkred; /* Темно-красный */
}

.sds-filled-very-difficult {
    background-color: #000000; /* Темно-красный */
}
.div-table {max-width: 650px !important;}
/* === RADIO (чистая версия) === */
.custom-radio {
    padding: 8px 0;
    margin: 0;
    border-bottom: 1px solid #C2C9D1;
}
.custom-radio:has(+ .bg-otazky) {
    border-bottom: none;
    padding-bottom: 12px;
}
/* уменьшаем отступ у первого варианта */
.bg-otazky + .custom-radio {
    padding-top: 2px;
    border-top: none;
}
.bg-otazky {
    margin-bottom: 7px;
}
.custom-radio label {
    display: flex;
    align-items: center; /* ВОТ ЭТО меняем */
    cursor: pointer;
    user-select: none;
}
.custom-radio input[type="radio"] {
    display: none;
}
.custom-radio span {
    position: relative;
    padding-left: 30px;
    display: inline-block;
    line-height: 1.35;
}
/* внешний круг */
.custom-radio span::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    border: 2px solid #6c757d;
    border-radius: 50%;
    background: #fff;
}
/* внутренняя точка */
.custom-radio input[type="radio"]:checked + span::after {
    content: "";
    position: absolute;
    left: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #6c757d;
}
/* лёгкий эффект нажатия (мобилки) */
.custom-radio label:active {
    opacity: 0.7;
}
nav ul.list-group-flush > li {
    border-bottom: 1px solid #bbb;
    padding: 0.75rem 1rem;
    transition: background-color 0.2s ease;
}
nav ul.list-group-flush > li:last-child {
    border-bottom: none; /* убираем границу у последнего пункта */
}
nav ul.list-group-flush > li:hover {
    /* Меняем только фон для всего пункта списка */
    background-color: #f0f8ff;
    /* УДАЛЕНО: color: #003366; -- это не сработает для ссылки */
}
/* 💡 НОВЫЙ СЕЛЕКТОР: Меняем цвет ссылки, когда наводим на РОДИТЕЛЬСКИЙ <li> */
nav ul.list-group-flush > li:hover a {
    color: #003366; /* Добавляем желаемый более темный цвет для текста */
    text-decoration: underline; /* Добавляем подчеркивание */
}
nav ul.list-group-flush > li a {
    text-decoration: none;
    font-weight: 500;
    color: #0056b3;
    display: block; /* Важно: заставляет ссылку занимать всю ширину <li> */
    transition: color 0.2s ease;
}
hr.custom-separator {
    border: none;
    border-bottom: 0.249rem solid #FFA67F;
    opacity: 0.8;
}
hr.custom-separator-think {
    border: none;
    border-bottom: 0.129rem solid #FFA67F;
    opacity: 0.75;
    width: 237px;
}
.text-orange {color: #FFA67F; opacity: 0.75;}
.unanswered {
    border: 2px solid #dc3545;
    background-color: #fff5f5;
    border-radius: 6px;
    padding: 10px;
}
.footer-link {
    color: #DCEAFC;
    text-decoration: none;
    border-bottom: 1px dashed rgba(116,192,252,0.4);
    transition: all 0.2s ease;
}
.footer-link:hover {
    color: #FFA67F;
    opacity: 0.75;
    border-bottom: 1px solid #FFA67F;
}
@media (max-width: 576px) {
    .row[style*="max-width: 900px"] .col-4 {
        width: 100% !important;
        flex: 0 0 100%;
        max-width: 100%;
        margin-bottom: 1rem;
    }
}
.fancy-line {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin: 25px 0 15px;
    color: #3A73AB;
}
.fancy-line::before,
.fancy-line::after {
    content: "";
    height: 1px;
    flex: 1;
    max-width: 560px;
    /* Затухание только на внешних концах */
    background: linear-gradient(
            to right,
            rgba(58,115,171,0) 0%,
            rgba(58,115,171,0) 10%,
            rgba(58,115,171,1) 30%,
            rgba(58,115,171,1) 100%
    );
}
.fancy-line::after {
    background: linear-gradient(
            to left,
            rgba(58,115,171,0) 0%,
            rgba(58,115,171,0) 10%,
            rgba(58,115,171,1) 30%,
            rgba(58,115,171,1) 100%
    );
}
.fancy-line span {
    letter-spacing: 2px;
    padding: 0 2px;
}
.lang-ru {
    display: inline-block;
    width: 34px;
    height: 25px;
    line-height: 24px;
    background-color: #6c757d; /* темнее = визуально плотнее */
    color: #fff;
    font-weight: 700;
    font-size: 12px;
    border-radius: 2px;
    border: 1px solid #495057;
    text-transform: uppercase;
    text-align: center;
    text-shadow: 1px 1px 1px #000000;
}
.lang-ru:hover {
    background-color: #5a6268;
}
.lang-ru {
    display: inline-block;
    width: 34px;
    height: 24px;
    line-height: 24px;
    background-color: #6c757d; /* темнее = визуально плотнее */
    color: #fff;
    font-weight: 700;
    font-size: 12px;
    border-radius: 2px;
    border: 1px solid #495057;
    text-transform: uppercase;
    text-align: center;
    text-shadow: 1px 1px 1px #000000;
    text-decoration: none;
}
.lang-ru:hover {
    background-color: #5a6268;
}
.green {
    color:#1C6900;
}
.blue {
    color: #1A83BB !important;
}
.red {
    color:#8B0000;
}
.brown {
    color:#A57505;
}
.dark-red {
    color:#000000;
}
.severe {color:#E15160;}
.bg_blue {
    background-color: #1A83BB;
    color:#fff;
    width: 25px;
    height: 25px;
}
.bg_green {
    background-color: #005C00;
    color:#fff;
}
.bg_orange {
    background-color: #AF7800;
    color:#fff;
}
.bg-severe {
    background-color:#E15160;
    color:#fff;
}
.bg_red {
    background-color: #8B0000;
    color:#fff;
    text-align: center; height:15px;
}
.dark_red {
    background-color:#000000;
    color:#fff;
}
.td_middle {
    height:5px;
}
.p_table {
    margin:4px;
    padding:0;
    line-height: 15px;
    color:#fff;
    text-align: center;
    font-size: .8em;
}
.table1 {
    width: 100%;
    table-layout: fixed;
}
.table1 td {
    border-right: 1px solid #fff5f5;
}
.table1 td:last-child {
    border-right: none;
}
.table2 {
    /* Меняем fixed на auto, чтобы колонки подстраивались под содержимое */
    table-layout: auto;
    /* Таблица будет занимать столько места, сколько нужно, но не больше экрана */
    width: auto !important;
    max-width: 100%;
    border-collapse: separate !important;
    border-spacing: 1px !important;
    /* Центрируем таблицу, если она стала узкой */
    margin-left: 0;border-top: 1px dotted #1A83BB;
}
.table2 td:first-child {
    /* Убираем жесткий процент, заменяем на min-width */
    width: auto;
    min-width: 200px;
    text-align: left;
    word-wrap: break-word;
    hyphens: auto;
    line-height: 1.2;
    padding: 5px 15px 5px 0 !important;
    border-bottom: 1px dotted #1A83BB;
}
.table2 td:not(:first-child) {
    /* Для квадратиков оставляем фиксированную небольшую ширину */
    width: 40px;
    text-align: center;
    vertical-align: middle;
    padding: 5px 5px !important;
    border-bottom: 1px dotted #1A83BB;
}
.btn-back-to-top {
    /* Основные размеры и форма */
    width: 60px; /* Достаточно большая для мобильного */
    height: 60px;
    border-radius: 50%; /* Делает её идеально круглой */
    aspect-ratio: 1 / 1; /* Гарантирует пропорции */
    /* Цвета и стиль */
    background-color: transparent; /* Или фон вашей карты */
    color: #1A83BB; /* Ваш синий цвет пунктира таблицы */
    border: 2px dotted #1A83BB; /* Стиль пунктира вашей таблицы */
    /* Центрирование SVG внутри */
    display: flex;
    justify-content: center;
    align-items: center;
    /* Эффекты */
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1); /* Легкая тень для объема */
}
/* Настройка SVG внутри кнопки */
.btn-back-to-top svg {
    width: 28px; /* Размер самой стрелки */
    height: 28px;
    fill: currentColor; /* SVG принимает цвет текста кнопки */
}
/* Эффекты при наведении (для десктопов) */
.btn-back-to-top:hover {
    background-color: #f0f8ff; /* Очень легкий голубой фон */
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}
.height_total {
    height:35px;
}
.border_left {
    border-left: 2px solid #8B0000;
}
.vysledek {
    box-shadow:1px 1px 7px #C7C7C7;
    border-radius: 5px;
    border: 1px solid #CFCFCF;
    padding:0 10px 15px 10px;
    margin-bottom: 30px;
}
.table-symptoms {
    box-shadow:1px 1px 7px #C7C7C7;
    border-radius: 5px;
    -moz-border-radius: 5px;
    -webkit-border-radius: 5px;
    border: 1px solid #CFCFCF;
    padding:0 10px 15px 10px;
    margin-bottom: -5px;
}
.bg-link{background-color: #FEE4DA !important;}
.nav-grid .nav-item-link {
    display: block;
    padding: 5px 0;
    color: #41464B;
    text-decoration: none;
    background-color: #f8f9fa;
    /*transition: all 0.2s;
    font-size: 0.9rem;*/
    margin-top: -8px;
}
.nav-grid .nav-item-link:hover {
    background-color: #e9ecef;
    color: #3A73AB;
    text-decoration: underline !important;
}
/* Состояние активной страницы (добавляйте через PHP) */
.nav-grid .active-link {
    background-color: #fff !important;
    color: #3A73AB !important;
    font-weight: bold !important;
    /* Убираем нижний бордер, чтобы "открыть" вкладку вниз к контенту */
    border-bottom: 2px solid #fff !important;
    position: relative;
    z-index: 2;
}