* { box-sizing: border-box; }
body { margin: 0; color: #171736; background: #f5f5fb; font: 1rem/1.6 system-ui, sans-serif; }
main { width: min(28rem, calc(100% - 2rem)); margin: 3rem auto; padding: 1.5rem; background: white; border-radius: 1rem; }
a { color: #3730a3; }
h1 { font-size: 1.5rem; }
label { display: grid; gap: .25rem; margin-bottom: 1rem; }
input, button { min-height: 2.75rem; padding: .5rem .75rem; border-radius: .4rem; font: inherit; }
input { width: 100%; border: 1px solid #6b6b84; }
button { border: 0; background: #3730a3; color: #fff; cursor: pointer; }
[role="alert"] { color: #9a2525; }

nav { display: flex; flex-wrap: wrap; gap: .75rem; margin-bottom: 1rem; }
form { margin-block: 1rem; }
select { min-height: 2.75rem; padding: .5rem .75rem; font: inherit; }
input[type="checkbox"] { width: auto; min-height: auto; }
dd { margin: 0 0 .5rem; overflow-wrap: anywhere; }

main:has(.report-list) { width: min(82rem, calc(100% - 2rem)); }
.report-list { overflow-x: auto; }
.report-list .report-table { min-width: 70rem; }
.report-table { border-collapse: collapse; width: 100%; text-align: left; }
.report-table th, .report-table td { padding: .65rem .75rem; border: 1px solid #d8d8e8; vertical-align: top; }
.report-table thead th { background: #eeedfb; }
.report-table tbody tr:nth-child(even) { background: #f7f7fc; }
.report-table td { overflow-wrap: anywhere; }
.report-table tbody th { width: 40%; }
.report-list a { white-space: nowrap; }
.report-list thead th { white-space: nowrap; }
.report-list tbody td:nth-child(-n+3) { white-space: nowrap; }

.export-actions, .print-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
@page { size: A4 landscape; margin: 9mm; }
@media print {
  body { background: #fff; }
  .print-actions { display: none; }
  main:has(.monthly-print) { margin: 0; padding: 0; width: 100%; }
  .monthly-print h1 { font-size: 14pt; margin: 0 0 3mm; }
  .monthly-print .report-list { overflow: visible; }
  .monthly-print .report-table { min-width: 0; font-size: 7.5pt; }
  .monthly-print .report-table th, .monthly-print .report-table td { padding: 1.25mm; }
  .monthly-print .report-table tr { break-inside: avoid; }
}

@media print {
  .annual-print-month + .annual-print-month { break-before: page; }
}

.report-list .report-table { min-width: 90rem; }
@media print { .monthly-print .report-table { min-width: 0; font-size: 6.5pt; } }
