@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;500;600&family=Cormorant+Garamond:ital,wght@0,300;0,500;0,700;1,300;1,500&family=Crimson+Pro:ital,wght@0,300;0,400;0,600;1,300;1,400&display=swap');

:root{
  --ink:#192617;
  --neon:#87ff71;
  --sun:#ffce5c;
  --paper:#f7f2e3;
  --paper2:#eee6d0;
  --rule:4px solid var(--ink);
}

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

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

body{
  margin:0;
  color:var(--ink);
  font-family:'Crimson Pro','Songti SC','Noto Serif SC',Georgia,serif;
  font-size:17px;
  line-height:1.85;
  background-color:var(--paper);
  background-image:radial-gradient(rgba(25,38,23,.13) 1.1px,transparent 1.1px);
  background-size:22px 22px;
  overflow-x:hidden;
}

:focus-visible{outline:3px solid var(--neon);outline-offset:3px}

summary,.brand,.f-links a,.rail-list a,.drop menu a,.f-sub button{
  transition:background .18s ease,color .18s ease,transform .18s ease,box-shadow .18s ease,padding .18s ease;
}

/* 顶部细条 */
.top{
  position:sticky;
  top:0;
  z-index:50;
  background:var(--paper);
  border-bottom:var(--rule);
}

.strip{
  margin:0;
  display:flex;
  align-items:center;
  gap:12px;
  padding:6px 18px;
  background:var(--neon);
  border-bottom:2px dashed var(--ink);
  font-family:'Cinzel','Songti SC',serif;
  font-size:14px;
  line-height:1.5;
  letter-spacing:.3em;
}

.strip-t{flex:0 1 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}

.strip-a{
  width:26px;height:10px;flex:0 0 auto;background:var(--ink);
  clip-path:polygon(0 0,100% 50%,0 100%);
}

.strip-b{
  width:14px;height:14px;flex:0 0 auto;border-radius:50%;
  background:var(--sun);border:2px solid var(--ink);
  margin-left:auto;
}

/* 品牌与菜单 */
.bar{
  display:grid;
  grid-template-columns:1fr auto 1fr;
  align-items:center;
  gap:10px;
  padding:12px 18px;
}

.brand{
  justify-self:center;
  font-family:'Cinzel','Cormorant Garamond','Songti SC',serif;
  font-size:clamp(18px,3.2vw,28px);
  line-height:1.3;
  letter-spacing:.13em;
  color:var(--ink);
  text-decoration:none;
  white-space:nowrap;
  background:var(--sun);
  border:3px solid var(--ink);
  padding:4px 14px;
  box-shadow:5px 5px 0 var(--ink);
  transform:rotate(-1.4deg);
}

.brand:hover{
  transform:rotate(1.4deg) translate(-2px,-2px);
  box-shadow:9px 9px 0 var(--neon);
}

.side{display:flex;min-width:0}
.side-r{justify-content:flex-end}

.drop{position:relative}

summary{
  list-style:none;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:8px 18px;
  border:3px solid var(--ink);
  border-radius:999px;
  background:var(--paper);
  color:var(--ink);
  font-family:'Cinzel','Songti SC',serif;
  font-size:15px;
  letter-spacing:.16em;
  white-space:nowrap;
}

summary::-webkit-details-marker{display:none}

summary::after{
  content:"";
  width:9px;height:9px;
  margin-left:9px;
  background:var(--neon);
  border:2px solid var(--ink);
  border-radius:50%;
  flex:0 0 auto;
}

summary:hover{background:var(--sun);transform:rotate(-2deg)}
.drop[open] summary{background:var(--neon);transform:none}

.drop menu{
  position:absolute;
  top:calc(100% + 10px);
  left:0;
  z-index:60;
  margin:0;
  padding:10px;
  list-style:none;
  width:min(74vw,272px);
  background:var(--paper);
  border:3px solid var(--ink);
  box-shadow:8px 8px 0 var(--neon);
}

.side-r .drop menu{left:auto;right:0}

.drop menu li{list-style:none}
.drop menu li + li{margin-top:2px}

.drop menu a{
  display:flex;
  align-items:center;
  min-height:44px;
  padding:8px 12px;
  font-size:16px;
  color:var(--ink);
  text-decoration:none;
  border-bottom:2px dotted rgba(25,38,23,.35);
}

.drop menu a:hover{background:var(--sun);padding-left:20px}

/* 主体网格 */
.shell{
  display:grid;
  grid-template-columns:206px minmax(0,1fr);
  gap:0 32px;
  max-width:1180px;
  margin:0 auto;
  padding:0 20px;
}

.shell > *{grid-column:2;min-width:0}

/* 左侧栏 */
.shell > .rail{
  grid-column:1;
  grid-row:1 / span 64;
  align-self:start;
  position:sticky;
  top:138px;
  margin-top:36px;
  padding:10px 0 26px 16px;
  border-left:var(--rule);
}

.rail-k{
  display:inline-block;
  background:var(--sun);
  border:2px solid var(--ink);
  padding:1px 10px;
  font-family:'Cinzel','Songti SC',serif;
  font-size:14px;
  line-height:1.6;
  letter-spacing:.24em;
}

.rail-h{
  margin:8px 0 14px;
  font-family:'Cinzel','Cormorant Garamond','Songti SC',serif;
  font-size:22px;
  line-height:1.3;
  letter-spacing:.12em;
}

.rail-list{
  margin:0;
  padding:0;
  list-style:none;
  counter-reset:r;
}

.rail-list li{counter-increment:r}

.rail-list a{
  display:block;
  min-height:40px;
  padding:6px 4px;
  color:var(--ink);
  text-decoration:none;
  font-size:16px;
  line-height:1.55;
  border-bottom:1px dotted rgba(25,38,23,.4);
}

.rail-list a::before{
  content:counter(r,decimal-leading-zero);
  font-family:'Cinzel',serif;
  font-size:12px;
  color:#55684a;
  margin-right:8px;
}

.rail-list a:hover{background:var(--neon)}

/* 首屏 */
.hero{
  display:grid;
  grid-template-columns:1.05fr .95fr;
  gap:0 30px;
  align-items:center;
  min-height:70vh;
  padding:42px 0 48px;
  border-bottom:var(--rule);
}

.hero-copy{min-width:0}

.hero-copy h1{
  margin:0 0 20px;
  font-family:'Cinzel','Cormorant Garamond','Songti SC',serif;
  font-size:clamp(30px,5vw,54px);
  line-height:1.26;
  letter-spacing:.05em;
  text-shadow:3px 3px 0 var(--neon);
}

.hero-desc{
  margin:0;
  max-width:46ch;
  font-size:17px;
  line-height:1.85;
  padding-left:16px;
  border-left:7px solid var(--sun);
}

.hero-art{
  position:relative;
  margin:0;
  align-self:stretch;
  min-height:320px;
  background:var(--sun);
  overflow:hidden;
  clip-path:polygon(0 5%,95% 0,100% 93%,7% 100%);
}

.hero-art::before{
  content:"";
  position:absolute;
  left:-12%;
  bottom:-16%;
  width:74%;
  height:64%;
  background:var(--neon);
  clip-path:polygon(50% 0,100% 100%,0 100%);
  mix-blend-mode:multiply;
  z-index:1;
  opacity:.92;
}

.hero-art::after{
  content:"";
  position:absolute;
  right:-46px;
  top:-46px;
  width:158px;
  height:158px;
  border:9px dashed var(--ink);
  border-radius:50%;
  opacity:.55;
  z-index:1;
}

.hero-img{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transform:scale(1.02);
}

/* 正文区块 */
.shell > div[id]{
  padding:46px 0 42px;
  border-bottom:var(--rule);
  scroll-margin-top:158px;
}

.shell > div[id]:last-of-type{border-bottom:0}

.shell > div[id] small{
  display:inline-block;
  margin-bottom:12px;
  padding:2px 12px;
  background:var(--neon);
  border:2px solid var(--ink);
  font-family:'Cinzel','Songti SC',serif;
  font-size:14px;
  line-height:1.6;
  letter-spacing:.28em;
}

.shell > div[id] h2,
.shell > div[id] h3{
  font-family:'Cinzel','Cormorant Garamond','Songti SC',serif;
  line-height:1.36;
  letter-spacing:.04em;
  margin:0 0 16px;
}

.shell > div[id] h2{
  font-size:clamp(24px,3.6vw,36px);
  padding-bottom:10px;
  border-bottom:4px solid var(--ink);
}

.shell > div[id] h3{font-size:clamp(19px,2.4vw,24px);margin-top:30px}

.shell > div[id] p{margin:0 0 18px;max-width:70ch}

.shell > div[id] a{
  color:#1d5222;
  text-decoration:underline;
  text-decoration-color:var(--neon);
  text-decoration-thickness:3px;
  text-underline-offset:3px;
}

.shell > div[id] a:hover{background:var(--sun);color:var(--ink)}

.shell > div[id] ul,
.shell > div[id] ol{padding-left:24px;max-width:70ch;margin:0 0 18px}

.shell > div[id] li{margin-bottom:8px}

.shell > div[id] blockquote{
  margin:24px 0;
  padding:16px 20px;
  background:var(--paper2);
  border-left:9px solid var(--neon);
}

.shell > div[id] figure{
  margin:24px 0;
  padding:9px;
  border:3px solid var(--ink);
  background:var(--paper2);
}

.shell > div[id] img{max-width:100%;height:auto;display:block}

.shell > div[id] table{
  width:100%;
  border-collapse:collapse;
  margin:22px 0;
  font-size:16px;
}

.shell > div[id] th,
.shell > div[id] td{
  border:2px solid var(--ink);
  padding:8px 10px;
  text-align:left;
}

.shell > div[id] th{background:var(--sun)}

.shell > div[id] code{
  font-family:ui-monospace,'SFMono-Regular',Menlo,monospace;
  font-size:15px;
  background:var(--paper2);
  padding:1px 5px;
}

/* 页脚 */
.foot{
  border-top:var(--rule);
  background:var(--ink);
  color:var(--paper);
  display:grid;
  grid-template-columns:1fr 1.5fr 1.4fr auto;
  gap:16px 26px;
  align-items:start;
  padding:36px max(20px,calc((100% - 1140px)/2)) 46px;
  font-size:16px;
}

.foot p{margin:0}

.f-brand{
  justify-self:start;
  background:var(--neon);
  color:var(--ink);
  border:2px solid var(--paper);
  padding:4px 12px;
  font-family:'Cinzel','Songti SC',serif;
  letter-spacing:.14em;
  line-height:1.6;
}

.f-links{display:flex;flex-wrap:wrap;gap:4px 16px}

.f-links a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  color:var(--paper);
  text-decoration:none;
  border-bottom:2px dotted var(--neon);
}

.f-links a:hover{color:var(--neon);background:rgba(135,255,113,.12)}

.f-sub{display:flex;flex-wrap:wrap;gap:8px}

.f-sub input{
  flex:1 1 132px;
  min-width:0;
  min-height:44px;
  padding:8px 12px;
  border:2px solid var(--paper);
  background:transparent;
  color:var(--paper);
  font:inherit;
  font-size:16px;
}

.f-sub input::placeholder{color:rgba(247,242,227,.72)}

.f-sub button{
  min-height:44px;
  padding:8px 20px;
  border:2px solid var(--ink);
  background:var(--sun);
  color:var(--ink);
  font:inherit;
  font-size:16px;
  cursor:pointer;
}

.f-sub button:hover{background:var(--neon)}

.f-copy{
  justify-self:end;
  align-self:center;
  font-family:'Cinzel','Songti SC',serif;
  font-size:15px;
  line-height:1.7;
  letter-spacing:.06em;
}

/* 动画 */
@media (prefers-reduced-motion: no-preference){
  @supports (animation-timeline: view()){
    .hero-img{
      animation:heroDrift linear both;
      animation-timeline:view();
      animation-range:entry 0% exit 100%;
    }
    @keyframes heroDrift{
      from{transform:translateY(-16px) scale(1.08)}
      to{transform:translateY(16px) scale(1.08)}
    }
  }
}

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

/* 断点 */
@media (max-width:900px){
  .shell{
    grid-template-columns:1fr;
    padding:0 16px;
  }
  .shell > *{grid-column:1}
  .shell > .rail{
    grid-row:auto;
    order:2;
    position:static;
    margin-top:0;
    padding:20px 0 6px;
    border-left:0;
    border-top:2px dashed var(--ink);
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:0 20px;
  }
  .rail-k{grid-column:1 / -1;justify-self:start}
  .rail-h{grid-column:1 / -1;margin:8px 0 10px;font-size:19px}
  .rail-list{
    grid-column:1 / -1;
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:0 20px;
  }
  .foot{grid-template-columns:1fr 1fr;gap:20px}
  .f-copy{justify-self:start;align-self:start}
  .hero{min-height:0}
}

@media (max-width:760px){
  .hero{
    grid-template-columns:1fr;
    gap:24px;
    padding:28px 0 36px;
    min-height:0;
  }
  .hero-art{min-height:236px;order:2}
  .hero-copy h1{font-size:clamp(28px,8.4vw,40px)}
  .hero-desc{font-size:17px}
}

@media (max-width:560px){
  body{font-size:17px}
  .bar{padding:10px;gap:6px}
  summary{padding:8px 12px;font-size:14px;letter-spacing:.06em}
  summary::after{display:none}
  .brand{font-size:16px;padding:4px 9px;box-shadow:3px 3px 0 var(--ink);letter-spacing:.08em}
  .brand:hover{box-shadow:4px 4px 0 var(--neon)}
  .strip{font-size:14px;letter-spacing:.16em;padding:5px 12px}
  .shell{padding:0 14px}
  .shell > div[id]{scroll-margin-top:142px;padding:34px 0 30px}
  .foot{grid-template-columns:1fr;padding:30px 16px 40px}
  .f-links{gap:2px 14px}
}

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