:root {
    --custom-black: #222222;
    --custom-blue: #91C8E4;
    --custom-white: #FFFFFF;
    --custom-background: #FFFFF2; 
    --custom-green: #b9e491;
    --custom-orange: #f5e6a6;

    --width-main: 1200px;
}

* {
    box-sizing: border-box;
    margin: 0px;
    padding: 0px; 
}

#hideAll
{
   position: fixed;
   left: 0px; 
   right: 0px; 
   top: 0px; 
   bottom: 0px; 
   background-color: white;
   z-index: 99; /* Higher than anything else in the document */

}

html, body {
    font-family: 'Inter', Helvetica, Arial, sans-serif;
    background-color: var(--custom-background);
    color: var(--custom-black);
    height: 100%; /* Добавить */
    margin: 0; /* Добавить */
    padding: 0; /* Добавить */
}


mjx-container {
    overflow-x: auto;
    overflow-y: hidden;
    vertical-align: middle;
}

ol {
    display: block;
    list-style-type: decimal;
    margin-block-start: 1em;
    margin-block-end: 1em;
    margin-inline-start: 0px;
    margin-inline-end: 0px;
    padding-inline-start: 40px;
    unicode-bidi: isolate;
}

ul {
    display: block;
    list-style-type: disc;
    margin-block-start: 1em;
    margin-block-end: 1em;
    margin-inline-start: 0px;
    margin-inline-end: 0px;
    padding-inline-start: 40px;
    unicode-bidi: isolate;
}

#indexul {
    margin-block-start: 0.5em;
    padding-inline-start: 20px;
}

li {
    margin-top: auto;
    line-height: 1.6;
}

code {
    font-size: 16px;
}

p {
    font-size: 16px;
    line-height: 1.6;
    color: var(--custom-black);
    text-align: justify;
}

h1, h2, h3 {
    color: var(--custom-black);
    line-height: 100%;
}

h4 {
    color: var(--custom-black);
}

h2 code {
    font-size: 1.3em;
}

h3 code {
    font-size: 1.3em;
}

.abstract h1 {
    text-align: left;
}

.abstract h2 {
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: var(--custom-black);
    text-align: left;
}

.abstract h3 {
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    text-align: left;
}

.abstract {
    text-align: justify;
    line-height: 1.6;
}


.sections h2 {
    margin-bottom: 0.5rem;
}

.sections h3 {
    margin-bottom: 0.5rem;
}

.a_black {
    color: var(--custom-black);
    text-decoration: none;
}

.a_black:hover {
    text-decoration: underline;
}


/* Link for main content */

.a2:link {
    color: var(--custom-black);
    background-color: transparent;
    text-decoration: none;
}
.a2:visited {
    color: var(--custom-black);
    background-color: transparent;
    text-decoration: none;
}
.a2:hover {
    color: var(--custom-black);
    background-color: transparent;
    text-decoration: none;
}
.a2:active {
    color: var(--custom-black);
    background-color: transparent;
    text-decoration: none;
}

.sentence {
    text-align: justify;
    line-height: 1.6;
}

.image {
    margin-top: 20px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.imgsentence {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.profile-image {
    border: 1px var(--custom-black) solid;
    width: 100%; /* Занимает всю доступную ширину контейнера */
    height: auto; /* Высота подстраивается автоматически для сохранения пропорций */
    object-fit: contain; /* Гарантирует, что изображение сохранит пропорции */
    margin-bottom: 1rem; /* Добавляем небольшой отступ между фото и текстом */
    display: block; /* Блочный элемент вместо flex */
}


.generalpage {
    display: grid;
    grid-template-columns: 2.2fr 0.8fr;
    gap: 1rem;
    align-items: start;
}

.generalpage h2{
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.generalpage h1{
    margin-bottom: 1rem;
}

.problem {
    padding: 10px;
    margin-top: 20px;
    margin-bottom: 20px;
    text-align: justify;
    align-self: center;
    background-color: var(--custom-green);
    border: 1px solid var(--custom-black);
    border-radius: 0px;
    line-height: 1.6;
}

/* .problem ol {
    padding-inline-start: 1rem;
    margin-block-end: 0;
} */

.formulas {
    margin: 20px;
    padding: 10px;
    margin-top: 20px;
    margin-bottom: 20px;
    text-align: justify;
    align-self: center;
    background-color: var(--custom-green);
    border: 1px solid var(--custom-black);
    border-radius: 0px;
    line-height: 1.6;
}

img {
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
}

.python {
    border: var(--custom-black) 1px solid;
    margin-bottom: 20px;
    margin-top: 20px;
}

.privacy_abstract h4 {
    margin-top: 1rem;
}
.privacy_abstract p {
    margin-bottom: 0.16rem;
}


.roles-container {
    display: flex; /* Располагаем элементы в строку */
    gap: 0.5rem; /* Добавляем отступы между ролями */
    flex-wrap: wrap; /* Переносим на новую строку при необходимости */
}

.role {
    display: inline-block; /* Делаем элемент строчно-блочным */
    padding: 5px 10px; /* Внутренние отступы для текста */
    border: 1px solid var(--custom-black); /* Белая обводка */
    font-size: 1rem; /* Размер шрифта */
}

.info {
    display: flex;
    justify-content: space-between;
}


.iconback {
    font-size: 1.2rem;
    color: #222222;
}

/* Стили для ссылок в навигации */
.nav-links a {
    display: flex;
    align-items: baseline;
    text-decoration: none;
    color: var(--custom-black);
    padding: 4px 0;
    
}

.nav-links a:hover {
    text-decoration: underline;
}

.nav-links {
    display: flex;
    flex-direction: column;
}

/* Контейнер для элемента навигации */
.nav-item {
    display: flex;
    align-items: baseline; /* Выравнивание по базовой линии */
}

/* Стиль для номера */
.nav-number {
    display: inline-block;
    flex-shrink: 0; /* Запрет сжатия */
}

/* Стиль для текста */
.nav-text {
    display: inline-block;
    flex-grow: 1; /* Занимает оставшееся пространство */
    margin-left: 5px;
}

hr {
    margin-bottom: 0.5rem;
    margin-top: 0.5rem;
}

.linkpdf {
    display: flex;
    /* align-items: start; */
    justify-content: space-between;
    align-items: center;
}

.linkpdf2 {
    display: flex;
    flex-wrap: wrap; /* Добавлено */
    gap: 0.25rem;    /* по желанию — отступ между иконками */
    align-items: center; /* Центрирует иконки по вертикали */
    justify-content: flex-end;


}

.download-btn {
    display: flex;
    flex-shrink: 0;
    /* margin: 0.25rem;
    margin-top: 0;
    margin-right: 0; */
    /* margin-top: 5px; */

}

#network-container {
    width: 100%;
    height: 430px;
    background-color: #f6f6f6;
    border: 1px solid var(--custom-black);
    position: relative; /* Для абсолютного позиционирования кнопки */

}


/* Стили для информационной панели */
.info-panel {
    margin-top: 10px;
    padding: 10px;
    background-color: #f6f6f6;
    border: 1px solid var(--custom-black);
    display: none;
}

.network-fullscreen-button {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    background-color: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--custom-black);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background-color 0.2s;
}

.network-fullscreen-button:hover {
    background-color: rgba(255, 255, 255, 1);
}

.network-fullscreen-button svg {
    color: var(--custom-black);
}

/* Стили для полноэкранного режима */
#network-container.fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
}

.person {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
}

.person-left {
    max-width: 70%;
}

.person-right {
    margin-top: 1em; 
}


.name {
    margin: 0 0 0.5em 0;
}


.contact {
    margin: 0;
}

/* .MJX-TEX {
    padding-top: 6px !important;; 
    padding-bottom: 6px !important;;
} */

table {
    border-collapse: collapse;
    border: 1px solid var(--custom-black);
    width: 100%;
    max-width: 500px;
    margin: 1rem auto;
  }
  

  thead {
    background-color: #F5E6A6;
    font-weight: bold;
  }
  
  th,
  td {
    border: 1px solid var(--custom-black);
    padding: 8px 12px;
  }

  th {
    text-align: left;
  }

  tbody > tr:nth-of-type(even) {
    background-color: #f6f6f6;
  }
  
