.system-admin-page { display:flex; flex-direction:column; gap:12px; min-width:0; }
body #content .system-admin-page button { width:auto; margin:0; flex:0 0 auto; }
body #content .system-admin-page nav, body #content .system-admin-page .sa-actions, body #content .system-admin-page .sa-row-actions { display:flex; flex-direction:row; align-items:center; gap:6px; }
body #content .system-admin-page .sa-panel { margin:0; }
.system-admin-page .sa-page-head, .system-admin-page .sa-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:0 0 10px; }
.system-admin-page h3, .system-admin-page h4 { margin:0; }
.system-admin-page h3 small { color:#64748b; font-size:12px; font-weight:400; margin-left:8px; }
.system-admin-page nav, .system-admin-page .sa-actions, .system-admin-page .sa-row-actions { display:flex; align-items:center; flex-wrap:wrap; gap:6px; }
.system-admin-page .sa-panel { padding:14px 16px; margin:0; min-width:0; }
.system-admin-page .sa-panel.sa-jump-target { outline:2px solid #2563eb; outline-offset:2px; }
body #content .system-admin-page .sa-page-head [data-system-action="jump"][aria-current="location"] { color:#fff; background:#155bc4; border-color:#155bc4; }
.system-admin-page .sa-help { color:#64748b; font-size:12px; margin:0 0 10px; }
.system-admin-page .sa-page-message:empty, .system-admin-page .sa-form-message:empty { display:none; }
.system-admin-page .sa-page-message, .system-admin-page .sa-form-message { padding:9px 12px; border-radius:5px; background:#eff6ff; color:#1e40af; }
.system-admin-page .sa-error { color:#b42318; background:#fff7ed; }
.system-admin-page .table-scroll { max-width:100%; overflow:auto; }
.system-admin-page table { width:100%; border-collapse:collapse; table-layout:auto; }
.system-admin-page th, .system-admin-page td { padding:9px 10px; vertical-align:middle; text-align:left; overflow-wrap:anywhere; }
.system-admin-page tbody tr:nth-child(even) { background:#f7f9fc; }
.system-admin-page tbody tr:hover { background:#edf4ff; }
.system-admin-page td small { display:block; color:#64748b; margin-top:3px; font-size:12px; }
.system-admin-page td:last-child { min-width:130px; white-space:nowrap; }
.system-admin-page .sa-row-actions button { padding:4px 9px; min-height:28px; font-size:12px; }
.system-admin-page .sa-more { display:inline-block; position:relative; }
.system-admin-page .sa-more summary { border:1px solid #cddbf0; color:#145abe; border-radius:5px; padding:4px 9px; cursor:pointer; list-style:none; font-size:12px; }
.system-admin-page .sa-more summary::after { content:' ▾'; }
.system-admin-page .sa-more[open] > button { color:#b42318; display:block; margin-top:5px; }
.system-admin-page .sa-backup-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin-bottom:14px; }
.system-admin-page .sa-backup-grid > div { padding:12px; background:#f7f9fc; border:1px solid #e1e8f3; border-radius:6px; }
.system-admin-page .sa-backup-grid > div:first-child { background:#f1f6ff; }
.system-admin-page .sa-backup-file summary { cursor:pointer; color:#64748b; font-size:12px; margin-top:4px; }
.system-admin-page .sa-backup-file small { max-width:440px; overflow-wrap:anywhere; }
.system-admin-page .sa-backup-grid p { font-size:12px; color:#64748b; line-height:1.6; margin:6px 0 10px; }
.system-admin-page .sa-file { display:inline-flex; align-items:center; padding:7px 12px; border:1px solid #cddbf0; color:#145abe; border-radius:5px; cursor:pointer; position:relative; overflow:hidden; font-size:13px; }
.system-admin-page .sa-file input { position:absolute; inset:0; opacity:0; cursor:pointer; width:100%; min-width:0; }
.system-admin-page details[data-system-fold] > summary { cursor:pointer; display:flex; align-items:center; flex-wrap:wrap; gap:12px; min-height:24px; color:#274365; }
.system-admin-page details[data-system-fold] > summary::before { content:'▸'; }
.system-admin-page details[data-system-fold][open] > summary::before { content:'▾'; }
.system-admin-page details[data-system-fold] > summary span { color:#64748b; font-size:12px; }
.system-admin-page details[data-system-fold][open] > summary { margin-bottom:14px; }
.system-admin-page .sa-form { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px 16px; margin:0; }
.system-admin-page .sa-field { display:flex; flex-direction:column; min-width:0; gap:5px; font-weight:400; }
.system-admin-page .sa-field > span { color:#274365; font-size:13px; }
.system-admin-page .sa-field input, .system-admin-page .sa-field select, .system-admin-page .sa-field textarea { width:100%; min-width:0; box-sizing:border-box; margin:0; }
.system-admin-page .sa-wide { grid-column:1 / -1; }
.system-admin-page .sa-form-actions { display:flex; align-items:center; justify-content:flex-end; gap:8px; padding-top:12px; border-top:1px solid #e1e8f3; margin:0; }
.system-admin-page .sa-summary { display:flex; gap:12px; flex-wrap:wrap; margin-bottom:12px; color:#64748b; font-size:12px; }
.system-admin-page .sa-preview { margin-top:14px; border:1px solid #d4e0f0; border-radius:6px; padding:12px; }
.system-admin-page .sa-preview h4 { margin-bottom:10px; }
.system-admin-page .sa-preview .table-scroll { max-height:320px; margin:10px 0; }
.system-admin-page .sa-preview details { margin:10px 0; }
.system-admin-page .sa-modal { position:fixed; inset:0; z-index:1500; display:flex; align-items:center; justify-content:center; padding:20px; }
.system-admin-page .sa-modal.hidden { display:none; }
.system-admin-page .sa-modal-backdrop { position:absolute; inset:0; background:rgba(24,37,57,.48); }
.system-admin-page .sa-dialog { position:relative; width:min(760px,100%); max-height:calc(100dvh - 40px); display:flex; flex-direction:column; background:white; border:1px solid #d4e0f0; border-radius:8px; box-shadow:0 18px 48px #14263f33; padding:0; overflow:hidden; }
.system-admin-page .sa-dialog > header { margin:0; padding:14px 18px; border-bottom:1px solid #d4e0f0; flex-shrink:0; }
.system-admin-page .sa-dialog > form { padding:16px 18px; overflow:auto; }
.system-admin-page .sa-dialog .sa-form-actions { position:sticky; bottom:-16px; background:white; padding-bottom:12px; z-index:1; }
body:has(.system-admin-page) > .bf-modal { z-index:1600; }
#content:has(.system-admin-page #systemBackup) [data-company-toolbar] [data-company-backup] { display:none; }
#content:has(.system-admin-page #systemBackup) > [data-company-toolbar]:not(:has([data-company-kind])) { display:none; }
@media (max-width:768px) {
  .system-admin-page .sa-page-head, .system-admin-page .sa-heading { flex-wrap:wrap; }
  .system-admin-page .sa-panel { padding:12px; }
  .system-admin-page .sa-backup-grid, .system-admin-page .sa-form { grid-template-columns:minmax(0,1fr); }
  .system-admin-page .sa-modal { padding:10px; }
  .system-admin-page .sa-dialog { max-height:calc(100dvh - 20px); }
  .system-admin-page .sa-dialog > header, .system-admin-page .sa-dialog > form { padding:12px; }
  .system-admin-page .sa-dialog .sa-form-actions { bottom:-12px; flex-wrap:wrap; }
}
