/* ===== 可切换 Banner 轮播 ===== */
.banner-section {
  position: relative;
  border-radius: var(--r-xl);
  overflow: hidden;
}

.banner-track {
  position: relative;
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(108,99,255,.15), 0 2px 8px rgba(0,0,0,.04);
}

.banner-slide {
  position: relative;
  display: none;
  min-height: 160px;
  padding: 26px 24px;
  border-radius: var(--r-xl);
  overflow: hidden;
}
.banner-slide.active { display: block; }

.banner-slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
  transform: scale(1.05);
}

.banner-slide-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  /* 左边毛玻璃渐变→右边清晰可见 */
  background: linear-gradient(90deg,
    rgba(108,99,255,.82) 0%,
    rgba(108,99,255,.55) 30%,
    rgba(108,99,255,.2) 60%,
    rgba(108,99,255,0) 100%
  );
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
}

/* 左侧文字区域加一层毛玻璃遮罩，右侧保持清晰 */
.banner-slide-overlay::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 60%;
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
}

.banner-content {
  position: relative;
  z-index: 2;
  color: #fff;
}

.banner-greeting {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
  text-shadow: 0 2px 12px rgba(0,0,0,.2);
}

.banner-slogan {
  font-size: 14px;
  line-height: 1.6;
  opacity: .95;
  text-shadow: 0 1px 8px rgba(0,0,0,.15);
}

.banner-btn {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.banner-btn i { font-size: 18px; }

/* 指示点 */
.banner-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
}

.banner-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(108,99,255,.2);
  transition: .3s var(--ease);
  cursor: pointer;
}

.banner-dots span.active {
  width: 22px;
  border-radius: 999px;
  background: var(--primary);
  box-shadow: 0 2px 8px rgba(108,99,255,.35);
}

/* ===== 全局毛玻璃卡片（高级感） ===== */
.glass-card-refined {
  background: rgba(255,255,255,.5);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,.6);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-glass);
  position: relative;
  overflow: hidden;
}

/* ===== 角色卡片网格：3列2行 ===== */
.role-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.role-card {
  background: rgba(255,255,255,.5);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,.6);
  border-radius: var(--r);
  box-shadow: var(--shadow-glass);
  padding: 14px 8px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: transform .22s var(--ease), box-shadow .25s var(--ease);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.role-card:active {
  transform: scale(.96);
  box-shadow: var(--shadow-float);
}

.role-avatar-wrap {
  width: 52px;
  height: 52px;
  margin-bottom: 8px;
  position: relative;
  z-index: 1;
}

.role-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,.95);
  background: rgba(255,255,255,.5);
  box-shadow: 0 4px 14px rgba(110,140,255,.1);
}

/* 阵营小圆点 */
.role-faction-dot {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,.95);
  box-shadow: 0 2px 6px rgba(0,0,0,.18);
}
.role-faction-蜀 { background: linear-gradient(135deg, #EF9A9A, #C62828); }
.role-faction-魏 { background: linear-gradient(135deg, #BBE0FF, #1976D2); }
.role-faction-吴 { background: linear-gradient(135deg, #FFE0B2, #F57C00); }
.role-faction-群 { background: linear-gradient(135deg, #CE93D8, #7B1FA2); }
.role-faction- { background: linear-gradient(135deg, var(--primary), var(--warm)); }

.role-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  position: relative;
  z-index: 1;
  min-width: 0;
}

.role-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.role-tag {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 999px;
  color: var(--primary);
  font-weight: 500;
  background: var(--primary-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* ===== 经典篇章 2X3 卡片网格 ===== */
.chapter-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: minmax(150px, auto);
  gap: 12px;
}

.chapter-card {
  background: rgba(255,255,255,.5);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,.6);
  border-radius: var(--r);
  box-shadow: var(--shadow-glass);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: transform .22s var(--ease), box-shadow .25s var(--ease);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.chapter-card > * {
  position: relative;
  z-index: 1;
}

.chapter-card:active {
  transform: scale(.97);
  box-shadow: var(--shadow-float);
}

.chapter-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.chapter-card .chapter-no {
  font-size: 11px;
  color: var(--primary);
  font-weight: 600;
  background: var(--primary-soft);
  padding: 3px 10px;
  border-radius: var(--r-pill);
}

.chapter-fav-btn {
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  color: var(--ink-3);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background .15s, transform .15s;
  padding: 0;
  font-size: 16px;
}

.chapter-fav-btn:hover {
  background: rgba(239,68,68,.08);
}

.chapter-fav-btn:active {
  transform: scale(.88);
}

.chapter-fav-btn .chapter-fav-icon {
  transition: color .15s;
}

.chapter-fav-btn.favorited .chapter-fav-icon {
  color: #EF4444;
}

.chapter-fav-btn.favorited .chapter-fav-icon::before {
  content: "\ee02"; /* ri-heart-fill */
}

.chapter-card .chapter-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.4;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.chapter-card .chapter-summary {
  font-size: 12px;
  color: var(--ink-3);
  line-height: 1.55;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.chapter-card-foot {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-top: 6px;
  border-top: 1px solid rgba(0,0,0,.04);
  margin-top: auto;
}

.chapter-foot-text {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.chapter-foot-divider {
  width: 1px;
  height: 10px;
  background: rgba(0,0,0,.08);
}

.chapter-foot-ai {
  font-size: 11px;
  font-weight: 500;
  color: var(--ink-3);
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

/* ===== 阵营筛选 ===== */
.faction-tabs {
  display: flex;
  gap: 8px;
  padding: 4px;
  background: rgba(255,255,255,.5);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,.6);
  border-radius: var(--r-pill);
  margin-bottom: 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.faction-tabs::-webkit-scrollbar { display: none; }

.faction-tab {
  padding: 8px 14px;
  border-radius: var(--r-pill);
  font-size: 13px;
  color: var(--ink-2);
  cursor: pointer;
  white-space: nowrap;
  font-weight: 500;
  transition: .2s;
}

.faction-tab.active {
  background: rgba(255,255,255,.8);
  box-shadow: var(--shadow-float);
  font-weight: 600;
}

.faction-tab[data-faction="蜀"].active { color: var(--faction-shu-deep); }
.faction-tab[data-faction="魏"].active { color: var(--faction-wei-deep); }
.faction-tab[data-faction="吴"].active { color: #0e8a80; }
.faction-tab[data-faction="群"].active { color: #6a4fb5; }
.faction-tab[data-faction="全部"].active { color: var(--primary); }

/* ===== section-title 使用 Remix Icon ===== */
.section-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.section-title i {
  font-size: 18px;
  color: var(--primary);
}

.section-link {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.section-link i { font-size: 16px; }
