@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: #172617;
  --deep: #0a1310;
  --deeper: #060d0a;
  --neon: #69ff69;
  --cyan: #00ffff;
  --paper: #e6fff0;
  --soft: #b9d9c6;
  --line: rgba(105, 255, 105, 0.32);
  --line-cyan: rgba(0, 255, 255, 0.34);
  --chrome: linear-gradient(135deg, #ffffff 0%, #a9ffc4 24%, #7dfff2 48%, #ffffff 64%, #8dffa1 84%, #d6fff0 100%);
  --serif: "Cinzel", "Times New Roman", serif;
  --sans: "Josefin Sans", system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

body {
  margin: 0;
  overflow-x: clip;
  background:
    radial-gradient(900px 640px at 90% -10%, rgba(0, 255, 255, 0.16), transparent 62%),
    radial-gradient(760px 560px at 2% 8%, rgba(105, 255, 105, 0.13), transparent 60%),
    var(--deeper);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.78;
  letter-spacing: 0.01em;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  opacity: 0.5;
  background: repeating-linear-gradient(180deg, rgba(105, 255, 105, 0.05) 0 1px, transparent 1px 4px);
}

img { max-width: 100%; }

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

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

/* ---------- 顶部两行 ---------- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 40;
  background: linear-gradient(180deg, rgba(8, 16, 12, 0.97), rgba(8, 16, 12, 0.86));
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.head-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px clamp(12px, 3vw, 26px);
  border-bottom: 1px dashed var(--line-cyan);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  text-decoration: none;
  font-family: var(--serif);
  letter-spacing: 0.18em;
}

.brand-mark {
  font-size: 22px;
  line-height: 1;
  color: var(--neon);
  filter: drop-shadow(0 0 10px rgba(105, 255, 105, 0.85));
}

.brand-name {
  font-size: clamp(18px, 3.4vw, 24px);
  font-weight: 600;
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 12px rgba(0, 255, 255, 0.5));
}

.head-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.head-contact {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line-cyan);
  color: var(--cyan);
  text-decoration: none;
  font-size: 16px;
  letter-spacing: 0.08em;
  background: rgba(0, 255, 255, 0.06);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35);
}

.head-contact:hover {
  color: var(--ink);
  background: var(--cyan);
  box-shadow: 0 0 18px rgba(0, 255, 255, 0.6);
}

.burger {
  width: 54px;
  height: 44px;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--neon);
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
}

.burger:hover { background: rgba(105, 255, 105, 0.1); }

.burger-bar {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--neon);
  box-shadow: 0 0 8px var(--neon);
  transition: transform 0.25s ease;
}

.head-menu { padding: 0 4px; }

.nav-ol {
  display: flex;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}

.nav-ol::-webkit-scrollbar { display: none; }

.nav-ol li { flex: 0 0 auto; }

.nav-ol a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 13px;
  color: var(--paper);
  text-decoration: none;
  font-size: 16px;
  letter-spacing: 0.06em;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.nav-ol a:hover,
.nav-ol a:focus-visible {
  color: var(--neon);
  border-bottom-color: var(--neon);
  text-shadow: 0 0 14px rgba(105, 255, 105, 0.9);
}

/* 全屏遮罩菜单 */

html.menu-open { overflow: hidden; }

html.menu-open .site-nav {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 84px 20px 40px;
  overflow-y: auto;
  background:
    radial-gradient(circle at 50% 18%, rgba(0, 255, 255, 0.2), transparent 62%),
    radial-gradient(circle at 80% 88%, rgba(105, 255, 105, 0.18), transparent 58%),
    rgba(6, 13, 10, 0.98);
  border-bottom: 1px solid var(--neon);
}

html.menu-open .nav-ol {
  flex-direction: column;
  gap: 8px;
  width: min(520px, 100%);
  overflow: visible;
}

html.menu-open .nav-ol a {
  min-height: 58px;
  padding: 0 18px;
  font-family: var(--serif);
  font-size: 21px;
  letter-spacing: 0.1em;
  border: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(105, 255, 105, 0.04);
}

html.menu-open .burger {
  position: fixed;
  top: 12px;
  right: clamp(12px, 3vw, 26px);
  z-index: 70;
  background: rgba(6, 13, 10, 0.9);
}

html.menu-open .burger-bar:first-child { transform: translateY(4.5px) rotate(45deg); }
html.menu-open .burger-bar:last-child { transform: translateY(-4.5px) rotate(-45deg); }

/* ---------- 首屏 ---------- */

.hero {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
}

.hero-figure {
  position: absolute;
  inset: 0;
  z-index: 0;
  margin: 0;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.2) contrast(1.06) brightness(0.82);
}

.hero--flat .hero-figure {
  background:
    conic-gradient(from 200deg at 28% 18%, #0b1f18, #17452f, #0a2d35, #12281c, #0b1f18);
}

.hero-figure::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, rgba(0, 255, 255, 0.08) 0 1px, transparent 1px 60px);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(6, 13, 10, 0.86), rgba(6, 13, 10, 0.24) 42%, rgba(6, 13, 10, 0.94)),
    radial-gradient(620px 440px at 12% 88%, rgba(105, 255, 105, 0.24), transparent 72%);
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: clamp(44px, 9vw, 88px);
  z-index: 2;
  background: linear-gradient(90deg, var(--cyan), var(--neon) 62%, #ffffff);
  clip-path: polygon(0 100%, 0 46%, 100% 0, 100% 100%);
  opacity: 0.9;
}

.hero-inner {
  position: relative;
  z-index: 3;
  padding: 0 clamp(16px, 4vw, 56px) clamp(86px, 13vw, 130px);
  max-width: 880px;
}

.hero-caption {
  position: absolute;
  right: 14px;
  top: 16px;
  z-index: 2;
  writing-mode: vertical-rl;
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 0.42em;
  color: var(--cyan);
  text-shadow: 0 0 12px rgba(0, 255, 255, 0.8);
}

.hero-h1 {
  margin: 0 0 18px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(30px, 7.4vw, 62px);
  line-height: 1.12;
  letter-spacing: 0.03em;
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 3px 0 rgba(10, 19, 16, 0.9)) drop-shadow(0 0 24px rgba(0, 255, 255, 0.6));
}

.hero-lede {
  margin: 0 0 24px;
  max-width: 54ch;
  font-size: 17px;
  color: #d8ffe6;
  text-shadow: 0 1px 12px rgba(6, 13, 10, 0.95);
}

.hero-jump {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 24px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  letter-spacing: 0.12em;
  background: linear-gradient(135deg, var(--neon), var(--cyan));
  border: 1px solid #ffffff;
  box-shadow: 0 0 0 1px rgba(10, 19, 16, 0.7), 0 10px 28px rgba(0, 255, 255, 0.35);
}

.hero-jump:hover {
  filter: drop-shadow(0 0 16px rgba(105, 255, 105, 0.9));
}

/* ---------- 正文区 ---------- */

.stage {
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
  gap: clamp(20px, 3.4vw, 44px);
  align-items: start;
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(40px, 6vw, 76px) clamp(16px, 4vw, 32px) 72px;
}

.toc {
  position: sticky;
  top: 122px;
  padding: 16px 14px;
  border: 1px solid var(--line);
  background:
    linear-gradient(160deg, rgba(105, 255, 105, 0.09), rgba(0, 255, 255, 0.05) 55%, transparent),
    rgba(10, 19, 16, 0.72);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.4);
}

.toc-title {
  margin: 0 0 12px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--line-cyan);
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.34em;
}

.toc-title::before {
  content: "\2726";
  margin-right: 8px;
  color: var(--neon);
  filter: drop-shadow(0 0 8px var(--neon));
}

.toc-title span {
  color: var(--cyan);
}

.toc-ol {
  counter-reset: toc;
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
}

.toc-ol li {
  counter-increment: toc;
  border-bottom: 1px solid rgba(105, 255, 105, 0.14);
}

.toc-ol a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 2px 0;
  color: var(--paper);
  text-decoration: none;
  font-size: 16px;
}

.toc-ol a::before {
  content: counter(toc, decimal-leading-zero);
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--neon);
  opacity: 0.85;
}

.toc-ol a:hover { color: var(--neon); text-shadow: 0 0 12px rgba(105, 255, 105, 0.8); }

.toc-top {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 42px;
  text-decoration: none;
  color: var(--ink);
  font-size: 16px;
  letter-spacing: 0.1em;
  background: linear-gradient(135deg, var(--neon), var(--cyan));
  border: 1px solid #ffffff;
}

.prose {
  min-width: 0;
  max-width: 74ch;
  font-size: 17px;
  line-height: 1.85;
}

.prose > article {
  position: relative;
  scroll-margin-top: 132px;
  padding: 6px 0 34px;
  border-top: 1px solid var(--line);
}

.prose > article + article { margin-top: 30px; }

.prose > article:first-child { border-top: 0; padding-top: 0; }

.prose h2,
.prose h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.32;
  letter-spacing: 0.02em;
  color: var(--paper);
}

.prose h2 {
  margin: 26px 0 14px;
  font-size: clamp(21px, 3.3vw, 30px);
}

.prose h3 {
  margin: 22px 0 10px;
  font-size: clamp(18px, 2.4vw, 22px);
}

.prose h2::before,
.prose h3::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 12px;
  vertical-align: middle;
  background: var(--neon);
  transform: rotate(45deg);
  box-shadow: 0 0 12px var(--neon);
}

.prose h2 > span,
.prose h3 > span {
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 14px rgba(0, 255, 255, 0.45));
}

.prose p { margin: 0 0 16px; }

.prose a {
  color: var(--cyan);
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
}

.prose a:hover { color: var(--neon); }

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

.prose ul,
.prose ol {
  margin: 0 0 18px;
  padding-left: 22px;
}

.prose li { margin-bottom: 8px; }

.prose li::marker { color: var(--cyan); }

.prose blockquote {
  margin: 20px 0;
  padding: 14px 18px;
  border-left: 3px solid var(--neon);
  background: rgba(105, 255, 105, 0.07);
  color: #d5f7e2;
}

.prose blockquote p:last-child { margin-bottom: 0; }

.prose figure {
  margin: 22px 0;
  border: 1px solid var(--line-cyan);
  padding: 10px;
  background: rgba(0, 255, 255, 0.05);
}

.prose img {
  display: block;
  width: 100%;
  height: auto;
}

.prose figcaption {
  margin-top: 8px;
  font-size: 15px;
  color: var(--soft);
}

.prose table {
  display: block;
  width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 16px;
}

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

.prose th { background: rgba(0, 255, 255, 0.1); color: var(--cyan); }

.prose hr {
  border: 0;
  border-top: 1px dashed var(--line-cyan);
  margin: 26px 0;
}

.prose code {
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 15px;
  color: var(--neon);
  background: rgba(105, 255, 105, 0.1);
  padding: 1px 5px;
}

/* 滚动揭示 */

.js .prose > article.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.js .prose > article.reveal.in {
  opacity: 1;
  transform: none;
}

/* ---------- 页脚 ---------- */

.foot {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding: clamp(34px, 5vw, 56px) clamp(16px, 4vw, 48px) 22px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(0, 255, 255, 0.09), transparent 46%);
}

.cta {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid var(--neon);
  background:
    linear-gradient(135deg, rgba(105, 255, 105, 0.16), rgba(0, 255, 255, 0.14)),
    rgba(10, 19, 16, 0.7);
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: "\2726";
  position: absolute;
  right: clamp(12px, 4vw, 42px);
  bottom: -14px;
  font-size: 84px;
  line-height: 1;
  color: rgba(0, 255, 255, 0.22);
  pointer-events: none;
}

.cta-h {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(22px, 4vw, 34px);
  font-weight: 600;
  letter-spacing: 0.1em;
}

.cta-h span {
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 18px rgba(105, 255, 105, 0.6));
}

.cta-btn {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 24px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  letter-spacing: 0.12em;
  background: linear-gradient(135deg, var(--cyan), var(--neon));
  border: 1px solid #ffffff;
  box-shadow: 0 8px 24px rgba(0, 255, 255, 0.28);
}

.fc { margin: 0; }

.fc dt {
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--line-cyan);
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0.3em;
  color: var(--cyan);
}

.fc dd { margin: 0; }

.fc dd a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--soft);
  text-decoration: none;
  font-size: 16px;
}

.fc dd a:hover { color: var(--neon); }

.foot-base {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 20px;
  margin-top: 6px;
  padding-top: 16px;
  border-top: 1px dashed rgba(105, 255, 105, 0.26);
  font-size: 15px;
  color: var(--soft);
}

.copy { margin: 0; letter-spacing: 0.08em; }

.base-links {
  display: flex;
  gap: 18px;
  margin: 0;
}

.base-links a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--cyan);
  text-decoration: none;
  letter-spacing: 0.08em;
}

.base-links a:hover { color: var(--neon); }

/* ---------- 自适应 ---------- */

@media (max-width: 900px) {
  .stage {
    grid-template-columns: minmax(0, 1fr);
    gap: 26px;
  }

  .toc { position: static; }

  .toc-ol {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
    margin-bottom: 12px;
  }

  .toc-ol li { border-bottom: 0; flex: 0 0 auto; }

  .toc-ol a { min-height: 40px; }

  .prose { max-width: none; }

  .foot { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .fc:nth-of-type(3) { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }

  .hero-inner { padding-bottom: 96px; }

  .hero-lede { font-size: 16px; }

  .head-contact { padding: 0 11px; font-size: 15px; }

  html.menu-open .nav-ol a { font-size: 19px; min-height: 54px; }

  .prose > article { scroll-margin-top: 122px; }

  .cta { flex-direction: column; align-items: flex-start; }

  .foot { grid-template-columns: minmax(0, 1fr); }
  .fc:nth-of-type(3) { grid-column: auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .js .prose > article.reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .hero-img { transform: none !important; }
}

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