/* PICC visual release: selected red-white business direction. */
:root { --brand:#e8380d; --brand-soft:#fff5f2; --ink:#171c28; --muted:#76808e; --paper:#fff; --surface:#fff; --line:#e7e9ee; --green:var(--brand); --green-dark:#cf2907; --shadow:none; }
body { background:#fff; font:15px/1.5 "Microsoft YaHei","PingFang SC",Arial,sans-serif; }
.shell, .shell.home-view { width:auto; max-width:none; margin:0 0 0 220px; padding:30px 40px 20px; }
.sidebar { position:fixed; inset:0 auto 0 0; width:220px; padding:28px 10px; border-right:1px solid var(--line); background:#fff; z-index:20; display:flex; flex-direction:column; }
.picc-brand { padding:4px 18px 36px; }
.picc-brand img { display:block; width:100%; height:auto; }
.tabs { display:flex; flex-direction:column; gap:8px; overflow:visible; margin:12px 0; }
.tab { display:flex; align-items:center; gap:16px; min-height:54px; padding:12px 18px; border-radius:5px; text-align:left; color:#343d4c; font-size:16px; font-weight:600; border-left:3px solid transparent; }
.tab img { width:22px; height:22px; opacity:.75; }
.tab:hover { background:#f8f9fb; }
.tab.active { background:var(--brand-soft); color:var(--brand); border-left-color:var(--brand); }
.tab.active img { filter:invert(24%) sepia(96%) saturate(3771%) hue-rotate(355deg) brightness(100%) contrast(94%); opacity:1; }
.sidebar-caption { margin-top:auto; padding:20px 18px 0; color:#9299a4; font-size:11px; }
.topbar, .home-view .topbar { border:0; padding:0 0 26px; align-items:flex-start; gap:16px; }
.product-title { border-left:5px solid var(--brand); padding-left:18px; }
.topbar h1, .home-view .topbar h1 { font:700 clamp(25px,2.8vw,38px)/1.2 "Microsoft YaHei",sans-serif; letter-spacing:0; margin:0; }
.product-subtitle { font-size:17px; color:var(--muted); margin:9px 0 0; }
.user-area { font-size:12px; gap:7px; padding-top:2px; }
.status-pill { font-size:11px; max-width:480px; text-align:right; }
.status-dot { background:#12825e; width:6px; height:6px; box-shadow:none; }
.user-chip { font-size:12px; }
.user-avatar { width:26px; height:26px; opacity:.65; }
.home-controls { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)) 150px; align-items:start; gap:14px; margin:0 0 32px; }
.home-controls > label { min-width:0; font-size:0; gap:0; }
.home-controls select { border:1px solid #d9dee7; border-radius:5px; padding:12px 14px; background:#fff; color:var(--ink); font-size:14px; min-height:46px; }
.home-more-filters { position:relative; }
.home-more-filters > summary { list-style:none; cursor:pointer; display:flex; align-items:center; gap:9px; justify-content:center; min-height:46px; border-left:1px solid var(--line); font-size:14px; color:#465061; }
.home-more-filters > summary::-webkit-details-marker { display:none; }
.home-more-filters img { width:18px; height:18px; }
.home-extra-fields { position:absolute; right:0; top:55px; width:290px; z-index:25; display:grid; gap:14px; padding:20px; border:1px solid var(--line); background:white; box-shadow:0 8px 28px #18213512; }
.home-extra-fields label { font-size:12px; }
.home-extra-fields .button { display:flex; gap:8px; align-items:center; justify-content:center; }
.home-kpis { grid-template-columns:repeat(3,minmax(0,1fr)); gap:0; margin:0 0 34px; }
.home-kpi, .home-kpi.primary { border:0; border-radius:0; background:transparent; color:var(--ink); padding:4px 26px 12px; display:flex; flex-direction:column; gap:8px; align-items:flex-start; min-width:0; }
.home-kpi:first-child { padding-left:0; }
.home-kpi + .home-kpi { border-left:1px solid var(--line); }
.home-kpi > span { color:var(--ink); font-size:16px; font-weight:600; }
.home-kpi > small { color:var(--muted); font-size:12px; min-height:18px; }
.home-kpi-figure { display:flex; align-items:baseline; flex-wrap:wrap; gap:5px; margin-top:4px; padding-bottom:14px; position:relative; }
.home-kpi-figure:after { content:""; position:absolute; left:0; bottom:0; width:30px; border-bottom:2px solid var(--brand); }
.home-kpi strong { font:700 clamp(29px,3.75vw,56px)/1.2 Arial,"Microsoft YaHei",sans-serif; letter-spacing:-.035em; white-space:nowrap; }
.metric-unit { font-size:17px; color:var(--ink); }
.change-arrow { width:28px; height:28px; align-self:center; filter:invert(29%) sepia(99%) saturate(3000%) hue-rotate(353deg) brightness(102%) contrast(90%); }
.home-trend { border:0; padding:0; margin-bottom:16px; box-shadow:none; background:transparent; }
.trend-heading { align-items:center; gap:12px; }
.trend-heading h2 { display:inline-block; font-size:24px; padding-left:15px; border-left:5px solid var(--brand); line-height:1.25; }
.trend-heading p { font-size:11px; color:var(--muted); margin:6px 0 0 20px; }
.trend-actions { flex-wrap:wrap; justify-content:flex-end; gap:10px; }
.trend-segments { display:flex; background:#f4f5f7; border:1px solid #e6e8ec; border-radius:5px; padding:2px; }
.trend-segments button { border:0; background:transparent; color:#626c7c; cursor:pointer; padding:6px 19px; border-radius:4px; font-size:14px; }
.trend-segments button[aria-pressed="true"] { background:var(--brand); color:#fff; }
.trend-chart { min-height:0; margin:18px 0 4px; }
.trend-grid { stroke:#e8ebf0; stroke-dasharray:3 3; }
.trend-axis { fill:#758093; font-family:Arial,"Microsoft YaHei",sans-serif; font-size:12px; }
.current-line { color:var(--brand); stroke:var(--brand); }
.previous-line { color:#969eac; stroke:#969eac; }
.trend-area { fill:var(--brand); fill-opacity:.035; }
.trend-line { stroke-width:2.5; }
.trend-line.previous-line { stroke-width:2; }
.trend-point { stroke:white; stroke-width:1.5; }
.trend-point.partial { fill:white; stroke:var(--brand); stroke-width:2; }
.trend-point.previous-line.partial { stroke:#969eac; }
.trend-point:focus, .trend-point:hover { stroke:var(--ink); stroke-width:2; }
.trend-legend { justify-content:center; gap:22px; font-size:13px; margin:10px 0 6px; }
.trend-legend small { margin:0; font-size:10px; }
.trend-readout { border:0; color:var(--muted); text-align:center; padding:6px 0; min-height:28px; }
.trend-notes { margin:5px 0; font-size:11px; }
.home-bottom { justify-content:space-between; align-items:center; gap:16px; margin:18px 0 8px; }
.home-bottom strong { font-size:15px; color:var(--ink); }
.home-bottom p { font-size:11px; color:var(--muted); margin:5px 0; }
.home-bottom button { white-space:nowrap; color:var(--brand); }
footer { border-color:var(--line); margin-top:28px; padding-top:14px; font-size:10px; color:#9299a4; }
.panel { border:1px solid var(--line); border-radius:6px; box-shadow:none; }
.controls-panel { background:#fafbfc; }
.button { border-radius:5px; }
.button.primary { background:var(--brand); }
.button.primary:hover { background:#ca2c0a; }
input:focus, select:focus, textarea:focus { border-color:var(--brand); box-shadow:0 0 0 3px #e8380d13; }
.kpi { background:#fff; color:var(--ink); border:1px solid var(--line); border-radius:5px; }
.kpi.accent, #kpi-grid .kpi:first-child { background:var(--brand-soft); }
.kpi-label { color:var(--muted); }
.kpi .positive { color:#12825e; }
.kpi .negative { color:#bd3c33; }
.kpi.alert { background:#fff5e4; }
.kpi-value { font-family:Arial,"Microsoft YaHei",sans-serif; }
.insight-banner { background:#fff7f4; border-left:4px solid var(--brand); border-radius:3px; padding:20px 24px; }
.insight-banner strong { font:600 22px/1.4 "Microsoft YaHei",sans-serif; }
.insight-banner span { color:var(--muted); }
tfoot td, tfoot th { background:#f6f7f9; }
.meter .ok { background:#12825e; }
.positive { color:#12825e; }
.notice { border-radius:5px; }
.auth-gate { background:#fafbfc; }
.auth-card { border:1px solid var(--line); border-radius:9px; padding:34px; box-shadow:0 10px 45px #1c24300a; }
.auth-picc-logo { display:block; width:190px; height:auto; margin:0 auto 24px; }
.auth-card h1 { font:700 26px/1.3 "Microsoft YaHei",sans-serif; text-align:center; }
.auth-card > p { text-align:center; }
@media(min-width:1600px) { .shell,.shell.home-view { padding-left:52px; padding-right:52px; } }
@media(min-width:701px) and (max-width:1150px) {
  .sidebar { width:180px; padding-left:6px; padding-right:6px; }
  .shell,.shell.home-view { margin-left:180px; padding:24px; }
  .tab { font-size:14px; gap:12px; }
  .home-controls { grid-template-columns:repeat(4,minmax(0,1fr)) 100px; gap:8px; }
  .home-controls select { padding:10px 7px; font-size:12px; }
  .home-kpi { padding-left:16px; padding-right:12px; }
  .home-kpi strong { font-size:32px; }
  .metric-unit { font-size:14px; }
  .topbar h1,.home-view .topbar h1 { font-size:30px; }
}
@media(max-width:700px) {
  .sidebar { position:static; width:auto; padding:16px 14px 0; border-right:0; border-bottom:1px solid var(--line); }
  .picc-brand { padding:0 0 13px; }
  .picc-brand img { width:145px; }
  .tabs,.home-view .tabs { flex-direction:row; overflow-x:auto; margin:0; gap:0; }
  .tab { border-left:0; border-bottom:2px solid transparent; border-radius:0; gap:7px; padding:9px 12px; min-height:42px; font-size:13px; }
  .tab img { width:17px; height:17px; }
  .tab.active { border-bottom-color:var(--brand); }
  .sidebar-caption { display:none; }
  .shell,.shell.home-view { padding:0; margin:0; }
  .topbar,.home-view .topbar { padding:20px 16px 16px; gap:12px; flex-direction:column; align-items:stretch; }
  .topbar h1,.home-view .topbar h1 { font-size:25px; }
  .product-title { padding-left:12px; border-left-width:4px; }
  .product-subtitle { font-size:13px; margin:4px 0 0; }
  .user-area { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:8px; padding-top:0; }
  .status-pill { text-align:left; font-size:10px; }
  .user-chip { font-size:11px; }
  .user-avatar { width:20px; height:20px; }
  main { padding:0 16px; }
  .home-controls { grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; margin-bottom:22px; }
  .home-controls select { min-height:40px; padding:9px 10px; font-size:12px; }
  .home-more-filters { grid-column:1/-1; justify-self:end; }
  .home-more-filters > summary { min-height:28px; font-size:12px; border:0; }
  .home-extra-fields { top:34px; width:min(290px,calc(100vw - 32px)); }
  .home-kpis { margin-bottom:26px; }
  .home-kpi { padding:0 8px 10px; gap:6px; }
  .home-kpi > span { font-size:11px; }
  .home-kpi > small { font-size:9px; min-height:27px; line-height:1.5; }
  .home-kpi-figure { gap:2px; flex-wrap:wrap; padding-bottom:10px; }
  .home-kpi strong { font-size:24px; white-space:normal; overflow-wrap:anywhere; }
  .metric-unit { font-size:10px; }
  .change-arrow { width:14px; height:14px; }
  .home-trend { padding:0; }
  .trend-heading { flex-direction:row; align-items:center; flex-wrap:wrap; }
  .trend-heading h2 { font-size:19px; padding-left:10px; border-left-width:4px; }
  .trend-heading p { margin-left:14px; font-size:10px; max-width:210px; }
  .trend-actions { width:auto; margin-left:auto; }
  .trend-segments button { padding:5px 13px; font-size:12px; }
  .trend-actions label select { padding:7px; width:70px; }
  .trend-chart { margin-top:12px; }
  .trend-axis { font-size:17px; }
  .trend-legend { gap:15px; margin-top:8px; }
  .trend-legend small { width:100%; text-align:center; }
  .trend-readout { font-size:10px; }
  .home-bottom { align-items:flex-start; }
  .home-bottom strong { font-size:12px; }
  .home-bottom button { font-size:11px; }
  footer { margin:20px 16px 0; padding:14px 0 20px; font-size:9px; }
}
@media(prefers-reduced-motion:reduce) { * { scroll-behavior:auto; transition:none !important; } }

/* Fidelity correction after comparison with the selected 1487x1058 reference. */
.panel.home-trend { border:0; border-radius:0; }
@media(min-width:1151px) and (min-height:851px) {
  .shell,.shell.home-view { padding-top:48px; }
  .topbar,.home-view .topbar { padding-bottom:36px; }
  .topbar h1,.home-view .topbar h1 { font-size:42px; }
  .home-controls { margin-bottom:42px; }
  .home-controls select { min-height:52px; }
  .home-more-filters > summary { min-height:52px; }
  .home-extra-fields { top:60px; }
  .home-kpis { margin-bottom:44px; }
  .home-kpi { padding-bottom:20px; }
}

/* Final reference typography calibration. */
@media(min-width:1151px) {
  .picc-brand { padding-left:5px; padding-right:5px; }
  .tab { font-size:17px; }
  .home-controls select { font-size:16px; }
  .home-kpi > span { font-size:18px; }
  .home-kpi > small { font-size:14px; }
  .home-kpi strong { font-size:clamp(46px,4.55vw,68px); }
  .metric-unit { font-size:20px; }
  .change-arrow { width:34px; height:34px; }
  .trend-heading h2 { font-size:28px; }
  .trend-axis { font-size:14px; }
}

/* Welcome refinement: generated full-page scenery, crisp independent UI. */
.auth-gate { position:relative; isolation:isolate; min-height:100svh; padding:48px 24px; overflow:hidden; background:#f0f3f6; }
.auth-gate::before { content:""; position:absolute; inset:-10px; z-index:-2; background:url('/static/welcome-scene-v1.webp') center/cover no-repeat; filter:blur(3px); opacity:.70; }
.auth-gate::after { content:""; position:absolute; inset:0; z-index:-1; background:rgba(255,255,255,.18); }
.auth-card { width:100%; max-width:440px; padding:36px 40px 24px; border:1px solid rgba(255,255,255,.9); border-radius:18px; background:rgba(255,255,255,.97); box-shadow:0 22px 65px rgba(35,49,64,.10),0 2px 8px rgba(35,49,64,.03); }
.auth-brand-lockup { padding-bottom:22px; border-bottom:1px solid #edf0f4; margin-bottom:24px; text-align:center; }
.auth-picc-logo { width:198px; max-width:100%; height:auto; margin:0 auto 13px; }
.auth-brand-caption { font-size:11px; letter-spacing:.18em; color:#78818d; }
.auth-title { text-align:center; }
.auth-eyebrow { display:block; margin-bottom:10px; font-size:11px; letter-spacing:.20em; color:#9a6c61; }
.auth-card h1 { font:700 28px/1.35 "Microsoft YaHei","PingFang SC",sans-serif; letter-spacing:.015em; color:#192330; margin:0; }
.auth-card > p { font-size:13px; line-height:1.7; color:#7c8591; margin:10px 0 26px; }
.auth-card .stack-form { gap:17px; }
.auth-card label { gap:8px; font-size:12px; font-weight:600; color:#4c5663; }
.auth-card input { height:48px; border:1px solid #dfe4eb; border-radius:7px; padding:12px 14px; background:#fff; font-size:14px; }
.auth-card input::placeholder { color:#a3aab4; font-size:12px; }
.auth-card .button.primary { min-height:48px; margin-top:5px; border-radius:7px; background:#e8380d; font-size:14px; letter-spacing:.06em; box-shadow:0 5px 14px rgba(232,56,13,.12); }
.auth-card .button.primary:hover { background:#ce2c08; }
.auth-card .button.primary:focus-visible { outline:3px solid #f5b4a4; outline-offset:3px; }
.auth-message { min-height:19px; margin-top:12px; font-size:12px; color:#bc3629; line-height:1.5; }
.auth-assurance { display:flex; justify-content:center; gap:6px; align-items:center; color:#929ba6; font-size:10px; letter-spacing:.06em; margin-top:10px; }
.auth-assurance img { width:14px; height:14px; opacity:.45; }
.auth-signature { position:absolute; bottom:18px; left:20px; right:20px; text-align:center; color:#7e8994; font-size:10px; letter-spacing:.12em; }
@media(max-width:560px) {
 .auth-gate { padding:28px 20px 44px; }
 .auth-gate::before { background-position:25% center; opacity:.58; }
 .auth-card { max-width:390px; padding:28px 27px 22px; border-radius:15px; }
 .auth-brand-lockup { padding-bottom:18px; margin-bottom:20px; }
 .auth-picc-logo { width:185px; }
 .auth-card h1 { font-size:25px; }
 .auth-card > p { font-size:12px; margin-bottom:22px; }
 .auth-eyebrow { font-size:10px; }
 .auth-signature { bottom:12px; font-size:9px; }
}
@media(max-height:700px) {
 .auth-gate { padding-top:24px; padding-bottom:40px; }
 .auth-card { padding-top:24px; padding-bottom:18px; }
 .auth-brand-lockup { padding-bottom:14px; margin-bottom:16px; }
 .auth-card > p { margin-bottom:18px; }
}
