:root {
  --ink: #192617;
  --ink-2: #10200f;
  --neon: #87ff71;
  --mustard: #ffce5c;
  --paper: #f3ffe9;
  --muted: #a8c79b;
  --pad: clamp(1rem, 3.2vw, 2.6rem);
  --line: 3px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 17px;
  line-height: 1.68;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(var(--neon) 1.2px, transparent 1.2px);
  background-size: 26px 26px;
  opacity: 0.13;
}

body::after {
  content: "";
  position: fixed;
  right: -80px;
  bottom: -60px;
  width: 260px;
  height: 260px;
  z-index: 0;
  pointer-events: none;
  background: var(--mustard);
  opacity: 0.1;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  transform: rotate(-14deg);
}

a { color: var(--neon); }

/* ---------- 头部 ---------- */
.site-head {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem var(--pad);
  background: var(--ink);
  border-bottom: var(--line) solid var(--neon);
}

.brand {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 100%;
  padding: 0.35rem 0.85rem;
  background: var(--mustard);
  color: var(--ink);
  text-decoration: none;
  border: var(--line) solid var(--neon);
  font-weight: 700;
  letter-spacing: 0.08em;
  transform: rotate(-1.6deg);
  transition: transform 0.18s ease, background 0.18s ease;
}

.brand:hover { transform: rotate(1.2deg) translateY(-2px); background: var(--neon); }

.brand-word { font-size: 1.05rem; white-space: nowrap; }
.brand-logo { display: block; width: 30px; height: 30px; object-fit: contain; }

.drawer { position: relative; }
.drawer > summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 44px;
  padding: 0.5rem 0.8rem;
  border: var(--line) dashed var(--mustard);
  color: var(--paper);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  transition: background 0.16s ease, color 0.16s ease;
}
.drawer > summary::-webkit-details-marker { display: none; }
.drawer > summary:hover { background: var(--neon); color: var(--ink); }

.burger {
  width: 18px;
  height: 13px;
  background:
    linear-gradient(var(--neon), var(--neon)) 0 0 / 100% 3px no-repeat,
    linear-gradient(var(--neon), var(--neon)) 0 50% / 100% 3px no-repeat,
    linear-gradient(var(--neon), var(--neon)) 0 100% / 100% 3px no-repeat;
}
.drawer > summary:hover .burger,
.drawer[open] > summary .burger {
  background:
    linear-gradient(var(--ink), var(--ink)) 0 0 / 100% 3px no-repeat,
    linear-gradient(var(--ink), var(--ink)) 0 50% / 100% 3px no-repeat,
    linear-gradient(var(--ink), var(--ink)) 0 100% / 100% 3px no-repeat;
}

.panel {
  position: fixed;
  inset: 0;
  z-index: 35;
  margin: 0;
  padding: 5.5rem var(--pad) 3rem;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  overflow-y: auto;
  color: var(--ink);
  clip-path: polygon(0 0, 100% 0, 100% 94%, 58% 100%, 0 95%);
}

.site-head > details:first-child > .panel { background: var(--neon); }
.site-head > details:last-child > .panel { background: var(--mustard); }

.panel a {
  display: flex;
  align-items: center;
  min-height: 54px;
  padding: 0.55rem 0.2rem;
  color: var(--ink);
  text-decoration: none;
  font-size: 1.22rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border-bottom: 2px dashed rgba(25, 38, 23, 0.35);
  transition: padding-left 0.16s ease;
}
.panel a:hover { padding-left: 0.6rem; }

.drawer[open] > summary {
  position: fixed;
  top: 0.7rem;
  z-index: 40;
  background: var(--mustard);
  border-style: solid;
  border-color: var(--ink);
  color: var(--ink);
}
.site-head > details:first-child[open] > summary { left: var(--pad); }
.site-head > details:last-child[open] > summary { right: var(--pad); }

/* ---------- 主体 ---------- */
main { position: relative; z-index: 1; }

.hero {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 1.2rem;
  min-height: 45vh;
  padding: 2rem var(--pad) 3.2rem;
  border-bottom: 4px solid var(--neon);
  background:
    repeating-linear-gradient(135deg, rgba(135, 255, 113, 0.14) 0 12px, transparent 12px 24px),
    var(--ink-2);
  clip-path: polygon(0 0, 100% 0, 100% 90%, 0 100%);
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 46%;
  height: 10px;
  background: var(--mustard);
  clip-path: polygon(0 0, 100% 100%, 0 100%);
}

.hero-art {
  margin: 0;
  width: clamp(92px, 17vw, 168px);
  transform: rotate(-6deg);
}
.hero-art svg { display: block; width: 100%; height: auto; }

.hero-copy {
  justify-self: end;
  max-width: 44rem;
  text-align: right;
}

.eyebrow {
  display: inline-block;
  font-size: 0.95rem;
  letter-spacing: 0.22em;
  color: var(--mustard);
  padding: 0.15rem 0.5rem;
  border-bottom: var(--line) solid var(--neon);
}

.hero h1 {
  margin: 0.5rem 0 0;
  font-size: clamp(1.85rem, 6.4vw, 3.3rem);
  line-height: 1.16;
  letter-spacing: -0.01em;
  word-break: break-word;
}

/* ---------- 主体分栏 ---------- */
.shell {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 2.6rem);
  max-width: 1180px;
  margin: 0 auto;
  padding: 2.2rem var(--pad) 3.5rem;
  align-items: start;
}

.rail {
  position: sticky;
  top: 84px;
  align-self: start;
  padding: 1rem 0.9rem 1.2rem;
  background: rgba(255, 206, 92, 0.07);
  border: var(--line) solid var(--mustard);
  transform: rotate(-0.7deg);
}

.rail-kicker {
  display: inline-block;
  font-size: 0.95rem;
  letter-spacing: 0.22em;
  color: var(--mustard);
}

.rail h2 {
  margin: 0.15rem 0 0;
  font-size: 1.28rem;
  line-height: 1.3;
  padding-bottom: 0.5rem;
  border-bottom: var(--line) dotted var(--neon);
}

.rail-list {
  list-style: none;
  margin: 0.6rem 0 0;
  padding: 0;
}

.rail-list a {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 0.35rem 0.3rem;
  color: var(--paper);
  text-decoration: none;
  font-size: 1rem;
  border-bottom: 1px dotted rgba(135, 255, 113, 0.35);
  transition: background 0.15s ease, color 0.15s ease, padding-left 0.15s ease;
}
.rail-list a:hover { background: var(--neon); color: var(--ink); padding-left: 0.6rem; }

/* ---------- 正文流 ---------- */
.stream { min-width: 0; }

.stream > article {
  scroll-margin-top: 100px;
  padding: 1.6rem 0 1.9rem;
  border-top: 2px dashed rgba(135, 255, 113, 0.3);
}
.stream > article:first-child { border-top: 0; padding-top: 0.4rem; }

.stream h2 {
  margin: 0.2rem 0 0.7rem;
  font-size: clamp(1.32rem, 3.6vw, 1.95rem);
  line-height: 1.28;
  padding-left: 0.7rem;
  border-left: 9px solid var(--neon);
}

.stream h3 {
  margin: 1.3rem 0 0.5rem;
  font-size: 1.16rem;
  line-height: 1.4;
  color: var(--mustard);
}

.stream small {
  display: inline-block;
  font-size: 0.95rem;
  letter-spacing: 0.2em;
  color: var(--mustard);
  margin-bottom: 0.1rem;
}

.stream p { margin: 0.6rem 0; }

.stream ul,
.stream ol { margin: 0.6rem 0; padding-left: 1.35rem; }
.stream li { margin: 0.3rem 0; }

.stream a { color: var(--neon); text-underline-offset: 3px; }
.stream a:hover { background: var(--neon); color: var(--ink); text-decoration: none; }

.stream strong { color: var(--neon); }

.stream blockquote {
  margin: 1rem 0;
  padding: 0.7rem 1rem;
  border-left: 9px solid var(--mustard);
  background: rgba(255, 206, 92, 0.08);
}
.stream blockquote p { margin: 0.25rem 0; }

.stream figure {
  margin: 1rem 0;
  padding: 0.5rem;
  border: var(--line) solid var(--mustard);
  transform: rotate(-0.5deg);
}
.stream figure img { display: block; width: 100%; height: auto; }

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

.stream table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 1rem;
}
.stream th,
.stream td {
  border: 2px solid rgba(135, 255, 113, 0.45);
  padding: 0.45rem 0.6rem;
  text-align: left;
  vertical-align: top;
}
.stream th { background: rgba(135, 255, 113, 0.12); color: var(--paper); }

.stream code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: rgba(135, 255, 113, 0.14);
  padding: 0.1rem 0.35rem;
}

/* ---------- 页脚 ---------- */
.site-foot {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 1.4rem var(--pad) 1.8rem;
  background: var(--ink-2);
  border-top: 4px solid var(--mustard);
}

.site-foot address {
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--neon);
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.foot-links a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0.3rem 0.75rem;
  color: var(--paper);
  text-decoration: none;
  font-size: 1rem;
  border: 2px dotted rgba(255, 206, 92, 0.65);
  transition: background 0.15s ease, color 0.15s ease;
}
.foot-links a:hover { background: var(--mustard); color: var(--ink); }

.copy {
  width: 100%;
  margin: 0;
  font-size: 1rem;
  color: var(--muted);
}

/* ---------- 窄屏 ---------- */
@media (max-width: 860px) {
  .shell {
    grid-template-columns: minmax(0, 1fr);
    padding-top: 1.6rem;
  }
  .rail {
    position: static;
    transform: none;
    order: -1;
  }
  .rail-list { display: grid; grid-template-columns: 1fr 1fr; gap: 0 0.6rem; }
  .rail-list a { border-bottom: 1px dotted rgba(135, 255, 113, 0.3); }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: 45vh;
    padding-bottom: 2.6rem;
    gap: 0.9rem;
  }
  .hero-art { width: 78px; order: -1; transform: rotate(-8deg); }
  .hero-copy { justify-self: stretch; text-align: right; max-width: none; }
  .brand-word { font-size: 0.98rem; }
  .drawer > summary { padding: 0.45rem 0.6rem; font-size: 0.95rem; }
  .panel a { font-size: 1.1rem; }
  .stream h2 { padding-left: 0.55rem; border-left-width: 7px; }
  .site-foot { justify-content: flex-start; }
}

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

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