/* MAAC P&L — light executive theme. Visual-only; no business logic changes. */
:root{color-scheme:light;--bg:#f3f8fc;--surface:#fff;--text:#172b42;--secondary:#536a7e;--muted:#8495a5;--border:#dce8f1;--accent:#217aa8;--accent-soft:#eaf5fb;--positive:#168b74;--negative:#d66b72;--radius:11px;--shadow:0 2px 9px rgba(35,77,107,.055);font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;font-feature-settings:"tnum" 1;color:var(--text);background:var(--bg)}
*{box-sizing:border-box}html{min-width:320px}body{margin:0;min-height:100vh}button,select{font:inherit}button{cursor:pointer}button:focus-visible,select:focus-visible,tbody tr:focus-visible{outline:3px solid #9bcee8;outline-offset:2px}button:disabled{opacity:.5;cursor:not-allowed}
.hero{background:linear-gradient(100deg,#e9f5fb 0%,#f5fbfe 62%,#e6f3f7 100%);border-bottom:1px solid #cbdfe9}.hero-inner{max-width:1680px;margin:auto;padding:22px clamp(15px,2vw,32px);display:flex;align-items:center;gap:32px}.brand{display:flex;align-items:center;gap:11px;flex-shrink:0;border-right:1px solid #b8d1de;padding-right:30px;min-height:58px}.mark{font-size:31px;letter-spacing:-6px;color:#209c9e;display:inline-block;margin-right:5px}.brand-type b{display:block;font-size:26px;letter-spacing:-1px;line-height:1;font-weight:850;color:#154568}.brand-type small{display:block;font-size:13px;color:#426e83;margin-top:4px}.headtext{min-width:0}.headtext h1{font-size:clamp(19px,2vw,29px);font-weight:780;line-height:1.2;letter-spacing:-.025em;margin:0;color:#16446a}.heading-divider{color:#a3c5d7}.headtext p{font-size:13px;color:#5c7b90;margin:7px 0 0}.subtitle-divider{padding:0 7px;color:#9bb7c8}
.app-shell{max-width:1680px;margin:auto;padding:14px clamp(12px,1.4vw,24px) 26px}.toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:11px 13px;background:#fff;border:1px solid var(--border);border-radius:10px;box-shadow:var(--shadow);flex-wrap:wrap}.filter-group{display:flex;align-items:center;gap:12px;flex:1 1 650px;flex-wrap:wrap}.toolbar label{display:flex;align-items:center;gap:9px;white-space:nowrap;font-size:12px;font-weight:700;color:#39566d;flex:1 1 145px;min-width:0}.toolbar select{width:100%;min-width:70px;height:35px;padding:0 24px 0 10px;background:#fafdff;border:1px solid #ccdde8;border-radius:7px;color:#294b62;font-size:12px;font-weight:600;outline:0}.toolbar select:focus{border-color:var(--accent);box-shadow:0 0 0 3px #217aa81c}.actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.actions button,.dialoghead button{height:35px;padding:0 12px;background:#fff;border:1px solid #c6dce7;border-radius:7px;color:#315b73;font-size:12px;font-weight:700;white-space:nowrap}.actions button:hover,.dialoghead button:hover{background:#eef8fc}.actions .primary{background:#168c91;color:#fff;border-color:#168c91}.actions .primary:hover{background:#117a80}.actions button span{margin-right:4px}.status{padding:7px 3px 9px;font-size:11px;color:var(--secondary);min-height:29px}.status:before{content:"";display:inline-block;width:6px;height:6px;border-radius:50%;background:#93b7c8;margin-right:7px;vertical-align:middle}.status.error{color:#c94f5b}.status.warn{color:#b57824}
.kpis{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:11px;margin-bottom:14px}.kpi{min-width:0;min-height:116px;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;padding:15px 15px 13px;background:linear-gradient(145deg,#fff,#f1f8fc);border:1px solid #dbeaf2;border-radius:10px;box-shadow:var(--shadow)}.kpi:nth-child(2),.kpi:nth-child(3),.kpi:nth-child(5),.kpi:nth-child(6){background:linear-gradient(145deg,#fff,#f0faf7)}.kpi:nth-child(4){background:linear-gradient(145deg,#fff,#fff5f2)}.kpi .kt{font-size:12px;font-weight:700;color:#355267;line-height:1.3}.kpi .kv{font-size:clamp(21px,2vw,30px);font-weight:800;line-height:1.18;letter-spacing:-.04em;margin:7px 0 5px;color:#19384f;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.kpi .kd{font-size:10px;line-height:1.4;font-weight:600;color:#688092}.kpi .kd.up{color:#168b74}.kpi .kd.down{color:#d66b72}.kpi .kd.muted{color:#8495a5}
.grid{display:grid;gap:12px;margin-bottom:12px}.topcharts{grid-template-columns:minmax(0,1.06fr) minmax(0,.94fr)}.bottomcharts{grid-template-columns:minmax(0,1.04fr) minmax(0,.9fr) minmax(0,1fr)}.panel{min-width:0;overflow:hidden;background:var(--surface);border:1px solid var(--border);border-radius:10px;box-shadow:var(--shadow)}.panel h2{margin:0;min-height:37px;padding:9px 15px;display:flex;align-items:center;justify-content:space-between;gap:10px;background:#e7f2f9;border-bottom:1px solid #d4e6f0;color:#285779;font-size:13px;font-weight:780;line-height:1.3}.panel h2 span{font-size:10px;font-weight:550;color:#6a889a;white-space:nowrap}.panel h2.teal{background:#e3f5f1;color:#19766f;border-bottom-color:#cce9e3}.canvasbox{height:285px;padding:13px 13px 10px;position:relative;min-width:0}.bottomcharts .canvasbox{height:255px}.chartnote{margin:0 14px 9px;min-height:8px;font-size:11px;color:#ae762f}.donutbox{height:230px!important;max-width:340px;margin:auto;padding:13px 18px 0}.costlegend{display:flex;flex-direction:column;gap:7px;padding:7px 18px 14px;font-size:11px;color:#526d80}.costlegend span{line-height:1.5}.insights{padding:10px 15px 12px;max-height:345px;overflow:auto}.insight{padding:12px 0;border-bottom:1px solid #e7f0f5}.insight:last-child{border-bottom:0}.insight b{font-size:12px;font-weight:750;color:#1b6b73}.insight p{font-size:11px;line-height:1.65;color:#526e80;margin:5px 0 0}
.tablepanel{margin-top:12px}.tablewrap{overflow:auto;max-height:520px}table{width:100%;border-collapse:separate;border-spacing:0;white-space:nowrap;font-size:12px;font-variant-numeric:tabular-nums}th,td{padding:10px 13px;text-align:right;border-bottom:1px solid #e5eef4}th{position:sticky;top:0;z-index:2;background:#f0f7fb;color:#355e76;font-size:11px;font-weight:750}td{color:#355066}th:first-child,td:first-child,th:nth-child(2),td:nth-child(2){text-align:left}tbody tr{cursor:pointer}tbody tr:nth-child(even){background:#f9fcfe}tbody tr:hover{background:#edf8fd}tbody td:first-child{font-weight:750;color:#246487}tfoot td{background:#ddf5ef;font-weight:800;color:#176a65;border-bottom:0}.hint{margin:0;padding:10px 14px;font-size:11px;color:#748d9d}#audit{padding:15px;background:#f6fbfd;border-top:1px solid var(--border);font-size:12px;overflow:auto}#audit[hidden]{display:none}footer{max-width:1680px;margin:auto;display:flex;justify-content:space-between;gap:14px;padding:3px clamp(12px,1.4vw,24px) 24px;font-size:11px;color:#6e8798}.footer-dot{padding:0 5px}
dialog{border:1px solid var(--border);border-radius:12px;box-shadow:0 20px 70px #244b6c33;width:min(980px,95vw);max-height:85vh;overflow:auto;padding:22px;color:var(--text)}dialog::backdrop{background:#1c344e80}.dialoghead{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:18px}.dialoghead h2{font-size:17px;margin:0}.validation-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.validation-grid>div{background:#f4f9fc;border:1px solid var(--border);padding:14px;border-radius:8px;font-size:12px;color:var(--secondary)}.validation-grid strong{display:block;font-size:20px;color:var(--text);margin-top:5px}.audit-table{font-size:11px;width:100%;margin-top:15px}.empty{padding:32px;text-align:center;color:var(--muted);font-size:12px}.badgewarn{color:#b57824;font-weight:700}canvas{max-width:100%}
@media(max-width:1370px){.toolbar{align-items:stretch}.filter-group{flex-basis:100%}.toolbar label{flex:1 1 160px}.kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.bottomcharts{grid-template-columns:repeat(2,minmax(0,1fr))}.bottomcharts>.panel:last-child{grid-column:1/-1}}
@media(max-width:860px){.hero-inner{gap:16px}.brand{padding-right:17px}.headtext h1{font-size:20px}.topcharts,.bottomcharts{grid-template-columns:1fr}.bottomcharts>.panel:last-child{grid-column:auto}.actions{width:100%}.actions button{flex:1}.canvasbox{height:280px}}
@media(max-width:540px){.hero-inner{display:block;padding:17px 15px}.brand{border:0;padding:0;margin-bottom:13px}.headtext h1{font-size:20px}.headtext p{font-size:11px}.app-shell{padding:11px 10px 25px}.toolbar{padding:12px}.filter-group{gap:10px}.toolbar label{flex:1 1 calc(50% - 7px);display:flex;flex-direction:column;align-items:stretch;gap:5px}.actions button{flex:1 1 calc(50% - 6px);padding:0 7px}.actions button:last-of-type{flex-basis:100%}.kpis{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.kpi{min-height:107px;padding:12px}.kpi .kv{font-size:23px}.kpi .kd{font-size:9px}.panel h2{font-size:12px;padding:9px 10px}.panel h2 span{font-size:9px}.canvasbox{height:265px;padding:10px 6px}.bottomcharts .canvasbox{height:250px}.donutbox{height:220px!important}.validation-grid{grid-template-columns:1fr}footer{flex-wrap:wrap}}
@media(max-width:370px){.kpis{grid-template-columns:1fr}.kpi{min-height:95px}}
