/* Tabulator — header/column borders, header filters, header styling, card mode */

/* Tabulator header column borders */
.tabulator-header .tabulator-col {
    border-right: 1px solid #dee2e6 !important;
    border-bottom: 1px solid #dee2e6 !important;
}

.tabulator-header .tabulator-col:last-child {
    border-right: none !important;
}

/* Hide header filter inputs when toggle is off */
.tabulator-header-filter-hidden div.tabulator-col-content input,
.tabulator-header-filter-hidden div.tabulator-col-content select {
    display: none !important;
}

/* Style column filter inputs with primary border */
.tabulator-col-content input,
.tabulator-col-content select {
    border: 1px solid var(--bs-primary) !important;
    border-radius: 0.25rem;
}

/* Tabulator data row column borders - only on larger screens */
@media (min-width: 768px) {
    .tabulator-row .tabulator-cell {
        border-right: 1px solid #dee2e6 !important;
    }

    .tabulator-row .tabulator-cell:last-child {
        border-right: none !important;
    }
}

.tabulator .tabulator-tableholder .tabulator-table {
    min-width: 100%;
}

/* Tabulator header styling — bolder titles, tighter padding, clear separator */
.tabulator-header {
    border-bottom: 2px solid #adb5bd !important;
}
.tabulator-header .tabulator-col-content {
    padding: .5rem .75rem;
}
.tabulator-col .tabulator-col-content .tabulator-col-title {
    font-weight: 600;
}
.tabulator-col-sorter {
    margin-left: .25rem;
    vertical-align: middle;
}

/* Mobile-card mode — strip the wrapper's border/shadow/rounded corners;
   each card already provides its own chrome. */
.tabulator-card-mode {
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    overflow: visible !important;
}

/* Freeze toggle in the show/hide column menu (snowflake icon button);
   the button carries the frozen state so the FA icon inherits its color. */
.tab-freeze-btn {
    background: none;
    border: 0;
    padding: 0 .25rem;
    font-size: .875rem;
    line-height: 1;
    color: var(--bs-secondary-color);
}
.tab-freeze-btn.is-frozen {
    color: var(--bs-primary);
}
.tab-freeze-btn:hover,
.tab-freeze-btn:focus-visible {
    color: var(--bs-primary);
}
/* Snowflake is disabled while any column to its left is unfrozen (the freeze
   follows a left-hand prefix); keep it clearly inert in the menu. */
.tab-freeze-btn:disabled {
    color: var(--bs-secondary-color);
    opacity: .35;
    cursor: not-allowed;
}