/* 移动端和桌面端通用样式 */
.swiper-pagination-bullet {
  position: relative;
  background: rgba(0, 0, 0, 0.29) !important;
  opacity: 0.4 !important;
  border-radius: 0 !important;
}

/* 激活项样式 */
.swiper-pagination-bullet-active {
  opacity: 1 !important;
  /* 保留原始灰色背景 */
}

/* 进度条动画轨道（覆盖在原始背景上） */
.swiper-pagination-bullet-active::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 100%;
  background: #0023ff;
  animation: progress 5s linear forwards;
  z-index: 1; /* 确保进度条在原始背景上方 */
}

/* 移动端特殊尺寸 */
@media (max-width: 767px) {
  .swiper-pagination-bullet {
    width: 40px !important;
    height: 3px !important;
    margin: 0 2px !important;
  }
}

/* 桌面端特殊尺寸 */
@media (min-width: 768px) {
  .swiper-pagination-bullet {
    width: 50px !important;
    height: 4px !important;
    margin: 0 5px !important;
  }
}

@keyframes progress {
  from { width: 0; }
  to { width: 100%; }
}

/* 切换时重置动画 */
.swiper-container-active .swiper-pagination-bullet-active::after {
  animation: none;
}