/* ==========================================================================
   ouszs.com — 哔哩漫画
   报纸编辑风：墨黑 / 纸白 / 细分隔线 / 衬线标题 + 无衬线正文
   分组：base · layout · components · pages · responsive
   ========================================================================== */

/* --------------------------------------------------------------------------
   base
   -------------------------------------------------------------------------- */

:root {
  --ink: #14131a;
  --paper: #faf9f6;
  --paper-soft: #f2efe9;
  --rule: #d8d3c9;
  --muted: #5b5860;
  --accent: #a3352b;
  --serif: "Songti SC", "SimSun", "Source Han Serif SC", "Noto Serif SC", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --container: 1200px;
  --main-col: 800px;
  --side-col: 320px;
  --gutter: 40px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--ink);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  color: var(--ink);
  font-weight: 700;
  line-height: 1.35;
  margin: 0 0 0.6em;
}

h1 {
  font-size: 32px;
}

h2 {
  font-size: 20px;
}

h3 {
  font-size: 17px;
}

p {
  margin: 0 0 1em;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

figure {
  margin: 0;
}

figcaption {
  font-size: 14px;
  color: var(--muted);
  margin-top: 8px;
  line-height: 1.6;
}

table {
  border-collapse: collapse;
  width: 100%;
}

button {
  font: inherit;
  color: inherit;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 200;
  transform: translateY(-120%);
  background: var(--ink);
  color: var(--paper);
  padding: 10px 18px;
  font-size: 14px;
  border-radius: 0 0 6px 0;
}

.skip-link:focus {
  transform: translateY(0);
  color: var(--paper);
  text-decoration: none;
}

/* --------------------------------------------------------------------------
   layout — 骨架：container / 页头 / 导航 / 主体 / 页脚
   -------------------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.site-body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
}

/* 页头（报头） */

.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
}

.header-brand {
  border-bottom: 3px double var(--ink);
}

.header-brand-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 72px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand-logo {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.brand-logo:hover {
  color: var(--accent);
  text-decoration: none;
}

.brand-slogan {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
  border-left: 1px solid var(--rule);
  padding-left: 20px;
  line-height: 1.5;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  min-width: 44px;
  min-height: 44px;
  padding: 0 14px;
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
}

.nav-toggle:hover {
  border-color: var(--ink);
}

/* 主导航 */

.site-nav {
  background: var(--paper);
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0;
}

.nav-list > li {
  display: flex;
}

.nav-list a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 20px;
  font-size: 15px;
  color: var(--ink);
  border-bottom: 3px solid transparent;
}

.nav-list > li:first-child a {
  padding-left: 0;
}

.nav-list a:hover,
.nav-list a:focus-visible {
  color: var(--accent);
  text-decoration: none;
  border-bottom-color: var(--rule);
}

.nav-list a.is-current {
  color: var(--ink);
  font-weight: 700;
  border-bottom-color: var(--accent);
}

/* 主体 */

.site-main {
  display: block;
  padding: 0 0 56px;
}

.inner-main {
  padding-top: 0;
}

/* 面包屑（内页统一） */

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--muted);
  padding: 18px 0 0;
}

.breadcrumb a {
  color: var(--muted);
}

.breadcrumb a:hover {
  color: var(--accent);
}

.breadcrumb-sep {
  color: var(--rule);
}

.breadcrumb-current {
  color: var(--ink);
}

/* 页标题区（内页统一） */

.page-header {
  border-bottom: 1px solid var(--rule);
  padding: 14px 0 18px;
  margin-bottom: 0;
}

.page-title {
  font-family: var(--serif);
  font-size: 32px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--ink);
  margin: 0;
}

.page-title-section,
.page-hero,
.page-head {
  padding: 18px 0 0;
}

.page-lede,
.page-lead {
  font-size: 16px;
  color: var(--ink);
  max-width: 76ch;
  margin: 0 0 10px;
}

.page-meta {
  font-size: 14px;
  color: var(--muted);
  border-top: 1px solid var(--rule);
  padding-top: 10px;
  margin: 0;
}

/* 通用页面布局：主栏在前，侧栏在后 */

.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--side-col);
  gap: var(--gutter);
  align-items: start;
  padding-top: 28px;
}

.page-layout > .main-column,
.page-layout > .page-content,
.page-layout > .page-main,
.page-layout > .content-main {
  min-width: 0;
}

.page-layout > .side-column,
.page-layout > .page-sidebar,
.page-layout > .page-aside,
.page-layout > .content-side {
  min-width: 0;
}

/* 页脚 */

.site-footer {
  border-top: 3px double var(--ink);
  background: var(--paper-soft);
  color: var(--ink);
  font-size: 15px;
  margin-top: 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.4fr;
  gap: var(--gutter);
  padding-top: 40px;
  padding-bottom: 32px;
}

.footer-title {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--rule);
}

.footer-about p,
.footer-note p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
  margin: 0 0 12px;
}

.footer-nav ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 18px;
}

.footer-nav a {
  font-size: 14px;
  color: var(--ink);
  display: inline-block;
  padding: 2px 0;
}

.footer-copy {
  border-top: 1px solid var(--rule);
  padding-top: 12px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   components — 通用模块
   -------------------------------------------------------------------------- */

/* 栏目标题头（标题 + 右侧入口） */

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 8px;
  margin-bottom: 14px;
}

.section-head h2,
.section-head .section-title,
.section-head h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 700;
}

.section-more {
  font-size: 14px;
  color: var(--muted);
  white-space: nowrap;
}

.section-more:hover {
  color: var(--accent);
}

.section-title {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--rule);
}

.section-note,
.section-desc,
.section-intro {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
  margin: 0 0 16px;
}

.group-title {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--rule);
}

/* 条目行 */

.entry-list {
  display: block;
}

.entry-row {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 2fr) auto auto auto;
  gap: 10px 16px;
  align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px dotted var(--rule);
  font-size: 15px;
}

.entry-row:last-child {
  border-bottom: 0;
}

.entry-title {
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}

.entry-genre,
.entry-feature,
.entry-note,
.entry-trait {
  color: var(--muted);
  font-size: 14px;
  min-width: 0;
}

.entry-status,
.entry-rhythm,
.entry-volume {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

.entry-status.is-ongoing,
.status-ongoing {
  color: var(--accent);
}

.entry-status.is-paused,
.status-hiatus {
  color: var(--muted);
}

.entry-status.is-finished,
.status-completed {
  color: var(--ink);
}

.entry-link {
  display: inline-block;
  font-size: 15px;
  padding: 6px 14px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  margin-right: 10px;
  margin-bottom: 8px;
}

.entry-link:hover {
  border-color: var(--ink);
  text-decoration: none;
  color: var(--accent);
}

/* 榜单条目 */

.rank-list {
  display: block;
}

.rank-list > li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dotted var(--rule);
  font-size: 15px;
}

.rank-list > li:last-child {
  border-bottom: 0;
}

.rank-no {
  font-family: var(--serif);
  font-size: 14px;
  color: var(--accent);
  min-width: 22px;
  font-weight: 700;
}

.rank-genre {
  color: var(--ink);
  min-width: 0;
}

/* 归档提示 */

.archive-hint,
.archive-note {
  margin-top: 18px;
  padding: 14px 16px;
  background: var(--paper-soft);
  border-left: 3px solid var(--rule);
  font-size: 14px;
  color: var(--muted);
  border-radius: 0 6px 6px 0;
}

.archive-hint a,
.archive-note a {
  color: var(--accent);
}

/* 字段速查表 */

.field-table {
  width: 100%;
  font-size: 14px;
  border-top: 1px solid var(--rule);
}

.field-table caption {
  text-align: left;
}

.field-table th,
.field-table td {
  text-align: left;
  padding: 9px 10px;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}

.field-table thead th {
  font-family: var(--serif);
  font-size: 14px;
  color: var(--ink);
  background: var(--paper-soft);
  border-bottom: 1px solid var(--ink);
}

.field-table tbody th {
  color: var(--ink);
  font-weight: 700;
  white-space: nowrap;
  width: 30%;
}

.field-table tbody td {
  color: var(--muted);
}

/* 相关页面链接组 */

.related-links {
  margin-top: 32px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
}

.related-list,
.related-links ul {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
}

.related-list a,
.related-links a {
  font-size: 15px;
  color: var(--ink);
  border-bottom: 1px solid var(--rule);
  padding-bottom: 2px;
}

.related-list a:hover,
.related-links a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
  text-decoration: none;
}

/* 侧栏通用块 */

.side-block,
.sidebar-block,
.aside-block {
  padding: 16px 0;
  border-top: 1px solid var(--rule);
}

.side-block:first-child,
.sidebar-block:first-child,
.aside-block:first-child {
  border-top: 2px solid var(--ink);
}

.side-block h2,
.sidebar-block h2,
.aside-title {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 12px;
}

.side-links,
.side-link-list,
.aside-list,
.aside-links,
.legend-list {
  font-size: 14px;
}

.side-links li,
.side-link-list li,
.aside-list li,
.aside-links li,
.legend-list li {
  padding: 7px 0;
  border-bottom: 1px dotted var(--rule);
  color: var(--muted);
  line-height: 1.65;
}

.side-links li:last-child,
.side-link-list li:last-child,
.aside-list li:last-child,
.aside-links li:last-child,
.legend-list li:last-child {
  border-bottom: 0;
}

.aside-link a {
  color: var(--accent);
}

/* 图片容器统一约束 */

.hero-figure,
.genre-media,
.article-media,
.ranking-feature,
.compare-figure,
.guide-figure,
.content-figure {
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--paper-soft);
}

.hero-figure img,
.genre-media img,
.article-media img,
.ranking-feature img,
.compare-figure img,
.guide-figure img,
.content-figure img,
.genre-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --------------------------------------------------------------------------
   pages — 首页
   -------------------------------------------------------------------------- */

/* 分区地图首屏 */

.hero {
  border-bottom: 3px double var(--ink);
  padding: 32px 0 36px;
  background: var(--paper);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: var(--gutter);
  align-items: start;
}

.hero-visual {
  min-width: 0;
}

.hero-visual h1 {
  font-size: 34px;
  line-height: 1.3;
  margin: 0 0 12px;
}

.hero-lead {
  font-size: 16px;
  color: var(--muted);
  max-width: 60ch;
  margin: 0 0 20px;
}

.hero-figure {
  margin: 0;
}

.hero-figure img {
  width: 100%;
  height: 340px;
  object-fit: cover;
}

.hero-index {
  min-width: 0;
  padding-left: 24px;
  border-left: 1px solid var(--rule);
}

.hero-index .section-title {
  font-size: 18px;
}

.genre-index-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: 6px;
  overflow: hidden;
}

.genre-index-item {
  background: var(--paper);
}

.genre-index-item a {
  display: block;
  padding: 12px 10px;
  font-size: 15px;
  font-family: var(--serif);
  font-weight: 700;
  text-align: center;
  min-height: 44px;
}

.genre-index-item a:hover {
  background: var(--paper-soft);
  color: var(--accent);
  text-decoration: none;
}

.hero-entries {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}

/* 首页主体：最近更新主栏 + 榜单侧栏 */

.home-main .page-layout {
  padding-top: 36px;
}

.updates-column {
  min-width: 0;
}

.update-group {
  margin-bottom: 26px;
}

.update-group .entry-list {
  border-top: 1px solid var(--rule);
}

.ranking-aside {
  min-width: 0;
  padding-left: 24px;
  border-left: 1px solid var(--rule);
}

.aside-group {
  margin-bottom: 22px;
}

/* 题材分区地图 */

.genre-map {
  border-top: 1px solid var(--rule);
  padding: 40px 0;
  background: var(--paper-soft);
}

.genre-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

.genre-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.genre-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.genre-card h3 {
  font-size: 17px;
  margin: 14px 14px 8px;
}

.genre-card p {
  font-size: 14px;
  color: var(--muted);
  margin: 0 14px 10px;
  line-height: 1.65;
}

.genre-card .genre-card-field {
  font-size: 13px;
  color: var(--muted);
  border-top: 1px solid var(--rule);
  padding: 10px 14px 0;
  margin: auto 0 0;
}

.genre-card a {
  display: block;
  padding: 10px 14px 14px;
  font-size: 14px;
  color: var(--accent);
}

.genre-card a:hover {
  text-decoration: underline;
}

/* 推荐榜单三栏 */

.ranking-board {
  padding: 40px 0;
  border-top: 1px solid var(--rule);
}

.ranking-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--gutter);
}

.ranking-column {
  min-width: 0;
  border-top: 2px solid var(--ink);
  padding-top: 14px;
}

.ranking-column .rank-list {
  border-top: 1px solid var(--rule);
}

/* 作品对照入口 */

.compare-entry {
  border-top: 1px solid var(--rule);
  padding: 40px 0;
  background: var(--paper-soft);
}

.field-sample-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 20px;
}

.field-sample {
  background: var(--paper);
  padding: 16px;
}

.field-name {
  display: block;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.field-desc {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.65;
}

.compare-entry-link {
  margin: 0;
  font-size: 15px;
}

.compare-entry-link a {
  color: var(--accent);
  font-weight: 700;
}

/* 阅读指南与版权说明双栏 */

.guide-license {
  border-top: 1px solid var(--rule);
  padding: 40px 0;
}

.guide-license .section-title {
  margin-bottom: 22px;
}

.guide-license-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gutter);
}

.guide-summary,
.license-summary {
  min-width: 0;
  border-top: 2px solid var(--ink);
  padding-top: 14px;
}

.summary-list {
  font-size: 15px;
}

.summary-list li {
  padding: 9px 0;
  border-bottom: 1px dotted var(--rule);
  color: var(--muted);
  line-height: 1.7;
}

.summary-list li:last-child {
  border-bottom: 0;
}

.summary-link {
  margin: 14px 0 0;
  font-size: 15px;
}

.summary-link a {
  color: var(--accent);
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   pages — 题材分区
   -------------------------------------------------------------------------- */

.genre-filter {
  border-top: 2px solid var(--ink);
  padding-top: 16px;
  margin-bottom: 34px;
}

.genre-filter h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.genre-filter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: 6px;
  overflow: hidden;
}

.genre-filter-item {
  background: var(--paper);
  padding: 14px;
}

.genre-filter-item h3 {
  font-size: 16px;
  margin: 0 0 6px;
}

.genre-filter-item p {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 8px;
  line-height: 1.6;
}

.genre-filter-item .field-line {
  font-size: 13px;
  color: var(--accent);
  border-top: 1px dotted var(--rule);
  padding-top: 8px;
  margin: 0;
}

.genre-block {
  margin-bottom: 36px;
  padding-top: 4px;
}

.genre-media {
  margin-bottom: 16px;
}

.genre-media img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.genre-block .entry-list {
  border-top: 1px solid var(--rule);
}

.genre-block .entry-row {
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 2fr) auto auto auto;
}

/* --------------------------------------------------------------------------
   pages — 更新连载
   -------------------------------------------------------------------------- */

.page-layout-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--side-col);
  gap: var(--gutter);
  align-items: start;
  padding-top: 28px;
}

.page-content {
  min-width: 0;
}

.article-media {
  margin: 18px 0 26px;
}

.article-media img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.update-group .section-head {
  border-bottom: 2px solid var(--ink);
}

.update-group .section-head h2 {
  font-size: 20px;
}

.update-group .entry-row {
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.6fr) auto auto auto;
}

.archive-hint {
  margin-top: 26px;
}

.archive-hint h2 {
  font-family: var(--serif);
  font-size: 17px;
  margin: 0 0 8px;
  color: var(--ink);
}

.archive-hint p {
  margin: 0 0 8px;
}

.archive-hint p:last-child {
  margin-bottom: 0;
}

.page-sidebar {
  min-width: 0;
}

.legend-item {
  display: block;
}

/* --------------------------------------------------------------------------
   pages — 推荐榜单
   -------------------------------------------------------------------------- */

.layout-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  max-width: var(--main-col);
  margin: 0 auto;
  padding: 28px 24px 0;
}

.content-main {
  min-width: 0;
}

.ranking-criteria {
  border-top: 2px solid var(--ink);
  padding-top: 16px;
  margin-bottom: 40px;
}

.ranking-criteria .section-head {
  border-bottom: 0;
  padding-bottom: 0;
  margin-bottom: 16px;
}

.ranking-criteria .section-head h2 {
  font-size: 20px;
}

.ranking-criteria .section-head p {
  font-size: 14px;
  color: var(--muted);
  margin: 0;
  max-width: 46ch;
}

.criteria-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: 6px;
  overflow: hidden;
}

.criteria-item {
  background: var(--paper);
  padding: 16px;
}

.criteria-item h3 {
  font-size: 16px;
  margin: 0 0 8px;
}

.criteria-item p {
  font-size: 14px;
  color: var(--muted);
  margin: 0;
  line-height: 1.7;
}

.ranking-block {
  margin-bottom: 44px;
}

.ranking-block .section-head {
  border-bottom: 2px solid var(--ink);
}

.ranking-block .section-head h2 {
  font-size: 20px;
}

.ranking-block .section-head p {
  font-size: 14px;
  color: var(--muted);
  margin: 0;
  max-width: 50ch;
}

.ranking-feature {
  margin: 18px 0 22px;
}

.ranking-feature img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.ranking-list {
  border-top: 1px solid var(--rule);
}

.ranking-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
}

.rank-index {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.rank-body {
  min-width: 0;
  font-size: 15px;
  color: var(--ink);
  line-height: 1.7;
}

.rank-tag {
  font-size: 13px;
  color: var(--muted);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 3px 10px;
  white-space: nowrap;
}

.ranking-outside {
  border-top: 1px solid var(--rule);
  padding-top: 22px;
  margin-bottom: 10px;
}

.ranking-outside .section-head {
  border-bottom: 0;
  padding-bottom: 0;
  margin-bottom: 14px;
}

.ranking-outside .section-head h2 {
  font-size: 20px;
}

.ranking-outside .section-head p {
  font-size: 14px;
  color: var(--muted);
  margin: 0;
  max-width: 50ch;
}

.outside-body p {
  font-size: 15px;
  color: var(--muted);
  max-width: 72ch;
}

.outside-list {
  border-top: 1px solid var(--rule);
}

.outside-list li {
  padding: 12px 0;
  border-bottom: 1px dotted var(--rule);
  font-size: 15px;
  color: var(--ink);
  line-height: 1.75;
}

.outside-list li:last-child {
  border-bottom: 0;
}

/* --------------------------------------------------------------------------
   pages — 作品对照
   -------------------------------------------------------------------------- */

.compare-intro {
  border-top: 2px solid var(--ink);
  padding-top: 16px;
  margin-bottom: 34px;
}

.compare-intro h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.compare-field-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: 6px;
  overflow: hidden;
  margin-top: 16px;
}

.compare-field {
  background: var(--paper);
  padding: 14px;
}

.compare-field .field-name {
  font-size: 16px;
  margin-bottom: 6px;
}

.compare-field .field-meaning {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
  line-height: 1.65;
}

.compare-diagram {
  margin-bottom: 34px;
}

.compare-diagram h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.compare-figure img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.compare-table-section {
  margin-bottom: 30px;
}

.compare-table-section h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.compare-table-scroll {
  overflow-x: auto;
  border: 1px solid var(--rule);
  border-radius: 6px;
  -webkit-overflow-scrolling: touch;
}

.compare-table {
  min-width: 640px;
  font-size: 14px;
  background: var(--paper);
}

.compare-table caption {
  text-align: left;
  padding: 10px 12px;
  font-size: 13px;
  color: var(--muted);
  border-bottom: 1px solid var(--rule);
}

.compare-table th,
.compare-table td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  text-align: left;
  vertical-align: top;
  line-height: 1.7;
}

.compare-table th:last-child,
.compare-table td:last-child {
  border-right: 0;
}

.compare-table thead th {
  font-family: var(--serif);
  font-size: 14px;
  background: var(--paper-soft);
  border-bottom: 1px solid var(--ink);
  min-width: 130px;
}

.compare-table tbody th {
  font-family: var(--serif);
  font-size: 14px;
  background: var(--paper-soft);
  white-space: nowrap;
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 110px;
}

.compare-table tbody td {
  color: var(--muted);
}

.compare-table img {
  width: 100%;
  max-width: 120px;
  height: 76px;
  object-fit: cover;
  border: 1px solid var(--rule);
  border-radius: 4px;
  margin-bottom: 8px;
}

.compare-limit {
  border-top: 1px solid var(--rule);
  padding-top: 18px;
  margin-bottom: 34px;
}

.compare-limit h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.limit-note {
  font-size: 15px;
  color: var(--ink);
  background: var(--paper-soft);
  border-left: 3px solid var(--accent);
  border-radius: 0 6px 6px 0;
  padding: 12px 16px;
  margin: 0 0 14px;
}

.limit-steps {
  counter-reset: limit;
}

.limit-steps li {
  position: relative;
  padding: 8px 0 8px 30px;
  border-bottom: 1px dotted var(--rule);
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
  counter-increment: limit;
}

.limit-steps li:last-child {
  border-bottom: 0;
}

.limit-steps li::before {
  content: counter(limit);
  position: absolute;
  left: 0;
  top: 8px;
  width: 20px;
  height: 20px;
  line-height: 20px;
  text-align: center;
  font-size: 12px;
  font-family: var(--serif);
  color: var(--paper);
  background: var(--ink);
  border-radius: 50%;
}

.watchlist-section {
  margin-bottom: 10px;
}

.watchlist-section h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.watchlist-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 24px;
  border-top: 1px solid var(--rule);
}

.watchlist-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px dotted var(--rule);
  min-height: 44px;
}

.watchlist-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  cursor: pointer;
  min-width: 0;
}

.watchlist-check {
  width: 18px;
  height: 18px;
  flex: none;
  accent-color: var(--accent);
}

.watchlist-name {
  min-width: 0;
}

.watchlist-genre {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

.page-aside {
  min-width: 0;
}

.aside-text {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
  margin: 0 0 10px;
}

/* --------------------------------------------------------------------------
   pages — 阅读指南
   -------------------------------------------------------------------------- */

.page-head {
  padding-top: 18px;
}

.guide-path {
  border-top: 2px solid var(--ink);
  padding-top: 16px;
  margin-bottom: 40px;
}

.guide-path h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.guide-figure {
  margin: 0 0 22px;
}

.guide-figure img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

.path-steps {
  counter-reset: path;
  border-top: 1px solid var(--rule);
}

.path-step {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
  counter-increment: path;
}

.path-step .step-no {
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.2;
}

.path-step .step-no::before {
  content: counter(path, decimal-leading-zero);
}

.path-step .step-body {
  min-width: 0;
  font-size: 15px;
  color: var(--muted);
  line-height: 1.75;
}

.path-step .step-body a {
  color: var(--accent);
}

.field-table-block {
  margin-bottom: 40px;
}

.field-table-block h2,
.reading-rules h2,
.faq-block h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 10px;
}

.reading-rules {
  margin-bottom: 40px;
}

.rule-list {
  border-top: 1px solid var(--rule);
}

.rule-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
  font-size: 15px;
  color: var(--ink);
  line-height: 1.75;
}

.rule-list li:last-child {
  border-bottom: 0;
}

.faq-block {
  margin-bottom: 20px;
}

.faq-item {
  border-bottom: 1px solid var(--rule);
  padding: 4px 0;
}

.faq-item summary {
  cursor: pointer;
  padding: 12px 30px 12px 0;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  position: relative;
  list-style: none;
  min-height: 44px;
  display: flex;
  align-items: center;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: var(--muted);
  line-height: 1;
}

.faq-item[open] summary::after {
  content: "−";
  color: var(--accent);
}

.faq-item p {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.75;
  margin: 0 0 14px;
  padding-right: 20px;
}

.content-side {
  min-width: 0;
}

.inline-link {
  color: var(--accent);
}

/* --------------------------------------------------------------------------
   pages — 版权说明
   -------------------------------------------------------------------------- */

.page-title-block {
  padding-top: 18px;
}

.content-figure {
  margin: 18px 0 30px;
}

.content-figure img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.content-section {
  margin-bottom: 36px;
  padding-top: 4px;
}

.content-section h2 {
  font-family: var(--serif);
  font-size: 20px;
  margin: 0 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--rule);
}

.content-section > p {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.8;
  max-width: 72ch;
}

.section-link {
  font-size: 15px;
  margin: 14px 0 0;
}

.section-link a {
  color: var(--accent);
  margin-right: 18px;
}

/* --------------------------------------------------------------------------
   pages — 404
   -------------------------------------------------------------------------- */

.error-main {
  padding: 60px 0 80px;
}

.error-panel {
  max-width: 640px;
  border-top: 3px double var(--ink);
  padding-top: 24px;
}

.error-panel h1 {
  font-size: 32px;
  margin: 0 0 14px;
}

.error-panel p {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.8;
  max-width: 60ch;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.error-actions a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  font-size: 15px;
}

.error-actions a:hover {
  border-color: var(--ink);
  color: var(--accent);
  text-decoration: none;
}

.error-actions a.error-home {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

.error-actions a.error-home:hover {
  color: var(--paper);
  background: var(--accent);
  border-color: var(--accent);
}

/* 滚动出现（增强，不影响初始可见性） */

.reveal {
  animation: reveal-up 0.5s ease both;
}

@keyframes reveal-up {
  from {
    transform: translateY(12px);
  }
  to {
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    animation: none;
  }

  * {
    scroll-behavior: auto !important;
  }
}

/* --------------------------------------------------------------------------
   responsive — 1024 / 900 / 768 / 480
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {
  :root {
    --gutter: 28px;
  }

  h1,
  .page-title {
    font-size: 28px;
  }

  .hero-visual h1 {
    font-size: 28px;
  }

  .genre-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .genre-filter-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-about {
    grid-column: 1 / -1;
  }
}

@media (max-width: 900px) {
  .page-layout,
  .page-layout-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .ranking-aside,
  .hero-index {
    padding-left: 0;
    border-left: 0;
    padding-top: 22px;
    border-top: 1px solid var(--rule);
  }

  .ranking-columns {
    grid-template-columns: minmax(0, 1fr);
  }

  .criteria-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .compare-field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .field-sample-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .header-brand-inner {
    min-height: 64px;
    flex-wrap: wrap;
    gap: 12px;
  }

  .brand-slogan {
    border-left: 0;
    padding-left: 0;
    flex-basis: 100%;
    order: 3;
    font-size: 13px;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-list {
    display: none;
    flex-direction: column;
    border-top: 1px solid var(--rule);
  }

  .nav-list.is-open {
    display: flex;
  }

  .nav-list > li {
    width: 100%;
  }

  .nav-list a {
    width: 100%;
    min-height: 48px;
    padding: 0 4px;
    border-bottom: 1px solid var(--rule);
    border-left: 3px solid transparent;
  }

  .nav-list > li:first-child a {
    padding-left: 4px;
  }

  .nav-list a:hover,
  .nav-list a:focus-visible {
    border-bottom-color: var(--rule);
  }

  .nav-list a.is-current {
    border-bottom-color: var(--rule);
    border-left-color: var(--accent);
    padding-left: 10px;
  }

  h1,
  .page-title {
    font-size: 24px;
  }

  .hero-visual h1 {
    font-size: 24px;
  }

  .hero {
    padding: 24px 0 28px;
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-figure img {
    height: 220px;
  }

  .genre-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .genre-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .guide-license-columns {
    grid-template-columns: minmax(0, 1fr);
  }

  .entry-row,
  .genre-block .entry-row,
  .update-group .entry-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
    padding: 12px 0;
  }

  .entry-status,
  .entry-rhythm,
  .entry-volume {
    display: inline-block;
    margin-right: 14px;
  }

  .ranking-row {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
  }

  .rank-tag {
    grid-column: 2;
    justify-self: start;
  }

  .ranking-feature img,
  .guide-figure img,
  .content-figure img,
  .compare-figure img,
  .article-media img {
    height: 210px;
  }

  .watchlist-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 26px;
    padding-top: 30px;
  }

  .footer-about {
    grid-column: auto;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .layout-shell {
    padding: 24px 16px 0;
  }

  .hero-index .section-title,
  .section-title,
  .section-head h2 {
    font-size: 18px;
  }

  .genre-index-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .genre-card-grid,
  .genre-filter-grid,
  .compare-field-grid,
  .field-sample-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .genre-card img {
    height: 170px;
  }

  .hero-figure img {
    height: 190px;
  }

  .ranking-feature img,
  .guide-figure img,
  .content-figure img,
  .compare-figure img,
  .article-media img,
  .genre-media img {
    height: 190px;
  }

  .entry-link {
    display: block;
    margin-right: 0;
    text-align: center;
  }

  .path-step {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 12px;
  }

  .path-step .step-no {
    font-size: 20px;
  }

  .compare-table {
    min-width: 560px;
  }

  .error-panel h1 {
    font-size: 24px;
  }
}
