@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500&family=Playfair+Display:ital,wght@0,400;0,700;0,900;1,400&family=Source+Serif+4:ital,wght@0,300;0,400;0,600;1,300&display=swap');

:root {
  --neon: #69ff69;
  --cyan: #00ffff;
  --ink: #172617;
  --ink-0: #08120a;
  --ink-1: #0c1910;
  --ink-2: #12241a;
  --line: #2b4a32;
  --txt: #e4f5df;
  --dim: #a7c4a4;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --serif: "Source Serif 4", Georgia, "Songti SC", serif;
  --disp: "Playfair Display", Georgia, "Songti SC", serif;
  --chrome: linear-gradient(115deg, #e9f4ec 0%, #ffffff 14%, #a2bba8 30%, #f4fdf5 46%, #7f9d88 62%, #e0efe5 78%, #ffffff 100%);
}

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

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

body {
  margin: 0;
  background-color: var(--ink-0);
  background-image:
    radial-gradient(900px 620px at 10% -12%, rgba(105, 255, 105, .17), transparent 62%),
    radial-gradient(820px 540px at 94% 6%, rgba(0, 255, 255, .14), transparent 64%),
    linear-gradient(180deg, #08120a, #0d1b11 42%, #08120a);
  color: var(--txt);
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.75;
  overflow-x: hidden;
}

::selection { background: var(--cyan); color: #06110a; }

a:focus-visible,
a:focus { outline: 2px solid var(--cyan); outline-offset: 3px; }

img { max-width: 100%; }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 99;
  background: var(--neon);
  color: #06110a;
  padding: 12px 18px;
  font-family: var(--mono);
  font-size: 14px;
  text-decoration: none;
}

.skip:focus { left: 8px; top: 8px; }

/* ---------- 顶部细条 ---------- */

.topline {
  overflow: hidden;
  background: linear-gradient(90deg, var(--neon), var(--cyan) 70%, #b9ffd2);
  color: #06110a;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .24em;
  padding: 5px 0;
}

.track {
  display: flex;
  width: max-content;
  animation: marquee 34s linear infinite;
}

.track span { white-space: nowrap; }

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

/* ---------- 导航 ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 14px;
  background: rgba(8, 18, 10, .88);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav ol {
  display: flex;
  flex: 1 1 0;
  min-width: 0;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2px;
}

.nav ol:first-child { justify-content: flex-end; }
.nav ol:last-child { justify-content: flex-start; }

.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 9px;
  color: var(--dim);
  font-size: 16px;
  line-height: 1.2;
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

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

.brand {
  font-family: var(--disp);
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: .04em;
  line-height: 44px;
  padding: 0 16px;
  white-space: nowrap;
  text-decoration: none;
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 12px rgba(0, 255, 255, .4));
}

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

.hero {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 30px;
  align-content: start;
  justify-items: center;
  min-height: 100svh;
  max-width: 1180px;
  margin: 0 auto;
  padding: 46px 20px 30px;
}

.hero-text {
  display: grid;
  gap: 16px;
  justify-items: center;
  max-width: 860px;
  text-align: center;
}

.eyebrow {
  margin: 0;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .34em;
  color: var(--cyan);
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  font-family: var(--disp);
  font-weight: 900;
  font-size: clamp(2rem, 6.6vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -.01em;
  background: linear-gradient(158deg, #ffffff, #e2ffe4 38%, var(--neon) 68%, var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 20px rgba(105, 255, 105, .32));
}

.hero-desc {
  max-width: 56ch;
  margin: 0;
  font-size: 1.02rem;
  color: var(--dim);
}

.badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 4px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  font-family: var(--mono);
  font-size: 14px;
  letter-spacing: .08em;
  color: #06110a;
  text-decoration: none;
  background: linear-gradient(135deg, #ffffff, var(--cyan) 48%, var(--neon));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .5) inset, 0 0 26px rgba(0, 255, 255, .38);
  animation: float 7s ease-in-out infinite;
}

.badge:nth-child(2) { animation-delay: -2.3s; }
.badge:nth-child(3) { animation-delay: -4.6s; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

.hero-fig {
  position: relative;
  width: 100%;
  max-width: 960px;
  min-height: 190px;
  margin: 0;
  overflow: hidden;
  background: var(--chrome);
  background-size: 220% 220%;
  animation: sheen 14s ease-in-out infinite;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .45) inset, 0 24px 70px -28px rgba(0, 255, 255, .6);
}

.hero-fig::before,
.hero-fig::after {
  content: "✦";
  position: absolute;
  font-family: var(--mono);
  color: #06110a;
  opacity: .55;
  font-size: 22px;
}

.hero-fig::before { top: 12px; left: 14px; }
.hero-fig::after { bottom: 10px; right: 16px; }

.hero-img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 190px;
  object-fit: cover;
  filter: saturate(1.06) contrast(1.05);
}

@keyframes sheen {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* ---------- 正文与右栏 ---------- */

.rail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 292px;
  gap: 56px;
  align-items: start;
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 20px 72px;
}

.prose { min-width: 0; }

.prose section {
  padding-block: 36px;
  border-top: 1px solid var(--line);
  scroll-margin-top: 96px;
}

.prose section:first-child {
  border-top: 0;
  padding-top: 14px;
}

.prose small {
  display: block;
  margin-bottom: 8px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .3em;
  color: var(--cyan);
}

.prose h2 {
  margin: 0 0 16px;
  font-family: var(--disp);
  font-weight: 900;
  font-size: clamp(1.6rem, 3.6vw, 2.4rem);
  line-height: 1.16;
  color: #f4fff2;
}

.prose h3 {
  margin: 28px 0 10px;
  font-family: var(--disp);
  font-weight: 700;
  font-size: 1.28rem;
  line-height: 1.3;
  color: var(--neon);
}

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

.prose a {
  color: var(--neon);
  text-decoration: underline;
  text-decoration-color: rgba(105, 255, 105, .45);
  text-underline-offset: 3px;
}

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

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

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

.prose blockquote {
  margin: 24px 0;
  padding: 14px 20px;
  border-left: 3px solid var(--cyan);
  background: rgba(0, 255, 255, .07);
  color: #d9f3d5;
  font-style: italic;
}

.prose img {
  display: block;
  height: auto;
  margin: 18px 0;
  max-width: 100%;
}

.prose table {
  width: 100%;
  margin: 0 0 18px;
  border-collapse: collapse;
  font-size: 16px;
}

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

.prose th { background: rgba(105, 255, 105, .1); }

.prose code {
  font-family: var(--mono);
  font-size: .9em;
  background: rgba(0, 255, 255, .12);
  padding: 1px 5px;
}

.side {
  position: sticky;
  top: 84px;
}

.side-in {
  padding: 20px 18px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(0, 255, 255, .08), rgba(105, 255, 105, .05));
}

.side small {
  display: block;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .3em;
  color: var(--cyan);
}

.side h2 {
  margin: 4px 0 14px;
  font-family: var(--disp);
  font-weight: 700;
  font-size: 1.15rem;
  color: #f4fff2;
}

.side ol {
  counter-reset: s;
  list-style: none;
  margin: 0;
  padding: 0;
}

.side li { counter-increment: s; }

.side a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 4px 0;
  font-size: 16px;
  color: var(--dim);
  text-decoration: none;
  border-bottom: 1px dashed rgba(255, 255, 255, .1);
}

.side a::before {
  content: counter(s, decimal-leading-zero);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--neon);
  opacity: .8;
}

.side a:hover,
.side a.on {
  color: var(--neon);
  border-bottom-color: rgba(105, 255, 105, .5);
}

.sticker {
  margin-top: 18px;
  padding: 10px;
  text-align: center;
  font-size: 20px;
  color: #06110a;
  background: linear-gradient(135deg, var(--neon), var(--cyan));
}

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

.foot {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 20px 44px;
  border-top: 1px solid var(--line);
}

.cta {
  display: grid;
  gap: 12px;
  justify-items: center;
  padding: 48px 24px;
  text-align: center;
  color: #06110a;
  background: linear-gradient(122deg, var(--neon), var(--cyan) 58%, #d6ffdf);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .45) inset, 0 30px 80px -40px rgba(0, 255, 255, .8);
}

.cta small {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .34em;
  text-transform: uppercase;
}

.cta-h {
  margin: 0;
  font-family: var(--disp);
  font-weight: 900;
  font-size: clamp(1.6rem, 5vw, 2.6rem);
  line-height: 1.1;
  color: #06110a;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0 26px;
  font-family: var(--mono);
  font-size: 15px;
  letter-spacing: .1em;
  color: var(--neon);
  text-decoration: none;
  background: var(--ink);
  box-shadow: 0 0 0 1px #06110a, 0 0 24px rgba(23, 38, 23, .55);
}

.cta-btn:hover { background: #06110a; }

.cols {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 28px;
  padding: 42px 0 26px;
}

.brand-sm { font-size: 1.1rem; line-height: 1.4; padding: 0; }

.spark {
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 14px;
  letter-spacing: .5em;
  color: var(--neon);
}

.cols dl { margin: 0; }

.cols dt {
  margin-bottom: 6px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .24em;
  color: var(--cyan);
}

.cols dd { margin: 0; }

.cols dd a {
  display: flex;
  align-items: center;
  min-height: 42px;
  font-size: 16px;
  color: var(--dim);
  text-decoration: none;
  border-bottom: 1px dashed rgba(255, 255, 255, .08);
}

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

.copy {
  margin: 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--dim);
}

/* ---------- 滚动显现 ---------- */

.rv {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1);
}

.rv-in {
  opacity: 1;
  transform: none;
}

/* ---------- 窄屏 ---------- */

@media (max-width: 900px) {
  .rail {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
    padding-bottom: 56px;
  }

  .side { position: static; }

  .cols { grid-template-columns: 1fr 1fr; gap: 22px; }

  .col-brand { grid-column: 1 / -1; }
}

@media (max-width: 820px) {
  .nav {
    flex-wrap: wrap;
    gap: 2px;
    padding: 6px 10px;
  }

  .nav .brand {
    order: -1;
    flex: 0 0 100%;
    text-align: center;
    font-size: 1.05rem;
    line-height: 42px;
    padding: 0;
  }

  .nav ol {
    flex: 1 1 100%;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0 2px;
  }

  .nav a { padding: 0 8px; }

  .prose section { scroll-margin-top: 176px; }

  .hero {
    min-height: auto;
    padding: 34px 16px 26px;
    gap: 24px;
  }

  .hero-fig { min-height: 170px; }
  .hero-img { min-height: 170px; }

  .prose section { padding-block: 30px; }

  .cta { padding: 38px 18px; }
}

@media (max-width: 420px) {
  body { font-size: 16.5px; }
  .badge { font-size: 13px; padding: 0 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .track, .badge, .hero-fig { animation: none; }
  .rv { opacity: 1; transform: none; transition: none; }
}

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