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

:root{
  --forest:#33483B;
  --sand:#EDE7D9;
  --sage:#9DB49B;
  --ink:#24312A;
  --deep:#1E2A23;
  --bar:58px;
  --rail:236px;
  --serif:'Lora',"Songti SC","Noto Serif SC",Georgia,serif;
  --sans:'Raleway',system-ui,-apple-system,"PingFang SC","Microsoft YaHei",sans-serif;
}

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

html{
  scroll-behavior:smooth;
  scroll-padding-top:calc(var(--bar) + 16px);
  -webkit-text-size-adjust:100%;
}

body{
  margin:0;
  background:var(--sand);
  color:var(--ink);
  font:400 17px/1.85 var(--sans);
  overflow-x:hidden;
}

a{color:var(--forest)}

/* ---------- 顶部细条 ---------- */
.topbar{
  position:fixed;
  top:0;left:0;right:0;
  height:var(--bar);
  display:flex;
  align-items:center;
  gap:14px;
  padding:0 14px;
  background:var(--forest);
  color:var(--sand);
  border-bottom:1px solid rgba(157,180,155,.35);
  z-index:80;
}

.mark{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:38px;height:38px;
  flex:0 0 auto;
  border-radius:50%;
  background:var(--sand);
  color:var(--forest);
  font-family:var(--serif);
  font-size:19px;
  font-weight:600;
  line-height:1;
  text-decoration:none;
  transition:transform .35s ease,background .3s ease;
}
.mark:hover{transform:rotate(-9deg) scale(1.07);background:var(--sage)}

.slogan{
  flex:1 1 auto;
  min-width:0;
  font-size:16px;
  line-height:1.5;
  letter-spacing:.05em;
  opacity:.85;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.menu-btn{
  display:none;
  align-items:center;
  min-height:40px;
  padding:0 14px;
  border:1px solid rgba(237,231,217,.55);
  border-radius:999px;
  background:transparent;
  color:var(--sand);
  font:500 16px/1 var(--sans);
  cursor:pointer;
  transition:background .25s ease,color .25s ease;
}
.menu-btn:hover{background:var(--sand);color:var(--forest)}

/* ---------- 左侧竖排导航 ---------- */
.rail{
  position:fixed;
  top:var(--bar);
  bottom:0;
  left:0;
  width:var(--rail);
  padding:26px 16px 30px;
  display:flex;
  flex-direction:column;
  gap:10px;
  overflow-y:auto;
  background:linear-gradient(180deg,rgba(51,72,59,.08),rgba(157,180,155,.2));
  border-right:1px solid rgba(51,72,59,.18);
  z-index:70;
  transition:transform .36s cubic-bezier(.3,.7,.25,1);
}

.rail-h{
  margin:0;
  font:500 16px/1.4 var(--sans);
  letter-spacing:.34em;
  color:var(--forest);
}

.rail hr{
  width:100%;
  height:2px;
  border:0;
  margin:0 0 4px;
  background:linear-gradient(90deg,var(--sage),transparent);
}

.rail nav ul{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:3px;
}

.rail nav a{
  display:flex;
  align-items:center;
  gap:10px;
  min-height:44px;
  padding:10px 12px;
  color:var(--forest);
  text-decoration:none;
  font-size:16px;
  line-height:1.5;
  border-radius:2px;
  transition:background .26s ease,color .26s ease,padding .26s ease;
}

.rail nav a::before{
  content:"";
  width:6px;height:6px;
  flex:0 0 auto;
  border-radius:50%;
  background:var(--sage);
  transition:width .3s ease,height .3s ease,border-radius .3s ease,background .3s ease;
}

.rail nav a:hover,
.rail nav a.on{background:var(--forest);color:var(--sand);padding-left:16px}
.rail nav a:hover::before,
.rail nav a.on::before{width:18px;height:3px;border-radius:2px;background:var(--sand)}

/* ---------- 主体 ---------- */
main{
  margin-left:var(--rail);
  padding-top:var(--bar);
}

/* ---------- 首屏 ---------- */
.hero{
  position:relative;
  display:flex;
  align-items:flex-end;
  justify-content:flex-end;
  min-height:calc(100vh - var(--bar));
  min-height:calc(100svh - var(--bar));
  padding:clamp(28px,5vw,64px);
  padding-bottom:calc(clamp(28px,5vw,64px) + 54px);
  overflow:hidden;
  background:var(--forest);
  color:var(--sand);
}

.hero::after{
  content:"";
  position:absolute;
  left:0;right:0;bottom:-1px;
  height:clamp(34px,7vw,74px);
  background:var(--sand);
  clip-path:polygon(0 100%,100% 0,100% 100%);
  z-index:2;
}

.layer{
  position:absolute;
  inset:-12% 0 -34% 0;
  pointer-events:none;
  will-change:transform;
}
.l1{background:radial-gradient(120% 88% at 84% 10%,rgba(157,180,155,.36),transparent 62%)}
.l2{background:linear-gradient(116deg,transparent 45%,rgba(237,231,217,.1) 45.15%,rgba(237,231,217,.1) 62%,transparent 62.15%)}
.l3{background:linear-gradient(0deg,var(--deep),transparent 58%);opacity:.85}

.hero-inner{
  position:relative;
  z-index:3;
  max-width:min(100%,34ch);
  text-align:right;
  animation:rise 1s cubic-bezier(.2,.75,.25,1) both;
}

@keyframes rise{
  from{opacity:0;transform:translateY(34px)}
  to{opacity:1;transform:none}
}

.hero-kicker{
  margin:0 0 14px;
  font-size:16px;
  line-height:1.5;
  letter-spacing:.42em;
  opacity:.72;
}

.hero h1{
  margin:0 0 20px;
  font:600 clamp(2.7rem,8vw,6rem)/1.04 var(--serif);
  letter-spacing:-.01em;
  word-break:break-word;
}

.hero-desc{
  margin:0;
  font-size:16px;
  line-height:1.75;
  opacity:.82;
}

.hero-slash{
  display:block;
  width:88px;
  height:5px;
  margin:24px 0 0 auto;
  background:var(--sage);
  transform:skewX(-26deg);
}

/* ---------- 正文章节 ---------- */
article > section{
  padding-block:clamp(54px,8vw,104px);
  padding-inline:max(20px,calc((100% - 72ch)/2));
  border-top:1px solid rgba(51,72,59,.16);
  scroll-margin-top:calc(var(--bar) + 18px);
}

article > section:nth-of-type(even){
  background:rgba(157,180,155,.17);
}

article > section h2{
  margin:0 0 10px;
  font:600 clamp(1.55rem,3.2vw,2.1rem)/1.3 var(--serif);
  color:var(--forest);
  letter-spacing:-.01em;
}

article > section h2 + hr{
  width:76px;
  height:3px;
  border:0;
  margin:0 0 26px;
  background:var(--sage);
}

article > section h3{
  margin:34px 0 10px;
  font:600 clamp(1.2rem,2.2vw,1.45rem)/1.4 var(--serif);
  color:var(--forest);
}

article > section p,
article > section ul,
article > section ol,
article > section blockquote{margin:0 0 1.15em}

article > section ul,
article > section ol{padding-left:1.3em}
article > section li{margin:0 0 .45em}

article > section blockquote{
  padding:14px 20px;
  border-left:4px solid var(--sage);
  background:rgba(51,72,59,.06);
  color:var(--forest);
}

article > section a{color:var(--forest);text-decoration:underline;text-decoration-color:var(--sage);text-underline-offset:4px}
article > section a:hover{background:rgba(157,180,155,.35)}

article > section img{
  display:block;
  max-width:100%;
  height:auto;
  border-radius:18px;
  margin:26px 0;
}

article > section strong{color:var(--forest)}

/* ---------- 页脚 ---------- */
.foot{
  background:var(--forest);
  color:var(--sand);
  padding:clamp(40px,6vw,72px) clamp(20px,5vw,56px) 18px;
}

.foot-cta{
  margin:0 0 clamp(30px,5vw,52px);
  padding:clamp(26px,4vw,46px);
  border:1px solid rgba(237,231,217,.32);
  border-radius:18px;
  background:linear-gradient(142deg,rgba(157,180,155,.2),transparent 62%);
}

.foot-cta h2{
  margin:0 0 12px;
  font:600 clamp(1.7rem,4vw,2.6rem)/1.15 var(--serif);
}

.foot-cta hr{
  width:92px;
  height:4px;
  border:0;
  margin:0 0 22px;
  background:var(--sage);
}

.foot-btn{
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:0 24px;
  border-radius:999px;
  background:var(--sand);
  color:var(--forest);
  font-size:16px;
  font-weight:600;
  text-decoration:none;
  transition:transform .25s ease,background .25s ease;
}
.foot-btn:hover{transform:translateY(-3px);background:var(--sage)}

.foot-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:28px 20px;
  padding-bottom:34px;
  border-bottom:1px solid rgba(237,231,217,.25);
}

.foot-col p{margin:0 0 6px;font-size:16px;line-height:1.7;opacity:.82}
.foot-col ul{list-style:none;margin:0;padding:0}

.foot-col a{
  display:inline-flex;
  align-items:center;
  min-height:44px;
  color:var(--sand);
  font-size:16px;
  text-decoration:none;
  opacity:.85;
  transition:opacity .2s ease,transform .2s ease;
}
.foot-col a:hover{opacity:1;transform:translateX(3px)}

.foot-brand .mark{background:var(--sand);color:var(--forest);margin-bottom:10px}

.foot-base{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding-top:16px;
  font-size:16px;
  line-height:1.6;
  opacity:.7;
}

/* ---------- 滚动触发 ---------- */
html.js .reveal{
  opacity:0;
  transform:translateY(26px);
  transition:opacity .85s ease,transform .85s cubic-bezier(.22,.72,.3,1);
}
html.js .reveal.in{opacity:1;transform:none}

/* ---------- 移动端 ---------- */
@media (max-width:900px){
  .rail{
    width:min(84vw,302px);
    transform:translateX(-101%);
    box-shadow:24px 0 46px rgba(30,42,35,.22);
  }
  .rail.open{transform:none}
  main{margin-left:0}
  .menu-btn{display:inline-flex}
  .foot-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .foot-brand{grid-column:1 / -1}
}

@media (max-width:520px){
  .slogan{font-size:16px;letter-spacing:.02em}
  .hero{padding-bottom:calc(clamp(28px,5vw,64px) + 46px)}
  .hero-inner{max-width:100%}
  .hero-desc{font-size:16px}
  .foot-cta hr{width:64px}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{
    animation-duration:.001ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.001ms !important;
  }
  html.js .reveal{opacity:1;transform:none}
}

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