*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif;background:#f4f6f8;color:#17212b;font-size:14px}.shell{min-height:100vh;display:grid;grid-template-columns:220px 1fr}.side{background:#101820;color:#eef3f5;padding:18px 12px;display:flex;flex-direction:column}.brand{display:flex;gap:10px;align-items:center;padding:2px 8px 24px}.brandmark{width:34px;height:34px;border:1px solid #52606a;border-radius:9px;display:grid;place-items:center;font-weight:800;font-size:12px}.brand div{display:flex;flex-direction:column}.brand small,.sidefooter{color:#8fa0aa}.side nav{display:flex;flex-direction:column;gap:3px}.nav{border:0;background:transparent;color:#b8c4ca;text-align:left;padding:10px;border-radius:7px;cursor:pointer}.nav:hover,.nav.active{background:#1c2933;color:#fff}.sidefooter{margin-top:auto;font-size:12px;padding:10px}.dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:#5ed49a;margin-right:6px}main{padding:24px 28px;min-width:0}header{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:20px}h1{margin:0;font-size:23px}header p{margin:5px 0 0;color:#73808a;font-size:13px}.toolbar{display:flex;gap:8px;align-items:center}.toolbar select{min-width:250px}.view{display:none}.view.active{display:block}button,input,select{font:inherit}.ghost,.primary,.smallbtn{height:36px;border-radius:7px;padding:0 12px;cursor:pointer}.ghost,.smallbtn{border:1px solid #d5dde2;background:#fff;color:#26343d}.ghost:hover,.smallbtn:hover{background:#f7f9fa}.primary{border:1px solid #17212b;background:#17212b;color:#fff;font-weight:600}.primary.small,.ghost.small{height:32px;font-size:12px}.primarylite{background:#eef7fa;border-color:#b8dce7;color:#15566b}.stats{display:grid;grid-template-columns:repeat(7,minmax(110px,1fr));gap:8px;margin-bottom:12px}.stat{border:1px solid #e0e6ea;background:#fff;border-radius:8px;padding:12px;text-align:left;cursor:pointer}.stat:hover{border-color:#bcc9d0}.stat strong{font-size:23px;display:block}.stat span{color:#6f7c85;font-size:12px}.panel{background:#fff;border:1px solid #dde4e8;border-radius:9px;overflow:hidden;margin-bottom:14px}.panelhead{min-height:58px;padding:10px 14px;display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid #e9edef}.panelhead>div,.sectionline>div,.configbar>div{display:flex;flex-direction:column;gap:2px}.panelhead small,.sectionline small,.configbar small{color:#7d8992}.tablewrap{overflow:auto}table{border-collapse:collapse;width:100%;font-size:12.5px}th{background:#fafbfc;color:#64717b;font-weight:600;text-align:left;padding:10px 12px;border-bottom:1px solid #e5eaed;white-space:nowrap}td{padding:10px 12px;border-bottom:1px solid #edf0f2;vertical-align:middle}tbody tr:last-child td{border-bottom:0}tr.clickable:hover{background:#f7f9fa;cursor:pointer}.pill{display:inline-flex;align-items:center;font-size:10.5px;line-height:1;padding:4px 7px;border:1px solid #d7dee2;border-radius:20px;background:#fafbfc;white-space:nowrap}.pill.bad{border-color:#e9b8b8;background:#fff7f7}.pill.warn{border-color:#e4d09e;background:#fffbef}.pill.ok{border-color:#b6dcc6;background:#f5fff9}.muted{color:#7b8790;font-size:11.5px}.actions{display:flex;gap:5px;flex-wrap:wrap}.smallbtn{height:29px;padding:0 8px;font-size:11.5px}.errorcell{max-width:260px;overflow:hidden;text-overflow:ellipsis;color:#a94e54}.configbar{background:#fff;border:1px solid #dde4e8;border-radius:9px;padding:12px 14px;display:flex;align-items:center;justify-content:space-between;gap:16px}.configbar select{min-width:340px}.tabs{display:flex;gap:3px;border-bottom:1px solid #dfe5e9;margin-top:14px}.tab{border:0;background:transparent;padding:11px 14px;color:#66747e;cursor:pointer;border-bottom:2px solid transparent}.tab.active{color:#17212b;border-bottom-color:#17212b;font-weight:600}.tabpane{display:none;background:#fff;border:1px solid #dde4e8;border-top:0;border-radius:0 0 9px 9px;padding-bottom:14px}.tabpane.active{display:block}.sectionline{padding:14px;display:flex;align-items:center;justify-content:space-between;gap:14px;border-bottom:1px solid #edf0f2}.sectionline.topgap{margin-top:18px;border-top:1px solid #e4e9ec}.formrows{display:grid;gap:10px;padding:14px}.formrows.three{grid-template-columns:repeat(3,minmax(0,1fr))}.formrows.two{grid-template-columns:repeat(2,minmax(0,1fr));padding:0}.formrows label,.actionrow label,.autoline label,.drawerform label{display:flex;flex-direction:column;gap:5px;font-size:11.5px;color:#66737c}input,select{height:36px;border:1px solid #d4dce1;border-radius:7px;background:#fff;color:#25333c;padding:0 10px;outline:none}input:focus,select:focus{border-color:#8fb7c7;box-shadow:0 0 0 2px rgba(52,137,169,.08)}.configtable{padding:0 14px 12px}.configtable table{border:1px solid #e4e9ec}.tableinput{width:100%;min-width:170px;height:31px;border-radius:5px}.mappingrow select{height:31px;min-width:100px}.mappingrow input[type=checkbox]{height:auto}.actionrow{display:flex;align-items:flex-end;gap:8px;padding:14px;flex-wrap:wrap}.actionrow label{min-width:180px}.actionrow .wide{min-width:420px;flex:1}.summaryline{display:flex;gap:22px;padding:10px 14px;background:#f9fafb;border-bottom:1px solid #eceff1;font-size:12px;flex-wrap:wrap}.automationgrid{padding:0 14px}.autoline{display:grid;grid-template-columns:210px minmax(260px,1fr) 180px 150px;gap:12px;align-items:end;padding:14px 0;border-bottom:1px solid #edf0f2}.autoline:last-child{border-bottom:0}.switchline{display:flex!important;flex-direction:row!important;align-items:center!important;gap:8px!important;color:#24323a!important;font-weight:600}.switchline input{height:auto;width:auto}.readonly{display:flex;align-items:center;min-height:36px;padding:0 10px;background:#f5f7f8;border:1px solid #e0e6e9;border-radius:7px;color:#6e7a82;font-size:11px}.emptyline{padding:22px;color:#7a8790;text-align:center;border:1px dashed #d5dde2;border-radius:8px;margin-top:14px}.hidden{display:none!important}.testlayout{display:grid;grid-template-columns:minmax(360px,.75fr) minmax(520px,1.25fr);gap:14px;padding:14px}.testlayout>div{border:1px solid #e2e7ea;border-radius:8px;overflow:auto}.testdetail{min-height:320px}.testhead{display:flex;justify-content:space-between;align-items:center;padding:13px;border-bottom:1px solid #e5eaed}.testhead>div{display:flex;flex-direction:column;gap:3px}.steps{padding:6px 12px}.step{display:grid;grid-template-columns:30px 1fr auto;gap:10px;padding:11px 0;border-bottom:1px solid #edf0f2}.step:last-child{border-bottom:0}.stepnum{width:24px;height:24px;border-radius:50%;display:grid;place-items:center;background:#eef2f4;font-size:11px}.step p{margin:4px 0;color:#6f7c85;font-size:12px}.step details{margin-top:6px}.step pre{max-height:220px;overflow:auto;background:#f7f9fa;padding:9px;border-radius:6px;font-size:11px;white-space:pre-wrap}.drawer{position:fixed;inset:0;background:rgba(8,15,20,.36);display:none;justify-content:flex-end;z-index:2000}.drawer.open{display:flex}.drawerbox{width:min(700px,94vw);height:100%;background:#fff;padding:22px;overflow:auto;position:relative;box-shadow:-20px 0 60px rgba(0,0,0,.16)}.drawerbox.narrow{width:min(640px,94vw)}.x{position:absolute;right:14px;top:10px;border:0;background:transparent;font-size:28px;cursor:pointer;color:#6e7b83}.drawerhead{padding-right:35px;margin-bottom:18px}.drawerhead h2{margin:0 0 5px}.drawerhead p{margin:0;color:#74818a}.drawerform{display:flex;flex-direction:column;gap:18px}.formgroup{border-top:1px solid #e5eaed;padding-top:14px}.formgroup>strong{display:block;margin-bottom:10px}.draweractions{display:flex;justify-content:flex-end;gap:8px;padding-top:8px}.keyline{font-family:ui-monospace,SFMono-Regular,Consolas,monospace;background:#f5f7f8;border:1px solid #e1e6e9;padding:8px;border-radius:6px;word-break:break-all}.detailgrid{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:14px 0}.detailgrid span{display:flex;flex-direction:column;gap:4px}.timeline{margin-top:14px;border-left:2px solid #e3e8eb;padding-left:14px}.event{padding:4px 0 13px}.event strong{display:block}.topgap{margin-top:10px}.toast-stack{position:fixed;right:20px;top:20px;z-index:3000;display:flex;flex-direction:column;gap:8px;pointer-events:none}.toast{min-width:280px;max-width:430px;background:#17212b;color:#fff;border:1px solid #35434e;border-radius:9px;padding:11px 13px;box-shadow:0 14px 38px rgba(0,0,0,.18);opacity:0;transform:translateY(-8px);transition:.2s ease;font-size:12px}.toast.show{opacity:1;transform:translateY(0)}.toast.success{border-color:#3e8f68}.toast.error{border-color:#b94d55}.toast.info{border-color:#4f7f98}
/* login próprio */.login-page{min-height:100vh;background:#0f171e;color:#edf3f6}.login-shell{min-height:100vh;display:grid;place-items:center;padding:28px}.login-card{width:min(440px,100%);background:#151f27;border:1px solid #2a3944;border-radius:15px;padding:30px;box-shadow:0 28px 80px rgba(0,0,0,.3)}.login-brand{display:flex;align-items:center;gap:12px;margin-bottom:28px}.login-brand>div{display:flex;flex-direction:column}.login-brand small{color:#8fa1ad}.login-copy h1{font-size:24px;margin:0 0 8px}.login-copy p{color:#9cabb5;font-size:14px;line-height:1.45;margin:0 0 24px}.login-form{display:grid;gap:15px}.login-form label{font-size:12px;color:#aebbc4;display:grid;gap:6px}.login-form input{width:100%;height:44px;background:#1b2832;border:1px solid #344650;color:#f5f8fa}.password-field{position:relative}.password-field input{padding-right:82px}.iconbtn{position:absolute;right:6px;top:6px;height:32px;border:0;background:transparent;color:#8fc7dc;cursor:pointer;padding:0 8px}.remember{display:flex!important;grid-template-columns:auto 1fr!important;align-items:center;gap:8px!important}.remember input{width:auto;height:auto}.login-form .primary{height:44px}.form-status{min-height:18px;color:#ffb0b5;font-size:12px}.login-page .brandmark{border-color:#3c5563;background:#1b2a34;color:#8ee0fa}
@media(max-width:1180px){.stats{grid-template-columns:repeat(4,1fr)}.formrows.three{grid-template-columns:1fr 1fr}.autoline{grid-template-columns:1fr 1fr}.testlayout{grid-template-columns:1fr}.toolbar select{min-width:180px}}@media(max-width:850px){.shell{grid-template-columns:1fr}.side{display:none}main{padding:16px}.stats{grid-template-columns:repeat(2,1fr)}header{flex-direction:column}.toolbar{width:100%;flex-wrap:wrap}.toolbar select{flex:1}.formrows.three,.formrows.two{grid-template-columns:1fr}.configbar{align-items:flex-start;flex-direction:column}.configbar select{width:100%;min-width:0}.tabs{overflow:auto}.actionrow .wide{min-width:240px}.autoline{grid-template-columns:1fr}.detailgrid{grid-template-columns:1fr}}

/* V1.0.6 — grade operacional de NF-e */
.mini-svg{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;display:block}
.state-label{display:inline-flex;align-items:center;gap:7px;white-space:nowrap;font-size:11.5px;font-weight:600;color:#53616a}.state-icon{width:25px;height:25px;border-radius:7px;display:grid;place-items:center;background:#f1f4f6;border:1px solid #e1e6e9}.state-label.warn{color:#8a641d}.state-label.warn .state-icon{background:#fff9e9;border-color:#ead7a6}.state-label.bad{color:#a2464c}.state-label.bad .state-icon{background:#fff5f5;border-color:#edc1c4}.state-label.ok{color:#28704e}.state-label.ok .state-icon{background:#f2fbf6;border-color:#bddfc9}.state-label.info{color:#356a80}.state-label.info .state-icon,.state-label.accent .state-icon{background:#f0f8fb;border-color:#bedce7}.state-label.accent{color:#19637e}
.data-badge{display:inline-flex;align-items:center;min-height:23px;padding:0 8px;border-radius:999px;border:1px solid #dce3e7;background:#f7f9fa;color:#5e6b73;font-size:10.5px;font-weight:600;white-space:nowrap}.data-badge.ok{background:#f3fbf6;border-color:#bfe0cc;color:#2c7351}.data-badge.bad{background:#fff5f5;border-color:#e9c0c3;color:#a2474e}.data-badge.warn{background:#fff9eb;border-color:#ead6a2;color:#84601c}.data-badge.info{background:#f1f8fb;border-color:#bfdde8;color:#326a80}.data-badge.neutral{background:#f7f9fa;color:#67747c}
.nfe-table{max-width:100%;border-top:0}.nfe-table table{min-width:1760px}.nfe-table th{font-size:11px;text-transform:none;letter-spacing:.01em;position:sticky;top:0;z-index:2}.nfe-table td{padding-top:9px;padding-bottom:9px}.nfe-table .status-cell{min-width:180px}.nfe-table .num-cell{font-variant-numeric:tabular-nums}.nfe-table .party-cell{min-width:225px;max-width:285px}.party-cell>span{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-weight:500}.party-cell small{display:block;margin-top:3px;color:#8a959c;font-size:10.5px}.date-cell,.datetime-cell,.value-cell{white-space:nowrap;font-variant-numeric:tabular-nums}.datetime-cell{min-width:142px}.value-cell{text-align:right;font-weight:600}.nature-cell{min-width:210px;max-width:310px}.nature-cell span{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.doc-head{display:flex;justify-content:space-between;gap:18px;align-items:flex-start;padding-right:34px;margin-bottom:12px}.doc-head h2{margin:3px 0 0}.doc-head h2 small{font-size:12px;color:#77848c;font-weight:500;margin-left:7px}.eyebrow{text-transform:uppercase;letter-spacing:.08em;font-size:9.5px;color:#8a969d;font-weight:700}.doc-badges{display:flex;gap:6px;flex-wrap:wrap;margin:11px 0 4px}.detailgrid-wide{grid-template-columns:1fr 1fr 1fr}.detailgrid span small{display:block;color:#8a959c;font-size:10.5px}.detailgrid .detailwide{grid-column:1/-1}.detailgrid b{font-size:10.5px;color:#748089;text-transform:uppercase;letter-spacing:.04em}
@media(max-width:1050px){.detailgrid-wide{grid-template-columns:1fr 1fr}}@media(max-width:720px){.detailgrid-wide{grid-template-columns:1fr}.doc-head{flex-direction:column}.nfe-table table{min-width:1600px}}

/* V1.0.7 — dashboard, usuários, avisos, auditoria e exclusão segura */
.perm-hidden{display:none!important}.panelactions{display:flex;align-items:center;gap:8px}.panelactions input{min-width:320px}.noticebtn{position:relative;width:38px;height:36px;border:1px solid #d4dce1;border-radius:8px;background:#fff;color:#65737c;cursor:pointer;display:grid;place-items:center;font-weight:800}.noticebtn b{position:absolute;right:-5px;top:-7px;min-width:18px;height:18px;padding:0 4px;border-radius:999px;background:#70808a;color:#fff;border:2px solid #f4f6f7;font-size:9px;display:grid;place-items:center}.noticebtn.has-notice{border-color:#e2b5b8;color:#a53f46;background:#fff8f8}.noticebtn.has-notice b{background:#b3444c}.userchip{display:inline-flex;align-items:center;height:34px;padding:0 10px;border:1px solid #dce3e7;border-radius:999px;background:#fff;color:#5c6870;font-size:11px;white-space:nowrap}
.dashboard-grid{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(320px,.75fr);gap:14px;margin-top:14px}.compact-panel{min-width:0}.activity-row{width:100%;display:grid;grid-template-columns:auto 1fr;gap:10px;align-items:start;text-align:left;border:0;border-bottom:1px solid #edf0f2;background:#fff;padding:12px 14px;cursor:pointer;color:#26343c}.activity-row:last-child{border-bottom:0}.activity-row:hover{background:#f8fafb}.activity-row strong{display:block;font-size:11.5px;margin-bottom:4px}.activity-row small{display:block;color:#87939a;font-size:10.5px}.emptyline.compact{margin:12px;padding:14px}.compact-table table{min-width:680px}.active-filter{background:#17212b!important;color:#fff!important;border-color:#17212b!important}
.deleted-row{opacity:.72;background:#fbf7f7}.deleted-note{display:flex;flex-direction:column;gap:5px;margin:12px 0;padding:11px 12px;border:1px solid #e5bfc2;background:#fff7f7;border-radius:8px;color:#8d3f45}.document-actions{justify-content:flex-start;border-top:1px solid #edf0f2;margin-top:12px}.document-actions button{display:inline-flex;align-items:center;gap:7px}.dangerlite{color:#a4434a!important;border-color:#dfb9bd!important;background:#fffafa!important}.danger{height:36px;border:1px solid #a8434a;background:#a8434a;color:#fff;border-radius:7px;padding:0 14px;font-weight:600;cursor:pointer}.danger:hover{filter:brightness(.96)}
.detailscell{max-width:420px;white-space:normal;line-height:1.45}.modal{position:fixed;inset:0;background:rgba(8,15,20,.42);z-index:3500;display:none;align-items:center;justify-content:center;padding:18px}.modal.open{display:flex}.modalbox{width:min(560px,96vw);background:#fff;border-radius:12px;box-shadow:0 28px 80px rgba(0,0,0,.22);padding:22px;position:relative}.modalhead{padding-right:32px}.modalhead h2{margin:0 0 8px;font-size:19px}.modalhead p{margin:0;color:#69767e;line-height:1.5;font-size:12px}.modalfield{display:flex;flex-direction:column;gap:7px;margin-top:18px;font-size:11.5px;color:#64717a}.modalfield textarea{resize:vertical;min-height:92px;border:1px solid #d4dce1;border-radius:8px;padding:10px;font:inherit;color:#26343c;outline:none}.modalfield textarea:focus{border-color:#8fb7c7;box-shadow:0 0 0 2px rgba(52,137,169,.08)}.modalactions{display:flex;justify-content:flex-end;gap:8px;margin-top:18px}.form-error{min-height:17px;color:#ad4048;font-size:11px;margin-top:8px}
.checkgrid{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-top:10px}.checkrow{display:flex!important;flex-direction:row!important;align-items:flex-start!important;gap:9px!important;padding:9px;border:1px solid #e2e7ea;border-radius:7px;background:#fafbfc;color:#27353d!important}.checkrow input{height:auto;width:auto;margin-top:2px}.checkrow span{display:flex;flex-direction:column;gap:2px;font-size:11.5px}.checkrow small{color:#8a969d;font-size:9.5px}.permissions-grid{max-height:300px;overflow:auto;padding-right:4px}.disabled-zone{opacity:.45;pointer-events:none}.formgroup>p{margin:-4px 0 8px}.audit-details{font-family:ui-monospace,SFMono-Regular,Consolas,monospace}
@media(max-width:1100px){.dashboard-grid{grid-template-columns:1fr}.checkgrid{grid-template-columns:1fr}.panelactions input{min-width:220px}}@media(max-width:850px){.userchip{display:none}.panelactions{width:100%;flex-wrap:wrap}.panelactions input{flex:1;min-width:180px}}

/* V1.0.8 — layout firme, dashboard compacto e rolagem interna */
html,body{height:100%;min-height:0;overflow:hidden}.shell{height:100vh;min-height:0;overflow:hidden;grid-template-columns:210px minmax(0,1fr)}.side{height:100vh;min-height:0;overflow:hidden;padding:14px 10px}.brand{padding:2px 7px 18px}.side nav{min-height:0;overflow-y:auto;overflow-x:hidden;padding-right:2px}.nav{padding:9px 9px}.sidefooter{flex:0 0 auto}
main{height:100vh;min-height:0;overflow:hidden;padding:0;display:flex;flex-direction:column}header{flex:0 0 auto;min-height:70px;margin:0;padding:13px 18px 11px;border-bottom:1px solid #dfe5e9;background:#f7f9fa;align-items:center}h1{font-size:20px}header p{margin-top:3px;font-size:11.5px}.toolbar{min-width:0}.toolbar select{min-width:230px;height:34px}.toolbar .ghost,.noticebtn{height:34px}.userchip{height:32px}
.view{display:none;min-height:0;overflow:hidden;padding:10px 18px 14px}.view.active{display:flex;flex:1;flex-direction:column}.panel{min-height:0}.fill-panel{display:flex;flex:1;flex-direction:column;min-height:0;margin-bottom:0}.panelhead{flex:0 0 auto;min-height:48px;padding:8px 12px}.panelhead strong{font-size:12.5px}.panelhead small{font-size:10.5px}.tablehost{display:flex;flex:1;min-height:0;min-width:0;overflow:hidden}.tablehost>.tablewrap{flex:1;height:100%;min-height:0;min-width:0;overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable}.tablewrap{overscroll-behavior:contain}.tablewrap th{position:sticky;top:0;z-index:4;box-shadow:0 1px 0 #e5eaed}.tablewrap td,.tablewrap th{padding-top:8px;padding-bottom:8px}

/* Dashboard: indicadores baixos e uma única área operacional */
.stats{flex:0 0 auto;display:grid;grid-template-columns:repeat(8,minmax(78px,1fr));gap:6px;margin:0 0 8px}.stat{min-height:48px;border-radius:7px;padding:6px 9px;display:flex;align-items:center;justify-content:space-between;gap:8px}.stat strong{font-size:18px;line-height:1}.stat span{font-size:10.5px;text-align:right}.dashboard-priority{margin-top:0}.priority-table{overflow-x:hidden!important}.priority-table table{width:100%;min-width:0!important;table-layout:fixed}.priority-table th,.priority-table td{padding-left:9px;padding-right:9px}.priority-table th:nth-child(1){width:175px}.priority-table th:nth-child(2){width:86px}.priority-table th:nth-child(4),.priority-table th:nth-child(5){width:94px}.priority-table th:nth-child(6){width:86px}.priority-table th:nth-child(7),.priority-table th:nth-child(8){width:92px}.priority-table th:nth-child(9){width:68px}.priority-supplier{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.priority-supplier small{display:block;color:#8a959c;font-size:9.5px;overflow:hidden;text-overflow:ellipsis}.priority-action{text-align:right}

/* Área exclusiva de automação */
.jobstats{flex:0 0 auto;display:grid;grid-template-columns:repeat(4,minmax(120px,1fr));gap:6px;margin-bottom:8px}.jobstat{height:46px;border:1px solid #e0e6ea;border-radius:7px;background:#fff;padding:6px 10px;display:flex;align-items:center;justify-content:space-between}.jobstat strong{font-size:17px}.jobstat span{font-size:10.5px;color:#6f7c85}.jobs-table table{min-width:980px}

/* Configurações permanecem contidas na área útil */
#settings{padding-bottom:10px}.configbar{flex:0 0 auto;padding:9px 12px}.configbar select{height:34px}.tabs{flex:0 0 auto;margin-top:8px}.tab{padding:9px 12px;font-size:11.5px}#settingsBody{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;padding-bottom:4px}.tabpane{min-height:0}.sectionline{padding:11px 12px}.formrows{padding:12px}.actionrow{padding:12px}

/* Prazos de entrega */
.delivery-default{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:12px;border-bottom:1px solid #edf0f2;background:#fafbfc}.delivery-default>div:first-child{display:flex;flex-direction:column;gap:2px}.delivery-default small{color:#7e8a92;font-size:10.5px}.delivery-default-action{display:flex;align-items:center;gap:7px}.delivery-default-action input{width:82px;text-align:right}.delivery-default-action span{font-size:11px;color:#728089}.delivery-grid{display:grid;grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr);gap:10px;padding:12px}.subpanel{border:1px solid #e1e7ea;border-radius:8px;overflow:hidden;display:flex;flex-direction:column;min-height:330px;max-height:430px;background:#fff}.subpanel-head{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 11px;border-bottom:1px solid #e9edef}.subpanel-head>div{display:flex;flex-direction:column;gap:2px}.subpanel-head strong{font-size:12px}.subpanel-head small{font-size:10px;color:#80909a}.compact-host{min-height:0}.delivery-rule-table table{min-width:0}.delivery-rule-table td,.delivery-rule-table th{padding:7px 9px}.rule-source{display:flex;flex-direction:column;gap:2px}.rule-source small{font-size:9.5px;color:#8a959c}.rule-actions{white-space:nowrap}.rule-actions button+button{margin-left:4px}

/* Listas administrativas nunca empurram a página; rolam dentro da grade */
#documents,#alerts,#jobs,#companies,#users,#audit{min-height:0}.nfe-table{height:100%;max-width:none}.nfe-table table{min-width:1740px}.nfe-table th{top:0}.active-filter{background:#17212b!important;color:#fff!important;border-color:#17212b!important}

/* Drawer de documento: destaque da regra de entrega */
.delivery-rule-note{display:flex;gap:8px;align-items:center;margin:8px 0 2px;padding:8px 10px;border:1px solid #dbe6ea;border-radius:7px;background:#f8fbfc;color:#53636d;font-size:11px}.delivery-rule-note strong{color:#273740}.delivery-rule-note span{color:#75838c}

@media(max-width:1350px){.stats{grid-template-columns:repeat(4,minmax(90px,1fr))}.delivery-grid{grid-template-columns:1fr}.subpanel{min-height:260px;max-height:340px}.priority-table th:nth-child(7),.priority-table td:nth-child(7){display:none}}
@media(max-width:1050px){.shell{grid-template-columns:190px minmax(0,1fr)}.toolbar select{min-width:170px}.priority-table th:nth-child(5),.priority-table td:nth-child(5),.priority-table th:nth-child(8),.priority-table td:nth-child(8){display:none}.jobstats{grid-template-columns:repeat(2,1fr)}}
@media(max-width:850px){html,body{height:100%;overflow:hidden}.shell{height:100vh;grid-template-columns:1fr}.side{display:none}main{height:100vh;display:flex;padding:0}header{padding:10px 12px;align-items:flex-start;flex-direction:column;gap:8px}.toolbar{width:100%;flex-wrap:wrap}.toolbar select{flex:1;min-width:160px}.view{padding:8px 10px 10px}.view.active{display:flex}.stats{grid-template-columns:repeat(2,1fr)}.priority-table th:nth-child(4),.priority-table td:nth-child(4),.priority-table th:nth-child(6),.priority-table td:nth-child(6){display:none}.priority-table th:nth-child(1){width:150px}.panelactions{width:100%;flex-wrap:wrap}.panelactions input{flex:1;min-width:180px}.delivery-grid{padding:8px}.configbar{align-items:flex-start;flex-direction:column}.configbar select{width:100%;min-width:0}.tabs{overflow-x:auto}.detailgrid{grid-template-columns:1fr}}
.row-sub{display:block;margin-top:2px;color:#89959d;font-size:9.5px;font-weight:400}

/* V1.0.9 — visão geral executiva, sem duplicação, e prioridades em tela própria */
.dashboard-view.active{display:grid;grid-template-rows:auto minmax(0,1.08fr) minmax(0,.78fr);gap:10px;overflow:hidden}
.overview-metrics{display:grid;grid-template-columns:repeat(5,minmax(150px,1fr));gap:8px;min-height:0}
.overview-metric{height:64px;background:#fff;border:1px solid #dde4e8;border-radius:8px;padding:9px 11px;display:flex;align-items:center;gap:10px;min-width:0}
.metric-icon{width:34px;height:34px;border-radius:8px;background:#f1f6f8;color:#315f72;display:grid;place-items:center;flex:0 0 auto}.metric-icon .mini-svg{width:18px;height:18px}
.overview-metric>div{min-width:0;display:grid;grid-template-columns:auto 1fr;column-gap:8px;align-items:baseline}.overview-metric strong{font-size:20px;line-height:1;color:#17212b}.overview-metric span:not(.metric-icon){font-size:11px;color:#52616b;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.overview-metric small{grid-column:1/-1;color:#8a969d;font-size:9.5px;margin-top:2px}
.overview-grid{display:grid;gap:10px;min-height:0}.overview-grid-main{grid-template-columns:minmax(0,1.06fr) minmax(0,.92fr) minmax(260px,.72fr)}.overview-grid-bottom{grid-template-columns:minmax(0,.82fr) minmax(0,1.18fr)}
.overview-panel{margin:0;display:flex;flex-direction:column;min-height:0}.overview-panel .panelhead{min-height:44px}.overview-table{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}.compact-grid{width:100%;border-collapse:collapse;font-size:11.5px}.compact-grid th{position:sticky;top:0;z-index:2;padding:7px 10px;background:#fafbfc}.compact-grid td{padding:7px 10px}.compact-grid td small{display:block;color:#8b969d;font-size:9px;margin-top:1px}.compact-grid .right{text-align:right}.danger-number{color:#b44950;font-weight:700}
.flow-summary{flex:1;min-height:0;display:flex;flex-direction:column;justify-content:center;padding:8px 14px}.flow-item{display:grid;grid-template-columns:30px auto 1fr;grid-template-rows:auto auto;column-gap:9px;align-items:center;padding:9px 0}.flow-item>span{grid-row:1/3;width:28px;height:28px;border-radius:7px;background:#f2f6f8;color:#416b7c;display:grid;place-items:center}.flow-item>span .mini-svg{width:16px;height:16px}.flow-item strong{font-size:18px;line-height:1}.flow-item small{grid-column:2/4;color:#7b8891;font-size:9.7px;margin-top:3px}.flow-divider{height:1px;background:#edf0f2}
.schedule-label{display:inline-flex;align-items:center;gap:6px}.schedule-label .mini-svg{width:14px;height:14px;color:#607d8a}
.situations-panel{min-width:0}.situation-totals{flex:1;min-height:0;display:grid;grid-template-columns:repeat(7,minmax(72px,1fr));gap:6px;padding:10px}.situation-total{border:1px solid #e1e7ea;background:#fafcfd;border-radius:8px;padding:7px 5px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;cursor:pointer;min-width:0}.situation-total:hover{background:#f4f8fa;border-color:#cbd8de}.situation-total>span{width:25px;height:25px;border-radius:7px;background:#eef4f7;display:grid;place-items:center;color:#4b7080}.situation-total .mini-svg{width:14px;height:14px}.situation-total strong{font-size:17px}.situation-total small{font-size:9px;color:#71808a;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}

/* Prioridades: área operacional separada */
#priorities{min-height:0}.priority-stats{flex:0 0 auto;display:grid;grid-template-columns:repeat(6,minmax(125px,1fr));gap:7px;margin-bottom:8px}.priority-stat{height:52px;border:1px solid #dde4e8;background:#fff;border-radius:8px;padding:6px 9px;display:grid;grid-template-columns:28px auto 1fr;grid-template-rows:auto auto;align-items:center;column-gap:8px;cursor:pointer;text-align:left}.priority-stat>span{grid-row:1/3;width:27px;height:27px;border-radius:7px;background:#f1f5f7;display:grid;place-items:center}.priority-stat>span .mini-svg{width:15px;height:15px}.priority-stat strong{font-size:17px;line-height:1}.priority-stat small{grid-column:2/4;color:#6f7d86;font-size:9.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.priority-stat:hover,.priority-stat.active{border-color:#9fb7c2;background:#f7fafb}.priority-head{gap:12px}.priority-tools{display:flex;align-items:center;gap:7px}.priority-tools input{width:min(360px,32vw);height:32px}.priority-filters{flex:0 0 auto;display:flex;gap:5px;padding:7px 10px;border-bottom:1px solid #e9edef;overflow-x:auto;background:#fafbfc}.priority-filter{height:28px;border:1px solid #d8e0e4;border-radius:14px;background:#fff;color:#55646e;padding:0 10px;font-size:10.5px;white-space:nowrap;cursor:pointer}.priority-filter:hover,.priority-filter.active{background:#17212b;color:#fff;border-color:#17212b}.priorities-table{height:100%}.priorities-table table{min-width:1180px}.priorities-table th,.priorities-table td{padding-top:7px;padding-bottom:7px}.date-overdue{color:#ba3f48;font-weight:700}

/* O dashboard não exibe tabelas operacionais longas; cada bloco controla sua própria rolagem */
#dashboard .panelhead .smallbtn{height:27px}.overview-panel .tablewrap{height:100%;overflow:auto}.overview-panel table{font-size:11.5px}

@media(max-width:1400px){.overview-metrics{grid-template-columns:repeat(5,minmax(120px,1fr))}.overview-grid-main{grid-template-columns:1.05fr .95fr .68fr}.situation-totals{grid-template-columns:repeat(4,1fr)}.priority-stats{grid-template-columns:repeat(3,1fr)}}
@media(max-width:1100px){.dashboard-view.active{overflow:auto;display:block}.overview-metrics{grid-template-columns:repeat(2,1fr);margin-bottom:8px}.overview-grid-main,.overview-grid-bottom{grid-template-columns:1fr}.overview-panel{min-height:250px;margin-bottom:8px}.priority-stats{grid-template-columns:repeat(2,1fr)}}


/* V1.0.11 — dashboard executivo compacto, sem espaços vazios e sem duplicação */
#dashboard.dashboard-view.active{
  display:flex;
  flex-direction:column;
  gap:9px;
  overflow:hidden;
  width:100%;
  max-width:1780px;
  margin:0;
}
#dashboard .overview-metrics{
  flex:0 0 auto;
  display:grid;
  grid-template-columns:repeat(4,minmax(180px,1fr));
  gap:8px;
}
#dashboard .overview-metric{
  height:58px;
  padding:7px 10px;
  border-radius:8px;
}
#dashboard .overview-metric>div{
  display:grid;
  grid-template-columns:auto 1fr;
  align-items:baseline;
  column-gap:7px;
}
#dashboard .overview-metric strong{font-size:18px}
#dashboard .overview-metric span:not(.metric-icon){font-size:10.5px}
#dashboard .overview-metric small{font-size:8.8px;line-height:1.2;margin-top:1px}
#dashboard .metric-icon{width:30px;height:30px;border-radius:7px}
#dashboard .metric-icon .mini-svg{width:16px;height:16px}

#dashboard .overview-grid{display:grid;gap:9px;min-height:0}
#dashboard .overview-grid-main{
  flex:1 1 250px;
  min-height:190px;
  max-height:290px;
  grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr);
}
#dashboard .overview-grid-ops{
  flex:0 0 180px;
  grid-template-columns:minmax(360px,.78fr) minmax(0,1.22fr);
}
#dashboard .overview-panel{margin:0;min-height:0}
#dashboard .overview-panel .panelhead{min-height:40px;padding:7px 10px}
#dashboard .overview-panel .panelhead strong{font-size:11.5px}
#dashboard .overview-panel .panelhead small{font-size:9.5px}
#dashboard .overview-table{min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable}
#dashboard .compact-grid{font-size:10.5px}
#dashboard .compact-grid th,#dashboard .compact-grid td{padding:6px 8px}
#dashboard .compact-grid th{position:sticky;top:0;z-index:2}
#dashboard .compact-grid td small{font-size:8.5px}
#dashboard .truncate-cell{max-width:260px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

#dashboard .flow-summary{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  align-items:stretch;
  gap:0;
  padding:0;
  min-height:0;
}
#dashboard .flow-item{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:9px;
  padding:12px 14px;
  border-right:1px solid #edf0f2;
}
#dashboard .flow-item:last-child{border-right:0}
#dashboard .flow-item>span{
  flex:0 0 30px;
  width:30px;height:30px;
  border-radius:7px;
  background:#f1f6f8;
  color:#416b7c;
  display:grid;place-items:center;
}
#dashboard .flow-item>span .mini-svg{width:16px;height:16px}
#dashboard .flow-item>div{display:flex;flex-direction:column;gap:2px;min-width:0}
#dashboard .flow-item strong{font-size:19px;line-height:1}
#dashboard .flow-item small{font-size:9.5px;color:#77858e;white-space:nowrap}
#dashboard .flow-divider{display:none}

#dashboard .overview-situations-panel{flex:0 0 auto}
#dashboard .overview-situations-panel .panelhead{border-bottom:0}
#dashboard .situation-totals{
  display:grid;
  grid-template-columns:repeat(6,minmax(110px,1fr));
  gap:6px;
  padding:0 9px 9px;
}
#dashboard .situation-total{
  min-height:46px;
  padding:5px 8px;
  display:grid;
  grid-template-columns:27px auto;
  grid-template-rows:auto auto;
  column-gap:8px;
  justify-content:start;
  align-items:center;
  text-align:left;
  border-radius:7px;
}
#dashboard .situation-total>span{
  grid-row:1/3;
  width:27px;height:27px;
  border-radius:7px;
}
#dashboard .situation-total strong{font-size:16px;line-height:1}
#dashboard .situation-total small{font-size:9px;max-width:none}

#dashboard .smallbtn{height:25px;padding:0 9px;font-size:9.5px}

@media(min-width:1781px){
  #dashboard.dashboard-view.active{max-width:1780px}
}
@media(max-width:1250px){
  #dashboard .overview-metrics{grid-template-columns:repeat(2,1fr)}
  #dashboard .overview-grid-main,#dashboard .overview-grid-ops{grid-template-columns:1fr;max-height:none;flex-basis:auto}
  #dashboard .overview-grid-main{min-height:360px}
  #dashboard .overview-grid-ops{min-height:300px}
  #dashboard .situation-totals{grid-template-columns:repeat(3,1fr)}
}


/* V1.0.11 ajuste fino: os painéis crescem pelo conteúdo, nunca por espaço disponível */
#dashboard .overview-grid-main,
#dashboard .overview-grid-ops{
  flex:0 0 auto;
  min-height:0;
  max-height:none;
  align-items:start;
}
#dashboard .overview-grid-main .overview-panel{width:100%;max-height:230px}
#dashboard .overview-grid-ops .overview-panel{width:100%;max-height:170px}
#dashboard .overview-table{max-height:188px}
#dashboard .schedule-panel .overview-table{max-height:128px}
#dashboard .flow-panel{min-height:98px}
#dashboard .overview-situations-panel{min-height:0}
@media(max-width:1250px){
  #dashboard .overview-grid-main .overview-panel,#dashboard .overview-grid-ops .overview-panel{max-height:none}
  #dashboard .overview-table,#dashboard .schedule-panel .overview-table{max-height:220px}
}

/* V1.0.11 — correção visual: dashboard proporcional e drawer de NF-e refeito */
#dashboard.dashboard-view.active{
  display:flex;
  flex-direction:column;
  gap:10px;
  width:100%;
  max-width:none;
  margin:0;
  overflow:hidden;
}
#dashboard .overview-metrics{
  flex:0 0 66px;
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
}
#dashboard .overview-metric{
  height:66px;
  padding:9px 12px;
  border-radius:9px;
  background:#fff;
  border:1px solid #dde4e8;
}
#dashboard .overview-metric strong{font-size:20px}
#dashboard .overview-metric span:not(.metric-icon){font-size:11px;font-weight:600;color:#53616b}
#dashboard .overview-metric small{font-size:9.5px;color:#88949c}
#dashboard .metric-icon{width:34px;height:34px;border-radius:8px;background:#eef5f8}

#dashboard .dashboard-row{display:grid;gap:10px;min-height:0;flex:0 0 auto}
#dashboard .dashboard-row-main{
  height:222px;
  grid-template-columns:minmax(360px,1.05fr) minmax(330px,.95fr) minmax(300px,.72fr);
}
#dashboard .dashboard-row-secondary{
  height:188px;
  grid-template-columns:minmax(480px,1.25fr) minmax(420px,.95fr);
}
#dashboard .overview-panel{
  height:100%;
  max-height:none!important;
  min-height:0;
  display:flex;
  flex-direction:column;
  margin:0;
  background:#fff;
}
#dashboard .overview-panel .panelhead{
  flex:0 0 46px;
  min-height:46px;
  padding:8px 11px;
}
#dashboard .overview-panel .panelhead strong{font-size:12px}
#dashboard .overview-panel .panelhead small{font-size:9.5px}
#dashboard .overview-table{
  flex:1;
  min-height:0;
  max-height:none!important;
  overflow:auto;
  scrollbar-gutter:stable;
}
#dashboard .compact-grid{font-size:10.8px}
#dashboard .compact-grid th,#dashboard .compact-grid td{padding:7px 9px}
#dashboard .store-name strong,#dashboard .supplier-name strong{display:block;max-width:340px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

#dashboard .flow-summary{
  flex:1;
  display:flex;
  flex-direction:column;
  justify-content:center;
  padding:3px 14px;
}
#dashboard .flow-item{
  flex:1;
  min-height:0;
  border-right:0;
  border-bottom:1px solid #edf0f2;
  padding:9px 2px;
  display:grid;
  grid-template-columns:34px 1fr;
  grid-template-rows:auto auto;
  align-content:center;
  column-gap:10px;
}
#dashboard .flow-item:last-child{border-bottom:0}
#dashboard .flow-item>span{grid-row:1/3;width:32px;height:32px}
#dashboard .flow-item>div{display:contents}
#dashboard .flow-item strong{font-size:19px;line-height:1.05}
#dashboard .flow-item small{grid-column:2;color:#75838c;font-size:9.6px;margin-top:2px}

#dashboard .overview-trend{
  flex:1;
  min-height:0;
  padding:9px 13px 8px;
  display:flex;
  flex-direction:column;
}
#dashboard .trend-head{display:flex;gap:20px;align-items:center;flex:0 0 auto;font-size:10px;color:#6b7881}
#dashboard .trend-head span{display:flex;align-items:center;gap:5px}
#dashboard .trend-head strong{color:#25323a;margin-left:2px}
#dashboard .legend-dot{width:8px;height:8px;border-radius:50%;display:inline-block;background:#7aa8ba}
#dashboard .legend-dot.manifested{background:#7e8ca2}
#dashboard .trend-chart{flex:1;min-height:0;display:grid;grid-template-columns:repeat(7,1fr);gap:10px;align-items:end;padding-top:7px}
#dashboard .trend-day{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:4px}
#dashboard .trend-bars{height:105px;width:100%;display:flex;justify-content:center;align-items:flex-end;gap:5px;border-bottom:1px solid #e8edef}
#dashboard .trend-bar{width:min(16px,34%);min-height:3px;border-radius:4px 4px 1px 1px;background:#7aa8ba}
#dashboard .trend-bar.manifested{background:#7e8ca2}
#dashboard .trend-day small{font-size:9px;color:#7d8992}
#dashboard .trend-empty{margin:0;align-self:stretch}

#dashboard .overview-situations-panel{
  flex:0 0 82px;
  height:82px;
  min-height:82px;
}
#dashboard .overview-situations-panel .panelhead{height:34px;min-height:34px;padding:5px 9px;border-bottom:1px solid #edf0f2}
#dashboard .overview-situations-panel .panelhead small{display:none}
#dashboard .situation-totals{
  height:47px;
  display:grid;
  grid-template-columns:repeat(6,minmax(0,1fr));
  gap:6px;
  padding:5px 8px 7px;
}
#dashboard .situation-total{
  min-height:0;
  height:35px;
  padding:3px 7px;
  display:grid;
  grid-template-columns:24px auto 1fr;
  grid-template-rows:1fr;
  gap:7px;
  align-items:center;
  justify-content:start;
  text-align:left;
  background:#fafcfd;
}
#dashboard .situation-total>span{grid-row:auto;width:24px;height:24px}
#dashboard .situation-total strong{font-size:15px}
#dashboard .situation-total small{font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* Drawer específico da NF-e: conteúdo organizado, rolagem interna e ações fixas */
.drawerbox.document-drawer{
  width:min(620px,96vw);
  padding:0;
  overflow:hidden;
  display:flex;
  flex-direction:column;
}
.document-drawer>.x{z-index:5;top:13px;right:16px;width:34px;height:34px;font-size:24px;border-radius:7px}
.document-drawer>.x:hover{background:#f1f4f6}
#drawerContent{height:100%;min-height:0}
.doc-shell{height:100%;display:flex;flex-direction:column;min-height:0;background:#fff}
.doc-top{flex:0 0 auto;padding:20px 22px 13px;border-bottom:1px solid #e7ecef}
.doc-title-row{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;padding-right:38px}
.doc-title-row h2{font-size:22px;margin:3px 0 0}.doc-title-row h2 small{font-size:11px;color:#77848c;font-weight:600;margin-left:7px}
.eyebrow{text-transform:uppercase;letter-spacing:.06em;color:#839099;font-size:9.5px;font-weight:700}
.doc-key{margin-top:12px;display:grid;grid-template-columns:1fr auto;gap:6px;align-items:center;background:#f5f7f8;border:1px solid #e0e6e9;border-radius:7px;padding:4px 5px 4px 9px}
.doc-key code{font-size:11.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#2c3941}
.copybtn{height:28px;border:0;background:#fff;border-left:1px solid #dfe5e8;padding:0 9px;color:#4e6571;font-size:10px;cursor:pointer}
.doc-status-row{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin-top:9px}
.doc-top .delivery-rule-note{margin-top:9px;margin-bottom:0;background:#f8fbfc}
.doc-scroll{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;padding:0 22px 18px}
.doc-section{padding:17px 0;border-bottom:1px solid #edf0f2}.doc-section:last-child{border-bottom:0}
.doc-party-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.doc-party{min-width:0;border:1px solid #e3e8eb;border-radius:8px;padding:10px 11px;background:#fbfcfd;display:flex;flex-direction:column;gap:3px}
.doc-party>span,.doc-facts span,.doc-nature span{font-size:9.5px;text-transform:uppercase;letter-spacing:.03em;color:#7b8891;font-weight:700}
.doc-party strong{font-size:12px;line-height:1.35;white-space:normal}.doc-party small{font-size:9.5px;color:#89959d}
.doc-facts{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0;margin-top:13px;border:1px solid #e5eaed;border-radius:8px;overflow:hidden}
.doc-facts>div{padding:9px 10px;border-right:1px solid #e8edef;display:flex;flex-direction:column;gap:4px}.doc-facts>div:last-child{border-right:0}.doc-facts strong{font-size:11.5px}
.doc-nature{display:flex;flex-direction:column;gap:4px;margin-top:12px}.doc-nature strong{font-size:11.5px;line-height:1.4;font-weight:600;color:#34424a}
.doc-section-title{display:flex;align-items:baseline;justify-content:space-between;gap:10px;margin-bottom:12px}.doc-section-title strong{font-size:14px}.doc-section-title small{font-size:9.5px;color:#85929a}
.doc-timeline{position:relative;margin-left:5px}.doc-timeline:before{content:"";position:absolute;left:5px;top:7px;bottom:7px;width:1px;background:#dfe6ea}
.doc-event{position:relative;display:grid;grid-template-columns:12px 1fr;gap:10px;padding:0 0 14px}.doc-event:last-child{padding-bottom:0}
.doc-event-dot{width:11px;height:11px;border-radius:50%;background:#91a4ae;border:2px solid #fff;box-shadow:0 0 0 1px #cfd9de;z-index:1;margin-top:2px}.doc-event.dfe .doc-event-dot{background:#5eaa7a}.doc-event.manifest .doc-event-dot{background:#668ca3}.doc-event.alert .doc-event-dot{background:#c56b70}.doc-event.erp .doc-event-dot{background:#8898a3}
.doc-event strong{display:block;font-size:11.5px;color:#2a3840}.doc-event small{display:block;font-size:9.5px;color:#839099;margin-top:2px}
.doc-footer{flex:0 0 auto;min-height:58px;border-top:1px solid #e1e7ea;padding:10px 22px;display:flex;align-items:center;justify-content:flex-end;gap:8px;background:#fff}
.doc-footer .dangerlite{margin-right:auto}

@media(max-width:1320px){
  #dashboard .dashboard-row-main{grid-template-columns:1fr 1fr;height:390px}
  #dashboard .flow-panel{grid-column:1/-1;height:150px}
  #dashboard .flow-summary{display:grid;grid-template-columns:repeat(3,1fr)}
  #dashboard .flow-item{border-bottom:0;border-right:1px solid #edf0f2}
  #dashboard .flow-item:last-child{border-right:0}
  #dashboard .dashboard-row-secondary{grid-template-columns:1fr 1fr}
}
@media(max-width:1050px){
  #dashboard{overflow:auto!important}
  #dashboard .overview-metrics{grid-template-columns:repeat(2,1fr);flex-basis:auto}
  #dashboard .dashboard-row-main,#dashboard .dashboard-row-secondary{height:auto;grid-template-columns:1fr}
  #dashboard .overview-panel{min-height:190px;height:220px}
  #dashboard .flow-panel{grid-column:auto;height:170px}
  #dashboard .overview-situations-panel{height:auto;min-height:110px}
  #dashboard .situation-totals{height:auto;grid-template-columns:repeat(3,1fr)}
  .doc-facts{grid-template-columns:repeat(2,1fr)}.doc-facts>div:nth-child(2){border-right:0}.doc-facts>div:nth-child(-n+2){border-bottom:1px solid #e8edef}
}

/* V1.0.12 — dashboard confortável: elegante, funcional e sem compactação excessiva */
#dashboard.dashboard-view.active{
  display:flex;
  flex-direction:column;
  gap:12px;
  width:100%;
  min-height:0;
  overflow:auto;
  padding-bottom:4px;
  scrollbar-gutter:stable;
}
#dashboard .overview-metrics{
  flex:0 0 auto;
  display:grid;
  grid-template-columns:repeat(4,minmax(210px,1fr));
  gap:12px;
}
#dashboard .overview-metric{
  height:82px;
  min-width:0;
  padding:13px 15px;
  border-radius:11px;
  border:1px solid #dfe6ea;
  background:#fff;
  display:flex;
  align-items:center;
  gap:13px;
  box-shadow:0 1px 0 rgba(15,24,32,.02);
}
#dashboard .metric-icon{
  width:42px;height:42px;
  flex:0 0 42px;
  border-radius:10px;
  background:#eef5f8;
  color:#315f72;
  display:grid;place-items:center;
}
#dashboard .metric-icon .mini-svg{width:20px;height:20px}
#dashboard .metric-copy{display:flex!important;flex-direction:column;align-items:flex-start!important;gap:2px!important;min-width:0}
#dashboard .metric-copy>span{order:0;font-size:11px!important;font-weight:600!important;color:#677680!important;white-space:nowrap}
#dashboard .metric-copy>strong{order:1;font-size:24px!important;line-height:1.08;color:#17212b;white-space:nowrap}
#dashboard .metric-copy>small{order:2;font-size:10px!important;color:#89959d!important;margin:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}

#dashboard .dashboard-comfort-grid{
  flex:0 0 auto;
  display:grid;
  gap:12px;
  min-width:0;
}
#dashboard .dashboard-comfort-top{grid-template-columns:minmax(520px,1.25fr) minmax(420px,.75fr)}
#dashboard .dashboard-comfort-middle{grid-template-columns:minmax(560px,1.18fr) minmax(470px,.82fr)}
#dashboard .dashboard-card{
  margin:0;
  min-width:0;
  border-radius:11px;
  border-color:#dfe6ea;
  overflow:hidden;
  background:#fff;
}
#dashboard .dashboard-card .panelhead{
  min-height:54px;
  padding:10px 14px;
}
#dashboard .dashboard-card .panelhead strong{font-size:12.5px}
#dashboard .dashboard-card .panelhead small{font-size:10.5px}
#dashboard .dashboard-card .smallbtn{height:30px;padding:0 11px;font-size:10.5px}

#dashboard .stores-card{height:224px}
#dashboard .operation-card{height:224px}
#dashboard .suppliers-card{height:292px}
#dashboard .situations-card{height:292px}
#dashboard .dashboard-table-area{
  height:calc(100% - 54px);
  min-height:0;
  overflow:auto;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
}
#dashboard .dashboard-table-area .tablewrap{height:100%;overflow:auto}
#dashboard .compact-grid{font-size:11.5px}
#dashboard .compact-grid th{padding:8px 12px;position:sticky;top:0;z-index:3}
#dashboard .compact-grid td{padding:9px 12px}
#dashboard .compact-grid td small{font-size:9.5px;margin-top:2px}
#dashboard .store-name strong,#dashboard .supplier-name strong{display:block;max-width:430px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#dashboard .supplier-value{color:#56656f;font-variant-numeric:tabular-nums}

#dashboard .operation-cards{
  height:calc(100% - 54px);
  padding:12px;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
#dashboard .operation-tile{
  min-width:0;
  border:1px solid #e1e7ea;
  border-radius:10px;
  background:#fafcfd;
  padding:12px;
  display:flex;
  align-items:center;
  gap:11px;
}
#dashboard .operation-tile:hover{background:#f7fafb;border-color:#cfdadf}
#dashboard .operation-icon{
  width:36px;height:36px;
  flex:0 0 36px;
  border-radius:9px;
  background:#eef5f8;
  color:#3f6b7d;
  display:grid;place-items:center;
}
#dashboard .operation-icon .mini-svg{width:18px;height:18px}
#dashboard .operation-tile>div{display:flex;flex-direction:column;gap:2px;min-width:0}
#dashboard .operation-tile strong{font-size:23px;line-height:1.05;color:#17212b}
#dashboard .operation-tile span:not(.operation-icon){font-size:11px;font-weight:600;color:#53616b}
#dashboard .operation-tile small{font-size:9.5px;color:#89959d;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

#dashboard .situation-cards{
  height:calc(100% - 54px);
  padding:12px;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  grid-template-rows:repeat(3,minmax(0,1fr));
  gap:10px;
}
#dashboard .situation-card{
  min-width:0;
  border:1px solid #e1e7ea;
  border-radius:10px;
  background:#fafcfd;
  color:#25333c;
  padding:10px 12px;
  display:flex;
  align-items:center;
  gap:11px;
  text-align:left;
  cursor:pointer;
}
#dashboard .situation-card:hover{background:#f4f8fa;border-color:#bfd0d8;transform:translateY(-1px)}
#dashboard .situation-card-icon{
  width:36px;height:36px;
  flex:0 0 36px;
  border-radius:9px;
  background:#eef4f7;
  color:#496f80;
  display:grid;place-items:center;
}
#dashboard .situation-card-icon .mini-svg{width:18px;height:18px}
#dashboard .situation-card>div{display:flex;flex-direction:column;gap:3px;min-width:0}
#dashboard .situation-card strong{font-size:22px;line-height:1;color:#17212b}
#dashboard .situation-card span:not(.situation-card-icon){font-size:10.5px;font-weight:600;color:#5b6871;line-height:1.25}

#dashboard .schedule-strip-card{flex:0 0 auto;min-height:122px}
#dashboard .schedule-strip{
  padding:10px 12px 12px;
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
}
#dashboard .schedule-item{
  min-width:0;
  min-height:56px;
  border:1px solid #e2e7ea;
  background:#fafcfd;
  border-radius:9px;
  padding:9px 10px;
  display:grid;
  grid-template-columns:32px auto minmax(0,1fr);
  align-items:center;
  gap:9px;
}
#dashboard .schedule-icon{width:32px;height:32px;border-radius:8px;background:#eef5f8;color:#476d7c;display:grid;place-items:center}
#dashboard .schedule-icon .mini-svg{width:16px;height:16px}
#dashboard .schedule-time{display:flex;flex-direction:column;gap:1px;padding-right:8px;border-right:1px solid #e2e7ea}
#dashboard .schedule-time strong{font-size:14px}
#dashboard .schedule-time small{font-size:8.5px;color:#8a969d}
#dashboard .schedule-copy{display:flex;flex-direction:column;gap:2px;min-width:0}
#dashboard .schedule-copy strong{font-size:10.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#dashboard .schedule-copy small{font-size:9px;color:#7d8991;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#dashboard .schedule-empty{grid-column:1/-1;padding:14px;color:#7b8790;text-align:center}

@media(max-width:1380px){
  #dashboard .overview-metrics{grid-template-columns:repeat(2,minmax(220px,1fr))}
  #dashboard .dashboard-comfort-top,#dashboard .dashboard-comfort-middle{grid-template-columns:1fr 1fr}
  #dashboard .stores-card,#dashboard .operation-card{height:240px}
  #dashboard .suppliers-card,#dashboard .situations-card{height:300px}
  #dashboard .schedule-strip{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:1050px){
  #dashboard.dashboard-view.active{overflow:auto}
  #dashboard .dashboard-comfort-top,#dashboard .dashboard-comfort-middle{grid-template-columns:1fr}
  #dashboard .stores-card,#dashboard .operation-card,#dashboard .suppliers-card,#dashboard .situations-card{height:auto;min-height:250px}
  #dashboard .dashboard-table-area{height:220px}
  #dashboard .operation-cards,#dashboard .situation-cards{height:auto;min-height:210px}
}


/* V1.0.13 — Visão Geral: uso real do espaço, sem scroll prematuro e com densidade confortável */
#dashboard.dashboard-view.active{
  display:grid;
  grid-template-rows:auto minmax(210px,.88fr) minmax(310px,1.22fr) auto;
  gap:14px;
  width:100%;
  min-height:0;
  overflow:auto;
  padding-bottom:8px;
  align-content:stretch;
}
#dashboard .overview-metrics{
  display:grid;
  grid-template-columns:repeat(4,minmax(220px,1fr));
  gap:14px;
  margin:0;
}
#dashboard .overview-metric{
  min-height:88px;
  height:auto;
  padding:14px 17px;
  border-radius:12px;
  box-shadow:0 2px 10px rgba(21,36,46,.035);
}
#dashboard .metric-icon{
  width:44px;height:44px;flex-basis:44px;border-radius:11px;
  background:#eef6fa;color:#2d6d87;
}
#dashboard .metric-copy>span{font-size:11.5px!important}
#dashboard .metric-copy>strong{font-size:25px!important}
#dashboard .metric-copy>small{font-size:10.5px!important}

#dashboard .dashboard-comfort-grid{
  min-height:0;
  height:100%;
  gap:14px;
  align-items:stretch;
}
#dashboard .dashboard-comfort-top{
  grid-template-columns:minmax(620px,1.35fr) minmax(470px,.85fr);
}
#dashboard .dashboard-comfort-middle{
  grid-template-columns:minmax(650px,1.28fr) minmax(500px,.92fr);
}
#dashboard .dashboard-card{
  height:100%!important;
  min-height:0!important;
  border-radius:12px;
  box-shadow:0 2px 10px rgba(21,36,46,.025);
}
#dashboard .dashboard-card .panelhead{
  min-height:58px;
  padding:11px 15px;
}
#dashboard .dashboard-card .panelhead strong{font-size:13px}
#dashboard .dashboard-card .panelhead small{font-size:10.5px;line-height:1.35}
#dashboard .dashboard-card .smallbtn{height:31px;min-width:92px}

/* Tabelas do dashboard crescem com o card e não exibem scrollbar interna cedo */
#dashboard .dashboard-table-area{
  height:auto!important;
  min-height:0;
  overflow:visible!important;
}
#dashboard .dashboard-table-area .tablewrap{
  height:auto!important;
  overflow:visible!important;
}
#dashboard .compact-grid{
  font-size:11.8px;
  table-layout:fixed;
}
#dashboard .compact-grid th{
  position:static;
  padding:8px 13px;
  font-size:10.5px;
}
#dashboard .compact-grid td{
  padding:8px 13px;
  height:34px;
}
#dashboard .compact-grid td small{font-size:9.5px}
#dashboard .store-name strong,#dashboard .supplier-name strong{max-width:560px}
#dashboard .suppliers-card .compact-grid tbody tr:nth-child(n+9){display:none}
#dashboard .suppliers-card .compact-grid td{height:31px;padding-top:6px;padding-bottom:6px}
#dashboard .suppliers-card .supplier-name strong{font-size:11.3px}
#dashboard .suppliers-card .supplier-name small{font-size:8.8px}
#dashboard .suppliers-card .supplier-value{font-weight:600;color:#42535e}
#dashboard .right{text-align:right}
#dashboard .danger-number{color:#c04750;font-weight:700}

/* Operação de hoje — 4 cards de uso confortável */
#dashboard .operation-cards{
  height:calc(100% - 58px);
  min-height:0;
  padding:13px;
  grid-template-columns:repeat(2,minmax(0,1fr));
  grid-template-rows:repeat(2,minmax(0,1fr));
  gap:11px;
}
#dashboard .operation-tile{
  min-height:72px;
  padding:13px 14px;
  border-radius:11px;
  background:#fbfcfd;
}
#dashboard .operation-tile:nth-child(1){background:#f7fbfe}
#dashboard .operation-tile:nth-child(2){background:#f6fcf9}
#dashboard .operation-tile:nth-child(3){background:#faf8fe}
#dashboard .operation-tile:nth-child(4){background:#f5fcfb}
#dashboard .operation-icon{width:40px;height:40px;flex-basis:40px;border-radius:10px}
#dashboard .operation-icon .mini-svg{width:19px;height:19px}
#dashboard .operation-tile strong{font-size:25px}
#dashboard .operation-tile span:not(.operation-icon){font-size:11.5px}
#dashboard .operation-tile small{font-size:10px;white-space:normal;line-height:1.25}

/* Situação da operação — cards centrais, legíveis e clicáveis */
#dashboard .situation-cards{
  height:calc(100% - 58px);
  min-height:0;
  padding:13px;
  grid-template-columns:repeat(2,minmax(0,1fr));
  grid-template-rows:repeat(3,minmax(0,1fr));
  gap:11px;
}
#dashboard .situation-card{
  min-height:66px;
  padding:12px 14px;
  border-radius:11px;
  transition:border-color .16s ease,box-shadow .16s ease,transform .16s ease;
}
#dashboard .situation-card:nth-child(1){background:#f7fbfe}
#dashboard .situation-card:nth-child(2){background:#fffaf4}
#dashboard .situation-card:nth-child(3){background:#fff7f8;border-color:#efd7da}
#dashboard .situation-card:nth-child(4){background:#f5fcf8}
#dashboard .situation-card:nth-child(5){background:#faf8fe}
#dashboard .situation-card:nth-child(6){background:#f7fbfe}
#dashboard .situation-card:hover{box-shadow:0 4px 14px rgba(30,62,78,.08)}
#dashboard .situation-card:nth-child(3) strong{color:#bd3642}
#dashboard .situation-card-icon{width:40px;height:40px;flex-basis:40px;border-radius:10px}
#dashboard .situation-card-icon .mini-svg{width:19px;height:19px}
#dashboard .situation-card strong{font-size:24px}
#dashboard .situation-card span:not(.situation-card-icon){font-size:11.5px;white-space:normal}

/* Agenda ocupa a largura com cards confortáveis e sem scroll */
#dashboard .schedule-strip-card{
  min-height:132px;
  height:auto!important;
  margin:0;
}
#dashboard .schedule-strip{
  padding:11px 13px 13px;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:11px;
}
#dashboard .schedule-item{
  min-height:66px;
  padding:10px 12px;
  border-radius:10px;
  grid-template-columns:36px auto minmax(0,1fr);
  gap:10px;
  background:#fbfcfd;
}
#dashboard .schedule-icon{width:36px;height:36px;border-radius:9px}
#dashboard .schedule-time strong{font-size:15px}
#dashboard .schedule-time small{font-size:9px}
#dashboard .schedule-copy strong{font-size:11px}
#dashboard .schedule-copy small{font-size:9.5px;line-height:1.25;white-space:normal;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}

@media(min-width:1700px){
  #dashboard.dashboard-view.active{
    grid-template-rows:auto minmax(220px,.9fr) minmax(330px,1.28fr) auto;
  }
  #dashboard .overview-metric{min-height:92px}
  #dashboard .operation-tile,#dashboard .situation-card{padding-left:16px;padding-right:16px}
  #dashboard .compact-grid td{height:36px}
  #dashboard .suppliers-card .compact-grid td{height:33px}
}

@media(max-width:1380px){
  #dashboard.dashboard-view.active{display:flex;overflow:auto;gap:12px}
  #dashboard .overview-metrics{grid-template-columns:repeat(2,minmax(220px,1fr))}
  #dashboard .dashboard-comfort-top,#dashboard .dashboard-comfort-middle{grid-template-columns:1fr 1fr;height:auto}
  #dashboard .dashboard-card{min-height:245px!important;height:auto!important}
  #dashboard .suppliers-card,#dashboard .situations-card{min-height:320px!important}
  #dashboard .schedule-strip{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:1050px){
  #dashboard .dashboard-comfort-top,#dashboard .dashboard-comfort-middle{grid-template-columns:1fr}
  #dashboard .overview-metrics{grid-template-columns:1fr 1fr}
  #dashboard .operation-cards,#dashboard .situation-cards{height:auto;min-height:220px}
  #dashboard .schedule-strip{grid-template-columns:1fr 1fr}
}

.info-note{margin:0 14px 14px;padding:11px 12px;border:1px solid #d7e4ea;background:#f6fafc;border-radius:8px;color:#52626c;font-size:12px}.info-note strong{color:#26343d}.integration-mode{display:inline-flex;align-items:center;gap:6px;padding:5px 8px;border-radius:999px;border:1px solid #c9d8df;background:#f7fafb;font-size:11px}
/* TS API configurator / diagnostics */
.formrows .span2{grid-column:span 2}.live-test-result{margin:0 14px 14px;border:1px solid #e2e7ea;border-radius:8px;overflow:hidden;background:#fff}.live-test-result .testhead{background:#fafbfc}.live-test-result .steps{padding:4px 12px}.live-test-result .step pre{max-height:360px;overflow:auto;background:#111a21;color:#e7eef2;padding:11px;border-radius:7px;font-size:11px;line-height:1.45;white-space:pre-wrap;word-break:break-word}.live-test-result .step details summary{cursor:pointer;color:#52626c;font-size:11.5px;font-weight:600}.step.error>div>strong{color:#9d3f46}.step.warn>div>strong{color:#806523}
@media(max-width:850px){.formrows .span2{grid-column:span 1}}

/* V1.0.18 - configurador TS HUB claro e totalmente editável */
.config-card{border:1px solid var(--line,#d9e1ea);border-radius:12px;background:var(--panel,#fff);padding:16px;margin:14px 0}
.config-card-title{display:flex;flex-direction:column;gap:3px;margin-bottom:14px}
.config-card-title strong{font-size:14px}.config-card-title small{color:var(--muted,#6b7785)}
.request-preview{margin-top:12px;border:1px solid #dce4ee;border-radius:10px;background:#f8fafc;padding:12px;display:grid;gap:10px}
.request-preview>div{display:grid;gap:2px}.request-preview span{font-size:11px;color:#6b7785}.request-preview strong,.request-preview code{font-size:13px;overflow-wrap:anywhere}
.preview-title{font-weight:700;font-size:13px}.preview-grid{display:grid;grid-template-columns:140px 1fr 180px;gap:12px;align-items:start}.preview-url{min-width:0}.preview-body{grid-column:1/-1}.preview-body pre{margin:4px 0 0;white-space:pre-wrap}
.company-bindings{margin-top:14px}.bindings-head{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:8px}.bindings-head>div{display:flex;flex-direction:column}.bindings-head small{color:#6b7785}
.ts-bindings-table .tablewrap{max-height:none!important;overflow:visible!important}.ts-bindings-table input{min-width:120px}
.test-result-summary{display:flex;align-items:center;justify-content:space-between;gap:16px;border-radius:10px;padding:14px 16px;margin-top:14px}.test-result-summary>div{display:flex;flex-direction:column;gap:3px}.test-result-summary.success{background:#eef9f2;border:1px solid #bfe4ca}.test-result-summary.failed{background:#fff1f1;border:1px solid #efc0c0}.test-result-summary strong{font-size:14px}.test-result-summary span{font-size:12px}
.test-diagnosis{margin-top:12px;border-left:4px solid #d33;background:#fff6f6;border-radius:8px;padding:12px 14px}.test-diagnosis strong{display:block;margin-bottom:4px}.test-diagnosis p{margin:0 0 10px;line-height:1.45}.diag-line{margin-top:5px;overflow-wrap:anywhere}
.io-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:12px}.io-card{border:1px solid #dce4ee;border-radius:10px;overflow:hidden;background:#0e1720}.io-title{padding:9px 12px;background:#182431;color:#d7e4ef;font-size:11px;font-weight:700;letter-spacing:.04em}.io-card pre{margin:0;padding:12px;color:#e8f1f7;white-space:pre-wrap;word-break:break-word;max-height:360px;overflow:auto;font-size:12px;line-height:1.45}
.diagnostic-steps{margin-top:12px}.diagnostic-steps .step{min-height:58px}.test-console-card .actionrow{margin-top:0}
@media(max-width:1100px){.preview-grid,.io-grid{grid-template-columns:1fr}.preview-body{grid-column:auto}}

/* V1.0.22 — legibilidade do diagnóstico e ações por documento */
.preview-grid>div{min-width:0;display:flex;flex-direction:column;gap:4px!important}
.preview-grid>div>span{display:block;line-height:1.25}
.preview-grid>div>strong,.preview-grid>div>code{display:block;line-height:1.35;min-width:0;overflow-wrap:anywhere}
.doc-section-title>div{display:flex;flex-direction:column;gap:2px;min-width:0}
.doc-section-actions{display:flex!important;flex-direction:row!important;align-items:center;justify-content:flex-end;gap:7px;flex-wrap:wrap}
.doc-section-actions button{display:inline-flex;align-items:center;gap:6px}
.doc-section-actions .mini-svg{width:14px;height:14px}
.erp-section{padding-top:16px}
.erp-result-card{border:1px solid #dfe6ea;border-radius:9px;padding:11px 12px;background:#fafbfc;display:flex;flex-direction:column;gap:7px}
.erp-result-card.ok{border-color:#b8dcc6;background:#f5fff9}
.erp-result-card.warn{border-color:#e5d19c;background:#fffbef}
.erp-result-card.bad{border-color:#e9b8b8;background:#fff7f7}
.erp-result-card>div{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.erp-result-card>div>strong{font-size:11px;color:#62707a;font-weight:600}
.erp-result-card p{margin:0;font-size:11.5px;line-height:1.45;color:#44525c}
.erp-action-hint{margin-top:8px;border-left:3px solid #d9b960;background:#fffaf0;padding:8px 10px;border-radius:0 7px 7px 0;font-size:11px;line-height:1.4;color:#675a37}
.erp-mapping-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-top:9px}
.erp-map-count{border:1px solid #e1e7ea;border-radius:8px;padding:8px 9px;background:#fff;display:flex;align-items:baseline;gap:6px}
.erp-map-count strong{font-size:16px}.erp-map-count span{font-size:10.5px;color:#71808a}
.erp-map-count.ok{border-color:#c4dfce;background:#f8fffa}.erp-map-count.bad{border-color:#edc0c0;background:#fff8f8}
.erp-warning{margin-top:8px;border:1px solid #edc0c0;background:#fff8f8;border-radius:8px;padding:9px 10px;display:flex;flex-direction:column;gap:3px}
.erp-warning strong{font-size:11.5px;color:#963f46}.erp-warning span{font-size:11.5px;font-weight:600}.erp-warning small{font-size:10.5px;color:#78696b;line-height:1.4}
.erp-details{margin-top:9px;border:1px solid #e2e7ea;border-radius:8px;background:#fff;overflow:hidden}
.erp-details>summary{cursor:pointer;padding:9px 10px;font-size:11px;font-weight:700;color:#4e5e68;background:#fafbfc;list-style-position:inside}
.erp-details pre{margin:0;border-top:1px solid #e7ecef;background:#111a21;color:#e7eef2;padding:10px;max-height:300px;overflow:auto;font-size:10.5px;line-height:1.45;white-space:pre-wrap;word-break:break-word}
.erp-field-list,.erp-check-history{border-top:1px solid #e7ecef;padding:3px 10px}
.erp-field-list>div,.erp-check-history>div{padding:7px 0;border-bottom:1px solid #edf0f2;display:flex;align-items:flex-start;gap:8px;flex-wrap:wrap}
.erp-field-list>div:last-child,.erp-check-history>div:last-child{border-bottom:0}
.erp-field-list strong{font-size:10.8px;min-width:150px}.erp-field-list span,.erp-check-history small{font-size:10.5px;color:#6f7c85;line-height:1.4}
.erp-check-history>div>strong{font-size:10.5px;color:#5e6b74;font-weight:600}
.erp-technical-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:9px 10px;border-top:1px solid #e7ecef}
.erp-technical-grid>div{display:flex;flex-direction:column;gap:3px}.erp-technical-grid span{font-size:9.5px;text-transform:uppercase;color:#7b8790}.erp-technical-grid strong{font-size:11px}
.erp-error-text{margin:0 10px 9px;border:1px solid #ecc2c2;background:#fff6f6;color:#933d44;border-radius:7px;padding:8px 9px;font-size:11px;line-height:1.4}
.erp-json-title{padding:8px 10px 5px;border-top:1px solid #edf0f2;font-size:10.5px;font-weight:700;color:#596872}
@media(max-width:760px){.erp-mapping-summary{grid-template-columns:1fr}.erp-technical-grid{grid-template-columns:1fr}.doc-section-title{align-items:flex-start;flex-direction:column}.doc-section-actions{justify-content:flex-start;width:100%}}


/* V1.0.23 — filtros NF-e em linha, lote manual e preferência de totais financeiros */
#documents .documents-head{min-height:50px}
.document-filterbar{display:flex;align-items:center;gap:10px;padding:7px 10px;border-bottom:1px solid #e9edef;background:#fafbfc;min-width:0;white-space:nowrap}
.document-filters{display:flex;align-items:center;gap:5px;min-width:0;overflow-x:auto;scrollbar-width:thin;flex:1 1 auto;padding-bottom:1px}
.document-filter{height:28px;border:1px solid #d8e0e4;border-radius:14px;background:#fff;color:#55646e;padding:0 10px;font-size:10.5px;white-space:nowrap;cursor:pointer;flex:0 0 auto}
.document-filter:hover,.document-filter.active{background:#17212b;color:#fff;border-color:#17212b}
.document-tools{display:flex;align-items:center;gap:6px;flex:0 0 auto}
.document-tools input{width:min(390px,30vw);height:30px}
.document-tools .small{height:30px}
.toolbar #manualBatch{white-space:nowrap}
.manual-batch-options{display:grid;grid-template-columns:1fr;gap:8px;margin:14px 0}
.manual-batch-option{display:flex;align-items:flex-start;gap:10px;border:1px solid #dce4e8;border-radius:8px;padding:10px 11px;cursor:pointer;background:#fff;color:#27343d}
.manual-batch-option:hover{background:#f8fafb;border-color:#bfcdd4}
.manual-batch-option input{height:auto;margin-top:3px}
.manual-batch-option span{display:flex;flex-direction:column;gap:2px}
.manual-batch-option strong{font-size:12px}
.manual-batch-option small{font-size:10.5px;color:#75838c;line-height:1.35}
.manual-batch-option.disabled{opacity:.55;cursor:not-allowed;background:#f7f8f9}
.modalfield.compact{max-width:230px}
.modalfield.compact input{width:100%;margin-top:5px}
.manual-batch-warning{display:flex;align-items:center;gap:8px;margin:13px 0 4px;padding:9px 10px;border:1px solid #ead9a8;border-radius:7px;background:#fffbef;font-size:11.5px}
.manual-batch-warning strong{color:#775c18}
.drawerform .switchline.span2{grid-column:1/-1;align-items:flex-start!important;flex-wrap:wrap}
.drawerform .switchline.span2 small{display:block;flex-basis:100%;padding-left:24px;color:#7b8790;font-weight:400;line-height:1.35}
@media(max-width:1200px){.document-filterbar{overflow-x:auto}.document-filters{overflow:visible}.document-tools input{width:300px}}
@media(max-width:850px){.document-filterbar{align-items:center;overflow-x:auto}.document-filters{overflow:visible;flex:0 0 auto}.document-tools{flex:0 0 auto}.document-tools input{width:250px}.toolbar #manualBatch{order:3}}

#dashboard .overview-metrics.financial-hidden{grid-template-columns:repeat(3,minmax(220px,1fr))}
@media(max-width:1380px){#dashboard .overview-metrics.financial-hidden{grid-template-columns:repeat(2,minmax(220px,1fr))}}
@media(max-width:1050px){#dashboard .overview-metrics.financial-hidden{grid-template-columns:1fr 1fr}}
@media(max-width:650px){#dashboard .overview-metrics.financial-hidden{grid-template-columns:1fr}}

/* V1.0.24 — permissões efetivas, filtros de execuções e troca de senha */
.jobs-filterbar{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;padding:8px 10px;margin-bottom:8px;border:1px solid #dde4e8;border-radius:8px;background:#fff;flex-wrap:wrap}
.jobs-filtergroup{display:flex;align-items:flex-end;gap:7px;flex-wrap:wrap}.jobs-filtergroup label{display:flex;flex-direction:column;gap:4px;font-size:10.5px;color:#6b7780}.jobs-filtergroup input,.jobs-filtergroup select{height:31px;min-width:145px}.jobs-filtergroup select{min-width:180px}.jobs-filtergroup .small{height:31px}
.password-modalbox{width:min(470px,96vw)}.password-show{display:flex;align-items:center;gap:7px;margin-top:11px;font-size:11px;color:#68757e;cursor:pointer}.password-show input{width:auto;height:auto}.userchip{cursor:pointer}.userchip:hover{background:#f7f9fa;border-color:#c8d2d8;color:#34434c}
#passwordForm .modalfield input{width:100%;height:36px}.perm-hidden{display:none!important}
@media(max-width:850px){.jobs-filterbar{align-items:stretch}.jobs-filtergroup{width:100%}.jobs-filtergroup label{flex:1;min-width:135px}.jobs-filtergroup input,.jobs-filtergroup select{width:100%;min-width:0}.toolbar .userchip{display:inline-flex;max-width:190px;overflow:hidden;text-overflow:ellipsis}}

/* V1.0.25 — ações compactas em cabeçalhos */
.panel-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.panel-actions select{min-width:120px}
