[data-theme] .table {
    background-color: var(--table-bg, var(--surface));
    color: var(--table-text, var(--text-primary));
}

[data-theme] .table thead th,
[data-theme] .table thead td {
    background-color: var(--table-header-bg, var(--surface-alt));
    color: var(--table-header-text, var(--text-primary));
    border-color: var(--table-border, var(--border));
}

[data-theme] .table thead th a,
[data-theme] .table thead th a .icon,
[data-theme] .table thead th a i {
    color: inherit;
    text-decoration: none;
}

[data-theme] .table thead th a:hover,
[data-theme] .table thead th a:hover .icon,
[data-theme] .table thead th a:hover i {
    color: var(--table-header-link-hover, inherit);
    text-decoration: none;
}

[data-theme] .table tbody td,
[data-theme] .table tbody th {
    border-color: var(--border, #d9dede);
    color: var(--text-primary, #222222);
    vertical-align: middle;
}

[data-theme] .table tbody tr.is-row-clickable {
    cursor: pointer;
}

[data-theme] .table tbody td a {
    color: var(--table-link-color, var(--info));
}

[data-theme] .table tbody td a:not(.button):hover {
    color: var(--table-link-hover-color, var(--primary));
    text-decoration: none;
}

    [data-theme] .theme-empty-state-icon {
        color: var(--text-secondary, #435A5F);
    }

    [data-theme] .theme-empty-state-title {
        color: var(--text-primary, #222222);
    }

    [data-theme] .theme-empty-state-subtitle {
        color: var(--text-secondary, #435A5F);
    }
    /* Pagination — använd temavariabler så knappar följer valt tema */
    [data-theme] .pagination .pagination-previous,
    [data-theme] .pagination .pagination-next,
    [data-theme] .pagination .pagination-link {
        background: transparent;
        color: var(--text-primary, #222);
        border: 1px solid var(--border, #d9dede);
        border-radius: var(--radius-md);
        padding: 0.35rem 0.6rem;
        margin: 0 0.15rem;
        min-width: 2.25rem;
        text-align: center;
        transition: background-color var(--duration-base) ease, color var(--duration-base) ease, border-color var(--duration-base) ease;
    }
        /* Hover ska följa temat */
        [data-theme] .pagination .pagination-previous:hover,
        [data-theme] .pagination .pagination-next:hover,
        [data-theme] .pagination .pagination-link:hover {
            background-color: var(--table-row-hover, rgba(67,90,95,0.06));
            color: var(--table-header-link-hover, var(--primary, #ED6B19));
            border-color: var(--table-header-link-hover, var(--primary, #ED6B19));
        }
        /* Aktiv sida (markerad) — använd primärfärg med kontrasttext */
        [data-theme] .pagination .pagination-link.is-current {
            background-color: var(--primary, #ED6B19);
            color: var(--button-primary-text, #fff); /* lägg till --button-primary-text i teman om behövligt */
            border-color: var(--primary, #ED6B19);
            box-shadow: none;
        }
        /* Småjustering för prev/next när de är disabled */
        [data-theme] .pagination .pagination-previous.is-disabled,
        [data-theme] .pagination .pagination-next.is-disabled,
        [data-theme] .pagination .pagination-link[disabled] {
            opacity: 0.55;
            pointer-events: none;
        }
