:root {
  --ink: #1f2328;
  --muted: #656d76;
  --line: #d8dee4;
  --paper: #fffdf8;
  --paper-2: #f6f8fa;
  --brand: #0f766e;
  --hot: #c2410c;
  --blue: #2563eb;
  --rose: #be123c;
  --shadow: 0 14px 34px rgba(31, 35, 40, .10);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  line-height: 1.65;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 253, 248, .94);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: 1240px;
  margin: 0 auto;
  min-height: 70px;
  padding: 0 22px;
  display: flex;
  align-items: center;
  gap: 22px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 21px;
  white-space: nowrap;
}
.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--hot));
}
.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-link, .search-link {
  padding: 9px 12px;
  border-radius: 8px;
  color: #3b424a;
  font-size: 15px;
  white-space: nowrap;
}
.nav-link.active, .nav-link:hover, .search-link:hover {
  background: #eaf4f2;
  color: var(--brand);
}
.search-link {
  border: 1px solid var(--line);
  background: #fff;
}
.hero {
  max-width: 1240px;
  margin: 0 auto;
  min-height: 620px;
  padding: 58px 22px 34px;
  display: grid;
  grid-template-columns: minmax(320px, 430px) 1fr;
  gap: 34px;
  align-items: center;
}
.hero-copy h1, .page-title h1, .detail-info h1, .reader-top h1 {
  margin: 8px 0 14px;
  line-height: 1.1;
  letter-spacing: 0;
}
.hero-copy h1 { font-size: 56px; }
.hero-desc {
  margin: 0 0 24px;
  color: #3b424a;
  font-size: 18px;
}
.eyebrow {
  margin: 0;
  color: var(--hot);
  font-weight: 700;
  letter-spacing: 0;
}
.hero-actions, .reader-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.btn {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 8px;
  border: 1px solid var(--line);
  font-weight: 700;
}
.btn.primary {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}
.btn.ghost {
  background: #fff;
}
.hero-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.quick-tags {
  max-width: 1240px;
  margin: 0 auto 22px;
  padding: 0 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.quick-tags a {
  padding: 8px 12px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  color: #3b424a;
}
.section, .page-shell, .detail-shell, .reader-shell {
  max-width: 1240px;
  margin: 0 auto;
  padding: 36px 22px;
}
.section.soft {
  max-width: none;
  background: var(--paper-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section.soft > .section-head, .section.soft > .update-list {
  max-width: 1196px;
  margin-left: auto;
  margin-right: auto;
}
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.section-head h2, .page-title h1 {
  margin: 0 0 6px;
  font-size: 32px;
}
.section-head p, .page-title p {
  margin: 0;
  color: var(--muted);
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px;
}
.feature-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.library-grid {
  grid-template-columns: repeat(8, minmax(0, 1fr));
}
.small-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.comic-card {
  min-width: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(31,35,40,.06);
}
.cover-link {
  position: relative;
  display: block;
  aspect-ratio: 13 / 18;
  background: #eaeef2;
  overflow: hidden;
}
.cover-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .25s ease;
}
.comic-card:hover .cover-link img { transform: scale(1.04); }
.rank-badge {
  position: absolute;
  left: 8px;
  top: 8px;
  padding: 3px 8px;
  border-radius: 8px;
  color: #fff;
  background: var(--rose);
  font-size: 12px;
  font-weight: 800;
}
.card-body {
  padding: 10px 10px 12px;
}
.card-body h3 {
  margin: 0 0 4px;
  font-size: 16px;
  line-height: 1.35;
}
.card-body p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.card-meta {
  margin-top: 8px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: #4b5563;
  font-size: 12px;
}
.update-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.update-list.wide {
  grid-template-columns: 1fr;
}
.compact-item {
  display: grid;
  grid-template-columns: 54px 1fr 70px 70px 88px;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.compact-num {
  color: var(--hot);
  font-weight: 800;
}
.compact-title {
  font-weight: 800;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.seo-band {
  max-width: 1196px;
  margin: 44px auto 28px;
  padding: 30px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, #0f766e, #1d4ed8 52%, #c2410c);
}
.seo-band h2 {
  margin: 0 0 8px;
  font-size: 30px;
}
.seo-band p {
  margin: 0;
  max-width: 940px;
}
.page-title {
  padding: 26px 0 24px;
}
.page-title h1 {
  font-size: 42px;
}
.toolbar {
  margin-bottom: 24px;
  padding: 16px;
  display: grid;
  grid-template-columns: minmax(260px, 360px) 1fr;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.toolbar.single {
  grid-template-columns: 1fr;
}
.search-box {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}
.search-box input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 15px;
}
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.filter-btn {
  min-height: 36px;
  padding: 7px 11px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  color: #3b424a;
  cursor: pointer;
}
.filter-btn.active {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
}
.detail-hero {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 30px;
  align-items: center;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}
.detail-cover {
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 18px 40px rgba(31,35,40,.16);
}
.detail-info h1 {
  font-size: 44px;
}
.detail-info p {
  color: #3b424a;
}
.stats {
  margin: 18px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.stats span {
  padding: 8px 12px;
  border-radius: 8px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  font-weight: 700;
}
.chapter-section {
  padding-left: 0;
  padding-right: 0;
}
.chapter-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}
.chapter-grid a, .chapter-grid span {
  padding: 11px 12px;
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-weight: 700;
}
.chapter-grid span {
  color: var(--muted);
  background: var(--paper-2);
}
.reader-shell {
  max-width: 980px;
}
.reader-top {
  padding: 24px 0;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
}
.reader-top h1 {
  margin-bottom: 0;
  font-size: 34px;
}
.reader-pages {
  display: grid;
  gap: 14px;
}
.reader-pages img {
  width: 100%;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.reader-bottom {
  padding: 22px 0 46px;
  display: flex;
  justify-content: center;
  gap: 12px;
}
.site-footer {
  margin-top: 36px;
  padding: 38px 22px 28px;
  color: #e5e7eb;
  background: #20252b;
}
.footer-grid {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 28px;
}
.footer-grid p {
  margin: 8px 0 0;
  color: #c9d1d9;
}
.footer-grid h3 {
  margin: 0 0 8px;
  font-size: 16px;
}
.footer-grid a {
  display: block;
  color: #c9d1d9;
  margin: 4px 0;
}
.copyright {
  max-width: 1240px;
  margin: 26px auto 0;
  color: #9da7b1;
  font-size: 13px;
}
.is-hidden { display: none !important; }
@media (max-width: 1100px) {
  .hero { grid-template-columns: 1fr; }
  .library-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .card-grid, .feature-grid, .small-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 780px) {
  .header-inner { min-height: 64px; gap: 10px; padding: 0 14px; }
  .brand span:last-child { display: none; }
  .hero { padding: 34px 14px 20px; min-height: auto; }
  .hero-copy h1 { font-size: 40px; }
  .hero-panel { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .section, .page-shell, .detail-shell, .reader-shell { padding: 28px 14px; }
  .card-grid, .feature-grid, .small-grid, .library-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .update-list { grid-template-columns: 1fr; }
  .compact-item { grid-template-columns: 42px 1fr 56px; }
  .compact-item span:nth-child(4), .compact-item span:nth-child(5) { display: none; }
  .toolbar { grid-template-columns: 1fr; }
  .detail-hero { grid-template-columns: 1fr; padding: 16px; }
  .detail-cover { max-width: 260px; }
  .detail-info h1, .page-title h1 { font-size: 34px; }
  .chapter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .reader-top { display: grid; align-items: start; }
  .footer-grid { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  .hero-panel { grid-template-columns: 1fr 1fr; gap: 10px; }
  .card-body h3 { font-size: 15px; }
  .chapter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* variant 10 */
body.theme-0 {
  --brand: #0f766e;
  --hot: #c2410c;
  --blue: #2563eb;
  --rose: #be123c;
  --paper: #fffdf8;
  --paper-2: #f1f7f5;
}
body.theme-0 .site-header {
  border-bottom-color: color-mix(in srgb, var(--brand) 30%, var(--line));
}
body.theme-0 .brand-mark {
  background: linear-gradient(28deg, var(--brand), var(--hot) 48%, var(--blue));
}
body.theme-0 .hero {
  background:
    linear-gradient(28deg, color-mix(in srgb, var(--brand) 8%, transparent), transparent 42%),
    linear-gradient(83deg, color-mix(in srgb, var(--hot) 8%, transparent), transparent 48%);
  border-bottom: 1px solid color-mix(in srgb, var(--brand) 18%, var(--line));
}
body.layout-shelf.layout-shelf .hero-panel {
  grid-template-columns: 1.1fr .9fr 1.1fr;
  align-items: end;
}
body.layout-shelf.layout-magazine .hero {
  grid-template-columns: minmax(340px, 520px) 1fr;
}
body.layout-shelf.layout-magazine .hero-panel .comic-card:nth-child(1) {
  grid-column: span 2;
}
body.layout-shelf.layout-board .hero-panel {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
body.layout-shelf.layout-board .hero-panel .comic-card:nth-child(3) {
  grid-row: span 2;
}
body.layout-shelf.layout-ribbon .quick-tags a:nth-child(odd) {
  background: color-mix(in srgb, var(--brand) 14%, white);
  border-color: color-mix(in srgb, var(--brand) 28%, var(--line));
}
body.layout-shelf.layout-dense .library-grid {
  grid-template-columns: repeat(10, minmax(0, 1fr));
}
body.theme-0 .comic-card {
  border-color: color-mix(in srgb, var(--brand) 24%, var(--line));
}
body.theme-0 .seo-band {
  background: linear-gradient(48deg, var(--brand), var(--blue) 48%, var(--hot));
}
@media (max-width: 1100px) {
  body.layout-shelf.layout-dense .library-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (max-width: 780px) {
  body.layout-shelf.layout-dense .library-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.layout-shelf.layout-magazine .hero-panel .comic-card:nth-child(1) { grid-column: auto; }
}
