.nav-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  font-weight: 400;
  z-index: 100;
}

.nav-log-img {
  width: 98px;
  object-fit: contain;
}

.nav-bar-title-box {
  position: relative;
  width: 100%;
  padding: 0 8px 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f9f9f9;
}

.nav-bar-title {
  display: flex;
  font-size: 16px;
}

.nav-bar-index-title {
  padding: 0 32px;
  position: relative;
  height: 61px; /* 设置高度 */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.nav-bar-title-line {
  margin-top: 8px;
  width: 100%;
  height: 1px;
  background-color: #ff5a16;
  opacity: 0; /* 初始状态为隐藏 */
  transition: opacity 0.4s ease-out;
}

.nav-bar-title-line-show {
  opacity: 1;
}

.nav-bar-popup {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 99;
  opacity: 0;
  padding: 61px 0 0 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(61px);
  /* 隐藏/显示时的渐隐渐现过渡 */
  transition: opacity 0.3s ease;
}

.nav-bar-popup-item {
  width: 82%;
  display: none;
  flex-direction: column;
  padding: 40px 0 80px 0;
  font-size: 15px;
  font-weight: 400;
  gap: 20px;
  color: #fff;
}

.nav-bar-popup-show {
  opacity: 1;
  pointer-events: auto;
}

.nav-bar-popup-hide {
  opacity: 0;
  pointer-events: none;
}

.nav-bar-popup-item-show {
  display: flex;
}

.nav-bar-popup-item .item-box {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  gap: 10px;
}

.nav-bar-popup-item .other-gap {
  gap: 20px;
}

.nav-bar-popup-item .flex-gap {
  display: flex;
  gap: 80px;
}

.nav-bar-popup-item .item-box .item-list {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(11, 1fr);
  gap: 10px;
  border-radius: 10px;
}

.nav-bar-popup-item .item-box .item-list .item {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  width: 100%;
  min-width: 0;
}

.nav-bar-popup-item .item-box .item-list .item .badge {
  position: absolute;
  top: 0px;
  right: 0px;
  width: 38px;
  height: 15px;
  background: #ff5a16;
  display: flex;
  justify-content: center;
  font-size: 12px;
  line-height: 100%;
  color: #faf4f4;
  border-radius: 0 10px 0 10px;
}

.nav-bar-popup-item .item-box .item-list .item .item-img {
  border-radius: 10px;
  background-position: center;
  background-size: contain;
  aspect-ratio: 62 / 39;
  border: 1.5px solid transparent;
  box-sizing: border-box;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  background-origin: content-box;
  width: 100%;
  /*transition: transform 0.3s;*/
}

.nav-bar-popup-item .item-box .item-list .item:hover .item-img {
  border: 1.5px solid #ff5a16;
  /*transform: scale(1.1);*/
}

.nav-bar-popup-item .item-box .item-list .item .item-text {
  color: #ffffff;
  font-size: 12px;
  text-align: center;
  margin-top: 10px;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 驱动中心 / 其他 弹窗内的链接：hover 变色 */
#drive-popup a,
#others-popup a {
  transition: color 0.3s ease; /* 平滑过渡，可选 */
}

#drive-popup a:hover,
#others-popup a:hover {
  color: #ff5a16;
}

/* 移动端 */

.mobile-nav-bar-popup {
  position: fixed;
  top: 0;
  left: 0;
  /* 保持低于导航栏(.nav-bar, z-index:100)，否则全屏会盖住导航栏里的关闭按钮 */
  z-index: 99;
  display: none;
  opacity: 0;
  pointer-events: none;
  padding-top: 34px;
  align-items: center;
  justify-content: center;
  background-color: #ffffff;

  width: 100%;
  /* 铺满视口高度，内容超出时可滚动 */
  overflow-y: auto;
}

.mobile-nav-bar-title-box {
  position: relative;
  width: 100%;
  height: 34px;
  padding: 0 24px;
  display: none;
  justify-content: space-between;
  align-items: center;
  background-color: #f9f9f9;
}

.mobile-nav-bar-title-box .menu-img {
  width: 9px;
  height: 9px;
}

.mobile-nav-bar-title-box .menu-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mobile-nav-log-img {
  width: 44px;
  object-fit: contain;
}

.mobile-popup {
  padding: 30px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
}

.mobile-popup .title-box {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.mobile-popup .title-box .title {
  font-size: 15px;
  font-weight: 500;
  color: #000;
}

.mobile-popup .title-box .item-box {
  display: flex;
  flex-direction: column;
  gap: 12.5px;
  font-size: 12.5px;
  color: #43464b;
}

@media screen and (max-width: 768px) {
  .nav-bar {
    border-bottom: 0.5px solid #d8d8d8;
  }

  /* 桌面导航隐藏，移动导航显示 */
  .nav-bar-title-box {
    display: none;
  }

  .mobile-nav-bar-title-box {
    display: flex;
  }

  .float-btn-view .mobile-float-btn {
    display: flex;
  }

  /* 移动弹窗：默认隐藏，body.menu-open 时显示 */
  .mobile-nav-bar-popup {
    display: none;
    opacity: 0;
    pointer-events: none;
  }

  body.menu-open .mobile-nav-bar-popup {
    display: flex;
    opacity: 1;
    pointer-events: auto;
  }

  /* 菜单图标：默认显示汉堡(menu-list)、隐藏关闭(menu-close)；打开时互换 */
  #menu-list {
    display: flex;
  }

  #menu-close {
    display: none;
  }

  body.menu-open #menu-list {
    display: none;
  }

  body.menu-open #menu-close {
    display: flex;
  }
}

/* 桌面端（≥768px）：即使 JS 曾打开菜单（body.menu-open），移动弹窗与图标也不残留 */
@media screen and (min-width: 768px) {
  .mobile-nav-bar-popup {
    display: none !important;
  }
}
