/* ============================================================
   base — 全站基础样式
   ============================================================ */
:root {
  --color-dark: #2b2b2b;
  --color-cream: #f5f0e8;
  --color-red: #8c2f2f;
  --color-white: #ffffff;
  --color-gray: #6b6b6b;
  --color-light-gray: #e8e4dc;
  --color-bg: #f5f0e8;
  --font-serif: "Noto Serif SC", "Songti SC", "SimSun", serif;
  --font-sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --container-width: 1200px;
  --transition: 0.25s ease;
  --radius: 8px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--color-bg);
  color: var(--color-dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--color-dark);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--color-red);
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-serif);
  font-weight: 700;
  line-height: 1.3;
}

/* ============================================================
   layout — 全站布局骨架
   ============================================================ */
.site-header {
  background: var(--color-dark);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.header-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand-link {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0;
}

.brand-tag {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 2px;
}

.brand-link:hover .brand-name {
  color: var(--color-white);
}

.site-nav .nav-list {
  display: flex;
  gap: 4px;
}

.site-nav .nav-list a {
  display: block;
  padding: 8px 16px;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.85);
  border-radius: 4px;
  transition: background var(--transition), color var(--transition);
}

.site-nav .nav-list a:hover {
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.1);
}

.site-nav .nav-list a.is-current {
  color: var(--color-white);
  background: var(--color-red);
  font-weight: 600;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}

.toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-white);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.site-main {
  min-height: 60vh;
}

.inner-main {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 32px 24px 64px;
}

/* 面包屑 */
.breadcrumb {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 16px 24px 0;
  font-size: 14px;
  color: var(--color-gray);
}

.breadcrumb a {
  color: var(--color-gray);
}

.breadcrumb a:hover {
  color: var(--color-red);
}

.breadcrumb-sep {
  margin: 0 8px;
  color: var(--color-gray);
}

.breadcrumb-current {
  color: var(--color-dark);
}

/* 页面标题区 */
.page-header {
  background: var(--color-white);
  border-bottom: 1px solid var(--color-light-gray);
  padding: 32px 0;
}

.page-header-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.page-title {
  font-size: 32px;
  color: var(--color-dark);
  margin-bottom: 8px;
}

.page-lead,
.page-description {
  font-size: 16px;
  color: var(--color-gray);
  max-width: 720px;
}

/* 页脚 */
.site-footer {
  background: var(--color-red);
  color: rgba(255, 255, 255, 0.9);
  margin-top: 64px;
}

.footer-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 48px 24px 24px;
}

.footer-brand {
  margin-bottom: 32px;
}

.footer-site-name {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 8px;
}

.footer-desc {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  max-width: 480px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
  margin-bottom: 32px;
}

.footer-link-group h3 {
  font-size: 15px;
  color: var(--color-white);
  margin-bottom: 12px;
}

.footer-link-group ul li {
  margin-bottom: 8px;
}

.footer-link-group a {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
}

.footer-link-group a:hover {
  color: var(--color-white);
  text-decoration: underline;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 16px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}

.footer-bottom p {
  margin-bottom: 4px;
}

/* ============================================================
   components — 通用组件
   ============================================================ */
.section-intro {
  font-size: 15px;
  color: var(--color-gray);
  margin-bottom: 24px;
  max-width: 720px;
}

/* 按钮 */
.btn-primary,
.btn-secondary {
  display: inline-block;
  padding: 12px 28px;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius);
  transition: background var(--transition), transform var(--transition);
}

.btn-primary {
  background: var(--color-red);
  color: var(--color-white);
}

.btn-primary:hover {
  background: #a03a3a;
  color: var(--color-white);
  transform: translateY(-2px);
}

.btn-secondary {
  background: transparent;
  color: var(--color-dark);
  border: 1px solid var(--color-dark);
}

.btn-secondary:hover {
  background: var(--color-dark);
  color: var(--color-white);
  transform: translateY(-2px);
}

/* 封面卡通用 */
.work-cover,
.hero-figure,
.guide-figure,
.story-figure,
.relationship-figure {
  overflow: hidden;
  border-radius: var(--radius);
}

.work-cover img,
.hero-figure img,
.guide-figure img,
.story-figure img,
.relationship-figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 卡片 hover 上浮 */
.work-card,
.topic-card,
.guide-card {
  transition: transform var(--transition), box-shadow var(--transition);
}

.work-card:hover,
.topic-card:hover,
.guide-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

/* ============================================================
   pages — 首页
   ============================================================ */
.home-main .hero-section {
  background: var(--color-dark);
  color: var(--color-white);
  padding: 64px 24px;
}

.hero-section {
  max-width: var(--container-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.hero-content h1 {
  font-size: 36px;
  margin-bottom: 16px;
  color: var(--color-white);
}

.hero-lead {
  font-size: 17px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 24px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-figure {
  width: 100%;
  aspect-ratio: 4 / 3;
}

.hero-figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 分类导航区 */
.category-nav-section,
.recent-section,
.ranking-section,
.guide-entry-section,
.featured-topics-section {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 48px 24px;
}

.category-nav-section h2,
.recent-section h2,
.ranking-section h2,
.guide-entry-section h2,
.featured-topics-section h2 {
  font-size: 26px;
  margin-bottom: 8px;
}

.category-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.category-tag {
  display: inline-block;
  padding: 10px 24px;
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}

.category-tag:hover {
  background: var(--color-red);
  border-color: var(--color-red);
  color: var(--color-white);
}

/* 最近更新 */
.recent-section {
  background: var(--color-white);
}

.update-group {
  margin-bottom: 24px;
}

.update-group h3 {
  font-size: 18px;
  color: var(--color-red);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--color-light-gray);
}

.update-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.update-item {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 12px;
  background: var(--color-bg);
  border-radius: var(--radius);
  transition: background var(--transition);
}

.update-item:hover {
  background: var(--color-light-gray);
}

.update-item img {
  width: 80px;
  height: 100px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}

.update-info h4 {
  font-size: 16px;
  margin-bottom: 6px;
}

.update-meta {
  font-size: 13px;
  color: var(--color-gray);
}

/* 人气榜单 */
.ranking-list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.ranking-item {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: box-shadow var(--transition), transform var(--transition);
}

.ranking-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.ranking-number {
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 700;
  color: var(--color-red);
  line-height: 1;
}

.ranking-content h3 {
  font-size: 16px;
  margin-bottom: 8px;
}

.ranking-content p {
  font-size: 14px;
  color: var(--color-gray);
  line-height: 1.5;
}

/* 阅读指南入口 */
.guide-entry-section {
  background: var(--color-white);
}

.guide-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.guide-card {
  background: var(--color-bg);
  border-radius: var(--radius);
  padding: 28px;
  border: 1px solid var(--color-light-gray);
}

.guide-card h3 {
  font-size: 20px;
  margin-bottom: 12px;
}

.guide-card p {
  font-size: 15px;
  color: var(--color-gray);
  margin-bottom: 16px;
  line-height: 1.6;
}

.guide-link {
  display: inline-block;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-red);
}

.guide-link:hover {
  text-decoration: underline;
}

/* 专题卡 */
.topic-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.topic-card {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.topic-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.topic-card h3 {
  font-size: 20px;
  padding: 20px 20px 8px;
}

.topic-card p {
  font-size: 15px;
  color: var(--color-gray);
  padding: 0 20px 16px;
  line-height: 1.6;
  flex-grow: 1;
}

.topic-link {
  display: inline-block;
  padding: 0 20px 20px;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-red);
}

.topic-link:hover {
  text-decoration: underline;
}

/* ============================================================
   pages — 题材分类页
   ============================================================ */
.page-layout {
  display: grid;
  gap: 32px;
  margin-top: 32px;
}

.sidebar-left {
  grid-template-columns: 260px 1fr;
}

.sidebar-left .category-aside {
  order: 1;
}

.sidebar-left .category-main {
  order: 2;
}

.category-aside {
  background: var(--color-white);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--color-light-gray);
  align-self: start;
  position: sticky;
  top: 88px;
}

.aside-inner h2 {
  font-size: 20px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--color-light-gray);
}

.tag-list li {
  margin-bottom: 4px;
}

.tag-list a {
  display: block;
  padding: 10px 12px;
  font-size: 15px;
  border-radius: 4px;
  transition: background var(--transition), color var(--transition);
}

.tag-list a:hover {
  background: var(--color-bg);
  color: var(--color-red);
}

.aside-note {
  font-size: 13px;
  color: var(--color-gray);
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--color-light-gray);
  line-height: 1.5;
}

.category-block {
  margin-bottom: 40px;
}

.category-block h2 {
  font-size: 24px;
  margin-bottom: 8px;
}

.block-intro {
  font-size: 15px;
  color: var(--color-gray);
  margin-bottom: 20px;
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.work-card {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.work-cover {
  width: 100%;
  aspect-ratio: 3 / 4;
}

.work-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.work-card h3 {
  font-size: 18px;
  padding: 16px 16px 4px;
}

.work-tag {
  font-size: 13px;
  color: var(--color-red);
  padding: 0 16px;
  margin-bottom: 8px;
}

.work-desc {
  font-size: 14px;
  color: var(--color-gray);
  padding: 0 16px 16px;
  line-height: 1.5;
  flex-grow: 1;
}

.category-guide {
  background: var(--color-white);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--color-light-gray);
  margin-top: 16px;
}

.category-guide h2 {
  font-size: 20px;
  margin-bottom: 12px;
}

.category-guide p {
  font-size: 15px;
  color: var(--color-gray);
  line-height: 1.7;
  margin-bottom: 8px;
}

/* 相关链接 */
.related-links {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--color-light-gray);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 14px;
}

.related-links-label {
  font-weight: 600;
  color: var(--color-dark);
}

.related-links-item {
  color: var(--color-gray);
}

.related-links-item:hover {
  color: var(--color-red);
}

/* 分类页顶部面包屑（双面包屑场景） */
.page-fenlei .breadcrumb-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 16px 24px 0;
  font-size: 14px;
  color: var(--color-gray);
}

/* ============================================================
   pages — 阅读指南页
   ============================================================ */
.layout-single {
  max-width: 860px;
  margin: 0 auto;
}

.guide-section {
  margin-bottom: 40px;
}

.guide-section h2 {
  font-size: 24px;
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--color-light-gray);
}

.guide-section > p {
  font-size: 15px;
  color: var(--color-gray);
  margin-bottom: 16px;
  line-height: 1.7;
}

.prep-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 16px;
}

.prep-list li {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 20px;
}

.prep-list h3 {
  font-size: 16px;
  margin-bottom: 8px;
}

.prep-list p {
  font-size: 14px;
  color: var(--color-gray);
  line-height: 1.6;
}

.step-list {
  counter-reset: step;
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

.step-item {
  display: flex;
  gap: 16px;
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 20px;
  align-items: flex-start;
}

.step-num {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--color-red);
  flex-shrink: 0;
  min-width: 40px;
  text-align: center;
  background: var(--color-bg);
  border-radius: 4px;
  padding: 4px 8px;
}

.step-content h3 {
  font-size: 16px;
  margin-bottom: 6px;
}

.step-content p {
  font-size: 14px;
  color: var(--color-gray);
  line-height: 1.6;
}

.checklist {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 20px;
}

.checklist li {
  padding: 8px 0;
  font-size: 15px;
  position: relative;
  padding-left: 28px;
}

.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  width: 16px;
  height: 16px;
  border: 2px solid var(--color-red);
  border-radius: 3px;
}

.guide-figure {
  margin: 32px 0;
  aspect-ratio: 16 / 9;
}

.guide-figure figcaption {
  font-size: 13px;
  color: var(--color-gray);
  text-align: center;
  padding: 8px 0;
}

/* ============================================================
   pages — 人物解析页
   ============================================================ */
.character-list-section,
.relationship-section,
.related-topics {
  margin-bottom: 48px;
}

.section-title {
  font-size: 26px;
  margin-bottom: 8px;
}

.character-card-list {
  display: grid;
  gap: 20px;
  margin-top: 24px;
}

.character-card {
  display: flex;
  gap: 20px;
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 20px;
  transition: box-shadow var(--transition), transform var(--transition);
}

.character-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.character-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}

.character-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.character-info {
  flex: 1;
}

.character-name {
  font-size: 20px;
  margin-bottom: 4px;
}

.character-role {
  font-size: 14px;
  color: var(--color-red);
  margin-bottom: 8px;
  font-weight: 500;
}

.character-desc {
  font-size: 15px;
  color: var(--color-gray);
  line-height: 1.6;
}

.relationship-content {
  display: grid;
  gap: 24px;
  margin-top: 24px;
}

.relationship-block {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 24px;
}

.relationship-title {
  font-size: 18px;
  margin-bottom: 10px;
}

.relationship-block p {
  font-size: 15px;
  color: var(--color-gray);
  line-height: 1.7;
}

.relationship-figure {
  aspect-ratio: 16 / 9;
  margin-top: 8px;
}

.figure-caption {
  font-size: 13px;
  color: var(--color-gray);
  text-align: center;
  padding: 8px 0;
}

/* 相关专题 */
.related-topics .topic-cards {
  grid-template-columns: repeat(3, 1fr);
}

.topic-card-link {
  display: block;
  height: 100%;
}

.topic-card-link .topic-card {
  height: 100%;
}

.topic-title {
  font-size: 17px;
  padding: 16px 16px 4px;
}

.topic-excerpt {
  font-size: 14px;
  color: var(--color-gray);
  padding: 0 16px 16px;
  line-height: 1.5;
  flex-grow: 1;
}

/* ============================================================
   pages — 剧情解析页
   ============================================================ */
.module-block {
  margin-bottom: 48px;
}

.module-block > h2 {
  font-size: 26px;
  margin-bottom: 8px;
}

.module-block > p {
  font-size: 15px;
  color: var(--color-gray);
  margin-bottom: 20px;
  line-height: 1.7;
  max-width: 720px;
}

.timeline-list {
  display: grid;
  gap: 16px;
  margin-top: 24px;
  position: relative;
}

.timeline-list::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--color-light-gray);
}

.timeline-item {
  display: flex;
  gap: 20px;
  position: relative;
  padding-left: 48px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 8px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-red);
  border: 2px solid var(--color-white);
  box-shadow: 0 0 0 2px var(--color-red);
}

.timeline-era {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-red);
  flex-shrink: 0;
  min-width: 80px;
}

.timeline-item p {
  font-size: 15px;
  color: var(--color-gray);
  line-height: 1.6;
}

.event-card {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 16px;
  transition: box-shadow var(--transition);
}

.event-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.event-card h3 {
  font-size: 18px;
  margin-bottom: 8px;
  color: var(--color-red);
}

.event-card p {
  font-size: 15px;
  color: var(--color-gray);
  line-height: 1.7;
}

.story-figure {
  aspect-ratio: 16 / 9;
  margin: 24px 0;
}

.story-figure figcaption {
  font-size: 13px;
  color: var(--color-gray);
  text-align: center;
  padding: 8px 0;
}

.theme-analysis ul {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 16px;
}

.theme-analysis ul li {
  padding: 8px 0;
  font-size: 15px;
  color: var(--color-gray);
  line-height: 1.6;
  border-bottom: 1px solid var(--color-light-gray);
}

.theme-analysis ul li:last-child {
  border-bottom: none;
}

.theme-analysis ul strong {
  color: var(--color-dark);
}

.theme-analysis > p {
  margin-bottom: 12px;
}

.theme-analysis a {
  color: var(--color-red);
  font-weight: 500;
}

.theme-analysis a:hover {
  text-decoration: underline;
}

/* 相关阅读 */
.related-links.module-block {
  background: var(--color-white);
  border: 1px solid var(--color-light-gray);
  border-radius: var(--radius);
  padding: 24px;
}

.related-links.module-block h2 {
  font-size: 20px;
  margin-bottom: 16px;
}

.related-links.module-block ul li {
  padding: 8px 0;
  border-bottom: 1px solid var(--color-light-gray);
}

.related-links.module-block ul li:last-child {
  border-bottom: none;
}

.related-links.module-block a {
  font-size: 15px;
  color: var(--color-gray);
}

.related-links.module-block a:hover {
  color: var(--color-red);
}

/* ============================================================
   pages — 404 页
   ============================================================ */
.error-main {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  min-height: 60vh;
}

.error-section {
  text-align: center;
  max-width: 560px;
}

.error-section h1 {
  font-size: 72px;
  color: var(--color-red);
  margin-bottom: 16px;
}

.error-lead {
  font-size: 20px;
  margin-bottom: 12px;
}

.error-section p {
  font-size: 15px;
  color: var(--color-gray);
  margin-bottom: 24px;
}

.error-home-link {
  display: inline-block;
  padding: 12px 32px;
  background: var(--color-red);
  color: var(--color-white);
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  transition: background var(--transition);
}

.error-home-link:hover {
  background: #a03a3a;
  color: var(--color-white);
}

/* ============================================================
   responsive — 响应式
   ============================================================ */
@media (max-width: 1024px) {
  .hero-section {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .hero-content h1 {
    font-size: 30px;
  }

  .update-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .ranking-list {
    grid-template-columns: repeat(3, 1fr);
  }

  .sidebar-left {
    grid-template-columns: 1fr;
  }

  .sidebar-left .category-aside {
    order: 0;
    position: static;
  }

  .sidebar-left .category-main {
    order: 1;
  }

  .tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }

  .tag-list li {
    margin-bottom: 0;
  }

  .tag-list a {
    padding: 8px 16px;
    background: var(--color-bg);
    border-radius: 999px;
    font-size: 14px;
  }
}

@media (max-width: 768px) {
  .header-inner {
    height: 60px;
    padding: 0 16px;
  }

  .brand-name {
    font-size: 17px;
  }

  .brand-tag {
    font-size: 11px;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--color-dark);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .site-nav .nav-list {
    flex-direction: column;
    padding: 8px 16px;
    gap: 0;
    display: none;
  }

  .site-nav .nav-list.is-open {
    display: flex;
  }

  .site-nav .nav-list a {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 0;
  }

  .site-nav .nav-list a:last-child {
    border-bottom: none;
  }

  .inner-main {
    padding: 24px 16px 48px;
  }

  .page-title {
    font-size: 26px;
  }

  .hero-section {
    padding: 40px 16px;
  }

  .hero-content h1 {
    font-size: 26px;
  }

  .hero-lead {
    font-size: 15px;
  }

  .category-nav-section,
  .recent-section,
  .ranking-section,
  .guide-entry-section,
  .featured-topics-section {
    padding: 36px 16px;
  }

  .update-list {
    grid-template-columns: 1fr;
  }

  .ranking-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .guide-cards,
  .topic-cards {
    grid-template-columns: 1fr;
  }

  .work-grid {
    grid-template-columns: 1fr;
  }

  .prep-list {
    grid-template-columns: 1fr;
  }

  .character-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .character-avatar {
    width: 80px;
    height: 80px;
  }

  .related-topics .topic-cards {
    grid-template-columns: 1fr;
  }

  .timeline-item {
    padding-left: 40px;
  }

  .timeline-era {
    font-size: 16px;
    min-width: 60px;
  }

  .footer-inner {
    padding: 32px 16px 16px;
  }

  .footer-links {
    gap: 24px;
    flex-direction: column;
  }

  .error-main {
    padding: 48px 16px;
  }

  .error-section h1 {
    font-size: 56px;
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-primary,
  .btn-secondary {
    text-align: center;
  }

  .ranking-list {
    grid-template-columns: 1fr;
  }

  .update-item {
    padding: 10px;
  }

  .update-item img {
    width: 64px;
    height: 84px;
  }

  .step-item {
    flex-direction: column;
    gap: 8px;
  }

  .step-num {
    min-width: 32px;
    font-size: 20px;
    padding: 2px 6px;
  }

  .timeline-list::before {
    left: 12px;
  }

  .timeline-item::before {
    left: 6px;
    width: 12px;
    height: 12px;
  }

  .timeline-item {
    padding-left: 36px;
    gap: 12px;
  }

  .timeline-era {
    min-width: 48px;
    font-size: 15px;
  }

  .event-card {
    padding: 16px;
  }

  .theme-analysis ul {
    padding: 16px;
  }

  .character-card {
    padding: 16px;
  }
}

/* ============================================================
   辅助 — 滚动出现动画（增强，不影响初始可见性）
   ============================================================ */
@media (prefers-reduced-motion: no-preference) {
  .hero-section,
  .category-nav-section,
  .recent-section,
  .ranking-section,
  .guide-entry-section,
  .featured-topics-section,
  .character-card,
  .relationship-block,
  .event-card,
  .guide-section {
    animation: fadeInUp 0.6s ease both;
  }

  .category-nav-section {
    animation-delay: 0.1s;
  }

  .recent-section {
    animation-delay: 0.2s;
  }

  .ranking-section {
    animation-delay: 0.3s;
  }

  .guide-entry-section {
    animation-delay: 0.4s;
  }

  .featured-topics-section {
    animation-delay: 0.5s;
  }

  @keyframes fadeInUp {
    from {
      opacity: 1;
      transform: translateY(16px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
}
