/* 页面级组件样式 */
html, body { overflow-x: hidden; }

/* ---------- 数字孪生主界面 ---------- */
.site-wrap { position: relative; }

/* ---------- 数字孪生 · 模拟运行控制台 ---------- */
.sim-console {
  position: fixed; z-index: 70; right: 20px; top: calc(var(--nav-h) + 16px);
  width: 318px; max-width: calc(100vw - 28px);
  max-height: calc(100vh - var(--nav-h) - 32px);
  display: flex; flex-direction: column;
  background: rgba(255,255,255,0.94); backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  box-shadow: var(--shadow-lift); overflow: hidden;
}
.sim-console .sc-body { overflow-y: auto; }
.sim-console.shifted { right: 352px; }
.sc-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 14px; border-bottom: 1px solid var(--line);
  background: linear-gradient(135deg, #0B2B45, #0E3D60);
}
.sc-head b { color: #fff; font-size: 13.5px; display: flex; align-items: center; gap: 7px; }
.sc-head b::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--energy); box-shadow: 0 0 10px var(--energy); animation: breathe 2.2s infinite; }
.sc-tools { display: flex; gap: 6px; }
.sc-tools button {
  border: 1px solid rgba(255,255,255,0.25); background: rgba(255,255,255,0.1); color: #fff;
  border-radius: 999px; padding: 4px 12px; font-size: 12px; font-weight: 600; cursor: pointer;
  transition: all .2s;
}
.sc-tools button:hover { background: var(--energy); border-color: var(--energy); }
.sc-tools button.on { background: var(--energy); border-color: var(--energy); }
.sc-speed { display: flex; gap: 2px; background: rgba(255,255,255,0.14); border-radius: 999px; padding: 2px; }
.sc-speed button {
  border: 0; background: transparent; color: rgba(255,255,255,0.8);
  border-radius: 999px; padding: 2px 8px; font-size: 11px; font-weight: 700; cursor: pointer;
  font-family: var(--font-mono);
}
.sc-speed button:hover { color: #fff; }
.sc-speed button.on { background: var(--energy); color: #04263A; }
.sc-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 10px; }
.sc-body.collapsed { display: none; }
.sc-verdict { display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px; }
.sc-vitem {
  background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px;
  border-left: 3px solid var(--energy); min-width: 0;
}
.sc-vitem:nth-child(2) { border-left-color: #7C6FDE; }
.sc-vitem:nth-child(3) { border-left-color: #F59E0B; }
.sc-vitem:nth-child(4) { border-left-color: #0EA5A4; }
.sc-vitem .k { font-size: 10px; color: var(--ink-faint); font-family: var(--font-mono); letter-spacing: .03em; }
.sc-vitem .v {
  font-family: var(--font-mono); font-size: 13px; font-weight: 800; color: var(--ink);
  margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sc-vitem .v .u { font-size: 9.5px; color: var(--energy-deep); font-weight: 600; margin-left: 2px; }
.sc-vitem .v small { font-size: 9.5px; color: var(--ink-faint); font-weight: 500; margin-left: 2px; }
.sc-vitem.pass .v { color: var(--save-deep); }
.sc-tariff-strip {
  position: relative; height: 24px; border-radius: 8px; overflow: hidden;
  border: 1px solid var(--line); display: flex; margin-top: 2px; background: #fff;
}
.sc-tariff-strip .seg { flex: 1 1 0; min-width: 0; }
.sc-tariff-strip .playhead {
  position: absolute; top: -2px; bottom: -2px; width: 2px; background: #0B2B45;
  box-shadow: 0 0 0 1.5px #fff, 0 0 6px rgba(11,43,69,0.5); transition: left .12s linear;
  pointer-events: none;
}
.sc-tariff-strip .tag {
  position: absolute; top: 50%; transform: translate(-50%, -50%); font-size: 9px;
  color: #fff; font-weight: 700; letter-spacing: .03em; pointer-events: none;
  font-family: var(--font-mono); text-shadow: 0 1px 2px rgba(0,0,0,0.45);
  white-space: nowrap; background: rgba(11,43,69,0.55); border-radius: 999px; padding: 0 5px;
}
.sc-date-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.sc-date { font-family: var(--font-mono); font-size: 15px; font-weight: 800; color: var(--ink); }
.sc-time { font-family: var(--font-mono); font-size: 12.5px; color: var(--energy-deep); }
.sc-slider input[type=range] {
  width: 100%; height: 4px; -webkit-appearance: none; appearance: none;
  background: linear-gradient(90deg, var(--energy) 55%, rgba(11,43,69,0.12) 55%);
  border-radius: 4px; outline: none; cursor: pointer; margin: 6px 0 2px;
}
.sc-slider input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 15px; height: 15px; border-radius: 50%;
  background: #fff; border: 3px solid var(--energy); box-shadow: 0 0 0 4px var(--energy-glow);
}
.sc-scale { display: flex; justify-content: space-between; font-size: 10px; color: var(--ink-faint); font-family: var(--font-mono); }
.sc-chips { display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px; }
.sc-chip {
  background: #F4FBFC; border: 1px solid var(--line); border-radius: 10px; padding: 7px 10px;
  min-width: 0;
}
.sc-chip .k { font-size: 10.5px; color: var(--ink-faint); font-family: var(--font-mono); letter-spacing: .03em; }
.sc-chip .v { font-family: var(--font-mono); font-size: 15.5px; font-weight: 800; color: var(--ink); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-chip .v .u { font-size: 10px; color: var(--energy-deep); font-weight: 600; margin-left: 2px; }
.sc-chip .v.save { color: var(--save-deep); }
.sc-chip .v.cost { color: var(--cost-deep); }
.sc-chip.valley-on { background: linear-gradient(135deg, #FDF3E3, #FBF6EC); border-color: rgba(245,158,11,0.45); }
.sc-chip.valley-on .v { color: #b45309; }
.sc-soc { height: 5px; border-radius: 999px; background: rgba(11,43,69,0.1); margin-top: 5px; overflow: hidden; }
.sc-soc i {
  display: block; height: 100%; width: 60%; border-radius: 999px;
  background: linear-gradient(90deg, #00C2D1, #0EA5A4); transition: width .3s ease;
}
.sc-chip.valley-on .sc-soc i { background: linear-gradient(90deg, #F59E0B, #EA7A1F); }
.sc-chart { border: 1px solid var(--line); border-radius: 10px; padding: 6px; background: #fff; }
.sc-chart .chart-box { width: 100%; }
.sc-chart canvas { width: 100%; display: block; border-radius: 6px; }
.sc-legend { display: flex; gap: 12px; font-size: 10.5px; color: var(--ink-faint); padding: 6px 2px 0; }
.sc-legend i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.sc-note { font-size: 10.5px; color: var(--ink-faint); line-height: 1.6; }
.sc-note b { color: var(--energy-deep); font-weight: 600; }

@media (max-width: 1080px) {
  .sim-console { width: 300px; }
  .sim-console.shifted { right: 10px; }
}
@media (max-width: 720px) {
  .sim-console {
    right: 10px; left: 10px; width: auto; top: auto; bottom: 62px;
    max-height: 46vh; overflow-y: auto;
  }
  .sim-console.mini { bottom: 12px; width: auto; left: 10px; right: 10px; }
  .sim-console.mini .sc-body { display: none; }
}

.site-tools {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-bottom: 12px;
}
.site-tools .legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--ink-soft); }
.legend i { display: inline-block; width: 11px; height: 11px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.site-card { padding: 14px; }
.bld.sel rect:first-of-type { stroke-width: 5px; }
.bld.sel { filter: drop-shadow(0 0 10px rgba(0,194,209,0.65)); }
.bld:hover { filter: drop-shadow(0 0 8px rgba(0,194,209,0.5)); }
.bld.zone-off { opacity: 0.22; }
.station.zone-sel circle { r: 11; }
.station.zone-sel rect:first-of-type { stroke-width: 4.5; stroke: #0B2B45; }

/* 楼栋信息 */
.bld-panel .bp-head { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.bp-num {
  width: 46px; height: 46px; border-radius: 14px; flex: none;
  background: linear-gradient(135deg, var(--ink), var(--energy-deep));
  color: #fff; font-family: var(--font-mono); font-weight: 800; font-size: 20px;
  display: flex; align-items: center; justify-content: center;
}
.floor-grid { margin-top: 12px; display: flex; flex-direction: column; gap: 6px; max-height: 400px; overflow: auto; padding-right: 4px; }
.floor-row { display: flex; align-items: center; gap: 8px; }
.floor-label {
  width: 42px; flex: none; text-align: center;
  font-family: var(--font-mono); font-size: 12px; font-weight: 700; color: var(--ink-soft);
  background: #F2FAFB; border-radius: 8px; padding: 6px 0;
}
.floor-units { display: flex; gap: 6px; flex-wrap: wrap; }
.unit-btn {
  width: 40px; height: 34px; border-radius: 9px; border: 1px solid var(--line-strong);
  background: var(--bg-pure); color: var(--ink-soft); font-family: var(--font-mono);
  font-size: 12.5px; font-weight: 600; cursor: pointer; transition: all 0.25s var(--ease-out);
}
.unit-btn:hover { border-color: var(--energy); color: var(--energy-deep); background: var(--energy-glow); transform: translateY(-2px); }

/* 模拟时钟控制条 */
.sim-bar {
  position: sticky; bottom: 14px; z-index: 60;
  background: rgba(255,255,255,0.88); backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  box-shadow: var(--shadow-lift); padding: 14px 18px;
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
}
.sim-clock { display: flex; align-items: baseline; gap: 10px; }
.sim-clock .date { font-family: var(--font-mono); font-size: 18px; font-weight: 800; color: var(--ink); }
.sim-clock .time { font-family: var(--font-mono); font-size: 13px; color: var(--energy-deep); }
.sim-clock .day { font-size: 11.5px; color: var(--ink-faint); font-family: var(--font-mono); }
.sim-live { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.live-chip {
  font-family: var(--font-mono); font-size: 12px; color: var(--ink-soft);
  background: #F2FAFB; border-radius: 999px; padding: 6px 12px;
}
.live-chip b { color: var(--ink); }
.live-chip .u { color: var(--energy-deep); font-size: 10px; }

/* 户级模态 */
.hh-overlay {
  position: fixed; inset: 0; z-index: 200; background: rgba(11,43,69,0.45);
  display: flex; align-items: center; justify-content: center; padding: 24px;
  backdrop-filter: blur(4px);
}
.hh-modal {
  background: var(--bg); border-radius: 20px; width: min(1080px, 96vw);
  max-height: 92vh; overflow: auto; box-shadow: var(--shadow-lift);
  border: 1px solid var(--line-strong);
}
.hh-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 26px; border-bottom: 1px solid var(--line);
  background: var(--bg-pure); border-radius: 20px 20px 0 0;
}
.hh-title { font-size: 20px; font-weight: 800; color: var(--ink); }
.hh-sub { font-size: 12.5px; color: var(--ink-faint); margin-top: 2px; }
.hh-close {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-strong);
  background: var(--bg-pure); font-size: 20px; color: var(--ink-soft); cursor: pointer;
  transition: all 0.25s;
}
.hh-close:hover { color: var(--danger); border-color: var(--danger); transform: rotate(90deg); }
.hh-body { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(300px, 1fr); gap: 20px; padding: 22px 26px; }
.hh-plan { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 16px; }
.plan-img { position: relative; border: 1px solid var(--line-strong); border-radius: 12px; overflow: hidden; background: #fff; }
.plan-img img { display: block; width: 100%; height: auto; }
.plan-img-tag {
  position: absolute; left: 0; top: 0; background: rgba(11,43,69,0.82); color: #7fe9f2;
  font-size: 12.5px; font-weight: 700; padding: 6px 14px; border-radius: 0 0 12px 0;
  letter-spacing: 0.5px;
}
.plan-rooms {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; margin-top: 12px;
}
.plan-rooms-t {
  grid-column: 1 / -1; font-size: 12px; font-weight: 700; color: var(--ink-soft);
  margin-bottom: 2px;
}
.p-room {
  display: flex; align-items: center; gap: 6px; border: 1px solid rgba(11,43,69,0.16);
  border-radius: 8px; padding: 7px 9px; background: #FDFEFE; font-size: 12px;
}
.p-room-ic { font-size: 15px; }
.p-room-nm { flex: 1; font-weight: 600; color: var(--ink); }
.p-room-ar { color: var(--ink-faint); font-family: var(--font-mono); font-size: 11px; }
.p-room-tp { font-family: var(--font-mono); font-weight: 800; color: var(--energy-deep); }
.p-room-ht { color: var(--cost); font-size: 11px; animation: breathe 2.2s infinite; }
.unit-plan { display: grid; gap: 8px; }
.room {
  border: 1.5px solid rgba(11,43,69,0.20); border-radius: 10px;
  padding: 10px 8px; text-align: center; position: relative; background: #FDFEFE;
  min-height: 96px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
}
.room-icon { font-size: 22px; }
.room-name { font-size: 13px; font-weight: 700; color: var(--ink); }
.room-area { font-size: 11px; color: var(--ink-faint); font-family: var(--font-mono); }
.room-temp { font-size: 15px; font-weight: 800; font-family: var(--font-mono); color: var(--energy-deep); }
.room-heat {
  position: absolute; right: 6px; bottom: 4px; font-size: 11px; color: var(--cost);
  animation: breathe 2.2s infinite;
}
.hh-info { display: flex; flex-direction: column; gap: 14px; }
.hh-ctl {
  background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  padding: 14px;
}
.hh-ctl-lbl { display: flex; justify-content: space-between; align-items: baseline; font-size: 13.5px; color: var(--ink-soft); margin-bottom: 8px; }
.hh-ctl-lbl b { font-family: var(--font-mono); font-size: 20px; color: var(--energy-deep); }
.hh-ctl input[type=range] {
  width: 100%; -webkit-appearance: none; height: 5px; border-radius: 4px;
  background: linear-gradient(90deg, var(--energy) 40%, rgba(11,43,69,0.12) 40%); outline: none;
}
.hh-ctl input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%;
  background: #fff; border: 4px solid var(--energy); box-shadow: 0 0 0 5px var(--energy-glow);
}
.hh-ctl-note { font-size: 11.5px; color: var(--ink-faint); margin-top: 8px; }
.hh-meter { display: flex; flex-direction: column; gap: 8px; }
.hh-meter-row {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 13px; color: var(--ink-soft); padding: 9px 14px;
  background: var(--bg-pure); border: 1px solid var(--line); border-radius: var(--radius-sm);
}
.hh-meter-row b { font-family: var(--font-mono); color: var(--ink); }
.hh-meter-row b.save { color: var(--save-deep); }

/* ---------- 户级 3D 户型 ---------- */
.hh-modal-3d { width: min(1320px, 97vw); }
.hh-stage { min-width: 0; }
.hh-tabs { display: flex; gap: 6px; margin-bottom: 10px; }
.hh-tab {
  border: 1px solid var(--line-strong); background: var(--bg-pure); color: var(--ink-soft);
  border-radius: 999px; padding: 7px 16px; font-size: 13px; font-weight: 700; cursor: pointer;
  transition: all 0.2s;
}
.hh-tab.active { background: var(--energy); border-color: var(--energy); color: #fff; }
.hh-tab:hover:not(.active) { border-color: var(--energy); color: var(--energy-deep); }
.hh-3d { position: relative; height: 640px; background: #eef3f6; border: 1px solid var(--line-strong); border-radius: var(--radius); overflow: hidden; }
#hh-canvas { position: absolute; inset: 0; }
.hh-3d-tools { position: absolute; top: 12px; left: 12px; z-index: 5; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.hh-floor {
  display: flex; align-items: center; gap: 2px; background: rgba(255,255,255,0.94);
  border: 1px solid var(--line-strong); border-radius: 999px; padding: 3px 4px;
  box-shadow: 0 4px 14px rgba(11,43,69,.10);
}
.hh-floor button {
  width: 28px; height: 28px; border: 0; background: transparent; border-radius: 50%;
  font-size: 13px; color: var(--ink-soft); cursor: pointer; transition: all 0.2s;
}
.hh-floor button:hover { background: #eaf4f6; color: var(--energy-deep); }
.hh-floor b { font-family: var(--font-mono); font-size: 13px; color: var(--ink); min-width: 38px; text-align: center; }
.hh-3d-btn {
  border: 1px solid var(--line-strong); background: rgba(255,255,255,0.94); color: var(--ink-soft);
  border-radius: 999px; padding: 6px 13px; font-size: 12px; font-weight: 700; cursor: pointer;
  box-shadow: 0 4px 14px rgba(11,43,69,.10); transition: all 0.2s;
}
.hh-3d-btn:hover { border-color: var(--energy); color: var(--energy-deep); }
.hh-3d-btn.on { background: var(--ink); color: #7fe9f2; border-color: var(--ink); }
.hh-3d-legend {
  position: absolute; bottom: 12px; left: 12px; z-index: 5; display: flex; gap: 14px;
  background: rgba(255,255,255,0.94); border: 1px solid var(--line-strong); border-radius: 10px;
  padding: 7px 14px; font-size: 12px; color: var(--ink-soft); box-shadow: 0 4px 14px rgba(11,43,69,.10);
}
.hh-3d-legend span { display: inline-flex; align-items: center; gap: 6px; }
.hh-3d-legend i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.hh-3d-legend em { font-style: normal; font-family: var(--font-mono); font-weight: 800; color: var(--energy-deep); }
.hh-3d-legend .flow-ic { width: 18px; height: 8px; border-radius: 2px; background: linear-gradient(90deg, #ff5f3a, #ffb46b, #2f7cf6); position: relative; overflow: hidden; }
.hh-3d-legend .flow-ic::after {
  content: ""; position: absolute; left: -8px; top: 0; bottom: 0; width: 8px;
  background: rgba(255,255,255,0.85); animation: flowrun 1.1s linear infinite;
}
@keyframes flowrun { to { left: 100%; } }
.hh-3d-copy { position: absolute; right: 12px; bottom: 12px; z-index: 5; font-size: 11px; color: var(--ink-faint); background: rgba(255,255,255,0.85); border-radius: 8px; padding: 5px 10px; }
.h3-room-lbl {
  display: flex; flex-direction: column; align-items: center; gap: 1px; white-space: nowrap;
  background: rgba(255,255,255,0.96); border: 1px solid rgba(11,43,69,0.22); border-radius: 9px;
  padding: 4px 9px; box-shadow: 0 3px 10px rgba(11,43,69,.14); pointer-events: none;
}
.h3-room-lbl b { font-size: 11px; color: var(--ink-soft); font-weight: 700; }
.h3-room-lbl span { font-family: var(--font-mono); font-size: 13.5px; font-weight: 800; color: var(--energy-deep); }
.h3-man-lbl {
  display: flex; flex-direction: column; gap: 1px; white-space: nowrap; text-align: left;
  background: rgba(11,43,69,0.92); border: 1px solid rgba(11,43,69,0.6); border-radius: 10px;
  padding: 6px 11px; box-shadow: 0 4px 14px rgba(11,43,69,.3); pointer-events: none;
}
.h3-man-lbl b { font-size: 11.5px; color: #7fe9f2; font-weight: 800; letter-spacing: 0.5px; }
.h3-man-lbl span { font-family: var(--font-mono); font-size: 12.5px; font-weight: 700; }
.h3-man-lbl .hot { color: #ff9a72; }
.h3-man-lbl .cool { color: #8ab8ff; }
.hh-water { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 13px 14px; }
.hh-sec-t { font-size: 12.5px; font-weight: 800; color: var(--ink); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.hh-sec-t::before { content: ""; width: 4px; height: 13px; border-radius: 2px; background: var(--energy); }
.hh-water-row {
  display: flex; justify-content: space-between; align-items: center; font-size: 12.5px;
  color: var(--ink-soft); padding: 7px 0; border-bottom: 1px dashed var(--line);
}
.hh-water-row:last-of-type { border-bottom: 0; }
.hh-water-row b { font-family: var(--font-mono); font-size: 14px; color: var(--ink); }
.hh-water-row b .u { font-size: 10px; color: var(--ink-faint); font-family: var(--font-sans); margin-left: 2px; }
.hh-water-row b.hot { color: #e2552e; }
.hh-water-row b.cool { color: #2f6fc9; }
.hh-water-note { font-size: 11px; color: var(--ink-faint); margin-top: 8px; line-height: 1.6; }
.hh-rooms { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 13px 14px; }
.h3-room-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.h3-room {
  display: flex; justify-content: space-between; align-items: center; font-size: 12px;
  border: 1px solid rgba(11,43,69,0.14); border-radius: 8px; padding: 6px 9px; background: #FDFEFE;
}
.h3-room span { color: var(--ink-soft); }
.h3-room b { font-family: var(--font-mono); font-weight: 800; color: var(--energy-deep); }
.hh-modal-3d .hh-body { grid-template-columns: minmax(0, 1.55fr) minmax(330px, 1fr); }
.hh-modal-3d .hh-info { max-height: 640px; overflow: auto; padding-right: 2px; }
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.metric-cell {
  background: var(--bg-pure); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 9px 12px;
}
.metric-cell .label { font-size: 11px; color: var(--ink-faint); }
.metric-cell .num { font-family: var(--font-mono); font-size: 19px; font-weight: 800; color: var(--ink); }
.metric-cell .num .u { font-size: 10px; color: var(--ink-faint); font-family: var(--font-sans); margin-left: 2px; }
.metric-cell .num.save { color: var(--save-deep); }
.hh-plan-svg { background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: 12px; padding: 14px; }
.hh-plan-svg-t {
  display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
  font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 10px;
}
.hh-plan-svg-live {
  font-size: 11px; font-weight: 600; color: var(--energy-deep);
  background: #eaf9fb; border: 1px solid rgba(0,194,209,0.35); border-radius: 999px;
  padding: 2px 9px; font-family: var(--font-mono);
}
.hh-plan-svg svg { display: block; border-radius: 10px; width: 100%; height: auto; aspect-ratio: 560 / 430; }

/* ---------- 3D 数字孪生 · 楼栋面板 ---------- */
.t3d-panel {
  position: fixed; z-index: 60; top: calc(var(--nav-h) + 16px); right: 16px;
  width: 316px; max-height: calc(100vh - var(--nav-h) - 120px); overflow: auto;
  background: var(--bg-pure); border: 1px solid var(--line-strong); border-radius: 14px;
  box-shadow: var(--shadow-lift); padding: 16px;
  opacity: 0; transform: translateX(20px) translateY(-8px) scale(.98);
  visibility: hidden; pointer-events: none;
  transition: opacity .32s cubic-bezier(.22,.61,.36,1), transform .32s cubic-bezier(.22,.61,.36,1), visibility 0s linear .32s;
}
.t3d-panel.open {
  opacity: 1; transform: none; visibility: visible; pointer-events: auto;
  transition: opacity .32s cubic-bezier(.22,.61,.36,1), transform .32s cubic-bezier(.22,.61,.36,1);
}
.t3d-panel-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
#panel-title { font-size: 17px; font-weight: 800; color: var(--ink); }
#panel-sub { font-size: 12px; color: var(--ink-soft); margin-top: 3px; line-height: 1.5; }
#panel-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 12px 0; }
.t3d-stat { background: #f6fafb; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.t3d-stat .k { font-size: 11px; color: var(--ink-faint); }
.t3d-stat .v { font-family: var(--font-mono); font-size: 16px; font-weight: 800; color: var(--ink); }
.t3d-stat .v span { font-size: 10px; color: var(--ink-faint); margin-left: 2px; font-family: var(--font-sans); }
#panel-floors { border-top: 1px dashed var(--line-strong); padding-top: 12px; }
.t3d-floor { display: flex; align-items: center; gap: 4px; margin-bottom: 4px; }
.t3d-floor > span { width: 24px; font-size: 11px; color: var(--ink-faint); font-family: var(--font-mono); flex: none; }
.t3d-unit {
  flex: 1; border: 1px solid var(--line); background: #fbfdfe; border-radius: 7px;
  font-size: 11.5px; padding: 5px 2px; cursor: pointer; color: var(--ink-soft);
  font-family: var(--font-mono); transition: all .15s; white-space: nowrap; overflow: hidden;
}
.t3d-unit:hover { border-color: var(--energy); color: var(--energy-deep); background: #f2fbfc; }
.t3d-unit b { display: block; font-size: 11.5px; color: var(--ink); font-weight: 700; }
.t3d-unit small { display: block; font-size: 10px; color: var(--ink-faint); }
.t3d-unit.type-100 b { color: #0b8a63; }
.t3d-unit.type-110 b { color: #0b7f8f; }
.t3d-unit.type-130 b { color: #7c4a9e; }
.t3d-sec-t { font-size: 12px; font-weight: 800; color: var(--ink); margin: 12px 0 6px; display: flex; align-items: center; gap: 6px; }
.t3d-sec-t::before { content: ""; width: 4px; height: 12px; border-radius: 2px; background: var(--energy); }
.t3d-bld-list { display: flex; gap: 6px; flex-wrap: wrap; }
.t3d-bld-list {
  position: fixed; z-index: 55; top: calc(var(--nav-h) + 58px); left: 20px;
  width: 360px; max-width: calc(100vw - 24px); background: var(--bg-pure);
  border: 1px solid var(--line-strong); border-radius: 14px; box-shadow: var(--shadow-lift);
  padding: 12px; display: none;
}
.t3d-bld-list.open { display: flex; }
.t3d-bld-list-t { width: 100%; font-size: 12px; font-weight: 800; color: var(--ink); margin-bottom: 8px; }
.t3d-bld-list-t small { font-weight: 400; color: var(--ink-faint); margin-left: 6px; }
.t3d-bld {
  border: 1px solid var(--line-strong); background: #fff; border-radius: 999px;
  padding: 5px 12px; font-size: 12px; color: var(--ink-soft); cursor: pointer;
}
.t3d-bld:hover { border-color: var(--energy); color: var(--energy-deep); }
.t3d-tools {
  position: fixed; z-index: 55; top: calc(var(--nav-h) + 16px); left: 20px;
  display: flex; gap: 8px; flex-wrap: wrap;
}
.t3d-tools .tool-btn {
  display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-strong);
  background: var(--bg-pure); border-radius: 10px; padding: 7px 12px; font-size: 12.5px;
  font-weight: 600; color: var(--ink-soft); cursor: pointer; box-shadow: var(--shadow-card);
}
.t3d-tools .tool-btn.active { background: var(--ink); color: #7fe9f2; border-color: var(--ink); }
.t3d-tools .tool-btn:hover:not(.active) { border-color: var(--energy); color: var(--energy-deep); }
.t3d-tools .tool-btn .dot { width: 8px; height: 8px; border-radius: 50%; background: #0fb981; box-shadow: 0 0 6px rgba(15,185,129,.8); }
.t3d-tools .tool-btn .dot.off { background: #cbd5dd; box-shadow: none; }
@media (max-width: 720px) {
  .t3d-panel { top: calc(var(--nav-h) + 8px); right: 8px; left: 8px; width: auto; max-height: 46vh; }
  .t3d-tools { left: 10px; top: calc(var(--nav-h) + 8px); }
  .t3d-bld-list { left: 10px; top: calc(var(--nav-h) + 56px); width: calc(100vw - 20px); }
  .hh-modal-3d .hh-body { grid-template-columns: 1fr; }
}

/* ---------- 页面级公共样式（全局统一，内容页不再内联重复） ---------- */
.page { max-width: 1400px; margin: 0 auto; padding: 26px 28px 70px; }
.page-desc { color: var(--ink-soft); font-size: 14px; max-width: 980px; line-height: 1.8; margin-bottom: 16px; }
.card {
  background: #fff; border: 1px solid var(--line-strong); border-radius: var(--radius);
  padding: 20px 22px; box-shadow: var(--shadow-card);
}
.head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.head h3 { font-size: 16px; font-weight: 800; display: flex; align-items: center; gap: 8px; }
.head h3::before { content: ""; width: 4px; height: 15px; border-radius: 2px; background: linear-gradient(180deg, var(--energy), var(--energy-deep)); flex: none; }
.tag { display: inline-block; background: var(--energy-glow); color: var(--energy-deep); border-radius: 999px; padding: 3px 12px; font-size: 11.5px; font-weight: 600; }
.tag.warn { background: rgba(245,158,11,0.14); color: var(--cost-deep); }
.tag.save { background: rgba(15,185,129,0.14); color: var(--save-deep); }
.tbl-wrap { overflow: auto; border: 1px solid var(--line-strong); border-radius: 14px; background: #fff; box-shadow: var(--shadow-card); }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { color: var(--ink-soft); font-weight: 700; font-size: 12px; background: #F4FAFB; letter-spacing: 0.02em; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: #F4FBFC; }
td.num, th.num { text-align: right; font-family: var(--font-mono); }
tr.total td { background: #EDF8FA; font-weight: 700; }
.section { margin-top: 24px; }
.split { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(320px, 1fr); gap: 18px; align-items: start; margin-top: 18px; }
.stack { display: flex; flex-direction: column; gap: 18px; }
.concl { background: #f2fbfc; border: 1px solid rgba(0,194,209,0.28); border-radius: 10px; padding: 10px 14px; font-size: 12.5px; color: var(--ink-soft); line-height: 1.7; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.concl b { color: var(--energy-deep); font-family: var(--font-mono); }
.concl.save { border-color: rgba(11,185,129,0.5); background: #f0fbf6; }
.concl.warn { border-color: rgba(245,158,11,0.55); background: #fffaf0; }
.ctl-row { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.ctl { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #fbfdfe; }
.ctl .lbl { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.ctl .lbl span { font-size: 12.5px; color: var(--ink-soft); font-weight: 500; }
.ctl .lbl b { font-family: var(--font-mono); font-size: 14px; color: var(--energy-deep); }
.ctl input[type=range] { width: 100%; accent-color: var(--energy-deep); }
.ctl .range-note { font-size: 10.5px; color: var(--ink-faint); font-family: var(--font-mono); margin-top: 4px; line-height: 1.5; }
.invest-kpis { display: grid; gap: 12px; margin: 18px 0 8px; }
.invest-kpis .card { padding: 14px 16px; position: relative; overflow: hidden; }
.invest-kpis .card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--energy); }
.invest-kpis .card.cost::before { background: var(--cost); }
.invest-kpis .card.save::before { background: var(--save); }
.ik-label { font-size: 11.5px; color: var(--ink-faint); font-family: var(--font-mono); letter-spacing: 0.05em; }
.ik-value { font-family: var(--font-mono); font-size: clamp(19px, 2vw, 26px); font-weight: 800; color: var(--ink); margin: 2px 0; }
.ik-value .u { font-size: 11px; color: var(--energy-deep); }
.ik-value.cost { color: var(--cost-deep); }
.ik-value.save { color: var(--save-deep); }
.ik-note { font-size: 11px; color: var(--ink-faint); line-height: 1.5; }
.be-row { display: flex; gap: 16px; flex-wrap: wrap; align-items: stretch; }
.be-cell { flex: 1; min-width: 150px; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #fbfdfe; }
.be-cell .k { font-size: 11px; color: var(--ink-faint); }
.be-cell b { font-family: var(--font-mono); font-size: 20px; font-weight: 800; color: var(--ink); }
.be-cell .u { font-size: 11px; color: var(--ink-faint); }
.be-cell.ok { border-color: rgba(11,185,129,0.5); background: #f0fbf6; }
.be-cell.ok b { color: var(--save-deep); }
.be-cell.warn { border-color: rgba(245,158,11,0.5); background: #fffaf0; }
.be-cell.warn b { color: var(--cost-deep); }
.chart-box { position: relative; width: 100%; }
.chart-box canvas { width: 100%; display: block; border-radius: 10px; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 12px; margin: 8px 0 2px; font-size: 12px; color: var(--ink-soft); }
.chart-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; }
.dark-card p { font-size: 13px; color: rgba(255,255,255,0.85); line-height: 1.9; }
.dark-card b { color: #39E6F5; font-family: var(--font-mono); }
@media (max-width: 1000px) { .invest-kpis { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .invest-kpis { grid-template-columns: repeat(2, 1fr); } }

/* ---------- 能源站 ---------- */
.st-kpis { grid-template-columns: repeat(6, 1fr); }
.st-zone-badge {
  display: inline-block; font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  padding: 2px 9px; border-radius: 999px; margin-right: 6px;
}
.st-zone-badge.west { background: #e6f2fd; color: #1d5f9e; border: 1px solid #b8d6f0; }
.st-zone-badge.east { background: #e9f8ef; color: #0b7a45; border: 1px solid #b8e6c8; }
.st-zone-badge.north { background: #f3edfb; color: #6d3fb0; border: 1px solid #d5c6ef; }
.st-flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.st-flow .fnode {
  position: relative; border-radius: 14px; padding: 16px 14px 14px; text-align: center; color: #fff;
  min-height: 118px; display: flex; flex-direction: column; justify-content: center; gap: 5px;
}
.st-flow .fnode .no {
  position: absolute; top: -9px; left: 50%; transform: translateX(-50%);
  width: 22px; height: 22px; border-radius: 50%; background: #fff; color: var(--ink);
  font-family: var(--font-mono); font-size: 12px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 6px rgba(11,43,69,0.25);
}
.st-flow .fnode .t { font-size: 14px; font-weight: 800; line-height: 1.45; }
.st-flow .fnode .d { font-size: 11.5px; opacity: 0.88; line-height: 1.5; }
.st-flow .farr { display: flex; align-items: center; justify-content: center; color: var(--ink-faint); font-size: 20px; font-weight: 800; }
.st-table-wrap { max-height: 560px; overflow: auto; }
.st-table-wrap table { min-width: 820px; }
.st-table-wrap tbody tr { transition: background .18s; }
.st-table-wrap tbody tr:hover { background: #f0fbfc; }
.st-table-wrap td { font-size: 12.5px; }
.st-table-wrap td b { font-size: 13px; }
.st-table-wrap th { position: sticky; top: 0; z-index: 2; }
.st-note-card {
  background: linear-gradient(135deg, #0B2B45, #0E3D60); color: rgba(255,255,255,0.85);
  border-radius: 16px; padding: 20px 24px; font-size: 13px; line-height: 1.9;
}
.st-note-card b { color: #39E6F5; font-family: var(--font-mono); }
.st-note-card .k { font-family: var(--font-mono); color: #7FE9F2; font-size: 11px; letter-spacing: 0.16em; margin-bottom: 8px; }
@media (max-width: 1000px) { .st-kpis { grid-template-columns: repeat(3, 1fr); } .st-flow { grid-template-columns: 1fr; } .st-flow .farr { transform: rotate(90deg); } }
@media (max-width: 640px) { .st-kpis { grid-template-columns: repeat(2, 1fr); } }

/* ---------- 欧适能知识库依据 ---------- */
.kb-loading { font-size: 12.5px; color: var(--ink-faint); padding: 10px 0; }
.kb-item { border: 1px solid var(--line-strong); border-radius: 10px; padding: 12px 14px; margin-bottom: 12px; background: var(--bg-pure); }
.kb-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.kb-name { font-size: 13.5px; font-weight: 800; color: var(--ink); }
.kb-q { font-size: 11.5px; color: var(--energy-deep); font-family: var(--font-mono); }
.kb-rec { border-left: 3px solid var(--energy); background: #f2fbfc; border-radius: 0 8px 8px 0; padding: 8px 12px; margin-bottom: 8px; }
.kb-txt { font-size: 12.5px; line-height: 1.65; color: var(--ink-soft); }
.kb-meta { display: flex; justify-content: space-between; gap: 10px; margin-top: 6px; font-size: 11px; color: var(--ink-faint); font-family: var(--font-mono); }
.kb-err { font-size: 12.5px; color: #c2410c; }
.kb-none { font-size: 12.5px; color: var(--ink-faint); }

@media (max-width: 1080px) {
  .hh-body { grid-template-columns: 1fr; }
}
