/* ============================================
   ТеплоСила — Design System 9.0
   "Warm Ember" — Premium Orange & White Theme
   Modern e-commerce design for heating/climate
   ============================================ */

/* --- 1. CUSTOM PROPERTIES --- */
:root {
  --orange-50: #fff7ed;
  --orange-100: #ffedd5;
  --orange-200: #fed7aa;
  --orange-300: #fdba74;
  --orange-400: #fb923c;
  --orange-500: #f97316;
  --orange-600: #ea580c;
  --orange-700: #c2410c;
  --orange-800: #9a3412;
  --orange-900: #7c2d12;

  --primary: #f97316;
  --primary-light: #fb923c;
  --primary-dark: #ea580c;
  --primary-deeper: #c2410c;

  --accent-gradient: linear-gradient(135deg, #f97316 0%, #f59e0b 100%);
  --accent-gradient-hover: linear-gradient(135deg, #ea580c 0%, #d97706 100%);
  --accent-gradient-subtle: linear-gradient(
    135deg,
    rgba(249, 115, 22, 0.08) 0%,
    rgba(245, 158, 11, 0.06) 100%
  );

  --white: #ffffff;
  --gray-50: #fafaf9;
  --gray-100: #f5f5f4;
  --gray-200: #e7e5e4;
  --gray-300: #d6d3d1;
  --gray-400: #a8a29e;
  --gray-500: #78716c;
  --gray-600: #57534e;
  --gray-700: #44403c;
  --gray-800: #292524;
  --gray-900: #1c1917;

  --text-primary: #1c1917;
  --text-secondary: #57534e;
  --text-muted: #78716c;
  --text-on-primary: #ffffff;

  --bg-body: #fafaf9;
  --bg-card: #ffffff;
  --bg-elevated: #ffffff;

  --border-color: #e7e5e4;
  --border-light: #f5f5f4;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  --shadow-xs: 0 1px 2px rgba(28, 25, 23, 0.04);
  --shadow-sm:
    0 1px 3px rgba(28, 25, 23, 0.06), 0 1px 2px rgba(28, 25, 23, 0.04);
  --shadow-md:
    0 4px 6px -1px rgba(28, 25, 23, 0.06), 0 2px 4px -2px rgba(28, 25, 23, 0.04);
  --shadow-lg:
    0 10px 15px -3px rgba(28, 25, 23, 0.07),
    0 4px 6px -4px rgba(28, 25, 23, 0.04);
  --shadow-xl:
    0 20px 25px -5px rgba(28, 25, 23, 0.08),
    0 8px 10px -6px rgba(28, 25, 23, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(28, 25, 23, 0.16);
  --shadow-orange: 0 4px 14px rgba(249, 115, 22, 0.25);
  --shadow-orange-lg: 0 8px 24px rgba(249, 115, 22, 0.3);

  --glass-bg: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(255, 255, 255, 0.5);
  --glass-blur: blur(16px);

  --header-height: 160px;
  --nav-height: 48px;
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 350ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 500ms cubic-bezier(0.16, 1, 0.3, 1);

  --font-sans: "Inter", "Manrope", system-ui, -apple-system, sans-serif;
  --font-display: "Manrope", "Inter", system-ui, -apple-system, sans-serif;

  --container-max: 1280px;
  --container-pad: 20px;

  /* backward compat for inline SVG strokes */
  --red: #f97316;
  --blue: #f97316;
  --green: #22c55e;
}

/* --- 2. RESET & BASE --- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  height: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-body);
  min-height: 100vh;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--primary-dark);
}

ul,
ol {
  list-style: none;
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

input,
textarea,
select {
  outline: none;
}

::selection {
  background: rgba(249, 115, 22, 0.2);
  color: var(--text-primary);
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* --- 3. LAYOUT --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

.main-content {
  flex: 1;
  padding-top: 24px;
  padding-bottom: 64px;
}

/* --- 4. BUTTONS --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.2;
  border-radius: var(--radius-lg);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.15) 0%,
    transparent 60%
  );
  opacity: 0;
  transition: opacity var(--transition-fast);
  pointer-events: none;
  border-radius: inherit;
}

.btn:hover::after {
  opacity: 1;
}

.btn:active {
  transform: scale(0.97);
}

.btn--primary {
  background: var(--accent-gradient);
  color: var(--text-on-primary);
  border-color: transparent;
  box-shadow: var(--shadow-orange);
}

.btn--primary:hover {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-orange-lg);
  transform: translateY(-1px);
  color: var(--text-on-primary);
}

.btn--accent {
  background: var(--primary);
  color: var(--text-on-primary);
  border-color: transparent;
  box-shadow: var(--shadow-orange);
}

.btn--accent:hover {
  background: var(--primary-dark);
  box-shadow: var(--shadow-orange-lg);
  transform: translateY(-1px);
  color: var(--text-on-primary);
}

.btn--outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn--outline:hover {
  background: var(--primary);
  color: var(--text-on-primary);
  box-shadow: var(--shadow-orange);
  transform: translateY(-1px);
}

.btn--callback {
  background: var(--accent-gradient);
  color: var(--text-on-primary);
  border-color: transparent;
  box-shadow: var(--shadow-orange);
}

.btn--callback:hover {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-orange-lg);
  transform: translateY(-1px);
  color: var(--text-on-primary);
}

.btn--ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: var(--border-color);
}

.btn--ghost:hover {
  background: var(--gray-100);
  color: var(--text-primary);
  border-color: var(--gray-300);
}

.btn--full {
  width: 100%;
}

.btn--lg {
  padding: 16px 36px;
  font-size: 1.0625rem;
  border-radius: var(--radius-xl);
}

.btn--sm {
  padding: 8px 18px;
  font-size: 0.8125rem;
  border-radius: var(--radius-md);
}

/* --- 5. HEADER --- */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  transition:
    box-shadow var(--transition-smooth),
    transform var(--transition-smooth);
  will-change: transform;
}

.header--scrolled {
  box-shadow: 0 2px 24px rgba(28, 25, 23, 0.08);
}

/* -- 5a. Header Top Bar -- */
.header-top {
  background: var(--gray-900);
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.8125rem;
  line-height: 1.4;
  padding: 6px 0;
}

.header-top__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
  gap: 16px;
}

.header-top__left,
.header-top__right {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.header-top__phone,
.header-top__email,
.header-top__address {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.85);
  transition: color var(--transition-fast);
}

.header-top__phone:hover,
.header-top__email:hover {
  color: var(--orange-300);
}

.header-top__callback {
  color: var(--orange-300);
  font-weight: 600;
  cursor: pointer;
  transition: color var(--transition-fast);
  background: none;
  border: none;
  font-size: inherit;
}

.header-top__callback:hover {
  color: var(--orange-200);
}

/* -- 5b. Header Main -- */
.header-main {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 16px var(--container-pad);
  max-width: var(--container-max);
  margin: 0 auto;
  border-bottom: 1px solid var(--border-light);
  flex-wrap: wrap;
}

.header-logo {
  flex-shrink: 0;
}

.header-logo img {
  height: 48px;
  width: auto;
  transition: transform var(--transition-base);
}

.header-logo:hover img {
  transform: scale(1.03);
}

.header-slogan {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.3;
  max-width: 180px;
  flex-shrink: 0;
  display: none;
}

@media (min-width: 1024px) {
  .header-slogan {
    display: block;
  }
}

/* -- 5c. Header Search -- */
.header-search {
  flex: 1;
  max-width: 520px;
  position: relative;
  display: flex;
  align-items: center;
}

.header-search__input {
  width: 100%;
  padding: 12px 50px 12px 20px;
  border: 2px solid var(--border-color);
  border-radius: var(--radius-full);
  background: var(--gray-50);
  font-size: 0.9375rem;
  color: var(--text-primary);
  transition: all var(--transition-base);
}

.header-search__input::placeholder {
  color: var(--gray-400);
}

.header-search__input:focus {
  border-color: var(--primary);
  background: var(--white);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.1);
}

.header-search__btn {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--accent-gradient);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
}

.header-search__btn:hover {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-orange);
}

.header-search__btn svg {
  width: 18px;
  height: 18px;
}

/* -- 5d. Header Actions & Phone -- */
.header-actions {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

.header-phone {
  text-align: right;
  display: none;
}

@media (min-width: 768px) {
  .header-phone {
    display: block;
  }
}

.header-phone__number {
  display: block;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.header-phone__number:hover {
  color: var(--primary);
}

.header-phone__label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 1px;
}

.header-cta {
  display: none;
}

@media (min-width: 768px) {
  .header-cta {
    display: inline-flex;
  }
}

/* -- 5e. Hamburger Burger -- */
.header-burger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  gap: 5px;
  padding: 10px;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}

.header-burger:hover {
  background: var(--gray-100);
}

.header-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition-base);
  transform-origin: center;
}

.header-burger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header-burger.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.header-burger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (min-width: 769px) {
  .header-burger {
    display: none;
  }
}

/* -- 5f. Header Nav (Accent Bar) -- */
.header-nav {
  background: var(--accent-gradient);
  position: relative;
  z-index: 100;
  display: none;
}

@media (min-width: 769px) {
  .header-nav {
    display: block;
  }
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

.nav__item {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 16px;
  color: var(--white);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
  border-radius: var(--radius-md);
  transition:
    background var(--transition-fast),
    color var(--transition-fast);
  text-decoration: none;
  position: relative;
}

.nav__item:hover {
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
}

.nav__item:active {
  background: rgba(255, 255, 255, 0.25);
}

.nav__chevron {
  width: 16px;
  height: 16px;
  transition: transform var(--transition-base);
  opacity: 0.8;
}

.nav__dropdown {
  position: relative;
}

.nav__dropdown:hover .nav__chevron {
  transform: rotate(180deg);
}

/* -- 5g. Mega Menu -- */
.mega-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--white);
  border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  box-shadow:
    0 25px 60px -12px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(0, 0, 0, 0.04);
  padding: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 200;
  max-width: var(--container-max);
  margin: 0 auto;
  max-height: 75vh;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.nav__dropdown:hover .mega-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Header bar inside mega-menu */
.mega-menu__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px 16px;
  border-bottom: 1px solid var(--border-light);
}

.mega-menu__title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.mega-menu__title svg {
  color: var(--primary);
}

.mega-menu__all-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--orange-50);
  transition: all var(--transition-base);
}

.mega-menu__all-link:hover {
  background: var(--primary);
  color: var(--white);
}

/* Grid of category cards */
.mega-menu__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0;
  padding: 12px 20px 20px;
}

/* Each category card */
.mega-menu__card {
  padding: 12px;
  border-radius: var(--radius-lg);
  transition: background var(--transition-base);
}

.mega-menu__card:hover {
  background: var(--gray-50);
}

/* Card header: icon + name + arrow in one row */
.mega-menu__card-head {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-primary);
  padding: 8px 10px;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
}

.mega-menu__card-head:hover {
  background: var(--orange-50);
}

.mega-menu__icon-wrap {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--orange-50);
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  overflow: hidden;
}

.mega-menu__card-head:hover .mega-menu__icon-wrap {
  background: var(--orange-100);
  transform: scale(1.05);
}

.mega-menu__img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  flex-shrink: 0;
}

.mega-menu__icon-wrap svg {
  color: var(--primary);
}

.mega-menu__name {
  flex: 1;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.mega-menu__arrow {
  flex-shrink: 0;
  color: var(--dark-200);
  opacity: 0;
  transform: translateX(-4px);
  transition: all var(--transition-base);
}

.mega-menu__card-head:hover .mega-menu__arrow {
  opacity: 1;
  transform: translateX(0);
  color: var(--primary);
}

/* Subcategory list */
.mega-menu__subs {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 4px 0 0;
  padding: 0 0 0 60px;
}

.mega-menu__subs li {
  line-height: 1;
}

.mega-menu__sub {
  display: inline-block;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-decoration: none;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  line-height: 1.4;
}

.mega-menu__sub:hover {
  color: var(--primary);
  background: var(--orange-50);
}

.mega-menu__sub--more {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.75rem;
}

.mega-menu__sub--more:hover {
  color: var(--primary-dark);
}

/* --- 6. MOBILE MENU --- */
.mobile-overlay {
  position: fixed;
  inset: 0;
  background: rgba(28, 25, 23, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-smooth);
}

.mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: min(360px, 85vw);
  height: 100vh;
  height: 100dvh;
  background: var(--white);
  z-index: 2001;
  transform: translateX(100%);
  transition: transform var(--transition-slow);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.mobile-menu.active {
  transform: translateX(0);
}

.mobile-menu__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  flex-shrink: 0;
}

.mobile-menu__title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
}

.mobile-menu__close {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
  color: var(--text-secondary);
  font-size: 1.25rem;
}

.mobile-menu__close:hover {
  background: var(--gray-100);
}

.mobile-menu__phone {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-light);
}

.mobile-menu__phone-number {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  display: block;
}

.mobile-menu__nav {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
}

.mobile-menu__nav-item {
  display: block;
  padding: 12px 20px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.mobile-menu__nav-item:hover {
  background: var(--orange-50);
  color: var(--primary);
}

.mobile-menu__categories {
  padding: 16px 20px;
  flex: 1;
}

.mobile-menu__cat-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.mobile-menu__cat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-primary);
  transition: all var(--transition-fast);
  text-decoration: none;
  margin-bottom: 2px;
}

.mobile-menu__cat-item:hover {
  background: var(--orange-50);
  color: var(--primary);
}

.mobile-menu__cat-img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  flex-shrink: 0;
}

/* --- 7. HERO CAROUSEL --- */
.hero-carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  margin-bottom: 40px;
  background: var(--gray-100);
}

.hero-carousel__track {
  position: relative;
  width: 100%;
  aspect-ratio: 2.2 / 1;
}

/* -- Hero carousel slides use background-image inline style -- */
.hero-carousel__slide {
  min-width: 100%;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 600ms cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
}

.hero-carousel__slide--active {
  opacity: 1;
  z-index: 1;
}

.hero-carousel__content {
  position: relative;
  z-index: 2;
  padding: 48px 56px;
  max-width: 560px;
}

.hero-carousel__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--white);
  margin-bottom: 12px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.hero-carousel__subtitle {
  font-size: clamp(0.875rem, 1.5vw, 1.125rem);
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 24px;
  line-height: 1.5;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.hero-carousel__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: var(--white);
  color: var(--primary);
  font-weight: 700;
  font-size: 1rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-base);
  text-decoration: none;
}

.hero-carousel__btn:hover {
  background: var(--orange-50);
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
  color: var(--primary-dark);
}

.hero-carousel__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  color: var(--text-primary);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  font-size: 1.25rem;
  opacity: 0;
  pointer-events: none;
}

.hero-carousel:hover .hero-carousel__arrow {
  opacity: 1;
  pointer-events: auto;
}

.hero-carousel__arrow:hover {
  background: var(--white);
  box-shadow: var(--shadow-lg);
  transform: translateY(-50%) scale(1.08);
}

.hero-carousel__arrow--prev {
  left: 16px;
}

.hero-carousel__arrow--next {
  right: 16px;
}

.hero-carousel__dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.hero-carousel__dot {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.45);
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
  padding: 0;
}

.hero-carousel__dot:hover {
  background: rgba(255, 255, 255, 0.7);
}

.hero-carousel__dot--active {
  background: var(--white);
  width: 28px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.15);
}

/* -- Hero Banner (fallback) -- */
.hero-banner {
  background: var(--accent-gradient);
  border-radius: var(--radius-xl);
  padding: 56px 48px;
  margin-bottom: 40px;
  color: var(--white);
  text-align: center;
}

.hero-banner__text {
  margin-bottom: 24px;
}

.hero-banner__text h1 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 12px;
  color: inherit;
}

.hero-banner__text p {
  font-size: clamp(0.95rem, 1.5vw, 1.125rem);
  opacity: 0.85;
  line-height: 1.5;
}

.hero-banner__actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-banner__actions .btn--callback {
  background: var(--white);
  color: var(--primary);
  border: none;
}

.hero-banner__actions .btn--callback:hover {
  background: var(--gray-100);
}

.hero-banner__actions .btn--outline {
  border-color: rgba(255, 255, 255, 0.6);
  color: var(--white);
  background: transparent;
}

.hero-banner__actions .btn--outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--white);
}

/* --- 8. SECTIONS --- */
.section {
  margin-bottom: 56px;
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 16px;
  flex-wrap: wrap;
}

.section-header__title {
  font-family: var(--font-display);
  font-size: clamp(1.375rem, 2.5vw, 1.75rem);
  font-weight: 800;
  color: var(--text-primary);
  position: relative;
}

.section-header__title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 40px;
  height: 3px;
  background: var(--accent-gradient);
  border-radius: 2px;
}

.section-header__link {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 4px;
  transition:
    gap var(--transition-base),
    color var(--transition-fast);
}

.section-header__link:hover {
  color: var(--primary-dark);
  gap: 8px;
}

.section-header__count {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* --- 9. PRODUCT GRID & CARDS --- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.product-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-smooth);
  position: relative;
}

.product-card:hover {
  border-color: var(--orange-200);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.product-card__img {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
}

.product-card__img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  /* Слегка увеличиваем — у исходных фото много встроенных белых полей,
     лишнее обрезается overflow:hidden, и товар выглядит крупнее. */
  transform: scale(1.25);
  transition: transform var(--transition-smooth);
}

.product-card:hover .product-card__img img {
  transform: scale(1.33);
}

/* product-card__img is itself the <a> element, no nested a needed */

.product-card__badge {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: var(--radius-full);
  line-height: 1.4;
}

.product-card__badge--in {
  background: #16a34a;
  color: var(--white);
}

.product-card__badge--order {
  background: var(--orange-100);
  color: var(--primary-dark);
}

.product-card__stock {
  margin-top: 6px;
}

.product-card__overlay {
  position: absolute;
  inset: 0;
  background: rgba(28, 25, 23, 0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-base);
  z-index: 1;
}

.product-card:hover .product-card__overlay {
  opacity: 1;
}

.product-card__quick-btn {
  padding: 10px 20px;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-full);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-base);
  transform: translateY(8px);
  text-decoration: none;
}

.product-card:hover .product-card__quick-btn {
  transform: translateY(0);
}

.product-card__quick-btn:hover {
  background: var(--white);
  box-shadow: var(--shadow-md);
}

.product-card__body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-card__category {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary);
  margin-bottom: 6px;
}

.product-card__name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color var(--transition-fast);
}

.product-card__name a {
  color: inherit;
  text-decoration: none;
}

.product-card__name a:hover {
  color: var(--primary);
}

.product-card__footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
}

.product-card__price {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.product-card__price--request {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0;
}

.product-card__unit {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-left: 2px;
}

.product-card__action {
  padding: 0 16px 16px;
  margin-top: auto;
}

.product-card__action .btn {
  padding: 8px 16px;
  font-size: 0.8125rem;
}

/* --- 10. PRODUCT DETAIL PAGE --- */
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

@media (max-width: 768px) {
  .product-detail {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

.product-detail__gallery {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-light);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 0;
}

.gallery-main {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  min-height: 420px;
  background: var(--white);
}

.gallery-main img {
  max-width: 100%;
  max-height: 500px;
  object-fit: contain;
  transform: scale(1.05);
  transition: opacity 0.2s ease, transform var(--transition-smooth);
}

.gallery-thumbs {
  display: flex;
  gap: 8px;
  padding: 12px 16px 16px;
  overflow-x: auto;
  border-top: 1px solid var(--border-light);
  background: var(--gray-50);
}

.gallery-thumb {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  padding: 4px;
  background: var(--white);
  transition: all var(--transition-base);
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.gallery-thumb:hover {
  border-color: var(--orange-200);
}

.gallery-thumb--active {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--orange-100);
}

.product-detail__gallery > img {
  max-width: 100%;
  max-height: 480px;
  object-fit: contain;
  padding: 32px;
}

.product-detail__preview {
  margin-top: 16px;
}

.product-detail__preview h3 {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.product-detail__preview p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

.product-detail__info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.product-detail__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.2;
}

.product-detail__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.product-detail__meta-tag {
  padding: 4px 14px;
  background: var(--gray-100);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.product-detail__meta-tag:hover {
  background: var(--gray-200);
  color: var(--text-primary);
}

.product-detail__meta-tag--category {
  background: var(--orange-50);
  color: var(--primary);
}

.product-detail__meta-tag--category:hover {
  background: var(--orange-100);
  color: var(--primary-dark);
}

.product-detail__price-block {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  border: 1px solid var(--border-light);
}

.product-detail__price {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.product-detail__price--request {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--primary);
}

.product-detail__price-unit {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-left: 4px;
}

.product-detail__stock {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8125rem;
  font-weight: 600;
  margin-top: 8px;
}

.product-detail__stock svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.product-detail__stock::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
}

.product-detail__stock--in {
  color: #16a34a;
}

.product-detail__stock--in::before {
  background: #16a34a;
}

.product-detail__stock--out {
  color: var(--text-muted);
}

.product-detail__stock--out::before {
  background: var(--gray-300);
}

.product-detail__cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.product-detail__badges {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  padding-top: 8px;
}

.product-detail__badge-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--gray-50);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.product-detail__badge-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  color: var(--primary);
  width: 20px;
  height: 20px;
}

.product-detail__badge-icon svg {
  width: 20px;
  height: 20px;
}

.product-detail__badge-text {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.3;
}

/* -- Product Tabs -- */
.product-tabs {
  margin-bottom: 48px;
}

.product-tabs__header {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid var(--border-color);
  margin-bottom: 28px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.product-tabs__header::-webkit-scrollbar {
  display: none;
}

.product-tabs__tab {
  padding: 14px 24px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-muted);
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-base);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.product-tabs__tab:hover {
  color: var(--text-primary);
  background: var(--gray-50);
}

.product-tabs__tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  background: var(--orange-50);
}

.product-tabs__content {
  display: none;
  animation: tabFadeIn 350ms ease;
}

.product-tabs__content.active {
  display: block;
}

@keyframes tabFadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* -- Characteristics Table -- */
.chars-group {
  margin-bottom: 32px;
}

.chars-group__title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-light);
}

.chars-table {
  width: 100%;
  border-collapse: collapse;
}

.chars-table__row {
  display: flex;
  align-items: baseline;
  padding: 11px 12px;
  border-radius: var(--radius-sm);
  transition: background var(--transition-fast);
}

.chars-table__row--even {
  background: var(--gray-50);
}

.chars-table__row:hover {
  background: var(--orange-50);
}

.chars-table__name {
  flex-shrink: 0;
  color: var(--text-muted);
  font-size: 0.875rem;
  white-space: nowrap;
}

.chars-table__unit {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 0.8125rem;
  opacity: 0.7;
}

.chars-table__dots {
  flex: 1;
  border-bottom: 2px dotted var(--border-light);
  margin: 0 10px;
  min-width: 20px;
  position: relative;
  top: -4px;
}

.chars-table__value {
  flex-shrink: 0;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.875rem;
  text-align: right;
}

.chars-table__row--hidden {
  display: none !important;
}

.chars-table__row--hidden.chars-table__row--visible {
  display: flex !important;
  animation: charsFadeIn 0.3s ease;
}

@keyframes charsFadeIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.chars-show-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding: 8px 16px;
  background: var(--gray-50);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  color: var(--primary);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.chars-show-more:hover {
  background: var(--orange-50);
  border-color: var(--primary);
}

.chars-show-more__icon {
  transition: transform 0.3s ease;
}

.chars-show-more--expanded .chars-show-more__icon {
  transform: rotate(180deg);
}

/* --- 11. CATEGORY PAGE --- */
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 16px 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.breadcrumbs a {
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.breadcrumbs a:hover {
  color: var(--primary);
}

.breadcrumbs .sep {
  color: var(--gray-300);
  user-select: none;
}

.page-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 24px;
  line-height: 1.2;
}

.subcategories {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}

.subcategory-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all var(--transition-base);
}

.subcategory-tag:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--orange-50);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  box-shadow: var(--shadow-sm);
}

/* -- Filter Bar -- */
.filter-bar {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-bottom: 28px;
}

.filter-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 16px;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.filter-input {
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  background: var(--gray-50);
  transition: all var(--transition-fast);
  min-width: 100px;
  color: var(--text-primary);
}

.filter-input:focus {
  border-color: var(--primary);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.08);
}

.filter-dash {
  color: var(--gray-300);
  font-weight: 500;
  align-self: center;
  padding-bottom: 0;
  line-height: 2.5;
}

.filter-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.filter-checkbox input[type="checkbox"] {
  accent-color: var(--primary);
  width: 16px;
  height: 16px;
}

.filter-select {
  padding: 10px 32px 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  background: var(--gray-50)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2378716C' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E")
    no-repeat right 12px center;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--text-primary);
}

.filter-select:focus {
  border-color: var(--primary);
  background-color: var(--white);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.08);
}

.filter-btn {
  padding: 10px 24px;
  background: var(--accent-gradient);
  color: var(--white);
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
}

.filter-btn:hover {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-orange);
}

.filter-reset {
  padding: 10px 18px;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8125rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: color var(--transition-fast);
  text-decoration: none;
}

.filter-reset:hover {
  color: var(--primary);
}

.filter-count {
  font-size: 0.8125rem;
  color: var(--text-muted);
  align-self: center;
}

/* -- Pagination -- */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 40px;
  padding: 16px 0;
}

.pagination a,
.pagination__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-decoration: none;
  border: 1px solid var(--border-color);
  background: var(--white);
  transition: all var(--transition-base);
}

.pagination a:hover,
.pagination__link:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--orange-50);
}

.pagination .active,
.pagination__link--active {
  background: var(--accent-gradient);
  color: var(--white);
  border-color: transparent;
  box-shadow: var(--shadow-orange);
  pointer-events: none;
}

.empty-msg {
  text-align: center;
  padding: 64px 24px;
  color: var(--text-muted);
  font-size: 1rem;
}

/* --- 12. SEO BLOCK --- */
.seo-block {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-top: 40px;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

.seo-block h2,
.seo-block h3 {
  color: var(--text-primary);
  margin-bottom: 12px;
  margin-top: 20px;
  font-weight: 700;
}

.seo-block h2:first-child,
.seo-block h3:first-child {
  margin-top: 0;
}

.seo-block p {
  margin-bottom: 12px;
}

.seo-block ul,
.seo-block ol {
  padding-left: 20px;
  margin-bottom: 12px;
}

.seo-block li {
  list-style: disc;
  margin-bottom: 4px;
}

/* --- 13. BRANDS PAGES --- */
.brands-page {
  padding-top: 8px;
}

.brands-page__desc {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 32px;
  max-width: 720px;
}

.brands-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.brands-grid__card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  transition: all var(--transition-smooth);
  text-decoration: none;
  color: var(--text-primary);
}

.brands-grid__card:hover {
  border-color: var(--orange-200);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.brands-grid__logo {
  width: 100px;
  height: 60px;
  object-fit: contain;
  transition: transform var(--transition-base);
}

.brands-grid__card:hover .brands-grid__logo {
  transform: scale(1.05);
}

.brands-grid__text {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
}

.brand-detail {
  margin-bottom: 48px;
}

.brand-detail__header {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.brand-detail__logo {
  width: 140px;
  height: auto;
  object-fit: contain;
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
}

.brand-detail__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 800;
  color: var(--text-primary);
}

.brand-detail__description {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 24px;
  max-width: 800px;
}

.brand-detail__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* --- 14. COMPANY PAGE --- */
.company-page {
  padding-top: 8px;
}

.company-section {
  margin-bottom: 48px;
}

.company-section__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 12px;
}

.company-section__title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 40px;
  height: 3px;
  background: var(--accent-gradient);
  border-radius: 2px;
}

.company-lead {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: 800px;
  margin-bottom: 32px;
}

/* -- Timeline -- */
.company-timeline {
  position: relative;
  padding-left: 36px;
}

.company-timeline::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--orange-200);
  border-radius: 2px;
}

.company-timeline__item {
  position: relative;
  padding-bottom: 28px;
}

.company-timeline__item::before {
  content: "";
  position: absolute;
  left: -30px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: var(--radius-full);
  background: var(--primary);
  border: 3px solid var(--orange-100);
  box-shadow: 0 0 0 3px var(--white);
}

.company-timeline__year {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}

.company-timeline__text {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* -- Highlights -- */
.company-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.company-highlight {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  transition: all var(--transition-smooth);
}

.company-highlight:hover {
  border-color: var(--orange-200);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.company-highlight__icon {
  font-size: 2rem;
  margin-bottom: 12px;
  display: block;
}

/* -- Values -- */
.company-values {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.company-value {
  background: var(--accent-gradient-subtle);
  border: 1px solid var(--orange-100);
  border-radius: var(--radius-lg);
  padding: 24px;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.company-value:hover {
  border-color: var(--orange-200);
  box-shadow: var(--shadow-sm);
}

/* -- CTA Section -- */
.company-cta {
  background: var(--accent-gradient);
  border-radius: var(--radius-xl);
  padding: 48px;
  text-align: center;
  color: var(--white);
}

.company-cta__actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}

.company-cta__actions .btn--callback {
  background: var(--white);
  color: var(--primary);
  border: none;
}

.company-cta__actions .btn--callback:hover {
  background: var(--gray-100);
}

.company-cta__actions .btn--outline {
  border-color: rgba(255, 255, 255, 0.6);
  color: var(--white);
  background: transparent;
}

.company-cta__actions .btn--outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--white);
}

/* --- 15. CONTACTS PAGE --- */
.contacts-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 36px;
  margin-bottom: 32px;
  box-shadow: var(--shadow-sm);
}

.contacts-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contacts-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}

.contacts-item:hover {
  background: var(--gray-50);
}

.contacts-item__icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--orange-50);
  color: var(--primary);
  font-size: 1.125rem;
  flex-shrink: 0;
}

.contacts-item__icon--social {
  background: var(--gray-100);
  color: var(--text-secondary);
}

.contacts-item__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.contacts-item__label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.contacts-item__value {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
}

.contacts-item__value a {
  color: var(--text-primary);
  transition: color var(--transition-fast);
}

.contacts-item__value a:hover {
  color: var(--primary);
}

.contacts-item__vk-logo {
  width: 20px;
  height: 20px;
}

.contacts-action {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.contacts-about {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-top: 24px;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

.contacts-about__legal {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-color);
}

/* --- 16. PRIVACY PAGE --- */
.privacy-page {
  max-width: 800px;
  padding-top: 8px;
}

.privacy-section {
  margin-bottom: 32px;
  font-size: 0.9375rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.privacy-section h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.privacy-section p {
  margin-bottom: 12px;
}

.privacy-section ul,
.privacy-section ol {
  padding-left: 24px;
  margin-bottom: 12px;
}

.privacy-section li {
  list-style: disc;
  margin-bottom: 6px;
}

.privacy-legal {
  font-size: 0.8125rem;
  color: var(--text-muted);
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

/* --- 17. SITEMAP PAGE --- */
.sitemap-page {
  padding-top: 8px;
}

.sitemap-section {
  margin-bottom: 32px;
}

.sitemap-section h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--orange-100);
}

.sitemap-section ul {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 6px;
}

.sitemap-section li {
  list-style: none;
}

.sitemap-section a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 0;
  color: var(--text-secondary);
  font-size: 0.9375rem;
  transition: color var(--transition-fast);
}

.sitemap-section a:hover {
  color: var(--primary);
}

.sitemap-section a::before {
  content: "→";
  color: var(--orange-300);
  font-size: 0.75rem;
}

/* --- 18. 404 PAGE --- */
.error-page {
  text-align: center;
  padding: 80px 24px;
  max-width: 560px;
  margin: 0 auto;
}

.error-page__code {
  font-family: var(--font-display);
  font-size: clamp(5rem, 12vw, 8rem);
  font-weight: 900;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 12px;
}

.error-page__title {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.error-page__text {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.6;
}

.error-page__search {
  max-width: 400px;
  margin: 0 auto 28px;
}

.error-page__links {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- 19. SEARCH --- */
.search-count {
  font-size: 0.9375rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.search-count strong {
  color: var(--text-primary);
  font-weight: 700;
}

/* --- 20. TEXT (Rich Content) --- */
.text {
  font-size: 0.9375rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.text h1,
.text h2,
.text h3,
.text h4,
.text h5,
.text h6 {
  color: var(--text-primary);
  font-weight: 700;
  margin-top: 24px;
  margin-bottom: 12px;
  line-height: 1.3;
}

.text h2 {
  font-size: 1.5rem;
}
.text h3 {
  font-size: 1.25rem;
}
.text h4 {
  font-size: 1.125rem;
}

.text p {
  margin-bottom: 14px;
}

.text ul,
.text ol {
  padding-left: 24px;
  margin-bottom: 14px;
}

.text li {
  list-style: disc;
  margin-bottom: 6px;
}

.text ol li {
  list-style: decimal;
}

.text a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.text a:hover {
  color: var(--primary-dark);
}

.text img {
  border-radius: var(--radius-md);
  margin: 16px 0;
}

.text blockquote {
  border-left: 4px solid var(--primary);
  padding: 12px 20px;
  margin: 16px 0;
  background: var(--orange-50);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  color: var(--text-secondary);
  font-style: italic;
}

.text table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 0.875rem;
}

.text th,
.text td {
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  text-align: left;
}

.text th {
  background: var(--gray-50);
  font-weight: 700;
  color: var(--text-primary);
}

/* --- 21. FOOTER --- */
.footer {
  background: var(--gray-900);
  color: rgba(255, 255, 255, 0.8);
  margin-top: auto;
}

.footer-main {
  padding: 56px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 40px 48px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

@media (max-width: 992px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px 40px;
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

.footer-col {
  display: flex;
  flex-direction: column;
}

.footer-col--contacts {
  gap: 4px;
}

.footer-col__title {
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 12px;
}

.footer-col__title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: var(--primary);
  border-radius: 1px;
}

.footer-col__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col__list a {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.875rem;
  transition:
    color var(--transition-fast),
    padding-left var(--transition-fast);
  text-decoration: none;
}

.footer-col__list a:hover {
  color: var(--orange-300);
  padding-left: 4px;
}

.footer-social {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.footer-social__link {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.65);
  transition: all var(--transition-base);
  text-decoration: none;
}

.footer-social__link:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-2px);
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 10px;
}

.footer-contact-item svg {
  flex-shrink: 0;
  color: var(--primary);
}

.footer-contact-item a {
  color: rgba(255, 255, 255, 0.75);
  transition: color var(--transition-fast);
  font-weight: 500;
}

.footer-contact-item a:hover {
  color: var(--orange-300);
}

.footer-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 0;
}

.footer-bar > .container {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-bar__inner {
  display: flex;
  align-items: center;
  gap: 20px;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-bar__logo {
  flex-shrink: 0;
}

.footer-bar__logo img {
  height: 32px;
  width: auto;
  opacity: 0.5;
  transition: opacity var(--transition-base);
}

.footer-bar__logo:hover img {
  opacity: 0.8;
}

.footer-bar__text {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
}

.footer-bar__copy {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.4);
}

.footer-bar__legal {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.5;
}

.footer-bar__legal a {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.4);
  transition: color var(--transition-fast);
  text-decoration: none;
}

.footer-bar__legal a:hover {
  color: rgba(255, 255, 255, 0.7);
}

/* --- 22. MODALS --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(28, 25, 23, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-smooth);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.popup-form {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 40px;
  max-width: 440px;
  width: calc(100% - 32px);
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.97);
  opacity: 0;
  pointer-events: none;
  transition: all var(--transition-slow);
  box-shadow: var(--shadow-2xl);
  z-index: 1001;
}

.popup-form.active {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.popup-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  font-size: 1.25rem;
  color: var(--text-muted);
  transition: all var(--transition-fast);
  cursor: pointer;
}

.popup-close:hover {
  background: var(--gray-100);
  color: var(--text-primary);
}

.popup-form__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-lg);
  background: var(--orange-50);
  color: var(--primary);
  font-size: 1.5rem;
  margin-bottom: 16px;
}

.popup-form__title {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.popup-form__subtitle {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 24px;
  line-height: 1.5;
}

.popup-form__field {
  margin-bottom: 16px;
}

.popup-form__field input,
.popup-form__field textarea {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  font-size: 0.9375rem;
  background: var(--gray-50);
  transition: all var(--transition-base);
  color: var(--text-primary);
}

.popup-form__field input::placeholder,
.popup-form__field textarea::placeholder {
  color: var(--gray-400);
}

.popup-form__field input:focus,
.popup-form__field textarea:focus {
  border-color: var(--primary);
  background: var(--white);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.1);
}

.popup-form__field textarea {
  min-height: 100px;
  resize: vertical;
}

.popup-form__field input.input-error {
  border-color: #ef4444;
  background: #fef2f2;
}

.popup-form__field input.input-error:focus {
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1);
}

.popup-form__success {
  text-align: center;
  padding: 20px 0;
}

.popup-form__success h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.popup-form__success p {
  color: var(--text-muted);
  font-size: 0.9375rem;
}

/* --- 23. COOKIE BANNER --- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 4000;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-top: 1px solid var(--glass-border);
  padding: 16px var(--container-pad);
  box-shadow: 0 -4px 20px rgba(28, 25, 23, 0.06);
  animation: slideUpBanner 400ms ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  max-width: 100%;
}

@keyframes slideUpBanner {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.cookie-banner__content {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.cookie-banner__content a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-banner__actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

/* --- 24. MOBILE PHONE BUTTON --- */
.mobile-phone-btn {
  display: none;
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-full);
  background: var(--accent-gradient);
  color: var(--white);
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-orange-lg);
  z-index: 900;
  font-size: 1.25rem;
  animation: phoneGlow 2s ease-in-out infinite;
  text-decoration: none;
  border: none;
  cursor: pointer;
}

@keyframes phoneGlow {
  0%,
  100% {
    box-shadow: 0 4px 14px rgba(249, 115, 22, 0.3);
  }
  50% {
    box-shadow: 0 4px 28px rgba(249, 115, 22, 0.5);
  }
}

@media (max-width: 768px) {
  .mobile-phone-btn {
    display: flex;
  }
}

/* --- 25. SCROLL ANIMATIONS --- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 600ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children animation */
.product-grid .animate-on-scroll:nth-child(1) {
  transition-delay: 50ms;
}
.product-grid .animate-on-scroll:nth-child(2) {
  transition-delay: 100ms;
}
.product-grid .animate-on-scroll:nth-child(3) {
  transition-delay: 150ms;
}
.product-grid .animate-on-scroll:nth-child(4) {
  transition-delay: 200ms;
}
.product-grid .animate-on-scroll:nth-child(5) {
  transition-delay: 250ms;
}
.product-grid .animate-on-scroll:nth-child(6) {
  transition-delay: 300ms;
}
.product-grid .animate-on-scroll:nth-child(7) {
  transition-delay: 350ms;
}
.product-grid .animate-on-scroll:nth-child(8) {
  transition-delay: 400ms;
}

/* --- 26. RESPONSIVE — TABLET (max-width: 768px) --- */
@media (max-width: 768px) {
  :root {
    --container-pad: 16px;
  }

  .header-top {
    font-size: 0.75rem;
    padding: 4px 0;
  }

  .header-top__inner {
    flex-direction: column;
    gap: 4px;
  }

  .header-top__address {
    display: none;
  }

  .header-main {
    padding: 10px 0;
  }

  .header-main > .container {
    gap: 12px;
  }

  .header-logo img {
    height: 36px;
  }

  .header-search {
    max-width: none;
    order: 10;
    flex-basis: 100%;
  }

  .header-search__input {
    padding: 10px 44px 10px 16px;
    font-size: 0.875rem;
  }

  .header-search__btn {
    width: 36px;
    height: 36px;
  }

  .header-nav {
    display: none;
  }

  .header-burger {
    display: flex;
    margin-left: auto;
  }

  .hero-carousel {
    border-radius: var(--radius-lg);
    margin-bottom: 28px;
  }

  .hero-carousel__slide {
    aspect-ratio: 1.6 / 1;
  }

  .hero-carousel__content {
    padding: 24px 28px;
  }

  .hero-carousel__arrow {
    width: 36px;
    height: 36px;
  }

  .hero-banner {
    padding: 36px 24px;
    border-radius: var(--radius-lg);
    margin-bottom: 28px;
  }

  .section {
    margin-bottom: 36px;
  }

  .section-header {
    margin-bottom: 20px;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
    gap: 12px;
  }

  .product-card__body {
    padding: 12px;
  }

  .product-card__name {
    font-size: 0.8125rem;
  }

  .product-card__price {
    font-size: 1rem;
  }

  .product-card__footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .product-detail {
    grid-template-columns: 1fr;
  }

  .product-detail__gallery {
    min-height: 280px;
    padding: 20px;
  }

  .product-detail__badges {
    grid-template-columns: 1fr 1fr;
  }

  .product-tabs__tab {
    padding: 10px 16px;
    font-size: 0.8125rem;
  }

  .filter-bar {
    padding: 16px;
  }

  .filter-form {
    flex-direction: column;
    gap: 12px;
  }

  .filter-group {
    width: 100%;
  }

  .filter-input,
  .filter-select {
    width: 100%;
  }

  .company-cta {
    padding: 32px 24px;
  }

  .contacts-card {
    padding: 24px;
  }

  .popup-form {
    padding: 28px 24px;
    max-width: calc(100% - 24px);
    width: calc(100% - 24px);
  }

  .brands-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
  }

  .brand-detail__header {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* --- 27. RESPONSIVE — MOBILE (max-width: 480px) --- */
@media (max-width: 480px) {
  .header-top__left,
  .header-top__right {
    gap: 10px;
    font-size: 0.6875rem;
  }

  .header-main > .container {
    flex-wrap: wrap;
  }

  .header-logo img {
    height: 32px;
  }

  .hero-carousel__slide {
    aspect-ratio: 1.2 / 1;
  }

  .hero-carousel__content {
    padding: 20px;
  }

  .hero-carousel__title {
    font-size: 1.25rem;
  }

  .hero-carousel__subtitle {
    font-size: 0.8125rem;
  }

  .hero-carousel__btn {
    padding: 10px 24px;
    font-size: 0.875rem;
  }

  .hero-carousel__arrow {
    width: 32px;
    height: 32px;
    font-size: 1rem;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .product-card__img {
    padding: 10px;
  }

  .product-card__body {
    padding: 10px;
  }

  .product-card__name {
    font-size: 0.75rem;
    -webkit-line-clamp: 2;
  }

  .product-card__price {
    font-size: 0.9375rem;
  }

  .product-card__badge {
    font-size: 0.625rem;
    padding: 3px 8px;
  }

  .product-detail__title {
    font-size: 1.25rem;
  }

  .product-detail__price {
    font-size: 1.5rem;
  }

  .product-detail__badges {
    grid-template-columns: 1fr;
  }

  .page-title {
    font-size: 1.25rem;
  }

  .section-header__title {
    font-size: 1.125rem;
  }

  .footer-main {
    padding: 36px 0 28px;
  }

  .pagination {
    gap: 4px;
  }

  .pagination a,
  .pagination__link {
    min-width: 36px;
    height: 36px;
    font-size: 0.8125rem;
  }

  .subcategories {
    gap: 6px;
  }

  .subcategory-tag {
    padding: 6px 12px;
    font-size: 0.75rem;
  }

  .breadcrumbs {
    font-size: 0.75rem;
  }

  .error-page {
    padding: 48px 16px;
  }

  .company-highlights {
    grid-template-columns: 1fr 1fr;
  }

  .company-values {
    grid-template-columns: 1fr;
  }

  .brands-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .brands-grid__card {
    padding: 16px;
  }

  .brands-grid__logo {
    width: 80px;
    height: 48px;
  }

  .cookie-banner__content {
    font-size: 0.75rem;
  }

  .cookie-banner__actions {
    flex-direction: column;
  }

  .chars-table__row {
    flex-direction: column;
    gap: 2px;
  }

  .chars-table__dots {
    display: none;
  }

  .chars-table__value {
    text-align: left;
  }
}

/* --- 28. UTILITY — PRINT --- */
@media print {
  .header,
  .footer,
  .mobile-phone-btn,
  .cookie-banner,
  .modal-overlay,
  .mobile-overlay,
  .mobile-menu {
    display: none !important;
  }

  .main-content {
    padding-top: 0;
  }

  body {
    background: white;
    color: black;
  }

  .product-card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ddd;
  }
}

/* --- 29. ACCESSIBILITY --- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .animate-on-scroll {
    opacity: 1;
    transform: none;
  }

  .hero-carousel__track {
    transition-duration: 0.01ms !important;
  }
}

/* --- 30. DARK MODE PREP (optional, respects system) --- */
@media (prefers-color-scheme: dark) {
  /* Intentionally empty — light mode only for this brand.
       Keeping this block as a hook for future dark mode. */
}

/* --- 31. MEGA MENU FIX — full-width positioning --- */
.header-nav {
  position: relative;
}

.nav__dropdown {
  position: static;
}

.mega-menu {
  left: 0;
  right: 0;
  border-top: 3px solid var(--primary);
  border-radius: 0 0 20px 20px;
}

.mega-menu::-webkit-scrollbar {
  width: 5px;
}

.mega-menu::-webkit-scrollbar-track {
  background: transparent;
  margin: 12px 0;
}

.mega-menu::-webkit-scrollbar-thumb {
  background: var(--orange-200);
  border-radius: 10px;
}

.mega-menu::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* --- 32. SMOOTH SCROLLBAR --- */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
  background: var(--gray-300);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gray-400);
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--gray-300) var(--gray-100);
}

/* --- 33. INPUT ERROR STATE --- */
.input-error {
  border-color: #ef4444 !important;
  background: #fef2f2 !important;
}

.input-error:focus {
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1) !important;
}

/* --- 34. LOADING SKELETON (bonus) --- */
@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--gray-100) 25%,
    var(--gray-50) 50%,
    var(--gray-100) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s ease infinite;
  border-radius: var(--radius-md);
}

/* --- 35. HEADER MAIN FLEX WRAP FIX --- */
@media (max-width: 768px) {
  .header-main > .container {
    flex-wrap: wrap;
  }

  .header-search {
    order: 10;
    flex-basis: 100%;
    max-width: 100%;
  }
}

/* --- 36. CARD GLASS EFFECT ON HOVER --- */
.product-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(
    180deg,
    rgba(249, 115, 22, 0.02) 0%,
    transparent 100%
  );
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  opacity: 0;
  transition: opacity var(--transition-base);
  pointer-events: none;
  z-index: 0;
}

.product-card:hover::before {
  opacity: 1;
}

/* --- 37. ADDITIONAL LINK UNDERLINE EFFECTS --- */
.nav__item::after {
  content: "";
  position: absolute;
  bottom: 4px;
  left: 16px;
  right: 16px;
  height: 2px;
  background: var(--white);
  border-radius: 1px;
  transform: scaleX(0);
  transition: transform var(--transition-base);
}

.nav__item:hover::after {
  transform: scaleX(1);
}

/* --- 38. FOCUS STATES FOR FORM ELEMENTS --- */
.filter-checkbox input:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.filter-select:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* --- 39. SMOOTH CARD IMAGE LOADING --- */
.product-card__img img,
.mega-menu__img,
.brands-grid__logo {
  opacity: 1;
  transition:
    opacity var(--transition-base),
    transform var(--transition-smooth);
}

/* ============================================
   SECTION 40: CATALOG LAYOUT WITH FILTER SIDEBAR
   ============================================ */

/* --- Catalog two-column layout --- */
.catalog-layout {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  margin-top: 24px;
}

.catalog-content {
  flex: 1;
  min-width: 0;
}

/* --- Filter toggle button (mobile) --- */
.filter-toggle-btn {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--white);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
  margin-bottom: 16px;
}

.filter-toggle-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.filter-badge {
  color: var(--primary);
  font-size: 0.6rem;
  line-height: 1;
}

/* --- Sidebar overlay (mobile) --- */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 299;
  backdrop-filter: blur(2px);
}

.sidebar-overlay.is-visible {
  display: block;
}

/* --- Filter Sidebar --- */
.filter-sidebar {
  width: 272px;
  flex-shrink: 0;
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: sticky;
  top: 96px; /* below fixed header */
  max-height: calc(100vh - 112px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--gray-200) transparent;
}

.filter-sidebar::-webkit-scrollbar {
  width: 4px;
}

.filter-sidebar::-webkit-scrollbar-thumb {
  background: var(--gray-200);
  border-radius: 4px;
}

/* --- Sidebar header (visible on mobile) --- */
.sidebar-header {
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-light);
  background: var(--gray-50);
}

.sidebar-header__title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.sidebar-close-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 4px;
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast);
}

.sidebar-close-btn:hover {
  color: var(--text-primary);
}

/* --- Sidebar sections --- */
.sidebar-section {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-light);
}

.sidebar-section:last-child {
  border-bottom: none;
}

.sidebar-section__title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

/* --- Price range inputs --- */
.price-range-inputs {
  display: flex;
  align-items: center;
  gap: 8px;
}

.price-range-input {
  flex: 1;
  min-width: 0;
  padding: 9px 12px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  background: var(--gray-50);
  color: var(--text-primary);
  transition: all var(--transition-fast);
  -moz-appearance: textfield;
}

.price-range-input::-webkit-inner-spin-button,
.price-range-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

.price-range-input:focus {
  border-color: var(--primary);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.08);
  outline: none;
}

.price-range-sep {
  color: var(--gray-300);
  font-size: 1rem;
  flex-shrink: 0;
}

/* --- Sidebar accordion button --- */
.sidebar-accordion-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  background: none;
  border: none;
  padding: 0;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
  transition: color var(--transition-fast);
}

.sidebar-accordion-btn > span:first-child {
  flex: 1;
}

.sidebar-accordion-btn:hover {
  color: var(--primary);
}

.accordion-arrow {
  flex-shrink: 0;
  transition: transform var(--transition-base);
}

.sidebar-accordion-btn.is-open .accordion-arrow {
  transform: rotate(180deg);
}

.sidebar-selected-count {
  font-size: 0.6875rem;
  font-weight: 700;
  color: var(--primary);
  background: var(--orange-50);
  padding: 1px 6px;
  border-radius: var(--radius-full);
}

/* --- Accordion body --- */
.sidebar-accordion-body {
  display: none;
  margin-top: 12px;
  animation: sidebarAccordionOpen 0.18s ease;
}

.sidebar-accordion-body.is-open {
  display: block;
}

@keyframes sidebarAccordionOpen {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sidebar-accordion-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

/* --- Attribute group within accordion --- */
.sidebar-attr-group + .sidebar-attr-group {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--border-light);
}

.sidebar-attr-name {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 8px;
}

/* --- Sidebar search input --- */
.sidebar-search-wrap {
  margin-bottom: 8px;
}

.sidebar-search {
  width: 100%;
  padding: 7px 10px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 0.8125rem;
  background: var(--gray-50);
  color: var(--text-primary);
  transition: all var(--transition-fast);
}

.sidebar-search:focus {
  border-color: var(--primary);
  outline: none;
  background: var(--white);
}

/* --- Checkbox list --- */
.sidebar-checkbox-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 220px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--gray-200) transparent;
  padding-right: 2px;
}

.sidebar-checkbox-list::-webkit-scrollbar {
  width: 3px;
}

.sidebar-checkbox-list::-webkit-scrollbar-thumb {
  background: var(--gray-200);
}

/* --- Custom checkbox --- */
.sidebar-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}

.sidebar-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.sidebar-checkbox__mark {
  flex-shrink: 0;
  width: 17px;
  height: 17px;
  border: 1.5px solid var(--border-color);
  border-radius: 4px;
  background: var(--white);
  transition: all var(--transition-fast);
  position: relative;
  margin-top: 1px;
}

.sidebar-checkbox input:checked ~ .sidebar-checkbox__mark {
  background: var(--primary);
  border-color: var(--primary);
}

.sidebar-checkbox input:checked ~ .sidebar-checkbox__mark::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 5px;
  width: 5px;
  height: 9px;
  border: 2px solid white;
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}

.sidebar-checkbox:hover .sidebar-checkbox__mark {
  border-color: var(--primary);
}

.sidebar-checkbox__label {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.4;
  transition: color var(--transition-fast);
}

.sidebar-checkbox:hover .sidebar-checkbox__label {
  color: var(--text-primary);
}

.sidebar-count {
  font-style: normal;
  color: var(--text-muted);
  font-size: 0.75rem;
}

/* --- Sidebar action buttons --- */
.sidebar-actions {
  padding: 16px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sidebar-apply-btn {
  display: block;
  width: 100%;
  padding: 11px 20px;
  background: var(--accent-gradient);
  color: var(--white);
  font-weight: 700;
  font-size: 0.875rem;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
  text-align: center;
}

.sidebar-apply-btn:hover {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-orange);
  transform: translateY(-1px);
}

.sidebar-reset-btn {
  display: block;
  width: 100%;
  padding: 9px 20px;
  background: transparent;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.8125rem;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.sidebar-reset-btn:hover {
  border-color: var(--gray-400);
  color: var(--text-primary);
}

/* --- Catalog top bar (count + sort) --- */
.catalog-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.catalog-topbar__count {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.catalog-topbar__count strong {
  color: var(--text-primary);
  font-weight: 700;
}

.catalog-topbar__sort {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-sort-label {
  font-size: 0.8125rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.topbar-sort-select {
  padding: 8px 30px 8px 12px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 0.8125rem;
  background: var(--gray-50)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2378716C' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E")
    no-repeat right 10px center;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  color: var(--text-primary);
  transition: border-color var(--transition-fast);
}

.topbar-sort-select:focus {
  border-color: var(--primary);
  outline: none;
}

/* --- Active filter tags --- */
.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.active-filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: var(--orange-50);
  border: 1px solid var(--orange-200);
  border-radius: var(--radius-full);
  font-size: 0.8125rem;
  color: var(--primary-dark);
  font-weight: 500;
}

.active-filter-tag__remove {
  color: var(--primary);
  text-decoration: none;
  font-size: 1rem;
  line-height: 1;
  font-weight: 700;
  transition: color var(--transition-fast);
}

.active-filter-tag__remove:hover {
  color: var(--primary-deeper);
}

/* --- Inline "clear all" link inside active filters row --- */
.active-filter-clear {
  display: inline-flex;
  align-items: center;
  padding: 5px 4px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  border-bottom: 1px dashed var(--text-muted);
  transition: color var(--transition-fast), border-color var(--transition-fast);
}

.active-filter-clear:hover {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

/* ============================================
   HOMEPAGE CATEGORIES GRID (vseinstrumenti-style)
   ============================================ */
.home-categories {
  display: grid;
  /* minmax(0,1fr) — критично: без этого большие фото «распирают» ячейки */
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.home-cat-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0; /* запрет на blowout грид-ячейки */
  min-height: 230px;
  max-height: 280px;
  padding: 16px 16px 12px;
  background: var(--gray-50);
  border: 1px solid transparent;
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--text-primary);
  overflow: hidden;
  transition: border-color var(--transition-base),
              background var(--transition-base),
              transform var(--transition-base),
              box-shadow var(--transition-base);
}

.home-cat-card:hover {
  background: var(--white);
  border-color: var(--orange-200);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  color: var(--text-primary);
}

.home-cat-card__text {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.home-cat-card__title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--text-primary);
  transition: color var(--transition-fast);
}

.home-cat-card:hover .home-cat-card__title {
  color: var(--primary-dark);
}

.home-cat-card__count {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
}

.home-cat-card__img-wrap {
  margin-top: auto;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  width: 100%;
  height: 130px;
  overflow: hidden;
}

.home-cat-card__img {
  max-height: 130px;
  max-width: 100%;
  width: auto;
  object-fit: contain;
  transform: scale(1.1);
  transition: transform var(--transition-base);
}

.home-cat-card:hover .home-cat-card__img {
  transform: scale(1.18);
}

.home-cat-card__img--ph {
  opacity: 0.35;
}

@media (max-width: 1200px) {
  .home-categories { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .home-categories { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .home-categories { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .home-cat-card { min-height: 190px; padding: 14px 14px 10px; }
  .home-cat-card__img-wrap { height: 100px; }
  .home-cat-card__img { max-height: 100px; }
}
@media (max-width: 480px) {
  .home-categories { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-cat-card__title { font-size: 0.875rem; }
}

/* --- Empty catalog state --- */
.empty-catalog {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 60px 20px;
  color: var(--text-muted);
  text-align: center;
}

.empty-catalog svg {
  opacity: 0.3;
}

.empty-catalog p {
  font-size: 1rem;
  color: var(--text-muted);
}

/* ============================================
   RESPONSIVE: catalog sidebar
   ============================================ */

@media (max-width: 1024px) {
  .filter-sidebar {
    width: 240px;
  }
  .catalog-layout {
    gap: 20px;
  }
}

@media (max-width: 860px) {
  /* Collapse sidebar to drawer on mobile */
  .filter-toggle-btn {
    display: inline-flex;
  }

  .catalog-layout {
    display: block;
    margin-top: 0;
  }

  .filter-sidebar {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100dvh;
    max-height: 100dvh;
    z-index: 300;
    border-radius: 0;
    border: none;
    box-shadow: var(--shadow-2xl);
    transition: left 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .filter-sidebar.is-open {
    left: 0;
  }

  .sidebar-header {
    display: flex;
  }
}

@media (max-width: 640px) {
  .catalog-topbar {
    gap: 10px;
  }

  .topbar-sort-label {
    display: none;
  }
}

/* --- END OF SECTION 40 --- */

/* --- END OF STYLESHEET --- */
