@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;500;600;700&family=Josefin+Sans:wght@300;400;500;600;700&display=swap');

:root{
  --ink:#172623;
  --ink-soft:#3d4d47;
  --teal:#5cc6b0;
  --teal-deep:#2b8a78;
  --sand:#d4c4a8;
  --sand-lite:#ecdfcb;
  --clay:#c67b5c;
  --olive:#6b7b3c;
  --paper:#f7f0e5;
  --paper-2:#f0e5d4;
  --card:#fffdf8;
  --line:rgba(23,38,35,.13);
  --radius:18px;
  --shadow:0 12px 28px -14px rgba(66,48,30,.34), 0 2px 6px rgba(66,48,30,.06);
  --maxw:1120px;
  --font-head:'Cinzel','Songti SC','Noto Serif SC',Georgia,serif;
  --font-body:'Josefin Sans',-apple-system,'PingFang SC','Hiragino Sans GB','Microsoft YaHei',sans-serif;
}

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

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

body{
  margin:0;
  font-family:var(--font-body);
  font-size:17px;
  line-height:1.72;
  color:var(--ink);
  background:
    radial-gradient(1100px 460px at 8% -10%,#fcf7f0 0%,rgba(252,247,240,0) 68%),
    radial-gradient(900px 420px at 96% 6%,rgba(212,196,168,.5) 0%,rgba(212,196,168,0) 70%),
    linear-gradient(180deg,var(--paper) 0%,var(--paper-2) 100%);
  -webkit-font-smoothing:antialiased;
}

body::after{
  content:'';
  position:fixed;
  inset:0;
  z-index:60;
  pointer-events:none;
  opacity:.055;
  mix-blend-mode:multiply;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/></filter><rect width='160' height='160' filter='url(%23n)' opacity='0.6'/></svg>");
  background-size:160px 160px;
}

h1,h2,h3,h4{
  font-family:var(--font-head);
  font-weight:600;
  line-height:1.3;
  letter-spacing:.01em;
  margin:0 0 .5em;
}

a{color:inherit}

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

:focus-visible{outline:2px solid var(--teal-deep);outline-offset:3px;border-radius:8px}

/* --- 顶条 --- */
.site-head{
  position:sticky;
  top:0;
  z-index:40;
  background:rgba(247,240,229,.94);
  backdrop-filter:blur(10px);
  border-bottom:1px solid var(--line);
}

.strip{
  margin:0;
  padding:8px 20px;
  font-size:15px;
  letter-spacing:.08em;
  text-align:center;
  color:#ecdfcb;
  background:linear-gradient(90deg,#172623,#2b4a41 52%,#3c6152);
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.head-inner{
  max-width:var(--maxw);
  margin:0 auto;
  padding:10px 20px;
  display:grid;
  grid-template-columns:1fr auto 1fr;
  align-items:center;
  gap:10px;
}

.head-inner nav{min-width:0}
.head-inner nav ol{
  display:flex;
  list-style:none;
  margin:0;
  padding:0;
  gap:2px;
}
.head-r ol{justify-content:flex-end}

.head-inner nav a{
  display:inline-flex;
  align-items:center;
  gap:7px;
  min-height:42px;
  padding:10px 11px;
  font-size:15px;
  line-height:1.4;
  color:var(--ink-soft);
  text-decoration:none;
  border-radius:12px;
  transition:color .25s ease-out,background-color .25s ease-out;
}
.head-inner nav a:hover,
.head-inner nav a[aria-current]{color:var(--ink);background:rgba(92,198,176,.18)}

.dot{
  width:6px;
  height:6px;
  flex:none;
  border-radius:50%;
  background:var(--sand);
  box-shadow:0 0 0 1px rgba(23,38,35,.22);
  transition:background-color .25s ease-out,transform .25s ease-out;
}
.head-inner nav a:hover .dot{background:var(--teal);transform:scale(1.45)}

.brand{
  justify-self:center;
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:6px 4px;
  text-decoration:none;
  color:var(--ink);
}
.seal{
  width:38px;
  height:38px;
  flex:none;
  display:grid;
  place-items:center;
  font-family:var(--font-head);
  font-size:18px;
  font-weight:700;
  color:#0e1c19;
  background:linear-gradient(150deg,var(--teal),#3d9b88);
  border-radius:14px 19px 12px 17px;
  box-shadow:var(--shadow);
}
.brand-name{
  font-family:var(--font-head);
  font-size:20px;
  letter-spacing:.16em;
  white-space:nowrap;
}

/* --- 首屏 --- */
.hero{
  position:relative;
  max-width:var(--maxw);
  margin:0 auto;
  padding:clamp(22px,4vw,44px) 20px clamp(26px,4vw,40px);
  display:grid;
  grid-template-columns:minmax(0,1.15fr) minmax(0,.85fr);
  gap:clamp(20px,4vw,44px);
  align-items:center;
  min-height:45vh;
}

.hero-copy{max-width:56ch}

.badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  margin-bottom:16px;
  padding:6px 15px;
  font-size:15px;
  letter-spacing:.18em;
  color:#1b4a40;
  background:rgba(92,198,176,.2);
  border:1px solid rgba(92,198,176,.62);
  border-radius:999px;
  box-shadow:0 10px 20px -12px rgba(66,48,30,.5);
  transform:translateY(-2px);
}
.badge::before{
  content:'';
  width:7px;
  height:7px;
  border-radius:50%;
  background:var(--teal);
  box-shadow:0 0 0 3px rgba(92,198,176,.3);
}

h1{
  font-size:clamp(27px,4.4vw,44px);
  color:var(--ink);
  max-width:20ch;
  margin-bottom:14px;
}

.hero-desc{
  margin:0;
  max-width:44ch;
  color:var(--ink-soft);
  font-size:17px;
}

.hero-art{
  position:relative;
  margin:0;
  aspect-ratio:5/4;
  border-radius:54% 46% 42% 58% / 46% 52% 48% 54%;
  background:linear-gradient(150deg,#e9decd,#dccbad 58%,#cfbc9c);
  box-shadow:0 30px 50px -26px rgba(66,48,30,.55);
  will-change:transform;
}
.hero-art::before{
  content:'';
  position:absolute;
  inset:-12px;
  border:1px dashed rgba(92,198,176,.55);
  border-radius:inherit;
  animation:spin 42s linear infinite;
}
.hero-img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  border-radius:inherit;
}
.blob{
  display:block;
  width:100%;
  height:100%;
  border-radius:inherit;
  background:
    radial-gradient(circle at 30% 28%,rgba(92,198,176,.6),rgba(92,198,176,0) 55%),
    radial-gradient(circle at 74% 72%,rgba(198,123,92,.5),rgba(198,123,92,0) 58%);
  animation:pulse 12s ease-out infinite alternate;
}
@keyframes spin{to{transform:rotate(360deg)}}
@keyframes pulse{from{transform:scale(.97)}to{transform:scale(1.03)}}

/* --- 正文 + 侧栏 --- */
.essay{
  max-width:var(--maxw);
  margin:0 auto;
  padding:0 20px clamp(40px,6vw,72px);
  display:grid;
  grid-template-columns:minmax(0,1fr) 266px;
  gap:clamp(20px,3vw,38px);
  align-items:start;
}

.essay-body{
  min-width:0;
  display:grid;
  gap:20px;
  overflow-wrap:break-word;
}

.essay-body article{
  background:var(--card);
  border:1px solid rgba(23,38,35,.1);
  border-radius:var(--radius);
  padding:clamp(18px,2.6vw,28px);
  box-shadow:var(--shadow);
}

article[id]{scroll-margin-top:112px}

.essay-body small,
.side small{
  display:block;
  margin:0 0 5px;
  font-size:14px;
  letter-spacing:.28em;
  color:var(--teal-deep);
}

.essay-body h2{font-size:clamp(21px,2.6vw,26px);margin:0 0 .55em}
.essay-body h3{font-size:19px;margin:1.2em 0 .4em}
.essay-body p{margin:0 0 1em}
.essay-body ul,.essay-body ol{margin:0 0 1em;padding-left:1.3em}
.essay-body li{margin:.32em 0}
.essay-body a{
  color:var(--teal-deep);
  text-decoration:underline;
  text-underline-offset:3px;
  text-decoration-thickness:1px;
}
.essay-body a:hover{color:var(--ink)}

.essay-body figure{
  margin:1.2em 0;
  border-radius:var(--radius);
  overflow:hidden;
  background:#efe4d3;
  box-shadow:var(--shadow);
}
.essay-body figure img{display:block;width:100%;height:auto}
.essay-body figcaption{
  padding:10px 14px;
  font-size:14px;
  color:var(--ink-soft);
  background:#f5ecdd;
}
.essay-body img{border-radius:14px}

.essay-body blockquote{
  margin:1.2em 0;
  padding:14px 18px;
  border-left:3px solid var(--clay);
  border-radius:0 14px 14px 0;
  background:#f8f0e3;
  color:var(--ink-soft);
}

.essay-body table{
  display:block;
  width:100%;
  max-width:100%;
  overflow-x:auto;
  border-collapse:collapse;
  margin:1em 0;
  font-size:16px;
}
.essay-body th,.essay-body td{
  border:1px solid var(--line);
  padding:9px 12px;
  text-align:left;
}
.essay-body th{background:#f2e8d8}

.side{
  position:sticky;
  top:104px;
  padding:18px 16px;
  background:var(--card);
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
}
.side h2{
  font-size:18px;
  margin:0 0 12px;
  padding-bottom:10px;
  border-bottom:1px dashed var(--line);
}
.side-list{list-style:none;margin:0;padding:0;display:grid;gap:2px}
.side-list a{
  display:flex;
  align-items:center;
  min-height:42px;
  padding:4px 9px;
  font-size:15px;
  color:var(--ink-soft);
  text-decoration:none;
  border-left:2px solid transparent;
  border-radius:11px;
  transition:background-color .25s ease-out,color .25s ease-out;
}
.side-list a:hover{
  color:var(--ink);
  background:rgba(92,198,176,.16);
  border-left-color:var(--teal);
}

/* --- 页脚 --- */
.foot{
  padding:clamp(34px,5vw,54px) clamp(20px,5vw,64px) 22px;
  display:grid;
  grid-template-columns:minmax(0,1.4fr) minmax(0,1fr);
  gap:10px 40px;
  font-size:15px;
  color:#e9dfcd;
  background:linear-gradient(180deg,#1e332d,#121d1a);
}
.foot p{margin:0}
.foot-brand{max-width:46ch;line-height:1.75;color:rgba(233,223,205,.74)}
.foot-brand strong{
  display:block;
  margin-bottom:8px;
  font-family:var(--font-head);
  font-size:22px;
  letter-spacing:.14em;
  color:var(--teal);
}
.foot-links{display:flex;flex-wrap:wrap;gap:0 18px;align-content:start}
.foot-links a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  color:#e9dfcd;
  text-decoration:none;
  border-bottom:1px solid transparent;
}
.foot-links a:hover{color:var(--teal);border-bottom-color:var(--teal)}
.foot-copy{
  grid-column:1 / -1;
  margin-top:18px;
  padding-top:16px;
  border-top:1px solid rgba(233,223,205,.16);
  text-align:center;
  font-size:14px;
  color:rgba(233,223,205,.56);
}
.foot-copy a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:0 6px;
  color:var(--teal);
  text-decoration:none;
}

/* --- 断点 --- */
@media (max-width:900px){
  .head-inner{grid-template-columns:1fr;gap:4px;padding:8px 12px}
  .brand{order:-1}
  .head-inner nav ol{flex-wrap:wrap;justify-content:center}
  .head-r ol{justify-content:center}
  .head-inner nav a{font-size:15px;padding:9px 9px;min-height:40px}

  .strip{padding:7px 14px}

  .hero{grid-template-columns:minmax(0,1fr);min-height:0}
  .hero-art{max-width:420px;aspect-ratio:4/3}
  .hero-art::before{inset:-9px}

  .essay{grid-template-columns:minmax(0,1fr)}
  .side{position:static}

  .foot{grid-template-columns:1fr}
}

@media (max-width:420px){
  .brand-name{font-size:18px;letter-spacing:.1em}
  .seal{width:34px;height:34px;font-size:16px}
  .hero-desc{font-size:17px}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .hero-art::before,.blob{animation:none}
  *{transition-duration:.01ms !important;animation-duration:.01ms !important;animation-iteration-count:1 !important}
}

button[aria-expanded]{min-width:44px;min-height:44px}
