h1{
    font-size: 1.5rem;
}

body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    background-color: #f7f6f1;
}

p {
    color: #6f490f;
    font-weight: bold;
}

header {
    background-color: #ece0b5;
    color: #67430c;
    padding: 10px 30px;
    text-align: center;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

ul {
    padding-inline-start: 0px;
    margin-block-start: 0px;
}

/* Стили для таблицы */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 10px 0;
    font-size: 15px;
    text-align: left;
    border: 1px solid #ddd;
    background-color: #fff;
}

table thead {
    background-color: #ece0b5;
    color: #67430c;
}

table thead th {
    padding: 10px;
    border: 1px solid #ddd;
}

table tbody tr {
    border: 1px solid #ddd;
}

table tbody tr:nth-child(even) {
    background-color: #f9f9f9; /* Светло-серый для четных строк */
}

table tbody tr:nth-child(odd) {
    background-color: #fff; /* Белый для нечетных строк */
}

table tbody tr:hover {
    background-color: #f1f1f1; /* Легкий подсвет при наведении */
    cursor: pointer;
}

table tbody td {
    padding: 10px;
    border: 1px solid #ddd;
    font-size: unset;
}

h2 {
    color: #6f490f;
    margin: 0;
}

.expand-text {
    width: 100%;
}

.container {
    display: flex;
    gap: 20px;
    margin: 20px 5px;
    margin-bottom: 250px;
}

.left-pane {
    flex: 1;
    max-width: 410px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.right-pane {
    flex: 2;
    /* padding: 0 20px; */
    background-color: #f7f6f1;
}

.search-bar {
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-bar input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    transition: border-color 0.3s ease;
}

.search-bar input:focus {
    outline: none;
    border-color: #d78c18;
}



.search-bar button {
    padding: 10px 15px !important;
    border: none !important;
    background-color: #ece0b5;
    color: white !important;
    border-radius: 5px !important;
    cursor: pointer !important;
    transition: background-color 0.3s ease !important;
}

.search-bar button img{
    width: 15px;
}

.search-bar button:hover {
    background-color: #67430c;
}

/* Вложенные списки */
.directory ul {
    list-style: none;
    padding-left: 10px;
    margin: 0;
}

.directory .sublist {
    margin-left: 20px;
    display: none;
}

.directory .sublist.hidden {
    display: none;
}

.directory .sublist.visible {
    display: block;
}

.directory li {
    margin-bottom: 10px 0;
    list-style: none;
}

.directory button {
    background: none;
    border: none;
    color: #67430c;
    cursor: pointer;
    text-align: left;
    padding: 10px;
    font-size: 16px;
    width: 100%;
    transition: background-color 0.3s ease;
    font-weight: bold;
}

.directory button:hover {
    background-color: #f0f0f0;
    border-radius: 5px;
}

.directory .sublist > li {
    padding-left: 20px;
    cursor: pointer;
    color: #67430c;
    font-weight: bold;
    margin: 10px 0;
}

/* Стили для кнопок раскрытия подсписков */
.expandable-button {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    background-color: #fff; /* Фон кнопки */
    color: #333; /* Цвет текста */
    border: 1px solid #ccc; /* Рамка кнопки */
    border-radius: 5px;
    padding: 10px 15px;
    font-size: 16px;
    cursor: pointer;
    position: relative; /* Для корректной работы стрелки */
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

/* Контейнер стрелочки */
.expandable-button .arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s, fill 0.3s;
}

/* Стили SVG внутри стрелочки */
.expandable-button .arrow svg {
    width: 16px;
    height: 16px;
    padding-left: 100px;
    fill: #d78c18; /* Желтоватый цвет стрелочки */
    transition: transform 0.3s, fill 0.3s;
}

/* Стили при наведении */
.expandable-button:hover {
    border-color: #d78c18; /* Изменение цвета рамки */
}

.expandable-button:hover .arrow svg {
    fill: #67430c; /* Изменение цвета стрелочки при наведении */
}

.name {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.name a{
    color: #67430c;
    background: #ece0b5;
    border-radius: 10px;
    padding: 10px;
    text-decoration: unset;
    font-weight: bold;
    text-align: -webkit-center;
}

.title{
    display: flex;
    justify-content: space-between;
    align-items: center;

    a{
        color:#67430c;
        background-color: #ece0b5;
        padding: 10px;
        border-radius: 10px;
        text-decoration: none;
        transition: background-color 0.3s;

        &:hover {
          background-color: #e0d0a0;
        }
    }
}




@media (max-width: 768px) {
    body {
        font-size: 14px;
    }

    table thead th{
        font-size: x-small;
    }

    table tbody td{
        font-size: x-small;
    }

    .container {
        flex-direction: column;
        padding: 10px;
        margin: 0 !important;
        gap: 0 !important;
    }

    .right-pane {
        width: 100%;
        margin-top: 20px;
    }

    /* Делаем левую панель (меню) скрываемой при выборе */
    .left-pane.hidden {
        display: none;
    }

    .back-button {
        display: none;
        background: #67430c;
        color: white;
        border: none;
        padding: 10px;
        font-size: 16px;
        cursor: pointer;
        /* width: 100%; */
        text-align: center;
        margin-top: 20px;
        margin: 20px 0px 0px 10px;
        border-radius: 10px;
    }

    .back-button.visible {
        display: block;
    }

    /* Делаем таблицы адаптивными без прокрутки */
    table {
        width: 100%;
        table-layout: fixed;
        word-wrap: break-word;
    }

    /* Скрываем logo.svg в мобильной версии */
    header img[src*="logo.svg"] {
        display: none;
    }
}

/* Полностью скрываем кнопку "Назад" в десктопной версии */
@media (min-width: 769px) {
    .back-button {
        display: none !important;
    }
}


/* Стили для footer */
footer {
    /* background-color: #f1f1f1; */ /* Светлый фон */
    color: #67430c; /* Темный текст */
    text-align: center; /* Центрируем текст */
    padding: 15px 0;
    /* font-size: 14px; */ /* Размер текста */
    /* border-top: 1px solid #ddd; */ /* Линия сверху */
    border-top: 1px solid #ddd; /* Линия сверху */
    bottom: 0;
    width: 100%; /* Растягиваем на всю ширину */
    z-index: 100; /* Поверх других элементов */
}

/* Для мобильных устройств */
@media (max-width: 768px) {
    footer {
        font-size: 12px;
        padding: 10px 0px;
    }
}
