html, body {
    height: 100%;
}
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-size: 1.1rem; /* ~17.6px */
    line-height: 1.6;
}
main.container {
    flex: 1 0 auto;
    max-width: 920px !important;
}
footer {
    flex-shrink: 0;
}
.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;
}
blockquote {
    max-width: 650px;
    font-style: italic;
    background-color: #F0F5F9;
    border: .1em solid #9CBEDA;
    border-radius: 5px;
    padding: .6em;
}
blockquote p {
    font-size: 1.1em;
    font-weight: 500;
}
blockquote footer {
    font-size: 1em;
    text-align: right;
}
.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;
}
.vyskyt {
    display: block;
    margin: 0 auto;
}
.type-nav {
    max-width: 920px;
    margin-left: auto;
    margin-right: auto;
}
.type-legend {
    max-width: 400px;
}
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;
}
.green {
    color:#1C6900;
}
.blue {
    color: #1A83BB !important;
}
.text-blue {
    color: #2E5B89 !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;
}
@media (max-width: 460px) {
    div.col-6 p.custom-radio:not(.bg-secondary-subtle) {
        min-height: 4rem;
        display: flex;
        align-items: center;
    }
    div.col-6 p.custom-radio.bg-secondary-subtle {
        min-height: 5rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}
/* ===== COMPAT ===== */
.compat p {
    padding: 0;
    margin: 0;
}
.h3_compat {
    font-size: 1.1em;
    text-decoration: underline;
    color: #005890;
    line-height: 2.5em;
}
.compat table {
/ /
}
.compat td {
    border-right: 1px solid #005890;
    border-bottom: 1px solid #005890;
    padding: 0;
}
@media screen and (max-width: 800px) {
    .compat p {
        font-size: .9em;
    }
}
@media screen and (max-width: 760px) {
    .compat p {
        font-size: .88em;
    }
}
@media screen and (max-width: 730px) {
    .compat p {
        font-size: .88em;
    }
}
@media screen and (max-width: 700px) {
    .compat p {
        font-size: .85em;
    }
}
@media screen and (max-width: 687px) {
    .compat p {
        font-size: .79em;
    }
}
@media screen and (max-width: 640px) {
    .compat p {
        font-size: .75em;
    }
}
@media screen and (max-width: 620px) {
    .compat p {
        font-size: .72em;
    }
}
@media screen and (max-width: 620px) {
    .compat p {
        font-size: .69em;
    }
}
@media screen and (max-width: 560px) {
    .compat p {
        font-size: .64em;
    }
}
@media screen and (max-width: 500px) {
    .compat p {
        font-size: .57em;
    }
}
@media screen and (max-width: 480px) {
    .compat p {
        font-size: .55em;
    }
}
@media screen and (max-width: 460px) {
    .compat p {
        font-size: .51em;
    }
}
@media screen and (max-width: 440px) {
    .compat p {
        font-size: .49em;
    }
}
@media screen and (max-width: 400px) {
    .compat p {
        font-size: .45em;
    }
}
.bg45A659 {
    background-color: #45A659;
}
.bg35AEEE {
    background-color: #35AEEE;
}
.bgB82B19 {
    background-color: #B82B19;
}
.bgA5CE64 {
    background-color: #A5CE64;
}
.bgFEF840 {
    background-color: #FEF840;
}
.bgFF6633 {
    background-color: #FF6633;
}
.bg286DA6 {
    background-color: #286DA6;
}
.bg2BC06E {
    background-color: #2BC06E;
}
h2 {
    font-size: 1.2em;
    color: #1C6900;
    text-align: center;
    margin-top: 0;
    font-weight: bold;
}
h2 span {
    color: red;
    font-weight: bold;
}
.your_type {
    text-align: center;
    color: #2B4E82;
    font-size: 1.3em;
    line-height: 0.2em;
    margin-top: 25px;
    margin-bottom: 0;
    padding-bottom: 0;
    font-weight: 600;
}
.citat {
    border: 1px solid gray;
    margin: 0;
    padding: 0 1em 0 1em;
    background-color: #EEEEE8;
}
.citat p {
    margin-top: 0;
    font-weight: 600;
}
.compatibility {
    max-width: 600px;
    margin: 0 auto;
}
.hr-text-primary {
    line-height: 1em;
    position: relative;
    outline: 0;
    border: 0;
    color: #2E7589;
    text-align: center;
    height: 1.5em;
    opacity: 1;
}
.hr-text-primary:before {
    content: "";
    background: linear-gradient(to right, transparent, #2E7589, transparent);
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
}
.hr-text-primary:after {
    content: attr(data-content);
    position: relative;
    display: inline-block;
    padding: 0 0.5em;
    line-height: 1.5em;
    color: #2E7589;
    background-color: #ffffff;
    font-weight: 600;
}
.hr-text-success {
    line-height: 1em;
    position: relative;
    outline: 0;
    border: 0;
    color: #198754;
    text-align: center;
    height: 1.5em;
    opacity: 1;
}
.hr-text-success:before {
    content: "";
    background: linear-gradient(to right, transparent, #198754, transparent);
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
}
.hr-text-success:after {
    content: attr(data-content);
    position: relative;
    display: inline-block;
    padding: 0 0.5em;
    line-height: 1.5em;
    color: #157346;
    background-color: #ffffff;
    font-weight: 600;
}
.hr-text-orange {
    line-height: 1em;
    position: relative;
    outline: 0;
    border: 0;
    color: #F49F00;
    text-align: center;
    height: 1.5em;
    opacity: 1;
}
.hr-text-orange:before {
    content: "";
    background: linear-gradient(to right, transparent, #F49F00, transparent);
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
}
.hr-text-orange:after {
    content: attr(data-content);
    position: relative;
    display: inline-block;
    padding: 0 0.5em;
    line-height: 1.5em;
    color: #DF9200;
    background-color: #ffffff;
    font-weight: 600;
}
.hr-text-red {
    line-height: 1em;
    position: relative;
    outline: 0;
    border: 0;
    color: #DC3545;
    text-align: center;
    height: 1.5em;
    opacity: 1;
}
.hr-text-red:before {
    content: "";
    background: linear-gradient(to right, transparent, #DC3545, transparent);
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
}
.hr-text-red:after {
    content: attr(data-content);
    position: relative;
    display: inline-block;
    padding: 0 0.5em;
    line-height: 1.5em;
    color: #C62232;
    background-color: #ffffff;
    font-weight: 600;
}
.fon-print { -webkit-print-color-adjust: exact; print-color-adjust: exact;}
.h2-typ {
    color: #2E7589 !important;
}
.bg-introverze-light {
    background-color: #88B5F7;
}
.bg-intuice-light {
    background-color: #81BAA2;
}
.bg-mysleni-light {
    background-color: #FFD17D;
}
.bg-usuzovani-light {
    background-color: #F1B1B8;
}
.orange {
    color: orange;
}
.bg-orange {
    background-color: #F49F00;
}
