.site-header {
  height: 67px;
  padding: 0 max(22px, calc((100vw - 1280px) / 2));
  overflow: visible;
  background: rgba(255,255,255,.96);
  font-size: 14px;
}

.brand {
  flex-direction: row;
  align-items: center;
  gap: 0;
  min-width: 270px;
  height: 67px;
}

.official-logo { width: 54px; height: 28px; object-fit: contain; }
.logo-divider { width: 1px; height: 20px; margin: 0 15px; background: #ebeef5; }
.lab-logo { width: 92px; height: 26px; object-fit: contain; }

.nav {
  align-self: stretch;
  gap: 0;
  font-size: 14px;
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  height: 67px;
  padding: 0 16px;
}

.nav-item::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 3px;
  background: #006cff;
  transform: translateX(-50%);
  transition: width .3s ease;
}

.nav-item:hover::after { width: calc(100% - 20px); }
.nav-item > a,.nav-trigger { color: #1c1d1f !important; white-space: nowrap; }
.nav-trigger { padding: 0; border: 0; background: transparent; cursor: pointer; }
.nav-trigger span { display: inline-block; margin-left: 5px; color: #8a8d94; transition: transform .25s ease; }
.has-dropdown:hover .nav-trigger span { transform: rotate(180deg); }

.header-login {
  display: block !important;
  width: 70px;
  height: 32px;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 4px !important;
  color: #fff !important;
  line-height: 32px !important;
  text-align: center;
  background: #e8404b !important;
  box-shadow: none !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  text-decoration: none !important;
  transform: none !important;
  transition: none !important;
}

.header-login:hover,.header-login:focus,.header-login:active { color: #fff !important; background: #e8404b !important; transform: none !important; }
.nav-item.login-item { padding-right: 5px; padding-left: 5px; }
.nav-item:last-child::after { display: none; }

.mega-menu {
  position: fixed;
  z-index: 30;
  top: 67px;
  right: 0;
  left: 0;
  visibility: hidden;
  padding: 0 24px;
  border-top: 1px solid #f0f1f3;
  background: rgba(255,255,255,.94);
  box-shadow: 0 12px 24px rgba(20,25,35,.1);
  opacity: 0;
  transform: translateY(-8px);
  backdrop-filter: blur(14px);
  transition: opacity .22s ease, transform .22s ease, visibility .22s;
}

.has-dropdown:hover .mega-menu {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
}

.mega-inner {
  display: grid;
  grid-template-columns: 205px 1fr;
  gap: 42px;
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 36px 0 42px;
}

.mega-heading { padding-right: 30px; border-right: 1px solid #eceef2; }
.mega-heading span { display: block; font-size: 20px; font-weight: 700; }
.mega-heading a { display: inline-block; margin-top: 65px; color: #747780; font-size: 12px; }

.mega-products { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 10px 18px; }
.mega-products.three { grid-template-columns: repeat(3, minmax(0,1fr)); }
.mega-products > a { display: flex; align-items: center; gap: 13px; min-height: 78px; padding: 12px 15px; border: 1px solid transparent; transition: .2s ease; }
.mega-products > a:hover { border-color: #e8e9ed; background: #f8f8fa; transform: translateY(-2px); }
.mega-products img,.service-icon { flex: 0 0 38px; width: 38px; height: 38px; object-fit: contain; }
.mega-products img.academy-icon { flex-basis: 48px; width: 48px; height: 48px; }
.service-icon { display: grid; place-items: center; border-radius: 8px; color: #fff; font-size: 15px; font-weight: 700; background: linear-gradient(145deg,#e8404b,#f3757d); }
.mega-products b { display: block; color: #22242a; font-size: 14px; font-weight: 600; }
.mega-products p { margin: 6px 0 0; overflow: hidden; color: #8a8d95; font-size: 11px; line-height: 1.5; text-overflow: ellipsis; white-space: nowrap; }
.compact-menu .mega-inner { padding-top: 30px; padding-bottom: 34px; }

@media (max-width: 1120px) {
  .site-header { padding-right: 20px; padding-left: 20px; }
  .brand { min-width: 205px; }
  .lab-logo,.logo-divider { display: none; }
  .nav-item { padding-right: 10px; padding-left: 10px; }
}

@media (max-width: 850px) {
  .site-header { height: 64px; }
  .brand { min-width: 0; height: 64px; }
  .official-logo { width: 54px; height: 28px; }
  .lab-logo,.logo-divider { display: block; }
  .lab-logo { width: 82px; height: 23px; }
  .logo-divider { margin-right: 11px; margin-left: 11px; }
  .nav { top: 64px; max-height: calc(100vh - 64px); padding: 12px 20px 28px; overflow-y: auto; }
  .nav-item { display: block; height: auto; padding: 0; }
  .nav-item::after { display: none; }
  .nav-item > a,.nav-trigger { display: block; width: 100%; padding: 14px 2px; border-bottom: 1px solid #eff0f2; text-align: left; }
  .nav-trigger span { float: right; }
  .header-login { height: 42px !important; margin-top: 14px; color: #fff !important; line-height: 14px !important; text-align: center !important; }
  .mega-menu { position: static; display: none; visibility: visible; padding: 0; border: 0; box-shadow: none; opacity: 1; transform: none; backdrop-filter: none; }
  .mobile-open .mega-menu { display: block; }
  .mobile-open .nav-trigger span { transform: rotate(180deg); }
  .mega-inner { display: block; padding: 10px 0 16px; }
  .mega-heading { display: none; }
  .mega-products,.mega-products.three { grid-template-columns: 1fr; gap: 4px; }
  .mega-products > a { min-height: 62px; padding: 9px 10px; background: #f8f8fa; }
  .mega-products img,.service-icon { flex-basis: 32px; width: 32px; height: 32px; }
}

@media (max-width: 430px) {
  .lab-logo,.logo-divider { display: none; }
}
