/* Editor de risco cirúrgico: estilos de tela sobre os tokens do design system Biocardio.
   Carregar depois de assets/design-system/tokens.css e components.css.
   Cores, raios, sombras e tipografia vêm só de variáveis. O laudo impresso, no fim
   do arquivo, continua preto no branco por ser documento clínico. */

* { margin: 0; padding: 0; box-sizing: border-box; }

/* Tema escolhido pelo usuário (claro por padrão); controles nativos acompanham */
[data-theme="light"] { color-scheme: light; }
[data-theme="dark"] { color-scheme: dark; }

body {
    background: var(--surface-muted);
    color: var(--ink);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 26px;
    min-height: 100vh;
}

h1, h2, h3 { font-weight: 600; color: var(--ink); }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Ícones Lucide: tamanho e traço do manual da marca */
svg.lucide {
    width: 20px;
    height: 20px;
    stroke-width: 2;
    flex: none;
}

/* ===== Cabeçalho ===== */
.header {
    background: var(--surface-raised);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    padding: var(--space-3) 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

/* Mesma caixa do conteúdo (.editor-intro e .main-container): 1200px com recuo lateral igual */
.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-5);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-5);
}

.brand-identity {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    min-width: 0;
}

.brand-logo {
    display: inline-flex;
    align-items: center;
    gap: var(--space-3);
    text-decoration: none;
    color: var(--ink);
    flex: none;
    border-radius: var(--radius-sm);
}

.brand-logo:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
.brand-logo .brand-mark { width: 40px; height: 40px; display: block; }
.brand-mark { color: var(--primary); }
[data-theme="dark"] .brand-mark { color: var(--ink); }
.brand-wordmark { font: 600 18px/24px var(--font-sans); white-space: nowrap; letter-spacing: -.01em; }

/* Nome da clínica (personalização) e texto do cabeçalho, alinhados pela linha de base do nome do produto */
.brand-copy { display: flex; flex-direction: column; justify-content: center; min-width: 0; min-height: 40px; padding-left: var(--space-4); border-left: 1px solid var(--border); }
.brand-name:empty { display: none; }
.brand-name { font-size: 16px; line-height: 20px; font-weight: 600; color: var(--ink); }
.brand-identity h1 {
    font-size: 14px;
    line-height: 20px;
    font-weight: 400;
    color: var(--ink-muted);
}

.header-actions { display: flex; align-items: center; gap: var(--space-3); flex-wrap: wrap; }

.nav-badge { white-space: nowrap; }
.nav-badge svg.lucide { width: 16px; height: 16px; }

.theme-toggle { width: 40px; height: 40px; padding: 0; justify-content: center; }
.theme-toggle svg.lucide { width: 20px; height: 20px; }

/* ===== Botões ===== */
.bc-btn svg.lucide { width: 18px; height: 18px; }

/* ===== Diálogo de personalização ===== */
.settings-dialog {
    margin: auto;
    width: min(520px, calc(100vw - 2rem));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 0;
    color: var(--ink);
    background: var(--surface-raised);
    box-shadow: var(--shadow-md);
}

.settings-dialog::backdrop { background: rgba(3, 44, 87, 0.55); }
.settings-form { padding: var(--space-5); }
.settings-title { font-size: 24px; line-height: 32px; margin-bottom: var(--space-1); }
.settings-help { color: var(--ink-muted); font-size: 14px; line-height: 22px; margin-bottom: var(--space-5); }
.settings-field { display: block; margin-bottom: var(--space-4); }
.settings-field span { display: block; font-size: 14px; line-height: 20px; font-weight: 500; margin-bottom: 6px; }
.settings-field input,
.settings-field textarea {
    width: 100%;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-md);
    padding: 11px 14px;
    font: 400 16px/24px var(--font-sans);
    color: var(--ink);
    background: var(--surface-raised);
}
.settings-field textarea { resize: vertical; min-height: 76px; }
.settings-actions { display: flex; justify-content: flex-end; gap: var(--space-3); margin-top: var(--space-5); flex-wrap: wrap; }

/* ===== Área principal ===== */
.main-container {
    max-width: 1200px;
    margin: var(--space-6) auto;
    padding: 0 var(--space-5);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-5);
}

.card {
    background: var(--surface-raised);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.card-header {
    padding: var(--space-4) var(--space-5);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.card-header h2 { font-size: 18px; line-height: 26px; }

.card-header .icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--primary-soft);
    color: var(--primary);
    display: grid;
    place-items: center;
    flex: none;
}

.card-header .icon svg.lucide { width: 22px; height: 22px; }

.card-body { padding: var(--space-5); }

/* ===== Preditores do RCRI ===== */
.variable-group {
    margin-bottom: var(--space-3);
    padding: var(--space-4);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-raised);
    transition: border-color .15s, background-color .15s;
}

.variable-group:hover { border-color: var(--border-strong); }

.variable-group.active {
    border-color: var(--primary);
    background: var(--primary-soft);
}

.variable-label {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    cursor: pointer;
    user-select: none;
}

.variable-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 3px;
    accent-color: var(--primary);
    cursor: pointer;
    flex: none;
}

.variable-label .title { font-weight: 600; font-size: 16px; line-height: 26px; }
.variable-label .description { font-size: 14px; line-height: 22px; color: var(--ink-muted); }

/* ===== Classificação de risco ===== */
.risk-display {
    text-align: center;
    padding: var(--space-5);
    border-radius: var(--radius-lg);
    border: 1px solid transparent;
    margin-top: var(--space-5);
    transition: background-color .15s, color .15s;
}

.risk-class-1 { background: var(--success-soft); color: var(--success); border-color: var(--success); }
.risk-class-2 { background: var(--primary-soft); color: var(--blue-700); border-color: var(--primary); }
.risk-class-3 { background: var(--warning-soft); color: var(--warning); border-color: var(--warning); }
.risk-class-4 { background: var(--danger-soft); color: var(--danger); border-color: var(--danger); }

.risk-display .class-name { font-size: 24px; line-height: 32px; font-weight: 600; }
.risk-display .class-description { font-size: 16px; line-height: 26px; font-weight: 500; }
.risk-display .score { font-size: 48px; line-height: 56px; font-weight: 700; margin: var(--space-1) 0; }
.risk-display .score-label { font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }

/* ===== Chips ===== */
.chips-container { margin-top: var(--space-5); }

.chips-title {
    font-size: 12px;
    line-height: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--ink-muted);
    margin-bottom: var(--space-3);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-2);
}

.chips-title > span:first-child { display: inline-flex; align-items: center; gap: var(--space-2); }
.chips-title svg.lucide { width: 18px; height: 18px; color: var(--primary); }

.chips-count {
    background: var(--primary);
    color: var(--on-primary);
    border-radius: var(--radius-pill);
    padding: 0 8px;
    font-size: 12px;
    line-height: 20px;
    font-weight: 600;
    letter-spacing: 0;
    display: none;
}

.chips-count.show { display: inline-block; }

.chips-group {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
    margin-bottom: var(--space-4);
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background-color .15s, color .15s, border-color .15s;
    user-select: none;
}

.chip:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Categorias: azul (comorbidades), âmbar (medicamentos), verde (procedimentos), azul escuro (exames) */
.chip-disease { background: var(--primary-soft); color: var(--blue-700); border-color: var(--primary); }
.chip-disease:hover, .chip-disease.active { background: var(--primary); color: var(--on-primary); }

.chip-medication { background: var(--warning-soft); color: var(--warning); border-color: var(--warning); }
.chip-medication:hover, .chip-medication.active { background: var(--warning); color: var(--surface); }

.chip-procedure { background: var(--success-soft); color: var(--success); border-color: var(--success); }
.chip-procedure:hover, .chip-procedure.active { background: var(--success); color: var(--surface); }

.chip-exam { background: var(--blue-100); color: var(--blue-900); border-color: var(--blue-700); }
.chip-exam:hover, .chip-exam.active { background: var(--blue-700); color: var(--surface); }

.chip-custom { position: relative; }
.chip-remove {
    display: inline-grid;
    place-items: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    opacity: .7;
    cursor: pointer;
}
.chip-remove svg.lucide { width: 14px; height: 14px; }
.chip-remove:hover { opacity: 1; background: var(--danger-soft); color: var(--danger); }

/* ===== Painel de exames ===== */
.exam-panel {
    display: none;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-muted);
    padding: var(--space-3);
    margin: calc(-1 * var(--space-1)) 0 var(--space-4);
}

.exam-panel.show { display: grid; gap: var(--space-3); }

.exam-row {
    display: grid;
    grid-template-columns: minmax(160px, 1fr) auto;
    gap: var(--space-3);
    align-items: center;
    padding: var(--space-3);
    background: var(--surface-raised);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
}

.exam-name { font-size: 14px; line-height: 20px; font-weight: 600; color: var(--ink); }

.exam-status {
    display: inline-flex;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--surface-raised);
    justify-self: end;
}

.exam-status button {
    height: 36px;
    border: none;
    background: transparent;
    padding: 0 var(--space-3);
    color: var(--ink);
    font: 500 14px/20px var(--font-sans);
    cursor: pointer;
}

.exam-status button.active { background: var(--primary); color: var(--on-primary); }

.exam-note {
    display: none;
    grid-column: 1 / -1;
    width: 100%;
    min-height: 74px;
    max-height: 160px;
    resize: vertical;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-md);
    padding: 10px 12px;
    font: 400 16px/24px var(--font-sans);
    color: var(--ink);
    background: var(--surface-raised);
}

.exam-note.show { display: block; }
.exam-note:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ===== Item personalizado ===== */
.chip-add {
    display: flex;
    gap: var(--space-2);
    margin-top: calc(-1 * var(--space-2));
    margin-bottom: var(--space-4);
}

.chip-add input {
    flex: 1;
    min-width: 0;
    padding: 6px 14px;
    border: 1px dashed var(--border-strong);
    border-radius: var(--radius-pill);
    font: 400 14px/22px var(--font-sans);
    color: var(--ink);
    background: var(--surface-raised);
}

.chip-add input::placeholder { color: var(--ink-muted); }
.chip-add input:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-style: solid; }

.chip-add button {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    border: 1px solid var(--primary);
    background: transparent;
    color: var(--primary);
    border-radius: var(--radius-pill);
    padding: 0 14px;
    font: 500 14px/20px var(--font-sans);
    cursor: pointer;
    transition: background-color .15s, color .15s;
}

.chip-add button svg.lucide { width: 16px; height: 16px; }
.chip-add button:hover { background: var(--primary-soft); }

/* ===== Barra de ferramentas do laudo ===== */
.editor-toolbar {
    display: flex;
    gap: 2px;
    padding: var(--space-2);
    background: var(--surface-muted);
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    border: 1px solid var(--border);
    border-bottom: none;
    flex-wrap: wrap;
    align-items: center;
}

.editor-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 var(--space-2);
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font: 500 14px/20px var(--font-sans);
    color: var(--ink);
    transition: background-color .15s, box-shadow .15s;
}

.editor-btn svg.lucide { width: 18px; height: 18px; }
.editor-btn:hover { background: var(--surface-raised); box-shadow: var(--shadow-sm); }
.editor-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

.editor-select {
    height: 36px;
    border: 1px solid var(--border);
    background: var(--surface-raised);
    border-radius: var(--radius-sm);
    font: 400 14px/20px var(--font-sans);
    padding: 0 var(--space-2);
    cursor: pointer;
    color: var(--ink);
}

.editor-color {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    cursor: pointer;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font: 600 14px/20px var(--font-sans);
    color: var(--ink);
}

.editor-color svg.lucide { width: 18px; height: 18px; }
.editor-color-highlight { background: var(--warning-soft); color: var(--warning); }
.editor-color:hover { background: var(--surface-raised); box-shadow: var(--shadow-sm); }

.editor-color input[type="color"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
}

.editor-divider { width: 1px; align-self: stretch; background: var(--border); margin: 4px var(--space-2); }

/* ===== Pré-visualização do laudo ===== */
.report-preview {
    background: var(--surface-raised);
    border: 1px solid var(--border);
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    padding: var(--space-5);
    font-size: 16px;
    line-height: 26px;
    position: relative;
}

.report-live-badge { margin-bottom: var(--space-4); }
.report-live-badge::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

/* Avisos de edição manual e de conferência do RCRI seguem o Alert do design system */
.report-stale-notice {
    display: none;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-3);
    margin-top: var(--space-3);
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    background: var(--warning-soft);
    color: var(--ink);
    font-size: 14px;
    line-height: 22px;
}

.report-stale-notice:not([hidden]) { display: flex; }
.report-stale-notice p { flex: 1 1 220px; margin: 0; font-weight: 500; }

.rcri-inconsistency {
    display: none;
    margin-top: var(--space-4);
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    background: var(--warning-soft);
    color: var(--ink);
    font-size: 14px;
    line-height: 22px;
}

.rcri-inconsistency:not([hidden]) { display: flex; gap: var(--space-3); }
.rcri-inconsistency .bc-alert-icon { background: var(--warning); }
.rcri-inconsistency strong { color: var(--warning); }
.rcri-inconsistency ul { margin: var(--space-2) 0 0 var(--space-4); }
.rcri-inconsistency li { margin: 4px 0; }

#reportContent ul, #reportContent ol { margin: var(--space-1) 0 var(--space-1) var(--space-5); }
#reportContent .report-section-label { color: var(--primary); }
#reportContent { min-height: 220px; outline: none; border-radius: var(--radius-sm); }
#reportContent:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }

/* ===== Dados do paciente ===== */
.patient-fields {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: var(--space-3);
    margin-bottom: var(--space-4);
}

.patient-field label {
    display: block;
    font: 500 14px/20px var(--font-sans);
    color: var(--ink);
    margin-bottom: 6px;
}

.patient-field input,
.patient-field select {
    width: 100%;
    height: 46px;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-md);
    padding: 0 14px;
    font: 400 16px/24px var(--font-sans);
    color: var(--ink);
    background: var(--surface-raised);
}

.patient-field input::placeholder { color: var(--ink-muted); }
.patient-field input:focus-visible,
.patient-field select:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ===== Ações do laudo ===== */
.action-buttons {
    display: flex;
    gap: var(--space-3);
    margin-top: var(--space-5);
    flex-wrap: wrap;
}

.medical-disclaimer { margin-top: var(--space-4); font-size: 14px; line-height: 22px; }
.medical-disclaimer .bc-alert-icon svg.lucide { width: 14px; height: 14px; color: var(--surface); }

/* ===== Toast ===== */
.toast {
    position: fixed;
    bottom: var(--space-6);
    right: var(--space-6);
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    background: var(--gray-900);
    color: var(--surface);
    padding: var(--space-3) var(--space-4);
    border-radius: var(--radius-md);
    font: 500 14px/20px var(--font-sans);
    box-shadow: var(--shadow-md);
    transform: translateY(100px);
    opacity: 0;
    transition: transform .15s, opacity .15s;
    z-index: 1000;
    max-width: min(420px, calc(100vw - 2 * var(--space-6)));
}

.toast svg.lucide { width: 18px; height: 18px; }
.toast.show { transform: translateY(0); opacity: 1; }

.full-width { grid-column: 1 / -1; }

/* ===== Itens selecionados ===== */
.selected-items {
    margin-top: var(--space-3);
    padding: var(--space-3);
    background: var(--surface-muted);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    min-height: 54px;
}

.selected-empty { font-size: 14px; line-height: 22px; color: var(--ink-muted); }
.selected-cat { margin-bottom: var(--space-3); }
.selected-cat:last-child { margin-bottom: 0; }

.selected-cat-label {
    font-size: 12px;
    line-height: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--ink-muted);
    margin-bottom: var(--space-2);
}

.selected-tags-row { display: flex; flex-wrap: wrap; gap: var(--space-2); }

.selected-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 10px;
    border-radius: var(--radius-pill);
    font: 500 14px/20px var(--font-sans);
}

.selected-tag.cat-disease { background: var(--primary-soft); color: var(--blue-700); }
.selected-tag.cat-medication { background: var(--warning-soft); color: var(--warning); }
.selected-tag.cat-procedure { background: var(--success-soft); color: var(--success); }
.selected-tag.cat-exam { background: var(--blue-100); color: var(--blue-900); }

.selected-tag .remove {
    display: inline-grid;
    place-items: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    cursor: pointer;
    opacity: .75;
}
.selected-tag .remove svg.lucide { width: 14px; height: 14px; }
.selected-tag .remove:hover { opacity: 1; background: var(--surface-raised); }

/* ===== Responsivo ===== */
@media (max-width: 900px) {
    .main-container { grid-template-columns: 1fr; margin-top: var(--space-5); }
    .patient-fields { grid-template-columns: 1fr; }
    .exam-row { grid-template-columns: 1fr; }
    .exam-status { justify-self: start; }
    .header-content { flex-direction: column; align-items: flex-start; gap: var(--space-3); }
    .toast { right: var(--space-4); left: var(--space-4); bottom: var(--space-4); max-width: none; }
}

@media (max-width: 480px) {
    .main-container { padding: 0 var(--space-4); }
    .header-content { padding: 0 var(--space-4); }
    .card-body, .card-header { padding: var(--space-4); }
    .brand-identity { flex-wrap: wrap; }
    .brand-copy { padding-left: 0; border-left: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ===== Prévia de impressão do laudo (documento clínico: preto no branco, sempre) ===== */
.print-report {
    display: block;
    position: relative;
    width: min(794px, calc(100% - 3rem));
    min-height: min(1123px, calc((100vw - 3rem) * 1.414));
    margin: 0 auto var(--space-6);
    padding: 44px 48px 92px;
    background: #fff;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    color: #000;
    font-family: Arial, sans-serif;
    font-size: 14px;
    line-height: 1.35;
}

.print-report::before {
    content: 'Prévia de impressão';
    position: absolute;
    top: -14px;
    left: 24px;
    background: var(--surface-muted);
    color: var(--ink-muted);
    padding: 0 var(--space-2);
    font: 600 12px/16px var(--font-sans);
    letter-spacing: .1em;
    text-transform: uppercase;
}

.print-report-header {
    border-bottom: 1px solid #111;
    margin-bottom: 10pt;
    padding-bottom: 6pt;
    display: flex;
    justify-content: space-between;
    gap: 12pt;
    align-items: center;
}

.print-brand { display: flex; align-items: center; gap: 7pt; }
.print-report-date { font-size: 13px; color: #333; font-weight: 700; white-space: nowrap; }

.print-report-title {
    font-size: 12pt;
    line-height: 1.2;
    text-align: center;
    text-transform: uppercase;
    margin: 0 0 10pt;
    letter-spacing: 0;
    color: #000;
    font-weight: 700;
}

.print-patient-data { border: 1px solid #111; display: grid; grid-template-columns: 1.8fr 1fr; margin-bottom: 10pt; }
.print-patient-item { padding: 5pt 7pt; min-height: 24pt; }
.print-patient-item + .print-patient-item { border-left: 1px solid #111; }
.print-patient-label { display: block; font-size: 7.5pt; font-weight: 700; text-transform: uppercase; color: #333; margin-bottom: 2pt; }
.print-patient-value { font-size: 10.5pt; font-weight: 700; }
.print-report-content { max-width: 100%; }
.print-report-content p { margin: 0 0 6pt; }
.print-report-content ul, .print-report-content ol { margin: 0 0 6pt 16pt; }
.print-report-content .report-section-label { color: #000; }

.print-report-footer {
    position: absolute;
    left: 48px;
    right: 48px;
    bottom: 28px;
    border-top: 1px solid #c7c7c7;
    padding-top: 3pt;
    color: #000;
    font-size: 10pt;
    line-height: 1.25;
    font-style: italic;
}

.print-report-footer div { margin: 0; }
#printBrandFooter { white-space: pre-line; }

@media print {
    @page { size: A4; margin: 8mm 10mm; }
    * { box-shadow: none !important; text-shadow: none !important; }
    body { background: #fff; color: #000; min-height: auto; font-family: Arial, sans-serif; margin: 0; }
    html, body { width: auto; height: auto; overflow: visible; }
    body > :not(.print-report) { display: none !important; }

    .print-report {
        display: flex;
        flex-direction: column;
        position: relative;
        width: 100%;
        height: auto;
        min-height: calc(297mm - 16mm);
        margin: 0;
        padding: 0 2mm 2mm;
        border: 0;
        box-shadow: none;
        box-sizing: border-box;
        color: #000;
        font-size: 10.5pt;
        line-height: 1.35;
        overflow: visible;
    }

    .print-report::before { content: none; }
    .print-report-date { font-size: 11pt; }
    .print-report-content { flex: 1 0 auto; }
    .print-report-footer { position: static; margin-top: auto; background: #fff; }
}

/* ===== Pedido opcional de contato ao baixar o PDF ===== */
.lead-consent { display: flex; align-items: flex-start; gap: var(--space-2); font-size: 14px; line-height: 22px; margin-bottom: var(--space-3); cursor: pointer; }
.lead-consent input { margin: 3px 0 0; width: 18px; height: 18px; flex: none; accent-color: var(--primary); }
.lead-dialog .bc-field-error { margin-bottom: var(--space-3); }
.lead-dialog .bc-field-error[hidden] { display: none; }
.lead-dialog input[aria-invalid="true"] { border-color: var(--danger); }
.lead-disclaimer { margin-top: var(--space-2); }
.lead-disclaimer p { font-size: 14px; line-height: 22px; color: var(--ink); }
.lead-disclaimer .bc-alert-icon svg.lucide { width: 14px; height: 14px; color: var(--surface); }
.lead-honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
