header {
  position: fixed; /* 改为固定定位，使header固定在顶部 */
  z-index: 1000; /* 增大z-index确保header在最上层 */
  color: #fff;
  width: 100%;
  top: 0; /* 固定在顶部 */
  left: 0;
  right: 0;
  overflow-x: hidden;
  max-width: 100vw;
  box-sizing: border-box;
  background-color: #FFFFFF; /* 默认白色背景 */
  box-shadow: 0 2px 8px rgba(0,0,0,0.07); /* 默认添加阴影 */
}
header .info-top {
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.top-content {
  font-size: 14px;
  display: flex;
  gap: 18px;
  box-sizing: border-box;
  padding: 0 8%;
  line-height: 46px;
}
header .info-top .address {
  flex: 1;
}
header nav {
  box-sizing: border-box;
  padding: 10px 4%;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: transparent;
  transition: all 0.3s;
  width: 100%;
  max-width: 100%;
}
header nav.active {
  background-color: #FFFFFF;
  width: 100%;
  z-index: 9;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
}
header nav.active ul .active a {
  color: #1863AB !important;
}
header nav.active ul li a {
  color: #393939;
  transition: all 0.3s;
}
header nav.active li:hover a {
  color: #1863AB;
}
header .logo {
  height: 100%;
}
header .logo a {
  display: block;
  height: 100%;
  text-indent: -9999px;
}
header .logo img {
  height: 100%;
}
header ul {
  display: flex;
  gap: 20px;
}
header ul li {
  position: relative;
}
header ul li a {
  color: #393939; /* 修改默认文字颜色为深灰色，适应白色背景 */
}
header ul li::after {
  transition: all 0.2s;
  left: 0;
  bottom: -4px;
  position: absolute;
  content: "";
  display: block;
  width: 100%;
  height: 3px;
  background-color: #1863AB;
  transform: scaleX(0);
  transform-origin: left;
}
header ul .active::after {
  transform: scaleX(1);
  background-color: #1863AB;
}
header nav.active ul .active::after {
  background-color: #1863AB;
  transform: scaleX(1);
}
header ul li:hover::after {
  transform: scaleX(1);
}

/* 导航高亮样式 */
header ul li.active a {
  color: #1863AB; /* 修改为蓝色以匹配固定白色背景 */
  font-weight: 500;
}
header nav.active ul li.active a {
  color: #1863AB !important;
  font-weight: 500;
}
/* 移动端菜单样式 */
.mobile-menu-btn {
  display: none;
  width: 30px;
  height: 25px;
  position: relative;
  cursor: pointer;
  z-index: 10;
}

.mobile-menu-btn span {
  display: block;
  position: absolute;
  height: 3px;
  width: 100%;
  background: #1863AB;
  border-radius: 3px;
  opacity: 1;
  left: 0;
  transform: rotate(0deg);
  transition: .25s ease-in-out;
}

.mobile-menu-btn span:nth-child(1) {
  top: 0px;
}

.mobile-menu-btn span:nth-child(2) {
  top: 10px;
}

.mobile-menu-btn span:nth-child(3) {
  top: 20px;
}

.mobile-menu-btn.active span:nth-child(1) {
  top: 10px;
  transform: rotate(135deg);
}

.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
  left: -60px;
}

.mobile-menu-btn.active span:nth-child(3) {
  top: 10px;
  transform: rotate(-135deg);
}
/* 响应式导航栏 */
@media (max-width: 992px) {
  header nav {
    padding: 10px 4%;
  }
}

@media (max-width: 768px) {
  header {
    overflow: visible;
    position: fixed ;
    top: 0 ;
    left: 0;
    width: 100%;
    z-index: 1000;
  }
  
  /* 移动端菜单按钮 */
  .mobile-menu-btn {
    display: block;
    width: 30px;
    height: 25px;
    position: relative;
    cursor: pointer;
    z-index: 10;
  }
  
  header nav {
    height: 60px;
    padding: 10px 15px;
  }
  
  header ul li a {
    color: #393939 !important;
    display: block;
  }
  
  header ul li::after {
    display: none;
  }

  /* 确保移动端下拉菜单的位置和显示效果 */
  header ul {
    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    background-color: white;
    flex-direction: column;
    padding: 20px 0;
    gap: 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    transform: translateY(calc(-100% - 60px));
    transition: transform 0.3s ease;
    z-index: 100;
  }
  
  header ul.show {
    transform: translateY(0);
  }
  
  header ul li {
    width: 100%;
    text-align: center;
    padding: 10px 0;
  }
}