:root {
  --bg: #f3eee4;
  --bg-2: #e8e1d4;
  --ink: #1c2a22;
  --ink-2: #3d4a42;
  --ink-3: #6a746c;
  --line: rgba(28, 42, 34, 0.12);
  --gold: #b8862a;
  --gold-d: #8c651c;
  --paper: #faf6ee;
  --stamp: #1c2a22;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --t-fast: 150ms;
  --t-in: 250ms;
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.75;
  font-weight: 400;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--gold-d); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--ink); }
a:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
}
.skip:focus { left: 8px; background: var(--paper); padding: 8px 12px; }

.site-head {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding: 0 32px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  position: sticky;
  top: 0;
  z-index: 20;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  flex-shrink: 0;
}
.brand img {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
}
.brand span {
  font-weight: 500;
  letter-spacing: 0.02em;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  background: var(--bg-2);
  border: 1px solid var(--line);
  color: var(--ink);
  padding: 10px 14px;
  border-radius: var(--r-sm);
  min-height: 44px;
  font: inherit;
  cursor: pointer;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin-left: auto;
}
.site-nav a {
  color: var(--ink-2);
  text-decoration: none;
  padding: 8px 0;
  font-size: 15px;
}
.site-nav a:hover,
.site-nav a.is-active { color: var(--ink); }
.site-nav a.is-active { box-shadow: inset 0 -2px 0 var(--gold); }

.wrap {
  width: min(1240px, calc(100% - 48px));
  margin: 0 auto;
}

.stamp {
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--stamp);
  margin-right: 8px;
  vertical-align: 2px;
}

.kicker {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: 0.04em;
}

.site-foot {
  margin-top: 64px;
  border-top: 1px solid var(--line);
  background: var(--paper);
  padding: 40px 0 32px;
  color: var(--ink-2);
  font-size: 14px;
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}
.site-foot h2 {
  font-size: 14px;
  font-weight: 500;
  margin: 0 0 12px;
}
.site-foot p { margin: 0 0 8px; }
.site-foot ul { list-style: none; margin: 0; padding: 0; }
.site-foot li { margin-bottom: 6px; }
.site-foot a { color: var(--ink-2); text-decoration: none; }
.site-foot a:hover { color: var(--gold-d); }
.icp-line { margin-top: 24px; color: var(--ink-3); font-size: 13px; }

/* Home: 值班记分条 */
.home-shell {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: calc(100dvh - 72px);
}
.duty-rail {
  border-right: 1px solid var(--line);
  padding: 28px 24px;
  background: var(--bg-2);
}
.duty-rail h2 {
  font-size: 13px;
  font-weight: 500;
  margin: 0 0 16px;
  color: var(--ink-3);
}
.duty-item {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 8px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.duty-item time {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  color: var(--gold-d);
  font-size: 12px;
}
.home-stack { padding: 0; }

.sec { padding: 48px 40px; border-bottom: 1px solid var(--line); }
.sec h1, .sec h2 { font-weight: 500; letter-spacing: -0.02em; }
.sec h1 { font-size: 36px; line-height: 1.28; margin: 8px 0 16px; max-width: 18em; }
.sec h2 { font-size: 24px; margin: 0 0 16px; }
.sec p.lead { font-size: 17px; color: var(--ink-2); max-width: 42em; }

.split-visual {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 32px;
  align-items: start;
}
.split-visual img { border-radius: var(--r-lg); width: 100%; object-fit: cover; max-height: 420px; }

.offset-stack {
  display: grid;
  gap: 20px;
}
.offset-card {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 20px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 16px;
}
.offset-card:nth-child(even) { margin-left: 48px; }
.offset-card img {
  width: 160px;
  height: 112px;
  object-fit: cover;
  border-radius: var(--r-sm);
}
.offset-card h3 { margin: 0 0 8px; font-size: 18px; font-weight: 500; }
.offset-card h3 a { color: var(--ink); text-decoration: none; }
.offset-card p { margin: 0; color: var(--ink-2); font-size: 14px; }

.pair-row {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}
.pair-row img { border-radius: var(--r-md); width: 100%; object-fit: cover; max-height: 280px; }
.note-block {
  background: var(--bg-2);
  padding: 24px;
  border-radius: var(--r-md);
  border-left: 3px solid var(--gold);
}
.note-block h3 { margin: 0 0 8px; font-size: 16px; font-weight: 500; }

.cat-lanes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 32px;
}
.cat-lane {
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.cat-lane h3 { margin: 0 0 8px; font-size: 16px; font-weight: 500; }
.cat-lane a { text-decoration: none; color: var(--ink); }
.cat-lane ul { margin: 0; padding-left: 16px; color: var(--ink-2); font-size: 14px; }

.wide-photo img {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  border-radius: var(--r-lg);
}
.wide-photo figcaption { font-size: 13px; color: var(--ink-3); margin-top: 8px; }

.checklist {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 12px 16px;
  font-size: 15px;
}
.checklist dt {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  color: var(--gold-d);
  font-size: 13px;
}
.checklist dd { margin: 0; }

.desk-strip {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 24px;
  align-items: center;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 24px;
}
.desk-strip img {
  width: 220px;
  height: 160px;
  object-fit: cover;
  border-radius: var(--r-sm);
}

/* Article layout: sidebar LEFT */
.crumb {
  font-size: 13px;
  color: var(--ink-3);
  margin: 0 0 16px;
}
.crumb a { color: var(--ink-3); text-decoration: none; }
.crumb a:hover { color: var(--ink); }

.article-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 40px;
  padding: 40px 0 64px;
}
.article-shell aside {
  border-right: 1px solid var(--line);
  padding-right: 24px;
}
.article-shell aside h2 {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-3);
  margin: 0 0 12px;
}
.article-shell aside ul { list-style: none; padding: 0; margin: 0; }
.article-shell aside li { margin: 0 0 12px; }
.article-shell aside a { color: var(--ink-2); text-decoration: none; font-size: 14px; }
.article-shell aside a:hover { color: var(--gold-d); }

.meta-line {
  font-size: 13px;
  color: var(--ink-3);
  margin: 0 0 24px;
  font-variant-numeric: tabular-nums;
}
.article-body h1 { font-size: 32px; font-weight: 500; line-height: 1.3; margin: 0 0 12px; }
.article-body h2 { font-size: 22px; font-weight: 500; margin: 36px 0 12px; }
.article-body p { margin: 0 0 16px; max-width: 42em; }
.article-body figure { margin: 24px 0; }
.article-body figure img { border-radius: var(--r-md); }
.article-body figcaption { font-size: 13px; color: var(--ink-3); margin-top: 8px; }
.article-body .back-cat { margin-top: 32px; }

.layout-a .hero-img { width: 100%; max-height: 360px; object-fit: cover; border-radius: var(--r-md); margin-bottom: 24px; }
.layout-b .pull {
  float: right;
  width: min(280px, 40%);
  margin: 0 0 16px 24px;
}
.layout-b .pull img { border-radius: var(--r-sm); }
.layout-c .band {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 24px 0;
}
.layout-c .band img { height: 180px; object-fit: cover; border-radius: var(--r-sm); width: 100%; }

.faq dt { font-weight: 500; margin-top: 12px; }
.faq dd { margin: 4px 0 0; color: var(--ink-2); }

.cat-page { padding: 40px 0 64px; }
.cat-page h1 { font-size: 32px; font-weight: 500; margin: 0 0 8px; }
.cat-lead { color: var(--ink-2); max-width: 40em; }
.entry-list { list-style: none; padding: 0; margin: 32px 0 0; }
.entry-list li {
  padding: 20px 0;
  border-top: 1px solid var(--line);
}
.entry-list a { color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 500; }
.entry-list p { margin: 8px 0 0; color: var(--ink-2); font-size: 15px; }

@media (max-width: 1024px) {
  .home-shell { grid-template-columns: 1fr; }
  .duty-rail { border-right: 0; border-bottom: 1px solid var(--line); }
  .article-shell { grid-template-columns: 1fr; }
  .article-shell aside {
    border-right: 0;
    border-top: 1px solid var(--line);
    padding: 24px 0 0;
    order: 2;
  }
  .article-body { order: 1; }
}

@media (max-width: 768px) {
  .site-head { padding: 0 16px; }
  .nav-toggle { display: inline-flex; align-items: center; }
  .site-nav {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 72px;
    background: var(--paper);
    flex-direction: column;
    padding: 12px 16px 20px;
    border-bottom: 1px solid var(--line);
    margin: 0;
  }
  .site-nav.is-open { display: flex; }
  .wrap { width: calc(100% - 32px); }
  .sec { padding: 32px 16px; }
  .split-visual, .pair-row, .cat-lanes, .desk-strip, .foot-grid, .layout-c .band {
    grid-template-columns: 1fr;
  }
  .offset-card { grid-template-columns: 1fr; margin-left: 0 !important; }
  .offset-card img { width: 100%; height: 180px; }
  .layout-b .pull { float: none; width: 100%; margin: 0 0 16px; }
  .desk-strip img { width: 100%; height: 180px; }
  .sec h1 { font-size: 28px; }
}

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