
:root {
  --header-height: 84px;
  --orange: #ff681e;
  --orange-dark: #e95612;
  --border: #e5e5e5;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body.menu-open {
  overflow: hidden;
}

.site-header {
  position: relative;
  width: 100%;
  height: var(--header-height);
  z-index: 1000;
  background: #ffffff;
  border-bottom: 1px solid #ededed;
  font-family: "Plus Jakarta Sans", sans-serif;
}

.site-header.is-fixed {
  position: fixed;
  top: 0;
  left: 0;
  box-shadow: 0 5px 24px rgba(0, 0, 0, 0.06);
}

.site-header img {
  display: block;
  max-width: 100%;
}

.site-header button {
  font-family: inherit;
}

.header-inner {
  position: relative;
  width: calc(100% - 80px);
  max-width: 1810px;
  height: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

.header-logo {
  width: 175px;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  text-decoration: none;
}

.header-logo img {
  width: 100%;
  height: auto;
}

.header-nav {
  position: absolute;
  top: 0;
  left: 50%;
  height: 100%;
  transform: translateX(-50%);
}

.header-nav-list {
  height: 100%;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 38px;
  list-style: none;
}

.header-nav-item {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.site-header .header-nav-link,
.site-header button.header-nav-link,
.site-header a.header-nav-link {
  position: relative;
  height: 100%;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  border: 0;
  background: transparent;
  color: #4f4f4f;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 16px;
  font-weight: 500;
  font-style: normal;
  line-height: 1;
  letter-spacing: -0.025em;
  white-space: nowrap;
  text-decoration: none;
  text-transform: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  transition: color 0.25s ease;
}

.site-header .header-nav-link span {
  font: inherit;
  letter-spacing: inherit;
}

.site-header .header-nav-link:hover,
.site-header .header-nav-item:hover > .header-nav-link,
.site-header .header-nav-item.is-open > .header-nav-link,
.site-header .header-nav-item.is-current > .header-nav-link {
  color: var(--orange);
}

.site-header .header-nav-item::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 17px;
  width: 0;
  height: 2px;
  background: var(--orange);
  opacity: 0;
  transform: translateX(-50%);
  clip-path: none;
  pointer-events: none;
  transition:
    width 0.25s ease,
    opacity 0.25s ease;
}

.site-header .header-nav-item:hover::after,
.site-header .header-nav-item.is-open::after,
.site-header .header-nav-item.is-current::after {
  width: calc(100% - 4px);
  opacity: 1;
}

.nav-arrow {
  width: 11px;
  height: 7px;
  flex: 0 0 auto;
  overflow: visible;
  transition: transform 0.22s ease;
}

.nav-arrow path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: square;
  stroke-linejoin: miter;
}

.site-header .header-nav-item:hover .nav-arrow,
.site-header .header-nav-item:focus-within .nav-arrow,
.site-header .header-nav-item.is-open .nav-arrow {
  transform: rotate(180deg);
}

.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.site-header .consultation-button {
  height: 54px;
  padding: 0 10px 0 30px;
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  background: var(--orange);
  color: #ffffff;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  clip-path: polygon(
    0 0,
    90% 0,
    100% 100%,
    10% 100%
  );
  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.site-header .consultation-button:hover {
  background: var(--orange-dark);
  color: #ffffff;
  transform: translateY(-1px);
}

.consultation-arrow {
  width: 54px;
  height: 54px;
  margin-left: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-left: 1px solid rgba(255, 255, 255, 0.28);
}

.consultation-arrow svg {
  width: 17px;
  height: 17px;
}

.consultation-arrow path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
}

.language-switcher {
  position: relative;
  flex: 0 0 auto;
}

.language-button {
  min-width: 42px;
  height: var(--header-height);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  border: 0;
  background: transparent;
  color: #555555;
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
}

.language-button svg {
  width: 9px;
  height: 6px;
  transition: transform 0.2s ease;
}

.language-button path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
}

.language-switcher.is-open .language-button svg {
  transform: rotate(180deg);
}

.language-dropdown {
  position: absolute;
  top: calc(100% - 7px);
  right: 0;
  min-width: 82px;
  padding: 7px;
  z-index: 20;
  background: #ffffff;
  border: 1px solid var(--border);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-6px);
  clip-path: polygon(
    10px 0,
    100% 0,
    100% calc(100% - 10px),
    calc(100% - 10px) 100%,
    0 100%,
    0 10px
  );
  transition:
    opacity 0.2s ease,
    visibility 0.2s ease,
    transform 0.2s ease;
}

.language-switcher.is-open .language-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.language-dropdown a {
  display: block;
  padding: 9px 10px;
  color: #555555;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.language-dropdown a:hover,
.language-dropdown a.is-active {
  color: var(--orange);
}

.mega-menu {
  position: fixed;
  top: var(--header-height);
  left: 50%;
  width: min(1320px, calc(100vw - 80px));
  z-index: 990;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(-50%) translateY(8px);
  transition:
    opacity 0.22s ease,
    visibility 0.22s ease,
    transform 0.22s ease;
}

.header-nav-item.is-open > .mega-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

@media (min-width: 1121px) {
  .site-header .header-nav-item.has-mega-menu:hover > .mega-menu,
  .site-header .header-nav-item.has-mega-menu:focus-within > .mega-menu,
  .site-header .header-nav-item.has-mega-menu.is-open > .mega-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
  }

  .site-header .header-nav-item.has-mega-menu:hover .nav-arrow,
  .site-header .header-nav-item.has-mega-menu:focus-within .nav-arrow,
  .site-header .header-nav-item.has-mega-menu.is-open .nav-arrow {
    transform: rotate(180deg);
  }
}

.mega-menu-panel {
  width: 100%;
  min-height: 460px;
  padding: 24px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.16);
  clip-path: polygon(
    22px 0,
    100% 0,
    100% calc(100% - 22px),
    calc(100% - 22px) 100%,
    0 100%,
    0 22px
  );
}

.mega-menu-main {
  min-width: 0;
  padding: 10px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px 20px;
}

.mega-column {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mega-link,
.mega-featured {
  min-width: 0;
  min-height: 102px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  color: #222222;
  text-decoration: none;
  clip-path: polygon(
    10px 0,
    100% 0,
    100% calc(100% - 10px),
    calc(100% - 10px) 100%,
    0 100%,
    0 10px
  );
  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.mega-link:hover {
  background: #f5f5f5;
  transform: translateY(-2px);
}

.mega-featured {
  background: #eeeeee;
  border: 1px solid #dddddd;
}

.mega-featured:hover {
  background: #e8e8e8;
  transform: translateY(-2px);
}

.mega-title {
  display: block;
  margin-bottom: 8px;
  color: #272727;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.mega-description {
  display: block;
  color: #747474;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.48;
}

.mega-promo {
  position: relative;
  min-width: 0;
  min-height: 412px;
  padding: 28px 25px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  background: linear-gradient(
    145deg,
    #ff762c 0%,
    #ef4d0d 100%
  );
  color: #ffffff;
  text-decoration: none;
  clip-path: polygon(
    22px 0,
    100% 0,
    100% calc(100% - 22px),
    calc(100% - 22px) 100%,
    0 100%,
    0 22px
  );
}

.mega-promo::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  top: 110px;
  right: -110px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  transform: rotate(30deg);
  pointer-events: none;
}

.mega-promo-top {
  position: relative;
  z-index: 2;
}

.mega-promo-label {
  display: block;
  margin-bottom: 18px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  opacity: 0.8;
}

.mega-promo h3 {
  max-width: 230px;
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.03em;
}

.mega-promo p {
  max-width: 230px;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  opacity: 0.85;
}

.site-header .mega-promo .mega-promo-button,
.site-header .mega-promo button.mega-promo-button,
.site-header .mega-promo a.mega-promo-button {
  position: relative;
  z-index: 2;
  width: 100%;
  min-height: 54px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: transparent;
  color: #ffffff;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  appearance: none;
  clip-path: polygon(
    8px 0,
    100% 0,
    100% calc(100% - 8px),
    calc(100% - 8px) 100%,
    0 100%,
    0 8px
  );
  transition:
    background 0.25s ease,
    color 0.25s ease,
    border-color 0.25s ease;
}

.site-header .mega-promo .mega-promo-button:hover,
.site-header .mega-promo button.mega-promo-button:hover,
.site-header .mega-promo a.mega-promo-button:hover {
  background: #ffffff;
  border-color: #ffffff;
  color: #202020;
}

.site-header .mega-promo .mega-promo-button span {
  color: inherit;
}

.site-header .mega-promo .mega-promo-button svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.site-header .mega-promo .mega-promo-button svg path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

.mega-promo-dark {
  background: linear-gradient(
    145deg,
    #323232 0%,
    #141414 100%
  );
}

.about-mega-item .mega-menu-main {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.header-nav-item.has-account-menu {
  position: relative;
}

.account-dropdown {
  position: absolute;
  top: calc(100% - 4px);
  left: 50%;
  min-width: 190px;
  padding: 10px;
  background: #ffffff;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.12);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(-50%) translateY(-8px);
  clip-path: polygon(
    10px 0,
    100% 0,
    100% calc(100% - 10px),
    calc(100% - 10px) 100%,
    0 100%,
    0 10px
  );
  transition:
    opacity 0.2s ease,
    visibility 0.2s ease,
    transform 0.2s ease;
}

.header-nav-item.is-open .account-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

@media (min-width: 1121px) {
  .header-nav-item.has-account-menu:hover .account-dropdown,
  .header-nav-item.has-account-menu:focus-within .account-dropdown {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
  }

  .header-nav-item.has-account-menu:hover .nav-arrow,
  .header-nav-item.has-account-menu:focus-within .nav-arrow {
    transform: rotate(180deg);
  }
}

.account-dropdown a {
  display: block;
  padding: 11px 13px;
  color: #333333;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.account-dropdown a:hover {
  background: #f1f1f1;
  color: var(--orange);
}

.burger {
  position: relative;
  width: 44px;
  height: 44px;
  display: none;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.burger span {
  position: absolute;
  left: 7px;
  width: 30px;
  height: 1.5px;
  background: #222222;
  transition:
    top 0.3s ease,
    transform 0.3s ease;
}

.burger span:first-child {
  top: 17px;
}

.burger span:last-child {
  top: 26px;
}

.burger.is-active span:first-child {
  top: 22px;
  transform: rotate(45deg);
}

.burger.is-active span:last-child {
  top: 22px;
  transform: rotate(-45deg);
}

.mobile-menu {
  position: fixed;
  top: var(--header-height);
  left: 0;
  width: 100%;
  height: calc(100dvh - var(--header-height));
  overflow-y: auto;
  z-index: 995;
  background: #ffffff;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-10px);
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease,
    transform 0.25s ease;
}

.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.mobile-menu-inner {
  min-height: 100%;
  padding: 15px 25px 30px;
  display: flex;
  flex-direction: column;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
}

.mobile-main-link,
.mobile-nav-toggle {
  width: 100%;
  min-height: 64px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 0;
  border-bottom: 1px solid #e5e5e5;
  background: transparent;
  color: #222222;
  font-size: 19px;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.mobile-plus {
  position: relative;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.mobile-plus::before,
.mobile-plus::after {
  content: "";
  position: absolute;
  background: #222222;
  transition: transform 0.25s ease;
}

.mobile-plus::before {
  width: 14px;
  height: 1.5px;
  top: 8px;
  left: 2px;
}

.mobile-plus::after {
  width: 1.5px;
  height: 14px;
  top: 2px;
  left: 8px;
}

.mobile-nav-dropdown.is-open .mobile-plus::after {
  transform: rotate(90deg);
}

.mobile-submenu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.mobile-submenu a {
  display: block;
  padding: 10px 12px;
  color: #555555;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.mobile-submenu a:hover {
  color: var(--orange);
}

.mobile-bottom {
  margin-top: auto;
  padding-top: 40px;
}

.mobile-consultation {
  min-height: 54px;
  padding: 0 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--orange);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  clip-path: polygon(
    0 0,
    92% 0,
    100% 100%,
    8% 100%
  );
}

.mobile-languages {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 16px;
}

.mobile-languages a {
  color: #888888;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.mobile-languages a.is-active {
  color: var(--orange);
}

@media (max-width: 1550px) {
  .header-inner {
    width: calc(100% - 60px);
  }

  .header-nav-list {
    gap: 30px;
  }

  .site-header .header-nav-link,
  .site-header button.header-nav-link,
  .site-header a.header-nav-link {
    font-size: 15px;
  }

  .header-logo {
    width: 160px;
  }

  .header-actions {
    gap: 18px;
  }
}

@media (min-width: 1121px) and (max-width: 1350px) {
  .header-inner {
    width: calc(100% - 40px);
    gap: 16px;
  }

  .header-logo {
    width: 145px;
  }

  .header-nav {
    position: static;
    top: auto;
    left: auto;
    height: 100%;
    min-width: 0;
    margin-left: auto;
    transform: none;
  }

  .header-nav-list {
    gap: clamp(12px, 1.1vw, 18px);
  }

  .site-header .header-nav-link,
  .site-header button.header-nav-link,
  .site-header a.header-nav-link {
    font-size: 13px;
    gap: 6px;
  }

  .header-actions {
    margin-left: 0;
    flex: 0 0 auto;
    gap: 14px;
  }

  .site-header .consultation-button {
    height: 48px;
    padding-left: 18px;
    font-size: 12px;
  }

  .consultation-arrow {
    width: 45px;
    height: 48px;
    margin-left: 10px;
  }

  .mega-menu {
    width: calc(100vw - 50px);
  }

  .mega-menu-panel {
    grid-template-columns: minmax(0, 1fr) 270px;
    gap: 16px;
    padding: 18px;
  }

  .mega-menu-main {
    gap: 10px;
    padding: 6px;
  }

  .mega-link,
  .mega-featured {
    padding: 14px;
  }

  .mega-title {
    font-size: 14px;
  }

  .mega-description {
    font-size: 12px;
  }
}

@media (max-width: 1120px) {
  :root {
    --header-height: 72px;
  }

  .header-inner {
    width: calc(100% - 40px);
  }

  .site-header .header-nav,
  .site-header .language-switcher,
  .site-header .consultation-button {
    display: none;
  }

  .site-header .burger {
    display: block;
  }

  .header-logo {
    width: 135px;
  }

  .header-actions {
    margin-left: auto;
  }
}

@media (max-width: 600px) {
  :root {
    --header-height: 66px;
  }

  .header-inner {
    width: calc(100% - 30px);
  }

  .header-logo {
    width: 120px;
  }

  .mobile-menu-inner {
    padding-left: 15px;
    padding-right: 15px;
  }

  .mobile-main-link,
  .mobile-nav-toggle {
    font-size: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-header *,
  .site-header *::before,
  .site-header *::after {
    transition-duration: 0.01ms;
    animation-duration: 0.01ms;
  }
}
