/* 星火 Spark 官网 —— 工程师的浪漫:暗色 / 余烬 / 物理学定义的"火" */
:root {
  --flame: #FF6B35;
  --flame-2: #FF8A3D;
  --ember: #FFB627;
  --hot: #FFD9A0;
  --bg: #07080C;
  --bg-2: #0C0E15;
  --panel: rgba(20, 22, 31, 0.66);
  --line: rgba(255, 255, 255, 0.08);
  --ink: #F4F5F7;
  --ink-2: #A4ABBA;
  --ink-3: #6B7280;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --glow: 0 0 24px rgba(255, 107, 53, 0.45);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
  background: var(--bg); color: var(--ink); line-height: 1.65;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.mono { font-family: var(--mono); }
.flame-text { color: var(--flame); }
.glow { text-shadow: var(--glow); }

/* ---------- 全局余烬画布 ---------- */
#embers { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.page { position: relative; z-index: 1; }

/* ---------- 顶栏 ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 8, 12, 0.72); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav .container { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 20px; }
.brand .flame { font-size: 23px; filter: drop-shadow(0 0 8px rgba(255,107,53,.8)); }
.brand .en { color: var(--ink-3); font-weight: 600; font-size: 14px; letter-spacing: 1px; }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { color: var(--ink-2); font-weight: 600; font-size: 14px; }
.nav-links a:hover { color: var(--flame); }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px; justify-content: center;
  background: linear-gradient(135deg, var(--flame), var(--ember));
  color: #1a1206; font-weight: 800; font-size: 15px;
  padding: 12px 24px; border-radius: 999px; border: none; cursor: pointer;
  box-shadow: 0 6px 24px rgba(255,107,53,.35);
  transition: transform .18s, box-shadow .18s, filter .18s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 34px rgba(255,107,53,.55); filter: brightness(1.05); }
.btn.ghost { background: transparent; color: var(--flame); border: 1.5px solid rgba(255,107,53,.5); box-shadow: none; }
.btn.ghost:hover { background: rgba(255,107,53,.12); }
.btn.lg { padding: 16px 36px; font-size: 17px; }

/* ---------- Hero ---------- */
.hero { position: relative; text-align: center; padding: 120px 0 90px; }
.hero .spark-orb {
  font-size: 84px; line-height: 1; display: inline-block;
  filter: drop-shadow(0 0 30px rgba(255,107,53,.9));
  animation: pulse 2.6s ease-in-out infinite;
}
@keyframes pulse { 0%,100%{ transform: scale(1); filter: drop-shadow(0 0 24px rgba(255,107,53,.7)); } 50%{ transform: scale(1.08); filter: drop-shadow(0 0 46px rgba(255,182,39,1)); } }
.hero .terminal {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 26px;
  font-family: var(--mono); font-size: 13px; color: var(--ink-2);
  background: rgba(255,255,255,.04); border: 1px solid var(--line);
  padding: 7px 14px; border-radius: 8px;
}
.hero .terminal .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--flame); box-shadow: 0 0 8px var(--flame); }
.hero .terminal .cursor { display: inline-block; width: 8px; height: 15px; background: var(--ember); margin-left: 2px; animation: blink 1s steps(1) infinite; vertical-align: middle; }
@keyframes blink { 50% { opacity: 0; } }
.hero h1 { font-size: 64px; font-weight: 900; letter-spacing: -2px; margin: 18px 0 6px; }
.hero h1 .grad { background: linear-gradient(120deg, var(--hot), var(--flame) 55%, var(--ember)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero .tagline { font-size: 24px; color: var(--ink); font-weight: 700; opacity: .92; }
.hero .sub { font-size: 18px; color: var(--ink-2); max-width: 620px; margin: 22px auto 36px; }
.hero .cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero .pilot { margin-top: 26px; font-size: 13px; color: var(--ink-3); font-family: var(--mono); }
.hero .pilot b { color: var(--ember); }
.scroll-hint { margin-top: 56px; color: var(--ink-3); font-size: 12px; letter-spacing: 2px; animation: bob 2s ease-in-out infinite; }
@keyframes bob { 0%,100%{ transform: translateY(0); opacity:.6 } 50%{ transform: translateY(6px); opacity:1 } }

/* ---------- 数据信任带 ---------- */
.stats-band { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--panel); backdrop-filter: blur(8px); }
.stats-band .container { display: flex; flex-wrap: wrap; justify-content: space-around; align-items: center; gap: 20px; padding: 34px 0; }
.stats-band .stat { text-align: center; min-width: 130px; }
.stats-band .num { font-size: 34px; font-weight: 900; letter-spacing: -1px; background: linear-gradient(135deg, var(--flame), var(--ember)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stats-band .lab { color: var(--ink-2); font-size: 13px; margin-top: 6px; }
@media (max-width: 600px) { .stats-band .stat { min-width: 42%; } .stats-band .num { font-size: 28px; } }

/* ---------- 首页实时热榜小窗 ---------- */
.livebox { max-width: 640px; margin: 40px auto 0; background: var(--panel); border: 1px solid rgba(255,107,53,.22); border-radius: 20px; padding: 12px; }
.livelist { display: flex; flex-direction: column; }
.liveloading { text-align: center; color: var(--ink-3); padding: 30px; font-size: 14px; }
.liverow { display: flex; align-items: center; gap: 14px; padding: 14px 14px; border-radius: 12px; transition: background .2s ease; }
.liverow:hover { background: rgba(255,107,53,.08); }
.liverow + .liverow { border-top: 1px solid var(--line); }
.liverk { width: 28px; text-align: center; font-size: 19px; color: var(--ink-2); flex: none; }
.liverk b { color: var(--ink-3); font-size: 15px; font-weight: 800; }
.livetitle { flex: 1; min-width: 0; font-size: 15px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.livetitle i { display: block; font-style: normal; font-size: 12px; font-weight: 500; color: var(--ink-3); margin-top: 3px; }
.livehot { color: var(--flame); font-weight: 800; font-size: 13px; flex: none; }
.livemore { display: block; text-align: center; color: var(--flame); font-weight: 700; font-size: 14px; padding: 16px 0 8px; }

/* ---------- 通用区块 ---------- */
.section { padding: 96px 0; position: relative; }
.kicker { font-family: var(--mono); font-size: 13px; color: var(--flame); letter-spacing: 2px; text-transform: uppercase; margin-bottom: 14px; }
.section h2 { font-size: 40px; font-weight: 850; letter-spacing: -1px; line-height: 1.2; }
.section .lead { color: var(--ink-2); font-size: 17px; margin-top: 16px; max-width: 620px; }
.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }

/* 宣言大字 */
.manifesto { text-align: center; padding: 110px 0; }
.manifesto p { font-size: clamp(26px, 4.4vw, 46px); font-weight: 800; line-height: 1.4; letter-spacing: -1px; }
.manifesto .dim { color: var(--ink-3); }
.manifesto .hl { color: var(--flame); text-shadow: 0 0 30px rgba(255,107,53,.5); }

/* 特性两栏 */
.feature-row { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.feature-row.rev .copy { order: 2; }
.feature-row + .feature-row { margin-top: 110px; }
.copy h3 { font-size: 30px; font-weight: 800; margin: 12px 0 14px; }
.copy p { color: var(--ink-2); font-size: 16px; }
.copy .quote { margin-top: 18px; padding-left: 16px; border-left: 2px solid var(--flame); color: var(--hot); font-style: italic; font-size: 15px; }

/* 玻璃舞台 */
.stage { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 24px; padding: 28px; backdrop-filter: blur(10px); overflow: hidden; min-height: 320px; display: flex; align-items: center; justify-content: center; }
.stage::before { content: ""; position: absolute; inset: 0; background: radial-gradient(400px 200px at 70% 0%, rgba(255,107,53,.16), transparent 70%); }

/* 手机模型 */
.phone { width: 248px; height: 510px; border-radius: 38px; background: #0d0f16; border: 8px solid #1b1e28; box-shadow: 0 30px 80px rgba(0,0,0,.6), 0 0 50px rgba(255,107,53,.18); position: relative; overflow: hidden; }
.phone .notch { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); width: 96px; height: 22px; background: #1b1e28; border-radius: 0 0 14px 14px; z-index: 3; }
.phone .screen { position: absolute; inset: 0; padding: 38px 12px 12px; overflow: hidden; }
.app-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.app-head .t { font-weight: 800; font-size: 15px; color: var(--flame); }
.scope-tabs { display: flex; gap: 6px; margin-bottom: 12px; }
.scope-tabs span { font-size: 9px; padding: 4px 8px; border-radius: 999px; color: var(--ink-2); background: rgba(255,255,255,.05); }
.scope-tabs span.on { background: rgba(255,107,53,.18); color: var(--ember); }
.idea-card { background: rgba(255,255,255,.04); border: 1px solid var(--line); border-radius: 12px; padding: 10px; margin-bottom: 9px; }
.idea-card .r1 { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.idea-card .av { width: 18px; height: 18px; border-radius: 50%; background: linear-gradient(135deg,var(--flame),var(--ember)); }
.idea-card .nm { font-size: 9px; color: var(--ink-2); }
.idea-card .hot { margin-left: auto; font-size: 9px; color: var(--flame); font-weight: 800; }
.idea-card .ti { font-size: 11px; font-weight: 700; color: var(--ink); line-height: 1.4; }
.idea-card .tags { display: flex; gap: 4px; margin-top: 7px; }
.idea-card .tags i { font-size: 8px; font-style: normal; padding: 2px 6px; border-radius: 5px; background: rgba(255,107,53,.14); color: var(--ember); }

/* 热度公式 */
.formula { text-align: center; }
.formula .eq { font-family: var(--mono); font-size: clamp(20px, 3vw, 30px); font-weight: 700; letter-spacing: -.5px; }
.formula .eq .v { color: var(--flame); text-shadow: 0 0 18px rgba(255,107,53,.6); }
.formula .eq .a { color: var(--ember); text-shadow: 0 0 18px rgba(255,182,39,.6); }
.formula .leg { display: flex; gap: 22px; justify-content: center; flex-wrap: wrap; margin-top: 22px; font-size: 12px; color: var(--ink-2); font-family: var(--mono); }
.formula .leg b { color: var(--ink); }

/* 排行榜爬升 */
.board { width: 100%; max-width: 320px; }
.board .row { display: flex; align-items: center; gap: 10px; padding: 9px 4px; border-bottom: 1px solid var(--line); }
.board .rk { width: 22px; height: 22px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; background: rgba(255,255,255,.06); color: var(--ink-2); }
.board .row:nth-child(1) .rk { background: linear-gradient(135deg,var(--flame),var(--ember)); color: #1a1206; }
.board .nm2 { font-size: 12px; flex: 1; color: var(--ink); }
.board .bar { height: 6px; border-radius: 3px; background: linear-gradient(90deg,var(--flame),var(--ember)); width: 0; transition: width 1.1s cubic-bezier(.2,.8,.2,1); box-shadow: 0 0 10px rgba(255,107,53,.5); }
.board .sc { font-size: 11px; color: var(--flame); font-family: var(--mono); width: 36px; text-align: right; }

/* 扩散环 / 网络图 SVG 容器 */
.viz { width: 100%; height: 320px; }
.viz text { font-family: var(--mono); }

/* 对话故事 */
.story { background: linear-gradient(180deg, transparent, rgba(255,107,53,.04)); }
.chat { max-width: 560px; margin: 36px auto 0; }
.bubble { display: flex; gap: 10px; margin-bottom: 14px; opacity: 0; transform: translateY(12px); }
.bubble.in { opacity: 1; transform: none; transition: all .5s; }
.bubble.me { flex-direction: row-reverse; }
.bubble .ava { width: 34px; height: 34px; border-radius: 50%; flex: none; background: linear-gradient(135deg,var(--flame),var(--ember)); display:flex;align-items:center;justify-content:center;font-size:15px; }
.bubble.me .ava { background: linear-gradient(135deg,#3b82f6,#22d3ee); }
.bubble .txt { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 11px 15px; font-size: 15px; max-width: 78%; }
.bubble.me .txt { background: rgba(255,107,53,.14); border-color: rgba(255,107,53,.25); }

/* 数字 / 价值卡 */
.grid3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; margin-top: 46px; }
.vcard { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 28px; }
.vcard .ic { font-size: 30px; filter: drop-shadow(0 0 10px rgba(255,107,53,.5)); }
.vcard h4 { font-size: 18px; margin: 12px 0 6px; }
.vcard p { color: var(--ink-2); font-size: 14px; }
.vcard { transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease; }
.vcard:hover { transform: translateY(-4px); border-color: rgba(255,107,53,.4); box-shadow: 0 14px 40px rgba(255,107,53,.1); }

/* 三步点火 */
.flow { display: flex; align-items: stretch; justify-content: center; gap: 14px; margin-top: 50px; flex-wrap: nowrap; }
.flow .step { flex: 1 1 0; min-width: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 30px 26px; position: relative; text-align: left; }
.flow .step .sn { font-family: var(--mono); font-size: 13px; color: var(--flame); letter-spacing: 2px; }
.flow .step .si { font-size: 34px; margin: 8px 0 10px; filter: drop-shadow(0 0 12px rgba(255,107,53,.55)); }
.flow .step h4 { font-size: 19px; font-weight: 800; margin-bottom: 8px; }
.flow .step p { color: var(--ink-2); font-size: 14px; line-height: 1.7; }
.flow .arrow { display: flex; align-items: center; color: var(--flame); font-size: 26px; font-weight: 700; opacity: .7; }
@media (max-width: 760px) { .flow { flex-wrap: wrap; } .flow .arrow { transform: rotate(90deg); width: 100%; justify-content: center; } .flow .step { flex-basis: 100%; } }

/* FAQ */
.faq { max-width: 760px; margin: 44px auto 0; text-align: left; }
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 4px 22px; margin-bottom: 14px; transition: border-color .2s ease; }
.faq details[open] { border-color: rgba(255,107,53,.4); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 0; font-size: 17px; font-weight: 700; color: var(--ink); display: flex; justify-content: space-between; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; color: var(--flame); font-size: 24px; font-weight: 400; transition: transform .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--ink-2); font-size: 15px; line-height: 1.8; padding: 0 0 20px; margin: 0; }

/* git 极客段 */
.geek { text-align: center; }
.geek .code { display: inline-block; text-align: left; font-family: var(--mono); font-size: 15px; background: #0a0c12; border: 1px solid var(--line); border-radius: 14px; padding: 22px 26px; margin-top: 26px; color: var(--ink-2); line-height: 1.9; }
.geek .code .c { color: var(--ink-3); }
.geek .code .k { color: var(--flame); }
.geek .code .s { color: var(--ember); }

/* CTA */
.cta-band { text-align: center; padding: 90px 32px; border-radius: 30px; background: radial-gradient(600px 300px at 50% 0%, rgba(255,107,53,.22), transparent 70%), var(--bg-2); border: 1px solid rgba(255,107,53,.2); margin: 40px 0; }
.cta-band h2 { font-size: 42px; font-weight: 900; letter-spacing: -1px; }
.cta-band p { color: var(--ink-2); margin: 14px 0 30px; font-size: 17px; }

/* 页脚 */
.footer { border-top: 1px solid var(--line); padding: 50px 0 36px; color: var(--ink-3); }
.footer .top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 24px; }
.footer .col h5 { color: var(--ink); font-size: 14px; margin-bottom: 12px; }
.footer .col a { display: block; color: var(--ink-2); font-size: 14px; padding: 4px 0; }
.footer .col a:hover { color: var(--flame); }
.footer .cols { display: flex; gap: 56px; flex-wrap: wrap; }
.footer .bar { border-top: 1px solid var(--line); margin-top: 30px; padding-top: 20px; font-size: 13px; text-align: center; }
.footer .bar a:hover { color: var(--flame); }

/* 滚动揭示 */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 820px) {
  /* 移动端:保留品牌可点回首页 + 广场 + 下载按钮,隐藏次要锚点链接 */
  .nav-links { gap: 14px; }
  .nav-links a:not(.btn):not(.nav-keep) { display: none; }
  .nav-links .btn { padding: 9px 16px; font-size: 13px; }
  .nav .container { height: 56px; }
  .hero h1 { font-size: 44px; }
  .hero .tagline { font-size: 19px; }
  .section { padding: 70px 0; }
  .section h2 { font-size: 30px; }
  .feature-row { grid-template-columns: 1fr; gap: 30px; }
  .feature-row.rev .copy { order: 0; }
  .grid3 { grid-template-columns: 1fr; }
  .cta-band h2 { font-size: 30px; }
}
