:root { color-scheme: light; font: 16px/1.5 system-ui, sans-serif; color: #172b4d; background: #f3f5f8; }
body { margin: 0; padding: 24px; }
.model-header, #model-root, #model-error { max-width: 1280px; margin: 0 auto; }
.model-header { margin-bottom: 20px; }
.model-header h1 { font-size: 24px; line-height: 1.3; margin: 0 0 8px; }
.model-banner { margin: 0; color: #42546e; }
#model-root { padding: 24px; background: white; border: 1px solid #d7dfe9; border-radius: 8px; overflow-x: auto; }
#model-root :is(h1, h2, h3, h4) { color: #172b4d; line-height: 1.35; }
#model-root table { border-collapse: collapse; max-width: 100%; }
#model-root :is(td, th) { padding: 8px; vertical-align: top; }
#model-root th { text-align: left; color: #344968; }
#model-root :is(table.list, table.valueTable, table#characteristic, table#ktruCharacteristic, table#ktruSearchResult) { width: 100%; }
#model-root :is(table#characteristic, table#ktruCharacteristic, table#ktruSearchResult) > :is(thead, tbody) > tr > :is(td, th) { border: 1px solid #d7dfe9; }
#model-root :is(input:not([type]), input[type=text], input[type=number], textarea, select) { box-sizing: border-box; max-width: 100%; min-height: 36px; padding: 6px 8px; border: 1px solid #aab8cc; border-radius: 4px; font: inherit; color: #172b4d; background: #fff; }
#model-root textarea { min-height: 80px; }
#model-root :is(input[type=checkbox], input[type=radio]) { width: 18px; height: 18px; margin: 0 6px 0 0; vertical-align: middle; accent-color: #174ea6; }
#model-root :is(button, input[type=button], input[type=submit]) { min-height: 40px; padding: 8px 14px; border: 1px solid #174ea6; border-radius: 4px; background: #174ea6; color: #fff; font: inherit; cursor: pointer; }
#model-root a { color: #174ea6; }
#model-root :is(button, input, select, textarea, a):focus-visible { outline: 3px solid #2563eb; outline-offset: 3px; }
#model-root :is(button, input, select):disabled { cursor: default; }
#model-root .popUpWrapper { box-sizing: border-box; max-width: 100%; max-height: none !important; height: auto !important; margin: 20px 0; padding: 20px; border: 2px solid #8aa2c6; background: #fff; }
#model-root .characteristic-value > div > span { white-space: nowrap; }
#model-root .characteristic-value > div > span br { line-height: 1.8; }
#model-root .paginator, #model-root .paginator > .paging { display: flex; gap: 8px; list-style: none; padding: 0; }
#model-root .paginator :is(a, [aria-current]) { display: inline-block; min-width: 32px; padding: 4px 8px; text-align: center; border: 1px solid #aab8cc; border-radius: 4px; }
#model-root .paginator [aria-current] { background: #e8effa; font-weight: 600; }
#model-root .searchImg:empty::after { content: 'Выбрать'; }
.errorRed, #model-error { color: #a21c14; }
#model-error:not(:empty) { padding-top: 16px; }
/* Recorded hidden states remain hidden; decoration must not reveal inactive controls. */
#model-root [hidden], #model-root input[type=hidden] { display: none !important; }
@media (max-width: 640px) {
  body { padding: 12px; }
  #model-root { padding: 12px; }
  #model-root .popUpWrapper { padding: 12px; }
  #model-root :is(td, th) { padding: 6px; }
}
