/* Оптовая витрина AFK.
   Покупатель — профессионал: он знает артикул, заказывает десятками позиций
   и возвращается каждую неделю. Поэтому плотно, табличными цифрами и без
   украшений: всё оформление работает на скорость набора заказа. */

:root {
  --bg: #f3f4f1;
  --surface: #ffffff;
  --ink: #111418;
  --ink-2: #4a545f;
  --ink-3: #87909a;
  --line: #e2e5df;
  --line-2: #cfd4cc;

  /* Тёмная шапка и главный экран */
  --dark: #0d1013;
  --dark-2: #171b20;
  --dark-3: #232930;
  --dark-line: #2c333b;
  --on-dark: #f1f3ee;
  --on-dark-2: #9aa4ae;

  /* Сигнальный цвет бренда. Только заливкой под тёмный текст:
     как цвет букв на белом он не читается */
  --accent: #c8f03c;
  --accent-2: #b5dd26;
  --accent-ink: #141a00;
  --accent-soft: #f2fbd4;

  --ok: #14803f;
  --ok-soft: #e6f4ea;
  --wait: #a8690a;
  --wait-soft: #fbf1dd;
  --danger: #c2392b;
  --danger-soft: #fbe9e6;

  --radius: 10px;
  --radius-sm: 7px;
  --shadow: 0 1px 2px rgba(17, 20, 24, .04), 0 8px 24px rgba(17, 20, 24, .06);
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, "Roboto Mono", monospace;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font: 15px/1.5 "Segoe UI Variable Text", "Segoe UI", -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  /* цифры одной ширины: цены и остатки в столбцах стоят ровно */
  font-variant-numeric: tabular-nums;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: 30px; font-weight: 800; }
h2 { font-size: 22px; font-weight: 750; }
h3 { font-size: 16px; font-weight: 700; }
p { margin: 0 0 12px; }

.wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.link { text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.link:hover { text-decoration-color: var(--ink); }

.icon { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor;
        stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ── Шапка ─────────────────────────────────────────────────────────────── */

.hdr { background: var(--dark); color: var(--on-dark); position: sticky; top: 0; z-index: 40; }
.hdr__top { display: flex; align-items: center; gap: 20px; padding-top: 14px; padding-bottom: 14px; }

/* Знак AFK. Правила обращения с ним:
   — цвет один на весь знак: белый на тёмном, чёрный на светлом. Знак берёт
     цвет текста (`color`), отдельной краски у него нет;
   — задаётся только высота, ширина идёт следом: растягивать знак нельзя;
   — не мельче 30 px по высоте: ниже этого подчёркивание из двух линий
     слипается. Там, где места меньше, ставится буква «A» — как на значке вкладки;
   — вокруг знака свободное поле, ничто не подходит к нему вплотную. */
.logo { display: flex; align-items: center; gap: 14px; flex: none; color: var(--on-dark); }
.logo__svg { display: block; height: 40px; width: auto; }
.logo:hover .logo__svg { opacity: .86; }
.logo__sub { font-size: 11px; line-height: 1.25; text-transform: uppercase; letter-spacing: .09em;
             color: var(--on-dark-2); padding-left: 14px; border-left: 1px solid var(--dark-line); }
.logo--footer .logo__svg { height: 36px; }

.search { flex: 1; min-width: 0; display: flex; align-items: center; position: relative; }
.search .icon { position: absolute; left: 14px; color: var(--ink-3); pointer-events: none; }
.search input {
  flex: 1; min-width: 0; height: 46px; padding: 0 112px 0 44px;
  border: 2px solid transparent; border-radius: var(--radius); background: #fff;
  color: var(--ink); font-size: 15px; outline: none;
}
.search input::placeholder { color: var(--ink-3); }
.search input:focus { border-color: var(--accent); }
.search button {
  position: absolute; right: 5px; height: 36px; padding: 0 18px; border: 0; border-radius: 7px;
  background: var(--dark); color: #fff; font-weight: 650; cursor: pointer;
}
.search button:hover { background: var(--dark-3); }

.hdr__contact { text-align: right; white-space: nowrap; flex: none; }
.hdr__phone { display: block; font-size: 18px; font-weight: 750; letter-spacing: -0.01em; }
.hdr__phone:hover { color: var(--accent); }
.hdr__callback { font-size: 12px; color: var(--on-dark-2); border-bottom: 1px dashed currentColor; }
.hdr__callback:hover { color: var(--accent); }

.hdr__btn {
  display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 14px;
  border: 1px solid var(--dark-line); border-radius: var(--radius);
  white-space: nowrap; flex: none; line-height: 1.2; max-width: 240px;
}
.hdr__btn:hover { border-color: var(--accent); }
.hdr__btn b { display: block; font-size: 14px; font-weight: 650; overflow: hidden; text-overflow: ellipsis; }
.hdr__btn span { display: block; font-size: 12px; color: var(--on-dark-2); }
.hdr__btn > div { min-width: 0; }
.hdr__cart--full { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.hdr__cart--full span { color: var(--accent-ink); opacity: .75; }
.hdr__cart--full:hover { background: var(--accent-2); border-color: var(--accent-2); }

.nav { background: var(--dark-2); border-top: 1px solid var(--dark-line); }
/* Пункты меню расходятся на всю ширину строки, а не жмутся к левому краю:
   каждый получает равную долю свободного места (просьба владельца 09.10.2026) */
.nav__row { display: flex; align-items: center; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.nav__row::-webkit-scrollbar { display: none; }
.nav__item {
  display: flex; align-items: center; justify-content: center; gap: 7px; flex: 1 1 auto;
  padding: 11px 13px; white-space: nowrap;
  font-size: 14px; color: var(--on-dark-2); border-bottom: 2px solid transparent;
}
.nav__item:hover { color: var(--on-dark); }
.nav__item--on { color: var(--on-dark); border-bottom-color: var(--accent); }
.nav__item .icon { width: 17px; height: 17px; }
.nav__mode {
  flex: none; margin-left: 18px; padding: 5px 11px; border-radius: 20px; font-size: 12px; white-space: nowrap;
  background: var(--dark-3); color: var(--on-dark-2);
}
.nav__mode b { color: var(--accent); font-weight: 650; }
.nav__mode a { color: var(--on-dark); border-bottom: 1px dashed var(--on-dark-2); }
.nav__mode a:hover { color: var(--accent); }

/* ── Основное ──────────────────────────────────────────────────────────── */

.main { flex: 1; padding-top: 26px; padding-bottom: 64px; }
.main--flush { padding-top: 0; }

.crumbs { font-size: 13px; color: var(--ink-3); margin-bottom: 10px; }
.crumbs a:hover { color: var(--ink); }
.crumbs span { margin: 0 7px; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
             flex-wrap: wrap; margin-bottom: 18px; }
.page-head .btn { align-self: center; }
.page-head__count { color: var(--ink-2); font-size: 14px; }

.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
                 margin: 48px 0 18px; }
.section-title a { font-size: 14px; color: var(--ink-2); white-space: nowrap; }
.section-title a:hover { color: var(--ink); }

/* ── Кнопки ────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border: 1px solid transparent; border-radius: var(--radius-sm);
  background: var(--ink); color: #fff; font-size: 15px; font-weight: 650; white-space: nowrap;
  cursor: pointer; transition: background .12s, border-color .12s, transform .05s;
}
.btn:hover { background: #2a3038; }
.btn:active { transform: translateY(1px); }
.btn--accent { background: var(--accent); color: var(--accent-ink); }
.btn--accent:hover { background: var(--accent-2); }
.btn--ghost { background: var(--surface); color: var(--ink); border-color: var(--line-2); }
.btn--ghost:hover { background: var(--bg); border-color: var(--ink-3); }
.btn--dark-ghost { background: transparent; color: var(--on-dark); border-color: var(--dark-line); }
.btn--dark-ghost:hover { background: var(--dark-3); border-color: var(--on-dark-2); }
.btn--sm { height: 36px; padding: 0 14px; font-size: 14px; }
.btn--lg { height: 52px; padding: 0 26px; font-size: 16px; }
.btn--wide { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.link-btn { border: 0; background: none; padding: 0; color: var(--ink-2); cursor: pointer;
            text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.link-btn:hover { color: var(--ink); text-decoration-color: var(--ink); }

/* ── Главный экран ─────────────────────────────────────────────────────── */

.hero { background: var(--dark); color: var(--on-dark); position: relative; overflow: hidden; }
.hero::before {
  /* косая сетка — намёк на штамповку кузовной детали; чисто фон */
  content: ''; position: absolute; inset: 0; opacity: .5; pointer-events: none;
  background:
    linear-gradient(115deg, transparent 0 62%, rgba(200, 240, 60, .07) 62% 62.4%, transparent 62.4%),
    linear-gradient(115deg, transparent 0 70%, rgba(200, 240, 60, .05) 70% 70.3%, transparent 70.3%),
    radial-gradient(900px 420px at 88% 0%, rgba(200, 240, 60, .12), transparent 70%);
}
.hero__row { position: relative; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(320px, .75fr);
             gap: 48px; padding-top: 52px; padding-bottom: 56px; align-items: center; }
.hero__eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px;
                 text-transform: uppercase; letter-spacing: .1em; color: var(--accent); margin-bottom: 18px; }
.hero__eyebrow::before { content: ''; width: 22px; height: 2px; background: var(--accent); }
.hero h1 { font-size: clamp(32px, 4.3vw, 54px); font-weight: 850; line-height: 1.04; letter-spacing: -0.035em; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero__lead { margin: 20px 0 28px; font-size: 17px; line-height: 1.55; color: var(--on-dark-2); max-width: 560px; }
.hero__cta { display: flex; gap: 12px; flex-wrap: wrap; }

.stats { display: flex; gap: 36px; margin-top: 40px; padding-top: 26px; border-top: 1px solid var(--dark-line); flex-wrap: wrap; }
.stat b { display: block; font-size: 34px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.stat span { font-size: 13px; color: var(--on-dark-2); }

.quick {
  background: var(--dark-2); border: 1px solid var(--dark-line); border-radius: 14px; padding: 22px;
}
.quick__title { display: flex; align-items: center; gap: 9px; font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.quick__title .icon { color: var(--accent); }
.quick__hint { font-size: 13px; color: var(--on-dark-2); margin-bottom: 14px; }
.quick textarea {
  width: 100%; min-height: 132px; resize: vertical; padding: 12px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--dark-line); background: var(--dark); color: var(--on-dark);
  font-family: var(--mono); font-size: 14px; line-height: 1.6; outline: none;
}
.quick textarea::placeholder { color: #5d6771; }
.quick textarea:focus { border-color: var(--accent); }
.quick__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; flex-wrap: wrap; }
.quick__foot a { font-size: 13px; color: var(--on-dark-2); border-bottom: 1px dashed currentColor; }
.quick__foot a:hover { color: var(--accent); }

/* ── Автомобили ────────────────────────────────────────────────────────── */

.cars { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.car { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 16px 10px; }
.car__brand { display: flex; align-items: baseline; justify-content: space-between; gap: 8px;
              padding-bottom: 10px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.car__brand b { font-size: 17px; font-weight: 750; letter-spacing: -0.01em; }
.car__brand a:hover b { text-decoration: underline; text-underline-offset: 3px; }
.car__brand span { font-size: 12px; color: var(--ink-3); }
.car__model { display: flex; align-items: center; justify-content: space-between; gap: 10px;
              padding: 7px 8px; margin: 0 -8px; border-radius: 6px; font-size: 14px; }
.car__model:hover { background: var(--accent-soft); }
.car__model span { font-size: 12px; color: var(--ink-3); }

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.tile {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color .12s, box-shadow .12s;
}
.tile:hover { border-color: var(--ink); box-shadow: var(--shadow); }
.tile b { font-weight: 650; }
.tile span { font-size: 13px; color: var(--ink-3); }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; counter-reset: step; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; counter-increment: step; }
.step::before { content: '0' counter(step); display: block; font-family: var(--mono); font-size: 13px;
                color: var(--ink-3); margin-bottom: 26px; }
.step h3 { margin-bottom: 6px; }
.step p { margin: 0; font-size: 14px; color: var(--ink-2); }

.cta-band {
  margin-top: 48px; padding: 30px 32px; border-radius: 14px; background: var(--dark); color: var(--on-dark);
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.cta-band h2 { font-size: 24px; }
.cta-band p { margin: 6px 0 0; color: var(--on-dark-2); }

/* ── Фильтр каталога ───────────────────────────────────────────────────── */

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.chip {
  display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 13px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px; font-size: 14px; white-space: nowrap;
}
.chip:hover { border-color: var(--ink-3); }
.chip span { font-size: 12px; color: var(--ink-3); }
.chip--on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip--on span { color: #aab2bb; }

.toolbar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 12px; margin-bottom: 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.toolbar__spacer { flex: 1; }
.select {
  height: 38px; padding: 0 34px 0 12px; border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%234a545f' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 12px center;
  appearance: none; cursor: pointer; font-size: 14px; max-width: 100%;
}
.select:hover { border-color: var(--ink-3); }
.select:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.check { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; user-select: none; }
.check input { width: 18px; height: 18px; accent-color: var(--ink); margin: 0; cursor: pointer; }

.viewsw { display: flex; border: 1px solid var(--line-2); border-radius: var(--radius-sm); overflow: hidden; }
.viewsw a { display: flex; align-items: center; gap: 6px; height: 36px; padding: 0 11px; font-size: 13px; color: var(--ink-2); }
.viewsw a + a { border-left: 1px solid var(--line-2); }
.viewsw a:hover { background: var(--bg); }
.viewsw a.on { background: var(--ink); color: #fff; }
.viewsw .icon { width: 16px; height: 16px; }

/* ── Наличие и цена ────────────────────────────────────────────────────── */

.stock { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; white-space: nowrap; }
.stock::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
.stock--in { color: var(--ok); }
.stock--wait { color: var(--wait); }
.stock--none { color: var(--ink-3); }
.stock b { font-weight: 650; }

.art { font-family: var(--mono); font-size: 12.5px; color: var(--ink-2); letter-spacing: -0.01em; white-space: nowrap; }

.price { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; }
.price b { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; white-space: nowrap; }
.price__tag { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
              padding: 2px 6px; border-radius: 4px; background: var(--accent); color: var(--accent-ink); }
.price__sub { font-size: 12.5px; color: var(--ink-3); margin-top: 1px; }
.price__sub s { text-decoration-thickness: 1px; }
.price__sub a { color: var(--ink-2); border-bottom: 1px dashed var(--line-2); }
.price__sub a:hover { color: var(--ink); border-bottom-color: var(--ink); }
.price__save { color: var(--ok); font-weight: 650; }
.price--none b { font-size: 15px; font-weight: 600; color: var(--ink-2); }

/* ── Плитка товаров ────────────────────────────────────────────────────── */

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(236px, 1fr)); gap: 14px; }

.card {
  display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; transition: border-color .12s, box-shadow .12s;
}
.card:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.card__photo { display: block; aspect-ratio: 4 / 3; background: #fff; border-bottom: 1px solid var(--line); overflow: hidden; }
.card__photo img { width: 100%; height: 100%; object-fit: cover; }
.card__body { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px 14px; flex: 1; }
.card__meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.card__name {
  font-size: 14.5px; font-weight: 600; line-height: 1.32; min-height: 2.64em;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card__name:hover { text-decoration: underline; text-underline-offset: 3px; }
.card__buy { display: flex; gap: 8px; margin-top: auto; padding-top: 6px; }
.card__buy .btn { flex: 1; padding: 0 10px; }

/* Заглушка вместо фото: деталь без снимка всё равно должна выглядеть товаром */
.nophoto {
  width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px; color: var(--ink-3); font-size: 12px;
  background: repeating-linear-gradient(135deg, #f7f8f5 0 14px, #f1f3ee 14px 28px);
}
.nophoto .icon { width: 34px; height: 34px; stroke-width: 1.3; }

/* Счётчик количества */
.qty { display: inline-flex; align-items: stretch; height: 40px; border: 1px solid var(--line-2);
       border-radius: var(--radius-sm); overflow: hidden; background: var(--surface); flex: none; }
.qty button { width: 32px; border: 0; background: none; cursor: pointer; font-size: 17px; color: var(--ink-2); line-height: 1; }
.qty button:hover { background: var(--bg); color: var(--ink); }
.qty input { width: 44px; border: 0; text-align: center; font-weight: 650; outline: none; background: none;
             -moz-appearance: textfield; appearance: textfield; padding: 0; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty:focus-within { border-color: var(--ink); }
.qty--sm { height: 34px; }
.qty--sm button { width: 28px; }
.qty--sm input { width: 40px; }
.qty--lg { height: 52px; }
.qty--lg button { width: 42px; font-size: 20px; }
.qty--lg input { width: 56px; font-size: 17px; }

/* ── Таблица быстрого заказа ───────────────────────────────────────────── */

.table-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow-x: auto; }
.ptable { width: 100%; border-collapse: collapse; font-size: 14px; }
.ptable th {
  position: sticky; top: 0; text-align: left; padding: 10px 12px; font-size: 12px; font-weight: 650;
  text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); background: #fafbf9;
  border-bottom: 1px solid var(--line); white-space: nowrap;
}
.ptable td { padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.ptable tr:last-child td { border-bottom: 0; }
.ptable tbody tr:hover { background: #fafbf8; }
.ptable tr.is-picked { background: var(--accent-soft); }
.ptable tr.is-picked:hover { background: #ecf8c4; }
.ptable .num { text-align: right; white-space: nowrap; }
.ptable__photo { width: 60px; padding-right: 0 !important; }
.ptable__photo a { display: block; width: 48px; height: 48px; border-radius: 6px; overflow: hidden;
                   border: 1px solid var(--line); background: #fff; }
.ptable__photo img { width: 100%; height: 100%; object-fit: cover; }
.ptable__photo .nophoto { font-size: 0; gap: 0; }
.ptable__photo .nophoto .icon { width: 20px; height: 20px; }
.ptable__name { font-weight: 600; min-width: 220px; }
.ptable__name a:hover { text-decoration: underline; text-underline-offset: 3px; }
.ptable__opt { font-weight: 800; font-size: 15px; }
.ptable__retail { color: var(--ink-3); }
.ptable__qty { width: 1%; }

.pickbar {
  position: sticky; bottom: 14px; z-index: 30; margin-top: 14px; padding: 12px 14px 12px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  background: var(--dark); color: var(--on-dark); border-radius: 12px; box-shadow: 0 12px 32px rgba(13, 16, 19, .28);
}
.pickbar[hidden] { display: none; }
.pickbar__text b { font-size: 17px; }
.pickbar__text span { color: var(--on-dark-2); font-size: 14px; }
.pickbar__actions { display: flex; gap: 10px; align-items: center; }
.pickbar .link-btn { color: var(--on-dark-2); text-decoration-color: var(--dark-line); }
.pickbar .link-btn:hover { color: var(--on-dark); }

/* ── Постраничная навигация ────────────────────────────────────────────── */

.pager { display: flex; gap: 6px; margin-top: 24px; flex-wrap: wrap; }
.pager a, .pager span {
  min-width: 40px; height: 40px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 14px;
}
.pager a:hover { border-color: var(--ink); }
.pager .current { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 650; }
.pager .gap { border: 0; background: none; min-width: 20px; padding: 0; color: var(--ink-3); }

.empty {
  padding: 56px 24px; text-align: center; color: var(--ink-2); background: var(--surface);
  border: 1px dashed var(--line-2); border-radius: var(--radius);
}
.empty b { display: block; font-size: 18px; color: var(--ink); margin-bottom: 6px; }
.empty .btn { margin-top: 16px; }

/* ── Карточка товара ───────────────────────────────────────────────────── */

.product { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 36px; align-items: start; }

.gallery__main {
  aspect-ratio: 4 / 3; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; align-items: center; justify-content: center;
}
.gallery__main img { width: 100%; height: 100%; object-fit: contain; }
.gallery__thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; margin-top: 8px; }
.gallery__thumbs button {
  aspect-ratio: 1; padding: 0; border: 2px solid var(--line); border-radius: 8px; overflow: hidden;
  background: #fff; cursor: pointer;
}
.gallery__thumbs button.on, .gallery__thumbs button:hover { border-color: var(--ink); }
.gallery__thumbs img { width: 100%; height: 100%; object-fit: cover; }

/* «Нашли дешевле?» — просьба о цене ниже, под ценой в строке корзины */
.ask { display: block; margin-top: 3px; font-size: 12px; font-weight: 400; color: var(--ink-2);
       text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px;
       white-space: nowrap; }
/* В корзине восемь колонок, а рядом ещё «Итого»: поля ячеек чуть уже, чтобы
   таблица с пятизначными ценами помещалась без прокрутки вбок */
.ptable--cart th, .ptable--cart td { padding-left: 9px; padding-right: 9px; }
.ptable--cart .ptable__name { min-width: 180px; }
.ask:hover { color: var(--ink); text-decoration-color: currentColor; }
.ask--set { color: var(--ok); font-weight: 600; text-decoration-style: dashed; }
.ask[aria-expanded="true"] { color: var(--ink); text-decoration-color: currentColor; }
.ask-mark { color: var(--ok); font-weight: 600; }
/* Форма под строкой корзины: раскрывается по ссылке, покупатель остаётся в корзине */
.ask-row[hidden] { display: none !important; }
.ptable .ask-row td { padding: 0; background: #fafbf8; }
.askbox { padding: 14px 16px 16px; }
.askbox__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 10px; }
.askbox__head b { font-size: 15px; }
.askbox__head span { font-size: 13px; color: var(--ink-2); }
.askbox__fields { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 14px; }
.askbox__fields label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 650; }
.askbox__fields input { height: 36px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: var(--radius-sm);
                        background: var(--surface); font: inherit; font-weight: 400; color: var(--ink); outline: 0; }
.askbox__fields input:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(200, 240, 60, .45); }
.askbox__fields input.is-wrong { border-color: var(--danger); }
.askbox__price { flex: 0 0 170px; }
.askbox__source { flex: 1 1 240px; }
.askbox__price input, .askbox__source input { width: 100%; }
.askbox__fields .link-btn { height: 36px; }
.askbox__error { margin-top: 8px; font-size: 13px; font-weight: 600; color: var(--danger); }
.askbox__hint { margin-top: 10px; font-size: 12.5px; color: var(--ink-3); }
.ask-answer { margin-top: 3px; font-size: 12px; font-weight: 400; color: var(--ink-2); white-space: normal; }
.ask-answer--agreed, .ask-answer--countered { color: var(--ok); }
.ask-rules { margin: 18px 0 0; padding-left: 18px; font-size: 13.5px; color: var(--ink-2); }
.ask-rules li + li { margin-top: 4px; }

/* «Оповестить о наличии» — вместо «В корзину» у товара, которого нет на складе */
.notify { margin: 0; }
.notify--done { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--ok); }
.notify--done .icon { width: 17px; height: 17px; }
.notify .icon { width: 17px; height: 17px; }
.card__buy--none { display: block; }
.card__buy--none .btn { height: 40px; }
.buybox__form .notify, .buybox__form > .notify { flex: 1; }
.notify-product { display: flex; align-items: center; gap: 14px; margin: 16px 0; padding: 12px;
                  border: 1px solid var(--line); border-radius: var(--radius-sm); }
.notify-product img { width: 88px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; flex: none; }
.ptable__row--none td { background: var(--bg); }
.ptable__row--none .ptable__name a, .ptable__row--none .art { color: var(--ink-2); }

/* Под фотографиями: парная деталь или набор «двери, капот, багажник» */
.mates { margin-top: 22px; }
.mates__title { font-size: 16px; font-weight: 750; margin-bottom: 10px; }
.mate { display: flex; align-items: center; gap: 14px; padding: 10px; margin-top: 8px;
        background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.mate:hover { border-color: var(--line-2); }
.mate__photo { width: 96px; aspect-ratio: 4 / 3; flex: none; border-radius: var(--radius-sm);
               overflow: hidden; background: #fff; border: 1px solid var(--line); }
.mate__photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mate__photo .nophoto { height: 100%; font-size: 0; }
.mate__info { flex: 1; min-width: 0; }
.mate__name { display: block; font-weight: 650; line-height: 1.3; }
.mate__name:hover { text-decoration: underline; text-underline-offset: 3px; }
.mate__meta { display: flex; align-items: center; gap: 4px 12px; flex-wrap: wrap; margin-top: 5px; }
.mate__price { flex: none; text-align: right; white-space: nowrap; }
.mate__price b { display: block; font-size: 18px; font-weight: 800; letter-spacing: -0.02em; }
.mate__buy { display: flex; align-items: center; gap: 8px; flex: none; }
.mate__buy .btn { height: 34px; }

.product__head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.product h1 { font-size: 28px; margin-bottom: 18px; }
.brandtag { font-size: 12px; font-weight: 750; letter-spacing: .06em; padding: 3px 8px; border-radius: 5px;
            background: var(--ink); color: #fff; }

.buybox { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; }
.buybox__price { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.buybox__price b { font-size: 40px; font-weight: 850; letter-spacing: -0.035em; line-height: 1; }
.buybox__price small { font-size: 14px; color: var(--ink-2); }
.buybox__rows { margin: 16px 0 0; border-top: 1px solid var(--line); }
.buybox__row { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0;
               border-bottom: 1px solid var(--line); font-size: 14px; }
.buybox__row span:first-child { color: var(--ink-2); }
.buybox__row b { font-weight: 700; }
.buybox__stock { margin: 16px 0; font-size: 15px; }
.buybox__stock .stock { font-size: 15px; }
.buybox__form { display: flex; gap: 10px; }
.buybox__form .btn { flex: 1; }
.buybox__note { margin: 14px 0 0; font-size: 13px; color: var(--ink-2); }

.lockbox {
  margin-top: 14px; padding: 16px 18px; border-radius: var(--radius); background: var(--dark); color: var(--on-dark);
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.lockbox b { display: block; font-size: 15px; }
.lockbox span { font-size: 13px; color: var(--on-dark-2); }

.props { width: 100%; border-collapse: collapse; margin: 22px 0 0; font-size: 14px; }
.props td { padding: 9px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.props td:first-child { color: var(--ink-2); width: 42%; }

.fit { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* ── Корзина и заявки ──────────────────────────────────────────────────── */

.layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.panel--pad { padding: 20px; }
.panel__title { font-size: 16px; font-weight: 700; margin-bottom: 14px; }

.summary { position: sticky; top: 132px; }
.summary__row { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; font-size: 14px; }
.summary__row span:first-child { color: var(--ink-2); }
.summary__total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
                  padding: 14px 0; margin-top: 6px; border-top: 1px solid var(--line); }
.summary__total b { font-size: 26px; font-weight: 850; letter-spacing: -0.03em; }
.summary .btn { margin-top: 8px; }
.summary__note { margin: 12px 0 0; font-size: 13px; color: var(--ink-2); }
.summary__item { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0;
                 border-bottom: 1px solid var(--line); font-size: 14px; }
.summary__item:last-of-type { border-bottom: 0; }

.badge { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 20px;
         font-size: 12px; font-weight: 600; background: var(--bg); color: var(--ink-2); white-space: nowrap; }
.badge--new { background: var(--wait-soft); color: var(--wait); }
.badge--confirmed, .badge--paid, .badge--shipped { background: var(--ok-soft); color: var(--ok); }
.badge--invoiced { background: var(--accent-soft); color: #4d6400; }
.badge--cancelled { background: var(--danger-soft); color: var(--danger); }
.badge--opt { background: var(--accent); color: var(--accent-ink); }

.remove { border: 0; background: none; width: 32px; height: 32px; border-radius: 6px; cursor: pointer;
          color: var(--ink-3); display: inline-flex; align-items: center; justify-content: center; }
.remove:hover { background: var(--danger-soft); color: var(--danger); }
.remove .icon { width: 17px; height: 17px; }

/* ── Кабинет ───────────────────────────────────────────────────────────── */

.acc { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 14px; margin-bottom: 28px; }
.acc--even { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: start; }
.acc__card { padding: 22px; }
.acc__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.acc__head .panel__title { margin-bottom: 0; }
/* Контакты: подпись слева, значение справа */
.facts { display: grid; grid-template-columns: auto 1fr; gap: 9px 18px; margin: 0; font-size: 14.5px; }
.facts dt { color: var(--ink-2); }
.facts dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
/* Адреса доставки */
.places { list-style: none; margin: 0; padding: 0; }
.places__item { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px;
                padding: 12px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.places__item:first-child { border-top: 0; padding-top: 0; }
.places__item:last-child { padding-bottom: 0; }
.places__text { min-width: 0; overflow-wrap: anywhere; }
.places__text .badge { margin-left: 6px; height: 20px; padding: 0 8px; font-size: 11px; vertical-align: 2px; }
.places__actions { display: flex; align-items: center; gap: 12px; flex: none; }
.places__actions form { margin: 0; }
.acc__card--dark { background: var(--dark); color: var(--on-dark); border-color: var(--dark); }
.acc__card--dark .muted { color: var(--on-dark-2); }
.acc__name { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; margin: 6px 0 4px; }
.acc__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.acc__list { margin: 0; padding: 0; list-style: none; }
.acc__list li { display: flex; gap: 10px; padding: 7px 0; font-size: 14px; }
.acc__list .icon { color: var(--ok); width: 18px; height: 18px; margin-top: 2px; }

/* ── Формы ─────────────────────────────────────────────────────────────── */

.narrow { max-width: 460px; margin: 0 auto; }
.auth { display: grid; grid-template-columns: minmax(0, 460px) minmax(0, 1fr); gap: 40px; align-items: start;
        max-width: 1000px; margin: 0 auto; }
.form .field { margin-bottom: 15px; }
.form label { display: block; margin-bottom: 5px; font-size: 13.5px; font-weight: 650; }
.form input[type="text"], .form input[type="email"], .form input[type="password"],
.form input[type="tel"], .form input[type="number"], .form textarea {
  width: 100%; padding: 11px 13px; border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  background: var(--surface); outline: none;
}
.form input:focus, .form textarea:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(200, 240, 60, .45); }
.form textarea { resize: vertical; min-height: 96px; }
.form textarea.mono { font-family: var(--mono); font-size: 14px; line-height: 1.6; }
.form input[type="file"] { width: 100%; padding: 14px; border: 1px dashed var(--line-2); border-radius: var(--radius-sm);
                           background: var(--bg); cursor: pointer; }
.field__hint { font-size: 12.5px; color: var(--ink-3); margin-top: 4px; }
/* Пароль с кнопкой-глазом справа (app.js) */
.pass { position: relative; display: block; }
.form .pass input[type] { padding-right: 46px; }
.pass__eye { position: absolute; top: 50%; right: 6px; transform: translateY(-50%); width: 34px; height: 34px;
             display: grid; place-items: center; padding: 0; border: 0; border-radius: 8px;
             background: transparent; color: var(--ink-3); cursor: pointer; }
.pass__eye:hover, .pass__eye:focus-visible { color: var(--ink); background: var(--bg); }
.pass__eye svg { width: 20px; height: 20px; }
input::-ms-reveal { display: none; }   /* свой глаз у Edge — второй был бы лишним */
.form__consent { margin: 12px 0 0; font-size: 12.5px; line-height: 1.45; color: var(--ink-2); text-align: center; }
.form__consent a { text-decoration: underline; text-underline-offset: 2px; }
.form__consent a:hover { color: var(--ink); }
.field__error { font-size: 13px; color: var(--danger); margin-top: 4px; font-weight: 600; }
.field--error input, .field--error textarea { border-color: var(--danger); }
.field--check label { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 13.5px; cursor: pointer; }
.field--check input { width: 18px; height: 18px; margin: 2px 0 0; flex: none; accent-color: var(--ink); }

.radios { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.radio { position: relative; display: block; padding: 12px 14px; border: 1px solid var(--line-2);
         border-radius: var(--radius-sm); cursor: pointer; background: var(--surface); }
.radio input { position: absolute; opacity: 0; }
.radio b { display: block; font-size: 14px; }
.radio span { font-size: 13px; font-weight: 400; color: var(--ink-2); }
.radios--stack { grid-template-columns: 1fr; }
.radio:has(input:checked) { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); background: var(--accent-soft); }

.or { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--ink-3); font-size: 13px; }
.or::before, .or::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* ── Сообщения ─────────────────────────────────────────────────────────── */

.messages { margin-bottom: 18px; display: grid; gap: 8px; }
.message { padding: 12px 16px; border-radius: var(--radius-sm); border: 1px solid var(--line);
           background: var(--surface); font-size: 14px; }
.message--success { background: var(--ok-soft); border-color: #bfe0c9; color: #0d5a2b; }
.message--error { background: var(--danger-soft); border-color: #f0c5bf; color: #8a2419; }
.message--warning, .message--info { background: var(--wait-soft); border-color: #eeddb5; color: #6d4405; }
.message a { text-decoration: underline; text-underline-offset: 3px; }

.toast {
  position: fixed; right: 20px; bottom: 20px; z-index: 60; max-width: min(380px, calc(100vw - 40px));
  padding: 13px 16px; border-radius: 10px; background: var(--dark); color: var(--on-dark); font-size: 14px;
  box-shadow: 0 14px 36px rgba(13, 16, 19, .32); display: flex; gap: 12px; align-items: center;
  transform: translateY(16px); opacity: 0; pointer-events: none; transition: transform .18s, opacity .18s;
}
.toast.show { transform: none; opacity: 1; pointer-events: auto; }
.toast a { color: var(--accent); font-weight: 650; white-space: nowrap; }
.toast--error { background: var(--danger); }
.toast--plain a { display: none; }

/* ── Тексты ────────────────────────────────────────────────────────────── */

.article { max-width: 760px; background: var(--surface); border: 1px solid var(--line);
           border-radius: var(--radius); padding: 30px 34px; }
.article h1 { margin-bottom: 18px; }
.article p, .article li { font-size: 16px; line-height: 1.65; }
.article h2 { font-size: 20px; font-weight: 750; margin: 30px 0 12px; }
.article ul { margin: 0 0 16px; padding-left: 22px; }
.article li { margin: 8px 0; }
.article li::marker { color: var(--ink-3); }
.article a { text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }

/* Файл для скачивания под текстом страницы: презентация на «О компании» */
.article a.doc { display: flex; align-items: center; gap: 14px; margin-top: 24px; padding: 14px 16px;
                 border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg);
                 text-decoration: none; color: var(--ink); }
.article a.doc:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.doc__icon { display: grid; place-items: center; width: 44px; height: 44px; flex: none;
             border-radius: var(--radius-sm); background: var(--accent); color: var(--accent-ink); }
.doc__text { display: flex; flex-direction: column; gap: 2px; }
.doc__text b { font-size: 16px; }
.doc__text span { font-size: 14px; color: var(--ink-2); }

.map-block { margin-top: 20px; max-width: 760px; }
.map-block__frame { display: block; width: 100%; height: 420px; border: 1px solid var(--line); border-radius: var(--radius); }

/* Страница «Контакты»: слева форма, справа адрес с картой — одной высоты */
.contacts { display: grid; grid-template-columns: minmax(300px, 400px) minmax(0, 1fr); gap: 20px;
            align-items: stretch; max-width: 1120px; margin: 0 auto; }
.place { display: flex; flex-direction: column; min-height: 440px; overflow: hidden;
         background: var(--dark); border-radius: var(--radius); box-shadow: var(--shadow); }
.place__head { display: flex; align-items: center; gap: 14px; padding: 18px 20px; color: var(--on-dark); }
.place__pin { display: grid; place-items: center; width: 44px; height: 44px; flex: none;
              border-radius: 50%; background: var(--accent); color: var(--accent-ink); }
.place__pin svg { width: 22px; height: 22px; }
.place__text { flex: 1; min-width: 0; }
.place__label { font-size: 12px; font-weight: 650; text-transform: uppercase; letter-spacing: .09em;
                color: var(--on-dark-2); margin-bottom: 3px; }
.place__address { font-size: 20px; font-weight: 750; line-height: 1.25; letter-spacing: -0.01em; }
.place__hours { display: flex; align-items: center; gap: 6px; margin-top: 6px;
                font-size: 14px; color: var(--on-dark-2); }
.place__hours svg { width: 16px; height: 16px; flex: none; }
.place__route { flex: none; }
.place__map { display: block; flex: 1; width: 100%; min-height: 340px; border: 0; background: var(--dark-2); }

.address { display: inline-flex; align-items: flex-start; gap: 8px; line-height: 1.3; }
.address__pin { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.address__body { display: flex; flex-direction: column; gap: 3px; }
.hours { display: flex; align-items: flex-start; gap: 8px; line-height: 1.3; }
.hours__icon { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.address__hint { align-self: flex-start; font-size: 12px; border-bottom: 1px dashed currentColor; opacity: .8; }

/* ── Подвал ────────────────────────────────────────────────────────────── */

.footer { background: var(--dark); color: var(--on-dark-2); font-size: 14px; }
.footer__row { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr; gap: 32px; padding-top: 40px; padding-bottom: 36px; }
.footer__title { font-size: 12px; text-transform: uppercase; letter-spacing: .09em; color: var(--on-dark); margin-bottom: 12px; font-weight: 650; }
.footer__list { list-style: none; margin: 0; padding: 0; }
.footer__list li { margin: 7px 0; }
.footer a:hover { color: var(--accent); }
.footer__phone { font-size: 20px; font-weight: 750; color: var(--on-dark); }
.footer__small { font-size: 12.5px; opacity: .8; }
.footer__bottom { border-top: 1px solid var(--dark-line); padding-top: 16px; padding-bottom: 20px; font-size: 12.5px; }

/* ── Узкие экраны ──────────────────────────────────────────────────────── */

@media (max-width: 1250px) {
  /* Корзина: таблице рядом с «Итого» уже тесно — «Итого» уходит под неё */
  .layout--cart { grid-template-columns: 1fr; }
}

@media (max-width: 1120px) {
  .logo__sub { display: none; }
  .hdr__contact { display: none; }
  .hero__row { grid-template-columns: 1fr; gap: 32px; padding-top: 40px; padding-bottom: 44px; }
  .footer__row { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  /* На узком экране шапка в три строки: закреплённой она съедала бы треть экрана */
  .hdr { position: static; }
  .hdr__top { flex-wrap: wrap; gap: 10px 12px; }
  .search { order: 5; flex-basis: 100%; }
  .hdr__btn { margin-left: auto; height: 42px; }
  .hdr__btn + .hdr__btn { margin-left: 0; }
  .hdr__btn span { display: none; }
  .nav__mode { display: none; }
  .product { grid-template-columns: 1fr; gap: 22px; }
  /* В одну колонку: фото, потом цена и «В корзину», и только после них — пара */
  .product__media { display: contents; }
  .product__info { order: 2; }
  .mates { order: 3; margin-top: 0; }
  .layout, .acc, .auth, .contacts { grid-template-columns: 1fr; }
  .place { min-height: 0; }
  .place__map { flex: none; height: 340px; }
  .summary { position: static; }
  h1 { font-size: 24px; }
  .product h1 { font-size: 22px; }
  .buybox__price b { font-size: 32px; }
}

@media (max-width: 620px) {
  .wrap { padding: 0 14px; }
  .places__item { flex-direction: column; gap: 8px; }
  .facts { grid-template-columns: 1fr; gap: 2px 0; }
  .facts dd { margin-bottom: 8px; }
  .mate { flex-wrap: wrap; }
  .mate__photo { width: 76px; }
  .mate__info { flex-basis: calc(100% - 96px); }
  .mate__price { text-align: left; }
  .mate__price b { display: inline; margin-right: 6px; }
  .mate__buy { margin-left: auto; }
  .place__head { flex-wrap: wrap; padding: 16px; }
  .place__address { font-size: 18px; }
  .place__route { width: 100%; }
  .logo__svg { height: 32px; }
  .hdr__btn b { max-width: 96px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card__body { padding: 10px; }
  .card__meta { flex-direction: column; align-items: flex-start; gap: 3px; }
  .card__buy { flex-direction: column; }
  .card__buy .qty { width: 100%; }
  .card__buy .qty input { flex: 1; }
  .price b { font-size: 18px; }
  .toolbar { gap: 8px; }
  .toolbar .select { flex: 1 1 100%; }
  .toolbar__spacer { display: none; }
  .stats { gap: 22px; }
  .stat b { font-size: 28px; }
  .footer__row { grid-template-columns: 1fr; gap: 22px; }
  .article { padding: 22px 18px; }
  .radios { grid-template-columns: 1fr; }
  .cta-band { padding: 24px 20px; }
  .pickbar { bottom: 8px; padding: 12px; }
  .hide-sm { display: none !important; }

  /* Логотип, кабинет и корзина — в одну строку: от кнопки кабинета остаётся значок */
  .hdr__user { padding: 0 12px; }
  .hdr__user > div { display: none; }

  /* Таблица на телефоне складывается в строки-карточки: название во всю
     ширину, под ним артикул, наличие, цена и поле количества. Прокрутка вбок
     прятала бы за краем экрана самое нужное — куда вводить количество. */
  .table-wrap { overflow: visible; }
  .ptable, .ptable tbody { display: block; }
  .ptable thead { display: none; }
  .ptable tr { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
               padding: 12px; border-bottom: 1px solid var(--line); }
  .ptable tr:last-child { border-bottom: 0; }
  .ptable td { padding: 0; border: 0; }
  .ptable__photo, .ptable__retail { display: none; }
  .ptable__name { flex: 1 1 100%; min-width: 0; order: -1; }
  .ptable__qty { width: auto; margin-left: auto; }
  .askbox__price { flex: 1 1 100%; }
}


/* ── Сайт глазами клиента ──────────────────────────────────────────────────────
   Плашка над шапкой, пока сотрудник смотрит витрину с ценами клиента.
   Заметная: иначе менеджер примет чужие цены за общие. */
.viewas { background: var(--accent); color: var(--accent-ink); font-size: 14px; }
.viewas__in { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 8px; padding-bottom: 8px; }
.viewas__back { border: 1px solid var(--accent-ink); background: transparent; color: var(--accent-ink); border-radius: var(--radius-sm); padding: 6px 12px; font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap; }
.viewas__back:hover { background: var(--accent-ink); color: var(--accent); }
