:root {
    --ink: #14211f;
    --muted: #64716e;
    --line: #dfe7e3;
    --paper: #f6f8f5;
    --card: #ffffff;
    --primary: #0f766e;
    --primary-dark: #0b5c56;
    --accent: #f59e0b;
    --danger: #b42318;
    --success: #087443;
    --shadow: 0 18px 50px rgba(20, 33, 31, .08);
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.5; }
a { color: var(--primary-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.topbar { background: #12322e; color: #fff; border-bottom: 1px solid rgba(255,255,255,.12); }
.topbar-inner { min-height: 72px; display: flex; align-items: center; gap: 24px; }
.brand { color: #fff; font-weight: 800; letter-spacing: -.03em; font-size: 1.15rem; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.nav { display: flex; align-items: center; gap: 16px; flex: 1; }
.mobile-nav-toggle { display: none; border: 1px solid rgba(255,255,255,.35); border-radius: 8px; padding: 8px 11px; background: rgba(255,255,255,.1); color: #fff; font: inherit; font-size: .84rem; font-weight: 750; cursor: pointer; }
.nav a { color: rgba(255,255,255,.78); font-size: .9rem; }
.nav a:hover { color: #fff; }
.user-menu { display: flex; align-items: center; gap: 14px; font-size: .9rem; white-space: nowrap; }
.page-content { padding: 48px 0 80px; min-height: calc(100vh - 140px); }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); line-height: 1.05; letter-spacing: -.055em; margin-bottom: 14px; }
h2 { font-size: 1.25rem; letter-spacing: -.02em; margin-bottom: 18px; }
h3 { margin-bottom: 8px; }
.lead { color: var(--muted); font-size: 1.13rem; max-width: 650px; }
.eyebrow { color: var(--primary); text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; font-weight: 800; margin-bottom: 10px; }
.hero { display: grid; grid-template-columns: 1.45fr .75fr; gap: 42px; align-items: center; padding: 34px 0 56px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 26px; box-shadow: var(--shadow); }
.code-card { padding: 28px; }
.code-card h2 { margin-bottom: 22px; }
.event-summary { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 32px; border-left: 5px solid var(--accent); }
.event-summary h2 { margin-bottom: 5px; }
.event-summary p { margin: 0; color: var(--muted); }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature-grid .card { box-shadow: none; }
.feature-number { display: inline-block; color: var(--accent); font-weight: 800; font-size: .8rem; margin-bottom: 22px; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 30px; }
.page-heading h1 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 8px; }
.page-heading p:not(.eyebrow) { color: var(--muted); margin-bottom: 0; }
.button { display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 10px; padding: 12px 17px; background: var(--primary); color: #fff; font-weight: 750; cursor: pointer; font-size: .92rem; transition: background .2s, transform .2s; }
.button:hover { background: var(--primary-dark); color: #fff; text-decoration: none; transform: translateY(-1px); }
.button-ghost { color: var(--primary-dark); background: #e7f1ed; }
.button-ghost:hover { background: #d6e9e2; color: var(--primary-dark); }
.topbar .button-ghost { color: #d9f1e9; background: rgba(255,255,255,.12); }
.topbar .button-ghost:hover { color: #fff; background: rgba(255,255,255,.2); }
.button-small { padding: 8px 12px; font-size: .8rem; }
.button-danger { background: #b42318; }
.button-danger:hover { background: #8f1d14; }
.button-full { width: 100%; }
.form-card { margin-bottom: 30px; }
.form-section + .form-section { border-top: 1px solid var(--line); margin-top: 30px; padding-top: 30px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field-full { grid-column: 1 / -1; }
label { font-weight: 700; font-size: .88rem; }
input, select { width: 100%; border: 1px solid #cdd9d4; border-radius: 9px; padding: 12px 13px; color: var(--ink); background: #fff; font: inherit; outline: none; }
input:focus, select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(15,118,110,.13); }
input[type="radio"], input[type="checkbox"] { width: auto; accent-color: var(--primary); }
.radio-group { display: flex; gap: 22px; align-items: center; min-height: 46px; }
.radio-group label, .checkbox-field label { display: flex; gap: 9px; align-items: center; font-weight: 500; }
.field small, td small, .muted, .stat-note { color: var(--muted); font-size: .8rem; }
.form-actions { display: flex; gap: 10px; align-items: center; margin-top: 23px; }
.alert { padding: 14px 17px; border-radius: 12px; margin-bottom: 22px; border: 1px solid; }
.alert ul { margin: 4px 0 0 18px; padding: 0; }
.alert-success { color: #075e38; background: #e8f7ef; border-color: #b5e4ca; }
.alert-warning { color: #845400; background: #fff7df; border-color: #f4d27b; }
.alert-danger { color: #8d1c14; background: #fff0ef; border-color: #f2bbb6; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.stat-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; }
.stat-card > span:first-child { color: var(--muted); font-size: .86rem; font-weight: 700; }
.stat-card strong { font-size: 1.9rem; letter-spacing: -.04em; }
.stat-card a { font-size: .84rem; font-weight: 700; }
.section-heading { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.section-heading h2 { margin-bottom: 0; }
.capacity { display: flex; align-items: baseline; gap: 8px; color: var(--muted); }
.capacity strong { font-size: 2rem; color: var(--primary); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th { text-align: left; color: var(--muted); font-size: .72rem; letter-spacing: .07em; text-transform: uppercase; padding: 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 15px 12px; border-bottom: 1px solid #edf1ef; vertical-align: top; }
td strong, td small { display: block; }
td small { margin-top: 3px; }
.actions { white-space: nowrap; }
.event-list-table { min-width: 900px; }
.event-list-table th, .event-list-table td { padding: 12px 10px; }
.event-list-table th:nth-child(1) { width: 9%; }
.event-list-table th:nth-child(2) { width: 20%; }
.event-list-table th:nth-child(3) { width: 10%; }
.event-list-table th:nth-child(4) { width: 12%; }
.event-list-table th:nth-child(5) { width: 18%; }
.event-list-table th:nth-child(6) { width: 7%; }
.event-list-table th:nth-child(7) { width: 10%; }
.event-list-table th:nth-child(8) { width: 9%; }
.event-list-table th:nth-child(9) { width: 20%; }
.event-list-table .actions { white-space: normal; min-width: 190px; line-height: 2; }
.actions a, .link-button { margin-right: 10px; font-size: .82rem; font-weight: 750; }
.inline-form { display: inline; }
.link-button { padding: 0; border: 0; background: none; color: var(--primary-dark); cursor: pointer; font: inherit; }
.link-button:hover { text-decoration: underline; }
.badge { display: inline-block; padding: 4px 8px; border-radius: 999px; font-size: .74rem; font-weight: 800; white-space: nowrap; }
.badge-success { color: #075e38; background: #dcf5e7; }
.badge-danger { color: #8d1c14; background: #ffe2df; }
.badge-muted { color: #5b6662; background: #e9eeeb; }
.empty-cell { text-align: center; color: var(--muted); padding: 32px; }
.filter-card { margin-bottom: 25px; box-shadow: none; }
.room-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-top: 10px; }
.room-distribution-field { grid-column: 1 / -1; }
.room-total { margin: 10px 0 0; font-weight: 800; }
.room-total-ok { color: #075e38; }
.room-total-error { color: #8d1c14; }
.room-plan-table { width: 100%; margin: 0 0 12px; border-collapse: collapse; page-break-inside: avoid; }
.room-plan-table th, .room-plan-table td { border: 1px solid #111; padding: 5px 7px; font-size: .72rem; text-align: left; }
.room-plan-table th { background: #20577d; color: #fff; }
.room-plan-table th:first-child { width: 22%; }
.room-plan-table th:last-child { width: 25%; text-align: center; }
.room-plan-table td:last-child { text-align: center; font-weight: 700; }
.filter-form { display: flex; gap: 16px; align-items: flex-end; }
.filter-form .field { flex: 1; }
.choice-list { display: grid; gap: 10px; }
.choice { display: flex; align-items: flex-start; gap: 12px; border: 1px solid var(--line); border-radius: 12px; padding: 15px; cursor: pointer; font-weight: 500; }
.choice:hover { border-color: var(--primary); background: #f6fbf9; }
.choice span { display: flex; flex-direction: column; gap: 4px; }
.choice small { color: var(--muted); }
.choice .function-info { color: var(--ink); font-size: .9rem; line-height: 1.35; white-space: normal; }
.auth-wrap { min-height: 60vh; display: grid; place-items: center; }
.auth-card { width: min(430px, 100%); }
.auth-card h1 { font-size: 2.1rem; }
.auth-card .field { margin: 18px 0; }
.back-link { display: block; text-align: center; margin-top: 18px; font-size: .9rem; }
.narrow-card { width: min(560px, 100%); margin: 0 auto; }
.empty-state { text-align: center; max-width: 600px; margin: 80px auto; }
.allocation-change { display: flex; gap: 8px; min-width: 230px; }
.allocation-change select { padding: 8px; font-size: .8rem; }
.footer { padding: 26px 0; color: var(--muted); font-size: .8rem; border-top: 1px solid var(--line); }
code { background: #e8efeb; padding: 2px 5px; border-radius: 4px; color: var(--primary-dark); }
@media (max-width: 900px) { .topbar-inner { flex-wrap: wrap; gap: 12px 16px; padding-top: 12px; padding-bottom: 12px; } .mobile-nav-toggle { display: inline-flex; margin-left: auto; } .nav { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; gap: 10px; padding: 8px 0 4px; } .nav.is-open { display: flex; } .nav-group { width: 100%; } .nav-group .nav-toggle { width: 100%; text-align: left; } .nav-submenu { position: static; } .user-menu { margin-left: auto; } .hero { grid-template-columns: 1fr; } .stats-grid { grid-template-columns: repeat(2, 1fr); } .report-metrics .stat-card { min-height: 96px; } }
@media (max-width: 650px) { .container { width: min(100% - 28px, 1180px); } .page-content { padding-top: 30px; } .topbar-inner { min-height: 62px; } .user-menu span { display: none; } .feature-grid, .form-grid, .stats-grid { grid-template-columns: 1fr; } .field-full { grid-column: auto; } .page-heading, .event-summary, .filter-form { align-items: stretch; flex-direction: column; } .page-heading .button, .event-summary .button { width: 100%; } .card { padding: 20px; } .form-actions { flex-wrap: wrap; } .report-metrics .stat-card { min-height: auto; } .report-event-heading { align-items: stretch; flex-direction: column; gap: 12px; } .report-event-total { padding: 10px 0 0; border-left: 0; border-top: 1px solid #cdd9d4; } }

.pix-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(430px, 1fr)); gap: 20px; }
.pix-card { box-shadow: var(--shadow); padding: 18px; }
.pix-card-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.pix-card-head h2 { margin-bottom: 4px; }
.pix-card-head p { margin-bottom: 0; }
.pix-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 12px 0; }
.pix-meta > div { display: flex; flex-direction: column; gap: 4px; }
.pix-secondary { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: stretch; margin-top: 12px; }
.pix-secondary .payment-action, .pix-secondary .payment-audit { margin-top: 0; height: 100%; }
.pix-meta span, .pix-key-box > span, .pix-code > span { color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.pix-meta strong { font-size: .9rem; }
.pix-meta small { color: var(--muted); }
.pix-key-box { display: flex; flex-direction: column; gap: 5px; padding: 12px; background: #f4f8f5; border: 1px solid var(--line); border-radius: 10px; }
.pix-key-box strong { word-break: break-all; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .96rem; }
.pix-key-box small { color: var(--muted); }
.pix-key-box .button { align-self: flex-start; margin-top: 3px; }
.pix-payment { display: grid; grid-template-columns: 155px 1fr; gap: 12px; align-items: center; margin-top: 12px; }
.qr-box { display: flex; flex-direction: column; align-items: center; gap: 5px; text-align: center; }
.qr-box img { width: 140px; height: 140px; image-rendering: pixelated; border: 6px solid #fff; box-shadow: 0 3px 12px rgba(20,33,31,.12); }
.qr-box small { color: var(--muted); font-size: .78rem; }
.qr-missing { color: var(--danger); font-size: .8rem; }
.pix-code { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.pix-code textarea { width: 100%; resize: vertical; font: .72rem/1.35 ui-monospace, SFMono-Regular, Menlo, monospace; background: #172b28; color: #d8f5ea; border: 0; border-radius: 8px; padding: 11px; }
.copy-button { align-self: flex-start; }
@media print { .topbar, .footer, .filter-card, .page-heading .button, .copy-button { display: none !important; } body { background: #fff; } .container { width: 100%; } .page-content { padding: 0; } .pix-grid { grid-template-columns: 1fr 1fr; } .pix-card { box-shadow: none; break-inside: avoid; } }
@media (max-width: 650px) { .pix-grid { grid-template-columns: 1fr; } .pix-meta, .pix-payment, .pix-secondary { grid-template-columns: 1fr; } }

.payment-action { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; padding: 11px; background: #fff9e8; border: 1px solid #f2d48a; border-radius: 10px; }
.payment-buttons { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.payment-buttons .button { margin: 0; }
.payment-buttons .button:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.payment-action label { font-size: .78rem; color: #75510a; }
.payment-action input { background: #fff; }
.payment-action .button { align-self: flex-start; }
.payment-audit { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; margin-top: 12px; padding: 10px 12px; border-radius: 10px; color: #075e38; background: #e8f7ef; border: 1px solid #b5e4ca; font-size: .86rem; }
.payment-audit small { flex-basis: 100%; color: #3e6d55; }
.pix-secondary .payment-audit { align-content: center; }

.payment-sheet { width: 100%; border-collapse: collapse; background: #fff; color: #111; margin: 0 0 24px; table-layout: fixed; }
.payment-sheet th, .payment-sheet td { border: 1px solid #111; }
.sheet-head-cell { padding: 0; border: 1px solid #111; }
.sheet-heading { display: grid; grid-template-columns: 18% 82%; min-height: 70px; }
.sheet-logo { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 8px; border-right: 1px solid #111; color: #1c5277; text-align: center; }
.sheet-logo strong { font-size: 1.6rem; line-height: 1; letter-spacing: .02em; }
.sheet-logo small { margin-top: 5px; color: #333; font-size: .58rem; font-weight: 700; }
.sheet-title { display: flex; flex-direction: column; justify-content: space-evenly; align-items: center; gap: 4px; padding: 8px 12px; background: #20577d; color: #fff; text-align: center; font-size: 1.02rem; line-height: 1.18; }
.sheet-event-line { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; padding: 4px 8px; background: #f7f7f7; font-size: .78rem; }
.sheet-application-line { padding: 4px 8px; background: #eef5f1; color: #23473f; text-align: center; font-size: .7rem; font-weight: 700; }
.sheet-declaration { margin: 0; padding: 7px 9px; min-height: 70px; text-align: justify; font-size: .62rem; font-weight: 400; line-height: 1.2; }
.sheet-columns th { padding: 4px 6px; background: #20577d; color: #fff; font-size: .72rem; text-align: left; }
.sheet-person-row { height: 28px; }
.sheet-person-row td { padding: 3px 6px; font-size: .76rem; }
.sheet-person-row td:first-child { text-transform: uppercase; }
.sheet-person-row td:nth-child(3) { display: flex; gap: 13px; justify-content: flex-start; align-items: center; }
.sheet-person-row td:nth-child(4) { min-height: 28px; }
.sheet-total-label { padding: 5px 6px; text-align: right; font-weight: 800; font-size: .75rem; }
.sheet-total { padding: 5px 6px; font-weight: 800; font-size: .75rem; }
.payment-report .sheet-columns th { padding: 6px 8px; font-size: .84rem; }
.payment-report .sheet-person-row { height: 33px; }
.payment-report .sheet-person-row td { padding: 5px 8px; font-size: .86rem; }
.payment-report .sheet-person-row td:nth-child(4) { min-height: 33px; }
.payment-report .sheet-total-label, .payment-report .sheet-total { padding: 6px 8px; font-size: .84rem; }
.sheet-break { break-before: page; page-break-before: always; }
@media print {
    @page { size: A4 landscape; margin: 8mm; }
    body { background: #fff; color: #111; }
    .no-print, .topbar, .footer { display: none !important; }
    .page-content { padding: 0; }
    .container { width: 100%; max-width: none; margin: 0; padding: 0; }
    .payment-sheet { margin: 0; page-break-inside: auto; }
    .payment-report .sheet-heading { min-height: 78px; }
    .payment-report .sheet-title { padding: 10px 14px; font-size: 1.12rem; line-height: 1.22; }
    .payment-report .sheet-event-line { padding: 6px 9px; font-size: .88rem; }
    .payment-report .sheet-application-line { padding: 6px 9px; font-size: .8rem; }
    .payment-report .sheet-declaration { min-height: 86px; padding: 9px 11px; font-size: .76rem; line-height: 1.3; }
    .payment-report .sheet-columns th { padding: 7px 8px; font-size: .86rem; }
    .payment-report .sheet-person-row { height: 34px; }
    .payment-report .sheet-person-row td { padding: 5px 8px; font-size: .88rem; }
    .payment-report .sheet-person-row td:nth-child(4) { min-height: 34px; }
    .payment-report .sheet-total-label, .payment-report .sheet-total { padding: 7px 8px; font-size: .86rem; }
    .payment-sheet thead { display: table-header-group; }
    .payment-sheet tfoot { display: table-footer-group; }
    .payment-sheet tr { page-break-inside: avoid; break-inside: avoid; }
    .sheet-break { break-before: page; page-break-before: always; }
}

.sigilo-sheet .sheet-declaration { min-height: 0; padding: 6px 8px; font-size: .61rem; line-height: 1.15; }
.sigilo-sheet .sheet-declaration p { margin: 0 0 3px; }
.sigilo-sheet .sheet-declaration ol { margin: 0 0 3px; padding-left: 18px; }
.sigilo-sheet .sheet-declaration li { margin: 0; padding-left: 2px; }
.sigilo-sheet .sheet-person-row { height: 27px; }
.sigilo-sheet .sheet-person-row td { font-size: .7rem; }
@media print { .sigilo-sheet .sheet-declaration { font-size: .59rem; } .sigilo-sheet .sheet-person-row { height: 25px; } }

.sheet-logo img { display: block; max-width: 135px; max-height: 58px; width: auto; height: auto; object-fit: contain; }
.nav-group { position: relative; }
.nav-toggle { display: inline-flex; align-items: center; gap: 6px; border: 0; color: rgba(255,255,255,.78); background: transparent; font: inherit; font-size: .9rem; cursor: pointer; padding: 8px 10px; border-radius: 8px; transition: background .2s, color .2s; }
.nav-toggle-arrow { display: inline-block; font-size: .72em; line-height: 1; transition: transform .2s ease; }
.nav-group.is-open .nav-toggle-arrow { transform: rotate(180deg); }
.nav-toggle:hover, .nav-group.is-active .nav-toggle { color: #fff; background: rgba(255,255,255,.1); }
.nav-submenu[hidden] { display: none; }
.nav-submenu { position: absolute; z-index: 20; top: calc(100% + 12px); left: -12px; min-width: 210px; padding: 8px; background: #12322e; border: 1px solid rgba(255,255,255,.18); border-radius: 10px; box-shadow: 0 12px 30px rgba(0,0,0,.2); }
.nav-submenu a { display: block; padding: 9px 10px; border-radius: 7px; white-space: nowrap; }
.nav-submenu a:hover, .nav-submenu a.is-current { background: rgba(255,255,255,.14); color: #fff; text-decoration: none; }
.nav-submenu a.is-current { font-weight: 800; box-shadow: inset 3px 0 0 var(--accent); }

/* Tipografia padronizada dos relatórios */
.payment-sheet,
.payment-sheet th,
.payment-sheet td,
.report-table,
.report-table th,
.report-table td,
.room-plan-table,
.room-plan-table th,
.room-plan-table td {
    font-family: Arial, "Helvetica Neue", sans-serif;
}

.report-table,
.report-table th,
.report-table td,
.room-plan-table,
.room-plan-table th,
.room-plan-table td,
.payment-sheet .sheet-event-line,
.payment-sheet .sheet-application-line,
.payment-sheet .sheet-declaration,
.payment-sheet .sheet-columns th,
.payment-sheet .sheet-person-row td,
.payment-sheet .sheet-total-label,
.payment-sheet .sheet-total {
    font-size: 11pt;
}

.report-table th { padding: 10px 9px; }
.report-table td { padding: 11px 9px; }
.report-document { overflow: hidden; }
.report-event-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin: -2px -2px 18px; padding: 13px 15px; border-left: 5px solid #20577d; border-bottom: 1px solid #dfe7e3; background: #f6f9f7; }
.report-event-heading h2 { margin: 0 0 4px; color: #20577d; font-size: 1.16rem; letter-spacing: -.02em; }
.report-event-heading p { margin: 0; color: #64716e; font-size: .88rem; }
.report-event-heading .eyebrow { margin-bottom: 5px; font-size: .66rem; }
.report-event-total { flex: 0 0 auto; min-width: 92px; padding-left: 16px; border-left: 1px solid #cdd9d4; text-align: center; }
.report-event-total span { display: block; color: #64716e; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
.report-event-total strong { display: block; color: #20577d; font-size: 1.55rem; line-height: 1.1; }
.report-document .section-heading { padding-bottom: 12px; border-bottom: 2px solid #20577d; }
.report-document .section-heading h2 { color: #20577d; }
.report-document .report-table tbody tr:nth-child(even) { background: #f6f9f7; }
.report-document .report-table tbody tr:hover { background: #edf5f1; }
.report-metrics { margin-bottom: 20px; }
.report-metrics .stat-card { min-height: 112px; border-top: 4px solid #20577d; border-radius: 10px; padding: 16px 18px; }
.report-metrics .stat-card:nth-child(2) { border-top-color: #0f766e; }
.report-metrics .stat-card:nth-child(3) { border-top-color: #f59e0b; }
.report-metrics .stat-card:nth-child(4) { border-top-color: #64716e; }
.report-metrics .stat-card strong { font-size: 1.7rem; }
.report-detail-heading { margin-top: 22px; }
.report-document + .report-document { margin-top: 24px; }

.application-sheet { width: 100%; table-layout: fixed; }
.application-sheet .sheet-person-row td { overflow-wrap: anywhere; vertical-align: top; }
.application-sheet .sheet-person-row td:nth-child(3) { display: table-cell; gap: 0; align-items: initial; }
.application-sheet .sheet-person-row td small { display: block; font-size: .62rem; }
.distribution-sheet .sheet-person-row td { padding-top: 6px; padding-bottom: 6px; }
.room-plan-table th,

.room-plan-table td { padding: 7px 8px; }
.payment-sheet .sheet-title { font-family: Arial, "Helvetica Neue", sans-serif; font-size: 12pt; }
.payment-sheet .sheet-declaration { line-height: 1.3; }
.payment-sheet .sheet-columns th { padding: 7px 8px; }
.payment-sheet .sheet-person-row td { padding: 6px 8px; }
.payment-sheet .sheet-total-label,
.payment-sheet .sheet-total { padding: 7px 8px; }
.payment-report .sheet-columns th,
.payment-report .sheet-person-row td,
.payment-report .sheet-total-label,
.payment-report .sheet-total { font-size: 12pt; }
.payment-report .sheet-person-row { height: 36px; }
.payment-report .sheet-person-row td:nth-child(4) { min-height: 36px; }

@media print {
    .payment-sheet,
    .payment-sheet th,
    .payment-sheet td,
    .report-table,
    .report-table th,
    .report-table td,
    .room-plan-table,
    .room-plan-table th,
    .room-plan-table td {
        font-family: Arial, "Helvetica Neue", sans-serif;
    }
    .payment-sheet .sheet-event-line,
    .payment-sheet .sheet-application-line,
    .payment-sheet .sheet-declaration,
    .payment-sheet .sheet-columns th,
    .payment-sheet .sheet-person-row td,
    .payment-sheet .sheet-total-label,
    .payment-sheet .sheet-total,
    .report-table,
    .report-table th,
    .report-table td,
    .room-plan-table,
    .room-plan-table th,
    .room-plan-table td { font-size: 11pt; }
    .payment-report .sheet-columns th,
    .payment-report .sheet-person-row td,
    .payment-report .sheet-total-label,
    .payment-report .sheet-total { font-size: 12pt; }
}

/* Cabeçalho institucional dos relatórios: azul somente na primeira linha */
.report-thead .sheet-head-cell,
.report-thead .sheet-heading,
.report-thead .sheet-logo,
.report-thead .sheet-title {
    background: #20577d;
    color: #fff;
}

.report-thead .sheet-logo {
    border-right-color: rgba(255, 255, 255, .55);
}

.report-thead .sheet-logo small {
    color: rgba(255, 255, 255, .92);
}

.report-thead .sheet-event-line,
.report-thead .sheet-application-line,
.report-thead .sheet-declaration {
    background: #fff;
    color: #111;
}

.report-thead .sheet-event-line {
    border-top: 1px solid #111;
    border-bottom: 1px solid #111;
}

.report-thead .sheet-declaration {
    border-top: 1px solid #111;
}

/* Ajuste final: somente a primeira linha do cabeçalho recebe cor */
.report-thead .sheet-head-cell,
.report-thead .sheet-heading,
.report-thead .sheet-logo,
.report-thead .sheet-title {
    background: #20577d;
    color: #fff;
}

.report-thead .sheet-event-line,
.report-thead .sheet-application-line,
.report-thead .sheet-declaration {
    background: #fff;
    color: #111;
}

.report-thead .sheet-logo {
    border-right-color: rgba(255, 255, 255, .55);
}

.report-thead .sheet-logo small {
    color: rgba(255, 255, 255, .92);
}

.report-thead .sheet-event-line {
    border-top: 1px solid #111;
    border-bottom: 1px solid #111;
}

.report-thead .sheet-declaration {
    border-top: 1px solid #111;
}

@media print {
    .report-event-heading { break-inside: avoid; }
    .report-document { border: 0; border-radius: 0; box-shadow: none; padding: 0; }
    .report-document + .report-document { break-before: page; page-break-before: always; margin-top: 0; }
    @page report-portrait { size: A4 portrait; margin: 8mm; }
    @page report-landscape { size: A4 landscape; margin: 8mm; }
    .payment-sheet.report-portrait,
    .report-document.report-portrait { page: report-portrait; }
    .payment-sheet.report-landscape,
    .report-document.report-landscape { page: report-landscape; }
}

/* Organização do formulário de eventos */
.event-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.event-form-section { grid-column: 1 / -1; margin: 0; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: #fbfdfc; }
.event-form-section h3 { margin-bottom: 14px; color: var(--primary-dark); }
.event-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.event-fields-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.event-fields-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.distribution-summary { margin-bottom: 18px; }
.distribution-summary th:last-child,
.distribution-summary td:last-child,
.operational-summary th:last-child,
.operational-summary td:last-child { width: 25%; text-align: center; }

@media (max-width: 650px) {
    .event-form-grid { grid-template-columns: 1fr; }
    .event-form-section { grid-column: auto; }
    .event-fields,
    .event-fields-3,
    .event-fields-4 { grid-template-columns: 1fr; }
}

@media print {
    .room-plan-table.report-portrait { page: report-portrait; }
    .room-plan-table.report-landscape { page: report-landscape; }
}

/* As larguras das tabelas são definidas pelo colgroup configurado por relatório */
.payment-report .sheet-person-row { height: 42px; }
.payment-report .sheet-person-row td:nth-child(4) { min-height: 42px; }
.payment-report .sheet-person-row td:nth-child(3) { justify-content: flex-end; gap: 4px; }

.sigilo-sheet .sheet-person-row { height: 40px; }
.sigilo-sheet .sheet-person-row td:last-child { min-height: 40px; }

@media print {
    .payment-report .sheet-person-row { height: 42px; }
    .payment-report .sheet-person-row td:nth-child(4) { min-height: 42px; }
    .sigilo-sheet .sheet-person-row { height: 40px; }
    .sigilo-sheet .sheet-person-row td:last-child { min-height: 40px; }
}

/* Impressão por página dos relatórios de pagamento e sigilo */
.payment-report,
.sigilo-sheet,
.distribution-sheet,
.application-sheet,
.report-table {
    table-layout: fixed;
    page-break-inside: auto;
    break-inside: auto;
}
/* As larguras em tela e impressão vêm exclusivamente dos colgroups gerados pelo relatório */

/* O Sigilo herda a mesma fonte global da Lista de Pagamento na tela */
.sigilo-sheet,
.sigilo-sheet th,
.sigilo-sheet td,
.sigilo-sheet .sheet-columns th,
.sigilo-sheet .sheet-person-row td,
.sigilo-sheet .sheet-total-label,
.sigilo-sheet .sheet-total {
    font-family: inherit;
}
.sigilo-sheet .sheet-columns th { font-size: .84rem; }
.sigilo-sheet .sheet-person-row td { font-size: .86rem; }
.sigilo-sheet .sheet-total-label,
.sigilo-sheet .sheet-total { font-size: .84rem; }
.payment-report .sheet-person-row td:nth-child(3) {
    display: table-cell;
    min-height: 0;
    text-align: right;
    vertical-align: top;
    justify-content: initial;
    gap: 0;
}
.payment-report .sheet-person-row td:nth-child(3) span,
.payment-report .sheet-person-row td:nth-child(3) strong { display: inline; }
.sigilo-sheet .sheet-person-row td:nth-child(3) {
    display: table-cell;
    min-height: 0;
    text-align: left;
    vertical-align: top;
    justify-content: initial;
    gap: 0;
}
.sigilo-sheet .sheet-columns th { font-size: .84rem; }
.sigilo-sheet .sheet-person-row td { font-size: .86rem; }
.sigilo-sheet .sheet-total-label,
.sigilo-sheet .sheet-total { font-size: .84rem; }

/* Cabeçalho e declaração do Sigilo também herdam a fonte da Lista */
.sigilo-sheet .sheet-declaration,
.sigilo-sheet .sheet-event-line {
    font-family: inherit;
    font-size: .62rem;
    line-height: 1.2;
}

/* Fonte da tabela do Sigilo igual à fonte efetiva da Lista de Pagamento */
.sigilo-sheet .sheet-columns th,
.sigilo-sheet .sheet-person-row td,
.sigilo-sheet .sheet-total-label,
.sigilo-sheet .sheet-total {
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

@media print {
    .payment-report .sheet-columns th,
    .sigilo-sheet .sheet-columns th,
    .payment-report .sheet-person-row td,
    .sigilo-sheet .sheet-person-row td,
    .payment-report .sheet-total-label,
    .sigilo-sheet .sheet-total-label,
    .payment-report .sheet-total,
    .sigilo-sheet .sheet-total {
        font-family: Arial, "Helvetica Neue", sans-serif !important;
        font-size: 12pt !important;
    }
    .payment-report thead,
    .sigilo-sheet thead { display: table-header-group; }
    .payment-report tbody,
    .sigilo-sheet tbody { display: table-row-group; }
    .payment-report tfoot { display: table-footer-group; }
    .payment-report .sheet-columns th,
    .sigilo-sheet .sheet-columns th { white-space: normal; word-break: normal; }
    .payment-report .sheet-columns th,
    .sigilo-sheet .sheet-columns th { font-weight: 800; }
    .payment-report .sheet-person-row td,
    .sigilo-sheet .sheet-person-row td { padding: 5px 8px; }
    .sigilo-sheet .sheet-heading { min-height: 78px; }
    .sigilo-sheet .sheet-title { padding: 10px 14px; font-size: 1.12rem; line-height: 1.22; }
    .sigilo-sheet .sheet-event-line { padding: 6px 9px; font-size: .88rem; }
    .sigilo-sheet .sheet-application-line { padding: 6px 9px; font-size: .8rem; }
    .sigilo-sheet .sheet-declaration { min-height: 86px; padding: 9px 11px; font-size: .76rem; line-height: 1.3; }
    .sigilo-sheet .sheet-columns th { padding: 7px 8px; font-size: 12pt; }
    .sigilo-sheet .sheet-person-row { height: 42px; }
    .sigilo-sheet .sheet-person-row td { padding: 5px 8px; font-size: 12pt; }
    .sigilo-sheet .sheet-total-label,
    .sigilo-sheet .sheet-total { padding: 7px 8px; font-size: 12pt; }
}

/* O Sigilo mantém na impressão os mesmos valores visuais usados na tela */
@media print {
    .sigilo-sheet,
    .sigilo-sheet th,
    .sigilo-sheet td {
        font-family: Arial, "Helvetica Neue", sans-serif;
    }
    .sigilo-sheet .sheet-declaration {
        min-height: 0 !important;
        padding: 6px 8px !important;
        font-size: .61rem !important;
        line-height: 1.15 !important;
    }
    .sigilo-sheet .sheet-columns th,
    .sigilo-sheet .sheet-person-row td,
    .sigilo-sheet .sheet-total-label,
    .sigilo-sheet .sheet-total {
        font-size: 12pt !important;
    }
    .sigilo-sheet .sheet-person-row {
        height: 36px !important;
    }
}

/* Igualdade tipográfica final entre Sigilo e Lista de Pagamento na impressão */
@media print {
    .sigilo-sheet .sheet-columns th,
    .sigilo-sheet .sheet-person-row td,
    .sigilo-sheet .sheet-total-label,
    .sigilo-sheet .sheet-total {
        font: normal 12pt Arial, "Helvetica Neue", sans-serif !important;
        font-weight: 400 !important;
        line-height: normal !important;
    }
    .sigilo-sheet .sheet-columns th {
        font-weight: 700 !important;
    }
}

/* Pré-visualização de impressão do relatório de Sigilo */
body.print-preview-active { background: #dfe5e2; }
body.print-preview-active .page-content { max-width: 297mm; margin: 20px auto; padding: 0; }
body.print-preview-active .payment-sheet.sigilo-sheet {
    width: 100%;
    margin: 0 auto 18px;
    background: #fff;
    box-shadow: 0 2px 14px rgba(0, 0, 0, .14);
    font-family: Arial, "Helvetica Neue", sans-serif;
}
body.print-preview-active .sigilo-sheet .sheet-columns th,
body.print-preview-active .sigilo-sheet .sheet-person-row td,
body.print-preview-active .sigilo-sheet .sheet-total-label,
body.print-preview-active .sigilo-sheet .sheet-total {
    font-family: Arial, "Helvetica Neue", sans-serif !important;
    font-size: 12pt !important;
    line-height: normal !important;
}
body.print-preview-active .sigilo-sheet .sheet-columns th { font-weight: 700 !important; }
body.print-preview-active .sigilo-sheet .sheet-person-row td { font-weight: 400 !important; }
body.print-preview-active .sigilo-sheet .sheet-declaration {
    min-height: 0 !important;
    padding: 6px 8px !important;
    font-family: Arial, "Helvetica Neue", sans-serif !important;
    font-size: .61rem !important;
    line-height: 1.15 !important;
}
body.print-preview-active .sigilo-sheet .sheet-person-row { height: 36px !important; }
body.print-preview-active .sigilo-sheet .sheet-head-cell,
body.print-preview-active .sigilo-sheet .sheet-title,
body.print-preview-active .sigilo-sheet .sheet-event-line,
body.print-preview-active .sigilo-sheet .sheet-application-line,
body.print-preview-active .sigilo-sheet .sheet-declaration,
body.print-preview-active .sigilo-sheet .sheet-columns,
body.print-preview-active .sigilo-sheet .sheet-person-row,
body.print-preview-active .sigilo-sheet .sheet-total-label,
body.print-preview-active .sigilo-sheet .sheet-total { break-inside: avoid; }

/* O Sigilo usa exatamente a mesma escala de fonte na tela, prévia e impressão */
.sigilo-sheet .sheet-columns th { font-size: .84rem !important; }
.sigilo-sheet .sheet-person-row td { font-size: .70rem !important; }
.sigilo-sheet .sheet-total-label,
.sigilo-sheet .sheet-total { font-size: .84rem !important; }
@media print {
    .sigilo-sheet .sheet-columns th { font-size: .84rem !important; }
    .sigilo-sheet .sheet-person-row td { font-size: .70rem !important; }
    .sigilo-sheet .sheet-total-label,
    .sigilo-sheet .sheet-total { font-size: .84rem !important; }
}
body.print-preview-active .sigilo-sheet .sheet-columns th { font-size: .84rem !important; }
body.print-preview-active .sigilo-sheet .sheet-person-row td { font-size: .70rem !important; }
body.print-preview-active .sigilo-sheet .sheet-total-label,
body.print-preview-active .sigilo-sheet .sheet-total { font-size: .84rem !important; }

/* Espaçamento compacto aprovado para o Sigilo */
.sigilo-sheet .sheet-columns th {
    padding: 4px 6px !important;
}
.sigilo-sheet .sheet-person-row {
    height: 36px !important;
}
.sigilo-sheet .sheet-person-row td {
    padding: 2px 6px !important;
    line-height: 1.05 !important;
}
.sigilo-sheet .sheet-total-label,
.sigilo-sheet .sheet-total {
    padding: 4px 6px !important;
}
@media print {
    .sigilo-sheet .sheet-columns th {
        padding: 4px 6px !important;
    }
    .sigilo-sheet .sheet-person-row {
        height: 36px !important;
    }
    .sigilo-sheet .sheet-person-row td {
        padding: 2px 6px !important;
        line-height: 1.05 !important;
    }
    .sigilo-sheet .sheet-total-label,
    .sigilo-sheet .sheet-total {
        padding: 4px 6px !important;
    }
}
body.print-preview-active .sigilo-sheet .sheet-columns th {
    padding: 4px 6px !important;
}
body.print-preview-active .sigilo-sheet .sheet-person-row td {
    padding: 2px 6px !important;
    line-height: 1.05 !important;
}
body.print-preview-active .sigilo-sheet .sheet-total-label,
body.print-preview-active .sigilo-sheet .sheet-total {
    padding: 4px 6px !important;
}

/* Guias da configuração dos relatórios */
.report-tabs { display: flex; gap: 8px; overflow-x: auto; margin: 0 0 24px; padding: 4px; border-bottom: 1px solid var(--line); scrollbar-width: thin; }
.report-tab { flex: 0 0 auto; border: 1px solid transparent; border-radius: 9px 9px 0 0; padding: 11px 15px; background: transparent; color: var(--muted); font: inherit; font-size: .86rem; font-weight: 750; cursor: pointer; white-space: nowrap; }
.report-tab:hover { color: var(--primary-dark); background: #f1f7f4; }
.report-tab.is-active { color: var(--primary-dark); background: #e7f1ed; border-color: var(--line); border-bottom-color: #e7f1ed; }
.report-tab:focus-visible { outline: 3px solid rgba(15,118,110,.22); outline-offset: 2px; }
.report-tab-panel[hidden] { display: none; }
.report-tab-panel { animation: report-panel-in .16s ease-out; }
@keyframes report-panel-in { from { opacity: .35; transform: translateY(3px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 650px) {
    .report-tabs { display: grid; grid-template-columns: 1fr; gap: 6px; border-bottom: 0; padding: 0; }
    .report-tab { border: 1px solid var(--line); border-radius: 9px; text-align: left; }
    .report-tab.is-active { border-color: var(--primary); }
}

/* Tipografia configurável por relatório. Estas regras finais prevalecem sobre os ajustes legados. */
.payment-sheet,
.report-table { font-family: var(--report-body-font, Arial), sans-serif !important; font-size: var(--report-body-size, 11pt) !important; line-height: var(--report-line-height, 1.15) !important; }
.payment-sheet .sheet-title { font-family: var(--report-header-font, Arial), sans-serif !important; font-size: var(--report-header-size, 12pt) !important; font-weight: var(--report-header-weight, 700) !important; }
.payment-sheet .sheet-event-line,
.payment-sheet .sheet-application-line,
.payment-sheet .sheet-declaration { font-family: var(--report-body-font, Arial), sans-serif !important; font-size: var(--report-body-size, 11pt) !important; line-height: var(--report-line-height, 1.15) !important; }
.payment-sheet .sheet-columns th,
.report-table th { font-family: var(--report-table-header-font, Arial), sans-serif !important; font-size: var(--report-table-header-size, 11pt) !important; font-weight: var(--report-table-header-weight, 700) !important; line-height: var(--report-line-height, 1.15) !important; padding-top: var(--report-row-padding, 3px) !important; padding-bottom: var(--report-row-padding, 3px) !important; }
.payment-sheet .sheet-person-row td,
.payment-sheet .sheet-total-label,
.payment-sheet .sheet-total,
.report-table td { font-family: var(--report-table-row-font, Arial), sans-serif !important; font-size: var(--report-table-row-size, 11pt) !important; font-weight: var(--report-table-row-weight, 400) !important; line-height: var(--report-line-height, 1.15) !important; padding-top: var(--report-row-padding, 3px) !important; padding-bottom: var(--report-row-padding, 3px) !important; }
.report-document .report-event-heading h2 { font-family: var(--report-header-font, Arial), sans-serif !important; font-size: var(--report-header-size, 12pt) !important; font-weight: var(--report-header-weight, 700) !important; }
.report-document .report-event-heading p,
.report-document .report-event-total span,
.report-document .report-event-total strong { font-family: var(--report-body-font, Arial), sans-serif !important; font-size: var(--report-body-size, 11pt) !important; line-height: var(--report-line-height, 1.15) !important; }
.payment-sheet .sheet-person-row { height: var(--report-row-height, 36px) !important; }
.payment-sheet .sheet-person-row td { min-height: var(--report-row-height, 36px) !important; }
.report-table tbody tr { min-height: var(--report-row-height, 36px) !important; height: var(--report-row-height, 36px); }

/* Impressão: preservar as cores de fundo do cabeçalho e dos títulos das tabelas. */
@media print {
    .report-thead,
    .report-thead .sheet-head-cell,
    .report-thead .sheet-heading,
    .report-thead .sheet-logo,
    .report-thead .sheet-title,
    .report-thead .sheet-columns,
    .report-thead .sheet-columns th,
    .report-table thead,
    .report-table thead th {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
    .report-thead .sheet-heading,
    .report-thead .sheet-logo,
    .report-thead .sheet-title,
    .report-thead .sheet-columns th,
    .report-table thead th {
        background-color: #20577d !important;
    }
}

/* Lista de Pagamento: declaração sem espaço vertical excedente ao final. */
.payment-report .sheet-declaration { min-height: 0 !important; }
.payment-report .sheet-declaration p { margin-top: 0; margin-bottom: 3px; }
.payment-report .sheet-declaration p:last-child { margin-bottom: 0; }

/* Lista de Pagamento: valor à esquerda e moeda na mesma linha. */
.payment-report .payment-value-cell { text-align: left !important; }
.payment-report .payment-value { display: inline !important; font-weight: 400 !important; white-space: nowrap; }

/* Declarações de Pagamento e Sigilo: alinhamento justificado na tela, prévia e impressão. */
.payment-sheet .sheet-declaration,
.sigilo-sheet .sheet-declaration {
    text-align: var(--report-declaration-align, justify) !important;
    white-space: normal !important;
    text-transform: none !important;
    overflow-wrap: break-word;
    word-break: normal;
}
.payment-sheet .sheet-declaration p,
.payment-sheet .sheet-declaration li,
.sigilo-sheet .sheet-declaration p,
.sigilo-sheet .sheet-declaration li { text-align: inherit; }

/* Lista de colaboradores: código e nome na mesma linha, com peso e tamanho iguais. */
.collaborators-table { min-width: 1120px; table-layout: auto; }
.collaborators-table th:nth-child(1), .collaborators-table td:nth-child(1) { min-width: 350px; }
.collaborators-table th:nth-child(2), .collaborators-table td:nth-child(2) { min-width: 125px; }
.collaborators-table th:nth-child(3), .collaborators-table td:nth-child(3) { min-width: 125px; }
.collaborators-table th:nth-child(4), .collaborators-table td:nth-child(4) { min-width: 310px; }
.collaborators-table th:nth-child(5), .collaborators-table td:nth-child(5) { min-width: 90px; }
.collaborators-table td:nth-child(n+2) { white-space: nowrap; }
.collaborators-table td:first-child { white-space: nowrap; }
.collaborators-table .collaborator-code,
.collaborators-table .collaborator-name { display: inline; font-size: inherit; font-weight: 400; }
.collaborators-table .collaborator-code::after { content: ' — '; }
.collaborators-table .collaborator-phone { margin-right: .28rem; }
.whatsapp-collaborator-button { display: inline-flex; align-items: center; justify-content: center; width: 1.35rem; height: 1.35rem; padding: .18rem; border-radius: 50%; background: #25d366; color: #fff; vertical-align: middle; line-height: 1; }
.whatsapp-collaborator-button:hover, .whatsapp-collaborator-button:focus-visible { background: #1ebe5d; color: #fff; }
.whatsapp-collaborator-button svg { width: .92rem; height: .92rem; fill: currentColor; }
@media (max-width: 700px) { .whatsapp-collaborator-button { width: 1.25rem; height: 1.25rem; padding: .15rem; } .whatsapp-collaborator-button svg { width: .84rem; height: .84rem; } }

/* Associação compacta de colaboradores */
.compact-association-card { padding: 1rem; }
.compact-association-card > h2 { margin-bottom: .25rem; }
.compact-association-card > p { margin-bottom: .75rem; font-size: .9rem; }
.compact-association-card .form-grid { gap: .65rem; }
.compact-association-card .field { gap: .25rem; }
.compact-association-card .field label { font-size: .85rem; }
.inline-search { display: flex; align-items: stretch; gap: .4rem; }
.inline-search input { min-width: 0; flex: 1 1 auto; }
.inline-search .button { white-space: nowrap; }
.search-result { display: block; margin-top: .3rem; font-size: .8rem; }
.search-result-success { color: #166534; }
.search-result-warning { color: #92400e; }
.search-result-warning a { font-weight: 700; }
@media (max-width: 640px) {
    .compact-association-card { padding: .75rem; }
    .inline-search { flex-direction: column; }
    .inline-search .button { width: 100%; }
}
@media print { .compact-association-card { padding: 0; } }

/* Relatório do Evento: impressão compacta em uma página. */
.event-report-one-page { box-sizing: border-box; }
.event-report-one-page .sheet-person-row td { padding-top: 4px; padding-bottom: 4px; }
.event-report-one-page .report-detail-heading { margin-top: 8px; margin-bottom: 6px; }
.event-report-one-page .report-detail-heading h3 { margin-bottom: 2px; }
.event-report-one-page .report-detail-heading p { margin: 0; }
@media print {
    @page { size: A4 portrait; margin: 8mm; }
    .event-report-one-page { page-break-inside: avoid; break-inside: avoid; }
    .event-summary-report { margin-bottom: 6px; }
    .event-summary-report .sheet-head-cell { padding: 4px 6px; }
    .event-summary-report .sheet-declaration { min-height: 0; padding: 3px 6px; font-size: 8.5pt; line-height: 1.08; }
    .event-summary-report .sheet-declaration p { margin: 0; }
    .event-summary-report .sheet-event-line { padding: 2px 6px; }
    .event-summary-report .sheet-columns th { padding: 4px 6px; }
    .event-report-one-page .event-functions-report { margin-top: 6px; padding: 0; }
    .event-report-one-page .event-functions-report .section-heading { padding: 3px 6px; margin-bottom: 0; }
    .event-report-one-page .event-functions-report .report-table th,
    .event-report-one-page .event-functions-report .report-table td { padding: 4px 6px; font-size: 9pt; line-height: 1.05; }
    .event-report-one-page .event-summary-report .sheet-columns th,
    .event-report-one-page .event-functions-report .report-table thead th {
        background-color: #ffffff !important;
        color: #000000 !important;
        font-weight: 700 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
}

/* Dashboard: capacidade agrupada por evento. */
.dashboard-capacity-table .dashboard-event-row td { padding: 9px 12px 7px; background: #eef5f1; border-top: 2px solid #20577d; color: #20577d; }
.dashboard-capacity-table .dashboard-event-row td strong { display: block; font-size: .92rem; }
.dashboard-registration-link { display: block; margin-top: 3px; color: var(--muted); font-size: .78rem; font-weight: 400; white-space: nowrap; }
.dashboard-registration-link a { color: var(--primary-dark); font-weight: 700; }
.dashboard-capacity-table > thead > tr > th { white-space: nowrap; }

/* Dashboard: blocos independentes de capacidade por evento. */
.dashboard-event-block { margin-top: 18px; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.dashboard-event-block:first-of-type { margin-top: 0; }
.dashboard-event-heading { padding: 10px 12px 8px; background: #eef5f1; border-bottom: 1px solid var(--line); color: #20577d; }
.dashboard-event-heading > strong { display: block; font-size: .95rem; }
.dashboard-event-heading .dashboard-registration-link { margin-top: 4px; }
.dashboard-event-block .table-wrap { overflow-x: auto; }
.dashboard-event-block .dashboard-capacity-table { margin: 0; }
.dashboard-event-block .dashboard-capacity-table th,
.dashboard-event-block .dashboard-capacity-table td { white-space: nowrap; }

/* Botão lateral do WhatsApp na alocação pública. */
.whatsapp-event-button {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    flex: 0 0 auto;
    background: #25d366;
    border-color: #25d366;
    color: #ffffff;
    font-weight: 700;
    white-space: nowrap;
}
.whatsapp-event-button:hover,
.whatsapp-event-button:focus-visible {
    background: #1ebe5d;
    border-color: #1ebe5d;
    color: #ffffff;
}
.whatsapp-event-icon {
    width: 1.2rem;
    height: 1.2rem;
    fill: currentColor;
}
@media (max-width: 700px) {
    .page-heading:has(.whatsapp-event-button) { align-items: flex-start; }
    .whatsapp-event-button span { display: none; }
    .whatsapp-event-button { padding: .55rem .7rem; }
}

/* Relatório de alocações: cabeçalhos impressos sem fundo azul. */
@media print {
    .report-document .report-table thead,
    .report-document .report-table thead tr,
    .report-document .report-table thead th {
        background: #ffffff !important;
        background-color: #ffffff !important;
        color: #000000 !important;
        font-weight: 700 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
}
