:root{
  --lime:#80ff00;
  --green:#00ff00;
  --ink:#1f2617;
  --ink2:#2b3324;
  --paper:#f2ffe4;
  --line:rgba(128,255,0,.32);
  --r:10px;
}

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

html{
  scroll-behavior:smooth;
  -webkit-text-size-adjust:100%;
  background:var(--ink);
}

body{
  margin:0;
  font-family:"Space Mono",ui-monospace,SFMono-Regular,Menlo,Consolas,"PingFang SC","Hiragino Sans GB","Microsoft YaHei",monospace;
  font-size:17px;
  line-height:1.7;
  color:var(--paper);
  overflow-x:hidden;
  background:
    radial-gradient(900px 520px at 88% -12%, rgba(128,255,0,.20), transparent 70%),
    radial-gradient(700px 430px at -6% 18%, rgba(0,255,0,.13), transparent 66%),
    radial-gradient(600px 380px at 50% 108%, rgba(128,255,0,.10), transparent 70%),
    var(--ink);
  background-attachment:fixed;
}

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

a{color:var(--green)}

::selection{background:var(--green);color:var(--ink)}

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

/* ---------- 顶栏 ---------- */
.bar{
  position:sticky;
  top:0;
  z-index:50;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:9px 16px;
  background:rgba(31,38,23,.88);
  backdrop-filter:blur(9px) saturate(140%);
  border-bottom:3px solid var(--lime);
}

.mark{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:46px;
  min-height:46px;
  padding:6px;
  border-radius:12px;
  background:var(--lime);
  color:var(--ink);
  text-decoration:none;
  border:2px solid var(--ink);
  box-shadow:4px 4px 0 rgba(0,0,0,.55);
  transform:rotate(-6deg);
  animation:jitter 3.6s ease-in-out infinite;
}

.mark-img{width:30px;height:30px;object-fit:contain}

.mark-char{
  font-family:Syncopate,"PingFang SC","Microsoft YaHei",sans-serif;
  font-weight:700;
  font-size:19px;
  line-height:1;
}

@keyframes jitter{
  0%,100%{transform:rotate(-6deg)}
  50%{transform:rotate(-2.6deg) translateY(-2px)}
}

.cta{
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:9px 18px;
  border-radius:999px;
  background:var(--green);
  color:var(--ink);
  font-weight:700;
  font-size:15px;
  text-decoration:none;
  border:2px solid var(--ink);
  box-shadow:0 6px 0 rgba(0,0,0,.5);
  transform:rotate(1.6deg);
  white-space:nowrap;
}

.cta:active{transform:translateY(4px) rotate(1.6deg);box-shadow:0 2px 0 rgba(0,0,0,.5)}

/* ---------- 跑马灯 ---------- */
.tape{
  overflow:hidden;
  border-bottom:2px dashed rgba(128,255,0,.45);
  background:rgba(0,255,0,.07);
}

.tape-track{
  display:flex;
  gap:0;
  width:max-content;
  padding:6px 0;
  font-size:12px;
  letter-spacing:.26em;
  color:var(--lime);
  animation:marquee 26s linear infinite;
}

.tape-track span{white-space:nowrap;padding-right:1.4em}

@keyframes marquee{to{transform:translateX(-50%)}}

/* ---------- 骨架 ---------- */
.shell{
  display:grid;
  grid-template-columns:214px minmax(0,1fr);
  gap:26px;
  align-items:start;
  max-width:1200px;
  margin:0 auto;
  padding:22px 16px 70px;
}

/* ---------- 左侧栏 ---------- */
.rail{position:sticky;top:80px;z-index:30;min-width:0}

.rail nav{
  border:2px solid var(--lime);
  border-radius:var(--r);
  background:rgba(43,51,36,.94);
  padding:12px;
  transform:rotate(-1.5deg);
  box-shadow:7px 7px 0 rgba(0,0,0,.5);
}

.rail-t{
  margin:0 0 10px;
  font-size:12px;
  letter-spacing:.3em;
  font-weight:400;
  color:var(--green);
}

.rail-t span{
  display:inline-block;
  border-bottom:2px solid var(--green);
  padding-bottom:2px;
}

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

.rail-list a{
  display:flex;
  align-items:center;
  gap:9px;
  min-height:42px;
  padding:8px 9px;
  border-radius:8px;
  border:1px solid transparent;
  color:var(--paper);
  font-size:15px;
  line-height:1.35;
  text-decoration:none;
}

.rail-list .n{
  font-size:11px;
  letter-spacing:.1em;
  color:var(--lime);
  opacity:.85;
}

.rail-list a:hover,
.rail-list a:focus-visible,
.rail-list a.on{
  background:var(--lime);
  color:var(--ink);
  border-color:var(--ink);
  transform:translateX(3px);
}

.rail-list a:hover .n,
.rail-list a:focus-visible .n,
.rail-list a.on .n{color:var(--ink)}

/* ---------- 主体 ---------- */
.main{min-width:0}

.post{
  display:flex;
  flex-direction:column;
  gap:26px;
  min-width:0;
}

@keyframes rise{
  from{opacity:.15;translate:0 20px}
  to{opacity:1;translate:0 0}
}

.post > article.in{animation:rise .55s cubic-bezier(.2,.72,.3,1) both}

/* ---------- 头部拼贴 ---------- */
.hero{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  min-height:45vh;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:10px;
  text-align:center;
  padding:36px 18px 40px;
  border-radius:16px;
  border:2px solid rgba(128,255,0,.55);
  background:linear-gradient(155deg, rgba(128,255,0,.18), rgba(0,255,0,.05) 62%, transparent);
  box-shadow:0 16px 0 rgba(0,0,0,.28);
}

.ghost{
  position:absolute;
  left:-4%;
  right:-4%;
  bottom:2%;
  z-index:-1;
  text-align:center;
  white-space:nowrap;
  font-family:Syncopate,"PingFang SC","Microsoft YaHei",sans-serif;
  font-weight:700;
  font-size:clamp(58px,17vw,188px);
  line-height:.78;
  letter-spacing:-.055em;
  color:var(--lime);
  opacity:.17;
  mix-blend-mode:screen;
  transform:rotate(-5deg);
  pointer-events:none;
}

.hero-kicker{
  margin:0;
  font-size:12px;
  letter-spacing:.34em;
  color:var(--green);
}

.hero-h1{
  margin:0;
  font-family:Syncopate,"PingFang SC","Microsoft YaHei",sans-serif;
  font-weight:700;
  font-size:clamp(29px,7.2vw,62px);
  line-height:1.12;
  letter-spacing:-.02em;
  color:var(--paper);
  text-shadow:4px 4px 0 rgba(0,255,0,.32);
}

.hero-sub{
  margin:0;
  max-width:34ch;
  font-size:15px;
  color:rgba(242,255,228,.86);
}

.collage{
  display:flex;
  flex-wrap:wrap;
  gap:14px;
  justify-content:center;
  margin-top:12px;
}

.collage img{
  width:180px;
  max-width:42vw;
  border-radius:12px;
  border:3px solid var(--paper);
  box-shadow:9px 11px 0 rgba(0,0,0,.45);
  filter:saturate(150%);
  will-change:translate;
}

.collage img.c0{transform:rotate(-4.5deg)}
.collage img.c1{transform:rotate(3.5deg) translateY(-10px)}

/* ---------- 正文区块 ---------- */
.post > article[id]{scroll-margin-top:88px}

.post > article:not(.hero){
  position:relative;
  background:rgba(43,51,36,.74);
  border:1px solid var(--line);
  border-radius:var(--r);
  padding:22px 20px;
  box-shadow:0 10px 0 rgba(0,0,0,.26);
}

.post > article:not(.hero):nth-child(even){transform:rotate(-.35deg)}
.post > article:not(.hero):nth-child(odd){transform:rotate(.28deg)}

.post article h2{
  margin:.1em 0 .55em;
  font-family:Syncopate,"PingFang SC","Microsoft YaHei",sans-serif;
  font-weight:700;
  font-size:clamp(22px,4.6vw,33px);
  line-height:1.22;
  letter-spacing:-.015em;
  color:var(--lime);
}

.post article h2 span{
  display:inline-block;
  padding-bottom:3px;
  border-bottom:4px solid var(--green);
  transform:rotate(-1deg);
}

.post article h3{
  margin:1.2em 0 .4em;
  font-size:19px;
  line-height:1.4;
  color:var(--green);
}

.post article h3 span{
  display:inline-block;
  border-bottom:2px dotted var(--green);
}

.post article p{margin:0 0 1em}
.post article p:last-child{margin-bottom:0}

.post article a{
  color:var(--green);
  text-decoration:underline 2px;
  text-underline-offset:3px;
  word-break:break-word;
}

.post article ul,
.post article ol{margin:0 0 1em;padding-left:1.3em}

.post article li{margin:.36em 0}
.post article li::marker{color:var(--lime)}

.post article blockquote{
  margin:1em 0;
  padding:11px 15px;
  border-left:5px solid var(--lime);
  border-radius:0 10px 10px 0;
  background:rgba(128,255,0,.1);
}

.post article blockquote p:last-child{margin-bottom:0}

.post article strong{color:var(--lime)}

.post article time{
  display:inline-block;
  padding:2px 10px;
  border-radius:999px;
  background:var(--green);
  color:var(--ink);
  font-size:12px;
  letter-spacing:.12em;
}

.post article img{
  border-radius:10px;
  border:2px solid rgba(242,255,228,.5);
  box-shadow:6px 6px 0 rgba(0,0,0,.4);
  margin:1em 0;
}

.post article figure{margin:1em 0}
.post article figcaption{font-size:13px;color:rgba(242,255,228,.7);margin-top:.4em}

.post article table{
  display:block;
  width:100%;
  overflow-x:auto;
  border-collapse:collapse;
  font-size:15px;
  margin:1em 0;
}

.post article th,
.post article td{
  border:1px solid var(--line);
  padding:8px 10px;
  text-align:left;
}

.post article th{background:rgba(128,255,0,.12);color:var(--lime)}

.post article hr{
  border:0;
  border-top:2px dashed var(--line);
  margin:1.4em 0;
}

.post article code{
  background:rgba(0,255,0,.14);
  border-radius:5px;
  padding:1px 5px;
  font-size:.92em;
}

/* ---------- 页脚 ---------- */
.foot{
  border-top:4px solid var(--lime);
  background:rgba(0,0,0,.35);
  margin-top:12px;
}

.foot article{
  max-width:1200px;
  margin:0 auto;
  padding:14px 16px;
}

.foot article + article{border-top:1px dashed rgba(128,255,0,.3)}

.foot-brand h2{
  margin:0;
  overflow:hidden;
  white-space:nowrap;
  font-family:Syncopate,"PingFang SC","Microsoft YaHei",sans-serif;
  font-weight:700;
  font-size:clamp(32px,11vw,94px);
  line-height:.92;
  letter-spacing:-.045em;
  color:var(--lime);
  opacity:.9;
}

.foot-brand h2 span{
  display:inline-block;
  animation:slide 9s ease-in-out infinite alternate;
}

@keyframes slide{
  from{transform:translateX(0)}
  to{transform:translateX(-14px)}
}

.foot-copy p{
  margin:0;
  font-size:13px;
  letter-spacing:.09em;
  color:rgba(242,255,228,.7);
}

/* ---------- 窄屏 ---------- */
@media (max-width:820px){
  .shell{
    grid-template-columns:minmax(0,1fr);
    gap:18px;
    padding:14px 14px 56px;
  }

  .rail{position:sticky;top:64px;z-index:40}

  .rail nav{
    transform:none;
    padding:8px 10px;
    box-shadow:4px 5px 0 rgba(0,0,0,.5);
  }

  .rail-t{margin:0 0 6px;font-size:11px;letter-spacing:.24em}

  .rail-list{
    flex-direction:row;
    gap:8px;
    overflow-x:auto;
    padding-bottom:2px;
    scrollbar-width:thin;
  }

  .rail-list a{
    white-space:nowrap;
    min-height:44px;
    padding:9px 12px;
    border:1px solid rgba(128,255,0,.38);
  }

  .rail-list a:hover,
  .rail-list a:focus-visible,
  .rail-list a.on{transform:none}

  .hero{padding:28px 14px 32px;min-height:40vh}
  .hero-h1{font-size:clamp(27px,8.6vw,44px)}
  .post > article:not(.hero){padding:18px 15px}
  .post > article:not(.hero):nth-child(even),
  .post > article:not(.hero):nth-child(odd){transform:none}
  .post > article[id]{scroll-margin-top:150px}
  .foot-copy p{font-size:12px}
}

@media (max-width:420px){
  body{font-size:16px}
  .cta{font-size:14px;padding:9px 14px}
  .collage img{width:44vw}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .tape-track,
  .mark,
  .foot-brand h2 span{animation:none}
  .post > article.in{animation:none}
  *{transition:none!important}
}

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