/* ==========================================================================
   age动漫 · 全站样式表
   分组：base / layout / components / pages / responsive
   ========================================================================== */

/* --------------------------------------------------------------------------
   base：变量、重置、排版、图片、无障碍
   -------------------------------------------------------------------------- */
:root {
  --page-bg: #f5f6f7;
  --panel-bg: #ffffff;
  --panel-alt: #fafbfc;
  --text-main: #1f2328;
  --text-sub: #5b6470;
  --text-faint: #7d8794;
  --accent: #2f6feb;
  --accent-soft: #eaf1fe;
  --border: #d8dde3;
  --border-soft: #e7ebef;
  --rank-accent: #e8a33d;
  --radius: 6px;
  --radius-sm: 4px;
  --shadow-card: 0 1px 2px rgba(31, 35, 40, 0.06);
  --font-sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC",
    "Noto Sans CJK SC", "WenQuanYi Micro Hei", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: "SFMono-Regular", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", "Courier New", monospace;
  --wrap: 1160px;
  --wrap-narrow: 900px;
  --gutter: 20px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  background: var(--page-bg);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  font-weight: 400;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  color: var(--text-main);
  font-weight: 600;
  line-height: 1.35;
}

p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.18s ease, border-color 0.18s ease, background-color 0.18s ease;
}

a:hover {
  color: #1b56c4;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
  border: 0;
}

figure {
  margin: 0;
}

button {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

time {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   layout：页面骨架、容器、页头导航、页脚、通用栏格
   -------------------------------------------------------------------------- */
.site-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--page-bg);
  font-family: var(--font-sans);
  color: var(--text-main);
}

.site-main {
  flex: 1 1 auto;
  width: 100%;
}

/* 顶部事实条 */
.site-factbar {
  margin: 0;
  padding: 8px var(--gutter);
  background: #eef1f4;
  border-bottom: 1px solid var(--border-soft);
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

/* 页头与主导航 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--panel-bg);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 12px var(--gutter);
}

.brand {
  flex: 0 0 auto;
  color: var(--text-main);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.2;
}

.brand:hover {
  color: var(--accent);
}

.site-nav {
  flex: 1 1 auto;
  display: flex;
  justify-content: flex-end;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  display: block;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-sub);
  font-size: 15px;
  line-height: 1.4;
  white-space: nowrap;
}

.nav-link:hover {
  background: var(--panel-alt);
  color: var(--text-main);
}

.nav-link.is-current {
  color: var(--accent);
  font-weight: 600;
  background: var(--accent-soft);
}

/* 汉堡按钮：桌面隐藏 */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0 10px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text-main);
  border-radius: 1px;
}

/* 页脚 */
.site-footer {
  margin-top: 48px;
  background: #23272c;
  color: #c7ced6;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 32px;
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 40px var(--gutter) 28px;
}

.footer-col {
  min-width: 0;
}

.footer-brand {
  margin-bottom: 10px;
  color: #ffffff;
  font-size: 18px;
  font-weight: 700;
}

.footer-about {
  color: #a9b2bc;
  font-size: 14px;
  line-height: 1.75;
}

.footer-title {
  margin-bottom: 12px;
  color: #ffffff;
  font-size: 15px;
  font-weight: 600;
}

.footer-links {
  display: grid;
  gap: 8px;
}

.footer-links a {
  color: #c7ced6;
  font-size: 14px;
}

.footer-links a:hover {
  color: #ffffff;
}

.footer-note {
  color: #a9b2bc;
  font-size: 14px;
  line-height: 1.75;
}

.footer-link {
  display: inline-block;
  margin-top: 10px;
  color: #ffffff;
  font-size: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
}

.footer-link:hover {
  color: #ffffff;
  border-bottom-color: #ffffff;
}

.footer-copy {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 14px var(--gutter) 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #8f99a4;
  font-size: 13px;
  line-height: 1.6;
}

/* 内页主容器与页面标题区 */
.inner-main {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 20px var(--gutter) 0;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
  color: var(--text-faint);
  font-size: 13px;
  line-height: 1.6;
}

.breadcrumb a {
  color: var(--text-sub);
}

.breadcrumb a:hover {
  color: var(--accent);
}

.breadcrumb-sep {
  color: var(--border);
}

.breadcrumb-current {
  color: var(--text-main);
}

.page-header {
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.page-title {
  margin-bottom: 10px;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.3;
}

.page-description {
  max-width: 76ch;
  color: var(--text-sub);
  font-size: 15px;
  line-height: 1.75;
}

/* 内页主内容 + 侧栏 */
.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 32px;
  align-items: start;
}

.layout-main {
  min-width: 0;
}

.layout-aside {
  min-width: 0;
}

/* 更新页布局容器 */
.layout-main-aside {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 32px;
  align-items: start;
}

/* --------------------------------------------------------------------------
   components：区块标题、标签、卡片、条目行、表格、aside、FAQ、按钮
   -------------------------------------------------------------------------- */
.section-head {
  margin-bottom: 18px;
}

.section-head h2 {
  margin-bottom: 6px;
  font-size: 22px;
  font-weight: 600;
}

.section-desc {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.7;
}

.section-title {
  margin-bottom: 8px;
  font-size: 22px;
  font-weight: 600;
}

.section-lead,
.section-intro {
  margin-bottom: 18px;
  color: var(--text-sub);
  font-size: 15px;
  line-height: 1.75;
}

.section-note {
  margin-top: 16px;
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.section-note a {
  margin-right: 12px;
}

.section-more {
  display: inline-block;
  margin-top: 16px;
  font-size: 14px;
  font-weight: 600;
}

/* 标签 */
.tag {
  display: inline-block;
  padding: 2px 8px;
  background: var(--panel-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-sub);
  font-size: 12px;
  line-height: 1.6;
  white-space: nowrap;
}

/* 封面卡（首页与题材分类页共用） */
.cover-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.cover-grid-three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cover-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 10px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

.cover-card:hover {
  border-color: var(--accent);
  background: var(--panel-alt);
}

.cover-link {
  display: block;
  color: inherit;
}

.cover-link:hover {
  color: inherit;
}

.cover-figure {
  margin: 0;
}

.cover-img {
  width: 100%;
  height: 168px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: #eceff2;
}

.cover-name {
  margin-top: 8px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
}

.cover-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.cover-note {
  margin-top: 8px;
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

/* 更新记录行 */
.update-list {
  display: grid;
  gap: 2px;
}

.update-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 10px;
  padding: 9px 10px;
  border-bottom: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  transition: background-color 0.18s ease;
}

.update-row:hover {
  background: var(--panel-alt);
}

.update-date {
  color: var(--text-faint);
  font-size: 13px;
}

.update-name,
.update-entry {
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
}

.update-genre {
  color: var(--text-sub);
  font-size: 13px;
  white-space: nowrap;
}

/* 榜单条目（首页速览与榜单页共用基础） */
.rank-list {
  display: grid;
  gap: 2px;
}

.rank-no {
  flex: 0 0 auto;
  min-width: 30px;
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
}

.rank-name {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
}

.rank-name a {
  color: var(--text-main);
}

.rank-name a:hover {
  color: var(--accent);
}

.rank-note {
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

/* 字段口径对照表 */
.field-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel-bg);
}

.field-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-soft);
}

.field-row:last-child {
  border-bottom: 0;
}

.field-row-head {
  background: var(--panel-alt);
  font-weight: 600;
}

.field-name {
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.7;
}

.field-desc {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

/* 内页侧栏摘要 */
.aside-block {
  padding: 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.aside-block + .aside-block {
  margin-top: 16px;
}

.aside-title {
  margin-bottom: 8px;
  font-size: 16px;
  font-weight: 600;
}

.aside-text {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.aside-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.aside-item {
  position: relative;
  padding-left: 14px;
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.7;
}

.aside-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 5px;
  height: 5px;
  background: var(--accent);
  border-radius: 50%;
}

.aside-link {
  color: var(--accent);
  font-size: 13px;
}

/* 通用要点列表 */
.rule-list {
  display: grid;
  gap: 14px;
}

.rule-item {
  padding: 14px 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
}

.rule-name {
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 600;
}

.rule-text {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

/* 相关入口条 */
.related-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.related-card {
  display: block;
  padding: 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

.related-card:hover {
  border-color: var(--accent);
  background: var(--panel-alt);
}

.related-card-title,
.related-name {
  display: block;
  margin-bottom: 6px;
  color: var(--text-main);
  font-size: 15px;
  font-weight: 600;
}

.related-name a {
  color: var(--text-main);
}

.related-name a:hover {
  color: var(--accent);
}

.related-card-text,
.related-desc {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.related-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  padding: 14px 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.related-links-label {
  color: var(--text-sub);
  font-size: 14px;
  font-weight: 600;
}

.related-links-item {
  font-size: 14px;
}

/* FAQ 折叠条目 */
.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.faq-question {
  padding: 14px 16px;
  color: var(--text-main);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.6;
  cursor: pointer;
  list-style: none;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-question::after {
  content: "+";
  float: right;
  margin-left: 12px;
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-weight: 400;
}

.faq-item[open] .faq-question::after {
  content: "−";
}

.faq-item[open] .faq-question {
  border-bottom: 1px solid var(--border-soft);
}

.faq-answer {
  padding: 12px 16px 16px;
}

.faq-answer p {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.8;
}

/* 按钮（404） */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 20px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  background: #1b56c4;
  color: #ffffff;
}

.btn-ghost {
  background: var(--panel-bg);
  border-color: var(--border);
  color: var(--text-main);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* --------------------------------------------------------------------------
   pages：首页
   -------------------------------------------------------------------------- */
.home-main {
  width: 100%;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 420px);
  gap: 36px;
  align-items: center;
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 40px var(--gutter) 36px;
}

.hero-copy {
  min-width: 0;
}

.hero-title {
  margin-bottom: 14px;
  font-size: 32px;
  font-weight: 700;
  line-height: 1.3;
}

.hero-lead {
  max-width: 60ch;
  margin-bottom: 20px;
  color: var(--text-sub);
  font-size: 16px;
  line-height: 1.8;
}

.hero-paths {
  display: grid;
  gap: 10px;
  padding-top: 4px;
}

.hero-path {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  padding: 10px 14px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.hero-path-link {
  font-size: 15px;
  font-weight: 600;
}

.hero-path-note {
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

.hero-visual {
  min-width: 0;
  padding: 12px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.hero-visual img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: #eceff2;
}

.hero-caption {
  margin-top: 10px;
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

/* 题材方向总览 */
.genre-overview {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 8px var(--gutter) 32px;
}

.genre-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.genre-cell {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.genre-name {
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 600;
}

.genre-desc {
  flex: 1 1 auto;
  margin-bottom: 12px;
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.genre-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.genre-entry {
  font-size: 14px;
  font-weight: 600;
}

/* 封面速览 + 最近更新 并列区 */
.home-split {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: 32px;
  align-items: start;
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter) 32px;
}

.cover-board,
.update-brief,
.rank-brief,
.field-brief {
  min-width: 0;
  padding: 20px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

/* 人气榜单速览（首页左栏） */
.rank-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  padding: 10px 8px;
  border-bottom: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  transition: background-color 0.18s ease;
}

.rank-row:last-child {
  border-bottom: 0;
}

.rank-row:hover {
  background: var(--panel-alt);
}

.rank-row .rank-no {
  color: var(--rank-accent);
}

.rank-row .rank-name {
  margin-bottom: 2px;
}

.rank-genre {
  display: inline-block;
  margin-bottom: 4px;
  color: var(--text-faint);
  font-size: 12px;
}

.rank-row .rank-note {
  margin-top: 2px;
}

/* 条目字段口径摘要（首页右栏） */
.field-list {
  display: grid;
  gap: 0;
}

.field-list .field-row {
  grid-template-columns: 110px minmax(0, 1fr);
  padding: 10px 0;
}

.field-mean {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

/* 站内栏目索引 */
.site-index {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter) 8px;
}

.index-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.index-cell {
  min-width: 0;
  padding: 14px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

.index-cell:hover {
  border-color: var(--accent);
  background: var(--panel-alt);
}

.index-link {
  display: block;
  margin-bottom: 6px;
  color: var(--text-main);
  font-size: 15px;
  font-weight: 600;
}

.index-link:hover {
  color: var(--accent);
}

.index-desc {
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   pages：题材分类页
   -------------------------------------------------------------------------- */
.genre-group-list {
  display: grid;
  gap: 16px;
  margin-bottom: 32px;
}

.genre-group {
  padding: 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.genre-group-head {
  margin-bottom: 10px;
}

.genre-group-name {
  margin-bottom: 4px;
  font-size: 17px;
  font-weight: 600;
}

.genre-group-desc {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.genre-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.genre-tag {
  display: inline-block;
  padding: 3px 10px;
  background: var(--accent-soft);
  border: 1px solid #cfe0fb;
  border-radius: var(--radius-sm);
  color: #1b56c4;
  font-size: 13px;
  line-height: 1.6;
}

.genre-notes {
  margin-bottom: 32px;
}

.genre-note {
  padding: 14px 0;
  border-bottom: 1px solid var(--border-soft);
}

.genre-note:last-child {
  border-bottom: 0;
}

.genre-note-title {
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 600;
}

.genre-note-text {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.genre-picks {
  margin-bottom: 32px;
}

.genre-pick-group + .genre-pick-group {
  margin-top: 20px;
}

.genre-pick-heading {
  margin-bottom: 12px;
  font-size: 16px;
  font-weight: 600;
}

.genre-rules {
  margin-bottom: 8px;
}

.genre-rules .rule-list {
  margin-top: 4px;
}

/* --------------------------------------------------------------------------
   pages：最近更新页
   -------------------------------------------------------------------------- */
.content-section {
  margin-bottom: 36px;
}

.content-media {
  margin-bottom: 18px;
  padding: 10px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.content-media img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: #eceff2;
}

.content-media figcaption {
  margin-top: 8px;
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

.date-group {
  margin-bottom: 20px;
}

.date-group-title {
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 600;
}

.update-rows {
  display: grid;
  gap: 2px;
}

.updates-list-section .update-row {
  grid-template-columns: 96px minmax(0, 1fr) 90px minmax(0, 1.3fr);
  align-items: baseline;
}

.update-note {
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

.content-aside {
  min-width: 0;
}

.updates-aside .aside-block + .aside-block {
  margin-top: 16px;
}

.genre-tally {
  display: grid;
  gap: 6px;
  margin-top: 10px;
}

.genre-tally-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px dashed var(--border-soft);
  font-size: 13px;
}

.genre-tally-row:last-child {
  border-bottom: 0;
}

.genre-tally-name {
  color: var(--text-sub);
}

.genre-tally-count {
  color: var(--text-main);
  font-family: var(--font-mono);
  font-weight: 600;
}

.field-rule-section .field-table {
  margin-top: 4px;
}

.rhythm-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.rhythm-card {
  min-width: 0;
  padding: 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
}

.rhythm-card-title {
  margin-bottom: 8px;
  font-size: 15px;
  font-weight: 600;
}

.rhythm-card-text {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

/* --------------------------------------------------------------------------
   pages：人气榜单页
   -------------------------------------------------------------------------- */
.rank-section,
.rank-method,
.rank-distribution,
.rank-related {
  margin-bottom: 36px;
}

.rank-list .rank-item {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 12px 10px;
  border-bottom: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  transition: background-color 0.18s ease;
}

.rank-list .rank-item:hover {
  background: var(--panel-alt);
}

.rank-list .rank-top {
  grid-template-columns: 36px 96px minmax(0, 1fr);
  align-items: center;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  margin-bottom: 6px;
}

.rank-list .rank-top:hover {
  background: var(--panel-bg);
  border-color: var(--accent);
}

.rank-list .rank-top .rank-no {
  color: var(--rank-accent);
  font-size: 18px;
}

.rank-cover {
  min-width: 0;
}

.rank-cover img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: #eceff2;
}

.rank-body {
  min-width: 0;
}

.rank-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 4px 0 6px;
}

.method-list {
  display: grid;
  gap: 14px;
}

.method-item {
  padding: 14px 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.method-name {
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 600;
}

.method-item p {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.dist-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel-bg);
}

.dist-row {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-soft);
}

.dist-row:last-child {
  border-bottom: 0;
}

.dist-key {
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
}

.dist-value {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

/* --------------------------------------------------------------------------
   pages：阅读说明页
   -------------------------------------------------------------------------- */
.section-fields,
.section-tags,
.section-rules,
.section-faq,
.section-boundary {
  margin-bottom: 36px;
}

.field-figure {
  margin-bottom: 18px;
  padding: 10px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.field-figure img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: #eceff2;
}

.field-figure figcaption {
  margin-top: 8px;
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.65;
}

.tag-rule-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.tag-rule-item {
  padding: 14px 16px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

.boundary-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel-bg);
}

.boundary-row {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-soft);
}

.boundary-row:last-child {
  border-bottom: 0;
}

.boundary-name {
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.7;
}

.boundary-path {
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.75;
}

/* --------------------------------------------------------------------------
   pages：404
   -------------------------------------------------------------------------- */
.error-main {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 60px var(--gutter);
}

.error-panel {
  width: 100%;
  max-width: 640px;
  padding: 32px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
}

.error-code {
  margin-bottom: 8px;
  color: var(--rank-accent);
  font-family: var(--font-mono);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.1;
}

.error-title {
  margin-bottom: 12px;
  font-size: 24px;
  font-weight: 700;
}

.error-text {
  margin-bottom: 22px;
  color: var(--text-sub);
  font-size: 15px;
  line-height: 1.75;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 22px;
}

.error-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--border-soft);
}

.error-links a {
  font-size: 14px;
}

/* --------------------------------------------------------------------------
   responsive：平板与手机
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 340px);
    gap: 26px;
  }

  .hero-visual img {
    height: 280px;
  }

  .genre-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-split {
    grid-template-columns: minmax(0, 1fr);
  }

  .index-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .page-layout,
  .layout-main-aside {
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 24px;
  }

  .rhythm-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    display: block;
    padding: 0 var(--gutter);
    background: var(--panel-bg);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 6px 14px rgba(31, 35, 40, 0.08);
  }

  .nav-list {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0 14px;
  }

  .nav-list.is-open {
    display: flex;
  }

  .nav-link {
    padding: 12px 10px;
    min-height: 44px;
    display: flex;
    align-items: center;
    font-size: 16px;
    border-radius: var(--radius-sm);
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    padding-top: 28px;
  }

  .hero-visual {
    order: 2;
  }

  .hero-copy {
    order: 1;
  }

  .hero-visual img {
    height: 240px;
  }

  .page-layout,
  .layout-main-aside {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  .layout-aside,
  .content-aside {
    order: -1;
  }

  .updates-list-section .update-row {
    grid-template-columns: 92px minmax(0, 1fr);
    row-gap: 4px;
  }

  .updates-list-section .update-genre {
    grid-column: 2;
  }

  .updates-list-section .update-note {
    grid-column: 2;
  }

  .tag-rule-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .rhythm-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  .site-factbar {
    font-size: 12px;
    padding: 8px 14px;
  }

  .brand {
    font-size: 18px;
  }

  .hero {
    padding: 22px var(--gutter) 26px;
  }

  .hero-title {
    font-size: 23px;
  }

  .hero-lead {
    font-size: 15px;
  }

  .hero-visual img {
    height: 200px;
  }

  .genre-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .cover-grid,
  .cover-grid-three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cover-img {
    height: 140px;
  }

  .index-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-title {
    font-size: 23px;
  }

  .section-title,
  .section-head h2 {
    font-size: 19px;
  }

  .update-row {
    grid-template-columns: 84px minmax(0, 1fr);
    row-gap: 2px;
  }

  .update-row .update-genre {
    grid-column: 2;
  }

  .updates-list-section .update-row {
    grid-template-columns: 84px minmax(0, 1fr);
  }

  .field-row,
  .field-list .field-row,
  .dist-row,
  .boundary-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }

  .related-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .rank-list .rank-top {
    grid-template-columns: 32px 76px minmax(0, 1fr);
    gap: 10px;
  }

  .rank-cover img {
    height: 100px;
  }

  .footer-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    padding: 30px var(--gutter) 22px;
  }

  .error-panel {
    padding: 24px 18px;
  }

  .error-code {
    font-size: 34px;
  }
}

@media (max-width: 420px) {
  .cover-grid,
  .cover-grid-three {
    grid-template-columns: minmax(0, 1fr);
  }

  .cover-img {
    height: 170px;
  }

  .index-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}
