/* Preserve original cells and controls; collapse secondary fields in place. */
body table.mv-compact-table {
  display:block !important; width:100% !important; min-width:0 !important;
  max-width:100% !important; table-layout:auto; font-size:13px !important;
  border-collapse:collapse; margin-bottom:0;
}
body table.mv-compact-table > :is(thead,tbody,tfoot) { display:block !important; width:100%; }
body table.mv-compact-table > :is(thead,tbody,tfoot) > tr {
  display:grid; grid-template-columns:var(--mv-row-columns); align-items:center;
  gap:0 12px; width:100%; min-height:48px; height:auto !important;
  padding:0 12px; border-bottom:1px solid #e5eaf0; background:#fff;
}
body table.mv-compact-table > thead > tr { min-height:40px; background:#f8fafc; }
body table.mv-compact-table > :is(thead,tbody,tfoot) > tr > :is(th,td) {
  float:none !important; width:auto !important; min-width:0 !important;
  max-width:100%; height:auto !important; padding:6px 0 !important;
  border:0 !important; background:transparent !important; box-shadow:none !important;
  white-space:normal !important; overflow-wrap:anywhere; vertical-align:middle;
}
body table.mv-compact-table > :is(thead,tbody,tfoot) > tr > .mv-row-summary { display:block !important; grid-row:1; }
body table.mv-compact-table > :is(thead,tbody,tfoot) > tr > .mv-row-secondary { display:none !important; }
body table.mv-compact-table > tbody > tr > .mv-row-primary { position:relative; padding-right:38px !important; }
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary > :is(.small,.muted.small,.text-muted.small) { display:none; }
body table.mv-compact-table > tbody > tr > .mv-row-primary > :is(a,strong,span) {
  max-width:100%; display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:1; overflow:hidden; line-height:1.4; white-space:nowrap; text-overflow:ellipsis;
}
body table.mv-compact-table > tbody > tr.mv-row-expanded > .mv-row-primary > :is(a,strong,span) { -webkit-line-clamp:unset; white-space:normal; }
.mv-row-toggle { position:absolute; top:50%; right:0; transform:translateY(-50%); display:grid; place-items:center;
  width:32px; height:32px; border:1px solid #d7e0e9; border-radius:8px; background:#fff; color:#334155; cursor:pointer; }
.mv-row-toggle::before { content:'+'; font:600 20px/1 system-ui,sans-serif; }
.mv-row-toggle[aria-expanded=true]::before { content:'\2212'; }
.mv-row-toggle:hover { background:#edf3f8; }
.mv-row-toggle:focus-visible { outline:3px solid #2563eb; outline-offset:2px; }
body table.mv-compact-table > tbody > tr.mv-row-expanded { background:#f8fafc !important; padding-bottom:12px; }
body table.mv-compact-table > tbody > tr.mv-row-expanded > .mv-row-secondary {
  display:block !important; grid-column:1 / -1 !important; grid-row:var(--mv-detail-row,auto);
  width:calc(50% - 6px) !important; min-width:0; justify-self:var(--mv-detail-align,start); align-self:stretch; box-sizing:border-box;
  padding:9px 11px !important; margin-top:8px; background:#fff !important; border-radius:8px;
}
body table.mv-compact-table > tbody > tr.mv-row-expanded > .mv-row-secondary::before {
  content:attr(data-field-label); display:block; margin-bottom:6px; color:#64748b;
  font-size:11px; font-weight:700; line-height:1.4; text-transform:uppercase; letter-spacing:.04em;
}
body table.mv-compact-table > tbody > tr.mv-row-expanded > .mv-row-secondary :is(.d-flex,.btn-group) { flex-wrap:wrap; gap:6px; }
body table.mv-compact-table > tbody > tr.mv-row-message > td { display:block !important; grid-column:1 / -1; }
body table.mv-compact-table > thead > tr > th { font-size:11px !important; letter-spacing:.03em; text-transform:uppercase; color:#64748b; }
body table.mv-compact-table .sortable::after { content:' \2195'; }
body table.mv-compact-table .sortable.sort-asc::after { content:' \2191'; }
body table.mv-compact-table .sortable.sort-desc::after { content:' \2193'; }
body table.mv-compact-table > tbody > tr > td :is(img,video) {
  width:36px !important; height:36px !important; min-width:36px !important; min-height:0 !important;
  max-width:36px !important; max-height:36px !important; aspect-ratio:1;
  object-fit:contain; border-radius:8px; background:#f1f5f9;
}
body table.mv-compact-table .mv-row-media :is(button,a) { max-width:100%; }
body table.mv-compact-table img.mv-thumbnail-missing { font-size:0; color:transparent; border:1px dashed #cbd5e1; }
body table.mv-compact-table .badge { white-space:normal; font-size:11px; }
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-summary:not(.mv-row-primary){white-space:nowrap!important;overflow:hidden;text-overflow:ellipsis}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) .badge{white-space:nowrap!important;max-width:100%;overflow:hidden;text-overflow:ellipsis;vertical-align:middle}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary {white-space:nowrap!important;line-height:20px!important}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary :is(small,br,.small){display:none!important}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary :is(.customer-cell,.d-flex){flex-wrap:nowrap!important;min-width:0;gap:6px!important}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary :is(strong,a){white-space:nowrap!important;text-overflow:ellipsis;overflow:hidden;max-width:100%}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary .d-block{display:block!important;line-height:20px!important}
body table.mv-compact-table > tbody > tr:not(.mv-row-expanded) > .mv-row-primary > :not(.mv-row-toggle){max-height:36px;overflow:hidden}
@media(max-width:560px) {
 body table.mv-compact-table > tbody > tr.mv-row-expanded > .mv-row-secondary{width:100%!important;grid-row:auto!important;justify-self:stretch}
}
@media(max-width:600px) {
  body table.mv-compact-table { font-size:12px !important; }
  body table.mv-compact-table > :is(thead,tbody) > tr { gap:0 7px; padding-inline:8px; }
  body table.mv-compact-table > tbody > tr > .mv-row-primary { padding-right:31px !important; }
  .mv-row-toggle { width:27px; height:30px; }
}
@media print {
  body table.mv-compact-table { display:table !important; }
  body table.mv-compact-table > thead { display:table-header-group !important; }
  body table.mv-compact-table > tbody { display:table-row-group !important; }
  body table.mv-compact-table > tfoot { display:table-footer-group !important; }
  body table.mv-compact-table > :is(thead,tbody,tfoot) > tr { display:table-row; }
  body table.mv-compact-table > :is(thead,tbody,tfoot) > tr > :is(th,td) { display:table-cell !important; padding:8px !important; width:auto!important; }
  body table.mv-compact-table > tbody > tr.mv-row-expanded > .mv-row-secondary{width:auto!important;grid-row:auto!important}
  .mv-row-toggle { display:none; }
  body table.mv-compact-table .mv-row-secondary::before { content:none !important; }
}
