:root {
  --ink: #193c35;
  --muted: #6f8076;
  --green: #176c55;
  --green-dark: #12513f;
  --mint: #e9f4ed;
  --line: #e7ede9;
  --paper: #ffffff;
  --canvas: #f5f7f5;
  --orange: #c97d30;
  --radius: 18px;
  font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", system-ui, sans-serif;
  color: var(--ink);
  background: var(--canvas);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
body { margin: 0; font-size: 14px; line-height: 1.6; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button, select { cursor: pointer; }
button { color: inherit; }
button:disabled { cursor: not-allowed; opacity: .55; }
button, input, select, textarea { max-width: 100%; }
a { color: inherit; text-decoration: none; }
svg { flex-shrink: 0; vertical-align: middle; }
.icon { width: 18px; height: 18px; }
img, svg { max-width: 100%; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.4; }
strong { font-weight: 650; }
:focus-visible { outline: 3px solid #91c2a6; outline-offset: 4px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; z-index: 100; top: 12px; left: 12px; padding: 10px 18px; border-radius: 10px; background: var(--green); color: white; transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }

.shell { display: grid; grid-template-columns: 218px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; display: flex; flex-direction: column; height: 100vh; padding: 32px 18px 20px; background: var(--paper); border-right: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 9px; }
.brand-mark { display: grid; place-items: center; flex-shrink: 0; width: 43px; height: 43px; border-radius: 13px; color: #cee9ba; background: var(--green); }
.brand-mark svg { width: 31px; height: 31px; }
.brand strong { display: block; font-size: 24px; letter-spacing: 1px; }
.brand small { display: block; margin-top: 1px; font-size: 11px; color: var(--muted); letter-spacing: 1px; }
.nav-label { padding: 0 15px; margin: 42px 0 13px; color: #a0aaa5; font-size: 12px; letter-spacing: 2px; }
#navigation { display: flex; flex-direction: column; gap: 7px; }
.nav-item { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 10px 15px; border: 0; border-radius: 11px; color: #667d74; background: transparent; text-align: left; font-size: 13px; transition: background .18s ease, color .18s ease; }
.nav-item svg { width: 19px; height: 19px; }
.nav-item:hover { color: var(--green); background: #f3f7f3; }
.nav-item.active, .nav-item[aria-current="page"] { color: var(--green); background: #eaf3ed; font-weight: 650; }
.nav-item.active::after, .nav-item[aria-current="page"]::after { content: ""; position: absolute; right: 13px; width: 5px; height: 5px; border-radius: 50%; background: var(--green); }
.nav-dot { width: 5px; height: 5px; margin-left: auto; border-radius: 50%; background: #d8ac70; }
.nav-item.active .nav-dot { display: none; }
.sidebar-note { margin: 35px 9px 18px; padding: 18px 14px; border: 1px solid #edf1e9; border-radius: 14px; background: linear-gradient(145deg, #f3f7e9, #f8faf4); }
.tiny-label { display: block; color: #8b9a75; font-size: 11px; letter-spacing: 2px; }
.sidebar-note strong { display: block; margin-top: 8px; color: #506541; font-size: 18px; line-height: 1.7; letter-spacing: 1px; }
.sidebar-line { width: 26px; height: 2px; margin: 14px 0 10px; background: #b7c993; }
.sidebar-note p { color: #93a185; font-size: 11px; white-space: nowrap; }
.sidebar-bottom { margin-top: auto; }
.team { display: flex; align-items: center; gap: 10px; margin: 17px 9px 0; padding-top: 18px; border-top: 1px solid var(--line); }
.team-avatar { display: grid; place-items: center; width: 32px; height: 32px; flex-shrink: 0; border-radius: 10px; color: var(--green); background: #e7eee3; font-size: 13px; font-weight: 600; }
.team strong { display: block; font-size: 12px; }
.team small { display: block; color: #a0aaa5; font-size: 11px; }
.main-shell { min-width: 0; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 18px; min-height: 84px; padding: 19px 36px; border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, .8); }
.base-select, .topbar-actions { display: flex; align-items: center; gap: 12px; }
#base-icon { display: grid; place-items: center; width: 37px; height: 37px; border: 1px solid var(--line); border-radius: 11px; background: white; color: var(--green); }
#base-icon svg { width: 19px; height: 19px; }
.base-select strong { display: block; font-size: 13px; }
.base-select small { display: block; margin-top: 1px; color: var(--muted); font-size: 12px; }
.prototype-badge { padding: 4px 9px; border: 1px solid #dce8db; border-radius: 5px; font-size: 12px; color: #638057; background: #f5f9f1; white-space: nowrap; }
.demo-banner { display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 7px 36px; color: #8f794a; background: #fbf8ed; font-size: 12px; }
#demo-icon { display: inline-flex; flex-shrink: 0; }
#demo-icon svg { width: 14px; height: 14px; }
.demo-date { margin-left: auto; color: #a89772; white-space: nowrap; }
main { max-width: 1530px; padding: 27px 36px 36px; margin: 0 auto; }
main > .panel + .bottom-grid, main > .monitor-grid + .device-grid, main > .device-grid + .panel { margin-top: 23px; }
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 23px; }
.eyebrow { display: block; margin-bottom: 5px; color: #8da297; font-size: 11px; letter-spacing: 2px; text-transform: uppercase; }
.page-head h1 { color: #23483c; font-size: 27px; font-weight: 650; letter-spacing: .4px; }
.page-head p { margin-top: 6px; color: var(--muted); font-size: 12px; }
.controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.controls label { display: flex; align-items: center; gap: 8px; color: #809089; font-size: 12px; }
.picker { min-width: 118px; min-height: 35px; padding: 7px 29px 7px 11px; border: 1px solid #e1e9e2; border-radius: 9px; color: #446454; background: white; font-size: 12px; }
.button, button.primary, button.subtle, button.outline { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 37px; padding: 9px 15px; border: 1px solid transparent; border-radius: 9px; background: white; font-size: 12px; font-weight: 550; line-height: 1.5; transition: background .18s ease, box-shadow .18s ease, transform .18s ease; }
.button svg, button.primary svg, button.subtle svg, button.outline svg { width: 15px; height: 15px; }
.button:hover { box-shadow: 0 2px 7px #2645340d; }
.button.primary, button.primary { background: var(--green); color: white; }
.button.primary:hover, button.primary:hover { background: var(--green-dark); }
.button.subtle, button.subtle { border-color: var(--line); color: #5c776a; background: white; }
.button.subtle:hover, button.subtle:hover { background: #f5f9f5; }
.button.outline, button.outline { border-color: #d2e3d5; color: var(--green); background: transparent; }
.button.small, button.small { min-height: 30px; padding: 5px 10px; font-size: 12px; }

.hero { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 30px; min-height: 190px; margin-bottom: 22px; padding: 28px 31px; overflow: hidden; border: 1px solid #dbe8d8; border-radius: var(--radius); background: linear-gradient(108deg, #e8f1e3 0%, #f1f6e7 52%, #e6efdf 100%); }
.hero::before { content: ""; position: absolute; top: -142px; right: -47px; width: 440px; height: 440px; border: 1px solid #bdcfb966; border-radius: 50%; pointer-events: none; }
.hero::after { content: ""; position: absolute; top: -93px; right: 3px; width: 340px; height: 340px; border: 1px solid #bdcfb944; border-radius: 50%; pointer-events: none; }
.hero-copy, .hero-weather { position: relative; z-index: 1; }
.hero-copy { max-width: 70%; }
.kicker { display: inline-flex; align-items: center; gap: 5px; margin-bottom: 11px; color: #6c8558; font-size: 12px; letter-spacing: 1.6px; }
.kicker .icon { width: 13px; height: 13px; }
.hero h2 { font-size: clamp(21px, 2vw, 28px); font-weight: 600; letter-spacing: .4px; }
.hero-copy > p { margin-top: 10px; color: #6a826b; font-size: 12px; line-height: 1.8; }
.hero-copy .button { margin-top: 18px; min-height: 32px; padding: 6px 12px; }
.hero-weather { display: grid; justify-items: center; min-width: 155px; color: #34573e; }
.hero-weather > svg { width: 69px; height: 69px; margin-bottom: 2px; color: #ba9d45; }
.hero-weather strong { font-size: 35px; font-weight: 500; line-height: 1.2; }
.hero-weather strong span { margin-left: 3px; font-size: 20px; }
.hero-weather small { display: block; margin-top: 7px; color: #849178; font-size: 12px; }
.hero-weather > div { text-align: center; }
.workflow { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 6px; margin-bottom: 22px; padding: 10px 12px; border: 1px solid #e2e8de; border-radius: var(--radius); background: #fbfdf9; }
.wf-step { display: flex; align-items: center; gap: 10px; flex: 1 1 150px; min-width: 0; padding: 9px 12px; border-radius: 10px; background: #f2f7ef; border: 1px solid #e0ead9; color: inherit; text-decoration: none; transition: border-color .15s, background .15s; }
.wf-step:hover { background: #e9f3e2; border-color: #b9d3ab; }
.wf-num { flex: 0 0 auto; width: 26px; height: 26px; border-radius: 50%; background: #207b60; color: #fff; font-size: 13px; font-weight: 600; display: grid; place-items: center; }
.wf-text { min-width: 0; }
.wf-text h3 { font-size: 13.5px; font-weight: 600; color: #23452f; margin: 0; }
.wf-text p { margin: 2px 0 0; font-size: 11px; color: #7b8a7d; }
.wf-arrow { color: #9db0a0; font-size: 15px; font-style: normal; flex: 0 0 auto; padding: 0 2px; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 17px; margin-bottom: 23px; }
.kpi { min-width: 0; padding: 18px 21px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.kpi-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #73867d; font-size: 12px; }
.kpi-top > svg { width: 19px; height: 19px; color: #85a392; }
.kpi-value { display: flex; align-items: baseline; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.kpi-value strong { font-size: 31px; font-weight: 550; line-height: 1.25; letter-spacing: -.7px; font-variant-numeric: tabular-nums; }
.kpi-value > span { color: #95a29b; font-size: 12px; }
.kpi-note { margin-top: 8px; color: #94a097; font-size: 12px; }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr); align-items: stretch; gap: 22px; margin-bottom: 23px; }
.panel { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 23px 0; }
.panel-head h2 { color: #2c4b3f; font-size: 14px; font-weight: 600; }
.panel-head p { margin-top: 5px; color: #94a096; font-size: 12px; }
.panel-body { min-width: 0; padding: 19px 23px 23px; }
.chart-wrap { min-width: 0; width: 100%; overflow-x: auto; overflow-y: hidden; scrollbar-width: thin; scrollbar-color: #d7e4da transparent; }
.chart-wrap svg.plot { display: block; width: 100%; height: auto; min-width: 390px; }
.chart-wrap svg text { font-family: inherit; font-size: 12px; fill: #99a69c; }
.chart-wrap svg text[fill] { fill: #a77c3b; }
.horizon-tabs { display: inline-flex; flex-shrink: 0; padding: 3px; border: 1px solid #e6ece3; border-radius: 8px; background: #f7f9f5; }
.horizon-tabs button { min-width: 43px; padding: 4px 7px; border: 0; border-radius: 5px; color: #98a58d; background: transparent; font-size: 11px; }
.horizon-tabs button.active { color: #49794b; background: white; box-shadow: 0 1px 4px #37512b10; }
.chart-legend { display: flex; align-items: center; flex-wrap: wrap; gap: 18px; margin: 2px 0 11px; }
.legend-item { display: inline-flex; align-items: center; gap: 6px; color: #809189; font-size: 11px; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #2a8768; }
.dot.orange { background: #d08a32; }
.dot.blue { background: #91a3b3; }
.dot.dashed, .dashed { width: 15px; height: 0; border-top: 2px dashed #caaa69; border-radius: 0; background: none; }
.chart-note { display: flex; align-items: flex-start; gap: 6px; margin-top: 9px; color: #96a298; font-size: 11px; line-height: 1.8; }
.chart-note .icon { width: 12px; height: 12px; margin-top: 2px; }
.source-line { margin-top: 13px; color: #9aa69e; font-size: 11px; line-height: 1.8; }
.stat-inline { display: flex; flex-wrap: wrap; gap: 13px; color: #829289; font-size: 12px; }
.stat-inline strong { margin-left: 4px; color: #456151; }
.avatar-panel { display: flex; flex-direction: column; text-align: center; background: linear-gradient(160deg, #fcfdfb, #f2f6ed); }
.avatar-panel .panel-head { text-align: left; }
.avatar-panel .panel-body { flex: 1; padding-top: 4px; }
.avatar-stage { position: relative; display: grid; place-items: center; height: 187px; overflow: hidden; }
.avatar-stage::before { content: ""; position: absolute; bottom: 8px; width: 148px; height: 29px; border: 1px solid #c4d9c366; border-radius: 50%; background: #dce8d77a; }
.avatar-stage .person { position: relative; z-index: 1; height: 173px; width: auto; align-self: end; }
.avatar-label { position: absolute; z-index: 2; right: 6px; top: 36px; padding: 4px 8px; border: 1px solid #e0e9d7; border-radius: 7px; color: #8da07c; background: #fffffff2; font-size: 11px; }
.orbit { position: absolute; width: 145px; height: 145px; border: 1px dashed #cbdbc3; border-radius: 50%; }
.orbit-a { top: 15px; left: calc(50% - 73px); }
.orbit-b { top: 31px; left: calc(50% - 95px); width: 190px; height: 124px; transform: rotate(-24deg); }
.avatar-name { margin-top: 10px; color: #31533d; font-size: 15px; font-weight: 600; }
.avatar-name h3 { display: inline-block; margin-right: 6px; font-size: 16px; }
.avatar-name h3 span { margin-left: 5px; color: #829475; font-size: 12px; font-weight: 400; }
.avatar-name .tag { vertical-align: 2px; font-size: 11px; }
.avatar-brief { max-width: 280px; margin: 6px auto 0; color: #93a08a; font-size: 12px; line-height: 1.8; }
.avatar-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 9px; margin-top: 16px; }
.avatar-actions .button { min-height: 32px; padding: 7px 11px; font-size: 12px; }
.bottom-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.pond-map { width: 100%; overflow: hidden; border-radius: 11px; background: #f3f6ef; }
.pond-map svg { display: block; width: 100%; height: auto; }
.pond-map svg text { fill: #7a9072; font-size: 13px; font-family: inherit; }
.pond-buttons { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.pond-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 28px; padding: 5px 9px; border: 1px solid #e3eae3; border-radius: 7px; color: #8c9b8d; background: white; font-size: 11px; }
.pond-chip.active { border-color: #bfdbca; color: var(--green); background: #edf5ee; }
.pond-chip .icon { width: 12px; height: 12px; }
.action-list { display: flex; flex-direction: column; }
.action-item { display: flex; gap: 12px; padding: 16px 0; border-bottom: 1px solid #edf1ed; }
.action-item:first-child { padding-top: 2px; }
.action-item:last-child { padding-bottom: 0; border-bottom: 0; }
.action-index { display: grid; place-items: center; width: 25px; height: 25px; flex: 0 0 25px; border-radius: 8px; background: #f1f5eb; color: #98a97c; font-size: 12px; }
.action-item > div { min-width: 0; flex: 1; }
.action-item h3 { color: #4f6958; font-size: 12px; font-weight: 550; }
.action-item p { margin-top: 5px; color: #97a196; font-size: 12px; line-height: 1.75; }
.action-item .button { margin-top: 9px; }
.tag { display: inline-flex; align-items: center; gap: 4px; flex-shrink: 0; width: fit-content; padding: 3px 7px; border: 1px solid #e2eadf; border-radius: 5px; color: #748568; background: #f3f7ee; font-size: 11px; line-height: 1.4; font-weight: 500; }
.tag.warning { color: #b57a35; background: #fff5e7; border-color: #f1dfc4; }
.tag.normal { color: #548268; background: #edf7ef; border-color: #d9eadb; }
.tag.unknown { color: #857998; background: #f3eff7; border-color: #e6dfec; }
.tag.neutral { color: #8b958d; background: #f4f6f3; border-color: #e6eae3; }
.empty-state { display: grid; place-items: center; gap: 9px; min-height: 200px; padding: 27px; color: #9ba79b; text-align: center; font-size: 12px; }
.empty-state svg { width: 32px; height: 32px; color: #c0ccbd; }
.empty-state p { max-width: 430px; font-size: 12px; }
.empty-state.compact { min-height: 160px; padding: 24px 12px; }
.page-footer { display: flex; justify-content: space-between; gap: 15px; max-width: 1530px; margin: 0 auto; padding: 2px 36px 23px; color: #aab2a9; font-size: 11px; }

.table-wrap { max-width: 100%; overflow-x: auto; scrollbar-width: thin; }
.data-table, .metric-table { width: 100%; border-collapse: collapse; text-align: left; font-size: 12px; }
.data-table { min-width: 590px; }
.data-table th, .metric-table th { padding: 12px 13px; border-bottom: 1px solid #e4ece3; color: #8a9a8d; background: #f7f9f5; font-weight: 500; font-size: 12px; white-space: nowrap; }
.data-table td, .metric-table td { padding: 14px 13px; border-bottom: 1px solid #edf1ea; color: #627b68; font-variant-numeric: tabular-nums; }
.data-table tbody tr:last-child td, .metric-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: #fafcf8; }
.forecast-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin-bottom: 24px; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--line); }
.summary-block { padding: 20px 24px; background: white; }
.summary-block > .icon { float: right; width: 23px; height: 23px; color: #a1b392; }
.summary-block span, .summary-block small { display: block; color: #8b9a8c; font-size: 12px; }
.summary-block strong { display: block; margin-top: 5px; color: #375e45; font-size: 24px; font-weight: 550; }
.summary-block p { margin-top: 5px; color: #9aa597; font-size: 12px; }
.scenario-note { display: flex; align-items: flex-start; gap: 9px; margin-bottom: 20px; padding: 13px 17px; border: 1px solid #e3ead9; border-radius: 10px; color: #7e8e69; background: #f4f7eb; font-size: 12px; line-height: 1.8; }
.scenario-note svg { width: 16px; height: 16px; margin-top: 2px; }
.risk-card { margin-bottom: 16px; padding: 23px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.risk-title { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.risk-title h2, .risk-title h3 { flex: 1; color: #3b5a43; font-size: 15px; }
.risk-title > div { flex: 1; min-width: 0; }
.risk-title h2 { margin-top: 10px; font-size: 20px; }
.risk-title p { margin-top: 7px; color: #97a38e; font-size: 12px; }
.risk-title > svg { width: 21px; height: 21px; color: #c09555; }
.risk-body { margin-top: 13px; color: #81927e; font-size: 12px; line-height: 1.9; }
.evidence-list { display: flex; flex-wrap: wrap; gap: 7px; padding: 0; margin: 15px 0 0; list-style: none; }
.evidence-list li, .evidence-list > span { padding: 5px 9px; border: 1px solid #e7ebdf; border-radius: 6px; background: #f7f9f3; color: #89977f; font-size: 12px; }
.risk-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.record-list { display: flex; flex-direction: column; gap: 14px; }
.record-item { padding-bottom: 15px; border-bottom: 1px solid var(--line); }
.record-item:last-child { padding-bottom: 0; border-bottom: 0; }
.record-item > div { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 7px; }
.record-item time, .record-item small { color: #a0ad96; font-size: 11px; }
.record-item p { margin: 10px 0 5px; color: #7a9070; font-size: 12px; line-height: 1.85; overflow-wrap: anywhere; }
.detail-list { padding: 0; margin: 0; }
.detail-list > div { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 16px; padding: 12px 0; border-bottom: 1px solid #edf1e8; font-size: 12px; }
.detail-list > div:first-child { padding-top: 0; }
.detail-list > div:last-child { padding-bottom: 0; border: 0; }
.detail-list dt { color: #9aa78f; }
.detail-list dd { margin: 0; color: #6d8561; overflow-wrap: anywhere; }
.device-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-bottom: 23px; }
.device-card { min-width: 0; padding: 23px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.device-icon { display: grid; place-items: center; width: 39px; height: 39px; margin-bottom: 15px; border-radius: 11px; background: #edf4e7; color: #85a071; }
.device-icon svg { width: 21px; height: 21px; }
.device-card h3 { font-size: 14px; font-weight: 600; }
.device-card > .tag { float: right; margin-top: -49px; }
.device-card p { margin-top: 7px; color: #8d9b89; font-size: 12px; }
.device-status { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 9px; margin-top: 17px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 12px; color: #9ba796; }
.monitor-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 21px; }
.placeholder-camera { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; min-height: 230px; padding: 22px; border: 1px dashed #d9e3d1; border-radius: 12px; color: #a0af96; background: linear-gradient(130deg, #f5f8f0, #edf3e9); font-size: 12px; text-align: center; }
.placeholder-camera > svg { width: 35px; height: 35px; color: #b4c3a7; }
.placeholder-camera p { max-width: 300px; color: #a1ac99; font-size: 12px; }
.placeholder-camera img { display: block; width: 100%; max-height: 410px; object-fit: contain; border-radius: 8px; }
.file-button { position: relative; margin-top: 14px; cursor: pointer; }
.file-button input { position: absolute; inset: 0; width: 100%; opacity: 0; cursor: pointer; }
.file-button:focus-within { outline: 3px solid #91c2a6; outline-offset: 4px; }
.chat-layout { display: grid; grid-template-columns: minmax(230px, .75fr) minmax(0, 1.65fr); align-items: start; gap: 23px; }
.chat-panel { display: flex; flex-direction: column; min-width: 0; min-height: 530px; }
.chat-panel > .panel-body { display: flex; flex: 1; flex-direction: column; padding: 5px 0 14px; }
.chat-panel > .panel-body > .source-line { padding: 0 23px; }
.chat-messages { display: flex; flex-direction: column; gap: 23px; flex: 1; min-height: 310px; max-height: 530px; overflow-y: auto; padding: 24px; scrollbar-width: thin; }
.message { display: flex; align-items: flex-start; gap: 10px; }
.message-avatar { display: grid; place-items: center; width: 30px; height: 30px; flex: 0 0 30px; border-radius: 9px; background: #e6f0e2; color: #689061; font-size: 12px; }
.message-avatar svg { width: 18px; height: 18px; }
.message-body { max-width: 85%; padding: 13px 16px; border: 1px solid #e7ece1; border-radius: 0 13px 13px 13px; background: #f6f8f2; color: #6c8468; font-size: 12px; line-height: 1.9; overflow-wrap: anywhere; }
.message-body p + p { margin-top: 10px; }
.message-body small { display: block; margin-top: 9px; color: #9eac94; font-size: 11px; line-height: 1.8; }
.message-body strong { color: #3f6943; }
.message.user { flex-direction: row-reverse; }
.message.user .message-avatar { color: white; background: #6a8a64; }
.message.user .message-body { border-color: #dbe9d4; border-radius: 13px 0 13px 13px; background: #e9f2e2; color: #537648; }
.quick-questions { display: flex; flex-wrap: wrap; gap: 7px; padding: 8px 23px 14px; }
.quick-questions button { padding: 6px 10px; border: 1px solid #e2eadb; border-radius: 7px; background: white; color: #829773; font-size: 12px; }
.quick-questions button:hover { border-color: #aac5a0; background: #f6f9f1; }
.chat-form { display: flex; align-items: center; gap: 9px; padding: 16px 23px; border-top: 1px solid var(--line); }
.chat-form input { flex: 1; min-width: 0; min-height: 39px; padding: 10px 12px; border: 1px solid #e3eadb; border-radius: 9px; color: #46643a; background: #fafcf7; font-size: 12px; }
.chat-form input::placeholder { color: #a7b29e; }
.lab-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 21px; margin-bottom: 23px; }
.lab-card { padding: 24px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.lab-step { display: block; margin-bottom: 14px; color: #a4b38d; font-size: 12px; letter-spacing: 2px; }
.lab-card h2, .lab-card h3 { color: #47623d; font-size: 15px; }
.lab-card p { margin-top: 10px; color: #91a081; font-size: 12px; line-height: 1.85; }
.lab-card .tag { margin-top: 17px; }
.metric-table { min-width: 370px; }
.steps-list { padding-left: 21px; margin: 0; color: #7c9271; font-size: 12px; line-height: 1.9; }
.steps-list li { padding: 5px 0 9px 4px; }
.steps-list li::marker { color: #abc097; font-weight: 600; }
.callout { display: flex; align-items: flex-start; gap: 9px; margin-top: 17px; padding: 14px 17px; border: 1px solid #e4ead9; border-radius: 10px; background: #f5f8ed; color: #8d9b74; font-size: 12px; line-height: 1.85; }
.callout .icon { width: 16px; height: 16px; margin-top: 2px; }
.callout strong { color: #6f8553; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.chips > span { padding: 4px 9px; border-radius: 6px; background: #edf3e4; color: #8a9b71; font-size: 12px; }

dialog { width: min(610px, calc(100% - 32px)); max-height: calc(100dvh - 48px); margin: auto; padding: 0; overflow-y: auto; border: 1px solid #dfe8d8; border-radius: 19px; color: var(--ink); background: white; box-shadow: 0 24px 90px #1f3b3333; }
dialog::backdrop { background: #1b342960; backdrop-filter: blur(3px); }
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 23px 26px 18px; border-bottom: 1px solid var(--line); }
.modal-header h2 { font-size: 18px; font-weight: 600; }
.modal-header p { margin-top: 5px; color: #94a18a; font-size: 12px; }
.modal-header button { display: grid; place-items: center; flex-shrink: 0; width: 31px; height: 31px; padding: 5px; border: 0; border-radius: 8px; background: #f2f6ee; color: #92a482; }
.modal-header button svg { width: 17px; height: 17px; }
.modal-body { padding: 23px 26px; color: #74866c; font-size: 12px; line-height: 1.85; }
.modal-body > p + p { margin-top: 12px; }
.modal-body > h3 { margin-top: 18px; margin-bottom: 8px; font-size: 13px; }
.modal-actions { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 10px; padding: 17px 26px 22px; border-top: 1px solid var(--line); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.pond-fields { margin-top: 18px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field label { color: #728668; font-size: 12px; }
.field input, .field select, .field textarea { width: 100%; min-height: 39px; padding: 9px 11px; border: 1px solid #dfe7d7; border-radius: 8px; color: #4c6a3d; background: #fcfdfb; font-size: 12px; }
.field textarea { min-height: 95px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #b1bbab; }
.field small { color: #a0ad96; font-size: 12px; }
.toast { position: fixed; z-index: 100; right: 28px; bottom: 25px; max-width: min(440px, calc(100vw - 40px)); padding: 13px 20px; border: 1px solid #c6ddba; border-radius: 12px; color: #eaf3e1; background: #365f37; box-shadow: 0 8px 35px #29492826; font-size: 12px; opacity: 0; transform: translateY(14px); pointer-events: none; transition: opacity .2s ease, transform .2s ease; }
.toast.show { opacity: 1; transform: translateY(0); }

@media (min-width: 1650px) {
  main { padding-top: 35px; }
  .hero { min-height: 220px; }
  .hero h2 { font-size: 31px; }
  .kpi { padding-top: 22px; padding-bottom: 22px; }
}

@media (max-width: 1180px) {
  .topbar, .demo-banner { padding-left: 26px; padding-right: 26px; }
  main { padding: 25px 26px 30px; }
  .page-footer { padding-left: 26px; padding-right: 26px; }
  .page-head { align-items: flex-start; }
  .controls { max-width: 270px; gap: 7px; }
  .controls label { font-size: 11px; }
  .hero { gap: 20px; padding: 25px; }
  .hero-copy { max-width: 73%; }
  .hero-weather { min-width: 110px; }
  .kpi { padding: 16px; }
  .kpi-value strong { font-size: 27px; }
  .workspace-grid { grid-template-columns: minmax(0, 1.6fr) minmax(245px, 1fr); gap: 17px; }
  .panel-head { padding: 18px 18px 0; }
  .panel-body { padding: 17px 18px 19px; }
  .bottom-grid, .monitor-grid, .lab-grid { gap: 17px; }
  .demo-date { display: none; }
}

@media (max-width: 960px) {
  .shell { grid-template-columns: 185px minmax(0, 1fr); }
  .sidebar { padding-left: 12px; padding-right: 12px; }
  .brand { gap: 8px; padding-left: 4px; }
  .brand strong { font-size: 22px; }
  .brand small { font-size: 11px; letter-spacing: .6px; }
  .brand-mark { width: 37px; height: 37px; }
  .sidebar-note { margin-left: 3px; margin-right: 3px; }
  .page-head { flex-direction: column; gap: 14px; }
  .controls { justify-content: flex-start; max-width: none; }
  .workspace-grid { grid-template-columns: minmax(0, 1fr); }
  .avatar-panel .panel-body { display: flex; flex-direction: column; align-items: center; gap: 6px; }
  .avatar-panel .avatar-stage { width: 100%; height: 240px; }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bottom-grid, .monitor-grid, .chat-layout { grid-template-columns: minmax(0, 1fr); }
  .device-grid, .lab-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chat-layout > .avatar-panel { order: 0; }
  .chat-messages { max-height: 500px; }
  .topbar-actions { gap: 7px; }
  .topbar-actions .button { padding: 8px 10px; }
  .prototype-badge { display: none; }
  .summary-block { padding: 17px; }
  .summary-block strong { font-size: 21px; }
}

@media (max-width: 700px) {
  body { font-size: 13px; }
  .shell { display: block; }
  .sidebar { position: static; height: auto; padding: 15px 18px 9px; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand { width: fit-content; padding: 0 3px; }
  .brand-mark { width: 35px; height: 35px; border-radius: 11px; }
  .brand-mark svg { width: 27px; height: 27px; }
  .brand strong { font-size: 21px; line-height: 1.25; }
  .brand small { font-size: 11px; }
  .nav-label, .sidebar-note, .team { display: none; }
  #navigation { flex-direction: row; gap: 5px; margin: 15px -18px 0; padding: 0 18px 4px; overflow-x: auto; scrollbar-width: none; }
  #navigation::-webkit-scrollbar { display: none; }
  .nav-item { flex: 0 0 auto; width: auto; min-height: 36px; gap: 7px; padding: 8px 10px; border-radius: 8px; font-size: 12px; white-space: nowrap; }
  .nav-item svg { width: 15px; height: 15px; }
  .nav-item.active::after, .nav-item[aria-current="page"]::after { display: none; }
  .sidebar-bottom { position: absolute; top: 18px; right: 18px; }
  .sidebar-bottom .nav-item { min-height: 32px; padding: 7px 9px; font-size: 12px; }
  .topbar { min-height: 68px; padding: 13px 20px; gap: 9px; }
  .base-select { gap: 8px; min-width: 0; }
  .base-select strong { font-size: 12px; }
  .base-select small { font-size: 11px; }
  #base-icon { width: 32px; height: 32px; flex-shrink: 0; }
  .topbar-actions { flex-shrink: 0; }
  .topbar-actions .button { gap: 4px; min-height: 31px; padding: 6px 8px; font-size: 11px; }
  .topbar-actions .button svg { width: 12px; height: 12px; }
  .demo-banner { align-items: flex-start; padding: 8px 20px; font-size: 11px; line-height: 1.7; }
  #demo-icon { margin-top: 2px; }
  main { padding: 22px 20px 26px; }
  .page-head { gap: 16px; margin-bottom: 18px; }
  .page-head h1 { font-size: 24px; }
  .page-head p { font-size: 12px; }
  .eyebrow { font-size: 11px; }
  .controls { width: 100%; justify-content: flex-start; gap: 9px; }
  .controls label { flex: 1 1 140px; justify-content: space-between; gap: 6px; font-size: 11px; }
  .picker { flex: 1; min-width: 0; min-height: 34px; padding-left: 8px; padding-right: 17px; font-size: 12px; }
  .hero { gap: 12px; min-height: 177px; margin-bottom: 17px; padding: 22px 20px; border-radius: 15px; }
  .hero-copy { max-width: none; flex: 1; min-width: 0; }
  .hero h2 { font-size: 21px; line-height: 1.5; }
  .hero-copy > p { margin-top: 8px; font-size: 12px; }
  .kicker { margin-bottom: 7px; font-size: 11px; letter-spacing: 1px; }
  .hero-weather { min-width: 77px; }
  .hero-weather > svg { width: 48px; height: 48px; }
  .hero-weather strong { font-size: 27px; }
  .hero-weather small { font-size: 11px; }
  .hero-copy .button { margin-top: 14px; font-size: 11px; }
  .kpi-grid { gap: 11px; margin-bottom: 18px; }
  .kpi { padding: 14px 15px; border-radius: 12px; }
  .kpi-top { gap: 6px; font-size: 12px; }
  .kpi-top > svg { width: 17px; height: 17px; }
  .kpi-value { gap: 5px; margin-top: 10px; }
  .kpi-value strong { font-size: 28px; }
  .kpi-value > span { font-size: 11px; }
  .kpi-note { font-size: 11px; }
  .workspace-grid, .bottom-grid, .monitor-grid, .chat-layout, .device-grid, .lab-grid { gap: 17px; grid-template-columns: minmax(0, 1fr); }
  .workspace-grid { margin-bottom: 18px; }
  .panel { border-radius: 14px; }
  .panel-head { gap: 10px; padding: 18px 17px 0; }
  .panel-head h2 { font-size: 13px; }
  .panel-head p { font-size: 11px; }
  .panel-head .button { flex-shrink: 0; font-size: 11px; }
  .panel-body { padding: 17px; }
  .chart-wrap svg.plot { min-width: 370px; }
  .chart-legend { gap: 12px; }
  .legend-item { font-size: 11px; }
  .chart-note, .source-line { font-size: 11px; }
  .avatar-panel .panel-body { display: block; }
  .avatar-stage { height: 184px; }
  .avatar-label { right: max(10px, calc(50% - 124px)); }
  .avatar-name { margin-top: 8px; }
  .avatar-brief { font-size: 12px; }
  .forecast-summary { grid-template-columns: minmax(0, 1fr); gap: 1px; margin-bottom: 19px; }
  .summary-block { display: flex; align-items: center; flex-wrap: wrap; column-gap: 16px; padding: 15px 18px; }
  .summary-block strong { margin: 0 0 0 auto; font-size: 23px; }
  .summary-block > .icon { float: none; width: 19px; height: 19px; }
  .summary-block p { flex-basis: 100%; margin-top: 4px; font-size: 11px; }
  .risk-card { padding: 19px; }
  .risk-title { gap: 8px; }
  .risk-title h2, .risk-title h3 { font-size: 14px; }
  .risk-body { font-size: 12px; }
  .device-card, .lab-card { padding: 21px; }
  .chat-panel { min-height: 500px; }
  .chat-messages { gap: 18px; padding: 19px 16px; }
  .message { gap: 8px; }
  .message-avatar { width: 26px; height: 26px; flex-basis: 26px; font-size: 11px; }
  .message-body { max-width: calc(100% - 34px); padding: 11px 13px; font-size: 12px; }
  .quick-questions { padding: 6px 16px 13px; }
  .quick-questions button { font-size: 11px; }
  .chat-form { padding: 14px 16px; }
  .chat-form .button { padding-left: 10px; padding-right: 10px; }
  .chat-form input { font-size: 12px; }
  .form-grid { grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .modal-header { padding: 20px 21px 16px; }
  .modal-body { padding: 20px 21px; }
  .modal-actions { padding: 16px 21px 20px; }
  .page-footer { flex-direction: column; align-items: center; gap: 4px; padding: 0 20px 22px; font-size: 11px; }
  .toast { right: 20px; bottom: 18px; font-size: 12px; }
}

/* Keep primary text legible at every viewport; cards grow with their content. */
.nav-item, .base-select strong, .picker,
.button, button.primary, button.subtle, button.outline,
.hero-copy > p, .kpi-top, .action-item h3, .action-item p,
.avatar-brief, .risk-body, .device-card p, .record-item p,
.detail-list > div, .message-body, .chat-form input,
.quick-questions button, .lab-card p, .steps-list,
.callout, .scenario-note, .empty-state p, .placeholder-camera p,
.data-table, .metric-table, .modal-body,
.field input, .field select, .field textarea { font-size: 14px; }
.panel-head h2, .device-card h3, .lab-card h2, .lab-card h3 { font-size: 16px; }
.action-item h3 { font-weight: 600; }
.avatar-actions .button, .hero-copy .button,
.button.small, button.small, .pond-chip, .tag,
.base-select small, .controls label, .page-head p,
.panel-head p, .kpi-note, .kpi-value > span,
.source-line, .chart-note, .message-body small,
.record-item time, .record-item small, .field label,
.field small, .risk-title p, .evidence-list li,
.evidence-list > span, .device-status, .summary-block span,
.summary-block small, .summary-block p, .chips > span,
.placeholder-camera, .modal-header p, .page-footer { font-size: 12px; }
.kpi-note, .source-line, .panel-head p, .page-head p,
.chart-note, .avatar-brief, .action-item p, .hero-copy > p,
.device-card p, .record-item p, .lab-card p,
.message-body small, .detail-list dt, .field label,
.risk-title p, .evidence-list li, .evidence-list > span,
.record-item time, .record-item small, .summary-block span,
.summary-block small, .summary-block p, .placeholder-camera p,
.page-footer { color: #71816e; }
.page-head p, .hero-copy > p, .avatar-brief,
.action-item p, .risk-body, .device-card p,
.lab-card p, .record-item p { line-height: 1.8; }
.data-table th, .metric-table th { font-size: 12px; }
.avatar-name h3 span { font-size: 12px; }
.avatar-name .tag, .legend-item, .avatar-label,
.horizon-tabs button, .eyebrow, .prototype-badge,
.sidebar-note p, .team small { font-size: 11px; }
.icon-button { display: inline-grid; place-items: center; }

@media (max-width: 700px) {
  .sidebar-bottom .nav-item { font-size: 12px; }
  #navigation .nav-item { font-size: 13px; }
  .topbar-actions .button { font-size: 12px; }
  .topbar-actions .button svg { width: 14px; height: 14px; }
  .base-select small { max-width: 170px; overflow-wrap: anywhere; }
  .controls label { flex-basis: 100%; }
  .controls .picker { min-height: 40px; flex: 0 1 75%; }
  .panel-head { flex-wrap: wrap; }
  .panel-head h2 { font-size: 16px; }
  .hero { align-items: flex-start; }
  .hero-weather { padding-top: 23px; }
  .hero-weather small { max-width: 82px; font-size: 11px; line-height: 1.6; }
  .hero-copy .button { font-size: 12px; }
  .hero h2 { font-size: 21px; }
  .kpi-top { font-size: 13px; }
  .kpi-note { font-size: 11px; }
  .risk-title h2 { font-size: 19px; }
  .chart-wrap svg.plot { min-width: 520px; }
  .horizon-tabs button { min-width: 47px; min-height: 30px; }
  .quick-questions button { padding: 8px 10px; }
  .chat-form input { min-height: 44px; }
  .chat-form .button { min-height: 44px; }
  .summary-block { column-gap: 10px; }
  .summary-block strong { font-size: 22px; }
  .detail-list > div { grid-template-columns: 85px minmax(0, 1fr); gap: 12px; }
  .page-footer { font-size: 11px; }
}

.base-photo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.base-photo-card { margin: 0; border: 1px solid #dce6df; border-radius: 12px; overflow: hidden; background: #fafcf9; }
.base-photo-card.selected { border-color: #207b60; box-shadow: 0 0 0 1px #207b60; }
.base-photo-card button { display: block; width: 100%; border: 0; padding: 0; text-align: left; background: transparent; cursor: pointer; color: #214c3c; font: inherit; }
.base-photo-card img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.base-photo-card button span { display: block; padding: 14px 14px 0; font-size: 14px; font-weight: 600; }
.base-photo-card figcaption { padding: 10px 14px 16px; font-size: 12px; color: #71816e; line-height: 1.8; }
@media (max-width: 900px) {
  .base-photo-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* ===== 知知 · 魔珐星云数字人（驻留知知面板形象区域） ===== */
.xingyun-mount { position: absolute; z-index: 8; display: none; width: 0; height: 0; overflow: hidden; border-radius: 14px; background: linear-gradient(160deg, #f6faf5, #eaf2e6); }
.xingyun-mount.is-visible { display: block; }
.xingyun-mount canvas, .xingyun-mount video { display: block; position: absolute !important; z-index: 2; inset: 0 !important; left: 0 !important; right: 0 !important; top: 0 !important; bottom: 0 !important; margin: auto !important; width: 100% !important; height: 100% !important; transform: none !important; }
.xingyun-loading { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 9px; color: #6f8076; font-size: 12px; }
.xingyun-loading .pulse { width: 9px; height: 9px; border-radius: 50%; background: var(--green); animation: xpulse 1.2s ease-in-out infinite; }
@keyframes xpulse { 0%, 100% { opacity: .35; transform: scale(.8); } 50% { opacity: 1; transform: scale(1); } }
.xingyun-mount.is-live .xingyun-loading { display: none; }

.avatar-stage--live { color: #51745f; }
.avatar-stage--live .avatar-live-brief { position: absolute; z-index: 3; left: 12px; right: 12px; bottom: 10px; text-align: center; font-size: 11px; color: rgba(81, 116, 95, .82); background: rgba(255, 255, 255, .72); padding: 5px 8px; border-radius: 8px; pointer-events: none; }
.avatar-stage--live .avatar-label { z-index: 3; }
@media (max-width: 640px) {
  .xingyun-mount { border-radius: 12px; }
}
