/* ==========================================================================
   VFD HEADER 2026 — шапка страниц товара
   --------------------------------------------------------------------------
   Подключается только при body_class (страница товара), после product-vfd.css.
   Задача: убрать «слепые» зоны темы (тёмный текст на тёмном, светлый на
   светлом), собрать аккуратную двухуровневую шапку и дать ей нормальное
   поведение на всех ширинах.
   ========================================================================== */

html.body-product {
  --vfd-header-h: 86px;
  --vfd-header-top-h: 40px;
  --vfd-header-line: rgba(27, 25, 22, 0.12);
  --vfd-header-line-soft: rgba(27, 25, 22, 0.08);
  --vfd-header-muted: #6d655a;
  --vfd-header-ink: #1b1916;
  --vfd-header-gold: #7c6636;
  scroll-padding-top: calc(var(--vfd-header-h) + 16px);
}

/* --------------------------------------------------------------------------
   1. Верхняя служебная полоса
   -------------------------------------------------------------------------- */

html.body-product #top {
  height: var(--vfd-header-top-h);
  background: #f4efe5;
  border-bottom: 1px solid var(--vfd-header-line-soft);
  color: #4a4338;
  font-size: 11.5px;
  line-height: 1.3;
}

html.body-product #top > .container {
  height: 100%;
  align-items: center;
}

html.body-product #top .top-nav-info-list {
  align-items: center;
  margin: 0;
  padding: 0;
}

html.body-product #top .top-nav-info-list > li {
  border-right-color: rgba(27, 25, 22, 0.16);
  padding: 0 12px;
}

html.body-product #top .top-nav-info-list > li:first-child {
  padding-left: 0;
}

html.body-product #top .top-nav-info-list > li:last-child {
  padding-right: 0;
  border-right: 0;
}

html.body-product #top a,
html.body-product #top .link_zamer_head,
html.body-product #top .top-nav-account-links-item > span,
html.body-product #top .top-nav-account-links-item button {
  color: #4a4338;
  text-decoration: none;
  transition: color 0.18s ease;
}

html.body-product #top a:hover,
html.body-product #top .link_zamer_head:hover,
html.body-product #top .top-nav-account-links-item:hover > a,
html.body-product #top .top-nav-account-links-item:hover > span,
html.body-product #top .top-nav-account-links-item button:hover {
  color: var(--vfd-header-gold);
  text-decoration: none;
}

html.body-product #top .top-nav-info-list a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

html.body-product #top .top-nav-info-list a svg {
  flex: 0 0 auto;
  width: 13px;
  height: 13px;
}

/* Иконки в теме залиты фиксированными цветами — приводим к палитре шапки. */
html.body-product #top svg path {
  fill: #4a4338;
}

html.body-product #top .link_zamer_head svg path {
  fill: var(--vfd-header-gold);
}

html.body-product #top .social-head-list svg path {
  fill: #4a4338;
}

html.body-product #top .social-head-list a:hover svg path {
  fill: var(--vfd-header-gold);
}

html.body-product #top .mail-link-header {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 26px;
  margin-right: 18px;
  font-weight: 500;
}

html.body-product #top .mail-link-header svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

html.body-product #top .link_zamer_head {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 26px;
  cursor: pointer;
}

html.body-product #top .social-head-top {
  margin: 0 12px;
}

html.body-product #top .social-head-list {
  display: flex;
  align-items: center;
  gap: 4px;
}

html.body-product #top .social-head-list a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 26px;
}

html.body-product #top .social-head-list svg {
  width: 20px;
  height: 18px;
}

html.body-product #top .rm-header-address {
  order: 0;
  flex: 0 1 auto;
  margin: 0;
  padding: 0 18px;
  color: var(--vfd-header-muted);
  min-width: 0;
}

html.body-product #top .rm-header-address .rm-dropdown-toggle {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  line-height: 1.3;
}

html.body-product #top .rm-header-address .rm-dropdown-toggle > span:first-child {
  color: var(--vfd-header-muted);
  flex: 0 0 auto;
}

html.body-product #top .rm-header-address-link {
  overflow: hidden;
  color: #4a4338;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html.body-product #top .top-info-navhead {
  display: block;
  order: 1;
  flex: 1 1 auto;
  min-width: 0;
}

html.body-product #top .top-info-navhead ul {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 1.4vw, 20px);
  margin: 0;
  padding: 0 10px;
  list-style: none;
}

html.body-product #top .top-info-navhead a {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  color: #4a4338;
  font-weight: 500;
  white-space: nowrap;
}

html.body-product #top .top-info-navhead a:hover {
  color: var(--vfd-header-gold);
}

html.body-product #top .top-nav-account-links {
  order: 2;
  align-items: center;
  gap: 14px;
  margin: 0;
  flex: 0 0 auto;
}

html.body-product #top > .container > .top-nav-account-links-item {
  order: 3;
  flex: 0 0 auto;
}

html.body-product #top .top-nav-account-links a {
  margin-right: 0;
}

html.body-product #top .top-nav-account-links-item {
  margin-left: 0;
}

html.body-product #top .top-nav-account-links-item svg {
  width: 18px;
  height: 18px;
}

html.body-product #top .rm-dropdown-toggle::after {
  background: currentColor;
}

/* --------------------------------------------------------------------------
   2. Основная шапка
   -------------------------------------------------------------------------- */

html.body-product header.vfd-header,
html.body-product header {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 1020;
  padding: 0;
  background: #ffffff;
  border-bottom: 1px solid var(--vfd-header-line-soft);
  transition: box-shadow 0.22s ease;
}

html.body-product header.vfd-header.is-scrolled,
html.body-product header.is-scrolled {
  box-shadow: 0 12px 28px -22px rgba(27, 25, 22, 0.42);
}

html.body-product header > .container-fluid {
  max-width: 1600px;
  padding-right: clamp(16px, 3vw, 40px);
  padding-left: clamp(16px, 3vw, 40px);
}

html.body-product header > .container-fluid > .row {
  margin-right: 0;
  margin-left: 0;
}

@media (min-width: 992px) {
  html.body-product header > .container-fluid > .row {
    display: grid;
    grid-template-columns: minmax(210px, 240px) minmax(0, 1fr) auto 186px auto;
    grid-template-areas: 'logo nav contacts search cart';
    align-items: center;
    column-gap: clamp(14px, 1.5vw, 26px);
    min-height: 86px;
  }

  html.body-product header > .container-fluid > .row > div,
  html.body-product header > .container-fluid > .row > nav {
    flex: 0 0 auto;
    width: auto;
    max-width: none;
    padding: 0;
  }

  html.body-product .vfd-header__logo {
    grid-area: logo;
    min-width: 0;
  }

  html.body-product .vfd-header__nav {
    grid-area: nav;
    display: block !important;
    min-width: 0;
  }

  html.body-product .vfd-header__contacts {
    grid-area: contacts;
    justify-self: end;
  }

  html.body-product .vfd-header__search {
    grid-area: search;
    width: 100%;
    min-width: 0;
  }

  html.body-product .vfd-header__cart {
    grid-area: cart;
    justify-self: end;
  }

  html.body-product header #rm-menu,
  html.body-product header .rm-menu {
    display: none !important;
  }

  html.body-product .vfd-header-mobile-call {
    display: none !important;
  }
}

/* Логотип и подпись */

html.body-product header .logo-head-block {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  width: 100%;
  min-width: 0;
}

html.body-product header #logo {
  flex: 0 0 auto;
  max-width: none;
  margin: 0;
  justify-content: flex-start;
}

html.body-product header #logo svg,
html.body-product header #logo img {
  display: block;
  width: 46px;
  height: 46px;
}

html.body-product header #logo svg {
  color: var(--vfd-header-ink);
}

html.body-product header .logo-doptext-block {
  min-width: 0;
  padding-left: 12px;
  border-left: 1px solid var(--vfd-header-line);
}

html.body-product header .logo-doptext-cont {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

html.body-product header .logo-doptext-cont p {
  margin: 0;
  color: var(--vfd-header-muted);
  font-size: 9px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Меню разделов */

html.body-product header .brndvms-cont,
html.body-product header .brndvms-ul {
  display: flex;
  align-items: center;
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}

html.body-product header .brndvms-ul {
  flex-wrap: nowrap;
  gap: clamp(14px, 1.7vw, 30px);
}

html.body-product header .brndvms-ul > li {
  width: auto;
  margin: 0;
  padding: 0;
  border: 0;
}

html.body-product header .brndvms-item,
html.body-product header .brndvms-item-sp {
  color: var(--vfd-header-ink);
  font-family: var(--vfd-sans);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.01em;
  text-align: left;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.18s ease;
}

html.body-product header .brndvms-item {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0;
  justify-content: flex-start;
}

html.body-product header .brndvms-item:hover .brndvms-item-sp,
html.body-product header .brndvms-item:focus-visible .brndvms-item-sp {
  color: var(--vfd-header-gold);
}

html.body-product header .brndvms-item:focus-visible {
  outline: 2px solid var(--vfd-gold);
  outline-offset: 4px;
}

/* Телефоны и кнопка обратного звонка */

html.body-product header .rm-header-phones {
  display: flex;
  align-items: center;
  gap: 10px;
}

html.body-product header .rm-header-phones-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--vfd-header-line);
  border-radius: 50%;
  background: #faf7f0;
}

html.body-product header .rm-header-phones-icon svg {
  width: 17px;
  height: 17px;
  fill: var(--vfd-header-gold);
}

html.body-product header .rm-header-phones-list {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

html.body-product header .rm-header-phones-list-item {
  color: var(--vfd-header-ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
}

html.body-product header .rm-header-phones-list-item + .rm-header-phones-list-item {
  color: var(--vfd-header-muted);
  font-size: 11.5px;
  font-weight: 500;
}

html.body-product header .rm-header-phones-list-item:hover {
  color: var(--vfd-header-gold);
  text-decoration: none;
}

html.body-product header .rm-header-phones-list-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 27px;
  margin-top: 4px;
  padding: 0 10px;
  border: 1px solid rgba(124, 102, 54, 0.38);
  border-radius: 0;
  background: transparent;
  color: var(--vfd-header-gold);
  font-family: var(--vfd-sans);
  font-size: 9.5px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

html.body-product header .rm-header-phones-list-link:hover,
html.body-product header .rm-header-phones-list-link:focus-visible {
  border-color: var(--vfd-header-gold);
  background: var(--vfd-header-gold);
  color: #ffffff;
  text-decoration: none;
}

/* Поиск */

html.body-product header .rm-search {
  height: 42px;
  margin: 0;
}

html.body-product header .rm-search input {
  height: 42px;
  padding: 0 14px 0 42px;
  border: 1px solid #ddd5c6;
  border-radius: 0;
  background: #fbf9f4;
  color: var(--vfd-header-ink);
  font-family: var(--vfd-sans);
  font-size: 12.5px;
  line-height: 40px;
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

html.body-product header .rm-search input::placeholder {
  color: #7a7264;
  font-size: 12px;
}

html.body-product header .rm-search input:focus {
  border-color: var(--vfd-header-gold);
  background: #ffffff;
  outline: 0;
}

html.body-product header .rm-search input:focus::placeholder {
  color: #6d655a;
}

html.body-product header .btn-search {
  width: 42px;
  color: var(--vfd-header-muted);
}

html.body-product header .btn-search img {
  display: none;
}

html.body-product header .btn-search::before {
  content: '';
  display: block;
  width: 18px;
  height: 18px;
  margin: 0 auto;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-4.35-4.35'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-4.35-4.35'/%3E%3C/svg%3E") center / contain no-repeat;
}

html.body-product header .btn-search:hover {
  color: var(--vfd-header-gold);
}

html.body-product header .btn-search:focus-visible {
  outline: 2px solid var(--vfd-gold);
  outline-offset: -2px;
}

html.body-product #rm_livesearch {
  border: 1px solid var(--vfd-header-line);
  border-top: 0;
  box-shadow: 0 18px 34px -24px rgba(27, 25, 22, 0.4);
}

/* Корзина */

html.body-product header .rm-header-cart {
  display: flex !important;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  min-width: 86px;
  min-height: 46px;
  padding: 0 10px;
  border: 1px solid var(--vfd-header-line);
  border-radius: 0;
  background: #fbf9f4;
  box-shadow: none;
  color: var(--vfd-header-ink);
  text-shadow: none;
}

html.body-product header .rm-header-cart:hover,
html.body-product header .rm-header-cart:focus-visible {
  border-color: var(--vfd-header-gold);
  background: #ffffff;
  color: var(--vfd-header-gold);
}

html.body-product header .rm-header-cart-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 21px;
  height: 21px;
  margin: 0;
  left: 0;
}

html.body-product header .rm-header-cart-icon > img {
  width: 21px;
  height: 21px;
}

html.body-product header .rm-header-cart-text {
  display: inline-block;
  margin: 0;
  color: inherit;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}

html.body-product header .rm-header-cart-quantity {
  top: -7px;
  left: 11px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 9px;
  background: var(--vfd-header-ink);
  color: #fbf9f4;
  font-size: 10px;
  font-weight: 600;
  line-height: 17px;
  text-align: center;
}

/* --------------------------------------------------------------------------
   3. Полоса серий под шапкой
   -------------------------------------------------------------------------- */

html.body-product .navigation-profildoors {
  background: #fbf9f4;
  border-top: 1px solid var(--vfd-header-line-soft);
  border-bottom: 1px solid var(--vfd-header-line-soft);
}

html.body-product .navigation-profildoors .navpfdul {
  display: flex;
  align-items: stretch;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  color: #3f3a32;
}

html.body-product .navigation-profildoors .navpfdul::-webkit-scrollbar {
  display: none;
}

html.body-product .navigation-profildoors .nav-pfd-a {
  flex: 1 0 auto;
  width: auto;
  border-right: 1px solid var(--vfd-header-line-soft);
}

html.body-product .navigation-profildoors .nav-pfd-a:last-child {
  border-right: 0;
}

html.body-product .navigation-profildoors .nav-pfd-a a {
  display: block;
  padding: 0 clamp(11px, 1.4vw, 22px);
  background: transparent;
  color: #3f3a32;
  font-family: var(--vfd-sans);
  font-size: 11.5px;
  font-weight: 500;
  line-height: 39px;
  letter-spacing: 0.03em;
  text-align: center;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color 0.18s ease, color 0.18s ease;
}

html.body-product .navigation-profildoors .nav-pfd-a a:hover,
html.body-product .navigation-profildoors .nav-pfd-a a:focus-visible {
  background: #efe8da;
  color: var(--vfd-header-ink);
  text-decoration: none;
}

/* --------------------------------------------------------------------------
   4. Планшет: чуть плотнее, но без потери читаемости
   -------------------------------------------------------------------------- */


@media (max-width: 1399px) {
  html.body-product #top .rm-header-address {
    display: none !important;
  }
}

@media (min-width: 992px) and (max-width: 1199px) {
  html.body-product header > .container-fluid > .row {
    grid-template-columns: minmax(180px, 200px) minmax(0, 1fr) auto 140px auto;
    column-gap: 10px;
    min-height: 80px;
  }

  html.body-product {
    --vfd-header-h: 80px;
  }

  html.body-product header .brndvms-ul {
    gap: 12px;
  }

  html.body-product header .brndvms-item,
  html.body-product header .brndvms-item-sp {
    font-size: 12px;
  }

  html.body-product header .logo-doptext-block {
    display: none;
  }

  html.body-product header .rm-header-phones-icon {
    display: none;
  }

  html.body-product header .rm-header-phones-list-item {
    font-size: 12px;
  }

  html.body-product header .rm-header-phones-list-link {
    padding: 0 8px;
    font-size: 9px;
  }

  html.body-product header .rm-search input {
    padding-left: 36px;
    font-size: 12px;
  }

  html.body-product header .btn-search {
    width: 36px;
  }

  html.body-product header .rm-header-cart {
    min-width: 74px;
    padding: 0 8px;
  }

  html.body-product header .rm-header-cart-text {
    font-size: 11px;
  }
}

@media (min-width: 1200px) and (max-width: 1439px) {
  html.body-product header > .container-fluid > .row {
    grid-template-columns: minmax(200px, 220px) minmax(0, 1fr) auto 160px auto;
    column-gap: 16px;
  }
}

/* --------------------------------------------------------------------------
   5. Мобильная и планшетная шапка (< 992 px)
   -------------------------------------------------------------------------- */

@media (max-width: 991px) {
  html.body-product {
    --vfd-header-h: 0px;
  }

  html.body-product body {
    padding-top: 60px;
  }

  html.body-product header,
  html.body-product header.vfd-header {
    position: relative;
    top: auto;
    z-index: 1020;
    background: #ffffff;
    border-bottom: 1px solid var(--vfd-header-line-soft);
  }

  html.body-product header > .container-fluid {
    padding-right: 66px;
    padding-left: 15px;
  }

  html.body-product header > .container-fluid > .row {
    display: flex;
    flex-direction: row !important;
    flex-wrap: nowrap;
    align-items: center;
    margin: 0;
  }

  html.body-product header > .container-fluid > .row > div {
    width: auto;
    max-width: none;
    padding: 0;
  }

  html.body-product .vfd-header__logo,
  html.body-product .vfd-header__nav,
  html.body-product .vfd-header__contacts {
    display: none !important;
  }

  html.body-product .vfd-header__search {
    order: 2;
    flex: 1 1 auto;
    min-width: 0;
  }

  html.body-product header .rm-search {
    height: 44px;
    margin: 8px 0 9px;
  }

  html.body-product header .rm-search input {
    height: 44px;
    padding: 0 14px 0 42px;
    border-color: #ddd5c6;
    background: #fbf9f4;
    font-size: 13px;
    line-height: 42px;
  }

  html.body-product header .btn-search {
    width: 42px;
  }

  html.body-product #rm_livesearch_close {
    top: 52px;
  }

  /* Кнопка «Позвонить» рядом с поиском */
  html.body-product .vfd-header-mobile-call {
    order: 3;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 46px;
    width: 46px;
    height: 44px;
    margin: 8px 0 9px 8px;
    padding: 0;
    border: 1px solid var(--vfd-header-line);
    border-radius: 0;
    background: #fbf9f4;
    color: var(--vfd-header-ink);
    cursor: pointer;
    transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
  }

  html.body-product .vfd-header-mobile-call svg {
    width: 19px;
    height: 19px;
    fill: currentColor;
  }

  html.body-product .vfd-header-mobile-call:hover,
  html.body-product .vfd-header-mobile-call:focus-visible {
    border-color: var(--vfd-header-gold);
    background: var(--vfd-header-gold);
    color: #ffffff;
  }

  /* Верхняя мобильная панель */
  html.body-product #rm_mobile_nav {
    height: 60px;
    padding: 0 58px 0 15px;
    background: #ffffff;
    border-bottom: 1px solid var(--vfd-header-line-soft);
    box-shadow: 0 8px 22px -20px rgba(27, 25, 22, 0.5);
  }

  html.body-product #rm_mobile_menu_button {
    width: 42px;
    height: 42px;
    padding: 0;
    border-radius: 0;
    background: var(--vfd-header-ink);
    color: #fbf9f4;
  }

  html.body-product #rm_mobile_menu_button .rm-btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    width: 16px;
    height: 14px;
  }

  html.body-product #rm_mobile_menu_button .rm-btn-icon span {
    width: 16px;
    height: 2px;
    background: #fbf9f4;
  }

  html.body-product #rm_mobile_nav .logo-head-block {
    gap: 10px;
    min-width: 0;
  }

  html.body-product #rm_mobile_nav .mobile-logo-block img {
    width: 40px;
    height: 40px;
    object-fit: contain;
  }

  html.body-product #rm_mobile_nav .logo-doptext-block {
    display: block;
    min-width: 0;
    padding-left: 10px;
    border-left: 1px solid var(--vfd-header-line);
  }

  html.body-product #rm_mobile_nav .logo-doptext-cont p {
    margin: 0;
    color: #4a4338;
    font-size: 8px;
    font-weight: 600;
    line-height: 1.5;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  html.body-product #rm_mobile_nav .rm-mobile-nav-buttons-btn {
    height: 60px;
    border-left: 1px solid var(--vfd-header-line-soft);
  }

  html.body-product #rm_mobile_nav .rm-mobile-nav-buttons-btn:hover {
    background: #f4efe5;
  }

  /* Корзина в мобильной панели */
  html.body-product .rm-header-cart {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    left: auto !important;
    right: 0 !important;
    width: 58px !important;
    min-width: 58px !important;
    max-width: 58px;
    height: 60px;
    padding: 0;
    border: 0;
    border-left: 1px solid var(--vfd-header-line-soft);
    border-radius: 0;
    background: #ffffff;
    color: var(--vfd-header-ink);
    text-shadow: none;
  }

  html.body-product .rm-header-cart:hover,
  html.body-product .rm-header-cart:focus-visible {
    background: #f4efe5;
    color: var(--vfd-header-ink);
  }

  html.body-product .rm-header-cart-text {
    display: none;
  }

  html.body-product .rm-header-cart-quantity {
    top: -7px;
    left: 12px;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    border-radius: 9px;
    background: var(--vfd-header-ink);
    color: #fbf9f4;
    font-size: 10px;
    line-height: 17px;
  }

  html.body-product .navigation-profildoors {
    display: block;
    margin-top: 0;
  }

  html.body-product .navigation-profildoors .nav-pfd-a {
    flex: 0 0 auto;
  }

  html.body-product .navigation-profildoors .nav-pfd-a a {
    line-height: 38px;
    padding: 0 14px;
    font-size: 11px;
  }
}

@media (max-width: 575px) {
  html.body-product .navigation-profildoors {
    display: block !important;
  }

  html.body-product .navigation-profildoors .container {
    padding: 0;
  }
}

/* --------------------------------------------------------------------------
   6. Фокус и движение
   -------------------------------------------------------------------------- */

html.body-product header a:focus-visible,
html.body-product header button:focus-visible,
html.body-product header input:focus-visible {
  outline: 2px solid var(--vfd-gold);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  html.body-product header,
  html.body-product header *,
  html.body-product .navigation-profildoors * {
    transition-duration: 0.001ms !important;
  }
}

/* --------------------------------------------------------------------------
   7. Быстрая форма обратного звонка
   -------------------------------------------------------------------------- */

html.body-product .vfd-callback-modal {
  z-index: 32000;
}

html.body-product .vfd-callback-dialog {
  width: calc(100% - 24px);
  max-width: 440px;
  margin: 12px auto;
}

html.body-product .vfd-callback-modal .modal-content {
  overflow: hidden;
  border: 1px solid var(--vfd-header-line);
  border-radius: 2px;
  background: #ffffff;
  box-shadow: 0 34px 80px -44px rgba(27, 25, 22, 0.72);
}

html.body-product .vfd-callback-head {
  position: relative;
  padding: 26px 30px 20px;
  border-bottom: 1px solid var(--vfd-header-line-soft);
  background: #fbf9f4;
}

html.body-product .vfd-callback-eyebrow {
  display: block;
  margin-bottom: 8px;
  color: var(--vfd-header-gold);
  font-family: var(--vfd-sans);
  font-size: 9.5px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

html.body-product .vfd-callback-title {
  max-width: 330px;
  margin: 0 0 7px;
  color: var(--vfd-header-ink);
  font-family: var(--vfd-serif);
  font-size: 29px;
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.01em;
}

html.body-product .vfd-callback-desc {
  max-width: 340px;
  margin: 0;
  color: var(--vfd-header-muted);
  font-family: var(--vfd-sans);
  font-size: 12px;
  line-height: 1.55;
}

html.body-product .vfd-callback-close {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--vfd-header-ink);
  cursor: pointer;
}

html.body-product .vfd-callback-close:hover {
  color: var(--vfd-header-gold);
}

html.body-product .vfd-callback-close svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
}

html.body-product .vfd-callback-modal .modal-body {
  min-height: 0;
  padding: 22px 30px 26px;
}

html.body-product .vfd-callback-modal form {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

html.body-product .vfd-callback-modal .vfd-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

html.body-product .vfd-callback-modal .vfd-field__label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  color: var(--vfd-header-ink);
  font-family: var(--vfd-sans);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

html.body-product .vfd-callback-modal .vfd-field__label .vfd-field__optional {
  color: var(--vfd-header-muted);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: none;
}

html.body-product .vfd-callback-modal .form-control,
html.body-product .vfd-callback-modal input[type='text'],
html.body-product .vfd-callback-modal input[type='tel'] {
  width: 100%;
  height: 48px;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid #cfc6b6;
  border-radius: 0;
  background: #ffffff;
  box-shadow: none;
  color: var(--vfd-header-ink);
  font-family: var(--vfd-sans);
  font-size: 14px;
  line-height: 46px;
}

html.body-product .vfd-callback-modal .form-control::placeholder,
html.body-product .vfd-callback-modal input::placeholder {
  color: #7a7264;
  font-size: 13px;
}

html.body-product .vfd-callback-modal .form-control:focus,
html.body-product .vfd-callback-modal input:focus {
  border-color: var(--vfd-header-gold);
  box-shadow: 0 0 0 1px var(--vfd-header-gold);
  outline: 0;
}

html.body-product .vfd-callback-modal .vfd-field.is-invalid .form-control,
html.body-product .vfd-callback-modal .vfd-field.is-invalid input {
  border-color: #a83a2d;
  box-shadow: 0 0 0 1px #a83a2d;
}

html.body-product .vfd-callback-modal .vfd-field__error {
  display: none;
  color: #9c3326;
  font-family: var(--vfd-sans);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.4;
}

html.body-product .vfd-callback-modal .vfd-field.is-invalid .vfd-field__error {
  display: block;
}

html.body-product .vfd-callback-modal .form-checkbox-group {
  margin: 1px 0 0;
  padding: 0;
}

html.body-product .vfd-callback-modal .form-checkbox-group label,
html.body-product .vfd-callback-modal .vfd-consent {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 0;
  color: var(--vfd-header-muted);
  font-family: var(--vfd-sans);
  font-size: 10.5px;
  font-weight: 400;
  line-height: 1.5;
  cursor: pointer;
}

html.body-product .vfd-callback-modal .form-checkbox-group a {
  color: var(--vfd-header-gold);
  text-decoration: underline;
}

html.body-product .vfd-callback-modal .check-box {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  border: 1px solid #9c9281;
  border-radius: 0;
  background: #ffffff;
}

html.body-product .vfd-callback-modal .rm-form-checkbox-input:checked + .check-box {
  border-color: var(--vfd-header-ink);
  background: var(--vfd-header-ink);
}

html.body-product .vfd-callback-modal .rm-form-checkbox-input:checked + .check-box::after {
  content: '';
  display: block;
  width: 9px;
  height: 5px;
  margin: 4px 0 0 4px;
  border-bottom: 1.6px solid #ffffff;
  border-left: 1.6px solid #ffffff;
  transform: rotate(-45deg);
}

html.body-product .vfd-callback-modal .rm-form-checkbox-input:focus-visible + .check-box {
  outline: 2px solid var(--vfd-gold);
  outline-offset: 2px;
}

html.body-product .vfd-callback-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 52px;
  padding: 0 18px;
  border: 1px solid var(--vfd-gold);
  border-radius: 0;
  background: var(--vfd-gold);
  color: var(--vfd-header-ink);
  font-family: var(--vfd-sans);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

html.body-product .vfd-callback-submit svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

html.body-product .vfd-callback-submit:hover,
html.body-product .vfd-callback-submit:focus-visible {
  border-color: var(--vfd-header-ink);
  background: var(--vfd-header-ink);
  color: #fbf9f4;
}

html.body-product .vfd-callback-submit:disabled,
html.body-product .vfd-callback-submit.is-loading {
  cursor: wait;
  opacity: 0.72;
}

html.body-product .vfd-callback-submit.is-loading::before {
  content: '';
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: vfd-callback-spin 0.7s linear infinite;
}

html.body-product .vfd-callback-note {
  margin: 0;
  color: var(--vfd-header-muted);
  font-family: var(--vfd-sans);
  font-size: 10px;
  line-height: 1.5;
  text-align: center;
}

html.body-product .vfd-callback-alert {
  padding: 9px 11px;
  border-left: 2px solid #a83a2d;
  background: #fbf0ed;
  color: #7f2b21;
  font-family: var(--vfd-sans);
  font-size: 11.5px;
  line-height: 1.45;
}

html.body-product .vfd-callback-modal .rm-popup-success {
  padding: 12px 0 4px;
  text-align: center;
}

html.body-product .vfd-callback-modal .rm-popup-success img {
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
}

html.body-product .vfd-callback-modal .rm-popup-success p {
  margin: 0 0 8px;
  color: var(--vfd-header-ink);
  font-family: var(--vfd-sans);
  font-size: 13px;
  line-height: 1.6;
}

html.body-product .vfd-callback-modal .rm-popup-success .rm-btn {
  min-height: 44px;
  margin-top: 10px;
  border: 1px solid var(--vfd-header-ink);
  border-radius: 0;
  background: var(--vfd-header-ink);
  color: #fbf9f4;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Загрузка */

html.body-product .vfd-callback-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 260px;
  padding: 40px 24px;
  background: #ffffff;
}

html.body-product .vfd-callback-loading p {
  margin: 0;
  color: var(--vfd-header-muted);
  font-family: var(--vfd-sans);
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}

html.body-product .vfd-callback-loading .vfd-callback-loading__error {
  color: var(--vfd-header-ink);
  font-size: 12.5px;
}

html.body-product .vfd-callback-loading a {
  color: var(--vfd-header-gold);
}

html.body-product .vfd-callback-spinner {
  width: 26px;
  height: 26px;
  border: 2px solid #d6ccba;
  border-top-color: var(--vfd-header-gold);
  border-radius: 50%;
  animation: vfd-callback-spin 0.8s linear infinite;
}

@keyframes vfd-callback-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 575px) {
  html.body-product .vfd-callback-dialog {
    width: 100%;
    max-width: none;
    margin: 0;
  }

  html.body-product .vfd-callback-modal .modal-content {
    min-height: 100dvh;
    border: 0;
    border-radius: 0;
  }

  html.body-product .vfd-callback-head {
    padding: 24px 18px 18px;
  }

  html.body-product .vfd-callback-title {
    max-width: 260px;
    font-size: 25px;
  }

  html.body-product .vfd-callback-modal .modal-body {
    padding: 18px 18px calc(20px + env(safe-area-inset-bottom, 0px));
  }

  html.body-product .vfd-callback-modal .vfd-callback-close {
    width: 44px;
    height: 44px;
  }
}

/* Табы товара не должны прятаться под липкой шапкой */
@media (min-width: 992px) {
  html.body-product .nav-tabs-prod {
    top: var(--vfd-header-h, 86px);
  }
}


/* --------------------------------------------------------------------------
   8. Детерминированные отступы для якорей и липких табов
   Высота шапки = основная строка + полоса серий.
   -------------------------------------------------------------------------- */

@media (min-width: 1200px) {
  html.body-product {
    scroll-padding-top: 144px;
  }

  html.body-product .nav-tabs-prod {
    top: 128px;
  }
}

@media (min-width: 992px) and (max-width: 1199px) {
  html.body-product {
    scroll-padding-top: 138px;
  }

  html.body-product .nav-tabs-prod {
    top: 122px;
  }
}

@media (max-width: 991px) {
  html.body-product {
    scroll-padding-top: 72px;
  }
}
