/* ============================================================
   漫漫漫画 · 全站样式表
   视觉方向：简洁电商目录风，封面优先，筛选稳定
   配色：#f6f7f9 / #2b303a / #3a5a78 / #e97b2a / #ffffff
   ============================================================ */

/* ------------------------------------------------------------
   01 · Base —— 基础变量、重置、字体、通用元素
   ------------------------------------------------------------ */
:root {
  --color-bg: #f6f7f9;
  --color-ink: #2b303a;
  --color-primary: #3a5a78;
  --color-accent: #e97b2a;
  --color-white: #ffffff;
  --color-line: #e4e7ec;
  --color-muted: #7a808c;
  --color-soft: #eef1f5;

  --font-stack: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;

  --container-width: 1200px;
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;

  --space-xs: 8px;
  --space-sm: 12px;
  --space-md: 20px;
  --space-lg: 32px;
  --space-xl: 48px;

  --shadow-card: 0 1px 3px rgba(43, 48, 58, 0.06);
  --shadow-hover: 0 4px 14px rgba(43, 48, 58, 0.1);

  --header-height: 64px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-stack);
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-ink);
  background-color: var(--color-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--color-accent);
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.35;
  color: var(--color-ink);
}

h1 {
  font-size: 28px;
}

h2 {
  font-size: 20px;
}

h3 {
  font-size: 16px;
}

p {
  margin-bottom: 12px;
}

/* 统一容器 */
.site-header .header-inner,
.site-main,
.footer-inner,
.hero-select,
.boundary-statement,
.resource-center,
.reading-path,
.faq-preview,
.about-summary {
  width: 100%;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* ------------------------------------------------------------
   02 · Layout —— 全站骨架：页头、页脚、主容器、面包屑
   ------------------------------------------------------------ */

/* ---------- 页头 ---------- */
.site-header {
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-line);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
  gap: 24px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-shrink: 0;
}

.brand-name {
  font-size: 22px;
  font-weight: 800;
  color: var(--color-ink);
  letter-spacing: 0.02em;
}

.brand-tag {
  font-size: 12px;
  color: var(--color-muted);
  display: none;
}

/* 主导航 */
.site-nav {
  margin-left: auto;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-list li a {
  display: block;
  padding: 8px 14px;
  font-size: 15px;
  font-weight: 500;
  color: var(--color-ink);
  border-radius: var(--radius-sm);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-list li a:hover {
  background-color: var(--color-soft);
  color: var(--color-primary);
}

.nav-list li a.is-current {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* 汉堡按钮，桌面隐藏 */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-ink);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---------- 主容器 ---------- */
.site-main {
  flex: 1 0 auto;
  padding-top: var(--space-lg);
  padding-bottom: var(--space-xl);
}

/* 内页统一外壳 */
.inner-main {
  padding-top: var(--space-md);
  padding-bottom: var(--space-xl);
}

/* 面包屑 */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 16px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.breadcrumb a {
  color: var(--color-muted);
}

.breadcrumb a:hover {
  color: var(--color-accent);
}

.breadcrumb-sep {
  color: #b4bac4;
}

.breadcrumb-current {
  color: var(--color-ink);
  font-weight: 500;
}

/* 内页标题区 */
.page-header {
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-line);
  padding: 28px 0;
  margin-bottom: var(--space-lg);
}

.page-header .page-title,
.page-header .page-description {
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.page-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--color-ink);
  margin-bottom: 8px;
}

.page-description {
  font-size: 15px;
  color: var(--color-muted);
  line-height: 1.7;
  margin-bottom: 0;
}

/* ---------- 页脚 ---------- */
.site-footer {
  background-color: var(--color-ink);
  color: #c9cdd4;
  margin-top: auto;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 32px;
  padding-top: var(--space-xl);
  padding-bottom: var(--space-lg);
}

.footer-brand-name {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 8px;
}

.footer-col p {
  font-size: 14px;
  line-height: 1.7;
  color: #aeb4be;
}

.footer-col-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-white);
  margin-bottom: 12px;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col ul li a {
  font-size: 14px;
  color: #aeb4be;
}

.footer-col ul li a:hover {
  color: var(--color-accent);
}

.footer-note p {
  font-size: 13px;
  color: #8f96a1;
  line-height: 1.7;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 16px 24px;
  text-align: center;
}

.footer-bottom p {
  font-size: 13px;
  color: #8f96a1;
  margin-bottom: 0;
}

/* ------------------------------------------------------------
   03 · Components —— 通用组件：按钮、卡片、列表、侧栏、FAQ
   ------------------------------------------------------------ */

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  font-size: 15px;
  font-weight: 500;
  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, box-shadow 0.2s ease;
  min-height: 44px;
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-white);
}

.btn-primary:hover {
  background-color: #2f4a63;
  color: var(--color-white);
  box-shadow: var(--shadow-hover);
}

.btn-secondary {
  background-color: var(--color-accent);
  color: var(--color-white);
}

.btn-secondary:hover {
  background-color: #d16a1f;
  color: var(--color-white);
  box-shadow: var(--shadow-hover);
}

.btn-outline {
  background-color: transparent;
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn-outline:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* ---------- 分类侧栏 ---------- */
.category-sidebar {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.category-sidebar h2,
.sidebar-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-ink);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--color-soft);
}

.category-list li {
  margin-bottom: 4px;
}

.category-list li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  font-size: 14px;
  color: var(--color-ink);
  border-radius: var(--radius-sm);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.category-list li a:hover {
  background-color: var(--color-soft);
  color: var(--color-primary);
}

.category-list .count {
  font-size: 12px;
  color: var(--color-muted);
  background-color: var(--color-soft);
  padding: 2px 8px;
  border-radius: 10px;
}

.sidebar-link {
  display: inline-block;
  margin-top: 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-accent);
}

.sidebar-note {
  font-size: 13px;
  color: var(--color-muted);
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--color-line);
}

/* ---------- 紧凑列表 ---------- */
.compact-list li {
  border-bottom: 1px solid var(--color-soft);
}

.compact-list li:last-child {
  border-bottom: none;
}

.compact-list li a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  transition: background-color 0.2s ease;
  border-radius: var(--radius-sm);
}

.compact-list li a:hover {
  background-color: var(--color-soft);
}

.list-thumb {
  width: 44px;
  height: 58px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
  background-color: var(--color-soft);
}

.list-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.list-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.list-desc {
  font-size: 13px;
  color: var(--color-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.list-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.list-time {
  font-size: 12px;
  color: var(--color-muted);
  white-space: nowrap;
}

.list-rank {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-line);
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}

/* 热门列表前三名高亮 */
.resource-block .compact-list li:nth-child(-n + 3) .list-rank {
  color: var(--color-accent);
}

.block-more {
  display: inline-block;
  margin-top: 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-primary);
}

.block-more:hover {
  color: var(--color-accent);
}

/* ---------- 封面卡 ---------- */
.work-card {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.work-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.work-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background-color: var(--color-soft);
}

.work-card figcaption {
  padding: 10px 12px 12px;
}

.work-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-ink);
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.work-tag {
  display: inline-block;
  font-size: 12px;
  color: var(--color-primary);
  background-color: var(--color-soft);
  padding: 2px 8px;
  border-radius: 10px;
}

/* ---------- FAQ 折叠 ---------- */
.faq-item {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-item summary {
  padding: 16px 20px;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-ink);
  cursor: pointer;
  position: relative;
  padding-right: 40px;
  list-style: none;
  transition: background-color 0.2s ease;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  font-weight: 400;
  color: var(--color-muted);
  transition: transform 0.2s ease;
}

.faq-item[open] summary {
  background-color: var(--color-soft);
}

.faq-item[open] summary::after {
  transform: translateY(-50%) rotate(45deg);
  color: var(--color-accent);
}

.faq-item p {
  padding: 0 20px 16px;
  font-size: 14px;
  color: var(--color-muted);
  line-height: 1.7;
  margin-bottom: 0;
}

/* ---------- 相关链接卡片 ---------- */
.related-card {
  display: block;
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.related-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  color: var(--color-ink);
}

.related-card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--color-ink);
}

.related-card p {
  font-size: 13px;
  color: var(--color-muted);
  margin-bottom: 0;
  line-height: 1.6;
}

.related-title {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-ink);
  margin-bottom: 6px;
}

.related-desc {
  display: block;
  font-size: 13px;
  color: var(--color-muted);
  line-height: 1.6;
}

/* ---------- section 标题 ---------- */
.section-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-ink);
  margin-bottom: 16px;
  position: relative;
  padding-left: 12px;
}

.section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 4px;
  border-radius: 2px;
  background-color: var(--color-accent);
}

/* ---------- 双栏布局 ---------- */
.layout-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
  margin-bottom: var(--space-lg);
}

/* 侧栏在左（默认）.sidebar-left 祖先容器 */
.sidebar-left {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  align-items: start;
}

.sidebar-left > .category-sidebar,
.sidebar-left > .sidebar {
  grid-column: 1;
}

.sidebar-left > .work-list,
.sidebar-left > .content-area {
  grid-column: 2;
}

/* 内容区通用 */
.content-area {
  min-width: 0;
}

.work-list {
  min-width: 0;
}

/* ------------------------------------------------------------
   04 · Pages —— 首页各模块
   ------------------------------------------------------------ */

/* ---------- 首屏选择区 ---------- */
.hero-select {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  padding-top: var(--space-xl);
  padding-bottom: var(--space-xl);
}

.hero-media img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: var(--radius-lg);
  background-color: var(--color-soft);
  box-shadow: var(--shadow-card);
}

.hero-content h1 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 12px;
  line-height: 1.3;
}

.hero-lead {
  font-size: 16px;
  color: var(--color-muted);
  margin-bottom: 24px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- 边界声明条 ---------- */
.boundary-statement {
  background-color: var(--color-soft);
  border-left: 3px solid var(--color-primary);
  padding: 14px 20px;
  margin-bottom: var(--space-lg);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.boundary-statement p {
  font-size: 14px;
  color: var(--color-primary);
  margin-bottom: 0;
  line-height: 1.6;
}

/* ---------- 资源中心 ---------- */
.resource-center {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  margin-bottom: var(--space-xl);
  align-items: start;
}

.resource-main {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

.resource-block {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.resource-block h2 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--color-soft);
}

/* ---------- 阅读路径 ---------- */
.reading-path {
  margin-bottom: var(--space-xl);
}

.path-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}

.path-step {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 24px 20px;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.path-step:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.path-step .step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--color-primary);
  color: var(--color-white);
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 12px;
}

.path-step h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
}

.path-step p {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 0;
  line-height: 1.6;
}

.path-more {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-primary);
}

/* ---------- FAQ 预览 ---------- */
.faq-preview {
  margin-bottom: var(--space-xl);
}

.faq-preview h2 {
  font-size: 20px;
  margin-bottom: 16px;
}

.faq-more {
  display: inline-block;
  margin-top: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-primary);
}

/* ---------- 关于本站摘要 ---------- */
.about-summary {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: var(--space-xl);
}

.about-summary h2 {
  font-size: 20px;
  margin-bottom: 12px;
}

.about-summary p {
  font-size: 15px;
  color: var(--color-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}

.about-more {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-accent);
}

/* ------------------------------------------------------------
   05 · Pages —— 漫画大全 gallery
   ------------------------------------------------------------ */

/* 分类范围标签 */
.category-scope {
  grid-column: 1 / -1;
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 4px;
}

.category-scope .section-title {
  margin-bottom: 8px;
}

.category-scope p {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 12px;
}

.scope-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.scope-tags li a {
  display: inline-block;
  padding: 6px 14px;
  font-size: 13px;
  color: var(--color-primary);
  background-color: var(--color-soft);
  border-radius: 16px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.scope-tags li a:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* 分类作品区块 */
.work-category {
  margin-bottom: 28px;
}

.work-category:last-child {
  margin-bottom: 0;
}

.category-name {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--color-soft);
}

.category-desc {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 12px;
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

/* 相关内容导航条 */
.related-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
  margin-bottom: var(--space-lg);
}

.related-links-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-ink);
}

.related-links-item {
  font-size: 14px;
  color: var(--color-primary);
  padding: 4px 10px;
  background-color: var(--color-soft);
  border-radius: 14px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.related-links-item:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* ------------------------------------------------------------
   06 · Pages —— 今日更新 updates
   ------------------------------------------------------------ */

.update-note {
  background-color: var(--color-soft);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 24px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.update-note .section-title {
  margin-bottom: 8px;
}

.update-note p {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 0;
}

.update-note a {
  color: var(--color-primary);
  font-weight: 500;
}

/* 侧栏 */
.sidebar-block {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
}

.sidebar-block:last-child {
  margin-bottom: 0;
}

.sidebar-list li a {
  display: block;
  padding: 7px 10px;
  font-size: 14px;
  color: var(--color-ink);
  border-radius: var(--radius-sm);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.sidebar-list li a:hover {
  background-color: var(--color-soft);
  color: var(--color-primary);
}

/* 更新列表 */
.update-list-section {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.update-list {
  counter-reset: update-counter;
}

.update-item {
  display: flex;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-soft);
  align-items: center;
}

.update-item:last-child {
  border-bottom: none;
}

.update-thumb {
  width: 64px;
  height: 84px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background-color: var(--color-soft);
  flex-shrink: 0;
}

.update-info {
  flex: 1;
  min-width: 0;
}

.update-info h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
}

.update-info h3 a {
  color: var(--color-ink);
}

.update-info h3 a:hover {
  color: var(--color-accent);
}

.update-meta {
  font-size: 13px;
  color: var(--color-muted);
  margin-bottom: 4px;
}

.update-category {
  display: inline-block;
  font-size: 12px;
  color: var(--color-primary);
  background-color: var(--color-soft);
  padding: 2px 8px;
  border-radius: 10px;
}

/* 相关推荐网格 */
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

/* ------------------------------------------------------------
   07 · Pages —— 热门排行 ranking
   ------------------------------------------------------------ */

.ranking-section {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.ranking-list {
  counter-reset: ranking-counter;
}

.ranking-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--color-soft);
}

.ranking-item:last-child {
  border-bottom: none;
}

.ranking-num {
  font-size: 20px;
  font-weight: 800;
  color: var(--color-line);
  width: 32px;
  text-align: center;
  flex-shrink: 0;
  font-style: italic;
}

.ranking-item:nth-child(1) .ranking-num,
.ranking-item:nth-child(2) .ranking-num,
.ranking-item:nth-child(3) .ranking-num {
  color: var(--color-accent);
}

.ranking-cover {
  flex-shrink: 0;
}

.ranking-cover img {
  width: 48px;
  height: 64px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background-color: var(--color-soft);
}

.ranking-info {
  flex: 1;
  min-width: 0;
}

.ranking-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 2px;
}

.ranking-title a {
  color: var(--color-ink);
}

.ranking-title a:hover {
  color: var(--color-accent);
}

.ranking-tag {
  display: inline-block;
  font-size: 12px;
  color: var(--color-primary);
  background-color: var(--color-soft);
  padding: 1px 8px;
  border-radius: 10px;
  margin-bottom: 4px;
}

.ranking-desc {
  font-size: 13px;
  color: var(--color-muted);
  margin-bottom: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 排行规则说明 */
.rule-note {
  background-color: var(--color-soft);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-bottom: 24px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.rule-note .section-title {
  margin-bottom: 8px;
}

.rule-note p {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 8px;
}

.rule-note a {
  color: var(--color-primary);
  font-weight: 500;
  margin-right: 12px;
}

/* ------------------------------------------------------------
   08 · Pages —— 阅读指南 guide
   ------------------------------------------------------------ */

.scope-note {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-left: 3px solid var(--color-accent);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin-bottom: 24px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.scope-note h2 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 10px;
}

.scope-note p {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 8px;
  line-height: 1.7;
}

.scope-note p:last-child {
  margin-bottom: 0;
}

/* 阅读步骤 */
.reading-steps {
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
  margin-bottom: 24px;
}

.reading-steps > h2 {
  font-size: 20px;
  margin-bottom: 20px;
}

.step-card {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
  align-items: center;
}

.step-card:last-child {
  margin-bottom: 0;
}

.step-media img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: var(--radius-md);
  background-color: var(--color-soft);
}

.step-body .step-number {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-accent);
  background-color: var(--color-soft);
  padding: 2px 10px;
  border-radius: 12px;
  margin-bottom: 8px;
}

.step-body h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
}

.step-body p {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 6px;
  line-height: 1.7;
}

.step-body p:last-child {
  margin-bottom: 0;
}

/* 相关链接列表 */
.related-list {
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.related-list li {
  margin-bottom: 8px;
}

.related-list li a {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-primary);
  padding: 8px 16px;
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.related-list li a:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* ------------------------------------------------------------
   09 · Pages —— 常见问题 faq
   ------------------------------------------------------------ */

.faq-list-section {
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
  margin-bottom: 24px;
}

.faq-list-section .section-title {
  margin-bottom: 16px;
}

.content-media-inline {
  margin-bottom: 16px;
}

.content-media-inline img {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border-radius: var(--radius-lg);
  background-color: var(--color-soft);
}

.content-media-inline figcaption {
  font-size: 13px;
  color: var(--color-muted);
  padding: 8px 4px 0;
  text-align: center;
}

/* 版权说明 */
.copyright-note {
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.copyright-note .section-title {
  margin-bottom: 12px;
}

.note-content p {
  font-size: 14px;
  color: var(--color-muted);
  line-height: 1.7;
  margin-bottom: 8px;
}

.note-content p:last-child {
  margin-bottom: 0;
}

/* 相关卡片 */
.faq-list-section + .related-links {
  margin-top: 0;
}

/* ------------------------------------------------------------
   10 · Pages —— 关于本站 about
   ------------------------------------------------------------ */

.about-section {
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
  margin-bottom: 32px;
}

.about-section .section-title {
  margin-bottom: 12px;
}

.about-content p {
  font-size: 15px;
  color: var(--color-muted);
  line-height: 1.7;
  margin-bottom: 10px;
  max-width: 720px;
}

.about-content p:last-child {
  margin-bottom: 0;
}

.about-figure {
  margin-top: 16px;
}

.about-figure img {
  width: 100%;
  max-height: 280px;
  object-fit: cover;
  border-radius: var(--radius-lg);
  background-color: var(--color-soft);
}

.about-figure figcaption {
  font-size: 13px;
  color: var(--color-muted);
  padding: 8px 4px 0;
  text-align: center;
}

/* ------------------------------------------------------------
   11 · Pages —— 404 错误页
   ------------------------------------------------------------ */

.error-main {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
}

.error-inner {
  text-align: center;
  max-width: 480px;
}

.error-code {
  font-size: 72px;
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: 16px;
}

.error-inner h1 {
  font-size: 24px;
  margin-bottom: 12px;
}

.error-desc {
  font-size: 15px;
  color: var(--color-muted);
  margin-bottom: 8px;
}

.error-tip {
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 24px;
}

.error-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 28px;
  background-color: var(--color-primary);
  color: var(--color-white);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 500;
}

.error-btn:hover {
  background-color: #2f4a63;
  color: var(--color-white);
}

/* ------------------------------------------------------------
   12 · Responsive —— 响应式
   ------------------------------------------------------------ */

/* ---------- 平板与窄桌面 ---------- */
@media (max-width: 1024px) {
  .hero-select {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .hero-media {
    order: -1;
  }

  .hero-media img {
    max-height: 320px;
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
}

/* ---------- 移动端 768px ---------- */
@media (max-width: 768px) {
  .site-header .header-inner,
  .site-main,
  .footer-inner,
  .hero-select,
  .boundary-statement,
  .resource-center,
  .reading-path,
  .faq-preview,
  .about-summary,
  .breadcrumb,
  .page-header .page-title,
  .page-header .page-description,
  .layout-shell,
  .update-note,
  .ranking-section,
  .rule-note,
  .scope-note,
  .reading-steps,
  .related-list,
  .faq-list-section,
  .copyright-note,
  .about-section,
  .related-links {
    padding-left: 16px;
    padding-right: 16px;
  }

  /* 汉堡菜单 */
  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background-color: var(--color-white);
    border-bottom: 1px solid var(--color-line);
    box-shadow: 0 4px 12px rgba(43, 48, 58, 0.08);
    margin-left: 0;
  }

  .nav-list {
    display: none;
    flex-direction: column;
    padding: 8px 16px 16px;
    gap: 2px;
  }

  .nav-list.is-open {
    display: flex;
  }

  .nav-list li {
    width: 100%;
  }

  .nav-list li a {
    padding: 12px 14px;
    font-size: 16px;
    border-radius: var(--radius-sm);
  }

  /* 首页模块 */
  .hero-select {
    padding-top: 24px;
    padding-bottom: 24px;
  }

  .hero-content h1 {
    font-size: 26px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .resource-center {
    grid-template-columns: 1fr;
  }

  .category-sidebar {
    order: 2;
  }

  .resource-main {
    order: 1;
  }

  .path-steps {
    grid-template-columns: 1fr;
  }

  /* 内页双栏变单栏 */
  .layout-shell {
    grid-template-columns: 1fr;
  }

  .sidebar-left {
    grid-template-columns: 1fr;
  }

  .sidebar-left > .category-sidebar,
  .sidebar-left > .sidebar {
    grid-column: 1;
  }

  .sidebar-left > .work-list,
  .sidebar-left > .content-area {
    grid-column: 1;
  }

  /* 移动端顺序：内容在前，侧栏在后 */
  .sidebar-left > .work-list,
  .sidebar-left > .content-area {
    order: 1;
  }

  .sidebar-left > .category-sidebar,
  .sidebar-left > .sidebar {
    order: 2;
  }

  /* gallery 分类范围在第一 */
  .sidebar-left > .category-scope {
    order: 0;
    grid-column: 1;
  }

  /* 封面网格 */
  .work-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  /* 更新列表 */
  .update-item {
    flex-direction: row;
    gap: 12px;
  }

  .update-thumb {
    width: 52px;
    height: 68px;
  }

  /* 排行榜 */
  .ranking-item {
    gap: 12px;
  }

  .ranking-num {
    font-size: 17px;
    width: 24px;
  }

  .ranking-cover img {
    width: 40px;
    height: 54px;
  }

  .ranking-desc {
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* 指南步骤 */
  .step-card {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .step-media img {
    max-height: 200px;
  }

  /* 相关网格 */
  .related-grid {
    grid-template-columns: 1fr;
  }

  /* 页脚 */
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 24px;
    padding-top: 32px;
    padding-bottom: 24px;
  }

  .footer-col {
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .footer-col:last-child {
    border-bottom: none;
  }

  .footer-bottom {
    padding: 14px 16px;
  }
}

/* ---------- 小屏手机 390px ---------- */
@media (max-width: 420px) {
  .brand-tag {
    display: none;
  }

  .hero-content h1 {
    font-size: 24px;
  }

  .hero-lead {
    font-size: 15px;
  }

  .work-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .work-card figcaption {
    padding: 8px 10px 10px;
  }

  .work-title {
    font-size: 13px;
  }

  .work-tag {
    font-size: 11px;
    padding: 1px 6px;
  }

  .page-title {
    font-size: 24px;
  }

  .page-description {
    font-size: 14px;
  }

  .resource-block {
    padding: 16px;
  }

  .compact-list li a {
    gap: 10px;
  }

  .list-thumb {
    width: 40px;
    height: 52px;
  }

  .list-time {
    font-size: 11px;
  }

  .update-item {
    align-items: flex-start;
  }

  .update-thumb {
    width: 48px;
    height: 64px;
  }

  .update-info h3 {
    font-size: 14px;
  }

  .update-meta {
    font-size: 12px;
  }

  .ranking-item {
    padding: 10px 0;
  }

  .ranking-num {
    font-size: 16px;
    width: 20px;
  }

  .ranking-title {
    font-size: 14px;
  }

  .ranking-tag {
    font-size: 11px;
  }

  .ranking-desc {
    font-size: 12px;
  }

  .faq-item summary {
    padding: 14px 16px;
    padding-right: 36px;
    font-size: 14px;
  }

  .faq-item p {
    padding: 0 16px 14px;
    font-size: 13px;
  }

  .section-title {
    font-size: 18px;
  }

  .path-step {
    padding: 20px 16px;
  }

  .error-code {
    font-size: 56px;
  }
}
