/* V2 升级包 - 主页美化增强（精简版） */
/* 版本: 2.0.1 | 日期: 2026-11-03 */

/* 底部导航项悬浮光晕 */
.ng-bottom-nav__item::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 20px;
  background: radial-gradient(circle at center, 
    rgba(47, 123, 255, 0.15) 0%, 
    transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 0;
}

.ng-bottom-nav__item:hover::before {
  opacity: 1;
}

/* 激活项脉冲动画 */
.ng-bottom-nav__item[aria-current="page"] .ng-bottom-nav__icon {
  animation: navIconPulse 2s ease-in-out infinite;
}

@keyframes navIconPulse {
  0%, 100% {
    transform: scale(1);
    filter: saturate(1.08) brightness(1.05) drop-shadow(0 0 0 rgba(47, 123, 255, 0));
  }
  50% {
    transform: scale(1.05);
    filter: saturate(1.15) brightness(1.1) drop-shadow(0 0 8px rgba(47, 123, 255, 0.4));
  }
}

/* ===== 主页美化增强 ===== */

/* 分类标题装饰线增强 */
#cardsScroll .section .pk16-category-title {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 28px 0 16px;
  padding: 8px 0;
  font-size: 22px;
  font-weight: 800;
  color: #0f2250;
  letter-spacing: 0.5px;
  text-align: center;
  transition: transform 0.3s ease, text-shadow 0.3s ease;
}

#cardsScroll .section .pk16-category-title::before,
#cardsScroll .section .pk16-category-title::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, 
    transparent, 
    var(--primary-strong) 20%, 
    var(--accent) 50%, 
    var(--primary-strong) 80%, 
    transparent);
  box-shadow: 0 2px 8px rgba(47, 123, 255, 0.3);
}

#cardsScroll .section .pk16-category-title::before {
  top: 0;
}

#cardsScroll .section .pk16-category-title::after {
  bottom: 0;
}

/* 分类标题悬浮效果 */
#cardsScroll .section .pk16-category-title:hover {
  transform: scale(1.02);
  text-shadow: 0 2px 12px rgba(47, 123, 255, 0.3);
}

/* 卡片网格间距优化 */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 8px;
}

/* 卡片入场动画增强 */
.card {
  animation: cardSlideIn 0.62s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: var(--stagger, 0ms);
}

@keyframes cardSlideIn {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* 轮播图指示器增强 */
.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(15, 40, 90, 0.15);
  border: 1px solid rgba(15, 40, 90, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
}

.dot.active {
  background: var(--primary);
  box-shadow: 0 0 12px rgba(47, 123, 255, 0.5);
  transform: scale(1.3);
  animation: dotPulse 1.5s ease-in-out infinite;
}

@keyframes dotPulse {
  0%, 100% {
    box-shadow: 0 0 12px rgba(47, 123, 255, 0.5);
  }
  50% {
    box-shadow: 0 0 18px rgba(47, 123, 255, 0.8);
  }
}

/* 公告栏流光边框 */
.marquee-wrap {
  position: relative;
  overflow: hidden;
}

.marquee-wrap::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 14px;
  background: linear-gradient(90deg, 
    transparent 0%, 
    rgba(255, 255, 255, 0.4) 25%, 
    rgba(255, 255, 255, 0.6) 50%, 
    rgba(255, 255, 255, 0.4) 75%, 
    transparent 100%);
  background-size: 200% 100%;
  animation: marqueeBorderFlow 4s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
  opacity: 0.6;
}

@keyframes marqueeBorderFlow {
  0%, 100% { background-position: -100% 0; }
  50% { background-position: 100% 0; }
}

.marquee-wrap > * {
  position: relative;
  z-index: 1;
}
