:root {
    --bg-main: #0b0f19;
    --bg-surface: #111827;
    --bg-card: #161f30;
    --bg-input: #1f293d;
    --border-color: #26334d;
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    
    --accent-blue: #2563eb;
    --accent-blue-hover: #1d4ed8;
    --accent-blue-light: rgba(37, 99, 235, 0.15);
    
    --accent-green: #10b981;
    --accent-green-light: rgba(16, 185, 129, 0.15);
    
    --accent-orange: #f59e0b;
    --accent-orange-light: rgba(245, 158, 11, 0.15);
    
    --accent-purple: #8b5cf6;
    --accent-purple-light: rgba(139, 92, 246, 0.15);
    
    --accent-teal: #06b6d4;
    --accent-teal-light: rgba(6, 182, 212, 0.15);
    
    --accent-red: #ef4444;
    --accent-red-light: rgba(239, 68, 68, 0.15);
    
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --shadow-card: 0 4px 20px -2px rgba(0, 0, 0, 0.4);
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
    --bg-main: #f8fafc;
    --bg-surface: #ffffff;
    --bg-card: #ffffff;
    --bg-input: #f1f5f9;
    --border-color: #e2e8f0;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --shadow-card: 0 4px 16px -2px rgba(0, 0, 0, 0.06);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
}

/* LOGIN SCREEN */
.login-screen {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 50% 20%, #172554 0%, #0b0f19 80%);
    z-index: 9999;
    padding: 20px;
    overflow: hidden;
}

[data-theme="light"] .login-screen {
    background: radial-gradient(circle at 50% 20%, #dbeafe 0%, #f8fafc 80%);
}

.login-background-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    opacity: 0.4;
    animation: floatGlow 8s ease-in-out infinite alternate;
}

.glow-1 {
    width: 400px;
    height: 400px;
    background: #2563eb;
    top: 10%;
    left: 20%;
}

.glow-2 {
    width: 350px;
    height: 350px;
    background: #7c3aed;
    bottom: 10%;
    right: 20%;
    animation-delay: -4s;
}

@keyframes floatGlow {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(40px) scale(1.1); }
}

.login-card {
    position: relative;
    width: 100%;
    max-width: 440px;
    background: rgba(17, 24, 39, 0.85);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: 36px 32px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    z-index: 10;
    animation: loginFadeIn 0.35s ease-out;
}

[data-theme="light"] .login-card {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

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

.login-header {
    text-align: center;
    margin-bottom: 28px;
}

.login-logo-icon {
    width: 58px;
    height: 58px;
    background: linear-gradient(135deg, #1f93ff, #0066cc);
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    margin-bottom: 16px;
    box-shadow: 0 8px 24px rgba(31, 147, 255, 0.4);
}

.login-header h2 {
    font-size: 24px;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
}

.login-header p {
    font-size: 13px;
    color: var(--text-secondary);
}

.login-alert {
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 20px;
    background: var(--accent-red-light);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
    animation: shake 0.3s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-icon .input-icon {
    position: absolute;
    left: 12px;
    color: var(--text-muted);
    pointer-events: none;
}

.input-with-icon .form-control {
    padding-left: 40px;
    padding-right: 40px;
    height: 44px;
    font-size: 14px;
}

.password-toggle-btn {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    transition: var(--transition);
}

.password-toggle-btn:hover {
    color: var(--text-primary);
}

.btn-block {
    width: 100%;
    height: 44px;
    font-size: 14px;
    justify-content: center;
    margin-top: 8px;
}

.btn-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.login-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 24px;
    font-size: 12px;
    color: var(--text-muted);
}

/* APP LAYOUT & SIDEBAR */
.app-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 270px;
    background: var(--bg-surface);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    z-index: 100;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 24px 20px;
    border-bottom: 1px solid var(--border-color);
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #1f93ff, #0066cc);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 12px rgba(31, 147, 255, 0.35);
}

.logo-text h2 {
    font-size: 18px;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    letter-spacing: -0.5px;
}

.logo-text span {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 600;
}

.nav-menu {
    flex: 1;
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 13.5px;
    font-weight: 500;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    width: 100%;
}

.nav-item:hover {
    background: var(--bg-input);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--accent-blue);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.sidebar-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
}

.db-status-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 500;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.connected {
    background-color: var(--accent-green);
    box-shadow: 0 0 8px var(--accent-green);
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--bg-main);
}

.top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 32px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-surface);
    gap: 16px;
    flex-wrap: wrap;
}

.header-title h1 {
    font-size: 22px;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
}

.header-title p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* User Profile Badge */
.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px 6px 6px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: 30px;
}

.user-avatar {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

.user-info {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
}

.user-role-tag {
    font-size: 10px;
    font-weight: 600;
    color: #60a5fa;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.btn-logout {
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.3);
}

.btn-logout:hover {
    background: var(--accent-red-light);
    color: #ef4444;
    border-color: #ef4444;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-primary {
    background: var(--accent-blue);
    color: #fff;
}
.btn-primary:hover {
    background: var(--accent-blue-hover);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-secondary {
    background: var(--bg-input);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}
.btn-secondary:hover {
    background: var(--border-color);
}

.btn-outline {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}
.btn-outline:hover {
    background: var(--bg-input);
    color: var(--text-primary);
}

.btn-success {
    background: #059669;
    color: #fff;
}
.btn-success:hover {
    background: #047857;
}

.theme-toggle-btn {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 38px;
    height: 38px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.theme-toggle-btn:hover {
    color: var(--text-primary);
}

[data-theme="dark"] .sun-icon { display: block; }
[data-theme="dark"] .moon-icon { display: none; }
[data-theme="light"] .sun-icon { display: none; }
[data-theme="light"] .moon-icon { display: block; }

/* Filter Section */
.filter-section {
    padding: 20px 32px 0;
}

.filter-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    box-shadow: var(--shadow-card);
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    min-width: 130px;
}

.filter-group label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.form-control {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 9px 12px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    outline: none;
    transition: var(--transition);
    width: 100%;
}

.form-control:focus {
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
}

.filter-actions-col {
    flex: 0;
    min-width: auto;
}

/* Tab Pane System */
.tab-pane {
    display: none;
    padding: 24px 32px 32px;
}

.tab-pane.active {
    display: block;
    animation: fadeIn 0.25s ease-out;
}

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

/* Subtabs bar */
.subtabs-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.subtab-btn {
    padding: 10px 20px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
}

.subtab-btn.active {
    background: var(--accent-blue);
    color: #fff;
    border-color: var(--accent-blue);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.subtab-pane {
    display: none;
}

.subtab-pane.active {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

/* KPI Grid */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.kpi-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    box-shadow: var(--shadow-card);
    transition: var(--transition);
}

.kpi-card:hover {
    transform: translateY(-2px);
}

.kpi-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.kpi-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.kpi-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.kpi-icon.blue { background: var(--accent-blue-light); color: var(--accent-blue); }
.kpi-icon.green { background: var(--accent-green-light); color: var(--accent-green); }
.kpi-icon.orange { background: var(--accent-orange-light); color: var(--accent-orange); }
.kpi-icon.purple { background: var(--accent-purple-light); color: var(--accent-purple); }
.kpi-icon.teal { background: var(--accent-teal-light); color: var(--accent-teal); }

.kpi-value {
    font-size: 26px;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.kpi-footer {
    font-size: 12px;
    color: var(--text-muted);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 600;
    border-radius: 20px;
}

.badge.blue { background: var(--accent-blue-light); color: #60a5fa; }
.badge.green { background: var(--accent-green-light); color: #34d399; }
.badge.orange { background: var(--accent-orange-light); color: #fbbf24; }
.badge.purple { background: var(--accent-purple-light); color: #a78bfa; }
.badge.red { background: var(--accent-red-light); color: #f87171; }

.status-badge-resolvido { background: var(--accent-green-light); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.3); }
.status-badge-aberto { background: var(--accent-blue-light); color: #60a5fa; border: 1px solid rgba(37, 99, 235, 0.3); }
.status-badge-pendente { background: var(--accent-orange-light); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.3); }
.status-badge-adiado { background: var(--accent-purple-light); color: #a78bfa; border: 1px solid rgba(139, 92, 246, 0.3); }

/* Tag Pills */
.tag-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
}

.tag-color-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--bg-input);
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
}

.rank-badge.top-1 { background: #f59e0b; color: #000; }
.rank-badge.top-2 { background: #94a3b8; color: #000; }
.rank-badge.top-3 { background: #d97706; color: #fff; }

/* Charts */
.charts-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

.chart-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    box-shadow: var(--shadow-card);
}

.chart-header {
    margin-bottom: 16px;
}

.chart-header h3 {
    font-size: 16px;
    font-weight: 600;
}

.chart-subtitle {
    font-size: 12px;
    color: var(--text-muted);
}

.chart-body {
    position: relative;
    height: 280px;
}

/* Card */
.card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-card);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.card-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.card-header p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* Tables */
.table-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    overflow: hidden;
}

.table-header-bar {
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    flex-wrap: wrap;
    gap: 12px;
}

.table-search-box {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    width: 360px;
    max-width: 100%;
}

.table-search-box input {
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-size: 13px;
    width: 100%;
}

.table-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.table-count-badge {
    font-size: 12px;
    color: var(--text-secondary);
    padding-right: 8px;
}

.table-responsive {
    overflow-x: auto;
    width: 100%;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    text-align: left;
    white-space: nowrap;
}

.data-table th {
    background: var(--bg-input);
    color: var(--text-secondary);
    font-weight: 600;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

.table-empty-state {
    text-align: center;
    padding: 48px !important;
    color: var(--text-muted);
}

.ticket-tag {
    font-weight: 600;
    color: var(--accent-blue);
}

.phone-tag {
    font-family: 'Courier New', monospace;
    font-size: 12px;
    font-weight: 600;
    color: #38bdf8;
}

/* Pagination */
.pagination-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
    border-top: 1px solid var(--border-color);
    font-size: 13px;
    color: var(--text-secondary);
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pagination-page-label {
    font-weight: 600;
    color: var(--text-primary);
}

/* ====================================================
   HEATMAP MATRIX 24X7
   ==================================================== */
.heatmap-container {
    overflow-x: auto;
    padding: 10px 0;
}

.heatmap-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 4px;
}

.heatmap-table th {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-align: center;
    padding: 6px 4px;
}

.heatmap-table td.day-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    text-align: right;
    padding-right: 12px;
    white-space: nowrap;
}

.heatmap-cell {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
    text-align: center;
    vertical-align: middle;
    font-size: 11px;
    font-weight: 600;
}

.heatmap-cell:hover {
    transform: scale(1.15);
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* Heatmap intensity color steps */
.heatmap-cell.lvl-0 { background: rgba(255, 255, 255, 0.03); color: transparent; }
.heatmap-cell.lvl-1 { background: rgba(37, 99, 235, 0.25); color: #93c5fd; }
.heatmap-cell.lvl-2 { background: rgba(37, 99, 235, 0.55); color: #ffffff; }
.heatmap-cell.lvl-3 { background: rgba(37, 99, 235, 0.85); color: #ffffff; }
.heatmap-cell.lvl-4 { background: #3b82f6; color: #ffffff; box-shadow: 0 0 10px rgba(59, 130, 246, 0.5); }

[data-theme="light"] .heatmap-cell.lvl-0 { background: #f1f5f9; color: transparent; }
[data-theme="light"] .heatmap-cell.lvl-1 { background: #dbeafe; color: #1e40af; }
[data-theme="light"] .heatmap-cell.lvl-2 { background: #93c5fd; color: #1e3a8a; }
[data-theme="light"] .heatmap-cell.lvl-3 { background: #3b82f6; color: #ffffff; }
[data-theme="light"] .heatmap-cell.lvl-4 { background: #1d4ed8; color: #ffffff; }

.heatmap-legend {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
    font-size: 12px;
    color: var(--text-secondary);
}

.legend-scale {
    display: flex;
    gap: 4px;
}

.scale-box {
    width: 16px;
    height: 16px;
    border-radius: 3px;
}

.heatmap-loading {
    text-align: center;
    padding: 30px;
    color: var(--text-muted);
}

/* Print Styles */
@media print {
    .sidebar, .top-header, .filter-section, .table-header-bar, .pagination-bar, .login-screen, .subtabs-bar {
        display: none !important;
    }
    body, .main-content {
        background: #fff !important;
        color: #000 !important;
    }
    .table-card {
        border: none !important;
        box-shadow: none !important;
    }
    .data-table th, .data-table td {
        color: #000 !important;
        border-color: #ddd !important;
    }
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .charts-grid {
        grid-template-columns: 1fr;
    }
    .app-layout {
        flex-direction: column;
    }
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
}

/* ====================================================
   SETTINGS PANE & SWITCH TOGGLE
   ==================================================== */
.switch-control {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: var(--bg-input);
    border: 1px solid var(--border-color);
    transition: .3s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: #fff;
    transition: .3s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--accent-green);
    border-color: var(--accent-green);
}

input:checked + .slider:before {
    transform: translateX(20px);
}

.switch-label {
    font-size: 12px;
    font-weight: 600;
}

.switch-label.active {
    color: #34d399;
}

.switch-label.disabled {
    color: #f87171;
}

.agent-row-disabled {
    opacity: 0.55;
    background: rgba(239, 68, 68, 0.03);
}

.agent-info-cell {
    display: flex;
    align-items: center;
    gap: 10px;
}

.agent-avatar-sm {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

