/* 个人博客 · 纯文字极简风
   原则：无图片、无渐变、无阴影堆砌，层级只靠字号 / 字重 / 间距 / 缩进。 */

:root {
  --bg: #fdfcf9;
  --text: #1a1a18;
  --muted: #6e6a60;
  --border: #e3e0d8;
  --accent: #9a3412;
  --accent-soft: rgba(154, 52, 18, 0.08);
  --mark: rgba(154, 52, 18, 0.12);
  --font-serif: "Source Han Serif SC", "Noto Serif SC", "Songti SC", SimSun, Georgia, serif;
  --font-sans: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", Consolas, "Courier New", monospace;
}

[data-theme="dark"] {
  --bg: #16161a;
  --text: #e8e6e1;
  --muted: #9b978d;
  --border: #2c2c33;
  --accent: #e8a87c;
  --accent-soft: rgba(232, 168, 124, 0.1);
  --mark: rgba(232, 168, 124, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.8;
  transition: background 0.25s, color 0.25s;
}

body.is-locked {
  overflow: hidden;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.wrap {
  max-width: 700px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 顶部导航 ---------- */
.site-header {
  border-bottom: 1px solid var(--border);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 18px;
  padding-top: 20px;
  padding-bottom: 20px;
}

.site-title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text);
  margin-right: auto;
}

.site-title:hover {
  text-decoration: none;
  color: var(--accent);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.site-nav a {
  padding: 6px 12px;
  font-size: 0.95rem;
  color: var(--muted);
  border-radius: 6px;
}

.site-nav a:hover {
  color: var(--text);
  text-decoration: none;
  background: var(--accent-soft);
}

.site-nav a.is-active {
  color: var(--accent);
  font-weight: 600;
}

.icon-btn {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  width: 34px;
  height: 34px;
  border-radius: 8px;
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  transition: color 0.2s, border-color 0.2s;
}

.icon-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.settings-trigger {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  width: 34px;
  height: 34px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  transition: color 0.2s, border-color 0.2s;
}

.settings-trigger:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.settings-trigger svg {
  width: 16px;
  height: 16px;
}

/* ---------- 首页头部 ---------- */
.hero {
  padding: 64px 0 48px;
}

.hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 2.6rem);
  line-height: 1.35;
  margin: 0 0 14px;
}

.hero .tagline {
  color: var(--muted);
  font-size: 1.02rem;
  margin: 0 0 6px;
}

.hero .status {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0;
}

/* ---------- 搜索 ---------- */
.search-box {
  margin-bottom: 36px;
}

.search-box input {
  width: 100%;
  padding: 11px 16px;
  font: inherit;
  font-size: 0.95rem;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 10px;
  outline: none;
  transition: border-color 0.2s;
}

.search-box input:focus {
  border-color: var(--accent);
}

/* ---------- 文章卡片 ---------- */
.post-list {
  display: flex;
  flex-direction: column;
}

.post-card {
  padding: 26px 0;
  border-bottom: 1px solid var(--border);
}

.post-card:last-child {
  border-bottom: none;
}

.post-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 8px;
}

.tag {
  padding: 1px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.78rem;
}

.tag:hover {
  color: var(--accent);
  border-color: var(--accent);
  text-decoration: none;
}

.post-title {
  font-family: var(--font-serif);
  font-size: 1.28rem;
  line-height: 1.5;
  margin: 0 0 8px;
}

.post-title a {
  color: var(--text);
}

.post-title a:hover {
  color: var(--accent);
  text-decoration: none;
}

.post-summary {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0;
}

.empty {
  color: var(--muted);
  text-align: center;
  padding: 48px 0;
}

/* ---------- 文章页 ---------- */
.article-head {
  padding: 56px 0 32px;
  border-bottom: 1px solid var(--border);
}

.article-head h1 {
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 4.5vw, 2.2rem);
  line-height: 1.45;
  margin: 0 0 14px;
}

.article-body {
  padding: 36px 0;
  font-size: 1.02rem;
}

.article-body h2 {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  margin: 2.2em 0 0.7em;
}

.article-body h3 {
  font-size: 1.1rem;
  margin: 1.8em 0 0.6em;
}

.article-body p {
  margin: 0 0 1.1em;
}

.article-body ul,
.article-body ol {
  margin: 0 0 1.2em;
  padding-left: 1.6em;
}

.article-body li {
  margin-bottom: 0.4em;
}

.article-body blockquote {
  margin: 1.4em 0;
  padding: 4px 0 4px 18px;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}

.article-body blockquote p {
  margin-bottom: 0.4em;
}

.article-body code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--accent-soft);
  padding: 2px 6px;
  border-radius: 5px;
}

.article-body pre {
  background: var(--accent-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 18px;
  overflow-x: auto;
}

.article-body pre code {
  background: none;
  padding: 0;
  font-size: 0.88em;
  line-height: 1.7;
}

.article-body strong {
  background: linear-gradient(transparent 65%, var(--mark) 65%);
}

/* 文章翻页 */
.article-pager {
  display: flex;
  gap: 16px;
  padding: 8px 0 56px;
}

.pager-link {
  flex: 1;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pager-link:hover {
  text-decoration: none;
  border-color: var(--accent);
}

.pager-right {
  text-align: right;
}

.pager-label {
  font-size: 0.78rem;
  color: var(--muted);
}

.pager-title {
  font-size: 0.92rem;
  color: var(--text);
  font-weight: 600;
}

/* ---------- 归档页 ---------- */
.page-head {
  padding: 56px 0 28px;
}

.page-head h1 {
  font-family: var(--font-serif);
  font-size: 1.9rem;
  margin: 0 0 8px;
}

.page-head .sub {
  color: var(--muted);
  font-size: 0.92rem;
  margin: 0;
}

.archive-year {
  padding: 12px 0 8px;
}

.archive-year h2 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: var(--accent);
  margin: 18px 0 12px;
}

.archive-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.archive-list li {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--border);
}

.archive-date {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--muted);
  flex: none;
}

.archive-list a {
  color: var(--text);
  font-size: 0.98rem;
}

.archive-list a:hover {
  color: var(--accent);
}

.archive-clear {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.88rem;
}

/* ---------- 关于页 ---------- */
.about-body {
  padding: 8px 0 64px;
}

.about-body p {
  margin: 0 0 1.1em;
  font-size: 1.02rem;
}

.about-facts {
  margin: 28px 0;
  padding: 20px 24px;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.about-facts dl {
  margin: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 20px;
}

.about-facts dt {
  color: var(--muted);
  font-size: 0.9rem;
}

.about-facts dd {
  margin: 0;
  font-size: 0.92rem;
  word-break: break-all;
}

/* ---------- 页脚 ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 48px;
}

.site-footer .wrap {
  padding: 26px 24px 34px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 0.85rem;
}

/* ---------- 设置面板 ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 6vh 18px;
  overflow-y: auto;
  background: rgba(0, 0, 0, 0.45);
}

.modal[hidden] {
  display: none;
}

.modal-card {
  position: relative;
  width: min(680px, 100%);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 30px 32px;
  color: var(--text);
}

.modal-card > h1 {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  margin: 0 0 18px;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 1rem;
  cursor: pointer;
  border-radius: 8px;
}

.modal-close:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

.settings-note {
  margin: 0 0 18px;
  font-size: 0.85rem;
  line-height: 1.75;
  color: var(--muted);
}

.settings-note code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  background: var(--accent-soft);
  padding: 2px 6px;
  border-radius: 5px;
}

.admin-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admin-section {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 18px;
}

.admin-section > h2 {
  font-size: 0.98rem;
  margin: 0 0 12px;
  color: var(--accent);
}

.admin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label {
  font-size: 0.84rem;
  color: var(--muted);
}

.field input,
.field textarea {
  font: inherit;
  font-size: 0.94rem;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 12px;
  outline: none;
  transition: border-color 0.2s;
}

.field textarea {
  resize: vertical;
  min-height: 90px;
  line-height: 1.7;
}

.field input:focus,
.field textarea:focus {
  border-color: var(--accent);
}

.admin-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 4px;
}

.btn {
  font: inherit;
  font-size: 0.9rem;
  padding: 9px 18px;
  border-radius: 9px;
  cursor: pointer;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
  font-weight: 600;
}

.btn-primary:hover {
  opacity: 0.9;
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.admin-status {
  font-size: 0.85rem;
  color: var(--muted);
}

.admin-status.is-ok {
  color: var(--accent);
}

.admin-error {
  font-size: 0.85rem;
  color: #c0392b;
}

[data-theme="dark"] .admin-error {
  color: #e07060;
}

/* ---------- 文章页：布局 + 点赞 + TOC ---------- */
.article-layout {
  position: relative;
}

.article-extra {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0;
}

.article-extra span + span::before {
  content: " · ";
}

.article-tools {
  margin-top: 16px;
}

.like-btn {
  font: inherit;
  font-size: 0.88rem;
  padding: 7px 20px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.like-btn:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}

.like-btn.is-liked {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
  cursor: default;
}

.article-toc {
  position: absolute;
  top: 56px;
  left: calc(50% + 380px);
  width: 220px;
  font-size: 0.82rem;
}

.toc-title {
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  margin: 0 0 8px;
}

.article-toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 1px solid var(--border);
}

.article-toc li {
  margin: 0;
}

.article-toc a {
  display: block;
  padding: 4px 0 4px 14px;
  color: var(--muted);
  line-height: 1.5;
}

.article-toc a:hover {
  color: var(--accent);
  text-decoration: none;
}

.article-toc li.toc-sub a {
  padding-left: 28px;
}

@media (max-width: 1140px) {
  .article-toc {
    display: none;
  }
}

/* 代码块复制按钮 */
.copy-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  font: inherit;
  font-size: 0.75rem;
  padding: 3px 10px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--muted);
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s, color 0.2s, border-color 0.2s;
}

pre:hover .copy-btn {
  opacity: 1;
}

.copy-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* ---------- 评论区 ---------- */
.comments {
  border-top: 1px solid var(--border);
  padding: 32px 0 16px;
}

.comments-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin: 0 0 20px;
}

.comments-title span {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--muted);
}

.comment {
  display: flex;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px dashed var(--border);
}

.comment-avatar {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
}

.comment-main {
  flex: 1;
  min-width: 0;
}

.comment-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.comment-name {
  font-weight: 600;
  font-size: 0.92rem;
}

.comment-time {
  color: var(--muted);
  font-size: 0.78rem;
}

.comment-text {
  margin: 4px 0 0;
  font-size: 0.94rem;
  white-space: pre-line;
  word-break: break-word;
}

.comment-form {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.comment-form .field input,
.comment-form .field textarea {
  width: 100%;
}

.comment-form textarea {
  min-height: 84px;
}

.comments-mode {
  margin: 14px 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---------- 返回顶部 ---------- */
.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 60;
  font: inherit;
  font-size: 0.82rem;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  transition: color 0.2s, border-color 0.2s;
}

.back-top:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* ---------- 归档页：标签云 + 随机 ---------- */
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 4px;
}

.page-head-actions {
  margin: 14px 0 4px;
}

/* ---------- 友链页 ---------- */
.links-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-bottom: 48px;
}

.link-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 22px;
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: border-color 0.2s;
}

.link-card:hover {
  text-decoration: none;
  border-color: var(--accent);
}

.link-name {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}

.link-card:hover .link-name {
  color: var(--accent);
}

.link-desc {
  color: var(--muted);
  font-size: 0.9rem;
}

.link-url {
  color: var(--muted);
  font-size: 0.8rem;
  font-family: var(--font-mono);
}

/* ---------- 关于页：大事记 ---------- */
.about-sub {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  margin: 34px 0 16px;
}

.milestones {
  border-left: 2px solid var(--border);
  padding-left: 0;
}

.milestone {
  position: relative;
  display: flex;
  gap: 16px;
  padding: 8px 0 8px 22px;
}

.milestone::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 17px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.milestone-year {
  flex: none;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 700;
  line-height: 1.8;
}

.milestone-text {
  font-size: 0.94rem;
  color: var(--text);
}

/* ---------- 首页标签筛选 ---------- */
.home-tags {
  margin: -16px 0 28px;
}

.tag-btn {
  font-family: var(--font-sans);
  background: transparent;
  cursor: pointer;
  line-height: 1.7;
}

.tag-btn.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
}

/* ---------- 文章工具栏 ---------- */
.tool-group {
  display: inline-flex;
  gap: 8px;
  margin-left: 10px;
  flex-wrap: wrap;
}

.tool-btn {
  font: inherit;
  font-size: 0.82rem;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.tool-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* 正文字号 */
.article-body.font-s {
  font-size: 0.95rem;
}

.article-body.font-m {
  font-size: 1.02rem;
}

.article-body.font-l {
  font-size: 1.14rem;
}

.article-body.font-l p {
  line-height: 1.9;
}

/* ---------- 阅读进度条 ---------- */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 90;
  width: 0;
  height: 3px;
  background: var(--accent);
  transition: width 0.08s linear;
}

/* ---------- 继续阅读提示 ---------- */
.resume-bar {
  position: fixed;
  left: 22px;
  bottom: 22px;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  font-size: 0.84rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.resume-bar button {
  font: inherit;
  font-size: 0.82rem;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--accent);
  cursor: pointer;
}

.resume-close {
  border-color: transparent !important;
  color: var(--muted) !important;
  padding: 4px 6px !important;
}

/* ---------- 打印样式 ---------- */
@media print {
  .site-header,
  .site-footer,
  .article-toc,
  .article-pager,
  .article-tools,
  .comments,
  .back-top,
  .resume-bar,
  .reading-progress,
  .copy-btn,
  .settings-trigger,
  .modal {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 12pt;
  }

  .wrap {
    max-width: 100%;
    padding: 0;
  }

  .article-head {
    border-bottom: 1px solid #999;
  }

  a {
    color: #000;
    text-decoration: underline;
  }
}

/* ---------- 公告条 ---------- */
.notice-bar {
  border-bottom: 1px solid var(--border);
  background: var(--accent-soft);
  font-size: 0.85rem;
}

.notice-bar .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 10px;
  padding-bottom: 10px;
}

.notice-text {
  color: var(--text);
}

.notice-close {
  flex: none;
  font: inherit;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

/* ---------- 置顶标记 ---------- */
.post-badge {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 400;
  padding: 1px 7px;
  margin-right: 8px;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  vertical-align: middle;
}

/* ---------- 加载更多 ---------- */
.load-more-wrap {
  text-align: center;
  padding: 26px 0 10px;
}

/* ---------- 评论回复 ---------- */
.comment-reply {
  margin-left: 52px;
}

.comment-reply .comment-avatar {
  width: 30px;
  height: 30px;
  font-size: 0.8rem;
}

.comment-reply-btn {
  margin-left: auto;
  font: inherit;
  font-size: 0.75rem;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.comment-reply-btn:hover {
  color: var(--accent);
}

.reply-hint {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 8px 12px;
  font-size: 0.82rem;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.reply-hint b {
  color: var(--accent);
}

.reply-cancel {
  margin-left: auto;
  font: inherit;
  font-size: 0.78rem;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

/* ---------- 目录高亮当前章节 ---------- */
.article-toc a.is-current {
  color: var(--accent);
  font-weight: 600;
}

/* ---------- 友链申请 ---------- */
.apply-box {
  border-top: 1px solid var(--border);
  padding: 28px 0 60px;
}

.apply-box h2 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin: 0 0 10px;
}

.apply-box p {
  color: var(--muted);
  font-size: 0.9rem;
}

.apply-template {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.9;
  background: var(--accent-soft);
  border-radius: 10px;
  padding: 14px 16px;
  overflow-x: auto;
}

/* ---------- 通用可访问性 ---------- */
.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 8px 16px;
  background: var(--bg);
  border: 1px solid var(--accent);
  border-radius: 8px;
  color: var(--accent);
  transition: top 0.2s;
}

.skip-link:focus {
  top: 12px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.noscript-tip {
  margin: 0;
  padding: 10px 24px;
  background: var(--accent-soft);
  color: var(--text);
  font-size: 0.85rem;
  text-align: center;
}

/* ---------- 响应式 ---------- */
@media (max-width: 620px) {
  .site-header .wrap {
    flex-wrap: wrap;
    gap: 10px;
  }

  .site-title {
    width: 100%;
    margin-bottom: 0;
  }

  .site-nav {
    gap: 0;
    margin-right: auto;
  }

  .site-nav a {
    padding: 5px 8px;
    font-size: 0.88rem;
  }

  .footer-links {
    display: flex;
    gap: 14px;
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }

  .modal-card {
    padding: 24px 20px;
  }

  .article-pager {
    flex-direction: column;
  }
}

/* 评论区字数提示 */
.field-count {
  margin: -6px 0 0;
  text-align: right;
  font-size: 0.75rem;
  color: var(--muted);
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
