/* Preview viewport only: retain original document geometry, never recolor its art. */
.document-preview #mandadoPrisaoContainer,
.document-preview #sentencaJulgamentoContainer,
.document-preview #criminalNegativaContainer { width:1414px; min-width:1414px; margin:0; background:#fff; color:#000; }
.document-preview #mandadoPrisaoContainer .mandadoPrisao { margin-top:0!important; }
.document-preview #dadosCertidao > .container { display:flex; flex-wrap:wrap; gap:12px; padding:16px 0; margin:0; }
.document-preview #dadosCertidao > .container button { margin:0!important; min-height:44px; white-space:normal; }
/* Applies to the original documents in both preview and isolated export clones.
   Preserve newlines and every character; capacity is checked before downloading. */
:is(#mandadoPrisaoContainer, #sentencaJulgamentoContainer, #criminalNegativaContainer) .descricao {
    overflow-wrap:anywhere;
    /* html2canvas 1.3 recognizes break-all, but not overflow-wrap:anywhere alone. */
    word-break:break-all;
    white-space:pre-wrap!important;
}
/* Keep oversized preview text inside its paper, never over the real controls.
   Export uses an unclipped isolated copy and rejects capacity overflow. */
.document-preview :is(#mandadoPrisaoContainer, #sentencaJulgamentoContainer, #criminalNegativaContainer) {
    overflow:hidden;
}
.document-preview .legal-capacity-warning { color:#ffd2cc; padding:12px; border:1px solid currentColor; border-radius:8px; }
/* Transient messages must not block form/export controls on narrow screens. */
.document-page #notificationContainer { pointer-events:none; }
.document-page #notificationContainer button { pointer-events:auto; }
