/* v2-catalog.css — Redesign v2 (Figma GwYiEL3U7a634ABC0nE4b5, section 4706:2841) */
/* Catalog /katalog/, extras catalog /extras/, extra page /extras/{slug}/. Shared pieces live in v2-base.css. */

/* ---------- Catalog (4707:2854 / 4734:3870) ---------- */

.hh-catalog {
    margin-bottom: calc(120px - var(--hh-footer-gap));
    padding: calc(64px - var(--hh-wrap-extra)) 0 0;
}

.hh-catalog .hh-page-head {
    margin-bottom: 80px;
}

.hh-catalog__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 32px;
}

.hh-catalog__grid .hh-extras-banner {
    order: 1;
}

.hh-catalog__questions {
    margin-top: 80px;
}

.hh-extras-banner {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 32px;
    background: var(--hh-primary);
    color: #FFFFFF;
    text-decoration: none;
}

.hh-extras-banner__tag {
    padding: 6px 12px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-weight: 600;
    line-height: normal;
    text-transform: uppercase;
    white-space: nowrap;
}

.hh-extras-banner__title {
    max-width: 272px;
    margin-top: 28px;
    font-family: 'HH Cormorant', 'Cormorant', serif;
    font-size: 36px;
    font-weight: 500;
    line-height: 40px;
}

.hh-extras-banner__text {
    max-width: 272px;
    margin-top: 16px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    line-height: 21px;
}

.hh-extras-banner__thumbs {
    display: flex;
    align-items: center;
    margin-top: auto;
    padding-top: 24px;
}

.hh-extras-banner__thumb {
    display: block;
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    margin-right: -14px;
    overflow: hidden;
    border: 2px solid var(--hh-primary);
    border-radius: 50%;
    background: #FFFFFF;
}

.hh-extras-banner__thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hh-extras-banner__count {
    padding-left: 22px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    line-height: normal;
    white-space: nowrap;
}

.hh-extras-banner__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 56px;
    margin-top: 24px;
    padding: 0 16px;
    background: #FFFFFF;
    color: var(--hh-primary);
    font-size: 16px;
    font-weight: 600;
    line-height: normal;
    text-transform: uppercase;
    transition: background 0.2s;
}

.hh-extras-banner:hover .hh-extras-banner__btn {
    background: var(--hh-secondary);
}

/* ---------- Extras catalog (4708:3005 / 4735:3995) ---------- */

.hh-extras {
    margin-top: min(0px, calc(40px - var(--hh-wrap-extra)));
    margin-bottom: calc(120px - var(--hh-footer-gap));
    padding: max(0px, calc(40px - var(--hh-wrap-extra))) 0 0;
}

.hh-extras .hh-back {
    margin-bottom: 32px;
}

.hh-extras .hh-page-head,
.hh-extras .hh-info,
.hh-extras .hh-chips {
    margin-bottom: 32px;
}

.hh-extras__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 32px;
}

.hh-extras__empty {
    margin: 0;
    font-size: 16px;
}

.hh-extras__questions {
    display: none;
}

/* ---------- Extra page (4710:3343 / 4736:4291) ---------- */

.hh-extra-page {
    margin-top: min(0px, calc(32px - var(--hh-wrap-extra)));
    margin-bottom: calc(120px - var(--hh-footer-gap));
    padding: max(0px, calc(32px - var(--hh-wrap-extra))) 0 0;
}

.hh-extra-page__main {
    display: grid;
    grid-template-areas:
        "photo head"
        "photo info";
    grid-template-columns: minmax(0, 544px) minmax(0, 612px);
    grid-template-rows: auto 1fr;
    justify-content: space-between;
    column-gap: 40px;
    padding-left: 56px;
}

.hh-extra-page__head {
    grid-area: head;
    padding-top: 44px;
    margin-bottom: 32px;
}

.hh-extra-page__title {
    margin: 0;
    color: var(--hh-black);
    font-family: 'Montserrat';
    font-size: 32px;
    font-weight: 400;
    line-height: normal;
}

.hh-extra-page__size {
    margin: 8px 0 0;
    color: var(--hh-gray);
    font-size: 14px;
    line-height: normal;
}

.hh-extra-page__photo {
    grid-area: photo;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
}

.hh-extra-page__photo > img,
.hh-extra-gallery img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.hh-extra-gallery {
    width: 100%;
    height: 100%;
}

.hh-extra-gallery .swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    height: auto;
}

.hh-extra-gallery__dots {
    position: absolute;
    bottom: 8px;
    left: 50%;
    z-index: 2;
    transform: translateX(-50%);
}

.hh-extra-page__info {
    grid-area: info;
    display: flex;
    flex-direction: column;
    gap: 32px;
    min-width: 0;
}

.hh-extra-page__facts {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.hh-extra-page__facts:empty {
    display: none;
}

.hh-macros {
    display: flex;
    gap: 12px;
}

.hh-macros__item {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    min-width: 0;
    padding: 16px 4px;
    background: var(--hh-light);
    white-space: nowrap;
}

.hh-macros__value {
    color: var(--hh-black);
    font-size: 20px;
    font-weight: 500;
    line-height: normal;
}

.hh-macros__label {
    color: var(--hh-gray);
    font-size: 13px;
    line-height: normal;
}

.hh-extra-page__block {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hh-extra-page__label {
    margin: 0;
    color: var(--hh-gray);
    font-size: 13px;
    font-weight: 600;
    line-height: normal;
    text-transform: uppercase;
}

.hh-extra-page__ingredients {
    margin: 0;
    color: var(--hh-black);
    font-size: 16px;
    line-height: 24px;
}

.hh-extra-page__buy {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding-top: 32px;
    border-top: 1px solid var(--hh-secondary);
}

.hh-extra-page__price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.hh-extra-page__price {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.hh-extra-page__price-label {
    color: var(--hh-gray);
    font-size: 13px;
    line-height: normal;
}

.hh-extra-page__price-value {
    display: flex;
    align-items: baseline;
    gap: 6px;
    color: var(--hh-black);
    font-size: 18px;
    line-height: normal;
}

.hh-extra-page__price-value b {
    color: var(--hh-primary);
    font-size: 40px;
    font-weight: 500;
}

.hh-extra-page__add.is-done {
    background: #1C4466;
}

/* Rations slider */
.hh-rations-slider {
    margin-top: 120px;
}

.hh-rations-slider__head {
    display: flex;
    align-items: flex-end;
    gap: 24px;
    margin-bottom: 40px;
}

.hh-rations-slider__titles {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 12px;
    min-width: 0;
    color: var(--hh-black);
}

.hh-rations-slider__title {
    margin: 0;
    font-family: 'Montserrat';
    font-size: 40px;
    font-weight: 400;
    line-height: normal;
}

.hh-rations-slider__sub {
    margin: 0;
    font-size: 16px;
    line-height: normal;
}

.hh-rations-slider__swiper .swiper-slide {
    width: 336px;
    height: auto;
}

.hh-rations-slider__dots {
    margin-top: 40px;
}

/* Sticky add bar: mobile only */
.hh-sticky-add {
    display: none;
}

/* ---------- Breakpoints ---------- */

@media only screen and (max-width: 1439px) {
    .hh-catalog__grid {
        gap: 24px;
    }

    .hh-extras-banner {
        padding: 24px;
    }

    .hh-extras-banner__title {
        font-size: 32px;
        line-height: 36px;
    }

    .hh-extras-banner__thumb {
        width: 44px;
        height: 44px;
        margin-right: -12px;
    }

    .hh-extras-banner__count {
        padding-left: 18px;
    }

    .hh-extras-banner__btn {
        font-size: 14px;
        white-space: nowrap;
    }

    .hh-extra-page__main {
        padding-left: 0;
    }
}

@media only screen and (max-width: 1199px) {
    .hh-catalog__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .hh-extras__grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media only screen and (max-width: 1023px) {
    .hh-catalog__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hh-questions__btns {
        flex-direction: column;
    }

    .hh-extra-page__main {
        grid-template-areas:
            "head"
            "photo"
            "info";
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto;
        row-gap: 32px;
        margin-top: 32px;
    }

    .hh-extra-page__head {
        padding-top: 0;
        margin-bottom: 0;
    }

    .hh-extra-page__photo {
        max-width: 544px;
        margin: 0 auto;
    }
}

@media only screen and (max-width: 767px) {
    /* Catalog */
    .hh-catalog {
        margin-bottom: calc(64px - var(--hh-footer-gap));
        padding: max(0px, calc(32px - var(--hh-wrap-extra))) 0 0;
    }

    .hh-catalog .hh-page-head {
        margin-bottom: 32px;
    }

    .hh-catalog__grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
    }

    .hh-catalog__grid .hh-extras-banner {
        order: 0;
    }

    .hh-catalog__questions {
        margin-top: 32px;
    }

    .hh-extras-banner {
        gap: 16px;
        padding: 28px 24px 24px;
    }

    .hh-extras-banner__title {
        max-width: 295px;
        margin-top: 0;
        font-size: 32px;
        line-height: 36px;
    }

    .hh-extras-banner__text {
        max-width: 295px;
        margin-top: 0;
    }

    .hh-extras-banner__thumbs {
        margin-top: 0;
        padding-top: 0;
    }

    .hh-extras-banner__thumb {
        width: 48px;
        height: 48px;
        margin-right: -12px;
    }

    .hh-extras-banner__count {
        padding-left: 20px;
    }

    .hh-extras-banner__btn {
        margin-top: 0;
        padding: 0 12px;
        font-size: 16px;
    }

    /* Extras catalog */
    .hh-extras {
        margin-top: min(0px, calc(24px - var(--hh-wrap-extra)));
        margin-bottom: calc(64px - var(--hh-footer-gap));
        padding: max(0px, calc(24px - var(--hh-wrap-extra))) 0 0;
    }

    .hh-extras .hh-back,
    .hh-extras .hh-page-head,
    .hh-extras .hh-info,
    .hh-extras .hh-chips {
        margin-bottom: 24px;
    }

    .hh-extras__grid {
        gap: 12px;
    }

    .hh-extras__questions {
        display: flex;
        margin-top: 24px;
    }

    /* Extra page */
    .hh-extra-page {
        margin-top: min(0px, calc(32px - var(--hh-wrap-extra)));
        margin-bottom: calc(0px - var(--hh-footer-gap));
        padding: max(0px, calc(32px - var(--hh-wrap-extra))) 0 0;
    }

    /* Room for the sticky add bar at the end of the page. */
    body.single-extra .footer {
        padding-bottom: 116px;
    }

    .hh-extra-page__main {
        row-gap: 32px;
        margin-top: 32px;
    }

    .hh-extra-page__title {
        font-size: 32px;
        line-height: 38px;
    }

    .hh-extra-page__photo {
        aspect-ratio: 343 / 336;
        max-width: none;
    }

    .hh-extra-page__info {
        gap: 32px;
    }

    .hh-extra-page__facts {
        gap: 20px;
    }

    .hh-macros {
        gap: 8px;
    }

    .hh-macros__item {
        gap: 2px;
        padding: 10px 2px;
    }

    .hh-macros__value {
        font-size: 16px;
    }

    .hh-macros__label {
        font-size: 11px;
    }

    .hh-extra-page__block {
        gap: 6px;
    }

    .hh-extra-page__label {
        font-size: 12px;
    }

    .hh-extra-page__ingredients {
        font-size: 14px;
        line-height: 21px;
    }

    .hh-extra-page__buy {
        gap: 16px;
        padding-top: 24px;
    }

    .hh-extra-page__price-label {
        font-size: 12px;
    }

    .hh-extra-page__price-value {
        font-size: 16px;
    }

    .hh-extra-page__price-value b {
        font-size: 32px;
    }

    .hh-rations-slider {
        margin: 0 -16px 0 0;
        padding: 64px 0;
    }

    .hh-rations-slider__head {
        margin-bottom: 24px;
        padding-right: 16px;
    }

    .hh-rations-slider__titles {
        gap: 8px;
    }

    .hh-rations-slider__title {
        font-size: 28px;
        line-height: 34px;
    }

    .hh-rations-slider__sub {
        font-size: 14px;
        line-height: 20px;
    }

    .hh-rations-slider .hh-arrows,
    .hh-rations-slider__dots {
        display: none;
    }

    .hh-rations-slider__swiper .swiper-slide {
        width: 281px;
    }

    .hh-rations-slider .hh-ration-card {
        gap: 19.7px;
    }

    .hh-rations-slider .hh-ration-card__img {
        aspect-ratio: 281 / 269;
    }

    .hh-rations-slider .hh-ration-card__btn {
        height: 46px;
        font-size: 13px;
    }

    .hh-rations-slider .hh-ration-card__body {
        gap: 13px;
    }

    .hh-rations-slider .hh-ration-card__text {
        gap: 6.5px;
    }

    .hh-rations-slider .hh-ration-card__name,
    .hh-rations-slider .hh-ration-card__sub,
    .hh-rations-slider .hh-ration-card__price b,
    .hh-rations-slider .hh-ration-card__price strong {
        font-size: 13px;
    }

    .hh-rations-slider .hh-ration-card__price {
        font-size: 11.5px;
    }

    .hh-rations-slider .hh-ration-card__kcal {
        height: 20px;
        padding: 0 5px;
        font-size: 13px;
    }

    /* Sticky add bar (4742:14689 / 4757:14110) */
    .hh-sticky-add {
        position: fixed;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 900;
        display: flex;
        align-items: center;
        gap: 12px;
        height: 84px;
        padding: 16px;
        background: #FFFFFF;
        box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.1);
        transform: translateY(110%);
        transition: transform 0.25s ease-out;
    }

    .hh-sticky-add.is-visible {
        transform: none;
    }

    .hh-sticky-add__info {
        display: flex;
        flex: 1 1 0;
        flex-direction: column;
        min-width: 0;
        white-space: nowrap;
    }

    .hh-sticky-add__price {
        color: var(--hh-primary);
        font-size: 18px;
        font-weight: 500;
        line-height: normal;
    }

    .hh-sticky-add__note {
        color: var(--hh-gray);
        font-size: 12px;
        line-height: normal;
    }

    .hh-sticky-add__btn {
        display: flex;
        flex-shrink: 0;
        align-items: center;
        justify-content: center;
        gap: 8px;
        width: 160px;
        height: 44px;
        padding: 0 14px;
        border: 0;
        background: var(--hh-primary);
        color: #FFFFFF;
        font-family: inherit;
        font-size: 14px;
        font-weight: 600;
        line-height: normal;
        text-transform: uppercase;
        cursor: pointer;
    }

    .hh-sticky-add__btn img {
        display: block;
        width: 16px;
        height: 16px;
    }

    .hh-sticky-add .hh-qty,
    .hh-sticky-add.is-added .hh-sticky-add__btn {
        display: none;
    }

    .hh-sticky-add.is-added .hh-qty {
        display: inline-flex;
    }
}

/* Extra page: «3 × 85 грн.» under the total when more than one is chosen. */
.hh-extra-page__price-calc {
    color: var(--hh-gray);
    font-size: 13px;
    line-height: normal;
}
.hh-extra-page__price-calc[hidden] {
    display: none;
}
