/* ==========================================================================
   亲亲漫画 整站样式表
   版本: 1.0
   说明: 全站统一视觉外壳 + 各栏目独立业务模块
   ========================================================================== */

/* --------------------------------------------------------------------------
   Base — 基础变量、重置、全局字体与色彩
   -------------------------------------------------------------------------- */
:root {
  --page-bg: #f1f2f4;
  --card-bg: #ffffff;
  --text-main: #1a2b3c;
  --text-secondary: #4a5a6a;
  --text-muted: #6b7a8a;
  --link-blue: #1a5c9e;
  --link-hover: #0f3c73;
  --accent-amber: #d98e32;
  --border-light: #e2e5e9;
  --border-mid: #d0d5db;
  --header-height: 52px;
  --sidebar-width: 210px;
  --content-max: 1080px;
  --text-max: 720px;
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;
  --font-stack: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-stack);
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-main);
  background-color: var(--page-bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--link-blue);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--link-hover);
}

ul,
ol {
  list-style-position: inside;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.4;
  color: var(--text-main);
}

button {
  font-family: inherit;
  cursor: pointer;
}

/* 无障碍跳转链接 */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 2000;
  padding: 8px 16px;
  background: var(--text-main);
  color: #fff;
  font-size: 14px;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 0;
  color: #fff;
}

.sr-only {
  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-header {
  position: sticky;
  top: 0;
  z-index: 900;
  height: var(--header-height);
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-light);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 100%;
  padding: 0 20px;
  max-width: 1440px;
  margin: 0 auto;
}

.brand-area {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  font-size: 17px;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: 0.02em;
}

.brand-link:hover {
  color: var(--link-hover);
}

.brand-name {
  white-space: nowrap;
}

.brand-slogan {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-actions {
  display: flex;
  align-items: center;
}

/* 移动端导航开关按钮 */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border-mid);
  background: var(--card-bg);
  border-radius: var(--radius-md);
  align-items: center;
  justify-content: center;
}

.nav-toggle:hover {
  background: var(--page-bg);
}

.nav-toggle-icon {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text-main);
}

.nav-toggle-icon::before,
.nav-toggle-icon::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--text-main);
}

.nav-toggle-icon::before {
  top: -6px;
}

.nav-toggle-icon::after {
  top: 6px;
}

/* 移动端全站导航（默认收起） */
.site-nav {
  display: none;
}

.nav-list {
  list-style: none;
}

.nav-item {
  margin: 0;
}

/* 桌面端布局外壳 */
body {
  min-height: 100vh;
}

/* 首页：body > header, nav.site-nav, div.layout-shell.sidebar-left, footer */
.layout-shell.sidebar-left,
.page-layout.sidebar-left {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  min-height: calc(100vh - var(--header-height) - 320px);
}

/* 左侧窄边栏 */
.sidebar-nav {
  background: var(--card-bg);
  border-right: 1px solid var(--border-light);
  padding: 24px 0;
  min-height: 100%;
}

.sidebar-nav-list,
.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-nav-item,
.sidebar-item {
  margin: 0;
}

.sidebar-nav-item a,
.sidebar-item a,
.sidebar-link {
  display: block;
  padding: 10px 20px 10px 24px;
  font-size: 14px;
  color: var(--text-secondary);
  border-left: 3px solid transparent;
  line-height: 1.5;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.sidebar-nav-item a:hover,
.sidebar-item a:hover,
.sidebar-link:hover {
  background-color: #f6f7f9;
  color: var(--link-hover);
}

.sidebar-nav-item.is-current a,
.sidebar-item.is-current a,
.sidebar-link.is-current {
  background-color: #f6f7f9;
  color: var(--link-hover);
  border-left-color: var(--link-blue);
  font-weight: 600;
}

/* walkthrough 页特殊侧栏结构 */
.sidebar-inner {
  padding: 0;
}

.sidebar-label {
  font-size: 12px;
  color: var(--text-muted);
  padding: 8px 20px 8px 24px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.sidebar-note {
  margin-top: 32px;
  padding: 16px 20px 16px 24px;
  border-top: 1px solid var(--border-light);
}

.sidebar-note-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.sidebar-note-text {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 8px;
}

.sidebar-note-link {
  font-size: 13px;
}

/* 主内容区 */
.site-main {
  min-width: 0;
  padding: 32px 40px 56px;
}

.home-main {
  background: var(--card-bg);
}

.inner-main {
  background: var(--card-bg);
}

/* 内页顶部面包屑 */
.breadcrumb {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.breadcrumb a {
  color: var(--text-muted);
}

.breadcrumb a:hover {
  color: var(--link-hover);
}

.breadcrumb-sep {
  color: var(--border-mid);
  margin: 0 2px;
}

.breadcrumb-current {
  color: var(--text-secondary);
}

/* 内页标题区 */
.page-header {
  margin-bottom: 32px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-light);
}

.page-title {
  font-size: 26px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text-main);
  margin-bottom: 10px;
}

.page-description {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-secondary);
  max-width: var(--text-max);
}

.page-intro {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-secondary);
  max-width: var(--text-max);
  margin-bottom: 32px;
}

/* --------------------------------------------------------------------------
   Components — 通用组件：按钮、标题、表格、FAQ、链接区
   -------------------------------------------------------------------------- */

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  font-size: 15px;
  line-height: 1.5;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease,
    color 0.2s ease;
  min-height: 44px;
}

.btn-primary {
  background: var(--link-blue);
  color: #fff;
  border-color: var(--link-blue);
}

.btn-primary:hover {
  background: var(--link-hover);
  border-color: var(--link-hover);
  color: #fff;
}

.btn-secondary {
  background: transparent;
  color: var(--link-blue);
  border-color: var(--link-blue);
}

.btn-secondary:hover {
  background: #f0f5fa;
  color: var(--link-hover);
  border-color: var(--link-hover);
}

.btn-outline {
  background: transparent;
  color: var(--link-blue);
  border-color: var(--border-mid);
}

.btn-outline:hover {
  background: #f0f5fa;
  border-color: var(--link-blue);
  color: var(--link-hover);
}

/* 区块标题 */
.section-title {
  font-size: 19px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 12px;
  line-height: 1.5;
}

.section-desc,
.section-intro {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: var(--text-max);
  margin-bottom: 20px;
}

.section-note {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}

/* 表格通用 */
.table-wrap {
  overflow-x: auto;
  margin-bottom: 24px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.7;
  background: var(--card-bg);
}

.data-table th,
.data-table td {
  padding: 12px 16px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border-light);
}

.data-table thead th {
  background: #f6f7f9;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.data-table tbody tr:hover {
  background: #fafbfc;
}

/* 图文说明 */
.figure-caption {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-top: 8px;
  text-align: center;
}

/* FAQ 折叠 */
.faq-item {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  background: var(--card-bg);
  margin-bottom: 12px;
}

.faq-item summary {
  padding: 14px 18px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 20px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item[open] summary {
  border-bottom: 1px solid var(--border-light);
}

.faq-item p {
  padding: 14px 18px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
}

/* 相关链接条 */
.related-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  padding: 16px 0;
  margin-top: 32px;
  border-top: 1px solid var(--border-light);
  font-size: 14px;
}

.related-links-label {
  color: var(--text-muted);
  font-size: 13px;
}

.related-links-item {
  color: var(--link-blue);
}

.related-links-item:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

/* 文字链接 */
.text-link {
  font-size: 14px;
  color: var(--link-blue);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.text-link:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

.text-link::after {
  content: "→";
  font-size: 14px;
}

/* 普通有序/无序列表 */
.ordered-list {
  padding-left: 20px;
  list-style: decimal;
}

.ordered-list li {
  margin-bottom: 8px;
  line-height: 1.8;
  color: var(--text-secondary);
  padding-left: 4px;
}

/* 正文段落块 */
.text-block p {
  margin-bottom: 16px;
  line-height: 1.9;
  color: var(--text-secondary);
  max-width: var(--text-max);
}

.text-block p:last-child {
  margin-bottom: 0;
}

/* 站内正文链接 */
.text-block a {
  color: var(--link-blue);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.text-block a:hover {
  color: var(--link-hover);
}

/* --------------------------------------------------------------------------
   Pages — 首页
   -------------------------------------------------------------------------- */

/* hero 区 */
.hero-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 40px;
  align-items: center;
  padding: 40px 0 32px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 40px;
}

.hero-copy {
  min-width: 0;
}

.hero-title {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text-main);
  margin-bottom: 16px;
}

.hero-lead {
  font-size: 16px;
  line-height: 1.9;
  color: var(--text-secondary);
  margin-bottom: 12px;
  max-width: 560px;
}

.hero-note {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-figure {
  margin: 0;
}

.hero-image {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
}

/* 题材地图分类入口 */
.genre-map-section {
  padding: 0 0 40px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 40px;
}

.genre-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.genre-card {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.genre-card:hover {
  background: #e8eaee;
  border-color: var(--border-mid);
}

.genre-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
}

.genre-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 10px;
  flex-grow: 1;
}

.genre-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.genre-link {
  font-size: 13px;
  color: var(--link-blue);
  align-self: flex-start;
}

.genre-link:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

/* 棋盘式图文交替 */
.chessboard-section {
  padding: 0 0 40px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 40px;
}

.chess-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: center;
  margin-bottom: 48px;
}

.chess-row:last-child {
  margin-bottom: 0;
}

.chess-row-reverse .chess-copy {
  order: 1;
}

.chess-row-reverse .chess-figure {
  order: 2;
}

.chess-figure {
  margin: 0;
}

.chess-image {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
}

.chess-copy {
  min-width: 0;
}

.chess-title {
  font-size: 18px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 12px;
}

.chess-copy p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.9;
  margin-bottom: 12px;
}

.chess-copy .text-link {
  margin-top: 4px;
}

/* 整宽引文行 */
.chess-row-full {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.chess-figure-wide {
  margin: 0;
}

.chess-image-wide {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
}

.chess-copy-full {
  max-width: var(--text-max);
}

.chess-copy-full .chess-title {
  margin-bottom: 8px;
}

.chess-copy-full p {
  margin-bottom: 12px;
}

/* 特辑与路径入口 */
.preview-section {
  padding: 0 0 40px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 40px;
}

.preview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.preview-card {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 24px;
}

.preview-title {
  font-size: 17px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 10px;
}

.preview-card > p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 14px;
}

.preview-list {
  list-style: none;
  margin-bottom: 18px;
}

.preview-list li {
  position: relative;
  padding-left: 16px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 6px;
}

.preview-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 6px;
  height: 6px;
  background: var(--link-blue);
  border-radius: 50%;
}

.preview-steps {
  list-style: none;
  margin-bottom: 18px;
}

.preview-steps li {
  position: relative;
  padding-left: 24px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 6px;
}

.preview-steps li::before {
  content: attr(data-step);
  position: absolute;
  left: 0;
  top: 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-amber);
}

/* 问答摘要与边界 */
.info-block-section {
  padding: 0 0 16px;
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.info-title {
  font-size: 16px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 14px;
}

.faq-summary .faq-item {
  margin-bottom: 10px;
}

.faq-summary .faq-item summary {
  padding: 12px 16px;
  font-size: 14px;
}

.faq-summary .faq-item p {
  padding: 12px 16px;
  font-size: 13px;
}

.faq-summary .text-link {
  margin-top: 8px;
}

.boundary-list {
  list-style: none;
  margin-bottom: 14px;
}

.boundary-list li {
  position: relative;
  padding-left: 16px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 8px;
}

.boundary-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 6px;
  height: 6px;
  background: var(--accent-amber);
  border-radius: 50%;
}

/* --------------------------------------------------------------------------
   Pages — 题材总目 (genres.html)
   -------------------------------------------------------------------------- */

/* 顶部题材地图图示 */
.genres-map-figure {
  margin-bottom: 40px;
}

.map-figure {
  margin: 0;
}

.map-figure img {
  width: 100%;
  aspect-ratio: 21 / 8;
  object-fit: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
}

.map-figure figcaption {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}

/* 总览速览表 */
.genres-overview {
  margin-bottom: 48px;
}

/* 分题材档案 */
.genre-archives {
  margin-bottom: 48px;
}

.genre-entry {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin-bottom: 16px;
}

.genre-entry h3 {
  font-size: 17px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-light);
}

.genre-fields p {
  display: flex;
  gap: 12px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.genre-fields p:last-child {
  margin-bottom: 0;
}

.field-label {
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 72px;
}

/* 篇幅组合速查 */
.length-guide {
  margin-bottom: 48px;
}

.length-tip {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-top: 16px;
  padding: 14px 18px;
  background: #f8f4ec;
  border-left: 3px solid var(--accent-amber);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* 关联栏目出口 */
.related-links {
  border-top: 1px solid var(--border-light);
  padding-top: 24px;
}

.related-link-list {
  list-style: none;
  margin-top: 16px;
}

.related-link-item {
  margin-bottom: 10px;
  font-size: 15px;
}

.related-link-item a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.related-link-item a::before {
  content: "›";
  color: var(--link-blue);
  font-size: 18px;
}

/* --------------------------------------------------------------------------
   Pages — 特辑书架 (features.html)
   -------------------------------------------------------------------------- */

.features-guide {
  margin-bottom: 40px;
}

.features-guide p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.9;
  max-width: var(--text-max);
  margin-bottom: 12px;
}

.feature-group {
  margin-bottom: 48px;
  padding-top: 8px;
}

.group-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: var(--text-max);
  margin-bottom: 20px;
}

/* 三卡横排 */
.feature-cards-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  border-color: var(--border-mid);
  box-shadow: 0 2px 8px rgba(26, 43, 60, 0.06);
}

.feature-media {
  width: 100%;
}

.feature-media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.feature-content {
  padding: 16px 18px 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.feature-name {
  font-size: 16px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 10px;
}

.feature-field {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 4px;
}

.feature-field strong {
  color: var(--text-main);
  font-weight: 600;
  margin-right: 4px;
}

.feature-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-light);
}

/* 两卡并列 */
.feature-cards-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.feature-card-large {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.feature-card-large .feature-media img {
  height: 100%;
  aspect-ratio: auto;
}

.feature-card-large .feature-content {
  padding: 20px 22px;
}

/* 单列宽幅特辑 */
.feature-card-full {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.feature-card-full .feature-media img {
  width: 100%;
  aspect-ratio: 21 / 8;
  object-fit: cover;
}

.feature-card-full .feature-content {
  padding: 24px 28px;
}

.feature-card-full .feature-name {
  font-size: 18px;
}

/* 字段说明 */
.feature-fields {
  margin-bottom: 40px;
  padding: 24px;
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}

.feature-fields p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: var(--text-max);
  margin-bottom: 12px;
}

.field-list {
  list-style: none;
  margin-bottom: 16px;
}

.field-list li {
  position: relative;
  padding-left: 16px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 6px;
}

.field-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 6px;
  height: 6px;
  background: var(--link-blue);
  border-radius: 50%;
}

.field-list strong {
  color: var(--text-main);
  font-weight: 600;
  margin-right: 4px;
}

/* 交叉入口 */
.cross-links {
  margin-bottom: 20px;
}

.cross-link-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.cross-link {
  display: inline-flex;
  align-items: center;
  padding: 8px 18px;
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--link-blue);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.cross-link:hover {
  border-color: var(--link-blue);
  background: #f0f5fa;
  color: var(--link-hover);
}

/* --------------------------------------------------------------------------
   Pages — 阅读路径 (walkthrough.html)
   -------------------------------------------------------------------------- */

.path-overview {
  margin-bottom: 48px;
}

.overview-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.overview-step {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px 16px;
  text-align: center;
  position: relative;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--link-blue);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  border-radius: 50%;
  margin-bottom: 10px;
}

.step-info h3 {
  font-size: 15px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 6px;
}

.step-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* 步骤详情 */
.path-step {
  margin-bottom: 44px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--border-light);
}

.path-step:last-of-type {
  border-bottom: none;
}

.step-heading-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--accent-amber);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  border-radius: 50%;
  flex-shrink: 0;
}

.step-title {
  margin-bottom: 0;
}

.step-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.field-card {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px 20px;
}

.field-card h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-amber);
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}

.field-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
}

/* 步骤配图 */
.step-figure {
  margin: 20px 0 0;
}

.step-image {
  width: 100%;
  aspect-ratio: 21 / 7;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.step-figure figcaption {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}

.step-note {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-top: 16px;
  padding: 14px 18px;
  background: #f8f4ec;
  border-left: 3px solid var(--accent-amber);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* 常见障碍对照表 */
.obstacle-table-section {
  margin-bottom: 48px;
}

.obstacle-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.7;
  background: var(--card-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.obstacle-table th,
.obstacle-table td {
  padding: 12px 16px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border-light);
}

.obstacle-table thead th {
  background: #f6f7f9;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
}

.obstacle-table tbody tr:last-child td {
  border-bottom: none;
}

.obstacle-table tbody tr:hover {
  background: #fafbfc;
}

/* 下一步入口 */
.next-step-section {
  margin-bottom: 48px;
}

.next-step-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 20px;
}

.next-step-card {
  display: block;
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.next-step-card:hover {
  border-color: var(--link-blue);
  box-shadow: 0 2px 8px rgba(26, 92, 158, 0.08);
}

.next-step-title {
  font-size: 16px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 8px;
}

.next-step-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 12px;
}

.next-step-link {
  font-size: 14px;
  color: var(--link-blue);
  font-weight: 500;
}

.next-step-card:hover .next-step-link {
  color: var(--link-hover);
}

/* FAQ 摘要 */
.faq-teaser {
  margin-bottom: 24px;
}

.faq-teaser .faq-item {
  margin-bottom: 10px;
}

.faq-teaser .faq-item summary {
  padding: 12px 16px;
  font-size: 14px;
}

.faq-teaser .faq-item p {
  padding: 12px 16px;
  font-size: 13px;
}

.faq-more {
  font-size: 14px;
  margin-top: 12px;
}

/* --------------------------------------------------------------------------
   Pages — 术语词表 (glossary.html)
   -------------------------------------------------------------------------- */

.glossary-scope {
  margin-bottom: 36px;
}

.glossary-scope p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.9;
  max-width: var(--text-max);
  margin-bottom: 12px;
}

.glossary-terms {
  margin-bottom: 40px;
}

.term-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 20px;
}

.term-entry {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px 20px;
}

.term-name {
  font-size: 16px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-light);
}

.term-fields {
  margin: 0;
}

.term-field {
  display: flex;
  gap: 10px;
  margin-bottom: 8px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.term-field:last-child {
  margin-bottom: 0;
}

.term-field dt {
  flex-shrink: 0;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 60px;
}

.term-field dd {
  margin: 0;
  min-width: 0;
}

/* 尺幅对比图 */
.format-compare-figure {
  margin: 24px 0 40px;
}

.format-compare-image {
  width: 100%;
  aspect-ratio: 16 / 6;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.format-compare-figure figcaption {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}

/* 后半术语 */
.glossary-terms-extra {
  margin-bottom: 40px;
}

/* 量词与出版概念 */
.publication-terms {
  margin-bottom: 40px;
}

.publication-group-table {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.publication-group-row {
  background: var(--page-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px 20px;
}

.group-name {
  font-size: 15px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 6px;
}

.group-context {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 10px;
}

.group-term-list {
  list-style: none;
}

.group-term-list li {
  position: relative;
  padding-left: 14px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 4px;
}

.group-term-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 5px;
  height: 5px;
  background: var(--accent-amber);
  border-radius: 50%;
}

/* 相关出口 */
.glossary-related-links {
  margin-bottom: 24px;
}

.glossary-related-links ul {
  list-style: none;
  margin-top: 16px;
}

.glossary-related-links li {
  margin-bottom: 10px;
  font-size: 15px;
}

.glossary-related-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.glossary-related-links a::before {
  content: "›";
  color: var(--link-blue);
  font-size: 18px;
}

/* --------------------------------------------------------------------------
   Pages — 读者问答 (faq.html)
   -------------------------------------------------------------------------- */

.faq-section {
  margin-bottom: 40px;
}

.faq-section .faq-list {
  margin-top: 16px;
}

.faq-guide-figure {
  margin: 32px 0;
}

.faq-guide-figure img {
  width: 100%;
  aspect-ratio: 21 / 7;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.faq-guide-figure figcaption {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}

/* --------------------------------------------------------------------------
   Pages — 版权边界 (boundary.html)
   -------------------------------------------------------------------------- */

.boundary-section {
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border-light);
}

.boundary-section:last-of-type {
  border-bottom: none;
  margin-bottom: 24px;
  padding-bottom: 0;
}

.section-lead {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.9;
  max-width: var(--text-max);
  margin-bottom: 16px;
}

/* 素材使用原则表 */
.principle-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.7;
  background: var(--card-bg);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.principle-table th,
.principle-table td {
  padding: 12px 16px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border-light);
}

.principle-table thead th {
  background: #f6f7f9;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
}

.principle-table tbody tr:last-child td {
  border-bottom: none;
}

/* 氛围示意图 */
.boundary-figure {
  margin: 24px 0;
}

.boundary-figure img {
  width: 100%;
  aspect-ratio: 21 / 7;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.boundary-figure figcaption {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}

.content-image {
  width: 100%;
  aspect-ratio: 21 / 7;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.image-caption-text {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 8px;
}

.material-note {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-top: 12px;
  padding: 12px 16px;
  background: var(--page-bg);
  border-left: 3px solid var(--accent-amber);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.supplement-note {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-top: 12px;
  padding: 12px 16px;
  background: var(--page-bg);
  border-radius: var(--radius-sm);
}

.proper-steps {
  padding-left: 20px;
  margin-top: 16px;
}

.proper-steps li {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 8px;
  padding-left: 4px;
}

/* 站内栏目关系 */
.page-boundary .related-links {
  margin-top: 8px;
}

/* --------------------------------------------------------------------------
   Pages — 404 页面
   -------------------------------------------------------------------------- */

.error-main {
  background: var(--card-bg);
  min-height: calc(100vh - var(--header-height) - 320px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.error-section {
  text-align: center;
  max-width: 560px;
  padding: 40px 24px;
}

.error-code {
  font-size: 64px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--border-mid);
  margin-bottom: 8px;
}

.error-section h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 16px;
}

.error-desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 24px;
}

.error-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.error-home-link,
.error-genres-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  border-radius: var(--radius-md);
  font-size: 15px;
  min-height: 44px;
  transition: background-color 0.2s ease, color 0.2s ease,
    border-color 0.2s ease;
}

.error-home-link {
  background: var(--link-blue);
  color: #fff;
  border: 1px solid var(--link-blue);
}

.error-home-link:hover {
  background: var(--link-hover);
  color: #fff;
}

.error-genres-link {
  background: transparent;
  color: var(--link-blue);
  border: 1px solid var(--border-mid);
}

.error-genres-link:hover {
  border-color: var(--link-blue);
  color: var(--link-hover);
  background: #f0f5fa;
}

.error-help {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
}

.error-help a {
  color: var(--link-blue);
}

/* --------------------------------------------------------------------------
   Components — 全站页脚
   -------------------------------------------------------------------------- */

.site-footer {
  background: #e6e8eb;
  border-top: 1px solid var(--border-light);
  margin-top: 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.4fr;
  gap: 32px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px 24px;
}

.footer-col {
  min-width: 0;
}

.footer-brand {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.footer-tagline {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.footer-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.footer-title {
  font-size: 14px;
  font-weight: 650;
  color: var(--text-main);
  margin-bottom: 12px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-links a {
  font-size: 14px;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--link-hover);
}

.footer-boundary-text {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.8;
}

.footer-bottom {
  border-top: 1px solid var(--border-light);
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 1200px;
  margin: 0 auto;
  font-size: 13px;
  color: var(--text-muted);
}

.back-to-top {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  padding: 4px 0;
}

.back-to-top:hover {
  color: var(--link-hover);
}

.back-to-top::before {
  content: "↑";
  font-size: 14px;
}

.footer-home {
  font-size: 13px;
  color: var(--text-muted);
}

.footer-home:hover {
  color: var(--link-hover);
}

/* --------------------------------------------------------------------------
   Responsive — 900px 与 640px 两级断点
   -------------------------------------------------------------------------- */

/* 第一断点: 900px */
@media (max-width: 900px) {
  .site-header {
    position: sticky;
  }

  /* 移动端导航按钮显示 */
  .nav-toggle {
    display: inline-flex;
  }

  /* 移动端导航默认收起，点击 .is-open 展开 */
  .site-nav {
    display: block;
    position: fixed;
    top: var(--header-height);
    left: 0;
    z-index: 950;
    width: 100%;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-light);
    box-shadow: 0 4px 12px rgba(26, 43, 60, 0.08);
  }

  .nav-list {
    display: none;
    flex-direction: column;
    padding: 8px 0;
    max-height: calc(100vh - var(--header-height) - 16px);
    overflow-y: auto;
  }

  .nav-list.is-open {
    display: flex;
  }

  .nav-item {
    border-bottom: 1px solid #f0f1f3;
  }

  .nav-item:last-child {
    border-bottom: none;
  }

  .nav-link {
    display: block;
    padding: 12px 24px;
    font-size: 15px;
    color: var(--text-secondary);
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .nav-link:hover {
    background: var(--page-bg);
    color: var(--link-hover);
  }

  .nav-link.is-current {
    color: var(--link-hover);
    font-weight: 600;
    background: #f6f7f9;
  }

  /* 布局改为单列 */
  .layout-shell.sidebar-left,
  .page-layout.sidebar-left {
    display: block;
  }

  /* 桌面侧栏隐藏 */
  .sidebar-nav {
    display: none;
  }

  /* 主内容宽度调整 */
  .site-main {
    padding: 24px 24px 48px;
  }

  .hero-section {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 24px 0;
  }

  .hero-figure {
    max-width: 560px;
  }

  .genre-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .chess-row {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .chess-row-reverse .chess-copy {
    order: 0;
  }

  .chess-row-reverse .chess-figure {
    order: 0;
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }

  .feature-cards-row {
    grid-template-columns: 1fr 1fr;
  }

  .feature-card-large {
    grid-template-columns: 1fr;
  }

  .feature-card-large .feature-media img {
    aspect-ratio: 16 / 9;
  }

  .overview-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .step-fields {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .term-list {
    grid-template-columns: 1fr;
  }

  .publication-group-table {
    grid-template-columns: 1fr;
  }

  .preview-grid {
    grid-template-columns: 1fr;
  }

  .info-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .next-step-grid {
    grid-template-columns: 1fr;
  }

  .feature-cards-pair {
    grid-template-columns: 1fr;
  }

  /* 侧栏隐藏后正文宽度恢复 */
  .inner-main {
    width: 100%;
  }
}

/* 第二断点: 640px */
@media (max-width: 640px) {
  .header-inner {
    padding: 0 12px;
  }

  .brand-slogan {
    display: none;
  }

  .site-main {
    padding: 20px 16px 40px;
  }

  .home-main {
    padding: 20px 16px 40px;
  }

  .page-title {
    font-size: 23px;
  }

  .hero-title {
    font-size: 24px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }

  .genre-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .chess-row {
    gap: 16px;
    margin-bottom: 36px;
  }

  .chess-image,
  .chess-image-wide {
    aspect-ratio: 16 / 10;
  }

  .chess-row-full {
    gap: 16px;
  }

  .preview-card {
    padding: 18px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 32px 16px 20px;
  }

  .footer-bottom {
    padding: 14px 16px;
    flex-direction: column;
    align-items: flex-start;
  }

  .feature-cards-row {
    grid-template-columns: 1fr;
  }

  .feature-group {
    margin-bottom: 36px;
  }

  .feature-card-full .feature-content {
    padding: 18px;
  }

  .overview-steps {
    grid-template-columns: 1fr;
  }

  .step-fields {
    gap: 10px;
  }

  .field-card {
    padding: 14px 16px;
  }

  .genre-entry {
    padding: 16px;
  }

  .genre-fields p {
    flex-direction: column;
    gap: 2px;
  }

  .term-entry {
    padding: 14px 16px;
  }

  .term-field {
    flex-direction: column;
    gap: 2px;
  }

  .publication-group-row {
    padding: 14px 16px;
  }

  .related-link-item,
  .glossary-related-links li {
    font-size: 14px;
  }

  .error-code {
    font-size: 48px;
  }

  .error-section {
    padding: 24px 16px;
  }

  .breadcrumb {
    margin-bottom: 16px;
  }

  .page-header {
    margin-bottom: 24px;
  }

  .table-wrap {
    margin-bottom: 16px;
  }

  .data-table th,
  .data-table td {
    padding: 10px 12px;
    font-size: 13px;
  }

  .obstacle-table th,
  .obstacle-table td {
    padding: 10px 12px;
    font-size: 13px;
  }

  .faq-item summary {
    padding: 12px 14px;
    font-size: 14px;
  }

  .faq-item p {
    padding: 12px 14px;
    font-size: 13px;
  }

  .next-step-card {
    padding: 18px;
  }

  .feature-fields {
    padding: 18px;
  }
}
