.ir-report-center > .ir-page-heading { margin-bottom: 16px; }
.ir-report-controls { margin-bottom: 14px; padding: 13px 16px; }

.ir-report-selectors, .ir-report-control, .ir-report-context {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 13px;
}

.ir-report-selectors { gap: 9px 20px; }
.ir-report-control { gap: 7px; }
.ir-report-caption { font-size: 12px; font-weight: 660; color: var(--muted); }
.ir-report-selectors .ir-segmented { flex-wrap: wrap; }
.ir-report-refresh { margin-inline-start: auto; }
.ir-report-context { justify-content: space-between; margin-top: 10px; }
.ir-report-context .meta-row { align-items: center; }

.ir-report-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(230px, 282px);
  align-items: start;
  gap: 14px;
}

.ir-report-pane, .ir-report-archive { min-width: 0; }
.ir-report-pane { padding: 0; }
.ir-report-pane-head {
  align-items: flex-start;
  flex-wrap: wrap;
  margin: 0;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.ir-report-pane-head h2, .ir-report-archive h2 { font-size: 15px; }
.ir-report-pane-head .actions { gap: 6px; }
.ir-report-pane-head .actions .btn { min-height: 32px; padding: 5px 9px; font-size: 12px; }
.ir-report-paper { max-width: 100%; padding: clamp(18px, 3vw, 34px); }
.ir-report-paper h2 { font-size: clamp(23px, 2.9vw, 29px); line-height: 1.26; margin-bottom: 12px; }
.ir-report-paper h3 { margin-top: 18px; font-size: 16px; }
.ir-report-paper li { margin-top: 4px; }
.ir-report-paper a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 2px; }

.ir-report-editor { display: grid; gap: 12px; padding: 16px; }
.ir-report-editor .field > span { font-weight: 660; }
.ir-report-editor textarea { line-height: 1.65; }

.ir-report-archive { padding: 14px; }
.ir-report-records {
  max-height: max(240px, min(650px, 70vh));
  overflow: auto;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.ir-report-record { display: grid; gap: 5px; padding: 11px 3px; border-top: 1px solid var(--border); }
.ir-report-record.is-current { padding-inline: 8px; background: var(--accent-soft); border-color: var(--accent-border); }
.ir-report-record-title {
  border: 0;
  padding: 0;
  background: none;
  color: var(--accent-dark);
  font-weight: 660;
  overflow-wrap: anywhere;
  text-align: start;
  cursor: pointer;
}

.ir-report-record-title:hover { text-decoration: underline; text-underline-offset: 2px; }
.ir-report-record-meta { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.ir-report-empty { padding: 20px 16px; color: var(--muted); overflow-wrap: anywhere; }
.ir-report-empty .btn { margin-top: 9px; }
.ir-report-archive .ir-report-empty { padding: 9px 0 0; font-size: 13px; }

@media (max-width: 1020px) {
  .ir-report-grid { grid-template-columns: minmax(0, 1fr); }
  .ir-report-records { max-height: 365px; }
}

@media (max-width: 540px) {
  .ir-report-control { width: 100%; }
  .ir-report-refresh { margin-inline-start: 0; }
  .ir-report-selectors .ir-toggle { padding-inline: 6px; }
}

@page irReport { size: A4; margin: 15mm 17mm; }

@media print {
  body:has(.ir-report-paper) { background: #fff; }
  body:has(.ir-report-paper) :is(.sidebar, .workspace-header, .skip-link, .ir-report-chrome, #toast, #dialog) {
    display: none !important;
  }

  body:has(.ir-report-paper) :is(.app-shell, .workspace, main, .ir-report-center, .ir-report-grid, .ir-report-pane) {
    display: block;
    position: static;
    width: auto;
    max-width: none;
    height: auto;
    min-height: 0;
    overflow: visible;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: white;
  }

  .ir-report-paper { page: irReport; padding: 0; color: #151923; font-size: 10.5pt; line-height: 1.45; }
  .ir-report-paper :is(h2, h3, h4) { break-after: avoid; }
  .ir-report-paper h2 { font-size: 18pt; }
  .ir-report-paper h3 { margin-top: 12pt; font-size: 13pt; }
  .ir-report-paper :is(p, li) { orphans: 3; widows: 3; }
}
