.fm-store { --fm-table-header-line: #dfe4d9; --fm-table-header-paper: #f5f7f0; }
.fm-admin { --fm-table-header-line: #dce4d2; --fm-table-header-paper: #f5f8ef; }

/* Separate borders let header corners round without changing column alignment. */
:is(.fm-store, .fm-admin) .table:has(> thead) { border-collapse: separate; border-spacing: 0; }
:is(.fm-store, .fm-admin) .table > thead > tr > :is(th, td) {
    padding: 10px !important;
    background: var(--fm-table-header-paper);
    border: 0 solid var(--fm-table-header-line) !important;
    border-bottom-width: 1px !important;
}
:is(.fm-store, .fm-admin) .table > thead > tr:first-child > :is(th, td),
:is(.fm-store, .fm-admin) #aiz-data-table > thead > tr:first-child > :is(th, td) { border-top: 1px solid var(--fm-table-header-line) !important; }
:is(.fm-store, .fm-admin) .table > thead > tr > :is(th, td):is(:first-child, .footable-first-visible) { border-inline-start-width: 1px !important; }
:is(.fm-store, .fm-admin) .table > thead > tr > :is(th, td):is(:last-child, .footable-last-visible) { border-inline-end-width: 1px !important; }
:is(.fm-store, .fm-admin) .table > thead > tr:first-child > :is(th, td):is(:first-child, .footable-first-visible) { border-start-start-radius: 10px; }
:is(.fm-store, .fm-admin) .table > thead > tr:first-child > :is(th, td):is(:last-child, .footable-last-visible) { border-start-end-radius: 10px; }
:is(.fm-store, .fm-admin) .table > thead + tbody > tr:first-child > :is(th, td) { border-top-width: 0; }

/* Keep bordered body grids at one pixel rather than doubling shared edges. */
:is(.fm-store, .fm-admin) .table-bordered:has(> thead) { border-width: 0; }
:is(.fm-store, .fm-admin) .table-bordered:has(> thead) > tbody > tr > :is(th, td) { border-bottom-width: 0; border-inline-end-width: 0; }
:is(.fm-store, .fm-admin) .table-bordered:has(> thead) > tbody > tr > :is(th, td):is(:last-child, .footable-last-visible) { border-inline-end-width: 1px; }
:is(.fm-store, .fm-admin) .table-bordered:has(> thead) > tbody > tr:last-child > :is(th, td) { border-bottom-width: 1px; }
