/* ========== Reset & Base ========== */
.carousel-wrapper *,
.carousel-wrapper::before,
.carousel-wrapper::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, "PingFang SC", "Lantinghei SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: #fff;
}

/*ul,*/
/*li {*/
/*  list-style: none;*/
/*}*/

/* ========== 轮播容器 ========== */
.carousel-wrapper {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-color: #000;
  font-family: "Microsoft YaHei", sans-serif;
}

/* ========== 轮播轨道 ========== */
.carousel-track {
  display: flex;
  width: 600%;
  height: 100%;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.carousel-slide {
  width: 16.66666%;
  height: 100%;
  flex-shrink: 0;
  overflow: hidden;
}

.carousel-slide a {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  user-select: none;
  -webkit-user-drag: none;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
  transform: scale(1.1);
  /* 加大默认放大比例到 1.25 */
  transition: transform 0.8s ease-out;
  /* 失去焦点时快速恢复放大状态 */
}

/* 当前激活状态下，执行镜头拉远（缩小回原来大小）的慢速动画 */
.carousel-slide.active img {
  transform: scale(1);
  transition: transform 5s linear;
  /* 改为匀速 linear 动画，让呼吸感更连贯明显 */
}

/* 每个图片的 before 遮罩 */
.carousel-slide a::before {
  content: "";
  display: block;
  width: 100%;
  position: absolute;
  height: 3rem;
  background: url("../image/bannerbg.svg") bottom no-repeat;
  background-size: cover;
  bottom: 0;
  z-index: 3;
  pointer-events: none;
}

/* 每个图片的 after 遮罩 */
.carousel-slide a::after {
  content: "";
  display: block;
  width: 100%;
  position: absolute;
  height: 100%;
  z-index: 4;
  background: url("../image/bannerbg.png") top no-repeat;
  top: 0;
  left: 0;
  pointer-events: none;
}

/* ========== 左上角 Logo ========== */
/* ========== 头部综合容器 ========== */
.main-header {
  position: absolute;
  top: 40px;
  left: 0;
  width: 100%;
  height: 120px;
  z-index: 50;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  background-color: transparent;
  border-bottom: 1px solid transparent;
}

.main-header.sticky {
  position: fixed;
  top: 0;
  background-color: rgba(31, 92, 169, 0.88);
  /* 半透明品牌蓝 */
  backdrop-filter: blur(12px);
  /* 毛玻璃特效 */
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  height: 170px;
  z-index: 9999;
}

.logo {
  position: absolute;
  top: 28px;
  left: 4vw;
  z-index: 20;
  height: 60px;
  display: flex;
  align-items: center;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  width: auto;
  margin-left: 0;
}

.main-header.sticky .logo {
  top: 68px;
  /* 首屏的 28px + 顶部的 40px 补偿，保持视觉位置 */
  height: 60px;
  /* 恢复原大 */
}

.logo:hover {
  transform: scale(1.02);
}

.logo img {
  height: 100%;
  width: auto;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.2));
}

/* ========== 顶部右侧快捷入口 ========== */
.top-links {
  position: absolute;
  top: 28px;
  right: 4vw;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 17px;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 300;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.main-header.sticky .top-links {
  top: 68px;
  /* 首屏的 28px + 顶部的 40px 补偿，保持视觉位置 */
}

.top-links a {
  color: rgba(255, 255, 255, 0.85);
  transition:
    color 0.2s,
    opacity 0.2s;
}

.top-links a:hover {
  color: #fff;
  opacity: 1;
}

/* ========== 搜索框 ========== */
.search-form {
  display: flex;
  align-items: center;
  height: 32px;
  background-color: transparent;
  border-radius: 2px;
  overflow: hidden;
  transition: background-color 0.4s ease;
  margin-right: 8px;
}

.search-form:hover,
.search-form:focus-within {
  background-color: #fff;
}

.search-input {
  width: 0;
  height: 100%;
  padding: 0;
  border: none;
  outline: none;
  background: transparent;
  color: #333;
  font-size: 15px;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.search-input::placeholder {
  color: #999;
}

.search-form:hover .search-input,
.search-form:focus-within .search-input {
  width: 160px;
  padding: 0 12px;
}

.top-links .search-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 100%;
  background: transparent;
  border: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.85);
  transition: all 0.4s ease;
}

.top-links .search-btn:hover {
  color: #fff;
}

.search-form:hover .search-btn,
.search-form:focus-within .search-btn {
  background-color: #8ba0b3;
  /* 效果图中的灰蓝底色 */
  color: #fff;
}

.top-links .search-btn svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
}

.top-links .divider {
  color: rgba(255, 255, 255, 0.3);
  user-select: none;
  font-size: 11px;
}

/* ========== 主导航 (靠右对齐) ========== */
.main-nav {
  position: absolute;
  top: 78px;
  right: 4vw;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 15px;
  /* Adjust gap to allow padding inside nav-item */
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.main-header.sticky .main-nav {
  top: 116px;
  /* 首屏的 68px + 40px补偿 + 适当增大的 8px 间距 */
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  height: 44px;
}

.nav-link {
  font-size: 20px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.95);
  transition: all 0.2s ease;
  white-space: nowrap;
  letter-spacing: 0.5px;
  position: relative;
  padding: 12px 16px;
  /* 增加上下内边距，让底部白线离文字更远 */
  text-decoration: none;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -12px;
  /* 统一设置在此处，避免悬停时发生上下移动 */
  left: 50%;
  width: 0;
  height: 2px;
  background-color: #fff;
  transition: width 0.3s ease;
  /* 专门为宽度添加过渡动画 */
  transform: translateX(-50%);
}

.nav-item:hover .nav-link {
  color: #fff;
  background-color: #1f5ca9;
  /* 悬停蓝色背景 */
}

.nav-item:hover .nav-link::after {
  width: 60%;
}

/* ========== 下拉二级菜单 ========== */
.sub-nav {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background-color: #fff;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
  visibility: hidden;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 30;
  padding: 20px;
  margin-top: 35px;
  /* 初始状态往下移 */
}

/* 桥接，防止鼠标离开触发区域 */
.sub-nav::before {
  content: "";
  position: absolute;
  top: -35px;
  left: 0;
  right: 0;
  height: 35px;
}

.nav-item:hover .sub-nav {
  visibility: visible;
  opacity: 1;
  margin-top: 20px;
  /* 悬停时保留 20px 的间距（向下移动了一点） */
}

.sub-nav-inner {
  display: flex;
  gap: 30px;
  align-items: center;
}

.sub-img img {
  display: block;
  width: 250px;
  height: auto;
  object-fit: cover;
}

.sub-links {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 15px 30px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.sub-links li {
  position: relative;
  padding-left: 15px;
}

.sub-links li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #1f5ca9;
  /* 蓝色圆点 */
}

.sub-links a {
  font-size: 18px;
  font-weight: normal;
  color: #333;
  text-decoration: none;
  transition: color 0.2s;
  white-space: nowrap;
}

.sub-links a:hover {
  color: #1f5ca9;
}

.top-links a {
  color: inherit;
  transition: opacity 0.2s;
  white-space: nowrap;
}

.top-links a:hover {
  opacity: 0.8;
}

.top-links .divider {
  opacity: 0.5;
  margin: 0 2px;
}

/* ========== 顶部右侧信息 (代替原本的快捷链接) ========== */
.head_info {
  display: flex;
  align-items: center;
  gap: 15px;
}

.head_info span {
  display: flex;
  align-items: center;
  position: relative;
  cursor: pointer;
}

.head_info s {
  text-decoration: none;
  font-weight: bold;
  margin-left: 5px;
}

.wechat-hover i {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  display: none;
  padding-top: 10px;
  z-index: 100;
}

.wechat-hover i img {
  width: 100px;
  height: 120px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}

.wechat-hover:hover i {
  display: block;
}

/* ========== 左右切换主箭头 ========== */
.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  width: 44px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.22);
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  border-radius: 2px;
}

.arrow:hover {
  background: rgba(0, 0, 0, 0.45);
}

.arrow-left {
  left: 20px;
}

.arrow-right {
  right: 20px;
}

.arrow svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: rgba(255, 255, 255, 0.65);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition:
    stroke 0.3s,
    transform 0.3s;
}

.arrow:hover svg {
  stroke: #fff;
}

.arrow-left:hover svg {
  transform: translateX(-2px);
}

.arrow-right:hover svg {
  transform: translateX(2px);
}

/* ========== 右侧浮动功能条 ========== */
.right-floating-bar {
  position: absolute;
  right: 12px;
  top: 55%;
  transform: translateY(-50%);
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.floating-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: rgba(155, 13, 17, 0.85);
  /* 质感中国红 */
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.floating-btn:hover {
  background-color: rgba(180, 15, 20, 1);
  transform: scale(1.08);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

.floating-btn svg {
  width: 18px;
  height: 18px;
  fill: #ffffff;
  stroke: #ffffff;
  stroke-width: 0.5;
}

/* ========== 底部渐变及内容区 ========== */
.bottom-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 90px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 3vw 16px 3vw;
  background: linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.65) 0%,
    rgba(0, 0, 0, 0.2) 50%,
    rgba(0, 0, 0, 0) 100%
  );
  pointer-events: none;
}

/* 底部内容需要响应点击 */
.bottom-bar * {
  pointer-events: auto;
}

/* 底部左侧文字 */
.bottom-text {
  font-size: 28px;
  color: rgba(255, 255, 255, 0.92);
  letter-spacing: 1.5px;
  font-weight: 400;
  max-width: 45%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

/* 底部中间向下箭头 */
.down-arrow {
  position: absolute;
  left: 50%;
  bottom: 45px;
  transform: translateX(-50%);
  z-index: 25;
  cursor: pointer;
  animation: bounceDown 2s ease-in-out infinite;
}

.down-arrow img {
  width: 44px;
  height: auto;
  opacity: 0.8;
  transition:
    opacity 0.3s,
    transform 0.3s;
}

.down-arrow:hover img {
  opacity: 1;
  transform: scale(1.05);
}

@keyframes bounceDown {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  50% {
    transform: translateX(-50%) translateY(6px);
  }
}

/* 底部右侧指示器 */
.dots {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 32px;
}

.dots .dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1.2px solid rgba(255, 255, 255, 0.75);
  background: transparent;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
  outline: none;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.dots .dot.active {
  width: 72px;
  height: 36px;
  border-radius: 0;
  border: none;
  background: transparent;
}

.dots .dot img {
  display: none;
}

.dots .dot.active img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.dots .more-btn {
  font-size: 20px;
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  margin-left: 10px;
  white-space: nowrap;
  letter-spacing: 0.5px;
  transition: color 0.2s;
}

.dots .more-btn:hover {
  color: #fff;
  text-decoration: underline;
}

/* ========== 响应式微调 ========== */
@media (max-width: 1200px) {
  .main-nav {
    gap: 16px;
  }

  .main-nav a {
    font-size: 14px;
  }

  .logo {
    height: 52px;
  }
}

@media (max-width: 992px) {
  .top-links {
    display: none;
    /* 移动端或窄屏隐藏次要入口 */
  }

  .main-nav {
    top: 32px;
    gap: 12px;
  }

  .main-nav a {
    font-size: 13px;
  }
}
