.pe-hidden{display:none!important}
body.pe-open{overflow:hidden}
.pe-root{position:fixed;z-index:99999;inset:0;background:#eef2f7;color:#172033;font-family:Segoe UI,Arial,sans-serif;line-height:1.35}
.pe-root *{box-sizing:border-box}
.pe-shell{height:100%;display:grid;grid-template-rows:auto 1fr;min-width:0}
.pe-toolbar{height:auto;min-height:58px;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:10px 16px;background:#102a43;color:#fff;box-shadow:0 2px 10px #0002}
.pe-toolbar strong{display:block;font-size:16px}.pe-toolbar small{display:block;color:#c8d9e8;margin-top:2px;font-size:11px}
.pe-toolbar button,.pe-settings button,.pe-preview-toolbar button{font:inherit;border:1px solid #cbd5e1;border-radius:8px;background:#fff;color:#172033;padding:9px 12px;cursor:pointer}.pe-primary{background:#175cd3!important;border-color:#175cd3!important;color:#fff!important}
.pe-workspace{display:grid;grid-template-columns:320px minmax(0,1fr);min-height:0}
/* isolamento contra o aside global da aplicação */
.pe-settings{display:grid!important;grid-template-rows:auto minmax(0,1fr) auto!important;gap:0!important;min-width:0;overflow:hidden;background:#fff!important;color:#172033!important;border-right:1px solid #dce4ec;padding:0!important}
.pe-settings-head{padding:16px 18px 12px;border-bottom:1px solid #e5eaf0;background:#fff}.pe-settings-head h3{margin:0 0 4px;font-size:16px;color:#172033}.pe-settings-head p{margin:0;color:#64748b;font-size:12px;line-height:1.4}
.pe-settings-scroll{min-height:0;overflow:auto;padding:12px 18px 18px;scrollbar-gutter:stable}
.pe-settings-group{padding:0 0 14px;margin:0 0 14px;border-bottom:1px solid #edf1f5}.pe-settings-group:last-child{border-bottom:0;margin-bottom:0}.pe-settings-group-title{margin:0 0 8px;font-size:11px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:#64748b}
.pe-settings label{display:grid!important;grid-template-columns:1fr!important;gap:5px!important;margin:10px 0!important;color:#334155!important;font-size:12px!important;font-weight:700!important;line-height:1.25!important}
.pe-settings input,.pe-settings select{display:block;width:100%!important;min-width:0;padding:9px 10px!important;border:1px solid #cbd5e1!important;border-radius:8px!important;background:#fff!important;color:#172033!important;font:inherit!important;box-shadow:none!important}
.pe-settings input:focus,.pe-settings select:focus{outline:none;border-color:#175cd3!important;box-shadow:0 0 0 3px #175cd31c!important}
.pe-settings .pe-check{display:grid!important;grid-template-columns:18px minmax(0,1fr)!important;align-items:start!important;gap:8px!important;margin:8px 0!important;color:#334155!important;font-weight:500!important;cursor:pointer}.pe-settings .pe-check input{width:16px!important;height:16px!important;margin:1px 0 0!important;padding:0!important;accent-color:#175cd3}
.pe-secondary-action{width:100%;margin-top:4px}.pe-settings-footer{padding:12px 18px 14px;border-top:1px solid #dce4ec;background:#fff;box-shadow:0 -6px 18px #0f172a0a}.pe-settings-footer .pe-primary{width:100%;font-weight:700}.pe-settings-footer small{display:block;margin-top:7px;color:#64748b;font-size:10.5px;line-height:1.35}
.pe-hint{font-size:11px;line-height:1.45;color:#64748b;margin:8px 0 0}
.pe-stage{min-width:0;overflow:auto;padding:18px 22px 30px}
.pe-editor-panel{width:min(1180px,100%);margin:0 auto}.pe-editor-head,.pe-preview-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.pe-editor-head span{font-weight:700}.pe-editor-head small{color:#64748b}.pe-editor{min-height:calc(100vh - 120px);background:#fff;border:1px solid #dce4ec;border-radius:10px;box-shadow:0 8px 28px #0f172a14;padding:26px 28px;outline:none;font-family:Arial,sans-serif;line-height:1.5;overflow-x:auto}.pe-editor:focus{border-color:#175cd3;box-shadow:0 0 0 3px #175cd322}
.pe-editor table,.pe-page-body table{width:100%;border-collapse:collapse;margin:10px 0 14px;table-layout:auto}.pe-editor th,.pe-editor td,.pe-page-body th,.pe-page-body td{border:1px solid #9aa4b2;padding:5px 6px;vertical-align:top;overflow-wrap:break-word;word-break:normal}.pe-editor th,.pe-page-body th{background:#eef2f6;text-align:left}.pe-editor .pe-code-cell,.pe-page-body .pe-code-cell{white-space:nowrap;overflow-wrap:normal;word-break:normal}.pe-editor .pe-short-cell,.pe-page-body .pe-short-cell{white-space:nowrap}
.pe-editor table.pe-table-wide,.pe-page-body table.pe-table-wide{font-size:.86em}.pe-editor table.pe-table-wide th,.pe-editor table.pe-table-wide td,.pe-page-body table.pe-table-wide th,.pe-page-body table.pe-table-wide td{padding:4px 5px}.pe-page-body table.pe-table-xwide{font-size:.78em}.pe-page-body table.pe-table-xwide th,.pe-page-body table.pe-table-xwide td{padding:3px 4px}
.pe-editor table.pe-curricular-report col:nth-child(1),.pe-page-body table.pe-curricular-report col:nth-child(1){width:12%}.pe-editor table.pe-curricular-report col:nth-child(2),.pe-page-body table.pe-curricular-report col:nth-child(2){width:13%}.pe-editor table.pe-curricular-report col:nth-child(3),.pe-page-body table.pe-curricular-report col:nth-child(3){width:27%}.pe-editor table.pe-curricular-report col:nth-child(4),.pe-page-body table.pe-curricular-report col:nth-child(4){width:13%}.pe-editor table.pe-curricular-report col:nth-child(5),.pe-page-body table.pe-curricular-report col:nth-child(5){width:7%}.pe-editor table.pe-curricular-report col:nth-child(6),.pe-page-body table.pe-curricular-report col:nth-child(6){width:10%}.pe-editor table.pe-curricular-report col:nth-child(7),.pe-page-body table.pe-curricular-report col:nth-child(7){width:18%}
.pe-manual-break{margin:18px 0;border-top:2px dashed #ef8354;text-align:center;color:#b54708;user-select:none}.pe-manual-break span{position:relative;top:-10px;background:#fff;padding:0 10px;font-size:12px}
.pe-preview-panel{min-width:0}.pe-preview-toolbar{position:sticky;top:-18px;z-index:3;background:#eef2f7;padding:8px 0 10px}.pe-preview-toolbar span{color:#475569;font-weight:600}.pe-preview-pages{display:flex;flex-direction:column;align-items:center;gap:14mm;padding-bottom:30px;zoom:.68}.pe-a4-page{box-sizing:border-box;width:210mm;height:297mm;background:#fff;box-shadow:0 4mm 12mm #0f172a26;padding:var(--pe-margin);display:grid;grid-template-rows:auto minmax(0,1fr) auto;font-family:Arial,sans-serif;font-size:var(--pe-font-size);line-height:1.42;overflow:hidden}.pe-page-header{min-height:14mm;border-bottom:.35mm solid #334155;padding-bottom:3mm;margin-bottom:4mm;display:flex;flex-direction:column;justify-content:flex-end}.pe-page-header strong{font-size:1.25em}.pe-page-header span{font-size:.86em;color:#475569;margin-top:1mm}.pe-page-header-empty{visibility:hidden}.pe-page-body{min-height:0;overflow:hidden}.pe-page-body h1,.pe-page-body h2,.pe-page-body h3{page-break-after:avoid}.pe-page-body p{margin:2.5mm 0}.pe-page-body ol,.pe-page-body ul{margin-top:2mm}.pe-page-body .pe-question,.pe-page-body .print-block{break-inside:avoid;margin-bottom:5mm}.pe-page-footer{min-height:8mm;border-top:.25mm solid #94a3b8;padding-top:2.5mm;margin-top:4mm;display:flex;align-items:flex-start;justify-content:space-between;gap:8mm;font-size:.78em;color:#64748b}.pe-page-footer-empty{visibility:hidden}.pe-justify .pe-page-body p{text-align:justify}.pe-page-body a{color:inherit;text-decoration:none}.pe-page-body .tag,.pe-page-body .bpc-chip{display:inline-block;border:1px solid #cbd5e1;border-radius:999px;padding:1mm 2mm;background:#f8fafc}.pe-page-body .card{border:1px solid #cbd5e1;border-radius:2mm;padding:3mm;margin:3mm 0;box-shadow:none;background:#fff}.pe-page-body .detail-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:2mm 5mm}.pe-page-body .detail-grid small{display:block;color:#64748b}.pe-page-body .detail-grid strong{display:block}.pe-page-body .result-summary{margin:0 0 4mm;background:#f1f5f9;padding:3mm;border-radius:2mm}
.pe-print-frame{position:fixed!important;right:0!important;bottom:0!important;width:1px!important;height:1px!important;border:0!important;opacity:.001!important;pointer-events:none!important}
@media(max-width:1100px){.pe-workspace{grid-template-columns:290px minmax(0,1fr)}.pe-stage{padding-left:14px;padding-right:14px}.pe-editor{padding:22px 20px}}
@media(max-width:900px){.pe-workspace{grid-template-columns:1fr}.pe-settings{display:none!important}.pe-stage{padding:12px}.pe-preview-pages{zoom:.46}.pe-editor-head small{display:none}}
@media print{@page{size:A4 portrait;margin:0}html,body{margin:0!important;padding:0!important;background:#fff!important}body.pe-print-active>*:not(#printEngineRoot){display:none!important}body.pe-print-active #printEngineRoot{position:static!important;inset:auto!important;display:block!important;background:#fff!important;color:#172033!important}body.pe-print-active .pe-toolbar,body.pe-print-active .pe-settings,body.pe-print-active .pe-editor-panel,body.pe-print-active .pe-preview-toolbar{display:none!important}body.pe-print-active .pe-workspace,body.pe-print-active .pe-stage,body.pe-print-active .pe-preview-panel{display:block!important;padding:0!important;margin:0!important;overflow:visible!important}body.pe-print-active .pe-preview-pages{display:block!important;zoom:1!important;padding:0!important}body.pe-print-active .pe-a4-page{display:grid!important;box-shadow:none!important;margin:0!important;break-after:page;page-break-after:always;transform:none!important;zoom:1!important}body.pe-print-active .pe-page-header{display:flex!important}body.pe-print-active .pe-page-footer{display:flex!important}body.pe-print-active .pe-page-header-empty,body.pe-print-active .pe-page-footer-empty{visibility:hidden!important}body.pe-print-active .pe-a4-page:last-child{break-after:auto;page-break-after:auto}}

.pe-editor table.pe-computation-report col:nth-child(1),.pe-page-body table.pe-computation-report col:nth-child(1){width:11%}
.pe-editor table.pe-computation-report col:nth-child(2),.pe-page-body table.pe-computation-report col:nth-child(2){width:27%}
.pe-editor table.pe-computation-report col:nth-child(3),.pe-page-body table.pe-computation-report col:nth-child(3){width:8%}
.pe-editor table.pe-computation-report col:nth-child(4),.pe-page-body table.pe-computation-report col:nth-child(4){width:14%}
.pe-editor table.pe-computation-report col:nth-child(5),.pe-page-body table.pe-computation-report col:nth-child(5){width:20%}
.pe-editor table.pe-computation-report col:nth-child(6),.pe-page-body table.pe-computation-report col:nth-child(6){width:20%}

/* Relatório da Base Municipal */
.pe-editor table.pe-municipal-report col:nth-child(1),.pe-page-body table.pe-municipal-report col:nth-child(1){width:10%}
.pe-editor table.pe-municipal-report col:nth-child(2),.pe-page-body table.pe-municipal-report col:nth-child(2){width:7%}
.pe-editor table.pe-municipal-report col:nth-child(3),.pe-page-body table.pe-municipal-report col:nth-child(3){width:11%}
.pe-editor table.pe-municipal-report col:nth-child(4),.pe-page-body table.pe-municipal-report col:nth-child(4){width:16%}
.pe-editor table.pe-municipal-report col:nth-child(5),.pe-page-body table.pe-municipal-report col:nth-child(5){width:18%}
.pe-editor table.pe-municipal-report col:nth-child(6),.pe-page-body table.pe-municipal-report col:nth-child(6){width:20%}
.pe-editor table.pe-municipal-report col:nth-child(7),.pe-page-body table.pe-municipal-report col:nth-child(7){width:18%}
