:root {
  --bg: #e8edf2;
  --panel: #ffffff;
  --ink: #12151a;
  --muted: #5a6572;
  --line: #cfd8e3;
  --brand: #0a4d68;
  --brand-dark: #063445;
  --accent: #c4a35a;
  --asphalt: #14181f;
  --ok: #1f8a4c;
  --warn: #b45309;
  --font-body: "Vazirmatn", "Segoe UI", sans-serif;
  --font-display: "Barlow Condensed", "Vazirmatn", sans-serif;
}
* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0; max-width: 100%; overflow-x: clip;
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(196, 163, 90, .14), transparent 55%),
    linear-gradient(180deg, #dfe6ee 0%, var(--bg) 42%, #e4e9ef 100%);
  color: var(--ink);
  font-family: var(--font-body);
}
a { color: var(--brand); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; inset-inline-start: 12px; top: -40px; z-index: 50;
  background: var(--accent); color: #111; padding: 8px 12px; font-weight: 700;
}
.skip-link:focus { top: 12px; }

.site-header {
  position: sticky; top: 0; z-index: 30;
  background: rgba(20, 24, 31, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(196, 163, 90, .28);
  color: #fff;
}
.site-header-inner {
  max-width: 1200px; margin: 0 auto;
  padding: 14px 20px;
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; flex-wrap: wrap;
}
.brand-mark {
  display: grid; gap: 2px; text-decoration: none; color: inherit;
  animation: brand-in .7s ease both;
}
.brand-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.55rem, 2.4vw, 2rem);
  letter-spacing: .04em;
  line-height: 1;
  text-transform: uppercase;
  color: #fff;
}
.brand-tag {
  font-family: "Vazirmatn", "Segoe UI", Tahoma, sans-serif;
  font-size: 12px;
  color: rgba(255,255,255,.72);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}
.header-tools {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
}
.header-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.header-contact-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  text-decoration: none;
  color: #fff;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.06);
  transition: background .2s ease, border-color .2s ease;
}
.header-contact-link:hover {
  background: rgba(196, 163, 90, .16);
  border-color: rgba(196, 163, 90, .5);
  color: #fff;
}
.header-contact-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  flex: 0 0 auto;
}
.header-phone .header-contact-icon {
  background: #1f8a4c;
  color: #fff;
}
.header-telegram .header-contact-icon {
  background: transparent;
}
.header-contact-value {
  font-size: 12px;
  font-weight: 700;
  unicode-bidi: isolate;
  direction: ltr;
}
.site-nav { display: flex; gap: 8px; flex-wrap: wrap; }
.nav-link {
  color: rgba(255,255,255,.78);
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  padding: 8px 12px;
  border-bottom: 2px solid transparent;
  transition: color .2s ease, border-color .2s ease;
}
.nav-link:hover { color: #fff; }
.nav-link.is-active,
.nav-link[aria-current="page"] {
  color: #fff;
  border-bottom-color: var(--accent);
}
.lang-switch { display: flex; gap: 6px; }
.lang-switch button {
  background: transparent;
  color: rgba(255, 255, 255, .85);
  border: 1px solid rgba(255, 255, 255, .24);
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
}
.lang-switch button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #1a1408;
}
.cart-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent);
  color: #1a1408;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}
.cart-badge[hidden] { display: none !important; }
.cart-link.has-items { color: #fff; }
.cart-toast {
  position: fixed;
  inset-inline-end: 16px;
  bottom: 16px;
  z-index: 80;
  background: var(--asphalt);
  color: #fff;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid rgba(196, 163, 90, .45);
  box-shadow: 0 12px 28px rgba(0,0,0,.28);
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  font-weight: 700;
}
.cart-toast.is-visible {
  opacity: 1;
  transform: none;
}
.btn-cart,
.btn-cart-lg {
  background: var(--brand-dark);
  color: #fff;
  border: 0;
  border-radius: 10px;
  padding: 8px 12px;
  font-weight: 700;
  white-space: nowrap;
  font-family: "Vazirmatn", "Segoe UI", Tahoma, sans-serif;
  letter-spacing: 0;
}
.btn-cart {
  padding: 8px 10px;
  font-size: 13px;
  min-width: 3.2rem;
}
.btn-cart-lg { padding: 12px 18px; font-size: 15px; }
.product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  align-items: center;
}
.cell-cart { width: 1%; white-space: nowrap; }
.cart-panel .cart-head { margin-bottom: 12px; }
.cart-panel .cart-head h1 {
  font-family: "Vazirmatn", "Segoe UI", Tahoma, sans-serif;
  letter-spacing: 0;
}
.cart-empty {
  display: grid;
  gap: 16px;
  padding: 28px 18px;
  margin-top: 8px;
  text-align: center;
  justify-items: center;
  border: 1px dashed var(--line);
  border-radius: 14px;
  background: #f7f9fb;
}
.cart-empty > p {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
}
.cart-empty-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}
#cart-body.hidden,
#cart-empty.hidden {
  display: none !important;
}
.cart-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin: 16px 0 8px;
}
.cart-total { margin: 0; font-size: 1.05rem; }
.cart-qty {
  width: 72px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
}
.order-form {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  max-width: 520px;
}
.order-form label { display: grid; gap: 6px; font-weight: 600; }
.order-form input,
.order-form textarea {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
}
.order-form .status.error { color: #8a1f1f; }
.page-cart .hidden { display: none !important; }

.site-footer {
  margin-top: 48px;
  background:
    linear-gradient(180deg, rgba(20,24,31,.96), #0f1318 100%);
  color: #fff;
  border-top: 1px solid rgba(196, 163, 90, .35);
}
.site-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 20px 34px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px 28px;
}
.footer-brand-block { min-width: min(100%, 260px); }
.footer-brand {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  font-size: clamp(1.35rem, 2.2vw, 1.7rem);
  color: #fff;
}
.footer-note {
  margin: 8px 0 0;
  color: rgba(255,255,255,.68);
  font-size: 13px;
}
.footer-owner {
  margin: 14px 0 0;
  color: var(--accent);
  font-weight: 700;
  font-size: 14px;
}
.footer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-action {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 200px;
  padding: 12px 16px;
  border-radius: 12px;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}
.footer-action:hover {
  background: rgba(196, 163, 90, .14);
  border-color: rgba(196, 163, 90, .55);
  transform: translateY(-1px);
}
.footer-action-icon {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #1f8a4c;
  color: #fff;
}
.footer-action-icon svg { display: block; }
.footer-telegram .footer-action-icon {
  background: transparent;
  color: inherit;
  padding: 0;
}
.footer-action-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.footer-action-label {
  color: rgba(255,255,255,.62);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
}
.footer-action-value {
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  unicode-bidi: isolate;
  direction: ltr;
  text-align: start;
}
.footer-phone .footer-action-value { font-variant-numeric: tabular-nums; }
.footer-telegram:hover { border-color: rgba(42, 171, 238, .55); }

.footer-sep { color: var(--muted); font-weight: 400; }

/* Home hero: one composition */
.page-home .site-header {
  position: absolute; inset-inline: 0; top: 0;
  background: linear-gradient(180deg, rgba(10,12,16,.82), rgba(10,12,16,.2));
  border-bottom: 0;
  backdrop-filter: none;
}
.page-home .site-footer { display: none; }
.page-home main { max-width: none; margin: 0; padding: 0; }
.page-home .home-hero-copy {
  padding-top: clamp(150px, 22vh, 200px);
}
.home-hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: #fff;
}
.home-hero-media {
  position: absolute; inset: 0;
  animation: hero-zoom 12s ease-out both;
}
.home-hero-media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 35%;
  transform: scale(1.04);
}
.home-hero-veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(12,16,22,.88) 0%, rgba(12,16,22,.55) 48%, rgba(12,16,22,.28) 100%),
    linear-gradient(0deg, rgba(12,16,22,.75) 0%, transparent 48%);
}
.home-hero-copy {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: clamp(110px, 18vh, 160px) 20px 56px;
  animation: copy-up .8s ease .15s both;
}
.home-brand {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 5vw, 3.4rem);
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
  line-height: .92;
  color: #fff;
  text-shadow: 0 10px 40px rgba(0,0,0,.35);
}
.home-hero-copy h1,
.home-lead {
  font-family: "Vazirmatn", "Segoe UI", Tahoma, sans-serif;
  letter-spacing: 0 !important;
  text-transform: none !important;
  word-break: keep-all;
  overflow-wrap: normal;
}
.home-hero-copy h1 {
  margin: 0 0 12px;
  max-width: 100%;
  font-size: clamp(1.25rem, 2.4vw, 1.85rem);
  font-weight: 700;
  line-height: 1.45;
  white-space: nowrap;
}
.home-lead {
  margin: 0 0 22px;
  max-width: 640px;
  color: rgba(255,255,255,.82);
  font-size: 1.02rem;
  font-weight: 500;
  line-height: 1.6;
  white-space: nowrap;
}
.hero-search {
  display: flex; gap: 8px; flex-wrap: wrap;
  max-width: 640px;
}
.hero-search input {
  flex: 1 1 240px;
  min-width: min(100%, 220px);
  padding: 14px 16px;
  border: 0;
  border-radius: 4px;
  font: inherit;
  font-size: 16px;
  background: rgba(255,255,255,.95);
  color: var(--ink);
}
.hero-search button {
  border-radius: 4px;
  padding: 14px 20px;
  background: var(--accent);
  color: #1a1408;
}
.hero-cta-row { margin-top: 14px; }
.hero-secondary {
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid rgba(196,163,90,.85);
  padding-bottom: 2px;
  transition: color .2s ease, border-color .2s ease;
}
.hero-secondary:hover { color: var(--accent); }
.hero-status { min-height: 1.2em; color: rgba(255,255,255,.8); }

@keyframes brand-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}
@keyframes copy-up {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
@keyframes hero-zoom {
  from { transform: scale(1.08); }
  to { transform: scale(1); }
}

.pager button.active {
  background: var(--brand);
  color: #fff;
}
.grid-thumb {
  width: 56px;
  height: 56px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: block;
  cursor: zoom-in;
}
.grid-thumb.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 12px;
  cursor: default;
}
a.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--brand);
  color: white;
  border: 0;
  border-radius: 10px;
  padding: 12px 16px;
  font-weight: 700;
  text-decoration: none;
}
a.btn.ghost { background: white; color: var(--brand); border: 1px solid var(--brand); }
main { max-width: 1200px; margin: 24px auto; padding: 0 16px 48px; min-width: 0; }
.panel {
  background: var(--panel); border: 1px solid var(--line); border-radius: 14px;
  padding: 20px; margin-bottom: 18px; min-width: 0; max-width: 100%;
  box-shadow: 0 10px 28px rgba(18, 21, 26, .05);
}
.search-panel h1 {
  font-size: clamp(1.4rem, 2vw, 1.75rem);
}
h1, h2 { margin: 0 0 10px; }
.hint, .meta, .status { color: var(--muted); }
.search-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0; }
.search-row input {
  flex: 1 1 220px; min-width: min(100%, 220px); width: 100%;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 16px;
}
button {
  background: var(--brand); color: white; border: 0; border-radius: 10px; padding: 12px 16px; cursor: pointer; font-weight: 700;
}
button:disabled { opacity: .5; cursor: not-allowed; }
button.ghost { background: white; color: var(--brand); border: 1px solid var(--brand); }
.grid-toolbar { display: flex; gap: 16px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.type-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.type-filters .active { background: var(--brand); color: white; border-color: var(--brand); }
.parts-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 14px;
}
.parts-header h2 { margin: 0; }
.parts-header .meta { margin: 0; }
.filter-board {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
  padding: 14px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, #f7fafc 0%, #f3f6fa 100%);
}
.filter-section-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.filter-section-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
}
.filter-section { min-width: 0; }
.filter-grid {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 6px;
  scrollbar-width: thin;
}
.filter-grid::-webkit-scrollbar { height: 8px; }
.filter-grid::-webkit-scrollbar-thumb {
  background: #c5d0e0;
  border-radius: 8px;
}
.refine-hint { margin: 0 0 10px; }
.refine-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}
.refine-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 200px;
  min-width: min(100%, 200px);
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}
.refine-field select {
  width: 100%;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font-size: 15px;
  font-weight: 700;
}
.refine-row .ghost { margin-bottom: 1px; }
.filter-select { max-width: 420px; }
.refine-count { flex: 1 1 100%; margin: 0; font-weight: 800; color: var(--brand-dark); }
.fit-hit { margin-top: 4px; color: var(--brand-dark); font-weight: 800; font-size: 13px; }
.filter-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  width: auto;
  flex: 0 0 auto;
  margin: 0;
  padding: 10px 12px;
  white-space: nowrap;
  text-align: start;
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-weight: 600;
  line-height: 1.35;
  box-shadow: 0 1px 2px rgba(15, 35, 70, .04);
  transition: border-color .15s ease, background .15s ease, color .15s ease, box-shadow .15s ease;
}
.filter-chip:hover,
.filter-chip:focus {
  border-color: var(--brand);
  color: var(--brand-dark);
  background: #eef5ff;
  box-shadow: 0 4px 12px rgba(11, 92, 171, .1);
}
.filter-chip.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  box-shadow: 0 6px 14px rgba(11, 92, 171, .22);
}
.filter-chip-code {
  flex: 0 0 auto;
  min-width: 2.1em;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(11, 92, 171, .08);
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}
.filter-chip.active .filter-chip-code {
  background: rgba(255, 255, 255, .18);
  color: #fff;
}
.filter-chip-name {
  flex: 0 0 auto;
  white-space: nowrap;
}
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: start; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
tbody tr:hover { background: #f7fbff; }
tr.app-match { background: #e8f4ff; }
tr.app-match td { font-weight: 700; }
.subnum { color: var(--muted); font-size: 12px; margin-top: 2px; }
tr.supplier-sep td {
  padding: 10px 14px;
  background: #0b1f3a;
  border-top: 1px solid #071526;
  border-bottom: 1px solid #071526;
  text-align: center;
  vertical-align: middle;
}
tr.supplier-sep span {
  display: block;
  width: 100%;
  color: #ffd400;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.row-filter th { background: #f4f7fb; padding: 6px 8px; }
.row-filter input {
  width: 100%; padding: 7px 8px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px;
}
.pager { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.pager button { padding: 8px 12px; }
.pager-gap { color: var(--muted); padding: 0 4px; }
.yes { color: var(--ok); font-weight: 700; }
.no { color: var(--warn); font-weight: 700; }
.part-type {
  color: var(--brand);
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 2px;
}
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 16px; }
.card { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: #fbfdff; }
.card img { width: 100%; max-height: 220px; object-fit: contain; background: white; border-radius: 8px; }
.hidden { display: none; }
.back-row { margin: 0 0 14px; }
.product-hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: start; }
.gallery-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 420px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.gallery-stage img {
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  transform-origin: center center;
}
.gallery-turn { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.gallery-turn button { padding: 8px 12px; }
.thumbs { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.thumbs img {
  width: 72px; height: 72px; cursor: pointer; object-fit: contain;
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
}
.photo-viewer {
  position: fixed; inset: 0; z-index: 40;
  display: grid; place-items: center; padding: 16px;
  background: rgba(13, 27, 46, .72);
}
.photo-viewer[hidden] { display: none; }
.photo-viewer-panel {
  width: min(920px, 100%);
  background: #fff; border-radius: 14px; padding: 12px;
}
.photo-viewer-stage {
  display: flex; align-items: center; justify-content: center;
  height: min(68vh, 640px);
  background: #f7f9fc; border-radius: 10px; overflow: hidden;
}
.photo-viewer-stage img {
  min-width: 0; min-height: 0;
  max-width: 100%; max-height: 100%; object-fit: contain;
  transform-origin: center center;
}
.photo-viewer-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.photo-viewer-actions button { padding: 8px 12px; }
.kv { width: 100%; }
.kv td, .desc { overflow-wrap: anywhere; }
.kv th { color: var(--muted); font-weight: 600; padding-inline-end: 18px; }
.no-image { height: 240px; display: flex; align-items: center; justify-content: center; border: 1px dashed var(--line); border-radius: 10px; color: var(--muted); }
.eyebrow { color: var(--brand); font-weight: 700; margin-bottom: 4px; }
.status.error { color: #b42318; }
.vehicle-steps { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 16px 0 8px; }
.vehicle-steps .step {
  min-width: 120px; background: #fff; color: var(--brand); border: 1px solid var(--brand);
}
#step-category, #step-group { min-width: 180px; }
.vehicle-steps .step.active { background: var(--brand); color: #fff; }
.picker-search { margin-bottom: 12px; }
.picker-search input {
  width: 100%; max-width: 420px; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: 10px; font-size: 16px;
}
.choice.matched {
  background: var(--brand); color: #fff; border-color: var(--brand);
}
.choice-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 8px;
}
.choice-grid.year-grid {
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 10px;
}
.choice-grid.category-grid,
.choice-grid.group-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  max-width: 1080px;
}
.category-choice {
  text-align: start;
  padding: 12px 14px;
  border-radius: 10px;
}
.category-choice:hover, .category-choice:focus {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}
.choice {
  background: #fff; color: var(--ink); border: 1px solid var(--line); text-align: start;
  padding: 10px 12px; font-weight: 600;
}
.choice:hover, .choice:focus { background: #e8f2ff; border-color: var(--brand); color: var(--brand-dark); }
.year-choice {
  text-align: center;
  padding: 16px 8px;
  font-size: 18px;
  letter-spacing: .04em;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(15, 35, 70, .06);
}
.year-choice:hover, .year-choice:focus {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
  transform: translateY(-1px);
  box-shadow: 0 8px 16px rgba(11, 92, 171, .18);
}
@media (max-width: 800px) {
  .site-header-inner { padding: 12px 14px; align-items: stretch; }
  .header-tools, .site-nav, .lang-switch, .header-contact { width: 100%; }
  .nav-link, .lang-switch button { flex: 1 1 auto; text-align: center; }
  .header-contact-link { flex: 1 1 auto; justify-content: center; }
  .home-hero-copy { padding: 120px 16px 40px; }
  .home-hero-copy h1,
  .home-lead {
    white-space: normal;
  }
  .home-hero-veil {
    background:
      linear-gradient(180deg, rgba(12,16,22,.55) 0%, rgba(12,16,22,.72) 45%, rgba(12,16,22,.88) 100%);
  }
  main { margin: 12px auto; padding: 0 10px 32px; }
  .panel { padding: 14px; }
  h1 { font-size: 1.35rem; }
  .search-row > * { flex: 1 1 100%; }
  .grid-toolbar { align-items: stretch; }
  .grid-toolbar button, .refine-row .ghost { width: 100%; }
  .refine-field, .refine-field select { flex-basis: 100%; }
  .vehicle-steps .step, #step-category, #step-group { min-width: 0; flex: 1 1 calc(50% - 8px); }
  .product-hero { grid-template-columns: 1fr; }
  .gallery-stage { height: 240px; }
  .no-image { max-height: 240px; }
  .photo-viewer-actions button, .gallery-turn button { min-height: 44px; }
  .thumbs { flex-wrap: wrap; }
  .row-filter input, .picker-search input, select { font-size: 16px; }
  .pager button, .filter-chip, .choice, .vehicle-steps .step { min-height: 44px; }
  .table-wrap { overflow: visible; }
  .table-wrap table, .table-wrap thead, .table-wrap tbody { display: block; width: 100%; }
  .table-wrap thead tr:first-child { display: none; }
  .table-wrap thead tr.row-filter {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
  }
  .table-wrap thead tr.row-filter th {
    display: block; padding: 0; border: 0; background: transparent;
  }
  .table-wrap thead tr.row-filter th:not(:has(input)) { display: none; }
  .table-wrap tbody tr {
    display: flex; flex-wrap: wrap; align-items: center;
    border: 1px solid var(--line); border-radius: 12px;
    padding: 8px 12px; margin-bottom: 10px; background: #fff;
  }
  .table-wrap tbody tr:hover { background: #fff; }
  .table-wrap tbody td {
    display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
    flex: 1 1 100%; padding: 6px 0; border: 0; text-align: start; overflow-wrap: anywhere;
  }
  .table-wrap tbody td[data-label]::before {
    content: attr(data-label);
    flex: 0 0 38%;
    color: var(--muted); font-size: 12px; font-weight: 700;
  }
  .table-wrap tbody td.cell-check,
  .table-wrap tbody td.cell-media,
  .table-wrap tbody td.cell-cart {
    flex: 0 0 auto; width: auto; padding: 0;
  }
  .table-wrap tbody td.cell-check { order: -2; }
  .table-wrap tbody td.cell-media { order: -1; margin-inline-start: auto; }
  .table-wrap tbody td.cell-cart { order: 20; margin-inline-start: auto; }
  .table-wrap tbody td.cell-check::before,
  .table-wrap tbody td.cell-media::before,
  .table-wrap tbody td.cell-cart::before,
  .table-wrap tbody td[colspan]::before { content: none; }
  .cart-link { justify-content: center; }
  .table-wrap tbody tr.supplier-sep,
  .table-wrap tbody tr.supplier-sep td {
    display: block; width: 100%; flex: 1 1 100%;
    margin-bottom: 10px; padding: 0; border: 0;
  }
}
@media (max-width: 420px) {
  .table-wrap thead tr.row-filter { grid-template-columns: 1fr; }
  .table-wrap tbody td[data-label] { flex-direction: column; gap: 2px; }
  .table-wrap tbody td[data-label]::before { flex-basis: auto; }
}

.admin-panel .admin-head {
  display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; flex-wrap: wrap;
}
.admin-head-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.admin-login-form {
  display: grid; gap: 12px; max-width: 360px; margin-top: 12px;
}
.admin-login-form label { display: grid; gap: 6px; font-weight: 600; }
.admin-login-form input {
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font: inherit;
}
.admin-filters { margin: 14px 0; }
.admin-price-table th, .admin-price-table td { white-space: nowrap; }
.admin-price-table td.desc { white-space: normal; min-width: 180px; }
.admin-price-table td.num { font-variant-numeric: tabular-nums; font-weight: 700; }
.admin-price-table td.after-tax { color: var(--brand-dark); }
.admin-price-table td.sell-preview { color: #0b5; }
.admin-price-table td.sell-saved { color: var(--brand-dark); }
.admin-price-table td.center { text-align: center; }
.flash { margin: 10px 0; padding: 10px 12px; border-radius: 10px; font-weight: 600; }
.flash.ok { background: #e8f8ef; color: #0a5c2f; }
.flash.err { background: #fdecec; color: #8a1f1f; }
.pricing-rules-form { margin-top: 12px; display: grid; gap: 14px; }
.rules-meta {
  display: flex; gap: 16px; flex-wrap: wrap;
}
.rules-meta label { display: grid; gap: 6px; font-weight: 600; min-width: 180px; }
.rules-meta input, .rules-meta select,
.rules-table input {
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; width: 100%;
  box-sizing: border-box;
}
.rules-table input[type="checkbox"] { width: auto; }
.rules-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.refresh-status {
  margin: 14px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fafafa;
}
.btn.primary {
  background: var(--brand-dark); color: #fff; border-color: var(--brand-dark);
}
