.site-header .navbar.open {
    display: flex !important;
}

.site-header {
    align-items: center;
    justify-content: space-between;

    font-family: Montserrat, serif;
    line-height: normal;
    position: sticky;
    display: flow-root;
    top: 0;
    width: 100%;
    z-index: 1000;
    background-color: #fff; /* Set the background color as needed */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* Optional: Add a shadow for a subtle effect */
}

.site-header .logo {
    height: auto;
    width: 65px;
    float: left;
    margin-left: 5%;
}

#firm_name {
    display: inline-block;
    text-decoration: none;
    font-weight: bolder;
    float: left;
    color: black;
    vertical-align: middle;
    margin: 12px 0;
    font-size: 32px;
}

.burger {
    border: 0;
    padding: 0;
    background: transparent;
    cursor: pointer;
    display: none;
    float: right;
    margin-right: 5%;
    margin-top: 20px;
    position: relative;
    z-index: 50;
    align-items: center;
    justify-content: flex-end;
    width: 30px;
    height: 18px;
}

.burger::before,
.burger::after {
    content: "";
    position: absolute;
    height: 2px;
    width: 100%;
    background-color: black;
    transition: all 0.3s ease 0s;
}

.burger span {
    height: 2px;
    width: 100%;
    transform: scale(1);
    background-color: black;
}

.burger::before {
    top: 0;
}

.burger::after {
    bottom: 0;
}

/* Добавляем класс active для анимации иконки бургера */
.burger.active span {
    transform: scale(0);
}

.burger.active::before {
    top: 50%;
    transform: rotate(-45deg) translate(0, -50%);
}

.burger.active::after {
    bottom: 50%;
    transform: rotate(45deg) translate(0, 50%);
}


.navbar {
    float: right;
    font-family: Montserrat, serif;
    font-weight: 500;
    font-size: larger;
    color: black;
    text-decoration: none;
    margin-right: 5%;
    margin-top: 20px;
    white-space: nowrap;
}

.navbar a {
    text-decoration: none;
    color: inherit;
    vertical-align: middle; /* Выравнивание элементов по вертикали */
}

.navbar a:not(:last-child)::after {
    display: flex;
    content: "|"; /* Add the separator content */
    margin-left: 10px; /* Adjust the space between link and separator */
    color: black; /* Color of the separator */
    display: inline-block; /* Make sure the separator is inline with the text */
    vertical-align: middle; /* Выравнивание элементов по вертикали */
}

.navbar a:hover {
    font-weight: bold;
}

.navbar a:hover::after {
    font-weight: 500; /* To ensure the separator doesn't get bold on hover */
}

.num-icon {
    max-width: 20px; /* Максимальная ширина логотипа */
    height: auto; /* Сохраняем пропорции */
    vertical-align: middle; /* Выравнивание элементов по вертикали */
}

@media (max-width: 1100px) {
    .site-header .logo {
        width: 55px; /* Максимальная ширина логотипа */
        height: auto; /* Сохраняем пропорции */
        margin-left: 5%; /* Отступ слева от логотипа */
    }

    #firm_name {
        font-size: 26px;
        margin: 16px 0;
    }
}

/* Below this width the complete navigation no longer fits beside the brand. */
@media (max-width: 1399px) {
    .navbar {
        width: 90%;
        float: left;
        clear: both;
        margin-left: 5%;

        display: none;
        flex-direction: column;
        text-align: right;

        margin-bottom: 20px; /* Увеличиваем отступы между элементами */
        font-size: 24px;
        max-height: calc(100dvh - 105px);
        overflow-y: auto;
    }

    .site-header .navbar a[href^="https://max.ru/"],
    .site-header .navbar a[href^="https://t.me/"] {
        display: none;
    }

    .site-header .navbar a[href^="/"] {
        text-transform: uppercase;
    }

    .navbar a:not(:last-child)::after {
        content: none; /* Убираем разделитель для мобильной версии */
        margin-left: 0; /* Убираем отступ разделителя для мобильной версии */
    }

    .burger {
        display: flex;
    }
}

@media (max-width: 768px) {
    .site-header .logo {
        width: 60px; /* Максимальная ширина логотипа */
        height: auto; /* Сохраняем пропорции */
        margin-left: 5%; /* Отступ слева от логотипа */
    }

    #firm_name {
        font-size: 24px;
        margin: 16px 0;
    }

}

@media (max-width: 360px) {
    #firm_name {
        font-size: 20px;
        margin: 18px 0;
    }
}
