@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&family=Fira+Sans:wght@300;400;500;600;700&display=swap');

:root {
  --red: #ff0000;
  --violet: #8b00ff;
  --ink: #261717;
  --paper: #f7efec;
  --muted: #cbb6b1;
  --glass: rgba(255, 255, 255, 0.06);
  --glass-2: rgba(255, 255, 255, 0.1);
  --line: rgba(255, 255, 255, 0.17);
  --rail: 76px;
  --mono: "Fira Code", ui-monospace, SFMono-Regular, Menlo, monospace;
  --sans: "Fira Sans", system-ui, -apple-system, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: #1c1111;
  color: var(--paper);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.78;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 80% at 18% 0%, #3b1e1e 0%, rgba(28, 17, 17, 0) 62%),
    linear-gradient(180deg, #1e1212 0%, #170e0f 55%, #110b0c 100%);
}

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

a { color: #ff9d9d; text-underline-offset: 3px; }

.aurora {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
  animation: drift 22s ease-in-out infinite;
}

.b1 { width: 46vw; height: 46vw; left: -10vw; top: -12vw; background: radial-gradient(circle, rgba(255, 0, 0, 0.72), transparent 70%); }
.b2 { width: 56vw; height: 56vw; right: -16vw; top: 16vh; background: radial-gradient(circle, rgba(139, 0, 255, 0.66), transparent 70%); animation-delay: -7s; }
.b3 { width: 42vw; height: 42vw; left: 22vw; bottom: -16vw; background: radial-gradient(circle, rgba(255, 0, 0, 0.38), transparent 70%); animation-delay: -14s; }

@keyframes drift {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(3vw, 4vh, 0) scale(1.12); }
  100% { transform: translate3d(0, 0, 0) scale(1); }
}

/* 左侧固定竖排栏 */
.rail {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--rail);
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 16px 0;
  background: rgba(32, 19, 19, 0.55);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-right: 1px solid var(--line);
}

.mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--glass-2);
  text-decoration: none;
  color: var(--paper);
}

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

.mark-txt {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 18px;
  color: #fff;
}

.menu-wrap { margin-top: 4px; }

.menu-wrap summary {
  list-style: none;
  width: 44px;
  min-height: 44px;
  display: grid;
  place-items: center;
  padding: 8px 0;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--glass);
  color: var(--paper);
  cursor: pointer;
  font-size: 16px;
  letter-spacing: 0.18em;
  writing-mode: vertical-rl;
  transition: background 0.25s ease, border-color 0.25s ease;
}

.menu-wrap summary::-webkit-details-marker { display: none; }
.menu-wrap summary:hover { background: var(--glass-2); border-color: rgba(255, 0, 0, 0.5); }

.menu-wrap menu {
  list-style: none;
  margin: 0;
  padding: 22px 12px;
  position: fixed;
  left: var(--rail);
  top: 0;
  bottom: 0;
  z-index: 39;
  display: none;
  flex-direction: column;
  gap: 6px;
  overflow-y: auto;
  background: rgba(24, 14, 14, 0.88);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  border-right: 1px solid var(--line);
}

.menu-wrap[open] menu { display: flex; }

.menu-wrap menu a {
  display: block;
  min-height: 44px;
  min-width: 40px;
  padding: 14px 8px;
  writing-mode: vertical-rl;
  letter-spacing: 0.12em;
  font-size: 16px;
  line-height: 1.4;
  color: var(--muted);
  text-decoration: none;
  border-radius: 12px;
  border: 1px solid transparent;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.menu-wrap menu a:hover,
.menu-wrap menu a:focus-visible {
  color: #fff;
  background: var(--glass);
  border-color: var(--line);
}

/* 主体 */
main {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 30px 0 calc(var(--rail) + 30px);
  display: grid;
  grid-template-columns: 226px minmax(0, 1fr);
  column-gap: 42px;
  align-items: start;
}

.stage { display: contents; }

.side {
  grid-column: 1;
  grid-row: 1 / span 60;
  position: sticky;
  top: 26px;
  padding: 20px 18px 22px;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: var(--glass);
  -webkit-backdrop-filter: blur(15px);
  backdrop-filter: blur(15px);
  box-shadow: 0 20px 40px -28px rgba(0, 0, 0, 0.9);
}

.side-title {
  margin: 0 0 12px;
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.22em;
  color: #fff;
}

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

.side-list a {
  display: block;
  min-height: 40px;
  padding: 9px 2px;
  font-size: 16px;
  line-height: 1.42;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.side-list li:last-child a { border-bottom: 0; }
.side-list a:hover { color: #fff; padding-left: 6px; }

/* 首屏 */
.hero {
  grid-column: 2;
  position: relative;
  overflow: hidden;
  min-height: 45vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 26px;
  padding: 46px 22px 46px;
  border-radius: 32px;
  border: 1px solid var(--line);
  background:
    linear-gradient(160deg, rgba(255, 0, 0, 0.13), rgba(139, 0, 255, 0.14) 58%, rgba(255, 255, 255, 0.04));
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 30px 60px -40px rgba(0, 0, 0, 0.9);
}

.ghost {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-weight: 700;
  font-size: clamp(3.2rem, 12.5vw, 9.5rem);
  line-height: 1;
  letter-spacing: 0.05em;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.14);
  pointer-events: none;
}

.orb { margin: 0; position: relative; z-index: 1; }

.hero-title {
  position: relative;
  z-index: 1;
  margin: 0;
  text-align: center;
  font-size: clamp(1.85rem, 4.4vw, 3rem);
  line-height: 1.28;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #fff;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.55);
}

/* 正文区块 */
main > article:not(.stage) {
  grid-column: 2;
  margin: 22px 0;
  padding: 30px 30px 26px;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: var(--glass);
  -webkit-backdrop-filter: blur(15px);
  backdrop-filter: blur(15px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 24px 50px -36px rgba(0, 0, 0, 0.9);
  scroll-margin-top: 26px;
}

main > article:not(.stage) > *:first-child { margin-top: 0; }
main > article:not(.stage) > *:last-child { margin-bottom: 0; }

main h2 {
  margin: 0 0 0.55em;
  font-size: clamp(1.3rem, 2.3vw, 1.62rem);
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #fff;
}

main h2::after {
  content: "";
  display: block;
  width: 54px;
  height: 2px;
  margin-top: 12px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--red), var(--violet));
}

main h3 {
  margin: 1.4em 0 0.5em;
  font-size: 1.06rem;
  font-weight: 600;
  color: #ffe9e6;
}

main p { margin: 0 0 1.05em; }

p.subtitle {
  margin: -0.2em 0 1.1em;
  font-family: var(--mono);
  font-size: 0.94rem;
  line-height: 1.6;
  letter-spacing: 0.06em;
  color: var(--muted);
}

main ul, main ol { padding-left: 1.25em; margin: 0 0 1.1em; }
main li { margin-bottom: 0.45em; }

main blockquote {
  margin: 1.2em 0;
  padding: 14px 18px;
  border-left: 2px solid var(--violet);
  border-radius: 0 18px 18px 0;
  background: rgba(139, 0, 255, 0.12);
}

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

main figure { margin: 1.1em 0; }
main figure img { border-radius: 20px; border: 1px solid var(--line); }

main strong { color: #fff; font-weight: 600; }

time {
  font-family: var(--mono);
  font-size: 0.88em;
  color: var(--muted);
}

/* 滚动显现 */
body.js main > article:not(.stage) {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

body.js main > article:not(.stage).in { opacity: 1; transform: none; }

/* 页脚 */
.foot {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 42px auto 0;
  padding: 0 30px 40px calc(var(--rail) + 30px);
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 18px;
}

.foot article {
  border-radius: 28px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.045);
  -webkit-backdrop-filter: blur(15px);
  backdrop-filter: blur(15px);
  padding: 24px;
}

.cta {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 24px 34px !important;
  background: linear-gradient(150deg, rgba(255, 0, 0, 0.16), rgba(139, 0, 255, 0.18)) !important;
}

.cta-title {
  margin: 0 0 8px;
  font-family: var(--mono);
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #fff;
}

.cta .subtitle { margin: 0 0 20px; }

.cta-btn {
  display: inline-block;
  min-height: 46px;
  padding: 12px 26px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 16px;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.cta-btn:hover { transform: translateY(-2px); background: rgba(255, 255, 255, 0.24); }

.fcol-brand { display: flex; flex-direction: column; gap: 12px; }

.fmark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--glass-2);
  font-family: var(--mono);
  font-weight: 700;
  color: #fff;
}

.fbrand { margin: 0; font-size: 17px; color: #fff; letter-spacing: 0.04em; }

.fcol-title {
  margin: 0 0 12px;
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: #fff;
}

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

.fcol a {
  display: block;
  min-height: 40px;
  padding: 8px 0;
  font-size: 16px;
  line-height: 1.42;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.fcol li:last-child a { border-bottom: 0; }
.fcol a:hover { color: #fff; }

.base {
  grid-column: 1 / -1;
  text-align: center;
  padding: 18px 20px !important;
}

.base p {
  margin: 0;
  font-family: var(--mono);
  font-size: 15px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

@media (max-width: 900px) {
  .foot { grid-template-columns: 1fr 1fr; }
  .fcol-brand { grid-column: 1 / -1; flex-direction: row; align-items: center; }
}

@media (max-width: 780px) {
  :root { --rail: 0px; }

  .rail {
    left: 0;
    right: 0;
    bottom: auto;
    width: 100%;
    height: 62px;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 0 14px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .menu-wrap { margin: 0 0 0 auto; }

  .menu-wrap summary {
    writing-mode: horizontal-tb;
    width: auto;
    padding: 0 16px;
    height: 42px;
    letter-spacing: 0.08em;
  }

  .menu-wrap menu {
    position: fixed;
    left: 0;
    right: 0;
    top: 62px;
    bottom: auto;
    max-height: 70vh;
    padding: 10px 16px 16px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .menu-wrap menu a {
    writing-mode: horizontal-tb;
    padding: 12px 4px;
    letter-spacing: 0.03em;
    border-radius: 0;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  }

  main {
    display: block;
    padding: 62px 16px 0;
  }

  .hero { margin-top: 18px; padding: 40px 16px; min-height: 42vh; }

  .side { position: static; margin: 18px 0 0; padding: 18px; }

  main > article:not(.stage) { padding: 22px 18px 20px; border-radius: 24px; }

  .foot {
    display: grid;
    grid-template-columns: 1fr;
    padding: 0 16px 34px;
    margin-top: 30px;
  }

  .fcol-brand { grid-column: auto; }
  .cta, .base { grid-column: auto; }
  .foot article { border-radius: 24px; padding: 20px; }
}

@media (max-width: 420px) {
  .side-list a { padding: 11px 2px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .blob { animation: none; }
  body.js main > article:not(.stage) { opacity: 1; transform: none; transition: none; }
  .cta-btn:hover, .side-list a:hover { transform: none; }
}

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