@import url('https://fonts.googleapis.com/css2?family=Space+Mono:wght@400;700&display=swap');

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

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

body {
  margin: 0;
  font-family: 'Space Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, "Courier New", monospace;
  font-size: 16.5px;
  line-height: 1.8;
  color: #dcf2d6;
  background-color: #0b1410;
  background-image:
    radial-gradient(82rem 38rem at 84% -12%, rgba(255, 113, 206, .30), transparent 62%),
    radial-gradient(64rem 30rem at 4% 0%, rgba(1, 205, 254, .20), transparent 60%),
    linear-gradient(180deg, #132019 0%, #0e1a13 44%, #0b1410 100%);
  background-repeat: no-repeat;
  background-attachment: fixed;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(0, 0, 0, .20) 0 1px, rgba(0, 0, 0, 0) 1px 3px);
  opacity: .5;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 79;
  pointer-events: none;
  background: radial-gradient(120% 80% at 50% 40%, transparent 55%, rgba(4, 10, 7, .55) 100%);
}

::selection {
  background: #87ff71;
  color: #0b1410;
}

a { color: #01cdfe; }

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 90;
  padding: 12px 16px;
  background: #87ff71;
  color: #0b1410;
  border-radius: 8px;
  font-size: .9rem;
  text-decoration: none;
  transition: top .2s ease;
}
.skip:focus { top: 12px; }

/* 顶部细条 */
.announce {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 24px;
  font-size: 12.5px;
  letter-spacing: .26em;
  color: #b6f7d2;
  background: linear-gradient(90deg, rgba(255, 113, 206, .34), rgba(1, 205, 254, .20) 46%, rgba(135, 255, 113, .24));
  border-bottom: 1px solid rgba(1, 205, 254, .38);
}

.announce__dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #87ff71;
  box-shadow: 0 0 12px #87ff71;
  animation: pulse 2.6s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .35; transform: scale(.72); }
}

/* 页头 */
.masthead {
  position: sticky;
  top: 0;
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 11px 24px;
  background: rgba(9, 17, 13, .84);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(135, 255, 113, .18);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 4px 2px;
  color: #c9ffbb;
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: .16em;
  text-decoration: none;
}

.brand__name { text-shadow: 0 0 16px rgba(135, 255, 113, .55); }
.brand__logo { width: 30px; height: 30px; display: block; }

.brand__wire {
  flex: 1 1 auto;
  height: 1px;
  background: repeating-linear-gradient(90deg, rgba(1, 205, 254, .55) 0 8px, transparent 8px 16px);
}

/* 主体骨架 */
.shell {
  display: grid;
  grid-template-columns: 216px minmax(0, 1fr);
  gap: 34px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 24px 10px;
}

/* 左栏锚点 */
.rail {
  position: sticky;
  top: 78px;
  align-self: start;
}

.rail__head { margin-bottom: 12px; }

.rail__kicker {
  display: block;
  font-size: 11.5px;
  letter-spacing: .34em;
  color: #01cdfe;
}

.rail__title {
  margin: .1em 0 0;
  font-size: 1.02rem;
  letter-spacing: .14em;
  color: #c9ffbb;
}

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

.rail__nav a {
  display: block;
  padding: 12px 13px;
  font-size: .9rem;
  line-height: 1.4;
  color: #cfe9d2;
  text-decoration: none;
  border-left: 2px solid rgba(135, 255, 113, .30);
  background: rgba(25, 38, 23, .62);
  border-radius: 0 8px 8px 0;
  transition: color .2s ease, background .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.rail__nav a:hover,
.rail__nav a:focus-visible {
  color: #0b1410;
  background: linear-gradient(90deg, #87ff71, #01cdfe);
  border-left-color: #ff71ce;
  box-shadow: 0 0 20px rgba(1, 205, 254, .45);
  outline: none;
}

.rail__nav a.is-on {
  color: #0b1410;
  background: linear-gradient(90deg, #87ff71, #01cdfe);
  border-left-color: #ff71ce;
}

/* 主区 */
main { min-width: 0; }

.hero {
  position: relative;
  display: grid;
  gap: 20px;
  align-content: center;
  padding: 8px 0 34px;
  min-height: 42vh;
}

.hero__copy { text-align: right; }

.hero__title {
  margin: .1em 0 .35em;
  font-size: clamp(1.9rem, 6.2vw, 3.35rem);
  line-height: 1.2;
  letter-spacing: .01em;
  color: #d9ffcd;
  animation: chroma 6s ease-in-out infinite;
}

@keyframes chroma {
  0%, 100% {
    text-shadow: 0 0 22px rgba(135, 255, 113, .45), 2px 0 0 rgba(255, 113, 206, .55), -2px 0 0 rgba(1, 205, 254, .55);
  }
  50% {
    text-shadow: 0 0 34px rgba(1, 205, 254, .55), 4px 0 0 rgba(255, 113, 206, .70), -4px 0 0 rgba(135, 255, 113, .70);
  }
}

.hero__lede {
  max-width: 48ch;
  margin: 0 0 0 auto;
  color: #b9d9c1;
  font-size: .98rem;
}

.hero__media {
  position: relative;
  margin: 0;
  min-height: 148px;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: linear-gradient(180deg, #ff71ce 0%, #b967ff 42%, #01cdfe 76%, #16241a 100%);
  box-shadow: 0 20px 44px rgba(0, 0, 0, .5), 0 0 0 1px rgba(1, 205, 254, .35);
}

.hero__sun {
  position: absolute;
  top: 12%;
  left: 50%;
  width: 78px;
  height: 78px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle at 50% 38%, #fff5b0, #ff71ce 62%, #b967ff);
  box-shadow: 0 0 46px rgba(255, 113, 206, .85);
}

.hero__img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: auto;
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 24px;
  width: 128px;
  height: 8px;
  border-radius: 3px;
  background: linear-gradient(90deg, #ff71ce, #01cdfe, #87ff71);
  transform: skewX(-32deg);
  box-shadow: 0 0 18px rgba(1, 205, 254, .65);
}

/* 正文 */
.content { display: block; }

.content > article {
  position: relative;
  margin: 0 0 22px;
  padding: 26px 22px 20px;
  border: 1px solid rgba(135, 255, 113, .18);
  border-radius: 10px;
  background: rgba(19, 32, 24, .72);
  box-shadow: 0 12px 34px rgba(0, 0, 0, .38);
}

article[id] { scroll-margin-top: 92px; }

.content h2 {
  margin: 0 0 .55em;
  font-size: clamp(1.3rem, 3.1vw, 1.8rem);
  line-height: 1.35;
  color: #c9ffbb;
  text-shadow: 0 0 16px rgba(135, 255, 113, .42);
}

.content h3 {
  margin: 1.5em 0 .45em;
  font-size: 1.1rem;
  line-height: 1.5;
  color: #01cdfe;
}

.content p { margin: 0 0 1em; }
.content p:last-child { margin-bottom: 0; }

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

.content li { margin: .35em 0; }
.content li::marker { color: #87ff71; }

.content strong {
  color: #ecfff1;
  background: linear-gradient(transparent 64%, rgba(1, 205, 254, .30) 0);
}

.content a { color: #01cdfe; text-underline-offset: 3px; }

.content figure {
  margin: 1.2em 0;
  padding: 12px;
  border-radius: 10px;
  border: 1px dashed rgba(1, 205, 254, .40);
  background: rgba(1, 205, 254, .07);
}

.content figcaption {
  margin-top: 8px;
  font-size: .86rem;
  color: #9dc4ab;
}

.content blockquote {
  margin: 1.2em 0;
  padding: 12px 16px;
  border-left: 3px solid #ff71ce;
  border-radius: 0 10px 10px 0;
  background: rgba(255, 113, 206, .10);
  color: #f0dcf0;
}

.content img { max-width: 100%; height: auto; display: block; border-radius: 8px; }

.content table {
  width: 100%;
  border-collapse: collapse;
  font-size: .94rem;
  margin: 0 0 1em;
}

.content th, .content td {
  padding: 8px 10px;
  text-align: left;
  border: 1px solid rgba(135, 255, 113, .24);
}

.content th { background: rgba(135, 255, 113, .12); color: #d9ffcd; }

.content code {
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(135, 255, 113, .14);
  color: #b9ffa6;
  font-size: .92em;
}

/* 滚动浮现 */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

/* 页脚 */
.foot {
  margin-top: 54px;
  border-top: 1px solid rgba(135, 255, 113, .20);
  background: linear-gradient(180deg, rgba(255, 113, 206, .16), rgba(11, 20, 16, .92) 46%, #08100c 100%);
}

.foot__band {
  height: 74px;
  background-image:
    linear-gradient(rgba(1, 205, 254, .48) 1px, transparent 1px),
    linear-gradient(90deg, rgba(1, 205, 254, .48) 1px, transparent 1px);
  background-size: 100% 18px, 44px 100%;
  transform: perspective(110px) rotateX(54deg);
  transform-origin: top center;
  opacity: .5;
  pointer-events: none;
}

.foot__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr auto;
  gap: 26px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 30px 24px 10px;
}

.foot__addr { font-style: normal; }

.foot__brand {
  display: inline-block;
  color: #c9ffbb;
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: .18em;
  padding: 8px 0;
  text-shadow: 0 0 14px rgba(135, 255, 113, .5);
}

.foot__links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.foot__links a {
  display: inline-block;
  min-height: 42px;
  padding: 10px 0;
  color: #bfe6c9;
  font-size: .92rem;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .2s ease, border-color .2s ease;
}

.foot__links a:hover,
.foot__links a:focus-visible {
  color: #87ff71;
  border-bottom-color: #87ff71;
  outline: none;
}

.foot__base {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1180px;
  margin: 6px auto 0;
  padding: 10px 24px 30px;
  border-top: 1px solid rgba(135, 255, 113, .14);
}

.foot__copy {
  margin: 0;
  font-size: .84rem;
  letter-spacing: .1em;
  color: #8fb79a;
}

.foot__meta {
  list-style: none;
  display: flex;
  gap: 18px;
  margin: 0;
  padding: 0;
}

.foot__meta a {
  display: inline-block;
  min-height: 42px;
  padding: 10px 0;
  color: #bfe6c9;
  font-size: .84rem;
  text-decoration: none;
}

.foot__meta a:hover { color: #87ff71; }

/* 平板与手机 */
@media (max-width: 900px) {
  .shell {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    padding: 16px 16px 10px;
  }

  .rail {
    position: static;
    top: auto;
  }

  .rail__head {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 8px;
  }

  .rail__title { font-size: .96rem; }

  .rail__nav {
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .rail__nav::-webkit-scrollbar { display: none; }

  .rail__nav ul {
    flex-direction: row;
    gap: 8px;
  }

  .rail__nav a {
    white-space: nowrap;
    border-left-width: 1px;
    border-radius: 8px;
    padding: 12px 15px;
  }

  .hero {
    min-height: 0;
    padding: 4px 0 30px;
    gap: 16px;
  }

  .hero__copy { text-align: left; }
  .hero__lede { margin-left: 0; }
  .hero::after { bottom: 14px; width: 96px; }

  .content > article { padding: 20px 16px 16px; }

  .foot__grid {
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    padding: 24px 16px 8px;
  }

  .foot__col--end { grid-column: 1 / -1; }

  .foot__base {
    padding: 10px 16px 26px;
    flex-wrap: wrap;
  }
}

@media (max-width: 420px) {
  .announce { padding: 7px 16px; letter-spacing: .18em; }
  .masthead { padding: 10px 16px; }
  .hero__title { font-size: 1.72rem; }
  .foot__grid { grid-template-columns: 1fr; }
  .foot__col--end { grid-column: auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__title, .announce__dot { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

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