/* ============================================
   UNILUX — основные стили
   ============================================ */

:root {
  --brand: #D11252;
  --brand-dark: #A60D40;
  --brand-soft: #fce4ec;

  --ink: #1A2B32;
  --ink-2: #2a3a4d;
  --muted: #6b7785;
  --muted-2: #98a2b3;
  --line: #e6e9ee;
  --line-2: #eef1f5;

  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-2: #f9fafb;
  --dark-card: #2a3441;

  --success: #16a34a;
  --danger: #dc2626;

  --radius: 20px;
  --radius-sm: 14px;
  --radius-lg: 28px;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.04);
  --shadow: 0 2px 8px rgba(16, 24, 40, 0.06);
  --shadow-lg: 0 8px 24px rgba(16, 24, 40, 0.08);

  --container: 1240px;
  --gap: 20px;

  --header-h: 76px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
*::before, *::after { box-sizing: border-box; }

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

body {
  font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
svg { display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; -webkit-tap-highlight-color: transparent; }
input, textarea, select { font-family: inherit; font-size: inherit; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   ТОПБАР
   ============================================ */
.topbar {
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  padding: 10px 0;
}
.topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.topbar a { color: rgba(255,255,255,0.85); }
.topbar a:hover { color: #fff; }
.topbar-contacts { display: flex; gap: 24px; flex-wrap: wrap; }
.topbar-contacts span { color: rgba(255,255,255,0.65); margin-right: 6px; }
.topbar-note { color: rgba(255,255,255,0.85); }
.topbar-note span { color: rgba(255,255,255,0.6); margin-right: 6px; }

/* ============================================
   ШАПКА
   ============================================ */
.header {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 14px 0;
  min-height: var(--header-h);
}
.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  min-width: 0;
}
.logo img {
  height: 56px;
  width: auto;
  max-width: none;
}
.nav {
  display: flex;
  gap: 28px;
  align-items: center;
  flex: 1;
  min-width: 0;
}
.nav a {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
  padding: 6px 0;
  transition: color 0.15s;
  white-space: nowrap;
}
.nav a:hover, .nav a.active { color: var(--brand); }
.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.cart-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 18px;
  background: var(--brand);
  color: #fff;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  transition: background 0.15s;
  white-space: nowrap;
}
.cart-btn:hover { background: var(--brand-dark); }
.cart-btn svg { width: 18px; height: 18px; }
.cart-count {
  background: rgba(255,255,255,0.25);
  color: #fff;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  min-width: 22px;
  text-align: center;
}

.burger {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--surface-2);
  flex-shrink: 0;
}
.burger svg { width: 22px; height: 22px; color: var(--ink); }

/* ============================================
   ГЛАВНЫЙ БАННЕР с фото цеха
   ============================================ */
.hero { padding: 32px 0 8px; }
.hero-card {
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 64px 56px;
  position: relative;
  overflow: hidden;
  min-height: 460px;
  display: flex;
  align-items: center;
  background-color: #1A2B32;
  background-image: url('../images/hero-warehouse.jpg');
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
}
.hero-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    rgba(20, 30, 40, 0.92) 0%,
    rgba(20, 30, 40, 0.78) 30%,
    rgba(20, 30, 40, 0.35) 60%,
    rgba(20, 30, 40, 0.15) 100%);
  z-index: 1;
}
.hero-card::after {
  content: '';
  position: absolute;
  right: -100px; top: -100px;
  width: 360px; height: 360px;
  background: radial-gradient(circle, var(--brand) 0%, transparent 65%);
  opacity: 0.35;
  pointer-events: none;
  z-index: 2;
}
.hero-content {
  position: relative;
  z-index: 3;
  max-width: 580px;
  width: 100%;
}
.hero-eyebrow {
  display: inline-block;
  background: rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.95);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.02em;
  border: 1px solid rgba(255,255,255,0.15);
}
.hero h1 {
  font-size: clamp(28px, 4.2vw, 48px);
  font-weight: 800;
  line-height: 1.08;
  margin-bottom: 20px;
  letter-spacing: -0.025em;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}
.hero p {
  font-size: 17px;
  color: rgba(255,255,255,0.9);
  margin-bottom: 32px;
  max-width: 460px;
  text-shadow: 0 1px 10px rgba(0,0,0,0.4);
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 28px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 14px;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.15s;
  border: 2px solid transparent;
  white-space: nowrap;
  cursor: pointer;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-primary:disabled { background: var(--muted-2); cursor: not-allowed; }
.btn-secondary {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border: 2px solid rgba(255,255,255,0.2);
}
.btn-secondary:hover { background: rgba(255,255,255,0.2); }
.btn-outline {
  background: transparent;
  border: 2px solid var(--line);
  color: var(--ink);
}
.btn-outline:hover { border-color: var(--ink-2); }
.btn-large { padding: 16px 32px; font-size: 16px; }

.hero-stats { display: flex; gap: 36px; flex-wrap: wrap; }
.hero-stat-value {
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  color: #fff;
}
.hero-stat-label {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  margin-top: 4px;
}

/* ============================================
   БЫСТРАЯ ЗАЯВКА (под баннером)
   ============================================ */
.quick-lead {
  margin-top: 20px;
}
.quick-lead-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px 32px;
  display: grid;
  grid-template-columns: 1.1fr 1.8fr;
  gap: 28px;
  align-items: center;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.quick-lead-card::after {
  content: '';
  position: absolute;
  right: -60px; top: -60px;
  width: 200px; height: 200px;
  background: radial-gradient(circle, var(--brand-soft) 0%, transparent 70%);
  pointer-events: none;
}
.quick-lead-text { position: relative; z-index: 1; }
.quick-lead-text h3 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.015em;
  margin-bottom: 8px;
  line-height: 1.2;
}
.quick-lead-text p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}
.quick-lead-text .accent {
  color: var(--brand);
  font-weight: 700;
}
.quick-lead-form {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 10px;
  position: relative;
  z-index: 1;
}
.quick-lead-row {
  display: flex;
  align-items: center;
  gap: 10px;
  grid-column: 1 / -1;
  margin-top: 8px;
}
.quick-lead-consent {
  flex: 1;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
  display: flex;
  gap: 8px;
  align-items: flex-start;
}
.quick-lead-consent input {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  accent-color: var(--brand);
  flex-shrink: 0;
  cursor: pointer;
}
.quick-lead-consent a { color: var(--brand); text-decoration: underline; }

/* ============================================
   СЕКЦИИ
   ============================================ */
.section { padding: 48px 0; }
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 16px;
}
.section-head h2 {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1.1;
}
.section-head .link {
  color: var(--brand);
  font-weight: 600;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.15s;
}
.section-head .link:hover { gap: 10px; }

/* ============================================
   КАТЕГОРИИ
   ============================================ */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}
.category-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
  min-height: 220px;
  position: relative;
  overflow: hidden;
}
.category-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
.category-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  flex-shrink: 0;
}
.category-icon svg { width: 30px; height: 30px; }
.category-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.category-card p {
  font-size: 14px;
  color: var(--muted);
  flex: 1;
  line-height: 1.5;
}
.category-link {
  color: var(--brand);
  font-weight: 600;
  font-size: 14px;
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ============================================
   ПРОМО-КАРТОЧКИ
   ============================================ */
.promo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap);
  margin-top: var(--gap);
}
.promo-card {
  background: var(--dark-card);
  color: #fff;
  border-radius: var(--radius);
  padding: 36px 32px;
  min-height: 220px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
}
.promo-card.light {
  background: #f0c43e;
  color: var(--ink);
}
.promo-card h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.promo-card p {
  font-size: 14px;
  opacity: 0.75;
  max-width: 80%;
  line-height: 1.5;
}
.promo-card.light p { opacity: 0.7; }
.promo-card .btn-inline {
  display: inline-flex;
  background: rgba(255,255,255,0.95);
  color: var(--ink);
  padding: 11px 22px;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 600;
  align-self: flex-start;
  cursor: pointer;
  transition: transform 0.15s;
}
.promo-card .btn-inline:hover { transform: scale(1.04); }
.promo-card.light .btn-inline { background: var(--ink); color: #fff; }

/* ============================================
   ТОВАРЫ
   ============================================ */
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--gap);
}
.product-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
}
.product-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
.product-image {
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e8eaee 0%, #d3d7dc 100%);
  color: rgba(0,0,0,0.25);
}
.product-image-placeholder svg { width: 64px; height: 64px; }
.product-discount {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--brand);
  color: #fff;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
}
.product-out {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(0,0,0,0.7);
  color: #fff;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
}
.product-name {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 8px;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 42px;
}
.product-specs {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
  line-height: 1.4;
}
.product-price-row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
  margin-top: auto;
}
.product-price {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.product-price-old {
  font-size: 14px;
  color: var(--muted-2);
  text-decoration: line-through;
}
.product-price-unit {
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
}

/* ============================================
   КНОПКА "В КОРЗИНУ" / "В КОРЗИНЕ ✓ + ССЫЛКА"
   ============================================ */
.product-actions {
  display: flex;
  gap: 8px;
}
.btn-add {
  flex: 1;
  background: var(--ink);
  color: #fff;
  padding: 12px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14px;
  transition: background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
}
.btn-add:hover { background: var(--brand); }
.btn-add:disabled { background: var(--muted-2); cursor: not-allowed; }

/* Состояние "В корзине" — компактная зелёная кнопка + кнопка +1 */
.in-cart-control {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px;
}
.btn-in-cart {
  background: #dcfce7;
  color: var(--success);
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.15s;
  min-height: 44px;
  text-decoration: none;
}
.btn-in-cart:hover { background: #bbf7d0; }
.btn-in-cart svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn-plus-one {
  background: var(--ink);
  color: #fff;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  padding: 0 12px;
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.btn-plus-one:hover { background: var(--brand); }

.btn-icon {
  width: 44px;
  height: 44px;
  background: var(--surface-2);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  transition: background 0.15s;
  flex-shrink: 0;
}
.btn-icon:hover { background: var(--line); }
.btn-icon svg { width: 18px; height: 18px; }

/* ============================================
   ПРЕИМУЩЕСТВА
   ============================================ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--gap);
}
.feature {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.feature-icon svg { width: 24px; height: 24px; }
.feature h4 {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.feature p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
}

/* ============================================
   КАРТА И КОНТАКТЫ
   ============================================ */
.map-block {
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  min-height: 420px;
}
.map-info {
  padding: 40px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.map-info h3 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.contact-item {
  display: flex;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  align-items: flex-start;
}
.contact-item:last-child { border-bottom: none; }
.contact-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.contact-icon svg { width: 20px; height: 20px; }
.contact-text-label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  margin-bottom: 2px;
}
.contact-text-value {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.4;
  word-break: break-word;
}
.contact-text-value a:hover { color: var(--brand); }
.map-frame {
  position: relative;
  min-height: 420px;
  background: #e8eef3;
}
.map-frame iframe,
.map-frame > div,
.map-frame > ymaps {
  width: 100% !important;
  height: 100% !important;
  border: 0;
  position: absolute !important;
  inset: 0 !important;
}

/* ============================================
   СТРАНИЦА КАТАЛОГА
   ============================================ */
.page-header {
  background: var(--surface);
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
}
.page-header h1 {
  font-size: clamp(24px, 4vw, 40px);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
  line-height: 1.1;
}
.page-header p {
  color: var(--muted);
  font-size: 16px;
}
.breadcrumbs {
  display: flex;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.breadcrumbs a:hover { color: var(--brand); }
.breadcrumbs span { color: var(--muted-2); }

.catalog-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 28px;
  padding: 32px 0 64px;
}
.filters {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
  position: sticky;
  top: 100px;
  align-self: start;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}
.filters h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.01em;
}
.filter-group {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}
.filter-group:last-child { border-bottom: none; padding-bottom: 0; }
.filter-group h4 {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--ink-2);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.filter-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  cursor: pointer;
  user-select: none;
}
.filter-item input[type="checkbox"],
.filter-item input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: var(--brand);
  cursor: pointer;
  flex-shrink: 0;
}
.filter-item:hover { color: var(--brand); }
.filter-count {
  margin-left: auto;
  color: var(--muted-2);
  font-size: 13px;
}
.price-range {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.price-range input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  outline: none;
  transition: border-color 0.15s;
}
.price-range input:focus { border-color: var(--brand); }

.catalog-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}
.catalog-count { color: var(--muted); font-size: 14px; }
.catalog-sort {
  display: flex;
  align-items: center;
  gap: 10px;
}
.catalog-sort select {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  font-size: 14px;
  cursor: pointer;
  outline: none;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}

.empty-state {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 64px 32px;
  text-align: center;
  color: var(--muted);
}
.empty-state svg { width: 64px; height: 64px; color: var(--muted-2); margin-bottom: 16px; margin-left: auto; margin-right: auto; }
.empty-state h3 { font-size: 20px; color: var(--ink); margin-bottom: 8px; }

/* Кнопка показа фильтров на мобилке */
.filters-mobile-toggle {
  display: none;
  width: 100%;
  padding: 14px;
  background: var(--surface);
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 16px;
  justify-content: space-between;
  align-items: center;
}
.filters-mobile-toggle svg { width: 20px; height: 20px; }

/* ============================================
   СТРАНИЦА ТОВАРА
   ============================================ */
.product-page { padding: 32px 0 64px; }
.product-detail {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-bottom: 28px;
}
.product-detail-image {
  aspect-ratio: 1;
  background: var(--surface-2);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-detail-image img { width: 100%; height: 100%; object-fit: cover; }
.product-detail-info h1 {
  font-size: clamp(20px, 3vw, 30px);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  line-height: 1.2;
}
.product-meta {
  display: flex;
  gap: 16px;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.product-meta-item { display: flex; align-items: center; gap: 6px; }
.product-meta-item.in-stock { color: var(--success); font-weight: 600; }
.product-meta-item.out { color: var(--danger); font-weight: 600; }

.product-detail-price {
  background: var(--surface-2);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}
.product-detail-price-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.product-detail-price-main {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.product-detail-price-old {
  font-size: 18px;
  color: var(--muted-2);
  text-decoration: line-through;
}
.product-detail-badge {
  background: var(--brand);
  color: #fff;
  padding: 4px 12px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 700;
}

.qty-row {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: center;
  flex-wrap: wrap;
}
.qty-control {
  display: flex;
  align-items: center;
  background: var(--surface);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.qty-control button {
  width: 44px;
  height: 48px;
  font-size: 20px;
  font-weight: 600;
  color: var(--ink-2);
  transition: background 0.15s;
}
.qty-control button:hover { background: var(--surface-2); }
.qty-control input {
  width: 60px;
  height: 48px;
  text-align: center;
  border: none;
  background: transparent;
  font-weight: 600;
  font-size: 16px;
  outline: none;
  -moz-appearance: textfield;
}
.qty-control input::-webkit-outer-spin-button,
.qty-control input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-label { font-size: 14px; color: var(--muted); }

.product-cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.product-cta-row .btn { flex: 1; min-width: 180px; padding: 16px; }

.product-specs-short {
  margin-top: 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
}
.product-specs-short div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
}
.product-specs-short span:first-child { color: var(--muted); flex-shrink: 0; }
.product-specs-short span:last-child { font-weight: 600; color: var(--ink); text-align: right; }

.product-tabs {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px;
}
.tabs-nav {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.tabs-nav::-webkit-scrollbar { display: none; }
.tab-btn {
  padding: 14px 20px;
  font-size: 15px;
  font-weight: 600;
  color: var(--muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
  flex-shrink: 0;
}
.tab-btn.active { color: var(--brand); border-bottom-color: var(--brand); }
.tab-btn:hover:not(.active) { color: var(--ink); }
.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.2s; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.specs-table { width: 100%; border-collapse: collapse; }
.specs-table tr { border-bottom: 1px solid var(--line); }
.specs-table td { padding: 14px 0; font-size: 15px; vertical-align: top; }
.specs-table td:first-child { color: var(--muted); width: 50%; padding-right: 12px; }
.specs-table td:last-child { font-weight: 600; color: var(--ink); }
.product-description { font-size: 16px; line-height: 1.7; color: var(--ink-2); }
.product-description p + p { margin-top: 12px; }

/* ============================================
   КОРЗИНА
   ============================================ */
.cart-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 28px;
  padding: 32px 0 64px;
}
.cart-items {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
}
.cart-item {
  display: grid;
  grid-template-columns: 100px 1fr auto;
  gap: 20px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  align-items: center;
}
.cart-item:last-child { border-bottom: none; }
.cart-item:first-child { padding-top: 0; }
.cart-item-image {
  width: 100px;
  height: 100px;
  border-radius: 12px;
  background: var(--surface-2);
  overflow: hidden;
}
.cart-item-image img { width: 100%; height: 100%; object-fit: cover; }
.cart-item-info { min-width: 0; }
.cart-item-info h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.35;
}
.cart-item-info .meta { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.cart-item-info .price { font-size: 17px; font-weight: 700; }
.cart-item-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}
.cart-item-remove {
  color: var(--muted-2);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.15s;
  padding: 4px 8px;
}
.cart-item-remove:hover { color: var(--danger); }

.cart-summary {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  position: sticky;
  top: 100px;
  align-self: start;
}
.cart-summary h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.01em;
}
.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 15px;
  padding: 10px 0;
  color: var(--ink-2);
  gap: 12px;
}
.summary-row.total {
  font-size: 22px;
  font-weight: 800;
  padding: 16px 0;
  margin-top: 12px;
  border-top: 2px solid var(--line);
  letter-spacing: -0.01em;
}
.summary-row.total .price-unit { font-size: 14px; color: var(--muted); font-weight: 500; }

/* ============================================
   ФОРМЫ
   ============================================ */
.checkout-form { margin-top: 24px; }
.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink-2);
}
.form-label .req { color: var(--brand); }
.form-input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 16px; /* >= 16 чтобы iOS не зумил при фокусе */
  background: var(--surface);
  transition: border-color 0.15s;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}
.form-input:focus { border-color: var(--brand); }
.form-input.error { border-color: var(--danger); }
textarea.form-input {
  resize: vertical;
  min-height: 90px;
  font-family: inherit;
}
.form-hint { font-size: 12px; color: var(--muted); margin-top: 4px; }
.form-error { font-size: 12px; color: var(--danger); margin-top: 4px; }
.form-consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  margin: 16px 0;
}
.form-consent input {
  width: 20px;
  height: 20px;
  margin-top: 1px;
  accent-color: var(--brand);
  flex-shrink: 0;
  cursor: pointer;
}
.form-consent a { color: var(--brand); text-decoration: underline; }
.form-consent.error { color: var(--danger); }

.delivery-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.delivery-option {
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.15s;
  user-select: none;
}
.delivery-option:hover { border-color: var(--ink-2); }
.delivery-option.selected {
  border-color: var(--brand);
  background: var(--brand-soft);
  color: var(--brand);
}
.delivery-option input { display: none; }

.cart-empty {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 80px 32px;
  text-align: center;
}
.cart-empty svg { width: 80px; height: 80px; color: var(--muted-2); margin: 0 auto 20px; }
.cart-empty h2 { font-size: 24px; margin-bottom: 10px; }
.cart-empty p { color: var(--muted); margin-bottom: 24px; }

/* ============================================
   МОДАЛКИ И ТОСТЫ
   ============================================ */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  left: 20px;
  max-width: 360px;
  margin-left: auto;
  background: var(--ink);
  color: #fff;
  padding: 14px 18px;
  border-radius: 14px;
  font-weight: 500;
  font-size: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  z-index: 1000;
  transform: translateY(150%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}
.toast.show { transform: translateY(0); pointer-events: auto; }
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }
.toast svg { width: 18px; height: 18px; flex-shrink: 0; }
.toast span {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(16, 24, 40, 0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 16px;
  backdrop-filter: blur(4px);
  overflow-y: auto;
}
.modal-backdrop.show { display: flex; }
.modal {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 32px 28px;
  max-width: 480px;
  width: 100%;
  position: relative;
  margin: auto;
}
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-close:hover { background: var(--line); }
.modal-close svg { width: 18px; height: 18px; }
.modal h2 {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
  padding-right: 40px;
}
.modal-sub {
  color: var(--muted);
  margin-bottom: 20px;
  font-size: 15px;
}
.modal-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.modal-icon svg { width: 32px; height: 32px; }
.modal-success { text-align: center; }

/* ============================================
   ПОДВАЛ
   ============================================ */
.footer {
  background: var(--ink);
  color: rgba(255,255,255,0.7);
  padding: 56px 0 24px;
  margin-top: 64px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand img {
  height: 72px;
  width: auto;
  max-width: 260px;
  margin-bottom: 16px;
}
.footer-brand p { font-size: 14px; line-height: 1.6; max-width: 280px; }
.footer h5 {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
}
.footer ul { list-style: none; }
.footer li { padding: 5px 0; font-size: 14px; line-height: 1.5; }
.footer a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  font-size: 13px;
  flex-wrap: wrap;
  gap: 12px;
}

select.form-input {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b7785' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

/* ===========================================================
   АДАПТИВ
   =========================================================== */

/* Большой планшет / маленький десктоп */
@media (max-width: 1100px) {
  .products-grid { grid-template-columns: repeat(3, 1fr); }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .catalog-layout { grid-template-columns: 240px 1fr; }
  .catalog-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .quick-lead-card { grid-template-columns: 1fr; gap: 20px; }
  .quick-lead-form { grid-template-columns: 1fr 1fr; }
}

/* Планшет */
@media (max-width: 900px) {
  :root { --gap: 16px; }

  .topbar { font-size: 13px; padding: 8px 0; }
  .topbar-inner { gap: 6px; justify-content: center; text-align: center; }
  .topbar-contacts { gap: 14px; justify-content: center; }

  .nav { display: none; }
  .burger { display: flex; }
  .nav.open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--surface);
    padding: 16px 20px;
    gap: 4px;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .nav.open a {
    padding: 12px 8px;
    border-radius: 8px;
    width: 100%;
  }
  .nav.open a:active { background: var(--surface-2); }

  .header-inner { padding: 12px 0; gap: 12px; }
  .logo img { height: 52px; }

  .hero-card {
    padding: 40px 28px;
    min-height: 420px;
    background-position: center;
  }
  .hero-card::before {
    background: linear-gradient(180deg,
      rgba(20, 30, 40, 0.85) 0%,
      rgba(20, 30, 40, 0.7) 60%,
      rgba(20, 30, 40, 0.6) 100%);
  }

  .promo-grid { grid-template-columns: 1fr; }
  .promo-card { min-height: 180px; padding: 28px 24px; }
  .promo-card p { max-width: 100%; }
  .product-detail { grid-template-columns: 1fr; padding: 20px; gap: 24px; }
  .product-detail-image { aspect-ratio: 4/3; }
  .cart-layout { grid-template-columns: 1fr; }
  .cart-summary { position: static; }
  .categories-grid { grid-template-columns: 1fr; }
  .category-card { min-height: auto; padding: 24px; }

  .map-block { grid-template-columns: 1fr; min-height: auto; }
  .map-info { padding: 28px 24px; }
  .map-frame { min-height: 340px; height: 340px; }

  .filters {
    position: static;
    max-height: none;
    display: none;
  }
  .filters.open { display: block; margin-bottom: 16px; }
  .filters-mobile-toggle { display: flex; }
  .catalog-layout { grid-template-columns: 1fr; padding: 20px 0 40px; }
}

/* Мобила */
@media (max-width: 700px) {
  :root { --gap: 14px; }

  .container { padding: 0 16px; }
  .section { padding: 36px 0; }

  .hero { padding: 20px 0 8px; }
  .hero-card { padding: 32px 22px; min-height: 380px; border-radius: 22px; }
  .hero-eyebrow { font-size: 12px; padding: 6px 12px; margin-bottom: 18px; }
  .hero h1 { font-size: 28px; margin-bottom: 14px; }
  .hero p { font-size: 15px; margin-bottom: 24px; }
  .hero-actions { gap: 8px; margin-bottom: 22px; }
  .hero-stats { gap: 20px; }
  .hero-stat-value { font-size: 22px; }
  .hero-stat-label { font-size: 12px; }
  .btn-large { padding: 13px 22px; font-size: 15px; }

  .quick-lead-card { padding: 24px 20px; }
  .quick-lead-text h3 { font-size: 19px; }
  .quick-lead-form { grid-template-columns: 1fr; }

  .section-head h2 { font-size: 22px; }
  .section-head .link { font-size: 14px; }

  .products-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .product-card { padding: 12px; border-radius: 16px; }
  .product-name { font-size: 14px; min-height: 38px; }
  .product-specs { font-size: 12px; margin-bottom: 12px; }
  .product-price { font-size: 18px; }
  .product-price-old { font-size: 12px; }
  .product-price-unit { font-size: 12px; width: 100%; }
  .btn-add, .btn-in-cart { font-size: 13px; padding: 10px 6px; }
  .btn-plus-one { min-width: 38px; padding: 0 10px; font-size: 13px; }
  .btn-icon { display: none; }

  .features-grid { grid-template-columns: 1fr; }
  .feature { padding: 22px; }

  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer { padding: 40px 0 20px; margin-top: 40px; }
  .footer-bottom { flex-direction: column; gap: 8px; }

  .product-specs-short { grid-template-columns: 1fr; }
  .product-detail { padding: 16px; border-radius: 20px; }
  .product-tabs { padding: 20px 16px; border-radius: 20px; }
  .tab-btn { padding: 12px 14px; font-size: 14px; }
  .product-cta-row .btn { min-width: 0; padding: 14px; }

  .cart-items { padding: 16px; border-radius: 16px; }
  .cart-summary { padding: 20px; border-radius: 16px; }
  .cart-item {
    grid-template-columns: 80px 1fr;
    grid-template-rows: auto auto;
    gap: 12px;
    padding: 16px 0;
  }
  .cart-item-image { width: 80px; height: 80px; }
  .cart-item-info { grid-column: 2; }
  .cart-item-controls {
    grid-column: 1 / -1;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding-top: 4px;
  }

  .summary-row { font-size: 14px; }
  .summary-row.total { font-size: 19px; }

  .modal { padding: 24px 20px; border-radius: 18px; }
  .modal h2 { font-size: 19px; }
  .delivery-options { grid-template-columns: 1fr; }

  .cart-btn span:not(.cart-count) { display: none; }
  .cart-btn { padding: 11px 14px; }

  .toast { left: 12px; right: 12px; bottom: 12px; max-width: none; margin: 0; }

  .breadcrumbs { font-size: 12px; }

  .page-header { padding: 24px 0; }
  .page-header p { font-size: 14px; }
}

/* Очень маленькие мобилки */
@media (max-width: 380px) {
  .container { padding: 0 12px; }
  .logo img { height: 46px; }
  .topbar-contacts { gap: 8px; flex-direction: column; }
  .hero-card { padding: 28px 18px; min-height: 360px; border-radius: 18px; }
  .hero h1 { font-size: 24px; }
  .hero-stats { gap: 14px; }
  .hero-stat-value { font-size: 19px; }
  .products-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1; }
}
