/* 张家口桥西区清洁供暖 · 主题（Power AI 光明未来派设计规范） */
:root {
  --bg: #FAFBFD; --bg-pure: #FFFFFF;
  --ink: #0B2B45; --ink-soft: #3D5A73; --ink-faint: #7A93A8;
  --energy: #00C2D1; --energy-deep: #0891B2; --energy-bright: #39E6F5;
  --energy-glow: rgba(0,194,209,.14);
  --save: #0FB981; --save-deep: #0B8A63;
  --cost: #F59E0B; --cost-deep: #B45309;
  --danger: #E11D48;
  --line: rgba(11,43,69,.08); --line-strong: rgba(11,43,69,.16);
  --font-sans: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Segoe UI', sans-serif;
  --font-mono: 'SF Mono', 'JetBrains Mono', Menlo, Consolas, 'Courier New', monospace;
  --radius: 16px; --radius-sm: 10px;
  --ease-out: cubic-bezier(.22,1,.36,1);
  --shadow-card: 0 1px 2px rgba(11,43,69,.04), 0 8px 32px rgba(11,43,69,.06);
  --shadow-lift: 0 2px 4px rgba(11,43,69,.05), 0 20px 60px rgba(0,194,209,.12);
  --nav-h: 64px; --max-w: 1240px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--ink); font-family: var(--font-sans); line-height: 1.7; -webkit-font-smoothing: antialiased; }
::selection { background: var(--energy); color: #fff; }
.mono { font-family: var(--font-mono); }

/* 精密网格背景 */
.grid-bg { position: fixed; inset: 0; z-index: -1; opacity: .55; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 30%, transparent 100%);
  mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 30%, transparent 100%); }

/* 导航 */
.nav { position: sticky; top: 0; z-index: 50; height: var(--nav-h); display: flex; align-items: center; gap: 22px;
  padding: 0 clamp(16px, 4vw, 40px); background: rgba(255,255,255,.78); backdrop-filter: blur(20px) saturate(1.4);
  border-bottom: 1px solid var(--line); }
.nav .brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.nav .brand .logo { width: 32px; height: 32px; border-radius: 9px; background: linear-gradient(135deg, var(--ink), var(--energy-deep));
  display: flex; align-items: center; justify-content: center; color: #fff; font: 700 13px var(--font-mono); }
.nav .brand b { font-size: 15.5px; }
.nav .brand small { font: 10px var(--font-mono); letter-spacing: .18em; color: var(--ink-faint); display: block; line-height: 1.2; }
.nav .links { display: flex; gap: 4px; margin-left: auto; flex-wrap: wrap; }
.nav .links a { font-size: 13.5px; font-weight: 500; color: var(--ink-soft); text-decoration: none; padding: 6px 11px; border-radius: 999px; transition: .25s; }
.nav .links a:hover { color: var(--energy-deep); background: var(--energy-glow); }

/* 布局 */
.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 clamp(18px, 4vw, 44px); }
section { padding: clamp(56px, 8vw, 96px) 0 8px; }
.sec-index { font: 11.5px var(--font-mono); letter-spacing: .2em; color: var(--energy-deep); display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.sec-index::before { content: ''; width: 34px; height: 1px; background: var(--energy); }
h2 { font-size: clamp(26px, 3.4vw, 38px); font-weight: 800; letter-spacing: -.01em; margin-bottom: 10px; }
.sec-sub { color: var(--ink-soft); max-width: 860px; margin-bottom: 30px; font-size: 15px; }

/* Hero */
.hero { padding: clamp(64px, 9vw, 110px) 0 30px; }
.hero .eyebrow { display: inline-flex; align-items: center; gap: 8px; font: 11px var(--font-mono); letter-spacing: .2em; color: var(--energy-deep);
  border: 1px solid var(--line-strong); border-radius: 999px; padding: 7px 16px; background: var(--bg-pure); margin-bottom: 22px; }
.hero .eyebrow i { width: 7px; height: 7px; border-radius: 50%; background: var(--energy); box-shadow: 0 0 10px var(--energy); animation: blink 2.2s infinite; }
@keyframes blink { 50% { opacity: .35; } }
h1 { font-size: clamp(34px, 5.4vw, 60px); font-weight: 800; line-height: 1.18; letter-spacing: -.02em; max-width: 1000px; }
.energy-word { background: linear-gradient(100deg, #0891B2 10%, #00C2D1 45%, #39E6F5 70%, #0891B2 95%);
  background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: flow 5s linear infinite; }
@keyframes flow { to { background-position: -220% 0; } }
.hero .sub { color: var(--ink-soft); font-size: 16px; max-width: 880px; margin: 18px 0 34px; }
.hero-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.hero-stats .stat { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 20px 22px; position: relative; overflow: hidden; transition: .35s var(--ease-out); }
.hero-stats .stat::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, var(--energy-deep), var(--energy-bright)); transform: scaleX(0); transform-origin: left; transition: .4s var(--ease-out); }
.hero-stats .stat:hover::before { transform: scaleX(1); }
.hero-stats .stat:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.stat .v { font: 700 clamp(26px, 2.8vw, 38px) var(--font-mono); letter-spacing: -.02em; }
.stat .v small { font-size: .42em; color: var(--energy-deep); font-weight: 600; margin-left: 3px; }
.stat .l { font-size: 13.5px; font-weight: 600; margin-top: 2px; }
.stat .n { font-size: 12px; color: var(--ink-faint); }

/* 卡片与面板 */
.panel { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius); box-shadow: var(--shadow-card); padding: clamp(20px, 3vw, 30px); margin-bottom: 18px; }
.panel h3 { font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.panel .h-sub { font-size: 12.5px; color: var(--ink-faint); margin-bottom: 16px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }

/* KPI 卡 */
.kpi { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 16px 18px; }
.kpi .v { font: 700 26px var(--font-mono); letter-spacing: -.02em; }
.kpi .v small { font-size: .44em; color: var(--energy-deep); font-weight: 600; }
.kpi .l { font-size: 12.5px; font-weight: 600; color: var(--ink-soft); }
.kpi .n { font-size: 11.5px; color: var(--ink-faint); }
.kpi.big { grid-column: span 2; padding: 20px 22px; }
.kpi.big .v { font-size: clamp(34px, 3.6vw, 46px); }
.kpi.good .v { color: var(--save-deep); }
.kpi.bad .v { color: var(--danger); }
.kpi.warn .v { color: var(--cost-deep); }

/* 结论条 */
.takeaway { border: 1.5px dashed var(--line-strong); background: #F2FAFB; border-radius: var(--radius-sm);
  padding: 14px 18px; font-size: 14px; color: var(--ink-soft); margin-top: 14px; }
.takeaway b { color: var(--ink); }
.takeaway .emo { color: var(--energy-deep); font-weight: 700; }

/* 滑块控制台 */
.ctrl { padding: 10px 0 6px; border-bottom: 1px dashed var(--line); }
.ctrl label { display: flex; justify-content: space-between; align-items: baseline; font-size: 13.5px; font-weight: 600; color: var(--ink-soft); margin-bottom: 4px; }
.ctrl output { font: 700 15px var(--font-mono); color: var(--ink); }
.ctrl output small { font-size: 11px; color: var(--ink-faint); font-weight: 400; }
.ctrl input[type=range] { width: 100%; accent-color: var(--energy-deep); height: 22px; cursor: pointer; }
.ctrl .hint { font-size: 11px; color: var(--ink-faint); }
.ctrl-group-t { font: 11px var(--font-mono); letter-spacing: .16em; color: var(--energy-deep); margin: 16px 0 2px; }

/* 情景/开关按钮 */
.seg { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.seg button { border: 1px solid var(--line-strong); background: var(--bg-pure); color: var(--ink-soft); border-radius: 999px;
  padding: 7px 16px; font-size: 12.5px; font-weight: 600; cursor: pointer; transition: .25s; font-family: var(--font-sans); }
.seg button:hover { border-color: var(--energy-deep); color: var(--energy-deep); }
.seg button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.switch-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0; }
.switch { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line-strong); border-radius: 999px;
  padding: 7px 14px; font-size: 12.5px; font-weight: 600; color: var(--ink-soft); cursor: pointer; background: var(--bg-pure); transition: .25s; user-select: none; }
.switch i { width: 26px; height: 15px; border-radius: 999px; background: rgba(11,43,69,.18); position: relative; transition: .25s; flex: none; }
.switch i::after { content: ''; position: absolute; top: 2px; left: 2px; width: 11px; height: 11px; border-radius: 50%; background: #fff; transition: .25s; }
.switch.on { border-color: var(--energy-deep); color: var(--energy-deep); background: #F2FAFB; }
.switch.on i { background: var(--energy); }
.switch.on i::after { left: 13px; }

/* 表格 */
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; font-size: 12px; color: var(--ink-faint); font-weight: 600; padding: 9px 10px; border-bottom: 1.5px solid var(--line-strong); white-space: nowrap; }
.tbl td { padding: 9px 10px; border-bottom: 1px solid var(--line); }
.tbl td:first-child { font-weight: 600; }
.tbl tr:last-child td { border-bottom: none; }
.tbl tr.sum td { font-weight: 700; background: #F4FBFC; }
.tbl tr[data-c]:hover td { background: #F2FAFB; }
.tbl .num { font-family: var(--font-mono); font-weight: 600; text-align: right; }
.tbl th.num { text-align: right; }
.tbl-scroll { overflow-x: auto; }

/* 条形行 */
.bar-row { display: grid; grid-template-columns: 210px 1fr 90px; align-items: center; gap: 12px; padding: 7px 0; font-size: 13px; }
.bar-row .bn { font-weight: 600; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-row .bt { height: 14px; border-radius: 7px; background: rgba(11,43,69,.06); overflow: hidden; }
.bar-row .bf { height: 100%; border-radius: 7px; background: linear-gradient(90deg, var(--energy-deep), var(--energy)); transition: width .5s var(--ease-out); }
.bar-row .bv { font: 600 13px var(--font-mono); text-align: right; }

/* 流程 */
.flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; counter-reset: step; }
.flow .step { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 16px; position: relative; transition: .3s var(--ease-out); }
.flow .step:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: rgba(8,145,178,.4); }
.flow .step::before { counter-increment: step; content: '0' counter(step); font: 700 22px var(--font-mono); color: var(--energy); display: block; margin-bottom: 6px; }
.flow .step .t { font: 11px var(--font-mono); color: var(--energy-deep); letter-spacing: .06em; }
.flow .step b { display: block; font-size: 14.5px; margin: 2px 0 6px; }
.flow .step p { font-size: 12px; color: var(--ink-faint); line-height: 1.6; }

/* 深色叙事卡 */
.dark-card { background: linear-gradient(135deg, #0B2B45 0%, #0E3D60 60%, #0A4A5E 100%); border-radius: var(--radius);
  color: #fff; padding: clamp(24px, 3.4vw, 38px); position: relative; overflow: hidden; }
.dark-card::after { content: ''; position: absolute; right: -80px; top: -80px; width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(0,194,209,.28), transparent 70%); }
.dark-card h3 { font-size: clamp(19px, 2.2vw, 24px); margin-bottom: 10px; }
.dark-card p { color: rgba(255,255,255,.75); font-size: 14px; max-width: 760px; }
.dark-card .tagline { font: 11px var(--font-mono); letter-spacing: .2em; color: #7FE9F2; margin-bottom: 12px; }
.dark-card .verdict { font: 800 clamp(30px, 4vw, 44px) var(--font-mono); margin: 10px 0 4px; position: relative; z-index: 1; }

/* 徽标 */
.tag { display: inline-flex; align-items: center; gap: 6px; font: 10.5px var(--font-mono); letter-spacing: .08em;
  border-radius: 999px; padding: 3px 10px; border: 1px solid var(--line-strong); color: var(--ink-faint); }
.tag i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.tag-real { color: var(--save-deep); border-color: rgba(15,185,129,.4); }
.tag-sim { color: var(--energy-deep); border-color: rgba(8,145,178,.4); }
.tag-demo { color: var(--cost-deep); border-color: rgba(245,158,11,.4); }

footer { margin-top: 80px; padding: 40px clamp(18px, 4vw, 44px) 56px; background: linear-gradient(var(--bg), #EDF4F7); border-top: 1px solid var(--line-strong); }
footer .wrap { display: grid; grid-template-columns: 2fr 1fr; gap: 30px; }
footer p { font-size: 12.5px; color: var(--ink-faint); line-height: 1.8; }
footer .f-t { font: 11px var(--font-mono); letter-spacing: .2em; color: var(--ink-faint); margin-bottom: 10px; }

.reveal { opacity: 0; transform: translateY(30px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }
svg text { font-family: var(--font-sans); }

@media (max-width: 960px) {
  .hero-stats, .grid4 { grid-template-columns: repeat(2, 1fr); }
  .grid2, .grid3 { grid-template-columns: 1fr; }
  .flow { grid-template-columns: repeat(2, 1fr); }
  .nav .links { display: none; }
  .kpi.big { grid-column: span 2; }
  .fin-grid { grid-template-columns: 1fr !important; }
  footer .wrap { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .hero-stats, .grid4 { grid-template-columns: 1fr; }
  .flow { grid-template-columns: 1fr; }
  .kpi.big { grid-column: span 1; }
  .tbl-scroll .tbl { min-width: 660px; }
  .bar-row { grid-template-columns: 130px 1fr 80px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
