/* 公共阅读页面的布局与文字层级；保留既有雏宫主题。 */
.site-header .main-nav a[aria-current="page"] { color: #f1d494; text-decoration: underline; text-underline-offset: 8px; text-decoration-thickness: 1px; }
.site-menu-links a[aria-current="page"] { color: var(--paper); background: var(--blue); box-shadow: inset 3px 0 #c9a258; }
.site-menu-links a[aria-current="page"] > span { color: var(--gold); }
.site-menu-links a[aria-current="page"] small { color: var(--gold-soft); }
.archive-sort { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.archive-sort a { display: inline-flex; align-items: center; min-height: 44px; box-sizing: border-box; padding: 8px 18px; border: 1px solid #d9c7a7; border-radius: 24px; color: #7d3347; text-decoration: none; }
.archive-sort a[aria-current] { color: #fff9ed; background: #273052; border-color: #273052; }
.home-recent { padding: 32px 0; }
.home-recent-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.home-recent-heading h2 { margin: 6px 0 8px; }
.home-recent-heading p { margin: 0; }
.home-recent-heading > a { display: inline-flex; align-items: center; min-height: 44px; gap: 8px; }
.home-recent .work-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.post-feed-thumbnail { display: block; max-width: 320px; margin: 16px 0; }
.post-feed-thumbnail img { display: block; width: 100%; max-height: 220px; object-fit: contain; background: #f5eee0; border-radius: 8px; }
.post-feed-more { font-size: 13px; color: #756575; }
/* 固定装饰层遵循布局视口，避免 100vw 包含滚动条导致横向溢出。 */
html.js-enabled.motion-ready body.home-page .page-atmosphere,
html.js-enabled.motion-ready body.work-list-page .page-atmosphere { width: auto; }
body.home-page .page-atmosphere .page-fall:nth-of-type(n+9),
body.home-page .page-atmosphere .page-butterfly-c { display: none; }
body.public-site-page:not(.home-page) .page-atmosphere :is(.page-fall, .page-butterfly) { display: none; }
@media (max-width: 1100px) {
  .home-recent .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-recent .work-card:last-child { display: none; }
}
@media (max-width: 620px) {
  body.public-site-page main .work-grid { grid-template-columns: minmax(0, 1fr); }
  .home-recent .work-grid { grid-template-columns: minmax(0, 1fr); }
  .home-recent-heading { align-items: flex-start; gap: 8px; }
  body.home-page .page-atmosphere .page-fall:nth-of-type(n+5),
  body.home-page .page-atmosphere .page-butterfly { display: none; }
}
@media (min-width: 1000px) {
  html:is(.nav-pending, .nav-ready) .site-header .main-nav {
    display: flex !important;
    align-items: center;
    justify-content: flex-end;
    gap: clamp(16px, 2vw, 28px);
    margin-left: auto;
  }
  html:is(.nav-pending, .nav-ready) .site-header .main-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 14px;
    letter-spacing: .04em;
    white-space: nowrap;
  }
}

.work-list-page .page-hero .eyebrow,
.work-detail-page .reader-hero .eyebrow,
.serial-collection-page .page-hero .eyebrow,
.author-profile-page .eyebrow,
.post-feed-page .eyebrow,
.post-detail-page .eyebrow,
.work-detail-page .reader-meta > .meta {
  font-size: 11px;
  line-height: 1.5;
  letter-spacing: .1em;
}
.work-list-page .page-hero h1,
.work-detail-page .reader-hero h1,
.media-reading-page .page-hero h1,
.author-profile-page h1 {
  overflow-wrap: anywhere;
  text-wrap: pretty;
}
.work-card .card-body h3 {
  font-size: 21px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.work-card .card-visual .story-cover-title {
  display: -webkit-box;
  max-width: 82%;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  font-size: clamp(20px, 2vw, 30px);
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.work-card .card-body > p:not(.meta) {
  min-height: 0;
}
.work-card .card-summary {
  font-size: 14px;
  line-height: 1.8;
}
.work-card .card-body .meta,
.work-card .card-foot {
  font-size: 12px;
  line-height: 1.7;
}
.work-card .card-foot .card-foot-meta { display:grid; gap:3px; }
.work-list-page .archive-search { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; align-items:end; margin-bottom:18px; }
.work-list-page .archive-search label { display:grid; gap:6px; font-size:13px; color:var(--muted); }
.work-list-page .archive-search input { width:100%; min-width:0; height:46px; padding:10px 14px; box-sizing:border-box; color:var(--ink); background:#fffdf8; border:1px solid var(--line); border-radius:6px; font:14px/1.5 var(--sans); }
.work-list-page .archive-search button { height:46px; box-sizing:border-box; margin:0; }
@media(max-width:600px) { .work-card .card-foot { flex-direction:column; align-items:stretch; gap:10px; } .work-card .card-foot > a { align-self:flex-end; min-height:44px; display:inline-flex; align-items:center; } .work-card .card-body h3 { font-size:20px; line-height:1.55; } }
.work-detail-page .reader-byline {
  align-items: center;
  gap: 8px 20px;
  font-size: 13px;
  line-height: 1.8;
}
.work-detail-page .reader-author,
.work-detail-page .reader-author a {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.work-detail-page .reader-author a {
  min-height: 44px;
  overflow-wrap: anywhere;
}
.work-detail-page .reader-meta h2,
.author-profile-page .profile-section-heading h2,
.post-detail-page .post-comments > h2 {
  font-size: 22px;
  line-height: 1.5;
}
.post-feed-page .post-body,
.post-detail-page .post-body,
.author-profile-page .post-body {
  max-width: 42em;
  font-size: 16px;
  line-height: 1.8;
}

/* 画屏概要保持紧凑；完整标题与资料仍可在弹窗或作品页阅读。 */
.palace-gallery:where(.has-cards, .is-enhanced) .palace-current h3 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  text-wrap: pretty;
}
.palace-gallery:where(.has-cards, .is-enhanced) .palace-current .palace-card-attribution {
  display: block;
  color: var(--palace-muted);
  font-size: 12px;
  line-height: 1.7;
}

/* 原生 details 在无脚本时仍能展开筛选与完整阅读提示。 */
.work-list-page .archive-filter-panel {
  border: 1px solid #d9cbb8;
  background: #fffcf5;
}
.work-list-page .archive-filter-panel > summary {
  min-height: 48px;
  padding: 12px 16px;
  box-sizing: border-box;
  cursor: pointer;
  color: #403443;
  font-size: 14px;
  line-height: 24px;
}
.work-list-page .archive-filter-panel > summary span {
  margin-left: 12px;
  color: #726577;
  font-size: 12px;
}
.work-list-page .archive-filter-panel[open] > summary {
  border-bottom: 1px solid #e5dacc;
}
.work-list-page .archive-filter-panel .archive-filters {
  border: 0;
  margin: 0;
  padding-top: 12px;
  padding-bottom: 12px;
}
.work-list-page .archive-selected-filters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.6;
}
.work-list-page .archive-selected-filters > span {
  max-width: 100%;
  padding: 4px 8px;
  border: 1px solid #e0d4c4;
  color: #654d5b;
  overflow-wrap: anywhere;
}
.work-list-page .archive-selected-filters > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: #942d45;
}
.work-list-page .archive-reading-note {
  margin: 4px 0 0;
  color: #736373;
}
.work-list-page .archive-reading-note > summary {
  min-height: 44px;
  padding: 10px 0;
  box-sizing: border-box;
  font-size: 12px;
  line-height: 24px;
  cursor: pointer;
}
.work-list-page .archive-reading-note > p {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.75;
}
.work-list-page .archive-filter-panel > summary:focus-visible,
.work-list-page .archive-reading-note > summary:focus-visible {
  outline: 3px solid #9c304d;
  outline-offset: 3px;
}
.work-list-page .result-heading {
  margin-top: 8px;
}

.media-reading-page .page-hero {
  padding: 18px 0 8px;
}
.media-reading-page .page-hero h1 {
  margin: 0;
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.45;
}
.media-reading-page .media-reader-stage {
  padding-top: 8px;
}
.media-reading-page .media-reader-navigation {
  justify-content: space-between;
  gap: 4px 24px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid #dfd2c2;
  font-size: 13px;
  line-height: 1.6;
}
.media-reader-sequence {
  display: grid;
  grid-template-columns: minmax(80px, 1fr) auto minmax(80px, 1fr);
  align-items: center;
  gap: 8px;
}
.media-reader-sequence > :last-child {
  justify-self: end;
}
.media-reader-returns {
  display: flex;
  align-items: center;
  gap: 24px;
}
.media-reading-page .media-reader-navigation a {
  min-height: 44px;
}
.author-profile-page .profile-cover-eyebrow {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
}
.author-profile-page .profile-cover-eyebrow > span {
  white-space: nowrap;
}

@media (max-width: 760px) {
  .work-list-page .page-hero {
    padding: 18px 0 14px;
  }
  .work-list-page .page-hero h1 {
    font-size: 28px;
    margin: 4px 0 8px;
    line-height: 1.4;
  }
  .work-list-page .page-hero .eyebrow {
    margin: 0;
  }
  .work-list-page .page-hero .wrap > p:last-child {
    margin: 0;
    font-size: 13px;
    line-height: 1.7;
  }
  .work-list-page .archive-section {
    padding-top: 16px;
  }
  .work-list-page .result-heading {
    gap: 6px;
    margin-bottom: 12px;
  }
  .work-list-page .result-heading > span {
    font-size: 11px;
    line-height: 1.7;
  }
  .work-list-page .archive-filter-panel > summary {
    padding-left: 12px;
    padding-right: 12px;
  }
  .work-list-page .archive-filter-panel > summary span {
    margin-left: 8px;
  }
  .media-reading-page .page-hero {
    padding: 14px 0 4px;
  }
  .media-reading-page .media-reader-navigation {
    display: block;
  }
  .media-reader-sequence {
    grid-template-columns: 1fr auto 1fr;
  }
  .media-reader-returns {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .author-profile-page .profile-stats {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
  .author-profile-page .profile-stats > a {
    grid-column: span 2;
    border-top: 0;
    border-left: 1px solid #dbc9a6;
    padding: 12px 8px;
  }
  .author-profile-page .profile-stats > a:nth-child(n+4) {
    grid-column: span 3;
    border-top: 1px solid #dbc9a6;
  }
  .author-profile-page .profile-stats > a:first-child,
  .author-profile-page .profile-stats > a:nth-child(4) {
    border-left: 0;
  }
  body.author-profile-page .profile-stats > a:nth-child(-n+3) {
    border-top: 0;
  }
  body.author-profile-page .profile-stats > a:nth-child(2),
  body.author-profile-page .profile-stats > a:nth-child(3),
  body.author-profile-page .profile-stats > a:nth-child(5) {
    border-left: 1px solid #dbc9a6;
  }
  .author-profile-page .profile-stats strong {
    font-size: 22px;
    line-height: 1.3;
  }
  .author-profile-page .profile-stats span {
    font-size: 12px;
    line-height: 1.5;
    margin-top: 4px;
  }
}
