/* ============================================================
   宇宙回响：文明序曲 · 官网落地页
   ------------------------------------------------------------
   纯静态 CSS，不引外部字体 / CDN / 统计脚本。
   色系与游戏主菜单一致：深空底 #070B14，青 #39C6C0，金 #C8A44A。
   断点：980 / 720 / 560，360px 宽无横向滚动。
   ============================================================ */

:root {
  --bg: #070B14;
  --bg-2: #0B1220;
  --panel: rgba(13, 22, 38, .74);
  --panel-solid: #0D1626;
  --line: rgba(148, 180, 210, .14);
  --line-strong: rgba(148, 180, 210, .26);
  --text: #E8EEF7;
  --muted: #9AABC2;
  --dim: #6E8098;
  --teal: #39C6C0;
  --teal-lit: #7FE6E0;
  --gold: #C8A44A;
  --gold-lit: #E8C977;
  --radius: 18px;
  --max: 1160px;
  /* 页面左右安全边距：桌面最多 56px，手机最少 24px；所有区块共用 */
  --gutter: clamp(24px, 4vw, 56px);
  --nav-h: 68px;
  --font: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", "Source Han Sans SC",
    system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "Cascadia Mono", Consolas, "SFMono-Regular", "JetBrains Mono", monospace;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  /* vw 单位包含滚动条宽度，装饰层可能多出十几像素；在根元素裁掉，手机上不出现横向滚动 */
  overflow-x: hidden;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1100px 700px at 78% -10%, rgba(57, 198, 192, .10), transparent 62%),
    radial-gradient(900px 620px at 8% 12%, rgba(74, 134, 200, .10), transparent 60%),
    radial-gradient(1000px 800px at 50% 118%, rgba(200, 164, 74, .07), transparent 65%),
    var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: inherit; }

[hidden] { display: none !important; }

::selection { background: rgba(57, 198, 192, .32); color: #fff; }

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

#starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: .85;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 0%, transparent 40%, rgba(4, 7, 13, .55) 100%),
    linear-gradient(180deg, rgba(4, 7, 13, .18), rgba(4, 7, 13, .72));
}

.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--teal);
  color: #041014;
  font-weight: 700;
  text-decoration: none;
  transition: top .2s;
}
.skip-link:focus { top: 12px; }

/* ---------------- 顶栏 ---------------- */
.topbar {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  background: rgba(7, 11, 20, .72);
  border-bottom: 1px solid rgba(148, 180, 210, .10);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.topbar-inner {
  max-width: var(--max);
  margin: 0 auto;
  min-height: var(--nav-h);
  padding: 10px var(--gutter);
  display: flex;
  align-items: center;
  gap: 20px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  flex: none;
}
.brand img {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  box-shadow: 0 0 22px rgba(57, 198, 192, .18);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.18; }
.brand-text b { font-size: 15.5px; letter-spacing: .06em; }
.brand-text small { font-size: 10.5px; color: var(--dim); letter-spacing: .32em; }

.nav-links {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 26px;
}
.nav-links a {
  position: relative;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  letter-spacing: .02em;
  transition: color .18s;
}
.nav-links a:hover { color: var(--text); }
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -7px;
  height: 1px;
  background: linear-gradient(90deg, var(--teal), transparent);
  transition: right .22s;
}
.nav-links a:hover::after { right: 0; }

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 22px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: rgba(255, 255, 255, .035);
  color: var(--text);
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease, color .18s ease;
}
.btn:hover { transform: translateY(-1px); border-color: rgba(57, 198, 192, .45); }
.btn:active { transform: translateY(0); }
.btn.primary {
  background: linear-gradient(135deg, #45D4CD 0%, #2FA9A4 60%, #238B87 100%);
  border-color: transparent;
  color: #04141A;
  box-shadow: 0 12px 34px rgba(57, 198, 192, .22), inset 0 1px 0 rgba(255, 255, 255, .32);
}
.btn.primary:hover {
  box-shadow: 0 16px 44px rgba(57, 198, 192, .30), inset 0 1px 0 rgba(255, 255, 255, .36);
}
.btn.primary-2 {
  background: linear-gradient(135deg, #E8C977, #C8A44A);
  border-color: transparent;
  color: #241A06;
  box-shadow: 0 12px 34px rgba(200, 164, 74, .18);
}
.btn.ghost {
  background: transparent;
  border-color: rgba(148, 180, 210, .24);
  color: var(--text);
}
.btn.small {
  min-height: 36px;
  padding: 0 15px;
  font-size: 12.5px;
  border-radius: 10px;
}
.btn:disabled,
.btn[disabled] {
  cursor: not-allowed;
  opacity: .62;
  color: var(--muted);
  background: rgba(255, 255, 255, .035);
  border-color: var(--line);
  box-shadow: none;
  transform: none;
  filter: grayscale(.35);
}

/* ---------------- 首屏 ---------------- */
main { position: relative; z-index: 1; }

.hero {
  position: relative;
  max-width: var(--max);
  margin: 0 auto;
  padding: calc(var(--nav-h) + clamp(38px, 7vw, 84px)) var(--gutter) clamp(44px, 6vw, 76px);
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
  min-height: 92vh;
}
.hero-glow {
  position: absolute;
  z-index: -1;
  top: 8%;
  right: -6%;
  width: min(700px, 84vw);
  height: min(700px, 84vw);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(57, 198, 192, .15) 0%, rgba(57, 198, 192, .04) 42%, transparent 68%);
  filter: blur(8px);
  pointer-events: none;
}
.hero-copy { max-width: 640px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 20px;
  color: var(--teal-lit);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 4px rgba(57, 198, 192, .12), 0 0 16px rgba(57, 198, 192, .8);
  animation: pulse 3.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .55; transform: scale(.82); }
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.25rem, 6.2vw, 4.5rem);
  line-height: 1.08;
  letter-spacing: .005em;
  font-weight: 800;
  background: linear-gradient(175deg, #F6FAFF 18%, #CDDDEB 62%, #93A9BF 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-wrap: balance;
}
.lead {
  margin: 0 0 16px;
  max-width: 38em;
  color: var(--text);
  font-size: clamp(1.02rem, 1.7vw, 1.24rem);
  line-height: 1.75;
  font-weight: 500;
}
.intro { max-width: 40em; color: var(--muted); font-size: 14.5px; line-height: 1.95; }
.intro p { margin: 0 0 9px; }
.intro p:last-child { margin-bottom: 0; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}
.download-hint {
  margin: 14px 0 0;
  color: var(--dim);
  font-size: 12.5px;
  letter-spacing: .02em;
}

/* ---------------- 首屏星系 ---------------- */
.hero-art {
  position: relative;
  width: min(100%, 520px);
  aspect-ratio: 1;
  justify-self: center;
  filter: drop-shadow(0 30px 70px rgba(0, 0, 0, .45));
}
.galaxy-canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
}
.galaxy-glow {
  position: absolute;
  inset: 4%;
  z-index: 0;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%,
    rgba(232, 201, 119, .13) 0%,
    rgba(57, 198, 192, .07) 38%,
    rgba(74, 134, 200, .04) 56%,
    transparent 72%);
  filter: blur(10px);
  pointer-events: none;
}
.spark {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold-lit);
  box-shadow: 0 0 14px 3px rgba(232, 201, 119, .65);
  animation: float 9s ease-in-out infinite;
}
.spark-a { top: 13%; right: 20%; }
.spark-b { bottom: 18%; left: 6%; animation-delay: -3s; }
.spark-c { top: 42%; right: -2%; width: 3px; height: 3px; animation-delay: -6s; }
@keyframes float {
  0%, 100% { transform: translate3d(0, 0, 0); opacity: .55; }
  50% { transform: translate3d(0, -12px, 0); opacity: 1; }
}

/* ---------------- 数据条 ---------------- */
.stats {
  position: relative;
  z-index: 1;
  max-width: var(--max);
  width: min(calc(var(--max) - var(--gutter) * 2), calc(100% - var(--gutter) * 2));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(15, 24, 40, .72), rgba(10, 17, 30, .82));
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .28);
}
.stats > div {
  padding: 22px 20px;
  border-left: 1px solid var(--line);
  min-width: 0;
}
.stats > div:first-child { border-left: 0; }
.stats b {
  display: block;
  margin-bottom: 3px;
  color: var(--gold-lit);
  font-size: clamp(1rem, 1.9vw, 1.28rem);
  font-weight: 700;
  letter-spacing: .02em;
}
.stats span { color: var(--muted); font-size: 12.5px; line-height: 1.6; }

/* ---------------- 通用区块 ---------------- */
.section {
  position: relative;
  z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(64px, 9vw, 112px) var(--gutter) 0;
}
.kicker {
  margin: 0 0 12px;
  color: var(--teal);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .28em;
  text-transform: uppercase;
}
.section-head { max-width: 760px; margin-bottom: 36px; }
.section h2 {
  margin: 0 0 14px;
  font-size: clamp(1.7rem, 3.8vw, 2.55rem);
  line-height: 1.22;
  letter-spacing: .01em;
  font-weight: 750;
  text-wrap: balance;
}
.section-head p,
.split-lead {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.9;
  max-width: 62ch;
}

/* ---------------- 玩法卡片 ---------------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.card {
  position: relative;
  padding: 26px 24px 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .028), transparent 55%),
    linear-gradient(180deg, rgba(15, 24, 40, .82), rgba(9, 15, 27, .9));
  overflow: hidden;
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(57, 198, 192, .55), transparent);
  opacity: 0;
  transition: opacity .22s;
}
.card:hover {
  transform: translateY(-3px);
  border-color: rgba(57, 198, 192, .32);
  box-shadow: 0 22px 50px rgba(0, 0, 0, .32);
}
.card:hover::before { opacity: 1; }
.card-index {
  display: block;
  margin-bottom: 14px;
  color: var(--gold);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .18em;
}
.card h3 {
  margin: 0 0 9px;
  font-size: 1.14rem;
  font-weight: 700;
  letter-spacing: .01em;
}
.card p {
  margin: 0;
  color: var(--muted);
  font-size: 13.8px;
  line-height: 1.85;
}

/* ---------------- 世界如何运转 ---------------- */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
.split-copy h2 { margin-bottom: 16px; }
.steps {
  list-style: none;
  counter-reset: step;
  margin: 28px 0 0;
  padding: 0;
  display: grid;
  gap: 16px;
}
.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 44px;
  min-height: 34px;
}
.steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(57, 198, 192, .32);
  border-radius: 9px;
  background: rgba(57, 198, 192, .08);
  color: var(--teal-lit);
  font-family: var(--mono);
  font-size: 11px;
}
.steps b { display: block; font-size: 14.5px; margin-bottom: 2px; }
.steps span { color: var(--muted); font-size: 13.2px; line-height: 1.8; }

.terminal {
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(9, 16, 29, .96), rgba(6, 11, 21, .98));
  box-shadow: 0 30px 70px rgba(0, 0, 0, .42), 0 0 0 1px rgba(57, 198, 192, .04) inset;
  overflow: hidden;
}
.terminal-head {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .02);
}
.terminal-head i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(148, 180, 210, .28);
}
.terminal-head i:first-child { background: rgba(200, 164, 74, .55); }
.terminal-head i:nth-child(2) { background: rgba(57, 198, 192, .45); }
.terminal-head span {
  margin-left: 8px;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .22em;
}
.terminal-body { padding: 20px 18px; display: grid; gap: 13px; }
.terminal-body p {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
  margin: 0;
  font-family: var(--mono);
  font-size: 12.2px;
  line-height: 1.7;
}
.terminal-body em {
  color: var(--teal);
  font-style: normal;
  letter-spacing: .1em;
}
.terminal-body span { color: var(--muted); }
.terminal-body .ok em { color: var(--gold-lit); }
.terminal-body .ok span { color: rgba(232, 201, 119, .82); }

/* ---------------- 关于作者 ---------------- */
.about-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.about-card {
  padding: 28px 26px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .026), transparent 50%),
    linear-gradient(180deg, rgba(14, 23, 39, .84), rgba(9, 15, 26, .92));
}
.about-card h2 { font-size: clamp(1.45rem, 2.8vw, 1.9rem); margin-bottom: 12px; }
.about-card p { margin: 0 0 12px; color: var(--muted); font-size: 14px; line-height: 1.9; }
.about-card p[data-site="thanks"] { white-space: pre-line; }
.about-card p b { color: var(--text); }
.about-card p:last-child { margin-bottom: 0; }
.about-card .dim { color: var(--dim); }
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  color: var(--teal-lit);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(57, 198, 192, .32);
  padding-bottom: 2px;
  transition: color .18s, border-color .18s;
}
.text-link:hover { color: #fff; border-color: var(--teal); }
.about-card strong { color: var(--gold-lit); font-weight: 700; }

/* ---------------- 下载 ---------------- */
.download-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: clamp(26px, 4vw, 38px);
  border: 1px solid rgba(57, 198, 192, .22);
  border-radius: var(--radius);
  background:
    radial-gradient(700px 200px at 12% 0%, rgba(57, 198, 192, .13), transparent 70%),
    linear-gradient(180deg, rgba(15, 25, 41, .9), rgba(9, 15, 26, .95));
  box-shadow: 0 30px 70px rgba(0, 0, 0, .32);
}
.download-copy h2 { margin-bottom: 10px; }
.download-meta {
  margin: 0 0 6px;
  color: var(--gold-lit);
  font-size: 14.5px;
  font-weight: 600;
}
.download-copy .dim { margin: 0; color: var(--dim); font-size: 13px; line-height: 1.8; }
.download-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  flex: none;
}

/* ---------------- 社区 ---------------- */
.community {
  text-align: center;
  max-width: 820px;
  padding-bottom: 0;
}
.community h2 { margin-bottom: 14px; }
.community-lead {
  margin: 0 auto;
  max-width: 46em;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.95;
}
.community-lead b { color: var(--gold-lit); letter-spacing: .04em; }
.community-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
}

/* ---------------- 页脚 ---------------- */
.footer {
  position: relative;
  z-index: 1;
  margin-top: clamp(64px, 8vw, 100px);
  border-top: 1px solid var(--line);
  background: rgba(5, 9, 16, .6);
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 34px var(--gutter) 44px;
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
}
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  color: var(--text);
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: .04em;
}
.footer-brand img { width: 34px; height: 34px; border-radius: 9px; }
.footer-inner p { margin: 0 0 5px; }
.footer-inner .dim { color: var(--dim); font-size: 11.8px; }

.noscript {
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 12px 24px;
  background: rgba(200, 164, 74, .12);
  border-top: 1px solid rgba(200, 164, 74, .28);
  color: #E8C977;
  font-size: 12.5px;
  text-align: center;
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-top: calc(var(--nav-h) + 54px);
  }
  .hero-copy { max-width: 100%; }
  .hero-art { width: min(76vw, 380px); margin-top: 8px; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .topbar-inner { padding: 10px var(--gutter); gap: 12px; }
  .nav-links { display: none; }
  .brand img { width: 36px; height: 36px; }
  /* 大光晕在窄屏上只会制造溢出，保留星球本身的辉光就够了 */
  .hero-glow { display: none; }
  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stats > div { padding: 18px 16px; border-left: 0; border-top: 1px solid var(--line); }
  .stats > div:nth-child(-n + 2) { border-top: 0; }
  .stats > div:nth-child(even) { border-left: 1px solid var(--line); }
  .download-card { flex-direction: column; align-items: flex-start; }
  .download-actions { width: 100%; }
  .download-actions .btn { flex: 1 1 auto; }
  .hero-actions .btn { flex: 1 1 auto; }
  .terminal-body p { grid-template-columns: 64px minmax(0, 1fr); font-size: 11.6px; }
}

@media (max-width: 560px) {
  body { font-size: 15px; }
  .hero { padding-top: calc(var(--nav-h) + 38px); gap: 26px; }
  .hero-art { width: min(72vw, 280px); }
  .hero h1 { font-size: clamp(2rem, 10.4vw, 2.7rem); }
  .lead { font-size: 1rem; }
  .intro { font-size: 13.8px; line-height: 1.9; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { width: 100%; }
  .cards { grid-template-columns: 1fr; }
  .card { padding: 22px 20px; }
  .about-card { padding: 24px 20px; }
  .community-actions { flex-direction: column; }
  .community-actions .btn { width: 100%; }
  .footer-inner { padding: 30px var(--gutter) 40px; }
  .stats b { font-size: 1rem; }
  .stats span { font-size: 11.8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .dot, .spark { animation: none; }
  .btn, .card, .nav-links a::after { transition: none; }
  * { scroll-behavior: auto !important; }
}
