/* =========================================
   Первый экран и подбор шин (TZFILTER-20261031)
   ========================================= */
body { overflow-x: clip; } /* 100vw у первого экрана не даёт горизонтальной прокрутки; clip, в отличие от hidden, не ломает sticky-шапку */

/* ---------- первый экран ---------- */
.tz-hero {
    position: relative;
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-top: -1.5rem;          /* съедаем py-4 общего контейнера */
    margin-bottom: 2.5rem;
    min-height: calc(100vh - var(--tz-head, 168px));
    min-height: calc(100svh - var(--tz-head, 168px));
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
    background: #0d0d0d;
}
.tz-hero__bg { position: absolute; inset: 0; overflow: hidden; }
.tz-hero__bg picture, .tz-hero__poster, .tz-hero__video {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block;
}
.tz-hero__video { opacity: 0; transition: opacity .8s ease; transform: scale(1.025); } /* в ролике местами чёрные полосы по 10 px с боков */
.tz-hero__video.is-on { opacity: 1; }
.tz-hero__shade {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.35) 45%, rgba(0,0,0,.7) 100%);
}
.tz-hero__in { position: relative; z-index: 2; padding-top: 2.5rem; padding-bottom: 4.5rem; }
.tz-hero__h { font-weight: 800; font-size: clamp(1.6rem, 1rem + 2.2vw, 3rem); line-height: 1.15; margin: 0 0 .6rem; text-shadow: 0 2px 16px rgba(0,0,0,.5); }
.tz-hero__h span { color: var(--bs-primary); }
.tz-hero__sub { font-size: clamp(1rem, .9rem + .4vw, 1.25rem); margin: 0 0 1.75rem; color: rgba(255,255,255,.85); }
.tz-hero__down {
    position: absolute; left: 50%; bottom: 1.25rem; z-index: 2; transform: translateX(-50%);
    width: 44px; height: 44px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #fff; border: 1px solid rgba(255,255,255,.45); text-decoration: none;
    animation: tz-bob 2.2s ease-in-out infinite;
}
.tz-hero__down:hover { color: #fff; background: rgba(255,255,255,.12); }
@keyframes tz-bob { 0%,100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 6px); } }
@media (prefers-reduced-motion: reduce) { .tz-hero__down { animation: none; } .tz-hero__video { display: none; } }
@media (max-width: 767.98px) {
    .tz-hero { justify-content: flex-start; }
    .tz-hero__in { padding-top: 1.75rem; padding-bottom: 4rem; }
    .tz-hero__sub { margin-bottom: 1.25rem; }
    .tz-hero__shade { background: linear-gradient(180deg, rgba(0,0,0,.6) 0%, rgba(0,0,0,.45) 50%, rgba(0,0,0,.75) 100%); }
}

/* ---------- фильтр: общее ---------- */
.tzf { --tzf-acc: #eb9318; --tzf-acc-h: #d68210; position: relative; }
.tzf-tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 10px; margin-bottom: 12px; }
.tzf-tab {
    border: 0; background: transparent; font-weight: 600; font-size: .95rem;
    padding: 8px 16px; border-radius: 7px; cursor: pointer; white-space: nowrap;
}
.tzf-pane[hidden] { display: none !important; }
.tzf-row { position: relative; }
.tzf-f { position: relative; display: block; margin: 0; cursor: text; min-width: 0; }
.tzf-f__l { display: block; font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #6c757d; margin-bottom: 2px; white-space: nowrap; }
.tzf-x { position: relative; display: block; }
.tzf-in {
    width: 100%; border: 0; outline: 0; background: transparent; padding: 0 22px 0 0;
    font-size: 1.1rem; font-weight: 700; color: #212529; height: 30px; text-overflow: ellipsis;
}
.tzf-in::placeholder { color: #adb5bd; font-weight: 500; }
.tzf-in:disabled { cursor: not-allowed; }
.tzf-f.is-off .tzf-f__l { color: #ced4da; }
.tzf-clr {
    position: absolute; right: 0; top: 50%; transform: translateY(-50%);
    width: 20px; height: 20px; border: 0; border-radius: 50%; padding: 0; line-height: 18px;
    background: #e9ecef; color: #495057; font-size: 15px; display: none; cursor: pointer;
}
.tzf-f.is-set .tzf-clr { display: block; }
.tzf-clr:hover { background: #dee2e6; }
.tzf-list {
    display: none; position: absolute; left: -12px; top: calc(100% + 10px); z-index: 1060;
    min-width: calc(100% + 24px); max-width: 360px; max-height: 300px; overflow-y: auto;
    background: #fff; border-radius: 10px; box-shadow: 0 12px 32px rgba(0,0,0,.22); padding: 6px;
    color: #212529; text-align: left;
}
.tzf-list.is-open { display: block; }
.tzf-list.is-up { top: auto; bottom: calc(100% + 10px); }
.tzf-it { padding: 7px 10px; border-radius: 6px; font-size: .95rem; font-weight: 500; cursor: pointer; white-space: nowrap; display: flex; justify-content: space-between; gap: 12px; }
.tzf-it.is-hi { background: #fff3e0; }
.tzf-it.is-cur { font-weight: 700; color: #9a5700; }
.tzf-it__n { color: #adb5bd; font-size: .8rem; }
.tzf-none { padding: 8px 10px; font-size: .85rem; color: #6c757d; white-space: normal; min-width: 200px; }
.tzf-act { display: flex; }
.tzf-go {
    border: 0; border-radius: 10px; background: var(--tzf-acc); color: #1d232b; font-weight: 700; font-size: 1.05rem;
    padding: 0 22px; min-height: 52px; width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    cursor: pointer; transition: background .15s;
}
.tzf-go:hover, .tzf-go:focus-visible { background: var(--tzf-acc-h); }
.tzf-go:focus-visible { outline: 3px solid rgba(235,147,24,.45); outline-offset: 2px; }
.tzf-go__n:not(:empty) { background: rgba(0,0,0,.18); border-radius: 20px; padding: 1px 9px; font-size: .9rem; }
.tzf-foot { display: flex; align-items: center; gap: 14px; margin-top: 10px; font-size: .9rem; min-height: 1.4em; }
.tzf-reset { border: 0; background: none; padding: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-size: .9rem; }
.tzf-reset[hidden] { display: none; }
.tzf-res:empty { display: none; }
.tzf-res { margin-top: 14px; }
.tzf-res__t { font-weight: 600; margin-bottom: 8px; }
.tzf-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
.tzf-card {
    display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; border-radius: 10px;
    background: #fff; color: #212529; text-decoration: none; border: 1px solid #e9ecef; transition: border-color .15s, box-shadow .15s;
}
.tzf-card:hover { border-color: var(--tzf-acc); box-shadow: 0 4px 14px rgba(0,0,0,.12); color: #212529; }
.tzf-card__s { font-weight: 800; font-size: 1.05rem; }
.tzf-card__n { font-size: .82rem; color: #198754; }
.tzf-card.is-off { opacity: .6; }
.tzf-card.is-off .tzf-card__n { color: #6c757d; }

/* запасная форма до загрузки скрипта */
.tzf-fallback { display: flex; flex-wrap: wrap; gap: 8px; align-items: end; }
.tzf-fallback .form-select { min-width: 110px; }

/* ---------- широкая раскладка: первый экран ---------- */
.tzf--wide { max-width: 1080px; margin: 0 auto; }
.tzf--wide .tzf-tabs { background: rgba(0,0,0,.45); backdrop-filter: blur(6px); }
/* SPEED-20261104: размытие на телефонах дорого при прокрутке */
@media (max-width: 991.98px) { .tzf--wide .tzf-tabs { background: rgba(0,0,0,.62); backdrop-filter: none; } }
.tzf--wide .tzf-tab { color: rgba(255,255,255,.8); }
.tzf--wide .tzf-tab:hover { color: #fff; }
.tzf--wide .tzf-tab.is-on { background: #fff; color: #212529; }
.tzf--wide .tzf-row {
    display: grid; grid-template-columns: repeat(3, minmax(0, .8fr)) minmax(0, 1.25fr) minmax(0, 1.1fr) auto;
    background: #fff; border-radius: 14px; padding: 8px; box-shadow: 0 18px 50px rgba(0,0,0,.35); align-items: stretch;
}
.tzf--wide .tzf-row--auto { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, .6fr) minmax(0, 1.6fr); }
.tzf--wide .tzf-f { padding: 8px 14px; border-radius: 10px; transition: background .15s; }
.tzf--wide .tzf-f + .tzf-f::before { content: ''; position: absolute; left: 0; top: 14px; bottom: 14px; border-left: 1px solid #e9ecef; }
.tzf--wide .tzf-f:hover { background: #f8f9fa; }
.tzf--wide .tzf-f.is-open { background: #fff3e0; }
.tzf--wide .tzf-f.is-open::before, .tzf--wide .tzf-f.is-open + .tzf-f::before { border-color: transparent; }
.tzf--wide .tzf-act { padding-left: 8px; }
.tzf--wide .tzf-go { min-width: 170px; }
.tzf--wide .tzf-foot { color: rgba(255,255,255,.85); justify-content: center; }
.tzf--wide .tzf-reset { color: #fff; }
.tzf--wide .tzf-res__t { color: #fff; text-shadow: 0 1px 8px rgba(0,0,0,.6); }
@media (max-width: 991.98px) {
    .tzf--wide .tzf-row { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 4px; }
    .tzf--wide .tzf-f--season, .tzf--wide .tzf-f--vehicle { grid-column: span 1; }
    .tzf--wide .tzf-f--season::before { display: none; }
    .tzf--wide .tzf-act { padding: 4px 0 0; grid-column: 1 / -1; }
    .tzf--wide .tzf-row--auto { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tzf--wide .tzf-row--auto .tzf-f--year::before { display: none; }
}
@media (max-width: 575.98px) {
    .tzf--wide .tzf-tabs { display: flex; }
    .tzf--wide .tzf-tab { flex: 1; padding: 8px 6px; }
    .tzf--wide .tzf-row { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 6px; }
    .tzf--wide .tzf-f--width, .tzf--wide .tzf-f--profile, .tzf--wide .tzf-f--diameter { grid-column: span 1; }
    .tzf--wide .tzf-row:not(.tzf-row--auto) { grid-template-columns: repeat(6, minmax(0, 1fr)); }
    .tzf--wide .tzf-row:not(.tzf-row--auto) .tzf-f--width,
    .tzf--wide .tzf-row:not(.tzf-row--auto) .tzf-f--profile,
    .tzf--wide .tzf-row:not(.tzf-row--auto) .tzf-f--diameter { grid-column: span 2; }
    .tzf--wide .tzf-row:not(.tzf-row--auto) .tzf-f--season,
    .tzf--wide .tzf-row:not(.tzf-row--auto) .tzf-f--vehicle { grid-column: span 3; }
    .tzf--wide .tzf-f { padding: 8px 10px; }
    .tzf--wide .tzf-in { font-size: 1.05rem; }
    .tzf--wide .tzf-f--vehicle::before, .tzf--wide .tzf-row--auto .tzf-f--year::before { display: block; }
    .tzf--wide .tzf-f--season::before, .tzf--wide .tzf-row--auto .tzf-f--model::before { display: block; }
    .tzf--wide .tzf-row--auto .tzf-f--year::before { display: none; }
    .tzf--wide .tzf-row--auto .tzf-f--engine { grid-column: 1 / -1; }
    .tzf--wide .tzf-row--auto .tzf-f--engine::before { display: none; }
    .tzf--wide .tzf-list { max-height: 240px; }
    .tzf--wide .tzf-f--diameter .tzf-list, .tzf--wide .tzf-f--vehicle .tzf-list,
    .tzf--wide .tzf-f--model .tzf-list { left: auto; right: -12px; }
}

/* ---------- колонка каталога ---------- */
.tzf--side .tzf-tabs { display: flex; background: #f1f3f5; width: 100%; }
.tzf--side .tzf-tab { flex: 1; color: #495057; padding: 7px 6px; font-size: .9rem; }
.tzf--side .tzf-tab.is-on { background: #fff; color: #212529; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.tzf--side .tzf-row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
.tzf--side .tzf-row--auto, .tzf--side .tzf-f--season, .tzf--side .tzf-f--vehicle, .tzf--side .tzf-act { grid-column: 1 / -1; }
.tzf--side .tzf-row--auto { grid-template-columns: 1fr; }
.tzf--side .tzf-f { border: 1px solid #ced4da; border-radius: 8px; padding: 4px 10px 3px; background: #fff; transition: border-color .15s, box-shadow .15s; }
.tzf--side .tzf-f.is-open { border-color: var(--tzf-acc); box-shadow: 0 0 0 3px rgba(235,147,24,.18); }
.tzf--side .tzf-f.is-off { background: #f8f9fa; }
.tzf--side .tzf-f__l { font-size: .66rem; }
.tzf--side .tzf-in { font-size: 1rem; height: 26px; }
.tzf--side .tzf-list { left: -1px; top: calc(100% + 6px); min-width: calc(100% + 2px); }
.tzf--side .tzf-f--diameter .tzf-list { left: auto; right: -1px; }
.tzf--side .tzf-go { min-height: 44px; font-size: 1rem; }
.tzf--side .tzf-foot { color: #6c757d; font-size: .82rem; flex-wrap: wrap; gap: 4px 12px; }
.tzf--side .tzf-reset { color: #212529; font-size: .82rem; }
.tzf--side .tzf-cards { grid-template-columns: 1fr; }
.tzf--side .tzf-card { padding: 8px 12px; }
@media (min-width: 768px) and (max-width: 991.98px) {
    .tzf--side .tzf-row { grid-template-columns: 1fr; }
}

/* логотипы марок (AUTOLOGO-20261031) */
.tzf-logo { flex: 0 0 28px; width: 28px; height: 20px; display: inline-flex; align-items: center; justify-content: center; margin-right: 8px; }
.tzf-logo img, .tzf-sel-logo { max-width: 28px; max-height: 20px; object-fit: contain; }
.tzf-it:has(.tzf-logo) { justify-content: flex-start; }
.tzf-sel-logo { position: absolute; left: 0; top: 50%; transform: translateY(-50%); pointer-events: none; }
.tzf-sel-logo[hidden] { display: none; }
.tzf-f.has-logo .tzf-in { padding-left: 36px; }
