/* A comfortable, device-aware reading scale across every authenticated profile. */
html, body { width: 100%; max-width: 100%; overflow-x: hidden; overflow-x: clip; }
#app.portal-redesign, #app.portal-redesign .layout, #app.portal-redesign .main, #app.portal-redesign .content {
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
}
#app.portal-redesign :is(.grid, .two, .row, .section, .card, .interface-section-heading, .section-head, .actions, .welcome, .portal-client-workspace, .portal-record, .portal-facts) {
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
}
#app.portal-redesign :is(.tablewrap, .table-wrap, .table-scroll, .portal-tabs, .ops-tabs, .catalog-format-rail) {
  max-width: 100%;
}
#app.portal-redesign {
  --reading-body: clamp(15px, 1.05vw, 17px);
  --reading-small: clamp(13px, .92vw, 15px);
  font-size: var(--reading-body);
  line-height: 1.55;
}

#app.portal-redesign .welcome h1 { font-size: clamp(29px, 2.1vw, 34px); }
#app.portal-redesign .welcome :is(p, .interface-section-context, .section-sub, .section-subtitle) { font-size: var(--reading-small); line-height: 1.55; }
#app.portal-redesign :is(.portal-control, .portal-help > summary, .portal-preview-button, .portal-status-filter, .portal-tab, .portal-view-switch > .portal-control) {
  font-size: var(--reading-small);
  line-height: 1.4;
}
#app.portal-redesign .interface-section-heading > .actions:has(.portal-view-preferences) > :is(button, a.btn),
#app.portal-redesign .interface-section-heading > .actions > .portal-view-preferences > :is(.portal-control, .portal-help) { font-size: var(--reading-small); }
#app.portal-redesign :is(.btn, .portal-client-actions > .btn) { font-size: var(--reading-small); line-height: 1.4; min-height: 42px; }
#app.portal-redesign :is(.section h2, .portal-tab-content > h3, .portal-notice-group-heading h2) { font-size: clamp(18px, 1.35vw, 21px); line-height: 1.35; }
#app.portal-redesign :is(.portal-empty, .portal-muted, .portal-fact > span, .portal-overline, .portal-record, .portal-preview-facts, .portal-facts, .portal-notice-group, .portal-state, .badge, .field > label, .field label, .section-sub, .section-subtitle, .helper-text, .form-hint, small) {
  font-size: max(13px, .92em);
  line-height: 1.55;
}
#app.portal-redesign :is(input:not([type=hidden]):not([type=checkbox]):not([type=radio]), select, textarea) {
  font-size: 16px;
  line-height: 1.45;
}
#app.portal-redesign :is(td, th) { font-size: var(--reading-small); line-height: 1.45; }
#app.portal-redesign :is(.portal-tabs, .portal-tab-content, .organized-panel-content, .card.section) { line-height: 1.6; }

@media (min-width: 1500px) {
  #app.portal-redesign { --reading-body: 17px; --reading-small: 15px; }
}

@media (max-width: 760px) {
  #app.portal-redesign { --reading-body: 16px; --reading-small: 14px; padding-inline: 16px; }
  #app.portal-redesign :is(.welcome h1, .portal-tab-content > h3, .section h2) { font-size: clamp(19px, 5vw, 23px); }
  #app.portal-redesign :is(.portal-empty, .portal-muted, .portal-fact > span, .portal-overline, .portal-record, .portal-preview-facts, .portal-facts, .portal-notice-group, .portal-state, .badge, .field > label, .field label, .helper-text, .form-hint, small) { font-size: 14px; }
  #app.portal-redesign :is(.btn, .portal-control, .portal-help > summary, .portal-preview-button, .portal-tab, td, th) { font-size: 14px; }
  #app.portal-redesign :is(input:not([type=hidden]):not([type=checkbox]):not([type=radio]), select, textarea) { min-height: 44px; font-size: 16px; }
  #app.portal-redesign .portal-tab-content { padding: 18px 15px; }
}
