/* Основные стили */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Минимальная высота всей страницы */
}

/* Заголовок */
header {
    background: #35495e;
    color: white;
    padding: 5px;
    text-align: center;
    border-radius: 0;
}

header h1 {
    margin: 0;
    font-size: 24px;
}

/* Кодовые блоки */
pre, code {
    background: #272822 !important; /* Черный фон */
    color: #f8f8f2 !important; /* Белый текст */
    padding: 10px;
    border-radius: 5px;
    display: block;
    font-family: monospace;
    overflow-x: auto;
}

/* Шапка */
.site-header {
    background: #35495e;
    color: white;
    padding: 15px 0;
    text-align: center;
    width: 100%;
}

.site-header h1 {
    margin: 0;
    font-size: 15px;
}

/* Футер */
.site-footer {
    background: #1a252f;
    color: white;
    padding: 10px;
    text-align: center;
    width: 100%;
    margin-top: auto;
    position: relative;
    font-size: 14px;
    box-sizing: border-box;
}

/* Убираем горизонтальную прокрутку */
html, body {
    overflow-x: hidden;
}

/* Стили ссылок в футере */
.site-footer a {
    color: white;
    text-decoration: none;
    padding: 0 5px;
}

.site-footer a:visited {
    color: #ccc;
}

.site-footer a:hover {
    color: #f1f1f1;
}

/* Главное меню */
nav {
    background: #35495e;
    padding: 5px 0;
    text-align: center;
    margin-bottom: 5px;
}

.menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    background: #35495e;
}

.menu li {
    position: relative;
    min-width: 160px; /* Чуть уменьшили ширину */
    text-align: center;
}

.menu a, .menu span {
    display: block;
    padding: 10px 12px;
    font-size: 14px; /* Уменьшенный размер шрифта */
    color: white;
    text-decoration: none;
    font-weight: bold;
    cursor: pointer;
}

.menu a:hover, .menu span:hover {
    background: #2c3e50;
    border-radius: 5px;
}

/* Подменю */
.submenu {
    position: absolute;
    top: 100%;
    left: 0;
    background: #2c3e50;
    padding: 5px 0; /* Добавлен небольшой отступ сверху/снизу */
    min-width: 180px; /* Немного увеличенная ширина */
    display: none;
    border-radius: 5px;
    list-style: none;
    margin: 0;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2); /* Добавлена легкая тень */
}

/* Элементы подменю */
.submenu li {
    width: 100%;
}

/* Стили ссылок в подменю */
.submenu a {
    display: block;
    padding: 8px 15px; /* Комфортный размер отступов */
    font-size: 14px; /* Оптимальный размер шрифта */
    color: #ddd;
    font-weight: normal;
    text-align: left; /* Выравнивание текста по левому краю */
    white-space: nowrap; /* Запрещает перенос строк */
}

/* Эффект при наведении */
.submenu a:hover {
    background: #1a252f;
    color: white;
    border-radius: 3px;
}

/* Показываем подменю при наведении */
.submenu-parent {
    position: relative;
}

.submenu-parent:hover .submenu {
    display: block;
    animation: fadeIn 0.2s ease-in-out; /* Плавное появление */
}

/* Анимация появления */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .submenu {
        position: static;
        display: none;
        width: 100%;
        box-shadow: none;
        background: #2c3e50;
    }

    .submenu-parent:hover .submenu {
        display: block;
    }

    .submenu a {
        padding: 10px 15px;
        font-size: 14px;
    }
}

/* Контейнер */
.container {
    max-width: 1200px;
    width: 90%;
    margin: 20px auto;
    background: white;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    flex-grow: 1;
}

/* Основные стили для секций */
h2 {
    color: #35495e;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 5px;
    overflow: hidden;
}

table, th, td {
    border: 1px solid #ddd;
}

th, td {
    padding: 10px; /* Чуть уменьшенный padding */
    text-align: left;
}

th {
    background: #35495e;
    color: white;
}
/* Основные стили кнопок */
.button {
	background-color: #35495e;
    color: white;
    display: inline-block;
    padding: 10px 20px;
    margin: 5px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    transition: background 0.3s ease, transform 0.1s ease-in-out;
    border: none;
}
.button:hover {
    background-color: #222f3d;
}

/* Основная кнопка */
.button-primary {
    background-color: #005c00;
    color: white;
}

.button-primary:hover {
    background-color: #002900;
}

/* Второстепенная (серая) кнопка */
.button-secondary {
    background-color: #6c757d;
    color: white;
}

.button-secondary:hover {
    background-color: #5a6268;
}

/* Опасная (красная) кнопка */
.button-danger {
    background-color: #dc3545;
    color: white;
}

.button-danger:hover {
    background-color: #c82333;
}

.no-bullets {
    list-style-type: none; /* Убирает маркеры */
    padding-left: 0; /* Убирает отступ */
}

/* Адаптивность */
@media (max-width: 768px) {
    .container {
        width: 100%;
        margin: 0;
        border-radius: 0;
    }

    .menu {
        flex-direction: column;
        align-items: center;
    }

    .menu li {
        width: 100%;
    }

    .menu a {
        text-align: center;
        padding: 8px;
    }

    .submenu {
        position: static;
        display: none;
        width: 100%;
    }

    .submenu-parent:hover .submenu {
        display: block;
    }
}

.card-table {
    border: none !important;
    background: none !important;
    box-shadow: none !important;
}
.card-table th, .card-table td {
    border: none !important;
    background: none !important;
    padding: 7px 10px 7px 0;
    color: #345;
    font-size: 1em;
}
.card-table th {
    font-weight: 500;
    text-align: right;
    width: 120px;
    color: #35495e;
    background: none;
    padding-right: 16px;
    vertical-align: top;
}
.card-table td {
    color: #233;
    background: none;
}
.card-table a {
    color: #225dbb;
    text-decoration: none;
}
.card-table a:hover {
    color: #143d7b;
    text-decoration: underline;
}

