/* ==========================================================================
   nbqiantu.com 全站样式
   轻量移动应用风 · 内容列表优先 · 清爽二次元气质
   ========================================================================== */

/* ==========================================================================
   base — 基础变量 / 重置 / 全局排版
   ========================================================================== */

:root {
  --color-primary: #1a1a2e;
  --color-accent: #e94560;
  --color-secondary: #0f3460;
  --color-bg: #f5f5f5;
  --color-surface: #ffffff;
  --color-text: #2b2b3a;
  --color-text-light: #6b6b7b;
  --color-border: #e3e3ea;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --container-width: 1200px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 8px;
  --shadow-sm: 0 1px 3px rgba(26, 26, 46, 0.08);
  --shadow-md: 0 4px 12px rgba(26, 26, 46, 0.1);
  --transition-base: 0.2s ease;
  --breakpoint-mobile: 768px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

a {
  color: var(--color-secondary);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--color-accent);
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4 {
  line-height: 1.3;
  font-weight: 700;
  color: var(--color-primary);
}

h1 {
  font-size: 32px;
}

h2 {
  font-size: 24px;
}

h3 {
  font-size: 18px;
}

p {
  line-height: 1.7;
}

/* 无障碍隐藏 */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   layout — 全站骨架：页头 / 页脚 / 主容器 / 面包屑
   ========================================================================== */

.site-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: var(--color-bg);
}

/* ---------- 页头 ---------- */

.site-header {
  background-color: var(--color-primary);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand-logo {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  flex-shrink: 0;
}

.brand-name {
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.02em;
}

.brand-slogan {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 2px;
}

/* 主导航 */
.site-nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-item {
  padding: 0;
}

.nav-link {
  display: block;
  padding: 8px 14px;
  font-size: 15px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.82);
  border-radius: var(--radius-sm);
  transition: background-color var(--transition-base),
    color var(--transition-base);
}

.nav-link:hover {
  color: #ffffff;
  background-color: rgba(255, 255, 255, 0.1);
}

.nav-item.is-current .nav-link,
.nav-link.is-current {
  color: #ffffff;
  background-color: var(--color-accent);
}

/* 汉堡按钮（移动端） */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  border-radius: var(--radius-sm);
}

.nav-toggle-icon {
  display: block;
  width: 24px;
  height: 2px;
  background-color: #ffffff;
  position: relative;
  border-radius: 2px;
}

.nav-toggle-icon::before,
.nav-toggle-icon::after {
  content: "";
  position: absolute;
  left: 0;
  width: 24px;
  height: 2px;
  background-color: #ffffff;
  border-radius: 2px;
}

.nav-toggle-icon::before {
  top: -7px;
}

.nav-toggle-icon::after {
  top: 7px;
}

/* ---------- 面包屑 ---------- */

.breadcrumb {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 16px 24px 0;
  font-size: 14px;
  color: var(--color-text-light);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.breadcrumb a {
  color: var(--color-secondary);
}

.breadcrumb a:hover {
  color: var(--color-accent);
}

.breadcrumb-sep {
  margin: 0 8px;
  color: #b0b0c0;
}

.breadcrumb-current {
  color: var(--color-text);
  font-weight: 500;
}

/* ---------- 主容器 ---------- */

.site-main {
  flex: 1;
  width: 100%;
}

.inner-main {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px 48px;
  width: 100%;
}

/* ---------- 页标题区 ---------- */

.page-header {
  padding: 28px 0 8px;
  margin-bottom: 24px;
}

.page-title {
  font-size: 30px;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.page-description {
  font-size: 16px;
  color: var(--color-text-light);
  max-width: 720px;
}

/* ---------- 页脚 ---------- */

.site-footer {
  background-color: var(--color-primary);
  color: rgba(255, 255, 255, 0.8);
  margin-top: auto;
}

.footer-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 40px 24px 32px;
}

.footer-brand {
  margin-bottom: 24px;
}

.footer-brand-name {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
}

.footer-slogan {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 6px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-bottom: 20px;
}

.footer-link {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
  padding: 4px 0;
}

.footer-link:hover {
  color: #ffffff;
}

.footer-copyright {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
}

/* ---------- 通用 section 标题 ---------- */

.section-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 20px;
  position: relative;
  padding-left: 14px;
}

.section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 4px;
  border-radius: 2px;
  background-color: var(--color-accent);
}

/* 更多链接 */
.section-more-link {
  display: inline-block;
  margin-top: 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-accent);
  border-bottom: 1px solid transparent;
}

.section-more-link:hover {
  border-bottom-color: var(--color-accent);
}

/* ==========================================================================
   components — 卡片 / 列表 / 标签 / 按钮 / 榜单 / FAQ 等
   ========================================================================== */

/* ---------- 按钮 ---------- */

.btn-primary,
.btn-secondary {
  display: inline-block;
  padding: 12px 28px;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 600;
  text-align: center;
  min-height: 44px;
  line-height: 1.4;
  transition: background-color var(--transition-base),
    transform var(--transition-base);
}

.btn-primary {
  background-color: var(--color-accent);
  color: #ffffff;
}

.btn-primary:hover {
  background-color: #d63851;
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(2px);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.28);
  color: #ffffff;
  transform: translateY(-1px);
}

/* ---------- 题材标签 ---------- */

.genre-tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.genre-tag {
  display: inline-block;
  padding: 10px 20px;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  color: var(--color-secondary);
  min-height: 44px;
  line-height: 1.4;
  transition: all var(--transition-base);
}

.genre-tag:hover {
  background-color: var(--color-secondary);
  border-color: var(--color-secondary);
  color: #ffffff;
}

/* ---------- 更新列表（首页 / 更新页共用基础） ---------- */

.update-item {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base),
    transform var(--transition-base);
}

.update-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.update-cover {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background-color: #e8e8ef;
}

.update-info {
  padding: 12px 14px 14px;
}

.update-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.update-meta {
  font-size: 13px;
  color: var(--color-text-light);
  margin-bottom: 8px;
}

.update-link {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-accent);
}

/* ---------- 榜单条目 ---------- */

.ranking-item {
  display: flex;
  align-items: center;
  gap: 16px;
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base);
}

.ranking-item:hover {
  box-shadow: var(--shadow-md);
}

.rank-number {
  font-size: 24px;
  font-weight: 800;
  color: var(--color-accent);
  min-width: 32px;
  text-align: center;
  font-style: italic;
}

.rank-cover {
  width: 64px;
  height: 84px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
  background-color: #e8e8ef;
}

.rank-detail,
.rank-info {
  flex: 1;
  min-width: 0;
}

.rank-title,
.rank-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.rank-reason {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.5;
}

/* ---------- 剧情入口卡片 ---------- */

.entry-card {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base),
    transform var(--transition-base);
}

.entry-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.entry-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background-color: #e8e8ef;
}

.entry-card-content {
  padding: 20px;
}

.entry-card-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.entry-card-text {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.6;
  margin-bottom: 14px;
}

.entry-card-link {
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-accent);
}

/* ---------- 步骤卡片（阅读指南） ---------- */

.step-card {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--color-accent);
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
}

.step-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.step-desc {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.6;
}

.step-desc a {
  color: var(--color-accent);
  font-weight: 500;
}

/* ---------- 追更技巧列表 ---------- */

.tip-item {
  padding: 16px 0;
  border-bottom: 1px solid var(--color-border);
}

.tip-item:last-child {
  border-bottom: none;
}

.tip-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.tip-desc {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.6;
}

.tip-desc a {
  color: var(--color-accent);
  font-weight: 500;
}

/* ---------- FAQ 手风琴 ---------- */

.faq-item {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-question {
  padding: 18px 20px;
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-question::after {
  content: "+";
  font-size: 22px;
  font-weight: 400;
  color: var(--color-accent);
  flex-shrink: 0;
  transition: transform var(--transition-base);
}

.faq-item[open] .faq-question::after {
  transform: rotate(45deg);
}

.faq-answer {
  padding: 0 20px 18px;
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* ---------- 分类卡片 ---------- */

.category-card {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base),
    transform var(--transition-base);
}

.category-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.category-cover {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background-color: #e8e8ef;
}

.category-info {
  padding: 16px 18px;
}

.category-name {
  font-size: 17px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.category-desc {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.5;
}

/* ---------- 作品卡片（分类页） ---------- */

.work-item {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base),
    transform var(--transition-base);
}

.work-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.work-cover {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background-color: #e8e8ef;
}

.work-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-primary);
  padding: 12px 14px 2px;
}

.work-tags {
  font-size: 13px;
  color: var(--color-text-light);
  padding: 0 14px 14px;
}

/* ---------- 更新状态标签 ---------- */

.update-status {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: var(--color-accent);
  background-color: rgba(233, 69, 96, 0.1);
  padding: 3px 10px;
  border-radius: 999px;
  margin-top: 6px;
}

/* ---------- 归档条目 ---------- */

.archive-item {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.archive-date {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.archive-titles li {
  padding: 6px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 14px;
}

.archive-titles li:last-child {
  border-bottom: none;
}

.archive-titles a {
  color: var(--color-secondary);
}

.archive-titles a:hover {
  color: var(--color-accent);
}

.archive-more {
  display: inline-block;
  margin-top: 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-accent);
}

/* ---------- 相关卡片（更新页） ---------- */

.related-card {
  display: block;
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base),
    transform var(--transition-base);
}

.related-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.related-title {
  display: block;
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.related-desc {
  display: block;
  font-size: 13px;
  color: var(--color-text-light);
  line-height: 1.5;
}

/* ---------- 角色卡片（剧情页） ---------- */

.character-card {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base);
}

.character-card:hover {
  box-shadow: var(--shadow-md);
}

.character-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background-color: #e8e8ef;
}

.character-name {
  font-size: 17px;
  font-weight: 700;
  color: var(--color-primary);
  padding: 14px 16px 4px;
}

.character-desc {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.6;
  padding: 0 16px 16px;
}

/* ---------- 图文媒体（阅读指南） ---------- */

.guide-media {
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.guide-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background-color: #e8e8ef;
}

.guide-media figcaption {
  padding: 12px 16px;
  font-size: 13px;
  color: var(--color-text-light);
  background-color: var(--color-surface);
  border-top: 1px solid var(--color-border);
}

/* ---------- 剧情图（剧情页） ---------- */

.story-figure {
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
}

.story-hero-img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background-color: #e8e8ef;
}

.story-figure figcaption {
  padding: 12px 16px;
  font-size: 13px;
  color: var(--color-text-light);
  background-color: var(--color-surface);
  border-top: 1px solid var(--color-border);
}

/* ---------- 文本链接 ---------- */

.text-link {
  color: var(--color-accent);
  font-weight: 500;
  margin-right: 16px;
}

.text-link:hover {
  text-decoration: underline;
}

/* ---------- 侧栏 / 相关链接通用 ---------- */

.aside-text {
  font-size: 14px;
  color: var(--color-text-light);
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.aside-title,
.related-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 16px;
}

.link-list li,
.related-list li {
  padding: 8px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 14px;
}

.link-list li:last-child,
.related-list li:last-child {
  border-bottom: none;
}

.link-list a,
.related-list a {
  color: var(--color-secondary);
}

.link-list a:hover,
.related-list a:hover {
  color: var(--color-accent);
}

/* ==========================================================================
   pages — 首页
   ========================================================================== */

/* ---------- 首页 hero ---------- */

.hero-section {
  position: relative;
  background-color: var(--color-primary);
  min-height: 420px;
  display: flex;
  align-items: center;
}

.hero-figure {
  position: relative;
  width: 100%;
  min-height: 420px;
  display: flex;
  align-items: center;
}

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}

.hero-caption {
  position: relative;
  z-index: 1;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 60px 24px;
  color: #ffffff;
  width: 100%;
}

.hero-title {
  font-size: 36px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 12px;
  max-width: 640px;
  line-height: 1.25;
}

.hero-subtitle {
  font-size: 17px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 28px;
  max-width: 560px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* ---------- 首页题材导航 ---------- */

.genre-nav-section {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 48px 24px 8px;
}

/* ---------- 首页最近更新 ---------- */

.updates-section {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 40px 24px 8px;
}

.updates-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* ---------- 首页榜单预览 ---------- */

.ranking-preview-section {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 40px 24px 8px;
}

.ranking-preview-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ---------- 首页入口卡片 ---------- */

.entry-cards-section {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 40px 24px 48px;
}

.entry-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

/* ==========================================================================
   pages — 内页
   ========================================================================== */

/* ---------- 分类页 ---------- */

.category-grid {
  margin-bottom: 40px;
}

.category-grid-items {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.representative-works {
  margin-bottom: 40px;
}

.works-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.category-links {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
}

/* ---------- 阅读指南页 ---------- */

.guide-section {
  margin-bottom: 48px;
}

.steps-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.tips-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 28px;
  align-items: start;
}

.tips-list {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 8px 20px;
  box-shadow: var(--shadow-sm);
}

.faq-list {
  max-width: 860px;
}

/* ---------- 更新页 ---------- */

.update-group {
  margin-bottom: 48px;
}

.section-intro {
  font-size: 14px;
  color: var(--color-text-light);
  margin-bottom: 20px;
}

.update-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.update-archive {
  margin-bottom: 48px;
}

.archive-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.archive-link {
  margin-top: 24px;
}

.related-links {
  margin-bottom: 48px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.feedback-note {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--color-accent);
}

.feedback-note p {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* ---------- 榜单页 ---------- */

.ranking-section {
  margin-bottom: 48px;
}

.ranking-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ranking-list .ranking-item {
  padding: 16px 20px;
}

.ranking-list .rank-number {
  font-size: 28px;
  min-width: 40px;
}

.ranking-list .rank-cover {
  width: 72px;
  height: 96px;
}

.ranking-notes {
  margin-bottom: 48px;
}

.notes-content {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.notes-content p {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.7;
  margin-bottom: 12px;
}

.notes-content p:last-child {
  margin-bottom: 0;
}

.ranking-related {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

/* ---------- 剧情页 ---------- */

.story-overview,
.story-characters,
.story-background {
  margin-bottom: 48px;
}

.overview-content {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.overview-text {
  font-size: 15px;
  color: var(--color-text);
  line-height: 1.8;
  margin-bottom: 16px;
}

.overview-text:last-child {
  margin-bottom: 0;
}

.character-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.characters-note {
  font-size: 14px;
  color: var(--color-text-light);
}

.characters-note a {
  color: var(--color-accent);
  font-weight: 500;
}

.background-content {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.background-text {
  font-size: 15px;
  color: var(--color-text);
  line-height: 1.8;
  margin-bottom: 16px;
}

.background-text:last-child {
  margin-bottom: 0;
}

.story-links {
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

/* ---------- 404 页 ---------- */

.error-main {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  min-height: 60vh;
}

.error-panel {
  text-align: center;
  max-width: 520px;
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  padding: 48px 40px;
  box-shadow: var(--shadow-md);
}

.error-code {
  font-size: 72px;
  font-weight: 800;
  color: var(--color-accent);
  line-height: 1;
  margin-bottom: 16px;
}

.error-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.error-desc {
  font-size: 15px;
  color: var(--color-text-light);
  line-height: 1.6;
  margin-bottom: 28px;
}

.error-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.error-link {
  display: inline-block;
  padding: 12px 28px;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  min-height: 44px;
  line-height: 1.4;
}

.error-link:first-child {
  background-color: var(--color-accent);
  color: #ffffff;
}

.error-link:first-child:hover {
  background-color: #d63851;
  color: #ffffff;
}

.error-link:last-child {
  background-color: var(--color-bg);
  color: var(--color-secondary);
  border: 1px solid var(--color-border);
}

.error-link:last-child:hover {
  border-color: var(--color-secondary);
}

.error-tip {
  font-size: 13px;
  color: var(--color-text-light);
}

/* ==========================================================================
   responsive — 响应式
   ========================================================================== */

@media (max-width: 1024px) {
  .works-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .character-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .category-grid-items {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  /* 页头 */
  .header-inner {
    height: 60px;
    padding: 0 16px;
  }

  .brand-name {
    font-size: 19px;
  }

  .brand-slogan {
    font-size: 11px;
  }

  .nav-toggle {
    display: block;
    z-index: 110;
  }

  .site-nav {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background-color: var(--color-primary);
    box-shadow: var(--shadow-md);
  }

  .nav-list {
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 8px 16px 16px;
    gap: 2px;
  }

  .nav-list.is-open {
    display: flex;
  }

  .nav-link {
    padding: 14px 16px;
    font-size: 16px;
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  /* 面包屑 */
  .breadcrumb {
    padding: 14px 16px 0;
    font-size: 13px;
  }

  /* 主容器 */
  .inner-main {
    padding: 0 16px 40px;
  }

  /* 页标题 */
  .page-header {
    padding: 20px 0 4px;
    margin-bottom: 20px;
  }

  .page-title {
    font-size: 24px;
  }

  .page-description {
    font-size: 15px;
  }

  /* 页脚 */
  .footer-inner {
    padding: 32px 16px 28px;
  }

  .footer-nav {
    gap: 6px 18px;
  }

  .footer-link {
    font-size: 14px;
    min-height: 36px;
    display: inline-flex;
    align-items: center;
  }

  /* 首页 hero */
  .hero-section,
  .hero-figure {
    min-height: 360px;
  }

  .hero-caption {
    padding: 40px 16px;
  }

  .hero-title {
    font-size: 26px;
  }

  .hero-subtitle {
    font-size: 15px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
  }

  /* 首页区块 */
  .genre-nav-section,
  .updates-section,
  .ranking-preview-section,
  .entry-cards-section {
    padding-left: 16px;
    padding-right: 16px;
  }

  .genre-nav-section {
    padding-top: 36px;
  }

  .updates-section,
  .ranking-preview-section {
    padding-top: 32px;
  }

  .entry-cards-section {
    padding-top: 32px;
    padding-bottom: 40px;
  }

  .section-title {
    font-size: 20px;
  }

  .genre-tags-list {
    gap: 8px;
  }

  .genre-tag {
    padding: 9px 16px;
    font-size: 14px;
  }

  /* 首页更新 */
  .updates-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .update-info {
    padding: 10px 12px 12px;
  }

  .update-title {
    font-size: 14px;
  }

  .update-meta {
    font-size: 12px;
  }

  /* 首页榜单 */
  .ranking-item {
    padding: 12px;
    gap: 12px;
  }

  .rank-number {
    font-size: 20px;
    min-width: 24px;
  }

  .rank-cover {
    width: 52px;
    height: 70px;
  }

  .rank-title,
  .rank-name {
    font-size: 14px;
  }

  .rank-reason {
    font-size: 13px;
  }

  /* 首页入口卡片 */
  .entry-cards-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .entry-card-content {
    padding: 16px;
  }

  /* 分类页 */
  .category-grid-items {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .works-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .category-info {
    padding: 12px 14px;
  }

  .category-name {
    font-size: 16px;
  }

  .category-desc {
    font-size: 13px;
  }

  /* 阅读指南 */
  .steps-list {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .step-card {
    padding: 20px;
  }

  .tips-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .tips-list {
    padding: 4px 16px;
  }

  .faq-question {
    padding: 16px;
    font-size: 15px;
  }

  .faq-answer {
    padding: 0 16px 16px;
  }

  /* 更新页 */
  .update-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .archive-list {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .related-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .feedback-note {
    padding: 20px;
  }

  /* 榜单页 */
  .ranking-list .ranking-item {
    padding: 12px;
  }

  .ranking-list .rank-number {
    font-size: 22px;
    min-width: 28px;
  }

  .ranking-list .rank-cover {
    width: 56px;
    height: 76px;
  }

  .notes-content {
    padding: 20px;
  }

  .ranking-related {
    padding: 20px;
  }

  /* 剧情页 */
  .overview-content,
  .background-content {
    padding: 20px;
  }

  .overview-text,
  .background-text {
    font-size: 14px;
  }

  .character-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .character-name {
    font-size: 15px;
    padding: 12px 14px 2px;
  }

  .character-desc {
    font-size: 13px;
    padding: 0 14px 14px;
  }

  .story-links {
    padding: 20px;
  }

  /* 404 */
  .error-main {
    padding: 48px 16px;
  }

  .error-panel {
    padding: 36px 24px;
  }

  .error-code {
    font-size: 56px;
  }

  .error-title {
    font-size: 20px;
  }

  .error-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .error-link {
    width: 100%;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .updates-list {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .update-cover {
    aspect-ratio: 3 / 4;
  }

  .update-title {
    font-size: 13px;
  }

  .update-meta {
    font-size: 12px;
  }

  .works-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .work-name {
    font-size: 14px;
    padding: 10px 10px 2px;
  }

  .work-tags {
    font-size: 12px;
    padding: 0 10px 10px;
  }

  .character-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .character-img {
    aspect-ratio: 16 / 9;
  }
}
