.header-one {
  opacity: 1 !important;
  visibility: visible !important;
  filter: none !important;
}

.header-one .nav-item-link {
  border-radius: 9999px;
  transition: color 180ms ease, background-color 180ms ease,
    border-color 180ms ease, box-shadow 180ms ease;
}

@media (hover: hover) {
  .header-one .nav-item-link:hover {
    box-shadow: 0 4px 10px rgba(8, 15, 30, 0.22),
      0 1px 3px rgba(10, 74, 145, 0.16);
  }
}

.header-one .nav-item-link:focus-visible,
.header-one .nav-item.is-open > .nav-item-link {
  box-shadow: 0 4px 10px rgba(8, 15, 30, 0.22),
    0 1px 3px rgba(10, 74, 145, 0.16);
}

.header-one .nav-item-link.is-current,
.header-one .nav-item.is-current > .nav-item-link {
  border-color: rgba(18, 116, 214, 0.28);
  background: rgba(18, 163, 252, 0.12);
  color: #0a4a91;
  font-weight: 600;
  box-shadow: 0 3px 8px rgba(8, 15, 30, 0.18),
    inset 0 0 0 1px rgba(255, 255, 255, 0.34);
}

.header-one .nav-item-link:active {
  box-shadow: 0 2px 6px rgba(8, 15, 30, 0.26),
    inset 0 1px 2px rgba(8, 15, 30, 0.18);
}

.dark .header-one .nav-item-link:hover,
.dark .header-one .nav-item-link:focus-visible,
.dark .header-one .nav-item.is-open > .nav-item-link {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}

.dark .header-one .nav-item-link.is-current,
.dark .header-one .nav-item.is-current > .nav-item-link {
  border-color: rgba(80, 178, 255, 0.38);
  background: rgba(18, 163, 252, 0.16);
  color: #8ed3ff;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3),
    inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.dark .header-one .nav-item-link:active {
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3),
    inset 0 1px 2px rgba(0, 0, 0, 0.22);
}

/* Tailwind's individual `translate` property is not supported by every mobile
   WebView. Anchor the floating header to both viewport edges instead. */
@media (max-width: 1279px) {
  .header-one {
    box-sizing: border-box;
    left: 50% !important;
    right: auto !important;
    width: calc(100% - 32px) !important;
    max-width: 540px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-right: 76px !important;
    transform: translateX(-50%) !important;
    translate: none !important;
  }

  .header-one > div:first-child {
    flex: 0 1 auto;
    min-width: 0;
  }

  .header-one > div:first-child a {
    display: block;
    min-width: 0;
  }

  .header-one > div:first-child figure {
    min-width: 0;
  }

  .header-one > div:first-child img {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  .header-one > .flex {
    display: none !important;
  }

  .header-one > div:last-child {
    display: block !important;
    position: absolute;
    top: 50%;
    right: 10px;
    width: 48px;
    height: 48px;
    margin: 0;
    transform: translateY(-50%);
  }
}

@media (max-width: 1023px) {
  .header-one > div:first-child figure.lg\:hidden {
    width: clamp(150px, 48vw, 215px);
  }
}

@media (max-width: 359px) {
  .header-one {
    width: calc(100% - 16px) !important;
  }

  .header-one > div:first-child figure.lg\:hidden {
    width: 145px;
  }
}

@media (min-width: 1280px) {
  .header-one {
    max-width: min(1290px, calc(100vw - 48px)) !important;
  }

  .header-one > div:first-child,
  .header-one > .flex {
    flex-shrink: 0;
  }

  .header-one > nav {
    flex: 1 1 auto;
    justify-content: center;
    min-width: 0;
  }

  .header-one .nav-item-link {
    padding-left: clamp(8px, 1vw, 16px);
    padding-right: clamp(8px, 1vw, 16px);
    white-space: nowrap;
  }
}
/* 桌面端大导航由共享脚本切换 is-open；hover/focus-within 作为稳定回退。 */
.nav-item > div > .mega-menu,
.nav-item > div > .dropdown-menu {
  visibility: hidden;
  transform: translate(-50%, -8px);
}

.nav-item.is-open > div > .mega-menu,
.nav-item.is-open > div > .dropdown-menu,
.nav-item:hover > div > .mega-menu,
.nav-item:hover > div > .dropdown-menu,
.nav-item:focus-within > div > .mega-menu,
.nav-item:focus-within > div > .dropdown-menu {
  visibility: visible;
  pointer-events: auto;
  opacity: 1;
  transform: translate(-50%, 0);
}

.nav-item.is-open > div > .mega-menu-bridge,
.nav-item.is-open > div > .dropdown-menu-bridge,
.nav-item:hover > div > .mega-menu-bridge,
.nav-item:hover > div > .dropdown-menu-bridge,
.nav-item:focus-within > div > .mega-menu-bridge,
.nav-item:focus-within > div > .dropdown-menu-bridge {
  pointer-events: auto;
}

.nav-item.is-open > .nav-item-link .nav-arrow,
.nav-item:hover > .nav-item-link .nav-arrow,
.nav-item:focus-within > .nav-item-link .nav-arrow {
  transform: translateY(1px) rotate(180deg);
}

.p1-mega-layout {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  padding: 30px 25px;
}

.p1-mega-menu--application {
  max-width: 1290px;
}

.p1-mega-menu--product {
  max-width: 680px;
}

.p1-mega-menu--resources {
  max-width: 830px;
}

.p1-mega-main {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
}

.p1-mega-grid {
  display: grid;
  gap: 16px;
}

.p1-mega-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.p1-mega-grid--one {
  grid-template-columns: minmax(0, 1fr);
}

.p1-mega-grid--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.p1-mega-card,
.p1-mega-card > span:last-child {
  min-width: 0;
}

.p1-mega-card {
  border-radius: 20px;
  transition: border-color 180ms ease, background-color 180ms ease,
    box-shadow 180ms ease;
}

@media (hover: hover) {
  .p1-mega-card:hover {
    box-shadow: 0 6px 14px rgba(8, 15, 30, 0.2),
      0 1px 4px rgba(10, 74, 145, 0.14);
  }
}

.p1-mega-card:focus-visible {
  outline: none;
  box-shadow: 0 6px 14px rgba(8, 15, 30, 0.2),
    0 1px 4px rgba(10, 74, 145, 0.14),
    0 0 0 2px rgba(10, 74, 145, 0.34);
}

.p1-mega-card:active {
  box-shadow: 0 3px 8px rgba(8, 15, 30, 0.24),
    inset 0 1px 2px rgba(8, 15, 30, 0.18);
}

.p1-mega-card.is-current {
  border-color: rgba(18, 116, 214, 0.42) !important;
  background: rgba(18, 163, 252, 0.1);
  box-shadow: 0 3px 8px rgba(8, 15, 30, 0.16),
    inset 3px 0 0 #1274d6;
}

.dark .p1-mega-card:hover,
.dark .p1-mega-card:focus-visible {
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}

.dark .p1-mega-card.is-current {
  border-color: rgba(80, 178, 255, 0.42) !important;
  background: rgba(18, 163, 252, 0.14);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3),
    inset 3px 0 0 #50b2ff;
}

.dark .p1-mega-card:active {
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.34),
    inset 0 1px 2px rgba(0, 0, 0, 0.24);
}

.p1-mega-card > span:last-child > span {
  word-break: normal;
  overflow-wrap: break-word;
}

.p1-mega-blog {
  box-sizing: border-box;
  flex: 0 0 310px;
  width: 310px;
  min-width: 310px;
}

.p1-mega-menu--product .p1-mega-blog,
.p1-mega-menu--resources .p1-mega-blog {
  flex-basis: 280px;
  width: 280px;
  min-width: 280px;
}

.p1-mega-blog-image {
  display: block;
  width: 100%;
  height: 205px;
  object-fit: cover;
}

.p1-mega-menu--product .p1-mega-blog-image,
.p1-mega-menu--resources .p1-mega-blog-image {
  height: 186px;
}

.p1-nav-recommendation {
  position: absolute;
  z-index: 1;
  top: 6px;
  right: 0;
  display: block;
  width: 32px;
  min-width: 32px;
  max-width: none;
  height: 14px;
  object-fit: contain;
}
/* Reserve the brand slot before the lazy image is decoded. */
@media (min-width: 1024px) {
  .header-one > div:first-child figure {
    width: 198px;
    height: 41px;
  }

  .header-one > div:first-child figure img {
    width: 100%;
    height: 100%;
    object-fit: contain;
  }
}
/* 火山集团官网同款页头：桌面横向导航，移动端右侧抽屉。 */
.hj-legacy-header { display: none !important; }
.hj-site-header { position: relative; z-index: 100; }
.hj-main-nav { background: #0c5adb; border-bottom: 1px solid rgb(255 255 255 / 12%); padding: 8px 0; }
.hj-nav-inner { width: min(1260px, calc(100% - 44px)); height: 58px; margin: 0 auto; display: flex; align-items: center; gap: 34px; }
.hj-brand { display: inline-flex; align-items: center; flex: 0 0 auto; }
.hj-brand img { display: block; width: 164px; height: auto; max-height: 48px; object-fit: contain; }
.hj-nav-menu { display: flex; flex: 1 1 auto; align-items: center; justify-content: center; min-width: 0; }
.hj-nav-list { display: flex; align-items: center; justify-content: center; gap: 34px; margin: 0; padding: 0; list-style: none; }
.hj-nav-list a { display: inline-flex; height: 58px; align-items: center; color: #fff; font-size: 16px; font-weight: 600; line-height: 1; text-decoration: none; white-space: nowrap; transition: opacity .16s ease; }
.hj-nav-list a:hover, .hj-nav-list a.is-current { color: #fff; opacity: .75; }
.hj-demo-button { flex: 0 0 auto; min-width: 156px; height: 48px; padding: 0 24px; border-radius: 999px; background: #1477f8; color: #fff; display: inline-flex; align-items: center; justify-content: center; gap: 10px; font-size: 16px; font-weight: 700; text-decoration: none; box-shadow: 0 9px 22px rgb(0 50 150 / 20%); }
.hj-demo-button:hover { color: #fff; background: #2a88ff; }
.hj-demo-button--mobile, .hj-nav-toggle, .hj-nav-close, .hj-nav-overlay { display: none; }
@media (max-width: 991px) {
  .hj-nav-inner { width: min(100% - 32px, 760px); justify-content: space-between; gap: 16px; }
  .hj-brand img { width: 145px; }
  .hj-demo-button--desktop { display: none; }
  .hj-nav-toggle { width: 42px; height: 42px; padding: 0; border: 0; border-radius: 50%; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; color: #0c5adb; background: #fff; cursor: pointer; }
  .hj-nav-toggle span { width: 18px; height: 2px; border-radius: 2px; background: currentColor; }
  .hj-nav-menu { position: fixed; z-index: 1002; top: 0; right: 0; width: min(320px, 88vw); height: 100dvh; padding: 78px 24px 28px; display: block; background: #fff; box-shadow: -16px 0 32px rgb(20 34 66 / 16%); transform: translateX(100%); transition: transform .24s ease; }
  .hj-nav-menu.is-open { transform: translateX(0); }
  .hj-nav-close { position: absolute; top: 18px; right: 18px; display: inline-flex; width: 38px; height: 38px; align-items: center; justify-content: center; padding: 0; border: 0; border-radius: 50%; background: #f2f6ff; color: #0c5adb; font-size: 26px; line-height: 1; cursor: pointer; }
  .hj-nav-list { display: block; }
  .hj-nav-list li { border-bottom: 1px solid #edf1f6; }
  .hj-nav-list a { width: 100%; height: 50px; color: #1d2646; font-size: 16px; }
  .hj-nav-list a.is-current { color: #0c5adb; opacity: 1; }
  .hj-demo-button--mobile { width: 100%; margin-top: 26px; display: inline-flex; }
  .hj-nav-overlay.is-open { position: fixed; z-index: 1001; inset: 0; display: block; background: rgb(0 0 0 / 42%); }
  body.hj-nav-open { overflow: hidden; }
}
