/**
 * Каталог на телефоне, новый вид (до 767 px; планшеты и ПК — как были).
 * Перед товарами было: четыре большие плитки сезонов (417 px) и раскрытый подбор
 * по автомобилю (493 px) — первый товар оказывался на третьем экране.
 * Теперь сезоны — лентой, подбор — по кнопке рядом с «Фильтром».
 */

.kb-car-toggle {
    display: none;
}

@media (max-width: 767px) {
    /* сезоны: лента вместо плиток 2×2 */
    html.kb-catalog-v2 .seasons {
        margin: 0 0 4px;
        padding: 0;
    }

    html.kb-catalog-v2 .seasons-title {
        display: none;
    }

    html.kb-catalog-v2 .seasons > .row {
        display: flex;
        flex-wrap: nowrap;
        gap: 8px;
        margin: 0 -16px;
        padding: 4px 16px 8px;
        overflow-x: auto;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    html.kb-catalog-v2 .seasons > .row::-webkit-scrollbar {
        display: none;
    }

    html.kb-catalog-v2 .seasons > .row > [class*="col-"] {
        flex: none;
        width: auto;
        max-width: none;
        margin: 0;
        padding: 0;
    }

    html.kb-catalog-v2 .seasons .seasons-item {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 8px;
        height: 40px;
        min-height: 0;
        margin: 0;
        padding: 0 14px 0 8px;
        border-radius: 20px;
        background: #F1F3F4;
        color: #051A32;
        text-decoration: none;
    }

    html.kb-catalog-v2 .seasons .seasons-item.is-active {
        background: #79EBDC;
    }

    html.kb-catalog-v2 .seasons .seasons-item__images {
        flex: none;
        width: 26px;
        height: 26px;
        min-height: 0;
        margin: 0;
        padding: 0;
        border-radius: 0;
        background: none;
    }

    html.kb-catalog-v2 .seasons .seasons-item__images-big {
        position: relative;
        width: 26px;
        height: 26px;
        margin: 0;
    }

    html.kb-catalog-v2 .seasons .seasons-item__images-big img {
        width: 26px;
        height: 26px;
        object-fit: contain;
    }

    html.kb-catalog-v2 .seasons .seasons-item__images-small {
        position: absolute;
        top: auto;
        left: auto;
        right: -5px;
        bottom: -5px;
        width: 15px;
        height: 15px;
    }

    html.kb-catalog-v2 .seasons .seasons-item__images-small svg {
        width: 15px;
        height: 15px;
    }

    html.kb-catalog-v2 .seasons .seasons-item__title {
        margin: 0;
        padding: 0;
        font-size: 14px;
        font-weight: 600;
        line-height: 1;
        white-space: nowrap;
    }

    html.kb-catalog-v2 .seasons .seasons-item__title span {
        font-size: inherit;
        font-weight: inherit;
    }

    /* подбор по автомобилю — по кнопке рядом с «Фильтром» */
    html.kb-catalog-v2 .catalog-main__filter-top {
        display: flex;
        align-items: stretch;
        gap: 8px;
    }

    html.kb-catalog-v2 .catalog-main__filter-top .filter-mobile-btn {
        flex: none;
    }

    html.kb-catalog-v2 .kb-car-toggle {
        flex: 1;
        min-width: 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        min-height: 40px;
        padding: 0 14px;
        border: 1.5px solid #051A32;
        border-radius: 10px;
        background: #FFFFFF;
        color: #051A32;
        font: inherit;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
    }

    html.kb-catalog-v2 .kb-car-toggle span {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    html.kb-catalog-v2 .kb-car-toggle svg {
        flex: none;
        transition: transform .2s;
    }

    html.kb-catalog-v2 .kb-car-toggle[aria-expanded="true"] svg {
        transform: rotate(180deg);
    }

    html.kb-catalog-v2 .catalog-filters__product:not(.kb-car-open) {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    html.kb-catalog-v2 .kb-car-toggle svg {
        transition: none;
    }
}
