/* Approved branded header, isolated Bitrix laboratory only.
   Both logo windows show the unmodified original /logo.svg. */
html { scroll-padding-top: 112px; }
/* The legacy focus handler adds no-scroll. Keep the same scroll container;
   the dimmer intercepts clicks and the suggestions have their own scrolling. */
body.bx-background-image.no-scroll:has(.apux-branded-header) { overflow: visible; }
header.bx-header.apux-branded-header {
  --apux-brand-column: 220px;
  --apux-full-height: 180px;
  --apux-small-height: 88px;
  height: var(--apux-full-height);
  min-height: var(--apux-full-height);
  margin-bottom: 24px;
  padding-top: 0;
  pointer-events: none;
}
.apux-branded-header > .bx-header-section.container {
  width: 100%; max-width: 1488px; padding: 0 24px;
}
.apux-branded-header .header-section {
  display: grid;
  grid-template-columns: var(--apux-brand-column) minmax(0, 1fr) 132px;
  grid-template-rows: 28px 56px;
  column-gap: 24px; row-gap: 16px; align-content: center;
  height: var(--apux-full-height); padding: 20px 24px;
  background: #000; border-radius: 0 0 24px 24px;
  pointer-events: auto;
  transition: height 180ms ease, grid-template-rows 180ms ease, row-gap 180ms ease;
}
.apux-branded-header .header-footer-container { display: contents !important; }
.apux-branded-header .bx-header-logo {
  grid-area: 1 / 1 / 3 / 2; align-self: center;
  position: relative; width: 100%; height: 132px;
  border-right: 1px solid #ffffff45;
  transition: height 180ms ease;
}
.apux-branded-header .bx-logo-block {
  display: block; position: absolute; inset: 0 24px 0 0;
}
.apux-brand-mark, .apux-brand-word {
  display: block; position: absolute; overflow: hidden;
  transition: width 180ms ease, height 180ms ease, left 180ms ease, top 180ms ease;
}
.apux-brand-mark {
  width: 124px; height: 70px; left: calc(50% - 62px); top: 0;
}
.apux-brand-word {
  width: 190px; height: 28px; left: calc(50% - 95px); top: 75px;
}
.apux-branded-header .bx-logo-block img {
  display: block; position: absolute; max-width: none;
  height: auto; margin: 0;
}
.apux-branded-header .apux-brand-mark img {
  width: 227.4194%; left: 0; top: 0;
}
.apux-branded-header .apux-brand-word img {
  width: 181.9355%; left: -80%; top: -82%;
}
.apux-brand-tagline {
  position: absolute; top: 110px; left: 0; right: 0;
  color: #a6a6aa; text-align: center; letter-spacing: 3.5px;
  font-size: 12px; font-weight: 500; line-height: 18px;
  transition: opacity 120ms ease;
}
.apux-branded-header .header-top-container {
  grid-area: 1 / 2 / 2 / 4;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 0; min-width: 0; height: 28px;
  transition: opacity 120ms ease, visibility 120ms ease;
}
.apux-header-city {
  display: inline-flex; gap: 9px; align-items: center;
  color: #fff; font-size: 17px; font-weight: 600; line-height: 24px;
  white-space: nowrap;
}
.apux-header-city .bi { font-size: 20px; line-height: 1; }
.apux-header-city--compact {
  position: absolute; left: 72px; top: 31px;
  font-size: 13px; font-weight: 400; line-height: 20px;
  gap: 5px; visibility: hidden; opacity: 0;
  transition: opacity 120ms ease, visibility 120ms ease;
}
.apux-header-city--compact .bi { font-size: 13px; }
.apux-branded-header .header-contact { padding: 0; min-width: 0; font-size: 13px; }
.apux-branded-header .bx-header-phone-number { gap: 0; }
.apux-branded-header .header-contact__number { display: flex; align-items: center; gap: 14px; }
.apux-branded-header .header-contact__number > div:first-child { color: #b9b9be; font-weight: 400; }
.apux-branded-header .header-contact__number-links { display: flex; flex-direction: row; align-items: center; flex-wrap: nowrap; gap: 12px; white-space: nowrap; }
.apux-branded-header .header-contact__socials { display: none; }
.apux-branded-header .header-search {
  grid-area: 2 / 2 / 3 / 3; align-self: center;
  width: 100%; max-width: none; min-width: 0; margin: 0;
}
.apux-branded-header .search-wrapper { width: 100%; container-type: inline-size; }
.apux-branded-header .search-form-container { padding: 0 6px 0 18px; transition: none; }
.apux-branded-header .form-group { gap: 12px; }
.apux-branded-header .header-search .search-input {
  height: 56px; min-width: 0; padding: 0; font-size: 17px;
  outline: none;
}
.apux-branded-header .header-search .bi-search { width: 22px; height: 22px; flex-shrink: 0; }
.apux-branded-header .search-btn {
  flex-shrink: 0; width: 90px; height: 44px;
  padding: 0 14px; font-size: 14px; font-family: inherit;
  background: #e10918; opacity: 1; visibility: visible;
}
.apux-branded-header .search-btn:hover { background: #bf0815; }
.apux-branded-header .search-wrapper:has(:focus-visible) .bi-search { fill: #c70c19; }
.apux-branded-header .bx-header-personal {
  grid-area: 2 / 3 / 3 / 4; align-self: center; margin: 0; min-width: 0;
}
.apux-branded-header .header-profile {
  display: flex; width: 100%; max-width: none; gap: 12px; justify-content: space-between;
  font-size: 13px; font-weight: 400;
}
.apux-branded-header .header-profile a {
  width: 58px; height: 56px; gap: 4px; text-decoration: none;
}
.apux-branded-header .header-profile .apux-personal-icon { font-size: 28px; line-height: 30px; }
.apux-branded-header .header-profile p { display: block; margin: 0; line-height: 18px; color: #d9d9de; }
.apux-branded-header a:focus-visible, .apux-branded-header button:focus-visible {
  outline: 2px solid #fff; outline-offset: 4px; border-radius: 5px;
}
.apux-branded-header .search-btn:focus-visible { outline-color: #20232b; border-radius: 24px; }
.apux-branded-header .apux-search-shade { pointer-events: auto; }
.apux-branded-header.apux-header-compact .header-section {
  height: var(--apux-small-height); grid-template-rows: 0px 56px; row-gap: 0;
}
.apux-branded-header.apux-header-compact .header-top-container {
  opacity: 0; visibility: hidden; pointer-events: none;
}
.apux-branded-header.apux-header-compact .bx-header-logo { height: 56px; }
.apux-header-compact .apux-brand-mark { width: 64px; height: 37px; left: 0; top: 8px; }
.apux-header-compact .apux-brand-word { width: 124px; height: 19px; left: 72px; top: 8px; }
.apux-header-compact .apux-brand-tagline { opacity: 0; visibility: hidden; }
.apux-header-compact .apux-header-city--compact { opacity: 1; visibility: visible; }
.apux-branded-header #apux-search-panel { max-height: calc(100dvh - 150px); overflow-y: auto; overscroll-behavior: contain; }
@container (max-width: 640px) {
  .apux-branded-header #apux-search-panel { flex-direction: column; padding: 12px; }
  .apux-branded-header #apux-search-panel > .apux-search-explainer { min-height: 0; flex: auto; padding: 14px 16px; }
  .apux-branded-header #apux-search-panel > .apux-search-explainer:first-child { border-radius: 16px 16px 0 0; }
  .apux-branded-header #apux-search-panel > .apux-search-explainer:last-child { border-radius: 0 0 16px 16px; }
  .apux-branded-header #apux-search-panel > .apux-search-explainer + *::before {
    left: 16px; right: 16px; top: 0; bottom: auto; border-left: 0; border-top: 1px solid #cdd0d6;
  }
}
@media (max-width: 1150px) {
  .apux-branded-header .header-contact__number > div:first-child { display: none; }
  .apux-branded-header .header-contact__number-links a + a { display: none; }
  .apux-branded-header .header-section { column-gap: 18px; }
  .apux-branded-header .header-search .search-input { font-size: 16px; }
}
@media (min-width: 761px) and (max-width: 900px) {
  header.bx-header.apux-branded-header { --apux-brand-column: 180px; }
  .apux-branded-header > .bx-header-section.container { padding: 0 16px; }
  .apux-branded-header .header-section { padding: 20px 18px; column-gap: 16px; grid-template-columns: 180px minmax(0,1fr) 100px; }
  .apux-branded-header .bx-logo-block { right: 16px; }
  .apux-brand-word { width: 158px; height: 24px; left: calc(50% - 79px); }
  .apux-brand-tagline { font-size: 10px; letter-spacing: 2.5px; }
  .apux-header-compact .apux-brand-mark { width: 48px; height: 28px; top: 12px; }
  .apux-header-compact .apux-brand-word { width: 105px; height: 16px; left: 54px; top: 9px; }
  .apux-header-city--compact { left: 54px; }
  .apux-branded-header .header-profile { gap: 8px; }
  .apux-branded-header .header-profile a { width: 44px; }
  .apux-branded-header .search-btn { width: 70px; padding: 0 10px; font-size: 13px; }
  .apux-branded-header .search-form-container { padding-left: 12px; }
  .apux-branded-header .form-group { gap: 8px; }
}
@media (max-width: 760px) {
  html { scroll-padding-top: 140px; }
  /* The original fixed-width about image otherwise widens a 360px page. */
  body:has(.apux-branded-header) .main-about__img-container img { max-width: 100%; height: auto; }
  header.bx-header.apux-branded-header {
    --apux-full-height: 176px; --apux-small-height: 128px;
    height: var(--apux-full-height); min-height: var(--apux-full-height);
    padding-top: 0; margin-bottom: 12px;
  }
  .apux-branded-header > .bx-header-section.container { padding: 0 8px; }
  .apux-branded-header .header-section {
    grid-template-columns: minmax(0,1fr) 104px; grid-template-rows: 92px 52px;
    column-gap: 8px; row-gap: 8px; padding: 12px 14px; border-radius: 0 0 22px 22px;
  }
  .apux-branded-header .bx-header-logo {
    grid-area: 1 / 1 / 2 / 2; width: 170px; max-width: 100%; height: 92px; border: 0;
  }
  .apux-branded-header .bx-logo-block { inset: 0; }
  .apux-brand-mark { width: 82px; height: 47px; left: 44px; top: 0; }
  .apux-brand-word { width: 146px; height: 22px; left: 12px; top: 49px; }
  .apux-brand-tagline { top: 75px; font-size: 9px; line-height: 14px; letter-spacing: 2.5px; }
  .apux-branded-header .header-top-container {
    grid-area: 1 / 2 / 2 / 3; align-self: start; justify-content: flex-end; height: 28px; margin-top: 2px;
  }
  .apux-branded-header .header-contact { display: none; }
  .apux-branded-header .apux-header-city { font-size: 15px; gap: 6px; }
  .apux-branded-header .apux-header-city .bi { font-size: 16px; }
  .apux-branded-header .header-search { grid-area: 2 / 1 / 3 / 3; }
  .apux-branded-header .header-search .search-input { height: 52px; font-size: 16px; }
  .apux-branded-header .search-form-container { padding-left: 12px; }
  .apux-branded-header .form-group { gap: 8px; }
  .apux-branded-header .header-search .bi-search { width: 18px; height: 18px; }
  .apux-branded-header .search-btn { width: 62px; height: 40px; font-size: 12px; padding: 0 8px; }
  .apux-branded-header .bx-header-personal { grid-area: 1 / 2 / 2 / 3; align-self: end; }
  .apux-branded-header .header-profile { gap: 6px; }
  .apux-branded-header .header-profile a { width: 48px; height: 50px; font-size: 11px; gap: 1px; }
  .apux-branded-header .header-profile .apux-personal-icon { font-size: 25px; line-height: 28px; }
  .apux-branded-header.apux-header-compact .header-section { grid-template-rows: 44px 52px; row-gap: 8px; }
  .apux-branded-header.apux-header-compact .bx-header-logo { height: 44px; }
  .apux-header-compact .apux-brand-mark { width: 48px; height: 28px; left: 0; top: 8px; }
  .apux-header-compact .apux-brand-word { width: 111px; height: 17px; left: 53px; top: 3px; }
  .apux-branded-header .apux-header-city--compact { left: 53px; top: 24px; font-size: 12px; line-height: 17px; gap: 4px; }
  .apux-branded-header .apux-header-city--compact .bi { font-size: 12px; }
  .apux-branded-header.apux-header-compact .bx-header-personal { align-self: center; }
  .apux-branded-header #apux-search-panel { max-height: calc(100dvh - 225px); }
  .apux-branded-header.apux-header-compact #apux-search-panel { max-height: calc(100dvh - 177px); }
}
@media (prefers-reduced-motion: reduce) {
  .apux-branded-header *, .apux-branded-header *::before { transition: none !important; }
}
