/* ==========================================================================
   EG环境助手 · 官网
   深色高级视觉 + 玻璃拟态 + 轻量动效；不依赖任何 CDN / 外部字体
   ========================================================================== */

:root {
  --ink: #060a12;
  --ink-2: #0a1120;
  --ink-3: #0e1728;
  --panel: rgba(255, 255, 255, .045);
  --panel-2: rgba(255, 255, 255, .07);
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --text: #e9eef8;
  --muted: #93a2ba;
  --muted-2: #6c7c96;
  --brand: #3b82f6;
  --brand-2: #06b6d4;
  --brand-grad: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
  --ok: #34d399;
  --warn: #fbbf24;
  --radius: 18px;
  --wrap: 1180px;
  --font: "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", "Hiragino Sans GB", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 28px;
}

/* ==========================================================================
   顶部导航
   ========================================================================== */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  height: 68px;
  display: flex;
  align-items: center;
  transition: background .3s ease, border-color .3s ease, height .3s ease;
  border-bottom: 1px solid transparent;
}
.nav.solid {
  background: rgba(6, 10, 18, .78);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom-color: var(--line);
  height: 60px;
}
.nav .wrap {
  display: flex;
  align-items: center;
  gap: 36px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-weight: 700;
  letter-spacing: .02em;
  font-size: 17px;
}
.brand-mark {
  width: 30px; height: 30px;
  border-radius: 9px;
  background: var(--brand-grad);
  display: grid;
  place-items: center;
  box-shadow: 0 6px 16px rgba(59, 130, 246, .35);
}
.brand-mark img { width: 19px; }

.nav-links {
  display: flex;
  gap: 30px;
  margin-left: 8px;
  font-size: 14.5px;
  color: var(--muted);
}
.nav-links a { transition: color .2s ease; position: relative; }
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%; bottom: -6px;
  height: 1.5px;
  background: var(--brand-grad);
  transition: right .25s ease;
}
.nav-links a:hover { color: var(--text); }
.nav-links a:hover::after { right: 0; }
.nav-spacer { flex: 1; }

.nav-cta {
  height: 38px;
  padding: 0 20px;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all .22s ease;
}
.nav-cta:hover {
  background: var(--brand-grad);
  border-color: transparent;
  box-shadow: 0 8px 24px rgba(59, 130, 246, .38);
  transform: translateY(-1px);
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  padding: 168px 0 0;
  overflow: hidden;
  isolation: isolate;
}
.hero-bg {
  position: absolute;
  inset: -20% -10% 0 -10%;
  z-index: -1;
  background:
    radial-gradient(58% 46% at 50% 0%, rgba(37, 99, 235, .34) 0%, transparent 70%),
    radial-gradient(40% 40% at 82% 18%, rgba(6, 182, 212, .20) 0%, transparent 72%),
    radial-gradient(46% 42% at 12% 26%, rgba(99, 102, 241, .18) 0%, transparent 72%);
}
.hero-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, .045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(70% 55% at 50% 8%, #000 0%, transparent 78%);
  -webkit-mask-image: radial-gradient(70% 55% at 50% 8%, #000 0%, transparent 78%);
}
.hero-stars {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(rgba(255, 255, 255, .5) 1px, transparent 1px);
  background-size: 220px 180px;
  opacity: .16;
  mask-image: linear-gradient(to bottom, #000, transparent 70%);
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent 70%);
}

.hero-copy { text-align: center; max-width: 820px; margin: 0 auto; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 30px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, .04);
  color: #b9c6dc;
  font-size: 12.5px;
  letter-spacing: .06em;
  backdrop-filter: blur(6px);
}
.eyebrow .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(52, 211, 153, .18);
}

.hero h1 {
  margin: 26px 0 0;
  font-size: clamp(38px, 6.2vw, 66px);
  line-height: 1.14;
  letter-spacing: -.02em;
  font-weight: 800;
}
.hero h1 .grad {
  background: linear-gradient(100deg, #7dd3fc 0%, #3b82f6 45%, #a78bfa 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-lead {
  margin: 24px auto 0;
  max-width: 660px;
  color: var(--muted);
  font-size: 16.5px;
  line-height: 1.8;
}

.hero-actions {
  margin-top: 38px;
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}
.btn-primary, .btn-ghost {
  height: 50px;
  padding: 0 28px;
  border-radius: 12px;
  font-size: 15.5px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .22s cubic-bezier(.2,.7,.3,1), box-shadow .22s ease, background .22s ease;
}
.btn-primary {
  background: var(--brand-grad);
  color: #fff;
  box-shadow: 0 12px 32px rgba(37, 99, 235, .34), inset 0 1px 0 rgba(255, 255, 255, .28);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 44px rgba(37, 99, 235, .46), inset 0 1px 0 rgba(255, 255, 255, .3);
}
.btn-ghost {
  background: var(--panel);
  border-color: var(--line-strong);
  color: var(--text);
}
.btn-ghost:hover { background: var(--panel-2); transform: translateY(-2px); }

.hero-meta {
  margin-top: 20px;
  display: flex;
  gap: 18px;
  justify-content: center;
  flex-wrap: wrap;
  color: var(--muted-2);
  font-size: 13px;
}
.hero-meta span { display: inline-flex; align-items: center; gap: 7px; }
.hero-meta i {
  width: 4px; height: 4px;
  border-radius: 50%;
  background: currentColor;
  opacity: .7;
  font-style: normal;
}

/* ---- Hero 里的窗口舞台 ---- */
.hero-stage {
  position: relative;
  margin: 64px auto 0;
  max-width: 1080px;
  padding: 0 28px;
}
.stage-glow {
  position: absolute;
  left: 50%; top: 8%;
  width: 76%; height: 60%;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(59, 130, 246, .46), transparent 78%);
  filter: blur(60px);
  z-index: -1;
  pointer-events: none;
}
.stage-topline {
  position: absolute;
  left: 12%; right: 12%;
  top: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(125, 211, 252, .85), transparent);
}
.stage-floor {
  position: absolute;
  left: 0; right: 0; bottom: -60px;
  height: 120px;
  background: radial-gradient(60% 100% at 50% 0%, rgba(59, 130, 246, .22), transparent 72%);
  filter: blur(20px);
  pointer-events: none;
}

/* 窗口缩放容器 */
.demo-frame {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 12px;
}
.demo-scaler {
  width: 1080px;
  height: 740px;
  transform-origin: top left;
  will-change: transform;
}
.demo-scaler .win {
  box-shadow: 0 40px 90px rgba(0, 0, 0, .6), 0 0 0 1px rgba(255, 255, 255, .08);
  border-radius: 12px;
}
.hero-stage img {
  border-radius: 12px;
  box-shadow: 0 40px 90px rgba(0, 0, 0, .6), 0 0 0 1px rgba(255, 255, 255, .08);
}

/* 锚点滚动时避开固定导航 */
.section, .cta, .hero { scroll-margin-top: 78px; }


.demo-fallback { display: none; }
.demo-fallback img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 40px 90px rgba(0, 0, 0, .6), 0 0 0 1px rgba(255, 255, 255, .08);
}

/* ==========================================================================
   数据条
   ========================================================================== */
.metrics {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.028), transparent);
}
.metrics .wrap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  padding-top: 34px;
  padding-bottom: 34px;
}
.metric { text-align: center; border-left: 1px solid var(--line); padding: 0 12px; }
.metric:first-child { border-left: none; }
.metric b {
  display: block;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -.02em;
  background: linear-gradient(180deg, #fff, #9db6dd);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.metric span { font-size: 13px; color: var(--muted-2); letter-spacing: .04em; }

/* ==========================================================================
   区块通用
   ========================================================================== */
.section { padding: 108px 0; position: relative; }
.section-head { max-width: 700px; }
.section-head.center { margin: 0 auto; text-align: center; }
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  letter-spacing: .16em;
  color: #7dd3fc;
  text-transform: uppercase;
  font-weight: 600;
}
.kicker::before {
  content: "";
  width: 26px; height: 1px;
  background: linear-gradient(90deg, transparent, #7dd3fc);
}
.section-head.center .kicker::after {
  content: "";
  width: 26px; height: 1px;
  background: linear-gradient(90deg, #7dd3fc, transparent);
}
.section h2 {
  margin: 16px 0 0;
  font-size: clamp(26px, 3.6vw, 42px);
  line-height: 1.22;
  letter-spacing: -.02em;
  font-weight: 800;
}
.section-desc {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 16px;
}

/* ==========================================================================
   功能卡片
   ========================================================================== */
.features {
  margin-top: 54px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.fcard {
  position: relative;
  padding: 28px 26px 26px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.018));
  cursor: pointer;
  overflow: hidden;
  transition: transform .28s cubic-bezier(.2,.7,.3,1), border-color .28s ease, background .28s ease;
}
.fcard::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: radial-gradient(220px 120px at var(--mx, 50%) var(--my, 0%), rgba(59, 130, 246, .22), transparent 70%);
  opacity: 0;
  transition: opacity .3s ease;
  pointer-events: none;
}
.fcard:hover {
  transform: translateY(-4px);
  border-color: rgba(125, 211, 252, .38);
}
.fcard:hover::after { opacity: 1; }
.fcard .ico {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(59, 130, 246, .14);
  border: 1px solid rgba(125, 211, 252, .26);
  color: #8ecbff;
  margin-bottom: 18px;
}
.fcard .ico svg { width: 21px; height: 21px; }
.fcard h3 {
  margin: 0 0 8px;
  font-size: 17.5px;
  font-weight: 700;
  letter-spacing: .01em;
}
.fcard p {
  margin: 0;
  color: var(--muted);
  font-size: 14.2px;
  line-height: 1.72;
}
.fcard .go {
  margin-top: 16px;
  font-size: 13px;
  color: #7dd3fc;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  opacity: 0;
  transform: translateY(4px);
  transition: all .26s ease;
}
.fcard:hover .go { opacity: 1; transform: none; }

/* ==========================================================================
   演示区
   ========================================================================== */
.demo-section {
  background:
    radial-gradient(60% 50% at 50% 0%, rgba(37, 99, 235, .16), transparent 70%),
    var(--ink-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.demo-shell {
  margin-top: 46px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: rgba(10, 17, 32, .6);
  padding: 18px;
  box-shadow: 0 40px 100px rgba(0, 0, 0, .45);
}
.demo-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 2px 4px 14px;
}
.demo-bar .lights { display: flex; gap: 7px; }
.demo-bar .lights i {
  width: 11px; height: 11px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .16);
}
.demo-bar .lights i:first-child { background: #ff5f57; }
.demo-bar .lights i:nth-child(2) { background: #febc2e; }
.demo-bar .lights i:nth-child(3) { background: #28c840; }
.demo-bar .title {
  margin-left: 6px;
  font-size: 12.5px;
  color: var(--muted-2);
  letter-spacing: .04em;
}
.demo-hint {
  margin-left: auto;
  font-size: 12.5px;
  color: var(--muted-2);
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.demo-hint b { color: #7dd3fc; font-weight: 600; }

.demo-tips {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.tip {
  padding: 18px 20px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--panel);
  font-size: 13.8px;
  color: var(--muted);
}
.tip b { display: block; color: var(--text); font-size: 14.5px; margin-bottom: 4px; font-weight: 600; }

/* ==========================================================================
   使用流程
   ========================================================================== */
.steps {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  counter-reset: step;
  position: relative;
}
.step {
  position: relative;
  padding: 30px 26px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.014));
}
.step .num {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
  color: #7dd3fc;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.step .num::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(125, 211, 252, .4), transparent);
}
.step {
  transition: transform .28s cubic-bezier(.2,.7,.3,1), border-color .28s ease, background .28s ease;
}
.step:hover {
  transform: translateY(-4px);
  border-color: rgba(125, 211, 252, .3);
  background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.02));
}
.step h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; }
.step p { margin: 0; color: var(--muted); font-size: 14.2px; }

/* ==========================================================================
   FAQ
   ========================================================================== */
.faq {
  margin-top: 44px;
  border-top: 1px solid var(--line);
}
.faq details {
  border-bottom: 1px solid var(--line);
}
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 22px 44px 22px 0;
  font-size: 16.5px;
  font-weight: 600;
  position: relative;
  transition: color .2s ease;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: #8ecbff; }
.faq summary::after {
  content: "";
  position: absolute;
  right: 8px; top: 50%;
  width: 9px; height: 9px;
  border-right: 1.8px solid var(--muted);
  border-bottom: 1.8px solid var(--muted);
  transform: translateY(-70%) rotate(45deg);
  transition: transform .26s ease, border-color .26s ease;
}
.faq details[open] summary::after {
  transform: translateY(-30%) rotate(-135deg);
  border-color: #7dd3fc;
}
.faq .answer {
  padding: 0 60px 24px 0;
  color: var(--muted);
  font-size: 14.8px;
  line-height: 1.8;
}

/* ==========================================================================
   CTA
   ========================================================================== */
.cta {
  position: relative;
  padding: 96px 0;
  text-align: center;
  overflow: hidden;
  border-top: 1px solid var(--line);
}
.cta::before {
  content: "";
  position: absolute;
  left: 50%; top: 0;
  width: 900px; height: 420px;
  transform: translate(-50%, -40%);
  background: radial-gradient(closest-side, rgba(59, 130, 246, .35), transparent 72%);
  filter: blur(30px);
  pointer-events: none;
}
.cta h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  letter-spacing: -.02em;
}
.cta p { margin: 16px 0 0; color: var(--muted); font-size: 16px; }
.cta .hero-actions { margin-top: 32px; }

/* ==========================================================================
   页脚
   ========================================================================== */
.footer {
  border-top: 1px solid var(--line);
  padding: 34px 0;
  color: var(--muted-2);
  font-size: 13px;
}
.footer .wrap {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: space-between;
}
.footer .left { display: flex; align-items: center; gap: 12px; }
.footer .brand-mark { width: 26px; height: 26px; border-radius: 8px; }
.footer .brand-mark img { width: 16px; }

/* ==========================================================================
   入场动画
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s cubic-bezier(.2,.7,.3,1), transform .7s cubic-bezier(.2,.7,.3,1);
  transition-delay: var(--d, 0ms);
}
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn-primary, .btn-ghost, .fcard { transition: none; }
}

/* ==========================================================================
   响应式
   ========================================================================== */
@media (max-width: 1024px) {
  .features { grid-template-columns: repeat(2, 1fr); }
  .metrics .wrap { grid-template-columns: repeat(2, 1fr); row-gap: 26px; }
  .metric:nth-child(3) { border-left: none; }
}

@media (max-width: 900px) {
  .nav-links { display: none; }
  .hero { padding-top: 132px; }
  .hero-stage { padding: 0 20px; margin-top: 44px; }
  /* 小屏不跑交互界面，直接给截图，保证清晰度 */
  .demo-scaler { display: none; }
  .demo-fallback { display: block; }
  .steps { grid-template-columns: 1fr; }
  .demo-tips { grid-template-columns: 1fr; }
  .section { padding: 76px 0; }
}

@media (max-width: 720px) {
  .features { grid-template-columns: 1fr; }
  /* 数据条保持两列，比一列四行更紧凑 */
  .metrics .wrap { grid-template-columns: repeat(2, 1fr); row-gap: 22px; padding-top: 26px; padding-bottom: 26px; }
  .metric:nth-child(3) { border-left: none; }
  .metric b { font-size: 26px; }
  .hero h1 { font-size: 34px; }
  .hero-actions .btn-primary, .hero-actions .btn-ghost { width: 100%; justify-content: center; }
  .wrap { padding: 0 20px; }
}
