:root{--ink:#20312e;--muted:#78837f;--green:#176b57;--light:#eaf5ef;--line:#e0e7e2;--red:#b84c41;--orange:#a97424}*{box-sizing:border-box}body{margin:0;font-family:Inter,"Microsoft YaHei",system-ui,sans-serif;background:#f5f7f4;color:var(--ink);font-size:14px}button,input,select,textarea{font:inherit}button,a{touch-action:manipulation}button{cursor:pointer;border:1px solid var(--line);border-radius:7px;background:white;color:var(--ink);padding:9px 14px}button:hover{border-color:#8caf9f;background:#f5faf7}button:disabled{cursor:not-allowed;opacity:.45}.primary{background:var(--green);color:white;border-color:var(--green)}.primary:hover{background:#145844}.danger{color:var(--red)}.small{padding:5px 9px;font-size:12px}.quiet{border:0;background:transparent}.layout{display:grid;grid-template-columns:220px 1fr;min-height:100vh}.sidebar{background:#143e34;color:#c2d3cb;padding:27px 16px;position:fixed;width:220px;height:100vh;overflow:auto}.brand{display:flex;align-items:center;gap:12px;color:white;font-size:20px;font-weight:650;padding:0 12px 30px}.mark{background:#d9edb8;color:#23463a;border-radius:10px;width:37px;height:37px;display:grid;place-items:center;font-size:21px}.nav-caption{color:#84a599;padding:17px 13px 7px;font-size:11px;letter-spacing:2px}.nav button{display:block;width:100%;text-align:left;border:0;background:none;color:#c4d4cc;padding:11px 15px;margin:3px 0;border-radius:7px}.nav button:hover,.nav button.active{background:#2a5749;color:white}.nav-icon{display:inline-block;width:25px;color:#9abea8}.sidebar-footer{margin-top:30px;border-top:1px solid #376154;padding:18px 10px;font-size:12px;line-height:1.8;color:#98b6a5}.workspace{grid-column:2;min-width:0}.topbar{height:82px;background:#fff;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;padding:0 34px;gap:16px}.topbar .crumb{font-size:12px;color:var(--muted)}.top-title{font-weight:600;font-size:16px;margin-top:5px}.top-controls{display:flex;align-items:center;gap:12px}.top-controls select{max-width:300px}.avatar{background:#e9f1df;border-radius:50%;width:34px;height:34px;display:grid;place-items:center;font-weight:600}.main{padding:30px 34px 50px;max-width:1600px;margin:auto}.page-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;margin-bottom:25px}.eyebrow{color:#6e8b7c;font-size:11px;letter-spacing:2px;margin-bottom:8px}h1{font-size:27px;letter-spacing:-.5px;margin:0 0 10px;font-weight:600}h2{font-size:17px;margin:0}p{line-height:1.7}.sub{color:var(--muted);margin:0;font-size:13px}.toolbar{display:flex;gap:9px;align-items:center;flex-wrap:wrap}.demo-banner{background:#fbf4df;border:1px solid #ebdfba;padding:11px 16px;border-radius:8px;font-size:12px;color:#866c37;margin-bottom:22px}.cards{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:17px;margin-bottom:24px}.card,.panel{background:white;border:1px solid var(--line);border-radius:10px;box-shadow:0 3px 10px #173d3103}.card{padding:22px}.card .label{font-size:12px;color:var(--muted)}.card .number{font-size:29px;font-weight:600;letter-spacing:-1px;margin:13px 0 7px}.card .detail{font-size:12px;color:#698578}.panel{margin-bottom:22px}.panel-title{display:flex;align-items:center;justify-content:space-between;padding:19px 22px;border-bottom:1px solid #edf0eb;gap:16px}.panel-body{padding:20px 22px}.grid-two{display:grid;grid-template-columns:1.4fr 1fr;gap:22px}.badge{display:inline-flex;border-radius:20px;padding:4px 9px;font-size:11px;background:#eef2ee;color:#6a786c;white-space:nowrap}.badge.good{background:#e5f4e9;color:#287254}.badge.bad{background:#faece8;color:var(--red)}.badge.warn{background:#fcf3df;color:var(--orange)}.table-scroll{overflow:auto}table{border-collapse:collapse;width:100%;text-align:left;white-space:nowrap}th{padding:12px 16px;color:#7d8980;font-weight:500;font-size:12px;background:#fafcf9;border-bottom:1px solid var(--line)}td{padding:13px 16px;border-bottom:1px solid #edf1eb;font-size:12px}tr:last-child td{border-bottom:0}tbody tr:hover{background:#fbfdf9}.num{font-variant-numeric:tabular-nums;text-align:right}.money-negative{color:var(--red)}.empty{padding:48px 20px;text-align:center;color:var(--muted)}.notice{padding:13px 17px;border-radius:8px;background:#edf4ef;color:#4c6c5b;line-height:1.7;margin:16px 0;font-size:12px}.notice.error{background:#faece8;color:#9c4e41}.status-list{display:grid;gap:13px}.status-row{display:flex;justify-content:space-between;gap:15px;font-size:12px;padding-bottom:11px;border-bottom:1px solid #edf0eb}.bar-chart{height:165px;display:flex;gap:14px;align-items:flex-end;padding-top:20px}.bar-pair{flex:1;display:flex;flex-direction:column;align-items:center;height:100%}.bar-items{flex:1;display:flex;align-items:flex-end;gap:3px;width:100%;justify-content:center}.bar{width:14px;background:#275e4a;border-radius:4px 4px 0 0;min-height:3px}.bar.secondary{background:#c9dec3}.bar-label{font-size:10px;color:#8a958a;margin-top:10px}.legend{font-size:11px;color:var(--muted);display:flex;gap:15px}.dot{display:inline-block;width:7px;height:7px;background:#275e4a;margin-right:6px;border-radius:2px}.dot.light{background:#c9dec3}.filters{display:flex;gap:10px;margin-bottom:22px;align-items:center;flex-wrap:wrap}input,select,textarea{width:100%;padding:10px 11px;border:1px solid #d6dfd6;border-radius:6px;background:white;color:var(--ink);outline:none}input:focus,select:focus,textarea:focus{border-color:var(--green);box-shadow:0 0 0 2px #176b5712}textarea{resize:vertical;min-height:88px}.filters select{width:auto;min-width:130px}.login-wrap{min-height:100vh;display:grid;grid-template-columns:1fr 1fr}.login-brand{background:#163f33;color:white;padding:90px 12%;display:flex;flex-direction:column;justify-content:center}.login-brand h1{font-size:48px;line-height:1.35;margin:25px 0}.login-brand p{color:#afc4b4;max-width:380px}.login-right{display:grid;place-items:center;padding:35px;background:#f5f7f2}.login-box{width:100%;max-width:365px}.login-box h2{font-size:24px;margin-bottom:12px}.login-box label{display:block;margin:20px 0 7px;font-size:12px}.login-box button{width:100%;margin-top:22px}.login-box .secondary-login{margin-top:10px}.loading{padding:100px;text-align:center;color:#7b927f}dialog{padding:0;border:0;border-radius:12px;box-shadow:0 30px 90px #082a343b;width:min(800px,94vw);max-height:90vh}dialog::backdrop{background:#183b3555}.modal-head{padding:22px 27px;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;position:sticky;top:0;background:white;z-index:2}.modal-body{padding:25px 27px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.field label{display:block;font-size:12px;margin-bottom:8px;color:#5f7467}.field.full{grid-column:1/-1}.field .hint{font-size:11px;color:#8a988b;line-height:1.6;margin-top:6px}.modal-footer{display:flex;gap:10px;justify-content:flex-end;padding:19px 27px;border-top:1px solid var(--line);background:#f9fbf7}.code{font-family:Consolas,monospace;font-size:11px}.chips{display:flex;gap:7px;flex-wrap:wrap}.chip{background:#f1f5eb;padding:6px 10px;border-radius:5px;font-size:11px}.progress-line{height:5px;background:#edf2e8;margin-top:12px;border-radius:4px;overflow:hidden}.progress-fill{background:#407b5a;height:100%}.error-box{margin:14px 0;font-size:12px;color:var(--red);line-height:1.7}#toast{position:fixed;right:28px;bottom:26px;background:#173f33;color:white;padding:13px 20px;border-radius:8px;box-shadow:0 8px 30px #1c3d3330;display:none;z-index:20;max-width:460px;line-height:1.7}.split-note{padding:10px 16px;color:#7d8980;font-size:11px;border-top:1px solid #edf0eb}details{grid-column:1/-1;border:1px solid var(--line);padding:12px;border-radius:6px;font-size:12px}details summary{cursor:pointer;color:#587061;margin-bottom:10px}.check-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:9px}.check-grid label{display:flex;gap:8px;align-items:center;font-size:12px}.check-grid input{width:auto}.master-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:18px}.master-tabs .selected{background:#dceee2;color:#175840;border-color:#b4d2be}.user-line{display:flex;align-items:center;gap:10px;font-size:12px}.warning-text{color:#a27839}.right-note{font-size:11px;color:#8a958a}.node-label{padding:8px;background:#f6f9f1;border-radius:5px;font-size:12px;margin:6px 0}@media(max-width:1100px){.cards{grid-template-columns:repeat(2,1fr)}.grid-two{grid-template-columns:1fr}.topbar{padding:0 22px}.main{padding:24px 22px}.top-controls .user-name{display:none}}@media(max-width:760px){.layout{grid-template-columns:70px 1fr}.sidebar{width:70px;padding:20px 8px}.brand{padding:0 8px 20px}.brand span:last-child,.nav .nav-text,.nav-caption,.sidebar-footer{display:none}.nav button{padding:12px}.nav-icon{width:auto}.main{padding:20px 13px}.topbar{padding:0 13px}.top-title{font-size:13px}.top-controls{gap:7px}.top-controls select{max-width:180px}.cards{gap:10px}.card{padding:16px}.card .number{font-size:22px}.form-grid{grid-template-columns:1fr}.field.full{grid-column:auto}.login-wrap{grid-template-columns:1fr}.login-brand{display:none}.page-heading{flex-direction:column}.check-grid{grid-template-columns:1fr 1fr}}

.excel-file{margin-top:20px;margin-bottom:20px}#excel-result h3{font-size:14px;margin-top:22px}#excel-result td:last-child{white-space:normal;min-width:160px}#excel-errors[hidden]{display:none}
.allocation-row{border:1px solid var(--line);border-radius:8px;padding:16px;margin:14px 0}.allocation-row>.toolbar{justify-content:space-between;margin-bottom:12px}[data-department-group]>.hint{margin-bottom:12px}

.execution-cost-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.execution-cost-card{border:1px solid var(--line);border-radius:10px;padding:14px}.execution-cost-card h4{margin:0 0 8px}.execution-cost-card output{display:block;padding:10px 12px;background:#f0f5f2;border-radius:6px;min-height:40px}.execution-cost-card .field{margin-top:12px}@media(max-width:640px){.execution-cost-grid{grid-template-columns:1fr}}

.derived-value{display:block;padding:10px 12px;background:#f0f5f2;border-radius:6px;min-height:40px;font-weight:600}

.payroll-sections .panel-title{flex-wrap:wrap}.payroll-sections .panel-title h2{flex-shrink:0}.payroll-sections .panel-title .toolbar{flex:1;justify-content:flex-end}.payroll-sections button{white-space:nowrap}@media(max-width:760px){.payroll-sections .panel-title h2{width:100%}.payroll-sections .panel-title .toolbar{justify-content:flex-start}}
.budget-view-tabs{display:flex;gap:8px;border-bottom:1px solid var(--line);margin:0 0 22px;padding-bottom:12px}.budget-view-tabs .selected{background:var(--green);color:white}.budget-view-tabs button{min-width:110px}.summary-controls{display:flex;flex-wrap:wrap;gap:14px}.summary-controls label{font-size:12px;color:var(--muted);min-width:150px;flex:1;max-width:250px}.summary-controls select{margin-top:7px}.summary-kpis{display:flex;gap:16px;flex-wrap:wrap;margin:20px 0}.summary-kpis>div{flex:1;min-width:155px;background:#f1f6f1;border-radius:8px;padding:15px}.summary-kpis span{display:block;font-size:12px;color:var(--muted)}.summary-kpis strong{display:block;font-size:22px;margin-top:10px;font-weight:600}.summary-tabs{display:flex;gap:8px;flex-wrap:wrap;margin:16px 0}.summary-note{font-size:12px;color:var(--muted);line-height:1.8}.summary-table .table-scroll{max-height:460px}.summary-table th{position:sticky;top:0;z-index:1}.budget-summary .panel-title{flex-wrap:wrap}@media(max-width:760px){.budget-summary .panel-body{padding:16px}.summary-controls label{max-width:none;min-width:120px}.summary-kpis>div{min-width:130px}.summary-kpis strong{font-size:19px}}

.permission-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.permission-filters{display:flex;flex-wrap:wrap;gap:12px;align-items:end}.permission-filters label{font-size:12px;min-width:130px;max-width:240px;flex:1}.permission-filters input,.permission-filters select{margin-top:7px}.permission-filters .permission-search{min-width:230px}.permission-table{max-height:520px}.permission-table table{table-layout:fixed;min-width:930px;white-space:normal}.permission-table th{position:sticky;top:0;z-index:1;background:#f4f8f2}.permission-table td{vertical-align:top;line-height:1.7;overflow-wrap:anywhere}.permission-table th:nth-child(1){width:75px}.permission-table th:nth-child(2){width:90px}.permission-table th:nth-child(3){width:60px}.permission-table th:nth-child(4){width:225px}.permission-table th:nth-child(5){width:85px}.permission-table th:nth-child(6){width:165px}.permission-table th:nth-child(7){width:230px}.permission-table .hint{color:var(--muted);font-size:11px;margin-top:8px}.grant-summary+.grant-summary{border-top:1px dashed var(--line);padding-top:8px;margin-top:8px}.deny-text{color:var(--red)}#grant-editor-list{max-height:380px;overflow:auto;margin:16px 0}details.grant-editor-row{margin:8px 0;padding:12px}.grant-editor-row summary{line-height:1.7;margin:0;overflow-wrap:anywhere}.grant-editor-row[hidden]{display:none}.grant-editor-row code{display:block;color:var(--muted)}.grant-editor-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:16px}.grant-editor-fields .grant-permission{grid-column:1/-1}.grant-editor-fields label{font-size:12px}.grant-editor-fields input,.grant-editor-fields select{margin-top:7px}.grant-editor-fields .grant-delegable{display:flex;align-items:center;gap:8px}.grant-delegable input{width:auto;margin:0}.permission-editor-help p{overflow-wrap:anywhere;line-height:1.8}.permission-editor-help details{margin-bottom:14px}@media(max-width:760px){.permission-kpis{grid-template-columns:1fr}.permission-filters label{max-width:none}.grant-editor-fields{grid-template-columns:1fr}.grant-editor-fields .grant-permission{grid-column:auto}}

.simple-role-table table{table-layout:fixed;white-space:normal}.simple-role-table th:first-child{width:24%}.simple-role-table th:last-child{width:110px}.simple-role-table td{vertical-align:top;line-height:1.8}.simple-role-table .chips{gap:6px}.simple-role-table .chip{font-size:11px}.advanced-permission-catalog{margin-top:20px;background:white;padding:18px}.advanced-permission-catalog>summary{margin:0}.advanced-permission-catalog[open]>summary{margin-bottom:18px}.advanced-permission-catalog .toolbar{margin-bottom:18px}.simple-help{font-size:13px;line-height:1.8;margin:0 0 16px}.simple-permission-scope{background:#f2f6f0;border-radius:8px;padding:14px;margin-bottom:16px}.simple-permission-scope select{max-width:100%}.simple-permission-scope .hint{margin:8px 0 0}.simple-permission-table{max-height:420px}.simple-permission-table table{white-space:normal}.simple-permission-table th{position:sticky;top:0;background:#f4f8f2;z-index:1}.simple-permission-table th:first-child{width:58%}.simple-permission-table td{padding:10px 14px}.simple-permission-table td strong{font-size:12px;font-weight:500}.simple-permission-table label{display:flex;align-items:center;gap:7px;margin:0;font-size:11px}.simple-permission-table input{width:17px;height:17px;margin:0;accent-color:#275e4a}.simple-permission-table .hint{margin-top:3px}.simple-permission-editor>button{margin-top:4px}

dialog:has(.simple-permission-editor) #editor{display:flex;flex-direction:column;max-height:90vh}dialog:has(.simple-permission-editor) .modal-head,dialog:has(.simple-permission-editor) .modal-footer{flex-shrink:0}dialog:has(.simple-permission-editor) .modal-body{flex:1;min-height:0;overflow:auto}

.subject-tree{padding-left:calc(var(--subject-depth,0) * 20px)}.subject-tree-2,.subject-tree-3,.subject-tree-4{padding-left:calc(var(--subject-depth,0) * 20px)}.subject-tree-4{color:#5e6c65}.subject-branch{width:18px}.subject-toggle{width:18px;height:18px;padding:0;border:1px solid #b9d0c2;border-radius:50%;background:#fff;color:#176b57;line-height:15px;font-size:14px;cursor:pointer}.subject-toggle:hover{background:#eaf4ed;border-color:#176b57}.subject-toggle-placeholder{display:inline-block;width:18px;height:18px}
.profit-drilldown-toolbar{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin-bottom:14px}.profit-drilldown-toolbar label{display:flex;align-items:center;gap:8px;font-size:12px;color:#5f7467}.profit-drilldown-toolbar select{width:auto;min-width:130px}.profit-drilldown-table{max-height:460px}.profit-drilldown-table table{min-width:720px}.profit-drilldown-table td:nth-child(n+3),.profit-drilldown-table th:nth-child(n+3){text-align:right;font-variant-numeric:tabular-nums}
.cash-forecast-table .cash-drilldown{padding:0;border:0;background:transparent;color:#718177;font-size:12px}.cash-forecast-table .cash-drilldown:hover{background:transparent;color:var(--green);text-decoration:underline}.cash-drilldown-toolbar{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin-bottom:14px}.cash-drilldown-toolbar label{display:flex;align-items:center;gap:8px;font-size:12px;color:#5f7467}.cash-drilldown-toolbar select{width:auto;min-width:130px}.cash-drilldown-table{max-height:460px}.cash-drilldown-table table{min-width:980px}.cash-drilldown-table td:nth-child(n+4),.cash-drilldown-table th:nth-child(n+4){text-align:right;font-variant-numeric:tabular-nums}

.subject-result-table{max-height:650px}.subject-result-table table{min-width:1180px}.subject-result-table th{position:sticky;top:0;z-index:1;background:#f4f8f2}.subject-result-table td{vertical-align:middle}.subject-result-table th:nth-child(1),.subject-result-table td:nth-child(1){width:58px;text-align:center}.subject-result-table th:nth-child(2),.subject-result-table td:nth-child(2){width:72px;text-align:center}.subject-result-table th:nth-child(3){min-width:205px}.subject-result-table th:nth-child(4){min-width:230px}.subject-result-table td:nth-child(n+5){font-variant-numeric:tabular-nums;text-align:right}.subject-level{display:inline-flex;min-width:34px;justify-content:center;border-radius:12px;padding:4px 7px;font-size:11px;font-weight:600}.subject-level-1{background:#dceee2;color:#175840}.subject-level-2{background:#eef3df;color:#6b6f2b}.subject-level-3{background:#f7eee0;color:#91662a}.subject-code{font-family:Consolas,"Microsoft YaHei",monospace;font-size:12px;font-weight:600}.subject-code-1{color:#175840}.subject-code-2{color:#5b6d2d}.subject-code-3{color:#91662a}.subject-tree{display:flex;align-items:center;gap:9px;min-height:22px;line-height:1.5;font-weight:500}.subject-tree-1{font-weight:700;color:#173f33}.subject-tree-2{padding-left:18px;color:#344b43}.subject-tree-3{padding-left:38px;color:#5e6c65}.subject-branch{display:inline-flex;width:14px;justify-content:center;font-size:11px;color:#7d9c8d}.subject-tree-1 .subject-branch{color:#176b57}.subject-result-table tbody tr:has(.subject-tree-1){background:#f7fbf7}.subject-result-table tbody tr:has(.subject-tree-1) td{border-top:1px solid #dce8df}.subject-result-table tbody tr:has(.subject-tree-2):hover,.subject-result-table tbody tr:has(.subject-tree-3):hover{background:#fbfdf9}
 .subject-select-tree{border:1px solid #d6dfd6;border-radius:8px;background:#fbfdf9;padding:8px 12px;max-height:300px;overflow:auto}.subject-select-node{position:relative;padding:4px 0}.subject-select-node label{display:flex;align-items:center;gap:8px;margin:0;padding:7px 9px;border-radius:6px;color:#30483e}.subject-select-node label:hover{background:#eef6ef}.subject-select-node input{width:auto;margin:0}.subject-select-level-1>label{font-weight:700;color:#173f33}.subject-select-level-2>label{font-weight:600;color:#4d633f}.subject-select-level-3>label{color:#5e6c65}.subject-select-children{margin-left:22px;border-left:1px solid #d5e4d8;padding-left:12px}.subject-select-code{min-width:92px;font-family:Consolas,"Microsoft YaHei",monospace;font-size:11px;color:#7b8d82}
 .department-select-tree{border:1px solid #d6dfd6;border-radius:8px;background:#fbfdf9;padding:8px 12px;max-height:360px;overflow:auto}.department-select-node{position:relative;padding:4px 0}.department-select-node label{display:flex;align-items:center;gap:8px;margin:0;padding:7px 9px;border-radius:6px;color:#30483e}.department-select-node label:hover{background:#eef6ef}.department-select-node input{width:auto;margin:0}.department-select-level-1>label{font-weight:700;color:#173f33}.department-select-level-2>label{font-weight:650;color:#315b48}.department-select-level-3>label{color:#4d6d5c}.department-select-level-4>label{color:#687d72}.department-select-children{margin-left:22px;border-left:1px solid #d5e4d8;padding-left:12px}.department-select-code{min-width:76px;font-family:Consolas,"Microsoft YaHei",monospace;font-size:11px;color:#7b8d82}
.permission-tabs{display:flex;gap:8px;margin:0 0 16px;border-bottom:1px solid var(--line)}.permission-tabs button{border:0;border-bottom:3px solid transparent;border-radius:0;background:transparent;color:var(--muted);padding:10px 18px;font-weight:600}.permission-tabs button:hover{color:var(--ink);background:#f2f6f0}.permission-tabs button.active{color:var(--green);border-bottom-color:var(--green);background:#f2f6f0}
.brand .mark{width:148px;height:42px;flex:0 0 148px;background:transparent url('/assets/xiaoti-logo.png?v=20261018-1') center/contain no-repeat;border-radius:0;color:transparent;font-size:0}.sidebar .brand>span:last-child,.login-brand .brand>span:last-child{display:none}.login-brand .brand{padding:0}.login-brand .brand .mark{width:280px;height:68px;flex-basis:280px}
button{min-height:38px;padding:8px 14px;border-radius:8px;line-height:20px;font-weight:500}button.small{min-height:32px;padding:5px 10px;font-size:12px}button.quiet{min-height:32px;padding:5px 9px}input,select,textarea{min-height:38px;padding:9px 12px;border-radius:8px;line-height:20px}textarea{min-height:100px}.panel,.card{border-radius:12px}.panel-title{min-height:62px;padding:16px 22px}.panel-body{padding:20px 22px}th{height:44px;padding:11px 16px}td{height:46px;padding:11px 16px}.field label{font-weight:500}.toolbar{gap:10px}.permission-pager{justify-content:flex-end;margin-top:12px}.permission-pager .hint{margin-right:auto}
