/* Рабочие данные используют те же листы, поля и строки, что настройки. */
.records-modal { width: min(620px, 100%); }
body:has(.modal-wrap:not(.leave) .records-modal) #toasts { visibility: hidden; }
.records-form, .records-fields, .records-field { display: grid; gap: var(--space-4); min-width: 0; }
.records-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: end; }
.records-field { gap: var(--space-1); }
.records-field > span { font-weight: 500; }
.records-field small, .records-hint, .records-empty, .records-operation small, .records-operation-head > span {
  color: var(--fg-muted);
  font-size: var(--text-sm);
}
.records-field :is(.input, .select) { width: 100%; min-width: 0; }
.records-field input[type=date] { display: block; appearance: none; max-width: 100%; }
.records-field textarea { resize: vertical; min-height: 8rem; padding-top: var(--space-2); }
.records-field textarea[rows="2"] { min-height: 4.5rem; }
.records-field input[readonly] { background: var(--surface-2); color: var(--fg-muted); }
.records-field input[type=date]::-webkit-date-and-time-value { text-align: start; }
.records-toolbar, .records-actions { display: flex; flex-wrap: wrap; align-items: end; gap: var(--space-2); }
.records-toolbar .records-field { flex: 1 1 10rem; }
.records-toolbar > [hidden] { display: none; }
.records-import-options > [hidden] { display: none; }
.records-import-options:has(> :not([hidden])) { margin-top: var(--space-4); }
.records-row-options .records-actions { padding-bottom: var(--space-2); }
.records-toolbar:focus { outline: none; }
.records-feedback:not([hidden]) {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-2);
  margin-top: var(--space-2); color: var(--fg-muted); font-size: var(--text-sm);
}
.records-error, .records-danger { color: var(--danger); }
.records-message, .records-preview, .records-empty, [data-statement-panel] > .records-hint { margin-top: var(--space-4); }
.records-preview { background: var(--surface-2); border-radius: var(--radius-md); padding: var(--space-4); }
.records-preview h3 { font-size: var(--text-lg); margin: 0 0 var(--space-1); }
.records-preview .records-actions { margin-top: var(--space-3); }
.records-name, .records-operation :is(p, small, summary) { overflow-wrap: anywhere; }
.records-roles { border: 0; min-width: 0; padding: 0; margin: 0; }
.records-roles legend { font-weight: 500; margin-bottom: var(--space-2); }
.records-role { border-top: 1px solid var(--border); }
.records-role > .check { min-height: var(--tap); }
.records-role > .records-fields { margin-bottom: var(--space-3); }
.records-role > [hidden] { display: none; }
.records-batch { margin-top: var(--space-3); }
.records-batch .records-actions { margin-top: var(--space-2); }
.records-review-terms { text-align: end; }
.records-operation .check { min-height: var(--tap); width: fit-content; }
.records-operations { list-style: none; padding: 0; margin: var(--space-4) 0 0; }
.records-operation { display: grid; gap: var(--space-1); padding: var(--space-3) 0; border-top: 1px solid var(--border); }
.records-operation-head { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-3); justify-content: space-between; align-items: baseline; }
.records-credit { color: var(--accent); }
.records-operation details { font-size: var(--text-sm); color: var(--fg-muted); }
.records-operation summary { cursor: pointer; min-height: var(--tap); align-content: center; }
.records-operation details p { white-space: pre-wrap; margin-bottom: var(--space-2); }
.records-operation .btn { justify-self: start; }
.deals-create { display: flex; width: max-content; margin: 0 auto var(--space-4); }
.deals-empty .records-actions > .btn-ghost { margin-left: 0; }

@media (max-width: 400px) {
  .records-fields { gap: var(--space-2); }
  .records-field small { display: block; }
}
