/* ============================================================
   西安萤火新序科技有限公司 · 官网样式
   结构：变量 → 基础 → 背景 → 导航 → Hero → 能力条 → 区块通用
         → 业务 Bento → 流程 → 关于 → 联系 → 页脚 → 动效 → 响应式
   ============================================================ */

:root {
  --bg: #060810;
  --bg-soft: #0a0e1a;
  --text: #e8edfb;
  --muted: #939cba;
  --line: rgba(147, 156, 186, 0.14);
  --card: rgba(255, 255, 255, 0.035);
  --cyan: #22d3ee;
  --violet: #8b5cf6;
  --gold: #fbbf24;
  --radius: 18px;
  --content: 1200px;
  --pad-x: clamp(20px, 5vw, 64px);
}

/* ── 基础 ── */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
::selection { background: rgba(34, 211, 238, 0.32); }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { line-height: 1.3; }

/* ── 背景层 ── */
.bg-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(147,156,186,0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(147,156,186,0.055) 1px, transparent 1px);
  background-size: 54px 54px;
  -webkit-mask-image: radial-gradient(ellipse 90% 72% at 50% 28%, #000 30%, transparent 100%);
  mask-image: radial-gradient(ellipse 90% 72% at 50% 28%, #000 30%, transparent 100%);
}
.bg-glow {
  position: fixed; z-index: 0; pointer-events: none;
  border-radius: 50%; filter: blur(130px);
}
.bg-glow--1 { width: 620px; height: 620px; top: -220px; left: -180px; background: rgba(139,92,246,0.15); }
.bg-glow--2 { width: 560px; height: 560px; top: 18%; right: -220px; background: rgba(34,211,238,0.09); }
#fireflies { position: fixed; inset: 0; z-index: 1; pointer-events: none; }

/* ── 导航 ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 16px var(--pad-x);
  background: rgba(6, 8, 16, 0.55);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}
.nav--scrolled { border-bottom-color: var(--line); }
.brand { display: flex; align-items: center; gap: 12px; }
.brand__logo {
  width: 38px; height: 38px; border-radius: 11px; position: relative; flex-shrink: 0;
  background: linear-gradient(135deg, var(--violet), var(--cyan));
  box-shadow: 0 0 26px rgba(34, 211, 238, 0.35);
}
.brand__logo::after {
  content: ""; position: absolute; inset: 0; margin: auto;
  width: 8px; height: 8px; border-radius: 50%; background: #fff;
  box-shadow: 0 0 12px 4px rgba(255, 255, 255, 0.75);
  animation: core-pulse 2.4s ease-in-out infinite;
}
@keyframes core-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.45); opacity: 0.75; } }
.brand__text { display: flex; flex-direction: column; line-height: 1.25; }
.brand__cn { font-weight: 700; font-size: 16px; letter-spacing: 1px; }
.brand__en { font-size: 10px; letter-spacing: 3px; color: var(--muted); }
.nav__links { display: flex; gap: 32px; }
.nav__links a {
  position: relative; font-size: 14px; letter-spacing: 1px; color: var(--muted);
  transition: color 0.25s; padding: 4px 0;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: -3px; height: 2px; width: 0;
  border-radius: 2px; background: linear-gradient(90deg, var(--cyan), var(--violet));
  transition: width 0.3s;
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { width: 100%; }
.nav__cta {
  font-size: 13px; letter-spacing: 1px; color: var(--text);
  padding: 9px 22px; border-radius: 999px;
  border: 1px solid rgba(34, 211, 238, 0.35); background: rgba(34, 211, 238, 0.06);
  transition: background 0.25s, box-shadow 0.25s;
}
.nav__cta:hover { background: rgba(34, 211, 238, 0.14); box-shadow: 0 0 22px rgba(34, 211, 238, 0.25); }

/* ── Hero ── */
.hero {
  position: relative; z-index: 2;
  max-width: var(--content); margin: 0 auto;
  min-height: 100vh;
  display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: 48px;
  padding: 150px var(--pad-x) 90px;
}
.hero__badge {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 12px; letter-spacing: 3px; color: var(--cyan);
  border: 1px solid rgba(34, 211, 238, 0.3); border-radius: 999px;
  padding: 7px 18px; margin-bottom: 30px; background: rgba(34, 211, 238, 0.05);
}
.hero__badge .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan); animation: core-pulse 1.8s infinite;
}
.hero__title { font-size: clamp(34px, 4.6vw, 58px); font-weight: 800; letter-spacing: 1px; }
.hero__title .grad {
  background: linear-gradient(92deg, var(--cyan) 10%, #a78bfa 55%, var(--gold) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero__sub { margin-top: 24px; color: var(--muted); font-size: clamp(14px, 1.4vw, 16px); max-width: 480px; }
.hero__actions { margin-top: 40px; display: flex; gap: 16px; flex-wrap: wrap; }
.btn {
  display: inline-block; padding: 13px 34px; border-radius: 999px;
  font-size: 14px; letter-spacing: 2px; transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.btn--primary {
  color: #04121a; font-weight: 700;
  background: linear-gradient(92deg, var(--cyan), #7dd3fc);
  box-shadow: 0 8px 30px rgba(34, 211, 238, 0.32);
}
.btn--primary:hover { transform: translateY(-3px); box-shadow: 0 14px 42px rgba(34, 211, 238, 0.45); }
.btn--ghost { border: 1px solid var(--line); background: var(--card); color: var(--text); }
.btn--ghost:hover { transform: translateY(-3px); border-color: rgba(139, 92, 246, 0.6); }

/* Hero 右侧视觉：终端 + 轨道 */
.hero__visual { position: relative; min-height: 380px; display: flex; align-items: center; justify-content: center; }
.terminal {
  position: relative; z-index: 2; width: min(400px, 100%);
  border-radius: 16px; overflow: hidden;
  background: rgba(10, 14, 26, 0.85);
  border: 1px solid var(--line);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 60px rgba(34, 211, 238, 0.08);
  animation: float 6s ease-in-out infinite;
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.terminal__bar {
  display: flex; align-items: center; gap: 7px;
  padding: 12px 16px; border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, 0.02);
}
.terminal__bar i { width: 11px; height: 11px; border-radius: 50%; background: rgba(147, 156, 186, 0.35); }
.terminal__bar i:first-child { background: rgba(232, 100, 90, 0.7); }
.terminal__bar i:nth-child(2) { background: rgba(240, 190, 80, 0.7); }
.terminal__bar i:nth-child(3) { background: rgba(87, 200, 120, 0.7); }
.terminal__bar span { margin-left: 8px; font-size: 11px; color: var(--muted); letter-spacing: 1px; }
.terminal__body {
  padding: 20px 22px 26px; font-size: 13.5px; line-height: 2;
  font-family: "SF Mono", "JetBrains Mono", Consolas, monospace; color: #cdd6ec;
  white-space: pre-wrap; overflow: hidden;
}
.t-ok { color: #4ade80; } .t-dim { color: var(--muted); }
.t-cyan { color: var(--cyan); } .t-gold { color: var(--gold); }
.orbital { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.orbital__ring {
  position: absolute; border-radius: 50%; border: 1px dashed rgba(34, 211, 238, 0.22);
  animation: spin 24s linear infinite;
}
.orbital__ring--1 { width: 340px; height: 340px; }
.orbital__ring--2 { width: 250px; height: 250px; border-color: rgba(139, 92, 246, 0.3); animation-direction: reverse; animation-duration: 16s; }
.orbital__ring--3 { width: 160px; height: 160px; animation-duration: 10s; border-style: solid; border-color: rgba(251, 191, 36, 0.2); }
.orbital__core {
  width: 10px; height: 10px; border-radius: 50%; background: var(--cyan);
  box-shadow: 0 0 24px 6px rgba(34, 211, 238, 0.45);
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── 能力条 ── */
.marquee {
  position: relative; z-index: 2; overflow: hidden;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.015);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track {
  display: flex; gap: 64px; padding: 20px 0; width: max-content;
  animation: marquee 30s linear infinite;
}
.marquee__track span { font-size: 14px; letter-spacing: 3px; color: var(--muted); white-space: nowrap; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ── 区块通用 ── */
.section { position: relative; z-index: 2; max-width: var(--content); margin: 0 auto; padding: clamp(80px, 10vw, 130px) var(--pad-x) 0; }
.section__head { text-align: center; margin-bottom: clamp(44px, 6vw, 70px); }
.section__head--left { text-align: left; margin-bottom: 30px; }
.section__tag { font-size: 12px; letter-spacing: 5px; color: var(--cyan); margin-bottom: 12px; }
.section__title { font-size: clamp(26px, 3.2vw, 38px); font-weight: 800; letter-spacing: 2px; }
.section__head:not(.section__head--left) .section__title::after {
  content: ""; display: block; width: 52px; height: 3px; margin: 18px auto 0;
  border-radius: 3px; background: linear-gradient(90deg, var(--cyan), var(--violet));
}

/* ── 业务 Bento ── */
.bento { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.bento__item {
  position: relative; overflow: hidden;
  padding: 32px 30px; border-radius: var(--radius);
  background: var(--card); border: 1px solid var(--line);
  transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.bento__item::before {
  content: ""; position: absolute; inset: 0; opacity: 0; transition: opacity 0.3s;
  background: radial-gradient(460px 180px at 18% 0%, rgba(34, 211, 238, 0.11), transparent 62%);
}
.bento__item:hover { transform: translateY(-6px); border-color: rgba(34, 211, 238, 0.4); box-shadow: 0 22px 54px rgba(0, 0, 0, 0.45); }
.bento__item:hover::before { opacity: 1; }
.bento__item--wide { grid-column: span 2; }
.bento__icon {
  width: 46px; height: 46px; border-radius: 12px; margin-bottom: 20px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: var(--cyan);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.14), rgba(139, 92, 246, 0.14));
  border: 1px solid rgba(34, 211, 238, 0.22);
}
.bento__item h3 { font-size: 19px; letter-spacing: 1px; margin-bottom: 12px; }
.bento__item p { color: var(--muted); font-size: 14.5px; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.chips li {
  font-size: 11.5px; color: var(--cyan); padding: 3px 13px; border-radius: 999px;
  border: 1px solid rgba(34, 211, 238, 0.24); background: rgba(34, 211, 238, 0.05);
}

/* ── 流程 ── */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: step; }
.step {
  position: relative; padding: 28px 24px; border-radius: var(--radius);
  background: var(--card); border: 1px solid var(--line);
  transition: transform 0.3s, border-color 0.3s;
}
.step:hover { transform: translateY(-6px); border-color: rgba(139, 92, 246, 0.45); }
.step__no {
  display: block; font-size: 30px; font-weight: 800; margin-bottom: 16px;
  background: linear-gradient(92deg, var(--cyan), var(--violet));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-variant-numeric: tabular-nums;
}
.step h3 { font-size: 17px; letter-spacing: 1px; margin-bottom: 10px; }
.step p { color: var(--muted); font-size: 13.5px; }

/* ── 关于 ── */
.about { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 56px; align-items: center; }
.about__copy p { color: var(--muted); font-size: 15px; margin-bottom: 16px; }
.about__facts { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.fact {
  padding: 30px 24px; border-radius: var(--radius); text-align: center;
  background: var(--card); border: 1px solid var(--line);
  transition: transform 0.3s, border-color 0.3s;
}
.fact:hover { transform: translateY(-5px); border-color: rgba(34, 211, 238, 0.4); }
.fact b {
  display: block; font-size: 26px; font-weight: 800; margin-bottom: 6px;
  background: linear-gradient(92deg, var(--cyan), var(--violet));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.fact span { color: var(--muted); font-size: 13px; letter-spacing: 2px; }

/* ── 联系 ── */
.contact {
  text-align: center; padding: clamp(50px, 7vw, 80px) 30px; border-radius: 22px;
  background: linear-gradient(160deg, rgba(34, 211, 238, 0.07), rgba(139, 92, 246, 0.09));
  border: 1px solid var(--line);
}
.contact h2 { font-size: clamp(24px, 3vw, 32px); letter-spacing: 1px; }
.contact > p { color: var(--muted); margin-top: 16px; font-size: 15px; }
.contact__actions { margin-top: 34px; }
.contact__meta { margin-top: 26px; font-size: 13px; }

/* ── 页脚 ── */
.footer {
  position: relative; z-index: 2; margin-top: clamp(70px, 9vw, 110px);
  border-top: 1px solid var(--line);
  padding: 32px var(--pad-x);
  display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between;
  color: var(--muted); font-size: 13px;
}
.footer__links { display: flex; gap: 22px; }
.footer__links a { transition: color 0.25s; }
.footer__links a:hover { color: var(--cyan); }

/* ── 动效 ── */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.on { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ── 响应式 ── */
@media (max-width: 1024px) {
  .hero { grid-template-columns: 1fr; gap: 60px; padding-top: 140px; }
  .hero__visual { min-height: 320px; }
  .steps { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .nav__links, .nav__cta { display: none; }
  .bento { grid-template-columns: 1fr; }
  .bento__item--wide { grid-column: span 1; }
  .about { grid-template-columns: 1fr; gap: 40px; }
  .steps { grid-template-columns: 1fr; }
}
