.selo-smart-table {
    --selo-table-border: var(--bs-border-color, #e5e7eb);
    --selo-table-muted: var(--bs-secondary-color, #64748b);
    --selo-table-soft: var(--bs-tertiary-bg, #f8fafc);
    --selo-table-surface: var(--bs-body-bg, #ffffff);
    position: relative;
}

.selo-table-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.selo-table-title-wrap {
    min-width: 0;
}

.selo-table-title {
    margin: 0;
    color: var(--bs-heading-color, #111827);
    font-size: 22px;
    font-weight: 600;
    line-height: 1.3;
}

.selo-table-description {
    margin: 4px 0 0;
    color: var(--selo-table-muted);
    font-size: 13px;
}

.selo-table-header-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.selo-table-filter-card {
    margin-bottom: 14px;
    padding: 14px;
    background: var(--selo-table-surface);
    border: 1px solid var(--selo-table-border);
    border-radius: 12px;
    box-shadow:
        0 7px 22px
        rgba(15, 23, 42, 0.04);
}

.selo-filter-label {
    display: block;
    margin-bottom: 6px;
    color: var(--bs-heading-color, #111827);
    font-size: 12px;
    font-weight: 500;
}

.selo-table-stage {
    position: relative;
    min-height: 180px;
    overflow: hidden;
    background: var(--selo-table-surface);
    border: 1px solid var(--selo-table-border);
    border-radius: 12px;
    box-shadow:
        0 10px 28px
        rgba(15, 23, 42, 0.055);
}

.selo-table-loading {
    position: absolute;
    z-index: 15;
    top: 12px;
    left: 50%;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 7px 12px;
    color: var(--bs-body-color, #334155);
    font-size: 12px;
    background: var(--selo-table-surface);
    border: 1px solid var(--selo-table-border);
    border-radius: 999px;
    box-shadow:
        0 10px 24px
        rgba(15, 23, 42, 0.12);
    transform: translateX(-50%);
}

.selo-smart-table.is-loading
[data-selo-table-results] {
    pointer-events: none;
    opacity: 0.48;
    transition: opacity 0.15s ease;
}

.selo-table-scroll {
    width: 100%;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
}

.selo-data-table {
    width: 100%;
    min-width: 760px;
    margin: 0;
    border-collapse: separate;
    border-spacing: 0;
}

.selo-data-table
> :not(caption)
> *
> * {
    padding: 13px 14px;
    border-bottom:
        1px solid
        var(--selo-table-border);
    vertical-align: middle;
}

.selo-data-table thead th {
    color: var(--selo-table-muted);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.035em;
    text-transform: uppercase;
    background: var(--selo-table-soft);
    white-space: nowrap;
}

.selo-data-table tbody td {
    color: var(--bs-body-color, #334155);
    font-size: 13px;
    background: var(--selo-table-surface);
}

.selo-data-table
tbody
tr:last-child
td {
    border-bottom: 0;
}

.selo-data-table
tbody
tr:hover
td {
    background: rgba(148, 163, 184, 0.07);
}

.selo-sort-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    width: 100%;
    color: inherit;
    text-decoration: none;
}

.selo-sort-link:hover,
.selo-sort-link.is-active {
    color: var(--bs-primary, #8224e3);
}

.selo-sort-direction {
    font-size: 12px;
    line-height: 1;
}

.selo-table-primary {
    color: var(--bs-heading-color, #111827);
    font-weight: 600;
    line-height: 1.35;
}

.selo-table-secondary {
    margin-top: 3px;
    color: var(--selo-table-muted);
    font-size: 12px;
    line-height: 1.35;
}

.selo-table-actions {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
}

.selo-table-actions .btn {
    white-space: nowrap;
}

.selo-table-empty {
    padding: 52px 20px;
    text-align: center;
}

.selo-table-empty-title {
    margin: 0;
    color: var(--bs-heading-color, #111827);
    font-size: 16px;
    font-weight: 600;
}

.selo-table-empty-text {
    margin: 5px 0 0;
    color: var(--selo-table-muted);
    font-size: 13px;
}

.selo-pagination-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 13px 14px;
    border-top:
        1px solid
        var(--selo-table-border);
}

.selo-pagination-summary {
    color: var(--selo-table-muted);
    font-size: 12px;
}

.selo-pagination {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 5px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.selo-page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    min-height: 34px;
    padding: 6px 10px;
    color: var(--bs-body-color, #334155);
    font-size: 12px;
    text-decoration: none;
    background: var(--selo-table-surface);
    border:
        1px solid
        var(--selo-table-border);
    border-radius: 8px;
}

.selo-page-link:hover {
    color: var(--bs-primary, #8224e3);
    border-color:
        var(--bs-primary, #8224e3);
}

.selo-page-link.is-active {
    color: #ffffff;
    background:
        var(--bs-primary, #8224e3);
    border-color:
        var(--bs-primary, #8224e3);
}

.selo-page-link.is-disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.selo-table-checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.selo-product-thumb {
    width: 44px;
    height: 44px;
    object-fit: cover;
    background: var(--selo-table-soft);
    border:
        1px solid
        var(--selo-table-border);
    border-radius: 9px;
}

@media (max-width: 767.98px) {
    .selo-table-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .selo-table-header-actions,
    .selo-table-header-actions .btn {
        width: 100%;
    }

    .selo-table-header-actions .btn {
        justify-content: center;
    }

    .selo-table-stage {
        overflow: visible;
        background: transparent;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .selo-table-scroll {
        overflow: visible;
    }

    .selo-data-table {
        min-width: 0;
        border: 0;
    }

    .selo-data-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
        clip-path: inset(50%);
    }

    .selo-data-table,
    .selo-data-table tbody,
    .selo-data-table tr,
    .selo-data-table td {
        display: block;
        width: 100%;
    }

    .selo-data-table tbody {
        display: grid;
        gap: 10px;
    }

    .selo-data-table tbody tr {
        overflow: hidden;
        background: var(--selo-table-surface);
        border:
            1px solid
            var(--selo-table-border);
        border-radius: 12px;
        box-shadow:
            0 7px 20px
            rgba(15, 23, 42, 0.045);
    }

    .selo-data-table tbody td {
        display: grid;
        grid-template-columns:
            minmax(92px, 34%)
            1fr;
        gap: 12px;
        padding: 10px 12px;
        text-align: right !important;
        border-bottom:
            1px solid
            var(--selo-table-border);
    }

    .selo-data-table
    tbody
    td::before {
        content: attr(data-label);
        align-self: center;
        color: var(--selo-table-muted);
        font-size: 14px;
        font-weight: 600;
        letter-spacing: 0.025em;
        text-align: left;
        text-transform: uppercase;
    }

    .selo-data-table
    tbody
    td[data-label=""] {
        grid-template-columns: 1fr;
    }

    .selo-data-table
    tbody
    td[data-label=""]::before {
        display: none;
    }

    .selo-data-table
    tbody
    td:last-child {
        border-bottom: 0;
    }

    .selo-table-actions {
        justify-content: flex-end;
    }

    .selo-pagination-wrap {
        align-items: stretch;
        flex-direction: column;
        background: var(--selo-table-surface);
        border:
            1px solid
            var(--selo-table-border);
        border-radius: 12px;
    }

    .selo-pagination {
        justify-content: flex-start;
    }
}
/* --------------------------------------------------------------------------
   Smart Table compact toolbar and collapsible filters
   SeloCommerce by Webnion — Developed by Anik & Shohan.
   -------------------------------------------------------------------------- */

.selo-smart-table .selo-table-header {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) auto;
    align-items: center;
    gap: 14px;
    margin-bottom: 10px;
    padding: 10px 12px;
    background: var(--selo-table-surface);
    border: 1px solid var(--selo-table-border);
    border-radius: 12px;
    box-shadow: 0 5px 18px rgba(15, 23, 42, 0.035);
}

.selo-smart-table .selo-table-title-wrap {
    min-width: 0;
}

.selo-smart-table .selo-table-title {
    overflow: hidden;
    margin: 0;
    color: var(--bs-heading-color, #111827);
    font-size: 17px;
    font-weight: 600;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.selo-smart-table .selo-table-description {
    overflow: hidden;
    margin: 3px 0 0;
    color: var(--selo-table-muted);
    font-size: 14px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.selo-smart-table .selo-table-header-actions {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 6px;
    min-width: 0;
}

.selo-smart-table .selo-table-header-actions > * {
    flex: 0 0 auto;
}

.selo-smart-table .selo-table-header-actions .btn,
.selo-smart-table .selo-bulk-bar .btn,
.selo-smart-table .selo-filter-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: auto;
    min-height: 34px;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
}

.selo-smart-table .selo-bulk-bar {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 6px;
    min-width: 0;
}

.selo-smart-table .selo-bulk-bar > * {
    flex: 0 0 auto;
}

.selo-smart-table .selo-bulk-bar .form-select,
.selo-smart-table .selo-bulk-bar .form-control {
    width: auto;
    min-width: 142px;
    min-height: 34px;
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 8px;
    font-size: 12px;
}

.selo-smart-table .selo-bulk-bar [data-selo-bulk-extra] {
    display: inline-flex;
    flex: 0 0 auto;
}

.selo-smart-table .selo-bulk-bar [data-selo-bulk-extra][hidden] {
    display: none !important;
}

.selo-smart-table .selo-bulk-bar [data-selo-bulk-extra] .form-select,
.selo-smart-table .selo-bulk-bar [data-selo-bulk-extra] .form-control {
    min-width: 145px;
    max-width: 190px;
}

.selo-smart-table .selo-selected-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 32px;
    padding: 5px 8px;
    color: var(--selo-table-muted);
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    background: var(--selo-table-soft);
    border: 1px solid var(--selo-table-border);
    border-radius: 999px;
    white-space: nowrap;
}

.selo-smart-table .selo-filter-toggle {
    color: var(--bs-body-color, #334155);
    background: var(--selo-table-surface);
    border: 1px solid var(--selo-table-border);
}

.selo-smart-table .selo-filter-toggle:hover,
.selo-smart-table .selo-filter-toggle:focus-visible,
.selo-smart-table .selo-filter-toggle.is-active,
.selo-smart-table.has-active-filters .selo-filter-toggle {
    color: var(--bs-primary, #8224e3);
    background: color-mix(in srgb, var(--bs-primary, #8224e3) 7%, var(--selo-table-surface));
    border-color: color-mix(in srgb, var(--bs-primary, #8224e3) 38%, var(--selo-table-border));
}

.selo-smart-table .selo-filter-toggle .mdi {
    font-size: 16px;
    line-height: 1;
}

.selo-smart-table .selo-filter-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    background: var(--bs-primary, #8224e3);
    border-radius: 999px;
}

.selo-smart-table .selo-filter-count[hidden] {
    display: none !important;
}

.selo-smart-table .selo-table-filter-card {
    margin-bottom: 10px;
    padding: 10px;
    background: var(--selo-table-surface);
    border: 1px solid var(--selo-table-border);
    border-radius: 12px;
    box-shadow: 0 5px 18px rgba(15, 23, 42, 0.035);
}

.selo-smart-table .selo-table-filter-card[hidden] {
    display: none !important;
}

.selo-smart-table .selo-table-filter-card.is-open {
    animation: selo-filter-card-in 0.16s ease-out both;
}

@keyframes selo-filter-card-in {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.selo-smart-table .selo-filter-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--selo-table-border);
}

.selo-smart-table .selo-filter-card-title {
    margin: 0;
    color: var(--bs-heading-color, #111827);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.25;
}

.selo-smart-table .selo-filter-card-text {
    margin: 2px 0 0;
    color: var(--selo-table-muted);
    font-size: 14px;
    line-height: 1.3;
}

.selo-smart-table .selo-filter-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    padding: 0;
    color: var(--selo-table-muted);
    font-size: 17px;
    line-height: 1;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 7px;
}

.selo-smart-table .selo-filter-close:hover,
.selo-smart-table .selo-filter-close:focus-visible {
    color: var(--bs-heading-color, #111827);
    background: var(--selo-table-soft);
    border-color: var(--selo-table-border);
}

.selo-smart-table .selo-filter-grid {
    --bs-gutter-x: 0.5rem;
    --bs-gutter-y: 0.5rem;
}

.selo-smart-table .selo-filter-label {
    display: block;
    margin-bottom: 4px;
    color: var(--bs-heading-color, #111827);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
}

.selo-smart-table .selo-table-filter-card .form-control,
.selo-smart-table .selo-table-filter-card .form-select,
.selo-smart-table .selo-table-filter-card .btn {
    min-height: 34px;
    border-radius: 8px;
    font-size: 14px;
}

.selo-smart-table .selo-table-filter-card .form-control,
.selo-smart-table .selo-table-filter-card .form-select {
    padding-top: 5px;
    padding-bottom: 5px;
}

.selo-smart-table .selo-table-stage {
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.045);
}

@media (max-width: 1199.98px) {
    .selo-smart-table .selo-table-header {
        grid-template-columns: minmax(180px, 0.75fr) minmax(0, 1.25fr);
    }

    .selo-smart-table .selo-table-header-actions {
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 2px;
        scrollbar-width: thin;
    }

    .selo-smart-table .selo-bulk-bar {
        min-width: max-content;
    }
}

@media (max-width: 767.98px) {
    .selo-smart-table .selo-table-header {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        align-items: stretch;
        gap: 9px;
        padding: 10px;
    }

    .selo-smart-table .selo-table-title {
        font-size: 16px;
        white-space: normal;
    }

    .selo-smart-table .selo-table-description {
        display: -webkit-box;
        overflow: hidden;
        font-size: 14px;
        white-space: normal;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }

    .selo-smart-table .selo-table-header-actions {
        width: 100%;
        overflow-x: auto;
        flex-wrap: nowrap;
        justify-content: flex-start;
        padding: 1px 0 3px;
        scrollbar-width: thin;
    }

    .selo-smart-table .selo-table-header-actions .btn,
    .selo-smart-table .selo-bulk-bar .btn,
    .selo-smart-table .selo-filter-toggle {
        width: auto;
        min-width: max-content;
    }

    .selo-smart-table .selo-bulk-bar {
        width: auto;
        min-width: max-content;
        flex-wrap: nowrap;
    }

    .selo-smart-table .selo-bulk-bar > * {
        flex: 0 0 auto;
    }

    .selo-smart-table .selo-selected-pill {
        min-width: max-content;
    }

    .selo-smart-table .selo-table-filter-card {
        padding: 10px;
    }

    .selo-smart-table .selo-filter-card-text {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .selo-smart-table .selo-filter-toggle > span:not(.selo-filter-count) {
        display: none;
    }

    .selo-smart-table .selo-filter-toggle {
        width: 34px;
        padding-right: 7px;
        padding-left: 7px;
    }

    .selo-smart-table .selo-filter-count {
        position: absolute;
        top: -5px;
        right: -5px;
        min-width: 16px;
        height: 16px;
        padding: 0 4px;
        font-size: 9px;
        border: 2px solid var(--selo-table-surface);
    }

    .selo-smart-table .selo-filter-toggle {
        position: relative;
    }

    .selo-smart-table .selo-table-filter-card .row > [class*="col-"] {
        flex: 0 0 100%;
        width: 100%;
        max-width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .selo-smart-table .selo-table-filter-card.is-open {
        animation: none;
    }
}