/* Общие настройки */
@font-face {
    font-family: 'Izvestija';
    src: url('../fonts/Izvestija.ttf');
    font-display: swap;
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Rubrica';
    src: url('../fonts/a_RubricaXtCn.ttf');
    font-display: swap;
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Roboto';
    src: url('../fonts/Roboto-VariableFont.ttf');
    font-display: swap;
    font-style: normal;
}


body {
    margin: 0;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f0f0f0;
    color: #333;
    overflow-x: hidden;
    background-image: url(../img/background_full.jpg);
    background-repeat: repeat;
    background-size: cover;
}

.header_title__wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.header_title__lines-left,
.header_title__lines-right {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    /* расстояние между двумя линиями */
    width: 100%;
    /* ширина "зоны" под линии — можно регулировать */
}

/* Сами линии */
.header_title__line {
    height: 3px;
    background-color: #44392d;
    /* цвет линий — замени на нужный */
    width: 100%;
}

.header_text_logo__wrap {
    display: flex;
    gap: 6px;
}

.header_title__text {
    background: url(../img/gastronom_head.png) no-repeat;
    height: 46px;
    width: 158px;
    background-size: contain;
}

.header_title__logo {
    height: 46px;
    width: 46px;
    background: url(../img/N1.png) no-repeat;
    background-size: contain;
}

/* Контейнер книги */
.book_wrap {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 1024px;
    margin: 0 auto;
}

#book {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 10px;
    perspective: 2000px;
    margin: 20px auto;
    width: 1024px;
    height: 720px;
    z-index: 10;
}

/* Стиль страницы — базовый */
.page {
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transform-style: preserve-3d;
    backface-visibility: hidden;
    transition: transform 0.6s cubic-bezier(0.645, 0.045, 0.355, 1), box-shadow 0.3s ease;
    position: relative;
    height: 100%;
    width: 50%;
}

.main_content {
    display: flex;
    position: relative;
}

.store_content.footer {
    display: none;
}

.store_content {
    display: flex;
    flex-direction: column;
    width: 30%;
    max-width: 355px;
    position: absolute;
    left: 0;
    top: 7vh;
}

.store_content__title {
    font-family: Rubrica;
    letter-spacing: 1px;
    font-size: 30px;
    font-weight: 400;
    color: #44392d;
}

.store_content__title span {
    font-family: Izvestija;
    font-size: 35px;
}

.store_content__text {
    font-family: Rubrica;
    letter-spacing: 1px;
    font-size: 30px;
    font-weight: 400;
    color: #44392d;
}

.right_img {
    z-index: 0;
    position: absolute;
    background: url(../img/leafs_right.png) no-repeat;
    background-size: cover;
    height: 100%;
    width: 37%;
    top: 0;
    right: 0;
    opacity: 0.5;
}

.bottom_img {
    display: none;
}

/* Скрытие */
.page.hidden {
    display: none !important;
}

.page.flipping-right {
    transform-origin: left center;
    transform: rotateY(-180deg) translateZ(30px);
    box-shadow: 20px 10px 30px rgba(0, 0, 0, 0.4);
}

.page.flipping-left {
    transform-origin: right center;
    transform: rotateY(180deg) translateZ(30px);
    box-shadow: -20px 10px 30px rgba(0, 0, 0, 0.4);
}

/* Управление */
.controls {
    text-align: center;
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

button {
    font-family: Roboto;
    padding: 12px 24px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    background: #6b983b;
    color: white;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
}

button:hover {
    background: #7db039;
    transform: translateY(-2px);
}

button:active {
    transform: translateY(0);
}

#page-info {
    font-family: Rubrica;
    letter-spacing: 1px;
    font-size: 20px;
    font-weight: 500;
    color: #44392d;
    min-width: 200px;
    text-align: center;
}

.footer_pc {
    display: flex;
}

.footer_pc div {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.footer_tg_logo {
    background: url(../img/tg.png) no-repeat;
    width: 40px;
    height: 40px;
    background-size: contain;
}

.footer_txt {
    font-style: unset;
    font-family: Izvestija;
    font-size: 18px;
    font-weight: 500;
    color: #44392d;
    font-size: 26px;
}

@media (max-width: 1660px) {
    .store_content {
        display: none;
    }

    .footer_pc {
        flex-direction: column;
        align-items: center;
        margin-top: 30px;
    }

    .store_content.footer {
        display: flex;
        position: relative;
        margin-bottom: 100px;
        align-items: flex-start;
        width: 100%;
    }
}

@media (max-width: 1050px) {
    #book {
        width: -webkit-fill-available;
        height: 67vw;
    }

    .right_img {
        display: none;
    }

    .bottom_img {
        position: relative;
        bottom: 0;
        left: 0;
        display: block;
        background: url(../img/background_bottom.png) no-repeat;
        background-size: contain;
        height: 13vw;
        width: 100%;
    }

    .footer_pc div {
        gap: unset;
    }

    .store_content__text {
        font-size: 20px;
    }

}

@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    h2 {
        font-size: 1.4rem;
    }

    #book {
        flex-direction: column;
        align-items: center;
        gap: 15px;
        perspective: none;
        height: 80vh;
    }

    .page {
        width: 95vw;
        max-width: 500px;
        display: none;
    }

    .store_content {
        display: none;
    }

    .footer .store_content__title {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

    .footer .store_content__title span {
        font-size: 26px;
    }

    .page.active {
        display: block;
    }

    .page.flipping-left,
    .page.flipping-right {
        transform: none !important;
    }

    .controls {
        gap: 10px;
    }

    button {
        padding: 10px 20px;
        font-size: 14px;
    }

}

@media (max-width: 500px) {
    #book {
        height: 130vw;
    }

    .controls {
        justify-content: space-between;
    }

    button {
        padding: 10px 10px;
        font-size: 12px;
    }

    #page-info {
        min-width: unset;
    }
}