:root {
  --paper: #f3f1eb;
  --paper-deep: #e9e6dd;
  --ink: #19201b;
  --muted: #697069;
  --faint: #969b95;
  --line: #d5d4cd;
  --accent: #1d6d4f;
  --accent-soft: #d9e8df;
  --warm: #b75336;
  --surface: #faf9f5;
  --header-height: 72px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 15px;
  line-height: 1.7;
  letter-spacing: 0;
}

a { color: inherit; text-decoration: none; }
button { color: inherit; font: inherit; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 76%, transparent);
  backdrop-filter: blur(15px);
}

.header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  width: min(1180px, calc(100% - 48px));
  min-height: var(--header-height);
  margin: 0 auto;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 720;
}

.brand { justify-self: start; }

.brand-mark {
  position: relative;
  display: grid;
  width: 27px;
  height: 27px;
  place-items: center;
  overflow: hidden;
  background: var(--ink);
  border-radius: 6px;
}

.brand-mark::before,
.brand-mark::after,
.brand-mark span::before,
.brand-mark span::after {
  position: absolute;
  content: "";
  background: #a8ddbf;
  border-radius: 99px;
}

.brand-mark::before { width: 3px; height: 16px; }
.brand-mark::after { width: 16px; height: 3px; }
.brand-mark span::before { width: 3px; height: 11px; transform: rotate(45deg); }
.brand-mark span::after { width: 3px; height: 11px; transform: rotate(-45deg); }
.brand-mark.small { width: 24px; height: 24px; }

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 34px;
  color: var(--muted);
  font-size: 13px;
}

.desktop-nav a { position: relative; padding: 24px 0; }
.desktop-nav a:hover,
.desktop-nav a.active { color: var(--ink); }
.desktop-nav a.active::after {
  position: absolute;
  bottom: 16px;
  left: 50%;
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
  content: "";
  transform: translateX(-50%);
}

.header-actions {
  display: flex;
  justify-self: end;
  gap: 5px;
}

.icon-button {
  display: grid;
  width: 38px;
  height: 38px;
  padding: 0;
  place-items: center;
  background: transparent;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
}

.icon-button:hover { background: color-mix(in srgb, var(--ink) 7%, transparent); }
.menu-button { display: none; }
.mobile-nav { border-top: 1px solid var(--line); }
.mobile-nav a { display: block; padding: 13px 24px; border-bottom: 1px solid var(--line); }

.hero {
  position: relative;
  min-height: calc(82vh - var(--header-height));
  max-height: 760px;
  overflow: hidden;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

#thoughtCanvas { position: absolute; inset: 0; width: 100%; height: 100%; }

.hero::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--paper) 0%, color-mix(in srgb, var(--paper) 92%, transparent) 43%, color-mix(in srgb, var(--paper) 45%, transparent) 76%, transparent 100%);
  content: "";
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(1180px, calc(100% - 48px));
  min-height: calc(82vh - var(--header-height));
  max-height: 760px;
  margin: 0 auto;
  padding: 68px 0 76px;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 17px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 620;
}

.hero-meta span { width: 24px; height: 1px; background: var(--accent); }

.hero h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", "Songti SC", serif;
  font-size: clamp(68px, 10vw, 132px);
  font-weight: 520;
  line-height: 0.96;
  letter-spacing: 0;
}

.hero-copy {
  margin: 33px 0 30px;
  color: var(--muted);
  font-family: Georgia, "Times New Roman", "Songti SC", serif;
  font-size: 20px;
  line-height: 1.85;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--ink);
  font-size: 13px;
  font-weight: 650;
}

.text-link:hover { color: var(--accent); border-color: var(--accent); }
.hero-link span { color: var(--accent); }

.hero-note {
  position: absolute;
  right: 28px;
  bottom: 25px;
  z-index: 2;
  margin: 0;
  color: var(--faint);
  font-size: 10px;
  writing-mode: vertical-rl;
}

.section-band { border-bottom: 1px solid var(--line); }
.content-width { width: min(1080px, calc(100% - 48px)); margin: 0 auto; padding: 96px 0; }

.section-intro { margin-bottom: 44px; }
.section-label {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 760;
}

.section-intro h2,
.about-copy h2,
.legal-content > h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", "Songti SC", serif;
  font-size: 38px;
  font-weight: 520;
  line-height: 1.25;
}

.latest { background: var(--surface); }
.post-list { border-top: 1px solid var(--line); }
.post-row { border-bottom: 1px solid var(--line); }

.post-row a {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 36px;
  align-items: center;
  gap: 28px;
  min-height: 150px;
  padding: 24px 8px;
  transition: padding 180ms ease, color 180ms ease;
}

.post-row a:hover { padding-right: 0; padding-left: 16px; }
.post-row a:hover h3 { color: var(--accent); }
.post-row a:hover .post-arrow { transform: translate(3px, -3px); }

.post-date { display: flex; flex-direction: column; color: var(--faint); font-size: 11px; }
.post-date span { margin-top: 10px; color: var(--warm); }
.post-main h3 { margin: 0 0 7px; font-size: 23px; font-weight: 650; line-height: 1.35; }
.post-main p { margin: 0; color: var(--muted); }
.post-arrow { color: var(--faint); font-size: 22px; transition: transform 180ms ease; }

.archive { background: var(--paper-deep); }
.archive-layout { display: grid; grid-template-columns: minmax(260px, 0.85fr) 1.15fr; gap: 90px; }
.archive-intro h2 { line-height: 1.35; }
.archive-years { border-top: 1px solid var(--line); }
.year-row { display: grid; grid-template-columns: 150px 1fr; padding: 27px 0; border-bottom: 1px solid var(--line); }
.year { font-family: Georgia, "Times New Roman", serif; font-size: 28px; }
.year-row p { margin: 0; font-weight: 650; }
.year-row div span,
.archive-note { color: var(--muted); font-size: 13px; }
.archive-note { margin: 25px 0 0; }

.about { background: #1c241e; color: #edf1ed; }
.about-layout { display: grid; grid-template-columns: 180px minmax(0, 680px); align-items: start; gap: 95px; }
.about-mark {
  display: grid;
  width: 150px;
  height: 150px;
  place-items: center;
  color: #b6dec8;
  border: 1px solid #526158;
  border-radius: 50%;
  font-family: Georgia, "Songti SC", serif;
  font-size: 50px;
}

.about-copy .section-label { color: #86c6a4; }
.about-copy h2 { margin-bottom: 28px; font-size: 42px; }
.about-copy p:not(.section-label) { margin: 0 0 16px; color: #b6c0b8; font-size: 16px; }

.site-footer { padding: 29px 24px; background: #121813; color: #8f9a91; }
.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 30px;
  width: min(1080px, 100%);
  margin: 0 auto;
  font-size: 12px;
}

.footer-brand { color: #eef1ee; }
.footer-brand > div { display: flex; flex-direction: column; line-height: 1.35; }
.footer-brand span:last-child { color: #8f9a91; font-size: 10px; font-weight: 400; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 24px; }
.footer-links a:hover { color: #fff; }
.footer-inner > p { margin: 0; text-align: right; }

.back-link { justify-self: center; color: var(--muted); font-size: 13px; }
.back-link:hover { color: var(--ink); }

.reading-page { width: min(760px, calc(100% - 40px)); margin: 0 auto; }
.article { padding: 95px 0 110px; scroll-margin-top: 90px; }
.article + .article { border-top: 1px solid var(--line); }
.article-header { margin-bottom: 52px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 17px; margin: 0 0 23px; color: var(--faint); font-size: 12px; }
.article-meta span::before { margin-right: 17px; content: "·"; }
.article-header h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", "Songti SC", serif;
  font-size: 48px;
  font-weight: 520;
  line-height: 1.25;
}
.article-lead { margin: 22px 0 0; color: var(--muted); font-size: 18px; }
.article-body { font-family: Georgia, "Times New Roman", "Songti SC", serif; font-size: 18px; line-height: 2; }
.article-body p { margin: 0 0 24px; }
.article-body h2 { margin: 50px 0 15px; font-size: 25px; }
.article-body blockquote { margin: 40px 0; padding: 20px 0 20px 28px; color: var(--accent); border-left: 3px solid var(--accent); font-size: 20px; }
.article-nav { display: flex; justify-content: space-between; padding: 35px 0 70px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.article-nav a:hover { color: var(--accent); }

.legal-content { width: min(720px, calc(100% - 40px)); min-height: calc(100vh - 140px); margin: 0 auto; padding: 90px 0 110px; }
.legal-content > h1 { max-width: 600px; font-size: 45px; }
.legal-updated { margin: 12px 0 55px; color: var(--faint); font-size: 12px; }
.legal-content section { margin-top: 38px; }
.legal-content h2 { margin: 0 0 8px; font-size: 18px; }
.legal-content section p { margin: 0; color: var(--muted); }
.minimal-footer { padding: 25px; color: var(--faint); border-top: 1px solid var(--line); font-size: 11px; text-align: center; }
.minimal-footer a:hover { color: var(--ink); }

body.dark {
  --paper: #151a16;
  --paper-deep: #1a211c;
  --ink: #edf1ed;
  --muted: #a3ada5;
  --faint: #778179;
  --line: #303832;
  --accent: #7ac8a1;
  --accent-soft: #203a2d;
  --warm: #df8b70;
  --surface: #191f1a;
}

body.dark .about { background: #0f1410; }
body.dark .hero::after { background: linear-gradient(90deg, var(--paper) 0%, color-mix(in srgb, var(--paper) 92%, transparent) 43%, color-mix(in srgb, var(--paper) 45%, transparent) 76%, transparent 100%); }

@media (max-width: 720px) {
  :root { --header-height: 64px; }
  .header-inner { grid-template-columns: 1fr auto; width: calc(100% - 32px); }
  .desktop-nav { display: none; }
  .header-actions { grid-column: 2; }
  .menu-button { display: grid; }
  .back-link { display: none; }
  .hero { min-height: calc(76svh - var(--header-height)); }
  .hero-inner { width: calc(100% - 32px); min-height: calc(76svh - var(--header-height)); padding: 60px 0; }
  .hero h1 { font-size: 64px; }
  .hero-copy { font-size: 17px; }
  .hero-note { display: none; }
  .content-width { width: calc(100% - 32px); padding: 68px 0; }
  .section-intro h2,
  .about-copy h2 { font-size: 31px; }
  .post-row a { grid-template-columns: 1fr 24px; gap: 12px; min-height: 0; padding: 25px 0; }
  .post-date { grid-column: 1 / -1; flex-direction: row; gap: 12px; }
  .post-date span { margin-top: 0; }
  .post-main h3 { font-size: 20px; }
  .post-main p { font-size: 13px; }
  .post-row a:hover { padding-right: 0; padding-left: 0; }
  .archive-layout { grid-template-columns: 1fr; gap: 35px; }
  .year-row { grid-template-columns: 110px 1fr; }
  .about-layout { grid-template-columns: 1fr; gap: 38px; }
  .about-mark { width: 94px; height: 94px; font-size: 36px; }
  .footer-inner { grid-template-columns: 1fr; justify-items: center; gap: 20px; text-align: center; }
  .footer-inner > p { text-align: center; }
  .article { padding: 70px 0 82px; }
  .article-header { margin-bottom: 40px; }
  .article-header h1 { font-size: 34px; }
  .article-lead { font-size: 16px; }
  .article-body { font-size: 17px; line-height: 1.95; }
  .article-body blockquote { margin: 32px 0; font-size: 18px; }
  .legal-content { padding-top: 65px; }
  .legal-content > h1 { font-size: 34px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
