/* ====================================================== SLM Admin — Base CSS */
/* Brand: Armoni 360 — white dominant, green accent */

:root {
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    /* Colors — light theme, green accent */
    --bg-base: #f8fafb;
    --bg-card: #ffffff;
    --bg-input: #f4f6f8;
    --bg-hover: rgba(0, 0, 0, 0.02);

    --border: #e8ecf0;
    --border-light: #f0f2f5;

    --text: #1a1e24;
    --text-secondary: #5a6370;
    --text-muted: #9ca3af;

    --accent: #2DD4A0;
    --accent-dark: #1B6B5A;
    --accent-deep: #0F3D35;
    --accent-hover: #34D399;
    --accent-bg: rgba(45, 212, 160, 0.08);

    --success: #2DD4A0;
    --error: #ef4444;
    --warning: #f59e0b;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);

    /* Sidebar — dark theme */
    --bg-sidebar: #0f1117;
    --sidebar-text: rgba(255, 255, 255, 0.75);
    --sidebar-text-muted: rgba(255, 255, 255, 0.4);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-hover: rgba(255, 255, 255, 0.05);
    --sidebar-active: rgba(255, 255, 255, 0.08);

    /* Topbar */
    --topbar-height: 56px;

    /* Sidebar dimensions */
    --sidebar-width: 240px;
    --sidebar-collapsed-width: 64px;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font);
    background: var(--bg-base);
    color: var(--text);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--accent-dark);
    text-decoration: none;
}

a:hover {
    color: var(--accent);
}

/* ====================================================== Layout */

.layout {
    display: flex;
    min-height: 100vh;
}

/* ====================================================== Sidebar — Dark */

.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    border-right: 1px solid var(--sidebar-border);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
    transition: width 0.2s ease;
    overflow: hidden;
}

.sidebar-brand {
    padding: 20px 20px 16px;
    border-bottom: 1px solid var(--sidebar-border);
}

.sidebar-brand img {
    height: 26px;
    width: auto;
    transition: opacity 0.15s ease;
}

.sidebar-brand .sidebar-brand-icon {
    display: none;
    height: 26px;
    width: 26px;
}

.sidebar-nav {
    flex: 1;
    padding: 12px 8px;
    overflow-x: hidden;
    overflow-y: auto;
}

.sidebar-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--sidebar-text-muted);
    padding: 16px 12px 6px;
}

.sidebar-label:first-child {
    padding-top: 4px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 8px;
    color: var(--sidebar-text);
    font-size: 13px;
    font-weight: 450;
    transition: all 0.15s ease;
    cursor: pointer;
    position: relative;
    border-left: 2px solid transparent;
    margin-bottom: 2px;
    white-space: nowrap;
}

.sidebar-link span {
    transition: opacity 0.15s ease;
}

.sidebar-link svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    opacity: 0.6;
    transition: opacity 0.15s ease;
}

.sidebar-link:hover {
    background: var(--sidebar-hover);
    color: rgba(255, 255, 255, 0.95);
}

.sidebar-link:hover svg {
    opacity: 0.85;
}

.sidebar-link.active {
    background: var(--sidebar-active);
    color: #ffffff;
    font-weight: 550;
    border-left-color: var(--accent);
}

.sidebar-link.active svg {
    opacity: 1;
    color: var(--accent);
}

/* Sidebar footer */
.sidebar-footer {
    padding: 12px;
    border-top: 1px solid var(--sidebar-border);
    display: flex;
    align-items: center;
    gap: 8px;
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.sidebar-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(45, 212, 160, 0.15);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
    flex-shrink: 0;
    letter-spacing: 0.02em;
}

.sidebar-user-info {
    min-width: 0;
    line-height: 1.3;
}

.sidebar-user-info strong {
    display: block;
    font-size: 12px;
    font-weight: 550;
    color: rgba(255, 255, 255, 0.85);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-user-info span {
    display: block;
    font-size: 11px;
    color: var(--sidebar-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    color: var(--sidebar-text-muted);
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.sidebar-logout:hover {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
}

.sidebar-logout svg {
    width: 16px;
    height: 16px;
}

/* ====================================================== Sidebar toggle button */

.sidebar-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
    padding: 0;
    flex-shrink: 0;
}

.sidebar-toggle:hover {
    background: var(--bg-hover);
    color: var(--text);
}

.sidebar-toggle svg {
    width: 18px;
    height: 18px;
    transition: transform 0.2s ease;
}

/* ====================================================== Sidebar collapsed state */

body.sidebar-collapsed .sidebar {
    width: var(--sidebar-collapsed-width);
}

body.sidebar-collapsed .main {
    margin-left: var(--sidebar-collapsed-width);
}

body.sidebar-collapsed .sidebar-brand img.sidebar-brand-logo {
    display: none;
}

body.sidebar-collapsed .sidebar-brand .sidebar-brand-icon {
    display: block;
}

body.sidebar-collapsed .sidebar-label {
    opacity: 0;
    height: 0;
    padding: 0;
    margin: 0;
    overflow: hidden;
}

body.sidebar-collapsed .sidebar-link {
    justify-content: center;
    padding: 10px;
    border-left-color: transparent;
}

body.sidebar-collapsed .sidebar-link span {
    opacity: 0;
    width: 0;
    overflow: hidden;
    position: absolute;
}

body.sidebar-collapsed .sidebar-footer {
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 8px;
}

body.sidebar-collapsed .sidebar-user {
    justify-content: center;
}

body.sidebar-collapsed .sidebar-user-info {
    display: none;
}

body.sidebar-collapsed .sidebar-logout {
    width: 28px;
    height: 28px;
}

/* Collapsed toggle icon rotation */
body.sidebar-collapsed .sidebar-toggle svg {
    transform: scaleX(-1);
}

/* Tooltip on collapsed sidebar links */
body.sidebar-collapsed .sidebar-link {
    position: relative;
}

body.sidebar-collapsed .sidebar-link::after {
    content: attr(data-tooltip);
    position: absolute;
    left: calc(100% + 8px);
    top: 50%;
    transform: translateY(-50%);
    background: #1a1e24;
    color: #fff;
    font-size: 12px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 6px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
    z-index: 200;
}

body.sidebar-collapsed .sidebar-link:hover::after {
    opacity: 1;
}

/* ====================================================== Main + Topbar */

.main {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: margin-left 0.2s ease;
}

.topbar {
    height: var(--topbar-height);
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 50;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.topbar-breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
}

.topbar-breadcrumb .breadcrumb-separator {
    color: var(--text-muted);
    font-size: 12px;
}

.topbar-breadcrumb .breadcrumb-parent {
    color: var(--text-muted);
    font-weight: 400;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 450;
}

.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 2px rgba(45, 212, 160, 0.2);
}

.main-content {
    flex: 1;
    padding: 32px;
}

/* ====================================================== Components */

.page-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 24px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 16px;
    box-shadow: var(--shadow-sm);
}

.badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 6px;
    background: var(--accent-bg);
    color: var(--accent-dark);
}

.badge-success {
    background: rgba(45, 212, 160, 0.1);
    color: var(--accent-dark);
}

.badge-error {
    background: rgba(239, 68, 68, 0.08);
    color: var(--error);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #d97706;
}

/* ====================================================== Table */

.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

table th {
    text-align: left;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border);
}

table td {
    padding: 12px;
    font-size: 13px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-light);
}

table tr:hover td {
    background: var(--bg-hover);
}

/* ====================================================== Buttons */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    font-family: var(--font);
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}

.btn:hover {
    background: var(--bg-hover);
    color: var(--text);
    border-color: var(--border-light);
}

.btn-primary {
    background: var(--accent);
    color: var(--accent-deep);
    border-color: var(--accent);
    font-weight: 600;
}

.btn-primary:hover {
    background: var(--accent-hover);
    color: var(--accent-deep);
}

/* ====================================================== Utils */

/* ====================================================== Modal — reusable */

.slm-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 110;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: slmFadeIn 0.15s ease;
}

@keyframes slmFadeIn { from { opacity: 0; } to { opacity: 1; } }

.slm-modal {
    background: var(--bg-card);
    border-radius: 14px;
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
    margin: 20px;
    animation: slmSlideUp 0.2s ease;
}

@keyframes slmSlideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

.slm-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid var(--border);
}

.slm-modal-header h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
}

.slm-modal-close {
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 18px;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slm-modal-close:hover {
    background: var(--bg-hover);
    color: var(--text);
}

.slm-modal-body {
    padding: 20px 22px;
    overflow-y: auto;
    flex: 1;
}

.slm-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 14px 22px;
    border-top: 1px solid var(--border);
}

/* ====================================================== Form fields */

.slm-field {
    margin-bottom: 14px;
}

.slm-field label {
    display: block;
    font-size: 12px;
    font-weight: 550;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.slm-input, .slm-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 13px;
    font-family: var(--font);
    background: var(--bg-input);
    color: var(--text);
    outline: none;
    transition: border-color 0.15s;
}

.slm-input:focus, .slm-select:focus {
    border-color: var(--accent);
}

.slm-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ====================================================== Access sub-nav tabs */

.access-tabs {
    display: flex;
    gap: 4px;
    background: var(--bg-input);
    padding: 4px;
    border-radius: 10px;
    width: fit-content;
}

.access-tab {
    padding: 7px 18px;
    border: none;
    background: transparent;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 500;
    font-family: var(--font);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}

.access-tab:hover {
    color: var(--text);
}

.access-tab.active {
    background: var(--bg-card);
    color: var(--text);
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}

/* ====================================================== Permissions matrix */

.permissions-matrix {
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: auto;
    max-height: 320px;
}

.perm-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.perm-table th {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    padding: 8px 10px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-input);
    position: sticky;
    top: 0;
    z-index: 1;
}

.perm-table td {
    padding: 7px 10px;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-secondary);
}

.perm-table input[type="checkbox"] {
    width: 15px;
    height: 15px;
    accent-color: var(--accent);
    cursor: pointer;
}

/* ====================================================== Role checkboxes in user modal */

.roles-checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.role-check-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--text-secondary);
    padding: 5px 10px;
    border: 1px solid var(--border);
    border-radius: 7px;
    cursor: pointer;
    transition: all 0.15s;
}

.role-check-label:hover {
    border-color: var(--accent);
    background: var(--accent-bg);
}

.role-check-label input[type="checkbox"] {
    accent-color: var(--accent);
}

/* ====================================================== Custom Select — slm-select */

.slm-sel {
    position: relative;
    display: inline-block;
    min-width: 160px;
}

.slm-sel-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 13px;
    font-family: var(--font);
    background: var(--bg-card);
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.15s, box-shadow 0.15s;
    outline: none;
    min-height: 36px;
    user-select: none;
    white-space: nowrap;
}

.slm-sel-trigger:hover {
    border-color: #d0d5dd;
}

.slm-sel.open .slm-sel-trigger,
.slm-sel-trigger:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(45, 212, 160, 0.1);
}

.slm-sel-value {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.slm-sel-value.is-placeholder {
    color: var(--text-muted);
}

.slm-sel-arrow {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform 0.2s;
}

.slm-sel.open .slm-sel-arrow {
    transform: rotate(180deg);
}

/* Dropdown panel */
.slm-sel-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    min-width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1), 0 2px 6px rgba(0, 0, 0, 0.04);
    z-index: 120;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
    overflow: hidden;
}

.slm-sel.open .slm-sel-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.slm-sel.drop-up .slm-sel-dropdown {
    top: auto;
    bottom: calc(100% + 4px);
    transform: translateY(4px);
}

.slm-sel.drop-up.open .slm-sel-dropdown {
    transform: translateY(0);
}

/* Search */
.slm-sel-search-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-bottom: 1px solid var(--border);
}

.slm-sel-search-icon {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    flex-shrink: 0;
}

.slm-sel-search {
    width: 100%;
    border: none;
    background: transparent;
    font-size: 13px;
    font-family: var(--font);
    color: var(--text);
    outline: none;
    padding: 0;
}

.slm-sel-search::placeholder {
    color: var(--text-muted);
}

/* Options list */
.slm-sel-options {
    max-height: 200px;
    overflow-y: auto;
    padding: 4px;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}

.slm-sel-options::-webkit-scrollbar { width: 4px; }
.slm-sel-options::-webkit-scrollbar-track { background: transparent; }
.slm-sel-options::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.slm-sel-opt {
    padding: 7px 10px;
    font-size: 13px;
    color: var(--text);
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.1s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.slm-sel-opt:hover,
.slm-sel-opt.focused {
    background: var(--bg-input);
}

.slm-sel-opt.selected {
    color: var(--accent-dark);
    font-weight: 600;
    background: var(--accent-bg);
}

.slm-sel-opt.selected:hover,
.slm-sel-opt.selected.focused {
    background: rgba(45, 212, 160, 0.12);
}

.slm-sel-opt.placeholder {
    color: var(--text-muted);
    font-style: italic;
}

.slm-sel-opt.disabled {
    color: var(--text-muted);
    opacity: 0.5;
    cursor: default;
    pointer-events: none;
}

/* No results */
.slm-sel-empty {
    padding: 16px;
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
    display: none;
}

/* ====================================================== DataTables — theme override */

.dataTables_wrapper {
    font-family: var(--font);
    font-size: 13px;
    color: var(--text);
}

/* Hide default controls — we build our own toolbar */
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
    display: none !important;
}

/* Bottom bar: info left, pagination right */
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate {
    padding: 14px 0 2px;
    color: var(--text-muted);
    font-size: 12px;
}

.dataTables_wrapper .dataTables_info {
    float: left;
}

.dataTables_wrapper .dataTables_paginate {
    float: right;
}

.dataTables_wrapper::after {
    content: '';
    display: table;
    clear: both;
}

/* Pagination pills */
.dataTables_wrapper .dataTables_paginate .paginate_button {
    display: inline-block;
    padding: 5px 11px;
    margin: 0 2px;
    border: 1px solid var(--border) !important;
    border-radius: 7px;
    background: var(--bg-card) !important;
    color: var(--text-secondary) !important;
    font-size: 12px;
    font-family: var(--font);
    cursor: pointer;
    transition: all 0.12s;
    text-decoration: none;
}

.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: var(--bg-input) !important;
    color: var(--text) !important;
    border-color: #d0d5dd !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: var(--accent) !important;
    color: var(--accent-deep) !important;
    border-color: var(--accent) !important;
    font-weight: 600;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover {
    opacity: 0.3;
    cursor: default;
    background: transparent !important;
    border-color: var(--border) !important;
    color: var(--text-muted) !important;
}

/* Table core */
table.dataTable {
    border-collapse: collapse !important;
    width: 100% !important;
}

table.dataTable thead th {
    border-bottom: 2px solid var(--border) !important;
    border-top: none !important;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 10px 14px !important;
    background: transparent !important;
    white-space: nowrap;
}

/* Sort icons — custom arrows instead of default images */
table.dataTable thead th.sorting,
table.dataTable thead th.sorting_asc,
table.dataTable thead th.sorting_desc {
    background-image: none !important;
    cursor: pointer;
    position: relative;
    padding-right: 22px !important;
}

table.dataTable thead th.sorting::after,
table.dataTable thead th.sorting_asc::after,
table.dataTable thead th.sorting_desc::after {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    color: var(--text-muted);
}

table.dataTable thead th.sorting::after {
    content: '\f0dc';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    opacity: 0.25;
}

table.dataTable thead th.sorting_asc::after {
    content: '\f0de';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--accent-dark);
    opacity: 1;
}

table.dataTable thead th.sorting_desc::after {
    content: '\f0dd';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--accent-dark);
    opacity: 1;
}

table.dataTable tbody td {
    padding: 11px 14px !important;
    border-bottom: 1px solid var(--border-light) !important;
    font-size: 13px;
    color: var(--text-secondary);
    vertical-align: middle;
}

table.dataTable tbody tr:hover td {
    background: var(--bg-hover) !important;
}

table.dataTable.no-footer {
    border-bottom: none !important;
}

/* Custom toolbar above table */
.dt-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.dt-toolbar .dt-search {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-card);
    flex: 1;
    min-width: 200px;
    max-width: 360px;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.dt-toolbar .dt-search:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(45, 212, 160, 0.1);
}

.dt-toolbar .dt-search i {
    color: var(--text-muted);
    font-size: 13px;
    flex-shrink: 0;
}

.dt-toolbar .dt-search input {
    border: none;
    background: transparent;
    font-size: 13px;
    font-family: var(--font);
    color: var(--text);
    outline: none;
    width: 100%;
    padding: 0;
}

.dt-toolbar .dt-search input::placeholder {
    color: var(--text-muted);
}

.dt-toolbar .dt-per-page {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-muted);
    margin-left: auto;
}

.dt-toolbar .dt-per-page select {
    padding: 6px 8px;
    border: 1px solid var(--border);
    border-radius: 7px;
    font-size: 12px;
    font-family: var(--font);
    background: var(--bg-card);
    color: var(--text);
    outline: none;
    cursor: pointer;
    transition: border-color 0.15s;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%239ca3af' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    padding-right: 24px;
}

.dt-toolbar .dt-per-page select:focus {
    border-color: var(--accent);
}

.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-accent { color: var(--accent-dark); }
.text-success { color: var(--success); }
.text-error { color: var(--error); }
.mt-4 { margin-top: 16px; }
.mb-4 { margin-bottom: 16px; }
.gap-4 { gap: 16px; }
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
