/* ==========================================================================
   v2 — header. Изолирован маршрутом common/home_v2: остальные страницы
   продолжают использовать штатную шапку Journal2.
   ========================================================================== */

html.v2-header-active .v2-site-header {
  --v2-header-bg: #fff;
  --v2-header-paper: #f8f7f6;
  --v2-header-tint: #f3eefa;
  --v2-header-lilac: #b999e4;
  --v2-header-violet: #76508f;
  --v2-header-violet-dark: #68427f;
  --v2-header-ink: #302f30;
  --v2-header-muted: rgba(48, 47, 48, .62);
  --v2-header-line: rgba(48, 47, 48, .09);
  --v2-header-font: 'Inter v2', 'Helvetica Neue', Arial, sans-serif;
  position: relative;
  z-index: 1000;
  display: block !important;
  width: 100%;
  background: var(--v2-header-bg);
  color: var(--v2-header-ink);
  font-family: var(--v2-header-font);
}

html.v2-header-active .v2-site-header,
html.v2-header-active .v2-site-header *,
html.v2-header-active .v2-site-header *::before,
html.v2-header-active .v2-site-header *::after { box-sizing: border-box; }

html.v2-header-active .v2-site-header a { color: inherit; text-decoration: none; }
html.v2-header-active .v2-site-header button { font-family: inherit; }
html.v2-header-active .v2-journal-cart-sentinel {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  display: block !important;
  width: 0 !important;
  height: 0 !important;
  min-width: 0 !important;
  min-height: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

html.v2-header-active .v2-site-header a:focus-visible,
html.v2-header-active .v2-site-header button:focus-visible,
html.v2-header-active .v2-site-header input:focus-visible {
  outline: 2px solid var(--v2-header-lilac);
  outline-offset: 2px;
}

html.v2-header-active .v2-header-wrap {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding-right: 32px;
  padding-left: 32px;
}

/* Notice: самостоятельный короткий слой без старого Journal-модуля. */
html.v2-header-active .v2-site-header__notice {
  height: 32px;
  overflow: hidden;
  background: var(--v2-header-lilac);
  color: #fff;
  transition: height 180ms ease-out, opacity 180ms ease-out;
}

html.v2-header-active .v2-site-header__notice .v2-header-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: .02em;
}

html.v2-header-active .v2-notice-close {
  position: absolute;
  top: 0;
  right: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
  opacity: .78;
  transition: opacity 160ms ease-out;
}

html.v2-header-active .v2-notice-close:hover { opacity: 1; }
html.v2-header-active .v2-notice-close svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; }
html.v2-header-active .v2-site-header.is-notice-closed .v2-site-header__notice { height: 0; opacity: 0; }

/* Основная строка: logo 3 cols / search 5 cols / actions 4 cols. */
html.v2-header-active .v2-site-header__core {
  position: relative;
  z-index: 3;
  background: var(--v2-header-bg);
}

html.v2-header-active .v2-site-header__grid {
  display: grid;
  grid-template-columns: 240px minmax(420px, 500px) minmax(0, 1fr);
  align-items: center;
  gap: 32px;
  height: 68px;
}

html.v2-header-active .v2-menu-toggle { display: none !important; }

html.v2-header-active .v2-site-header__logo {
  display: flex;
  align-items: center;
  min-width: 0;
}

html.v2-header-active .v2-site-header__logo a { display: inline-flex; align-items: center; }
html.v2-header-active .v2-site-header__logo img {
  display: block;
  width: 100% !important;
  max-width: 240px !important;
  height: auto !important;
  max-height: 38px !important;
}

/* Штатный OpenCart search сохраняет autocomplete и навигацию по Enter. */
html.v2-header-active .v2-site-header__search { min-width: 0; }
html.v2-header-active .v2-site-header__search #search {
  position: relative !important;
  display: flex !important;
  width: 100% !important;
  height: 44px !important;
  min-height: 44px !important;
  float: none !important;
  border: 1px solid transparent !important;
  border-radius: 12px !important;
  background: var(--v2-header-tint) !important;
  box-shadow: none !important;
  transition: border-color 160ms ease-out, background 160ms ease-out;
}

html.v2-header-active .v2-site-header__search #search:focus-within {
  border-color: #c7aacb !important;
  background: #fff !important;
}

html.v2-header-active .v2-site-header__search #search input {
  flex: 1 1 auto !important;
  width: auto !important;
  height: 42px !important;
  min-height: 42px !important;
  margin: 0 !important;
  padding: 0 8px 0 16px !important;
  border: 0 !important;
  border-radius: 12px 0 0 12px !important;
  background: transparent !important;
  color: var(--v2-header-ink) !important;
  font-family: var(--v2-header-font) !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  line-height: 42px !important;
  box-shadow: none !important;
}

html.v2-header-active .v2-site-header__search #search input::placeholder { color: rgba(48, 47, 48, .48); opacity: 1; }
html.v2-header-active .v2-site-header__search #search .button-search {
  position: static !important;
  display: block !important;
  flex: 0 0 44px !important;
  width: 44px !important;
  height: 42px !important;
  min-height: 42px !important;
  border: 0 !important;
  background: transparent !important;
}

html.v2-header-active .v2-site-header__search #search .button-search button {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 44px !important;
  height: 42px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  color: var(--v2-header-ink) !important;
  cursor: pointer;
}

html.v2-header-active .v2-site-header__search #search .button-search i::before {
  color: var(--v2-header-ink) !important;
  font-size: 17px !important;
}

html.v2-header-active .v2-site-header__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

html.v2-header-active .v2-header-contact {
  position: relative;
  flex: 0 0 auto;
}

html.v2-header-active .v2-header-icon,
html.v2-header-active .v2-header-phone {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--v2-header-ink);
  cursor: pointer;
  transition: background 160ms ease-out, color 160ms ease-out;
}

html.v2-header-active .v2-header-icon:hover,
html.v2-header-active .v2-header-phone:hover { background: var(--v2-header-tint); color: var(--v2-header-violet); }
html.v2-header-active .v2-header-icon svg,
html.v2-header-active .v2-header-phone svg,
html.v2-header-active .v2-drawer-tools svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

html.v2-header-active .v2-header-phone {
  gap: 9px;
  min-width: 152px;
  padding: 0 10px;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

html.v2-header-active .v2-header-phone__chevron {
  width: 14px !important;
  height: 14px !important;
  margin-left: 1px;
  transition: transform 160ms ease-out;
}

html.v2-header-active .v2-header-phone > svg:first-child {
  width: 18px;
  height: 18px;
}

html.v2-header-active .v2-site-header.is-phone-picker-open .v2-header-phone__chevron { transform: rotate(180deg); }

html.v2-header-active .v2-phone-backdrop { display: none; }

html.v2-header-active .v2-phone-picker {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 20;
  width: 304px;
  padding: 8px;
  border: 1px solid var(--v2-header-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(48, 47, 48, .16);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 160ms ease-out, transform 160ms ease-out, visibility 160ms step-end;
}

html.v2-header-active .v2-site-header.is-phone-picker-open .v2-phone-picker {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
  transition: opacity 160ms ease-out, transform 160ms ease-out, visibility 0s;
}

html.v2-header-active .v2-phone-picker__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 8px 8px;
}

html.v2-header-active .v2-phone-picker__head h2,
html.v2-header-active .v2-phone-picker__head p { margin: 0; }
html.v2-header-active .v2-phone-picker__head h2 { color: var(--v2-header-ink); font-size: 14px; font-weight: 650; line-height: 20px; }
html.v2-header-active .v2-phone-picker__head p { margin-top: 1px; color: var(--v2-header-muted); font-size: 11px; line-height: 16px; }

html.v2-header-active .v2-phone-picker__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  margin: -4px -4px 0 0;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--v2-header-muted);
  cursor: pointer;
}

html.v2-header-active .v2-phone-picker__close:hover { background: var(--v2-header-tint); color: var(--v2-header-violet); }
html.v2-header-active .v2-phone-picker__close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; }

html.v2-header-active .v2-phone-picker__list { display: flex; flex-direction: column; }
html.v2-header-active .v2-phone-picker__item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: center;
  min-height: 56px;
  padding: 0 10px;
  border-radius: 10px;
  font-variant-numeric: tabular-nums;
  transition: background 140ms ease-out, color 140ms ease-out;
}

html.v2-header-active .v2-phone-picker__item + .v2-phone-picker__item { border-top: 1px solid var(--v2-header-line); }
html.v2-header-active .v2-phone-picker__item:hover { background: var(--v2-header-tint); color: var(--v2-header-violet); }
html.v2-header-active .v2-phone-picker__item span { color: var(--v2-header-muted); font-size: 12px; line-height: 18px; }
html.v2-header-active .v2-phone-picker__item strong { color: currentColor; font-size: 15px; font-weight: 650; line-height: 20px; white-space: nowrap; }
html.v2-header-active .v2-phone-picker__item .v2-phone-note {
  display: inline-flex;
  align-items: center;
  min-height: 18px;
  margin-left: 7px;
  padding: 0 6px;
  border-radius: 99px;
  background: var(--v2-header-tint);
  color: var(--v2-header-violet-dark);
  font-size: 10px;
  font-weight: 700;
  line-height: 18px;
  vertical-align: 1px;
}

/* Mini-cart: прежняя механика OpenCart, новый визуальный носитель. */
html.v2-header-active .v2-header-cart {
  position: relative;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
}

html.v2-header-active .v2-header-cart #cart,
html.v2-header-active .v2-header-cart #cart .heading,
html.v2-header-active .v2-header-cart #cart .heading > a {
  display: block !important;
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  min-height: 40px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  box-shadow: none !important;
  color: transparent !important;
}

html.v2-header-active .v2-header-cart #cart .heading:hover { background: var(--v2-header-tint) !important; }
html.v2-header-active .v2-header-cart #cart-total,
html.v2-header-active .v2-header-cart #cart .heading i { opacity: 0 !important; }
html.v2-header-active .v2-header-cart__icon {
  position: absolute;
  top: 9px;
  left: 9px;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--v2-header-ink);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}

html.v2-header-active .v2-header-cart__badge {
  position: absolute;
  top: 1px;
  right: -2px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: var(--v2-header-violet);
  color: #fff;
  font-size: 9px;
  font-weight: 600;
  line-height: 1;
  pointer-events: none;
}

html.v2-header-active .v2-header-cart #cart .content {
  top: 50px !important;
  right: 0 !important;
  left: auto !important;
  width: 360px !important;
  max-width: calc(100vw - 32px);
  border: 1px solid var(--v2-header-line) !important;
  border-radius: 12px !important;
  background: #fff !important;
  box-shadow: 0 18px 50px rgba(48, 47, 48, .16) !important;
  font-family: var(--v2-header-font) !important;
}

/* Desktop nav: один акцентный «Каталог», остальные ссылки текстом. */
html.v2-header-active .v2-site-header__nav {
  position: relative;
  z-index: 2;
  height: 44px;
  border-top: 1px solid var(--v2-header-line);
  border-bottom: 1px solid var(--v2-header-line);
  background: var(--v2-header-bg);
}

html.v2-header-active .v2-site-header__nav-inner {
  display: flex;
  align-items: center;
  height: 43px;
}

html.v2-header-active .v2-site-header__menu { flex: 1 1 auto; width: auto !important; height: 43px !important; }
html.v2-header-active .v2-site-header__menu .mobile-trigger { display: none !important; }
html.v2-header-active .v2-site-header__menu .super-menu {
  display: flex !important;
  align-items: center;
  width: auto !important;
  height: 43px !important;
  margin: 0 !important;
  border: 0 !important;
  table-layout: auto !important;
  background: transparent !important;
}

html.v2-header-active .v2-site-header__menu .super-menu > li {
  display: block !important;
  width: auto !important;
  height: 43px !important;
  border: 0 !important;
  background: transparent !important;
}

html.v2-header-active .v2-site-header__menu .super-menu > li:last-child { display: none !important; }
html.v2-header-active .v2-site-header__menu .super-menu > li > a {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important;
  height: 43px !important;
  padding: 0 18px !important;
  border: 0 !important;
  background: transparent !important;
  color: var(--v2-header-ink) !important;
  font-family: var(--v2-header-font) !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  line-height: 1 !important;
  text-transform: none !important;
  transition: color 160ms ease-out, background 160ms ease-out !important;
}

html.v2-header-active .v2-site-header__menu .super-menu > li:first-child > a {
  min-width: 152px;
  height: 36px !important;
  margin-top: 3px !important;
  margin-right: 14px !important;
  border-radius: 10px !important;
  background: var(--v2-header-violet) !important;
  color: #fff !important;
  font-weight: 600 !important;
}

html.v2-header-active .v2-site-header__menu .super-menu > li:first-child:hover > a { background: var(--v2-header-violet-dark) !important; }
html.v2-header-active .v2-site-header__menu .super-menu > li:not(:first-child):hover > a { background: var(--v2-header-tint) !important; color: var(--v2-header-violet) !important; }

html.v2-header-active .v2-site-header__menu .main-menu-text {
  color: inherit !important;
  font-family: inherit !important;
  font-size: inherit !important;
  font-weight: inherit !important;
}

html.v2-header-active .v2-site-header__language { flex: 0 0 auto; margin-left: auto; }
html.v2-header-active .v2-site-header__language {
  width: 132px !important;
  border: 0 !important;
}
html.v2-header-active .v2-site-header__language form,
html.v2-header-active .v2-site-header__language #language,
html.v2-header-active .v2-site-header__language .btn-group { height: 36px !important; }
html.v2-header-active .v2-site-header__language form,
html.v2-header-active .v2-site-header__language #language,
html.v2-header-active .v2-site-header__language .btn-group { position: relative; }
html.v2-header-active .v2-site-header__language #language button {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 132px !important;
  min-width: 132px !important;
  height: 36px !important;
  padding: 0 10px !important;
  border: 0 !important;
  border-radius: 9px !important;
  background: transparent !important;
  color: var(--v2-header-ink) !important;
  font-family: var(--v2-header-font) !important;
  font-size: 12px !important;
  font-weight: 600 !important;
}
html.v2-header-active .v2-site-header__language .dropdown-menu {
  top: calc(100% + 6px);
  right: 0;
  left: auto;
  min-width: 184px;
  margin: 0 !important;
  padding: 6px;
  border: 1px solid var(--v2-header-line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 14px 36px rgba(48, 47, 48, .14);
  transform: none;
}
html.v2-header-active .v2-site-header__language .dropdown-menu > li + li {
  border-top: 1px solid var(--v2-header-line);
}
html.v2-header-active .v2-site-header__language .dropdown-menu > li > a {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 10px;
  border-radius: 7px;
  color: var(--v2-header-ink);
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}
html.v2-header-active .v2-site-header__language .dropdown-menu > li > a:hover {
  background: var(--v2-header-tint);
  color: var(--v2-header-violet);
}

html.v2-header-active .v2-drawer-head,
html.v2-header-active .v2-drawer-tools,
html.v2-header-active .v2-menu-backdrop { display: none; }

/* Checkout uses its compact transactional header below the desktop breakpoint.
   Desktop restoration lives in checkout.css, next to the checkout layout rules. */
@media (max-width: 1023px) {
  html.v2-header-active .v2-site-header--checkout .v2-site-header__notice,
  html.v2-header-active .v2-site-header--checkout .v2-site-header__search,
  html.v2-header-active .v2-site-header--checkout .v2-site-header__nav,
  html.v2-header-active .v2-site-header--checkout .v2-menu-toggle,
  html.v2-header-active .v2-site-header--checkout .v2-desktop-action {
    display: none !important;
  }
}

@media (min-width: 1024px) and (max-width: 1199px) {
  html.v2-header-active .v2-header-wrap {
    padding-right: 24px;
    padding-left: 24px;
  }

  html.v2-header-active .v2-site-header__grid {
    grid-template-columns: 200px minmax(280px, 1fr) auto;
    gap: 16px;
  }

  html.v2-header-active .v2-site-header__logo img {
    max-width: 200px !important;
  }

  html.v2-header-active .v2-header-phone {
    width: 40px;
    min-width: 40px;
    padding: 0;
  }

  html.v2-header-active .v2-header-phone span,
  html.v2-header-active .v2-header-phone__chevron {
    display: none;
  }
}

/* ==========================================================================
   Mobile/tablet header: 40 notice + 56 brand row + 52 search.
   ========================================================================== */
@media (max-width: 1023px) {
  /* overflow:hidden создаёт новый scroll-container и ломает position:sticky. */
  html.v2-header-active,
  html.v2-header-active body { overflow-x: clip !important; }

  html.v2-header-active.v2-drawer-lock,
  html.v2-header-active.v2-drawer-lock body,
  html.v2-header-active.v2-phone-lock,
  html.v2-header-active.v2-phone-lock body { overflow: hidden !important; }

  html.v2-header-active.v2-phone-lock .scroll-top {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  html.v2-header-active .v2-site-header {
    position: sticky;
    top: 0;
    z-index: 2000;
    box-shadow: 0 1px 0 var(--v2-header-line);
  }

  html.v2-header-active .v2-header-wrap { padding-right: 20px; padding-left: 20px; }
  html.v2-header-active .v2-site-header__notice,
  html.v2-header-active .v2-site-header__notice .v2-header-wrap { height: 40px; }
  html.v2-header-active .v2-site-header__notice .v2-header-wrap { padding-right: 48px; font-size: 11px; }
  html.v2-header-active .v2-notice-close { right: 8px; width: 40px; height: 40px; }
  html.v2-header-active .v2-site-header.is-notice-closed .v2-site-header__notice,
  html.v2-header-active .v2-site-header.is-scrolled .v2-site-header__notice { height: 0; opacity: 0; }

  html.v2-header-active .v2-site-header__grid {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    grid-template-rows: 56px 52px;
    gap: 0;
    height: auto;
    min-height: 108px;
    transition: min-height 180ms ease-out;
  }

  html.v2-header-active .v2-menu-toggle { display: inline-flex !important; grid-column: 1; grid-row: 1; }
  html.v2-header-active .v2-site-header__logo {
    grid-column: 2;
    grid-row: 1;
    justify-content: center;
    padding: 0 8px;
  }

  html.v2-header-active .v2-site-header__logo img {
    max-width: min(190px, 100%) !important;
    max-height: 30px !important;
  }

  html.v2-header-active .v2-site-header__actions {
    grid-column: 3;
    grid-row: 1;
    gap: 8px;
  }

  html.v2-header-active .v2-desktop-action { display: none; }
  html.v2-header-active .v2-header-contact { width: 40px; height: 40px; }
  html.v2-header-active .v2-header-phone { width: 40px; min-width: 40px; padding: 0; }
  html.v2-header-active .v2-header-phone span {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
  }
  html.v2-header-active .v2-header-phone__chevron { display: none; }

  html.v2-header-active .v2-phone-backdrop {
    position: fixed;
    inset: 0;
    z-index: 2020;
    display: block;
    background: rgba(48, 47, 48, .32);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 200ms ease-out, visibility 200ms step-end;
  }

  html.v2-header-active .v2-site-header.is-phone-picker-open .v2-phone-backdrop {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 200ms ease-out, visibility 0s;
  }

  html.v2-header-active .v2-phone-picker {
    position: fixed;
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2030;
    width: 100%;
    max-width: none;
    max-height: min(480px, 82vh);
    max-height: min(480px, 82dvh);
    overflow-y: auto;
    padding: 8px 16px max(20px, env(safe-area-inset-bottom));
    border: 0;
    border-radius: 18px 18px 0 0;
    box-shadow: 0 -18px 54px rgba(48, 47, 48, .2);
    transform: translateY(105%);
    transition: transform 220ms ease-out, visibility 220ms step-end;
  }

  html.v2-header-active .v2-phone-picker::before {
    display: block;
    width: 40px;
    height: 4px;
    margin: 0 auto 8px;
    border-radius: 99px;
    background: var(--v2-header-line);
    content: '';
  }

  html.v2-header-active .v2-site-header.is-phone-picker-open .v2-phone-picker {
    transform: translateY(0);
    transition: transform 220ms ease-out, visibility 0s;
  }

  html.v2-header-active .v2-phone-picker__head { padding: 8px 4px 10px; }
  html.v2-header-active .v2-phone-picker__head h2 { font-size: 18px; line-height: 24px; }
  html.v2-header-active .v2-phone-picker__head p { margin-top: 2px; font-size: 12px; line-height: 18px; }
  html.v2-header-active .v2-phone-picker__close { flex-basis: 44px; width: 44px; height: 44px; margin: -4px -4px 0 0; }
  html.v2-header-active .v2-phone-picker__item {
    grid-template-columns: 72px minmax(0, 1fr);
    min-height: 60px;
    padding: 0 4px;
    border-radius: 0;
  }
  html.v2-header-active .v2-phone-picker__item strong { font-size: 16px; }

  html.v2-header-active .v2-site-header__search {
    grid-column: 1 / -1;
    grid-row: 2;
    align-self: start;
    height: 52px;
    padding-top: 6px;
    overflow: visible;
    opacity: 1;
    transition: height 180ms ease-out, padding 180ms ease-out, opacity 120ms ease-out;
  }

  html.v2-header-active .v2-site-header__search #search { height: 40px !important; min-height: 40px !important; }
  html.v2-header-active .v2-site-header__search #search input { height: 38px !important; min-height: 38px !important; line-height: 38px !important; }
  html.v2-header-active .v2-site-header__search #search .button-search,
  html.v2-header-active .v2-site-header__search #search .button-search button { height: 38px !important; min-height: 38px !important; }

  html.v2-header-active .v2-site-header.is-scrolled .v2-site-header__grid {
    grid-template-rows: 56px 0;
    min-height: 56px;
  }
  html.v2-header-active .v2-site-header.is-scrolled .v2-site-header__search {
    height: 0;
    padding-top: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
  }

  /* Drawer расположен поверх документа и не меняет позицию hero. */
  html.v2-header-active .v2-site-header__nav {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 2010;
    display: flex;
    flex-direction: column;
    width: min(340px, 86vw);
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
    border: 0;
    background: var(--v2-header-paper);
    box-shadow: 24px 0 60px rgba(48, 47, 48, .16);
    transform: translateX(-105%);
    visibility: hidden;
    transition: transform 220ms ease-out, visibility 220ms step-end;
  }

  html.v2-header-active .v2-site-header.is-drawer-open .v2-site-header__nav {
    transform: translateX(0);
    visibility: visible;
    transition: transform 220ms ease-out, visibility 0s;
  }

  html.v2-header-active .v2-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 2005;
    display: block;
    background: rgba(48, 47, 48, .32);
    opacity: 0;
    visibility: hidden;
    cursor: pointer;
    transition: opacity 220ms ease-out, visibility 220ms step-end;
  }

  html.v2-header-active .v2-site-header.is-drawer-open .v2-menu-backdrop {
    opacity: 1;
    visibility: visible;
    transition: opacity 220ms ease-out, visibility 0s;
  }

  html.v2-header-active .v2-drawer-head {
    position: sticky;
    top: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 0 0 56px;
    height: 56px;
    padding: 0 16px 0 20px;
    border-bottom: 1px solid var(--v2-header-line);
    background: #fff;
    font-size: 14px;
    font-weight: 600;
  }

  html.v2-header-active .v2-site-header__nav-inner {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    height: auto;
    padding: 12px !important;
  }

  html.v2-header-active .v2-site-header__menu {
    position: static !important;
    width: 100% !important;
    height: auto !important;
  }
  html.v2-header-active .v2-site-header__menu .super-menu {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    background: transparent !important;
  }

  html.v2-header-active .v2-site-header__menu .super-menu > li {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    min-height: 48px;
    margin: 0 0 4px !important;
    border-bottom: 1px solid var(--v2-header-line) !important;
    background: transparent !important;
  }

  html.v2-header-active .v2-site-header__menu .super-menu > li:last-child { display: none !important; }
  html.v2-header-active .v2-site-header__menu .super-menu > li > a,
  html.v2-header-active .v2-site-header__menu .super-menu > li:first-child > a {
    justify-content: flex-start;
    width: 100% !important;
    min-width: 0 !important;
    height: 48px !important;
    margin: 0 !important;
    padding: 0 44px 0 14px !important;
    border-radius: 10px !important;
    background: transparent !important;
    color: var(--v2-header-ink) !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    text-align: left !important;
  }

  html.v2-header-active .v2-site-header__menu .super-menu > li:first-child > a {
    background: var(--v2-header-violet) !important;
    color: #fff !important;
    font-weight: 600 !important;
  }

  html.v2-header-active .v2-site-header__menu .super-menu > li:first-child:hover > a { background: var(--v2-header-violet-dark) !important; }
  html.v2-header-active .v2-site-header__menu .super-menu > li:not(:first-child):hover > a { background: #fff !important; }
  html.v2-header-active .v2-site-header__menu .super-menu > li .mobile-plus {
    top: 4px !important;
    right: 4px !important;
    width: 40px !important;
    height: 40px !important;
    line-height: 40px !important;
    color: var(--v2-header-muted) !important;
  }

  html.v2-header-active .v2-site-header__menu .super-menu > li:first-child .mobile-plus { color: #fff !important; }
  html.v2-header-active .v2-site-header__menu .mega-menu,
  html.v2-header-active .v2-site-header__menu .super-menu > li > ul {
    position: static !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    border: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
  }

  html.v2-header-active .v2-site-header__language {
    width: 100%;
    margin: 8px 0 0;
    padding-top: 8px;
    border-top: 1px solid var(--v2-header-line);
  }

  html.v2-header-active .v2-site-header__language form,
  html.v2-header-active .v2-site-header__language #language,
  html.v2-header-active .v2-site-header__language .btn-group {
    width: 100%;
    height: auto !important;
  }

  html.v2-header-active .v2-site-header__language #language button {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    height: 44px !important;
    padding: 0 14px !important;
    background: #fff !important;
  }

  html.v2-header-active .v2-site-header__language #language button > div {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  html.v2-header-active .v2-site-header__language #language button::after {
    flex: 0 0 8px;
    width: 8px;
    height: 8px;
    margin-left: auto;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    box-sizing: border-box;
    content: '';
    transform: rotate(45deg);
    transition: transform 160ms ease-out;
  }

  html.v2-header-active .v2-site-header__language #language .btn-group.visible button::after {
    transform: rotate(225deg);
  }

  html.v2-header-active .v2-site-header__language .dropdown-menu {
    position: static !important;
    float: none;
    width: 100%;
    min-width: 0;
    margin: 4px 0 0 !important;
    box-shadow: none;
    transform: none !important;
  }

  html.v2-header-active .v2-site-header__language .dropdown-menu > li > a {
    min-height: 44px;
    padding: 0 14px;
    font-size: 14px;
  }

  html.v2-header-active .v2-drawer-tools {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    margin-top: auto;
    padding: 12px;
    border-top: 1px solid var(--v2-header-line);
    background: #fff;
  }

  html.v2-header-active .v2-drawer-tools a {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 0 12px;
    border-radius: 10px;
    color: var(--v2-header-ink);
    font-size: 14px;
    font-weight: 500;
  }

  html.v2-header-active .v2-drawer-tools a:hover { background: var(--v2-header-tint); color: var(--v2-header-violet); }

  /* На телефоне dropdown корзины становится нижней шторкой. */
  html.v2-header-active .v2-header-cart #cart .content {
    position: fixed !important;
    top: auto !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    z-index: 2030 !important;
    width: 100% !important;
    max-width: none !important;
    max-height: 72vh;
    overflow-y: auto;
    border: 0 !important;
    border-radius: 18px 18px 0 0 !important;
    box-shadow: 0 -18px 54px rgba(48, 47, 48, .2) !important;
  }
}

@media (max-width: 370px) {
  html.v2-header-active .v2-header-wrap { padding-right: 14px; padding-left: 14px; }
  html.v2-header-active .v2-site-header__logo img { max-width: 164px !important; }
}

/* ==========================================================================
   V2 catalogue mega-menu: two equal product directions instead of a flat
   Journal2 taxonomy dump. The original menu stays as a no-JS fallback.
   ========================================================================== */
html.v2-header-active .v2-catalog-mega {
  color: var(--v2-header-ink);
  font-family: var(--v2-header-font);
  text-align: left;
}

html.v2-header-active .v2-catalog-mega button,
html.v2-header-active .v2-catalog-mega a {
  font-family: inherit;
}

html.v2-header-active .v2-catalog-mega [hidden] { display: none !important; }
html.v2-header-active .v2-catalog-mega svg {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

html.v2-header-active .v2-catalog-mega__eyebrow {
  color: var(--v2-header-violet);
  font-size: 11px;
  font-weight: 700;
  line-height: 16px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

html.v2-header-active .v2-catalog-mega__prompt {
  color: var(--v2-header-ink);
  font-size: 18px;
  font-weight: 650;
  line-height: 24px;
}

html.v2-header-active .v2-catalog-door {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  padding: 0;
  border: 1px solid transparent;
  background: var(--v2-header-tint);
  color: var(--v2-header-ink);
  text-align: left;
  cursor: pointer;
  transition: border-color 160ms ease-out, background 160ms ease-out, color 160ms ease-out, transform 160ms ease-out;
}

html.v2-header-active .v2-catalog-door:hover,
html.v2-header-active .v2-catalog-door.is-active {
  border-color: rgba(118, 80, 143, .28);
  background: #eee5f7;
  color: var(--v2-header-violet);
}

html.v2-header-active .v2-catalog-door__copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

html.v2-header-active .v2-catalog-door strong {
  color: inherit;
  font-size: 18px;
  font-weight: 650;
  line-height: 24px;
}

html.v2-header-active .v2-catalog-door small {
  margin-top: 3px;
  color: var(--v2-header-muted);
  font-size: 12px;
  font-weight: 450;
  line-height: 17px;
}

html.v2-header-active .v2-catalog-door__arrow { transition: transform 160ms ease-out; }
html.v2-header-active .v2-catalog-door:hover .v2-catalog-door__arrow,
html.v2-header-active .v2-catalog-door.is-active .v2-catalog-door__arrow { transform: translateX(3px); }

html.v2-header-active .v2-catalog-panel__head h2 {
  margin: 0;
  color: var(--v2-header-ink);
  font-size: 18px;
  font-weight: 650;
  line-height: 24px;
}

html.v2-header-active .v2-catalog-panel__head p {
  margin: 2px 0 0;
  color: var(--v2-header-muted);
  font-size: 12px;
  line-height: 18px;
}

html.v2-header-active .v2-catalog-group__desktop-title {
  margin: 0;
  font-size: 15px;
  font-weight: 650;
  line-height: 22px;
}

html.v2-header-active .v2-catalog-group__desktop-title a:hover { color: var(--v2-header-violet); }
html.v2-header-active .v2-catalog-group__links {
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

html.v2-header-active .v2-catalog-group__links li {
  margin: 0;
  padding: 0;
}

html.v2-header-active .v2-catalog-group__links a {
  display: block;
  padding: 3px 0;
  color: rgba(48, 47, 48, .76);
  font-size: 13px;
  font-weight: 450;
  line-height: 18px;
}

html.v2-header-active .v2-catalog-group__links a:hover { color: var(--v2-header-violet); }
html.v2-header-active .v2-catalog-group__all {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 10px;
  color: var(--v2-header-violet) !important;
  font-size: 12px;
  font-weight: 650;
  line-height: 18px;
}

html.v2-header-active .v2-catalog-group__all-arrow { width: 16px !important; height: 16px !important; }
html.v2-header-active .v2-catalog-mega__utility {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--v2-header-line);
}

html.v2-header-active .v2-catalog-mega__promo,
html.v2-header-active .v2-catalog-mega__all {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--v2-header-muted) !important;
  font-size: 13px;
  font-weight: 600;
}

html.v2-header-active .v2-catalog-mega__promo:hover,
html.v2-header-active .v2-catalog-mega__all:hover { color: var(--v2-header-violet) !important; }
html.v2-header-active .v2-catalog-mega__all { gap: 4px; color: var(--v2-header-violet) !important; }
html.v2-header-active .v2-catalog-mega__all-arrow { width: 17px !important; height: 17px !important; }

@media (min-width: 1024px) {
  html.v2-header-active .v2-site-header__nav-inner { position: relative; }
  html.v2-header-active .v2-site-header__menu,
  html.v2-header-active .v2-site-header__menu .super-menu,
  html.v2-header-active .v2-site-header__menu .has-v2-catalog { overflow: visible !important; }

  html.v2-header-active .v2-site-header__menu,
  html.v2-header-active .v2-site-header__menu .super-menu { position: static !important; }
  html.v2-header-active .v2-site-header__menu .has-v2-catalog { position: static !important; }
  html.v2-header-active .v2-site-header__menu .has-v2-catalog > .mega-menu,
  html.v2-header-active .v2-site-header__menu .has-v2-catalog > .mobile-plus { display: none !important; }

  html.v2-header-active .v2-catalog-mega {
    position: absolute;
    top: 43px;
    right: 32px;
    left: 32px;
    z-index: 20;
    display: block;
    max-height: calc(100vh - 150px);
    max-height: calc(100dvh - 150px);
    overflow-x: hidden;
    overflow-y: auto;
    padding: 22px 28px 0;
    border: 1px solid var(--v2-header-line);
    border-radius: 0 0 16px 16px;
    background: #fff;
    box-shadow: 0 2px 6px rgba(48, 47, 48, .05), 0 12px 28px rgba(48, 47, 48, .08), 0 28px 56px rgba(48, 47, 48, .07);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(7px);
    transition: opacity 150ms ease-out, transform 180ms ease-out, visibility 180ms step-end;
  }

  html.v2-header-active .v2-site-header__menu .has-v2-catalog:hover > .v2-catalog-mega,
  html.v2-header-active .v2-site-header__menu .has-v2-catalog:focus-within > .v2-catalog-mega {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
    transition: opacity 150ms ease-out, transform 180ms ease-out, visibility 0s;
  }

  html.v2-header-active .v2-catalog-mega__intro {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 14px;
  }

  html.v2-header-active .v2-catalog-mega__doors {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  html.v2-header-active .v2-catalog-door {
    min-height: 80px;
    padding: 14px 18px 14px 20px;
    border-radius: 12px;
  }

  html.v2-header-active .v2-catalog-mega__panels { margin-top: 0; }
  html.v2-header-active .v2-catalog-mega.is-direction-open .v2-catalog-mega__panels { margin-top: 20px; }
  html.v2-header-active .v2-catalog-panel__back,
  html.v2-header-active .v2-catalog-group__toggle { display: none; }

  html.v2-header-active .v2-catalog-panel__head { display: none; }
  html.v2-header-active .v2-catalog-panel__groups {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
  }

  html.v2-header-active .v2-catalog-panel--materials .v2-catalog-panel__groups {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html.v2-header-active .v2-catalog-panel--finished .v2-catalog-panel__groups {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  html.v2-header-active .v2-catalog-group {
    min-width: 0;
    padding: 16px 17px 14px;
    border: 1px solid rgba(48, 47, 48, .06);
    border-radius: 12px;
    background: var(--v2-header-paper);
  }

  html.v2-header-active .v2-catalog-mega__utility {
    min-height: 52px;
    margin-top: 18px;
  }
}

@media (min-width: 1024px) and (max-width: 1199px) {
  html.v2-header-active .v2-catalog-mega { right: 24px; left: 24px; padding-right: 22px; padding-left: 22px; }
}

@media (max-width: 1023px) {
  html.v2-header-active .v2-site-header__menu .has-v2-catalog {
    position: static !important;
    height: auto !important;
    min-height: 0 !important;
    margin-bottom: 6px !important;
    border: 0 !important;
  }

  html.v2-header-active .v2-site-header__menu .super-menu > li.has-v2-catalog:first-child > a,
  html.v2-header-active .v2-site-header__menu .has-v2-catalog > .mega-menu,
  html.v2-header-active .v2-site-header__menu .has-v2-catalog > .mobile-plus { display: none !important; }

  html.v2-header-active .v2-catalog-mega {
    position: static !important;
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    padding: 4px 0 0;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  html.v2-header-active .v2-catalog-mega__intro {
    display: flex;
    flex-direction: column;
    gap: 1px;
    padding: 2px 8px 10px;
  }

  html.v2-header-active .v2-catalog-mega__prompt { font-size: 16px; line-height: 22px; }
  html.v2-header-active .v2-catalog-mega__doors {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  html.v2-header-active .v2-catalog-door {
    width: 100%;
    min-height: 70px;
    padding: 11px 12px 11px 14px;
    border-radius: 11px;
  }

  html.v2-header-active .v2-catalog-door strong { font-size: 15px; line-height: 20px; }
  html.v2-header-active .v2-catalog-door small { font-size: 11px; line-height: 16px; }
  html.v2-header-active .v2-catalog-mega.is-direction-open .v2-catalog-mega__intro,
  html.v2-header-active .v2-catalog-mega.is-direction-open .v2-catalog-mega__doors { display: none; }

  html.v2-header-active .v2-catalog-panel__back {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    width: 100%;
    min-height: 40px;
    margin: -4px 0 8px;
    padding: 0 6px;
    border: 0;
    border-bottom: 1px solid var(--v2-header-line);
    background: var(--v2-header-paper);
    color: var(--v2-header-violet);
    font-size: 12px;
    font-weight: 650;
    cursor: pointer;
  }

  html.v2-header-active .v2-catalog-panel__back-arrow { width: 17px !important; height: 17px !important; }
  html.v2-header-active .v2-catalog-panel__head { padding: 0 6px 12px; }
  html.v2-header-active .v2-catalog-panel__head h2 { font-size: 18px; line-height: 23px; }
  html.v2-header-active .v2-catalog-panel__groups {
    overflow: hidden;
    border: 1px solid var(--v2-header-line);
    border-radius: 12px;
    background: #fff;
  }

  html.v2-header-active .v2-catalog-group + .v2-catalog-group { border-top: 1px solid var(--v2-header-line); }
  html.v2-header-active .v2-catalog-group__desktop-title { display: none; }
  html.v2-header-active .v2-catalog-group__toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 52px;
    padding: 0 14px;
    border: 0;
    background: #fff;
    color: var(--v2-header-ink);
    font-size: 14px;
    font-weight: 650;
    line-height: 20px;
    text-align: left;
    cursor: pointer;
  }

  html.v2-header-active .v2-catalog-group__chevron {
    width: 18px !important;
    height: 18px !important;
    color: var(--v2-header-muted);
    transform: rotate(90deg);
    transition: transform 160ms ease-out;
  }

  html.v2-header-active .v2-catalog-group.is-open .v2-catalog-group__toggle {
    background: var(--v2-header-tint);
    color: var(--v2-header-violet);
  }

  html.v2-header-active .v2-catalog-group.is-open .v2-catalog-group__chevron { transform: rotate(-90deg); }
  html.v2-header-active .v2-catalog-group__body {
    display: none;
    padding: 2px 14px 13px;
    background: #fff;
  }

  html.v2-header-active .v2-catalog-group.is-open .v2-catalog-group__body { display: block; }
  html.v2-header-active .v2-catalog-group__links { margin-top: 4px; }
  html.v2-header-active .v2-catalog-group__links a {
    min-height: 38px;
    padding: 9px 0;
    font-size: 13px;
    line-height: 20px;
  }

  html.v2-header-active .v2-catalog-group__all { min-height: 38px; margin-top: 2px; }
  html.v2-header-active .v2-catalog-mega__utility {
    position: sticky;
    bottom: -12px;
    z-index: 2;
    min-height: 50px;
    margin-top: 10px;
    padding: 0 6px;
    background: var(--v2-header-paper);
  }

  html.v2-header-active .v2-catalog-mega__promo,
  html.v2-header-active .v2-catalog-mega__all { min-height: 44px; font-size: 12px; }
  html.v2-header-active .v2-site-header.is-catalog-subview .v2-site-header__menu .super-menu > li:not(:first-child),
  html.v2-header-active .v2-site-header.is-catalog-subview .v2-site-header__language,
  html.v2-header-active .v2-site-header.is-catalog-subview .v2-drawer-tools { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  html.v2-header-active .v2-site-header *,
  html.v2-header-active .v2-site-header *::before,
  html.v2-header-active .v2-site-header *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
