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

:root {
  --red: #ff0000;
  --mag: #ff006e;
  --ink: #1a1a2e;
  --bg: #0d0d1a;
  --fg: #eae6f5;
  --dim: #a29bbc;
  --line: rgba(255, 0, 110, 0.28);
  --soft: rgba(255, 255, 255, 0.08);
  --r: 18px;
  --mono: 'Fira Code', 'Share Tech Mono', ui-monospace, Menlo, Consolas, monospace;
  --hud: 'Share Tech Mono', 'Fira Code', ui-monospace, monospace;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  padding: 0;
  background-color: var(--ink);
  background-image:
    radial-gradient(900px 480px at 12% -12%, rgba(255, 0, 110, 0.22), transparent 70%),
    radial-gradient(760px 420px at 92% 2%, rgba(255, 0, 0, 0.18), transparent 72%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 44px);
  background-attachment: fixed;
  color: var(--fg);
  font-family: var(--mono);
  font-size: 17px;
  line-height: 1.78;
  overflow-x: hidden;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: 0.5;
  background: repeating-linear-gradient(180deg, rgba(0, 0, 0, 0.42) 0 1px, transparent 1px 3px);
}

img { max-width: 100%; }

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

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

/* ---------- 顶部 HUD 条 ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 14px;
  background: rgba(11, 10, 22, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 12px 34px -26px var(--mag);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 4px 8px 4px 0;
  text-decoration: none;
  color: #fff;
}

.brand-img {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  object-fit: cover;
}

.brand-glyph {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--mag);
  font-size: 17px;
  text-shadow: 0 0 10px var(--mag);
}

.brand-word {
  font-family: var(--hud);
  font-size: 15px;
  letter-spacing: 0.2em;
  text-shadow: 0 0 12px rgba(255, 0, 110, 0.75);
}

.rail { display: none; }

.rail-list {
  display: flex;
  align-items: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}

.rail-list::-webkit-scrollbar { display: none; }

.rail-list a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 11px;
  border-radius: 9px;
  color: #bdb6d4;
  text-decoration: none;
  font-size: 14px;
  letter-spacing: 0.04em;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
}

.rail-list a:hover,
.rail-list a.active {
  color: #fff;
  background: rgba(255, 0, 110, 0.16);
  border-bottom-color: var(--mag);
  text-shadow: 0 0 10px var(--mag);
}

.burger {
  margin-left: auto;
  min-height: 44px;
  min-width: 62px;
  padding: 8px 14px;
  font-family: var(--hud);
  font-size: 14px;
  letter-spacing: 0.16em;
  color: #fff;
  background: rgba(255, 0, 110, 0.12);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}

.burger:hover {
  background: rgba(255, 0, 110, 0.26);
  box-shadow: 0 0 18px rgba(255, 0, 110, 0.45);
}

/* ---------- 全屏遮罩菜单 ---------- */

.menu-panel {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
  padding: 84px 22px 40px;
  background:
    radial-gradient(700px 420px at 80% 8%, rgba(255, 0, 110, 0.24), transparent 70%),
    rgba(9, 8, 18, 0.98);
  transform: translateY(-102%);
  visibility: hidden;
  transition: transform 0.45s cubic-bezier(0.16, 0.8, 0.3, 1), visibility 0.45s;
}

.menu-panel.open {
  transform: none;
  visibility: visible;
}

.panel-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 4px;
}

.panel-list li {
  opacity: 0;
  transform: translateX(-14px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  transition-delay: calc(var(--i, 0) * 45ms);
}

.menu-panel.open .panel-list li {
  opacity: 1;
  transform: none;
}

.panel-list a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 10px 14px;
  font-family: var(--hud);
  font-size: 19px;
  letter-spacing: 0.1em;
  color: #ded9ee;
  text-decoration: none;
  border-left: 3px solid transparent;
  border-radius: 10px;
}

.panel-list a:hover,
.panel-list a:focus-visible {
  color: #fff;
  background: rgba(255, 0, 110, 0.18);
  border-left-color: var(--mag);
  text-shadow: 0 0 14px var(--mag);
}

.panel-foot {
  margin: 10px 0 0;
  padding-left: 17px;
  font-size: 13px;
  letter-spacing: 0.26em;
  color: var(--dim);
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 70vh;
  padding: 66px 18px 92px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

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

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

.hero-noise {
  display: block;
  width: 100%;
  height: 100%;
  background:
    repeating-linear-gradient(115deg, rgba(255, 0, 110, 0.16) 0 2px, transparent 2px 12px),
    linear-gradient(160deg, #14122b, #25081f 70%, #3a0a1e);
}

.hero-fig::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(10, 8, 20, 0.95) 6%, rgba(10, 8, 20, 0.6) 46%, rgba(255, 0, 110, 0.3) 100%);
}

.hero-cap {
  position: absolute;
  left: 18px;
  bottom: 40px;
  z-index: 2;
  font-size: 12px;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.62);
}

.hero-copy {
  position: relative;
  z-index: 2;
  max-width: 660px;
}

.hero-h1 {
  margin: 0 0 16px;
  font-family: var(--hud);
  font-size: clamp(28px, 6.2vw, 54px);
  line-height: 1.22;
  letter-spacing: 0.02em;
  color: #fff;
  text-shadow: 0 0 18px rgba(255, 0, 110, 0.85), 0 0 42px rgba(255, 0, 0, 0.45);
  animation: glitch 7s steps(1, end) infinite;
}

.hero-desc {
  margin: 0;
  max-width: 54ch;
  font-size: 16px;
  line-height: 1.8;
  color: #cfc9e2;
}

.hero-band {
  position: absolute;
  left: -4%;
  right: -4%;
  bottom: 0;
  height: 22px;
  z-index: 3;
  background: linear-gradient(90deg, var(--red), var(--mag) 55%, transparent);
  transform: skewY(-2.2deg);
  opacity: 0.9;
  box-shadow: 0 0 26px rgba(255, 0, 110, 0.6);
}

@keyframes glitch {
  0%, 91%, 100% { transform: none; }
  92% { transform: translate(-2px, 1px) skewX(-2deg); }
  94% { transform: translate(2px, -1px); }
  96% { transform: translate(-1px, 0) skewX(1.4deg); }
}

/* ---------- 主体网格 ---------- */

.deck {
  display: block;
  max-width: 1200px;
  margin: 0 auto;
}

.stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 26px;
  padding: 32px 14px 8px;
}

.flow { min-width: 0; }

.flow > section {
  position: relative;
  margin: 0 0 22px;
  padding: 22px 16px 24px 20px;
  scroll-margin-top: 132px;
  background: rgba(255, 255, 255, 0.028);
  border: 1px solid var(--soft);
  border-left: 3px solid var(--mag);
  border-radius: var(--r);
  box-shadow: 0 22px 48px -34px rgba(255, 0, 110, 0.85);
}

.flow > section::before {
  content: "";
  position: absolute;
  top: -1px;
  right: -1px;
  width: 54px;
  height: 3px;
  background: var(--red);
  border-radius: 0 var(--r) 0 0;
  opacity: 0.85;
}

.flow small {
  display: block;
  margin-bottom: 2px;
  font-size: 12px;
  letter-spacing: 0.26em;
  color: var(--mag);
  text-shadow: 0 0 10px rgba(255, 0, 110, 0.6);
}

.flow h2,
.flow h3 {
  margin: 0.1em 0 0.65em;
  font-family: var(--hud);
  font-size: clamp(21px, 2.6vw, 28px);
  line-height: 1.34;
  color: #fff;
  text-shadow: 0 0 14px rgba(255, 0, 110, 0.6);
}

.flow h3 { font-size: clamp(18px, 2.2vw, 22px); }

.flow p {
  margin: 0 0 1em;
  line-height: 1.86;
  color: #d7d2e6;
}

.flow ul,
.flow ol {
  margin: 0 0 1em;
  padding-left: 1.3em;
  color: #d7d2e6;
}

.flow li { margin-bottom: 0.5em; }

.flow a {
  color: var(--mag);
  text-underline-offset: 3px;
  text-shadow: 0 0 10px rgba(255, 0, 110, 0.4);
}

.flow figure {
  margin: 1.2em 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.28);
}

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

.flow figcaption {
  padding: 8px 12px;
  font-size: 13px;
  color: var(--dim);
  border-top: 1px solid var(--soft);
}

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

.flow blockquote {
  margin: 1.1em 0;
  padding: 12px 16px;
  border-left: 2px solid var(--red);
  background: rgba(255, 0, 0, 0.07);
  color: #e6e1f2;
  border-radius: 0 12px 12px 0;
}

/* ---------- 右侧栏 ---------- */

.side { order: 2; }

.side-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: linear-gradient(165deg, rgba(255, 0, 110, 0.14), rgba(255, 0, 0, 0.05));
  box-shadow: inset 0 0 0 1px rgba(255, 0, 110, 0.1), 0 24px 44px -34px var(--mag);
}

.side-card small {
  display: block;
  font-size: 12px;
  letter-spacing: 0.28em;
  color: var(--mag);
}

.side-h {
  margin: 4px 0 12px;
  font-family: var(--hud);
  font-size: 18px;
  letter-spacing: 0.08em;
  color: #fff;
  text-shadow: 0 0 12px rgba(255, 0, 110, 0.7);
}

.side-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 3px;
}

.side-list a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 10px;
  font-size: 15px;
  color: #cbc5e0;
  text-decoration: none;
  border-left: 2px solid transparent;
  border-radius: 0 10px 10px 0;
}

.side-list a:hover,
.side-list a.active {
  color: #fff;
  background: rgba(255, 0, 110, 0.18);
  border-left-color: var(--mag);
}

/* ---------- outro ---------- */

.outro {
  padding: 6px 14px 30px;
}

.outro-card {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  min-height: 56px;
  padding: 10px 16px;
  border: 1px dashed var(--line);
  border-radius: var(--r);
  background: rgba(255, 0, 110, 0.06);
}

.totop {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 8px 16px;
  font-size: 15px;
  letter-spacing: 0.1em;
  color: #fff;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.totop:hover {
  background: rgba(255, 0, 110, 0.24);
  box-shadow: 0 0 18px rgba(255, 0, 110, 0.5);
}

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

.base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 18px;
  margin-top: 8px;
  padding: 20px 16px 26px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--dim);
}

.base section { margin: 0; }

.base-brand {
  font-family: var(--hud);
  font-size: 15px;
  letter-spacing: 0.24em;
  color: #fff;
  text-shadow: 0 0 14px rgba(255, 0, 0, 0.75);
}

.foot-list {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.foot-list a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 9px;
  font-size: 13px;
  color: var(--dim);
  text-decoration: none;
  border-radius: 8px;
}

.foot-list a:hover {
  color: #fff;
  background: rgba(255, 0, 110, 0.18);
}

.base-copy p { margin: 0; font-size: 13px; }

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

[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.2, 0.8, 0.3, 1);
  transition-delay: calc(var(--i, 0) * 60ms);
}

[data-reveal].in {
  opacity: 1;
  transform: none;
}

/* ---------- 断点 ---------- */

@media (min-width: 700px) {
  .stage { padding: 38px 18px 8px; }
  .flow > section { padding: 28px 26px 30px 30px; }
  .outro { padding: 6px 18px 34px; }
  .base { padding: 22px 20px 28px; }
}

@media (min-width: 980px) {
  .brand-word { font-size: 16px; }
  .rail { display: block; flex: 1; min-width: 0; margin: 0 6px; }
  .burger { margin-left: 0; }
  .stage {
    grid-template-columns: minmax(0, 1fr) 296px;
    gap: 38px;
    padding: 44px 22px 10px;
  }
  .side { align-self: start; position: sticky; top: 122px; }
  .outro { padding: 6px 22px 40px; }
  .base { padding: 24px 24px 30px; }
}

@media (min-width: 1200px) {
  .stage { padding: 48px 24px 12px; }
}

@media (max-width: 420px) {
  .brand-word { display: none; }
  .hero { padding-top: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
  .panel-list li { opacity: 1; transform: none; }
  .menu-panel { transition: none; }
}

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