/*
Theme Name: 叙白 Xubai
Theme URI: https://goodform.design/xubai
Author: Xubai Studio
Author URI: https://goodform.design
Description: 为室内设计师打造的极简个人网站主题。项目、材料笔记与工地日志，暖白底色、1px 分隔线，让照片成为主角。不依赖任何付费插件，项目字段、首页文案、页脚与订阅区块均可在后台设置。
Version: 1.1.0
Requires at least: 6.2
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: xubai
Tags: blog, portfolio, one-column, custom-menu, custom-logo, featured-images, translation-ready, block-styles
Update URI: https://goodform.design/xubai
*/

/* =========================================================
   设计令牌 — 可在「外观 → 自定义」中调整文案
   ========================================================= */
/* =========================================================
   极简个人设计博客 — 样式规范
   设计令牌集中在 :root，可直接映射到 WordPress theme.json
   ========================================================= */

:root {
  /* 色彩 */
  --paper: #FBFAF8;
  --paper-2: #F2F0EA;
  --ink: #17171A;
  --ink-2: #45454B;
  --muted: #8B8880;
  --line: #E3DFD7;
  --accent: #A9482E;

  /* 字体 */
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system,
    BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Consolas", "Liberation Mono", Menlo, monospace;

  /* 尺度 */
  --page: 1160px;
  --measure: 680px;
  --ease: cubic-bezier(0.22, 0.7, 0.2, 1);
}

*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; display: block; }
button, input { font: inherit; color: inherit; }

::selection { background: #EADFD8; color: var(--ink); }

:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 4px;
}

.wrap {
  width: 100%;
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 40px;
}

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper);
  padding: 10px 16px; z-index: 100; font-size: 13px;
}
.skip:focus { left: 24px; top: 12px; }

/* ---------- 页头 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 250, 248, 0.9);
  backdrop-filter: saturate(120%) blur(10px);
  -webkit-backdrop-filter: saturate(120%) blur(10px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.06em;
}
.brand .dot { color: var(--accent); margin-left: 1px; }

.nav {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 13.5px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.nav a {
  position: relative;
  padding: 6px 0;
  transition: color 0.22s var(--ease);
}
.nav a:hover { color: var(--ink); }
.nav a.is-active { color: var(--ink); }
.nav a.is-active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--ink);
}
.nav .nav-sub { color: var(--ink); }
.nav .nav-sub::after {
  content: "";
  display: block;
  height: 1px;
  background: var(--line);
  margin-top: 2px;
  transition: background 0.22s var(--ease);
}
.nav .nav-sub:hover::after { background: var(--ink); }

/* ---------- 首页 · 开场 ---------- */
.intro { padding-top: 104px; padding-bottom: 84px; }

.intro > * { max-width: 860px; }
.intro > .lede { max-width: 540px; }

.eyebrow {
  margin: 0 0 30px;
  font-size: 11.5px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}

.intro h1 {
  margin: 0 0 30px;
  font-size: clamp(32px, 5.2vw, 58px);
  font-weight: 600;
  line-height: 1.32;
  letter-spacing: -0.025em;
}

.intro h1 em {
  font-style: normal;
  color: var(--muted);
}

.lede {
  margin: 0;
  max-width: 540px;
  font-size: 16.5px;
  line-height: 1.95;
  color: var(--ink-2);
}

.intro-meta {
  margin-top: 44px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.intro-meta span { display: inline-flex; align-items: center; gap: 10px; }
.intro-meta span + span::before {
  content: "";
  width: 1px; height: 10px;
  background: var(--line);
}

/* ---------- 精选 ---------- */
.feature {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 60px;
  align-items: center;
  padding-top: 12px;
  padding-bottom: 96px;
  border-bottom: 1px solid var(--line);
}

.feature-media {
  display: block;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--paper-2);
}
.feature-media img,
.ph img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.feature-media img {
  transition: transform 1.4s var(--ease);
}
.feature:hover .feature-media img { transform: scale(1.035); }

.label {
  margin: 0 0 18px;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.feature h2 {
  margin: 0 0 18px;
  font-size: clamp(23px, 2.8vw, 32px);
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: -0.015em;
}
.feature p {
  margin: 0 0 26px;
  font-size: 15.5px;
  line-height: 1.9;
  color: var(--ink-2);
}

.more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  letter-spacing: 0.05em;
  color: var(--ink);
}
.more .arrow { transition: transform 0.3s var(--ease); }
.more:hover .arrow { transform: translateX(5px); }

/* ---------- 列表区 ---------- */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  padding: 64px 0 4px;
}
.section-head h2 {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.section-head .count {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}

.post-list { padding-top: 12px; }

.post-item {
  display: grid;
  grid-template-columns: 112px 1fr 34px;
  gap: 34px;
  padding: 34px 0 32px;
  border-bottom: 1px solid var(--line);
  align-items: start;
}

.post-item time {
  padding-top: 7px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.03em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.post-item h3 {
  margin: 0 0 10px;
  font-size: 21px;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: -0.01em;
}
.post-item h3 a {
  background-image: linear-gradient(var(--ink), var(--ink));
  background-size: 0% 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size 0.4s var(--ease);
}
.post-item:hover h3 a { background-size: 100% 1px; }

.post-item .excerpt {
  margin: 0 0 14px;
  max-width: 540px;
  font-size: 14.5px;
  line-height: 1.85;
  color: var(--muted);
}
.post-item .tags {
  display: flex;
  gap: 8px;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.post-item .tags i { font-style: normal; opacity: 0.5; }

.post-item .num {
  padding-top: 8px;
  text-align: right;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--line);
  transition: color 0.3s var(--ease);
}
.post-item:hover .num { color: var(--muted); }

.list-foot {
  display: flex;
  justify-content: center;
  padding: 56px 0 0;
}

/* ---------- 订阅 ---------- */
.subscribe {
  margin: 104px 0 0;
  padding: 76px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.subscribe h2 {
  margin: 0 0 14px;
  font-size: clamp(22px, 2.6vw, 28px);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.5;
}
.subscribe p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.9;
  color: var(--muted);
  max-width: 380px;
}

.sub-form { display: flex; align-items: center; gap: 14px; }
.sub-form input {
  flex: 1;
  min-width: 0;
  padding: 12px 2px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  font-size: 14.5px;
  transition: border-color 0.25s var(--ease);
}
.sub-form input::placeholder { color: #B3AFA6; }
.sub-form input:focus { outline: none; border-color: var(--ink); }
.sub-form button {
  border: 0;
  background: transparent;
  padding: 12px 0;
  font-size: 13.5px;
  letter-spacing: 0.05em;
  cursor: pointer;
  color: var(--ink);
  white-space: nowrap;
}
.sub-form button:hover { color: var(--accent); }

/* ---------- 项目网格 ---------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 32px;
  padding-top: 28px;
}

.ph {
  display: block;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--paper-2);
}
.ph img { transition: transform 1.2s var(--ease); }
.project-card:hover .ph img,
.arc-photo:hover img { transform: scale(1.04); }

.project-card h3 {
  margin: 18px 0 6px;
  font-size: 16.5px;
  font-weight: 600;
  letter-spacing: -0.005em;
  line-height: 1.5;
}
.project-card h3 a:hover { color: var(--accent); }
.project-card .meta {
  margin: 0;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }

/* ---------- 项目详情 ---------- */
.proj-hero { margin-top: 44px; }
.proj-hero .ph { aspect-ratio: 3 / 2; }

.proj-facts {
  margin: 56px 0 0;
  padding: 30px 0 6px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.proj-facts div { padding-bottom: 22px; }
.proj-facts dt {
  margin: 0 0 8px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.proj-facts dd {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--ink);
}

.proj-body { max-width: var(--measure); margin-top: 64px; }
.proj-body p { font-size: 16.5px; line-height: 2.05; color: #2B2B30; margin: 0 0 28px; }
.proj-body h2 {
  margin: 60px 0 22px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.6;
}
.proj-body h2::before {
  content: "";
  display: block;
  width: 24px; height: 1px;
  background: var(--ink);
  margin-bottom: 18px;
}
.proj-body figure { margin: 48px 0; }
.proj-body figcaption {
  margin-top: 14px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.03em;
  text-align: center;
}

.proj-next {
  margin-top: 72px;
  border-top: 1px solid var(--line);
  padding-top: 34px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
}
.proj-next .dir {
  display: block;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.12em;
  margin-bottom: 8px;
}
.proj-next .ttl { font-size: 18px; font-weight: 600; }
.proj-next a:hover .ttl { color: var(--accent); }

/* ---------- 年份归档（项目） ---------- */
.year-row {
  display: flex;
  align-items: baseline;
  gap: 24px;
  padding: 52px 0 6px;
}
.year-row .y {
  font-family: var(--mono);
  font-size: 15px;
  letter-spacing: 0.04em;
  color: var(--ink);
}
.year-row .n {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* ---------- 页脚 ---------- */
.site-footer { padding: 52px 0 68px; }
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 20px 40px;
  align-items: baseline;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--muted);
  letter-spacing: 0.03em;
}
.footer-links { display: flex; gap: 24px; }
.footer-links a { transition: color 0.22s var(--ease); }
.footer-links a:hover { color: var(--ink); }

/* ---------- 文章页 ---------- */
.article-head { padding-top: 76px; padding-bottom: 44px; }
.article-head .inner { max-width: 760px; }

.article-head h1 {
  margin: 20px 0 0;
  font-size: clamp(28px, 4.2vw, 42px);
  font-weight: 600;
  line-height: 1.42;
  letter-spacing: -0.02em;
}

.article-meta {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.article-meta span + span::before {
  content: "/";
  margin-right: 20px;
  color: var(--line);
}

.article-body {
  max-width: var(--measure);
  padding: 8px 0 24px;
}

.article-body p {
  margin: 0 0 26px;
  font-size: 16.5px;
  line-height: 2.05;
  color: #2B2B30;
  letter-spacing: 0.005em;
}

.article-body > p:first-of-type { font-size: 17.5px; color: var(--ink); }

.article-body h2 {
  margin: 60px 0 22px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.6;
}
.article-body h2::before {
  content: "";
  display: block;
  width: 24px;
  height: 1px;
  background: var(--ink);
  margin-bottom: 18px;
}

.article-body blockquote {
  margin: 44px 0;
  padding: 4px 0 4px 26px;
  border-left: 1px solid var(--ink);
  font-size: 17px;
  line-height: 1.95;
  color: var(--ink);
}
.article-body blockquote p { margin: 0; font-size: inherit; color: inherit; }

.article-body figure { margin: 48px 0; }
.article-body figcaption {
  margin-top: 14px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.03em;
  text-align: center;
}

.article-body ul, .article-body ol {
  margin: 0 0 28px;
  padding-left: 20px;
}
.article-body li {
  font-size: 16.5px;
  line-height: 1.95;
  color: #2B2B30;
  margin-bottom: 10px;
}
.article-body li::marker { color: var(--muted); }

.article-body hr {
  border: 0;
  height: 1px;
  background: var(--line);
  margin: 56px 0;
}

.article-body code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: var(--paper-2);
  padding: 2px 6px;
}

.article-foot {
  max-width: var(--measure);
  margin-top: 40px;
  padding-top: 34px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
}
.article-foot .tag {
  border: 1px solid var(--line);
  padding: 5px 12px;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
}

.post-nav {
  max-width: var(--measure);
  margin-top: 64px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.post-nav a {
  padding: 30px 0;
  display: block;
}
.post-nav a + a {
  border-left: 1px solid var(--line);
  padding-left: 30px;
  text-align: right;
}
.post-nav .dir {
  display: block;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.12em;
  margin-bottom: 8px;
}
.post-nav .ttl { font-size: 15.5px; line-height: 1.6; }
.post-nav a:hover .ttl { color: var(--accent); }

/* ---------- 归档页 ---------- */
.page-head { padding-top: 88px; padding-bottom: 64px; border-bottom: 1px solid var(--line); }
.page-head h1 {
  margin: 0 0 18px;
  font-size: clamp(30px, 4.4vw, 44px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.35;
}
.page-head p {
  margin: 0;
  max-width: 500px;
  font-size: 15px;
  line-height: 1.9;
  color: var(--muted);
}

.year-group {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 40px;
  padding: 46px 0 20px;
  border-bottom: 1px solid var(--line);
}
.year-group:last-of-type { border-bottom: 0; }

.year {
  font-family: var(--mono);
  font-size: 15px;
  color: var(--ink);
  letter-spacing: 0.04em;
  padding-top: 4px;
}
.year small {
  display: block;
  margin-top: 6px;
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.arc-list { display: flex; flex-direction: column; }
.arc-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding: 11px 0;
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease);
}
.arc-item:hover { border-bottom-color: var(--line); }
.arc-item .ttl { font-size: 16.5px; line-height: 1.65; }
.arc-item:hover .ttl { color: var(--accent); }
.arc-item .cat {
  flex: none;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.06em;
}

/* ---------- 关于页 ---------- */
.about {
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 72px;
  padding-top: 88px;
  padding-bottom: 40px;
  align-items: start;
}

.portrait {
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--paper-2);
  overflow: hidden;
}
.portrait svg { width: 100%; height: 100%; }
.portrait img { width: 100%; height: 100%; object-fit: cover; }

.about-body h1 {
  margin: 0 0 26px;
  font-size: clamp(26px, 3.4vw, 34px);
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: -0.02em;
}
.about-body p {
  margin: 0 0 22px;
  font-size: 16px;
  line-height: 1.95;
  color: var(--ink-2);
  max-width: 560px;
}

.now {
  margin: 48px 0 0;
  padding: 34px 0 0;
  border-top: 1px solid var(--line);
  max-width: 560px;
}
.now h2 {
  margin: 0 0 20px;
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.now dl {
  margin: 0;
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px 20px;
  font-size: 14.5px;
}
.now dt { color: var(--muted); font-family: var(--mono); font-size: 12px; padding-top: 2px; }
.now dd { margin: 0; color: var(--ink-2); }

.contact {
  margin-top: 56px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
}
.contact a {
  font-size: 14px;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--line);
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.contact a:hover { border-color: var(--ink); color: var(--ink); }

/* ---------- 入场动效 ---------- */
@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
.rise { animation: rise 0.7s var(--ease) both; }
.rise-2 { animation-delay: 0.08s; }
.rise-3 { animation-delay: 0.16s; }
.rise-4 { animation-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* ---------- 响应式 ---------- */
@media (max-width: 980px) {
  .wrap { padding: 0 28px; }
  .feature { grid-template-columns: 1fr; gap: 34px; padding-bottom: 72px; }
  .feature-media { aspect-ratio: 16 / 10; }
  .project-grid { grid-template-columns: repeat(2, 1fr); gap: 40px 24px; }
  .proj-facts { grid-template-columns: repeat(2, 1fr); gap: 4px 24px; }
  .subscribe { grid-template-columns: 1fr; gap: 30px; padding: 56px 0; margin-top: 80px; }
  .about { grid-template-columns: 1fr; gap: 44px; padding-top: 64px; }
  .portrait { max-width: 260px; }
  .year-group { grid-template-columns: 1fr; gap: 14px; padding-top: 38px; }
}

@media (max-width: 680px) {
  .wrap { padding: 0 22px; }
  .header-inner { height: 64px; }
  .nav { gap: 20px; font-size: 13px; }
  .nav a.is-active::after { display: none; }
  .nav a.is-active { color: var(--ink); }

  .intro { padding-top: 64px; padding-bottom: 56px; }
  .intro h1 { font-size: 29px; }
  .intro-meta { margin-top: 32px; }

  .post-item {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 28px 0 26px;
  }
  .post-item time { padding-top: 0; }
  .post-item h3 { font-size: 18.5px; }
  .post-item .num { display: none; }
  .post-item .excerpt { font-size: 14px; }

  .article-head { padding-top: 52px; padding-bottom: 32px; }
  .article-body p, .article-body li { font-size: 16px; line-height: 1.95; }
  .article-body blockquote { font-size: 16px; padding-left: 18px; }
  .post-nav { grid-template-columns: 1fr; }
  .post-nav a + a { border-left: 0; padding-left: 0; text-align: left; border-top: 1px solid var(--line); }

  .page-head { padding-top: 56px; padding-bottom: 40px; }
  .project-grid { grid-template-columns: 1fr; gap: 44px; }
  .grid-2 { grid-template-columns: 1fr; }
  .proj-facts { grid-template-columns: 1fr 1fr; }
  .proj-facts dd { font-size: 13.5px; }
  .proj-next { flex-direction: column; gap: 26px; }
  .now dl { grid-template-columns: 1fr; gap: 2px 0; }
  .now dd { margin-bottom: 10px; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 14px; }
}

/* 页脚菜单（wp_nav_menu 输出） */
.footer-links ul {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-links li { margin: 0; }

/* 通用图片填充 */
.xs-img { display: block; width: 100%; height: 100%; object-fit: cover; }


/* =========================================================
   WordPress 兼容层
   ========================================================= */

/* 导航（wp_nav_menu 输出 ul） */
.nav ul {
  display: flex;
  align-items: center;
  gap: 30px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.nav li { position: relative; }
.nav .current-menu-item > a,
.nav .current_page_item > a,
.nav .current-menu-parent > a { color: var(--ink); }
.nav .current-menu-item > a::after,
.nav .current_page_item > a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--ink);
}

.custom-logo { max-height: 26px; width: auto; display: block; }

/* 跳转链接与屏幕阅读器 */
.screen-reader-text {
  border: 0;
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}
.screen-reader-text:focus {
  background: var(--paper);
  border: 1px solid var(--ink);
  clip-path: none;
  color: var(--ink);
  display: block;
  font-size: 13px;
  height: auto;
  left: 24px;
  top: 12px;
  line-height: normal;
  padding: 10px 16px;
  text-decoration: none;
  width: auto;
  z-index: 100000;
}

/* 后台工具条偏移 */
body.admin-bar .site-header { top: 32px; }
@media screen and (max-width: 782px) {
  body.admin-bar .site-header { top: 46px; }
}

/* 正文内的区块与媒体 */
.entry-content > * { max-width: 100%; }
.entry-content img { height: auto; }
.entry-content figure { margin: 48px 0; }
.entry-content figure img { margin-left: auto; margin-right: auto; }
.entry-content figcaption,
.entry-content .wp-block-image figcaption,
.wp-caption-text {
  margin-top: 14px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.03em;
  text-align: center;
}
.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 28px;
  font-size: 14.5px;
}
.entry-content th,
.entry-content td {
  border-bottom: 1px solid var(--line);
  padding: 11px 12px;
  text-align: left;
  vertical-align: top;
}
.entry-content th { font-weight: 600; color: var(--ink); }
.entry-content pre {
  background: var(--paper-2);
  padding: 22px;
  overflow: auto;
  margin: 0 0 28px;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.75;
}
.entry-content pre code { background: none; padding: 0; }
.entry-content iframe { max-width: 100%; }
.entry-content hr {
  border: 0;
  height: 1px;
  background: var(--line);
  margin: 56px 0;
}

/* 图片对齐 */
.alignleft { float: left; margin: 8px 28px 20px 0; max-width: 50%; }
.alignright { float: right; margin: 8px 0 20px 28px; max-width: 50%; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.alignwide { width: calc(100% + 128px); max-width: none; margin-left: -64px; }
.alignfull { width: 100vw; max-width: none; margin-left: calc(50% - 50vw); }
@media (max-width: 820px) {
  .alignwide { width: 100%; margin-left: 0; }
  .alignleft, .alignright { float: none; margin: 24px auto; max-width: 100%; }
}

/* 分页 */
.pagination {
  margin-top: 56px;
  padding-top: 34px;
  border-top: 1px solid var(--line);
}
.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12.5px;
}
.page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 9px;
  border: 1px solid var(--line);
  color: var(--muted);
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.page-numbers:hover,
.page-numbers.current { border-color: var(--ink); color: var(--ink); }
.page-numbers.dots { border-color: transparent; }

/* 搜索表单 */
.search-form {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 440px;
}
.search-form label { flex: 1; margin: 0; }
.search-form input[type="search"] {
  width: 100%;
  padding: 11px 2px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  font-size: 15px;
}
.search-form input[type="search"]:focus { outline: none; border-color: var(--ink); }
.search-form input[type="submit"],
.search-form button {
  border: 0;
  background: transparent;
  padding: 11px 0;
  font-size: 13.5px;
  letter-spacing: 0.05em;
  cursor: pointer;
  color: var(--ink);
}

/* 评论 */
.comments {
  max-width: var(--measure);
  margin-top: 64px;
  padding-top: 36px;
  border-top: 1px solid var(--line);
}
.comments-title,
.comment-reply-title {
  margin: 0 0 22px;
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment-list > li { padding: 22px 0; border-bottom: 1px solid var(--line); }
.comment-list .children {
  list-style: none;
  margin: 18px 0 0;
  padding-left: 22px;
  border-left: 1px solid var(--line);
}
.comment-author { font-size: 14px; font-weight: 600; }
.comment-author .avatar { width: 28px; height: 28px; border-radius: 0; margin-right: 10px; vertical-align: middle; }
.comment-metadata { font-family: var(--mono); font-size: 11.5px; color: var(--muted); margin: 6px 0 10px; }
.comment-content { font-size: 15px; line-height: 1.9; color: var(--ink-2); }
.comment-content p { margin: 0 0 12px; }
.comment-respond { margin-top: 40px; }
.comment-form p { margin: 0 0 18px; }
.comment-form label {
  display: block;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 6px;
}
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 10px 2px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  font-size: 15px;
  font-family: inherit;
}
.comment-form input:focus,
.comment-form textarea:focus { outline: none; border-color: var(--ink); }
.comment-form .submit,
.comment-form input[type="submit"] {
  border: 0;
  background: transparent;
  padding: 12px 0;
  font-size: 13.5px;
  letter-spacing: 0.05em;
  cursor: pointer;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
}
.comment-notes, .logged-in-as { font-size: 12.5px; color: var(--muted); }

/* 归档页描述 */
.archive-description {
  max-width: 540px;
  margin: 16px 0 0;
  font-size: 15px;
  line-height: 1.9;
  color: var(--muted);
}

/* 文章正文里的项目信息表（沿用 .proj-facts） */
.single-project .proj-facts { grid-template-columns: repeat(4, 1fr); }

/* 空状态 */
.no-results { padding: 40px 0 60px; max-width: var(--measure); }
.no-results h2 { font-size: 20px; font-weight: 600; margin: 0 0 12px; }
.no-results p { color: var(--muted); font-size: 15px; margin: 0 0 24px; }

/* 首页区块的 WordPress 特有间距 */
.front-section { padding-bottom: 8px; }

/* 移动端导航间距覆盖 */
@media (max-width: 980px) {
  .nav ul { gap: 24px; }
}
@media (max-width: 680px) {
  .nav ul { gap: 18px; }
  .nav .current-menu-item > a::after,
  .nav .current_page_item > a::after { display: none; }
  .nav a { padding: 4px 0; }
  .custom-logo { max-height: 22px; }
}
