/* =============================================================
 * style.css — Corporate / Empresarial redesign
 * Preserves all classes used by the PHP templates for drop-in use.
 * ============================================================= */

/* ---- 1. Color palette & tokens ---- */
:root {
    /* Primary: professional blue */
    --color-primary: #1a3a6c;
    --color-primary-rgb: 26, 58, 108;
    --color-primary-soft: #e7eef7;
    --color-primary-hover: #132f57;

    /* Accent (kept from existing) */
    --color-accent: #2563eb;
    --color-accent-rgb: 37, 99, 235;
    --color-accent-soft: #dbeafe;

    /* Neutrals */
    --color-surface: #ffffff;
    --color-surface-alt: #f8fafc;
    --color-surface-hover: #f1f5f9;
    --color-border: #e2e8f0;
    --color-border-strong: #cbd5e1;

    --color-text: #0f172a;
    --color-text-secondary: #475569;
    --color-text-tertiary: #94a3b8;

    /* States */
    --color-success: #15803d;
    --color-success-soft: #dcfce7;
    --color-success-border: #86efac;
    --color-warning: #b4520a;
    --color-warning-soft: #fef3c7;
    --color-warning-border: #fdba74;
    --color-danger: #b91c1c;
    --color-danger-soft: #fee2e2;
    --color-danger-border: #fca5a5;
    --color-info: #0369a1;
    --color-info-soft: #e0f2fe;

    /* Sidebar (dark theme preserved) */
    --sidebar-bg: #0f172a;
    --sidebar-text: #e2e8f0;
    --sidebar-muted: #94a3b8;
    --sidebar-active: var(--color-accent);

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 10px 18px -3px rgba(15, 23, 42, 0.10), 0 4px 6px -4px rgba(15, 23, 42, 0.06);
    --shadow-xl: 0 16px 28px -4px rgba(15, 23, 42, 0.12), 0 6px 22px -10px rgba(15, 23, 42, 0.08);

    /* Border radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 14px;
    --radius-xl: 20px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-base: 0.2s ease;
    --transition-slow: 0.3s ease;

    /* Typography */
    --font-base: 'Segoe UI', 'Inter', -apple-system, BlinkMacSystemFont, 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'SFMono-Regular', 'Menlo', 'Monaco', 'Consolas', monospace;
    --font-size-xs: 0.7rem;
    --font-size-sm: 0.825rem;
    --font-size-base: 0.9rem;
    --font-size-md: 1.05rem;
    --font-size-lg: 1.2rem;
    --font-size-xl: 1.5rem;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
}

/* ---- 2. Reset & base ---- */
* { box-sizing: border-box; }
body {
    margin: 0;
    padding: 0;
    font-family: var(--font-base);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-normal);
    background: var(--color-surface-alt);
    color: var(--color-text);
    line-height: 1.5;
}

/* ---- 3. Layout shell ---- */
.app-shell {
    display: flex;
    min-height: 100vh;
    background: var(--color-surface-alt);
}
.main-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--color-surface-alt);
}

/* ---- 4. Sidebar (dark corporate) ---- */
.sidebar {
    width: 260px;
    background: var(--sidebar-bg);
    color: var(--sidebar-text);
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 3px 0 8px rgba(0, 0, 0, 0.04);
}
.sidebar-top {
    padding: 24px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}
.company-logo {
    width: 120px;
    height: 120px;
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 14px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.25);
}
.company-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 6px;
}
.company-name {
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-semibold);
    color: #f8fafc;
    letter-spacing: 0.03em;
}
.sidebar-nav {
    padding: 18px 14px;
    flex: 1;
    overflow-y: auto;
}
.nav-group {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.nav-item a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    border-radius: var(--radius-md);
    text-decoration: none;
    color: var(--sidebar-text);
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-sm);
    transition: var(--transition-base);
}
.nav-item a:hover {
    background: rgba(148, 163, 184, 0.10);
    color: var(--sidebar-text);
    transform: translateX(3px);
}
.nav-item.active a {
    background: var(--sidebar-active);
    color: #fff;
    font-weight: var(--font-weight-semibold);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.30);
}
.nav-icon {
    width: 22px;
    text-align: center;
    font-size: 15px;
    color: var(--sidebar-muted);
    transition: var(--transition-fast);
}
.nav-item.active .nav-icon { color: #fff; }
.sidebar-footer {
    margin-top: auto;
    padding: 16px 18px 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--sidebar-muted);
    font-size: var(--font-size-xs);
    text-align: center;
    letter-spacing: 0.02em;
}

/* ---- 5. Topbar (clean corporate) ---- */
.topbar {
    position: relative;
    z-index: 100;
    height: 70px;
    min-height: 70px;
    background: rgba(255, 255, 255, 0.85);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    backdrop-filter: blur(6px);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}
.topbar .dropdown-menu { z-index: 1000 !important; }
.bread-nav {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    margin: 0 16px;
    flex-wrap: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.bread-nav a {
    color: var(--color-text);
    text-decoration: none;
    font-weight: var(--font-weight-semibold);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.bread-nav a:hover {
    color: var(--color-primary);
    text-decoration: underline;
}
.bread-nav .bread-sep {
    color: var(--color-text-tertiary);
    font-weight: var(--font-weight-bold);
    margin: 0 4px;
}
.bread-nav .bread-env {
    margin-left: auto;
    color: var(--color-text-secondary);
    font-weight: var(--font-weight-medium);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-full);
    padding: 4px 10px;
    font-size: var(--font-size-xs);
    white-space: nowrap;
}
.user-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 8px 14px;
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: var(--transition-fast);
}
.user-badge:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--color-accent);
}
.topbar .dropdown { position: relative; z-index: 1000; }
.avatar {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background: var(--color-primary-soft);
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: var(--font-weight-bold);
    font-size: 14px;
    flex-shrink: 0;
    border: 1px solid var(--color-border);
}
.user-name {
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-sm);
    color: var(--color-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 160px;
}

/* ---- 6. Content & page headers ---- */
.content { padding: 24px; flex: 1; }
.page-header {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
    flex-wrap: wrap;
}
.page-heading {
    margin: 0 0 4px;
    font-size: 1.6rem;
    font-weight: var(--font-weight-semibold);
    color: var(--color-primary);
    letter-spacing: -0.01em;
}
.page-heading-sm {
    margin: 0 0 12px;
    font-size: 1.15rem;
    font-weight: var(--font-weight-semibold);
    color: var(--color-primary);
}
.panel-spaced { margin-top: 24px; }

/* ---- 7. Cards & metrics grid ---- */
.grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 18px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
}
.card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}
.card-small {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.card-border { border: 2px solid var(--color-border-strong); }
.card-body-spaced { padding: 20px 12px; }
.metric-label {
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: var(--font-weight-medium);
}
.metric-value {
    font-size: 28px;
    font-weight: var(--font-weight-bold);
    color: var(--color-text);
    line-height: 1.2;
}
.metric-value-sm {
    font-size: 22px;
    margin-top: 8px;
    font-weight: var(--font-weight-bold);
    color: var(--color-text);
}
.metric-label-sm {
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-medium);
    color: var(--color-text-secondary);
}
.metric-positive {
    color: var(--color-success);
    font-weight: var(--font-weight-semibold);
}
.metric-grid-sm {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.metric-grid-sm .metric-value {
    font-size: 22px;
    margin-top: 8px;
    font-weight: var(--font-weight-bold);
    color: var(--color-text);
}
.metric-grid-sm .metric-label {
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-medium);
    color: var(--color-text-secondary);
}

/* ---- 8. Panels & placeholders ---- */
.panel-large {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
}
.panel-large:hover { box-shadow: var(--shadow-md); }
.placeholder-box {
    min-height: 220px;
    border: 1px dashed var(--color-border);
    background: linear-gradient(135deg, rgba(148, 163, 184, 0.04), rgba(59, 130, 246, 0.02));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-secondary);
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-sm);
    text-align: center;
    padding: 24px;
}

/* ---- 9. Tables ---- */
.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
    font-size: var(--font-size-sm);
    background: var(--color-surface);
}
.table th,
.table td {
    border-bottom: 1px solid var(--color-border);
    padding: 6px 10px;
    text-align: center;
    vertical-align: middle;
}
.table thead th {
    background: var(--color-surface-alt);
    font-weight: var(--font-weight-semibold);
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid var(--color-border-strong);
}
.table tbody tr:hover { background: var(--color-surface-hover); }
.table tbody tr:last-child td { border-bottom: none; }
.table.table-sm th,
.table.table-sm td { padding: 4px 8px; font-size: var(--font-size-xs); }
.table-sm { font-size: var(--font-size-xs); }
.table-sm th,
.table-sm td { padding: 4px 8px; }

/* ---- 10. Attendance matrix ---- */
.attendance-day {
    width: 22px;
    min-width: 22px;
    height: 78px;
    padding: 4px 1px !important;
    text-align: center !important;
    vertical-align: middle !important;
    white-space: nowrap;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    font-size: var(--font-size-xs);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}
.attendance-meta {
    font-size: var(--font-size-xs);
    margin-top: 8px;
    color: var(--color-text-secondary);
}

/* ---- 11. Tags & badges ---- */
.tag {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    background: var(--color-accent-soft);
    color: var(--color-primary);
    white-space: nowrap;
}

/* ---- 12. Form utilities ---- */
.form-spacer { margin-top: 16px; }
.select-constrained { max-width: 200px; }
.th-narrow { width: 30%; }
.data-scope-hidden { display: none; }
.chart-section { margin-top: 10px; }
.alert-detail {
    white-space: pre-wrap;
    font-size: var(--font-size-sm);
}

/* ---- 13. Section icon ---- */
.section-icon {
    font-size: 32px;
    margin-bottom: 8px;
    color: var(--color-primary);
}

/* ---- 14. Sticky sidebar (legacy utility) ---- */
.sticky-sidebar { position: sticky; top: 20px; }

/* ---- 15. Responsive ---- */
@media (max-width: 900px) {
    .sidebar-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        margin-right: 8px;
        color: var(--color-text-secondary);
        padding: 4px;
    }

    .sidebar-toggle .navbar-toggler-icon {
        display: block;
        width: 24px;
        height: 2px;
        background: var(--color-text);
        border-radius: 2px;
        position: relative;
        transition: var(--transition-fast);
    }

    .sidebar-toggle .navbar-toggler-icon,
    .sidebar-toggle .navbar-toggler-icon::before,
    .sidebar-toggle .navbar-toggler-icon::after {
        content: '';
    }

    .sidebar-toggle .navbar-toggler-icon::before,
    .sidebar-toggle .navbar-toggler-icon::after {
        content: '';
        position: absolute;
        width: 24px;
        height: 2px;
        background: var(--color-text);
        border-radius: 2px;
        left: 0;
    }

    .sidebar-toggle .navbar-toggler-icon::before { top: -8px; }
    .sidebar-toggle .navbar-toggler-icon::after  { top: 8px; }

    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.4);
        z-index: 1000;
    }

    .sidebar-overlay.active { display: block; }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        width: 260px;
        max-width: 80vw;
        height: 100vh;
        z-index: 1100;
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 2px 0 12px rgba(0, 0, 0, 0.15);
    }

    .sidebar.active { transform: translateX(0); }
    .company-logo { width: 90px; height: 90px; margin: 0 auto 10px; }

    .main-panel {
        flex: 1;
        min-width: 0;
    }

    .content { padding: 18px; }

    .user-name { display: none; }
    .bread-nav { margin: 0 8px; }
    .topbar { padding: 0 12px; }
}

@media (min-width: 901px) {
    .sidebar-toggle { display: none; }
    .sidebar-overlay { display: none; }
    .sidebar { position: relative !important; transform: none !important; }
}

/* ---- 16. Auth pages (login, recover, reset) ---- */
.auth-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #e7eef7 0%, #f8fafc 50%, #e7eef7 100%);
    padding: 16px;
}

.auth-card {
    width: min(92vw, 420px);
    background: var(--color-surface);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    padding: 40px 32px 32px;
    text-align: center;
}

.auth-logo {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.auth-logo img {
    max-width: 80%;
    height: auto;
    object-fit: contain;
}

.auth-title {
    font-size: 1.8rem;
    font-weight: var(--font-weight-bold);
    color: var(--color-primary);
    margin: 0 0 6px;
    letter-spacing: -0.01em;
}

.auth-subtitle {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    margin: 0 0 28px;
    line-height: 1.5;
}

.auth-form .form-label {
    display: block;
    text-align: left;
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    color: var(--color-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 6px;
}

.auth-form .form-control {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    font-size: var(--font-size-sm);
    background: var(--color-surface);
    color: var(--color-text);
    transition: var(--transition-fast);
}

.auth-form .form-control:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(26, 58, 108, 0.10);
}

.auth-form .form-control::placeholder {
    color: var(--color-text-tertiary);
}

.auth-form .btn-submit {
    width: 100%;
    padding: 12px;
    margin-top: 4px;
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 24px 0;
    color: var(--color-text-tertiary);
    font-size: var(--font-size-xs);
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-top: 1px solid var(--color-border);
}

.auth-divider span {
    padding: 0 14px;
}

.auth-footer {
    margin-top: 16px;
    font-size: var(--font-size-sm);
}

.auth-footer a {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: var(--font-weight-medium);
}

.auth-footer a:hover {
    text-decoration: underline;
}

.auth-error {
    background: var(--color-danger-soft);
    border: 1px solid var(--color-danger-border);
    color: var(--color-danger);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    font-size: var(--font-size-sm);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-success {
    background: var(--color-success-soft);
    border: 1px solid var(--color-success-border);
    color: var(--color-success);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    font-size: var(--font-size-sm);
    margin-bottom: 20px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--color-text-tertiary);
    cursor: pointer;
    padding: 4px;
    font-size: var(--font-size-sm);
    transition: var(--transition-fast);
}

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

.input-group-password {
    position: relative;
}

@media (max-width: 900px) {
    .auth-card {
        padding: 32px 24px 28px;
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow-md);
    }
    .auth-logo {
        width: 84px;
        height: 84px;
    }
    .auth-title {
        font-size: 1.5rem;
    }
}

/* ---- 17. Dashboard enhancements ---- */
.dashboard-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 14px;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
}

.stat-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.stat-card .stat-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    background: var(--color-primary-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--color-primary);
    flex-shrink: 0;
}

.stat-card .stat-content {
    flex: 1;
    min-width: 0;
}

.stat-card .stat-value {
    font-size: 22px;
    font-weight: var(--font-weight-bold);
    color: var(--color-text);
    line-height: 1.2;
}

.stat-card .stat-label {
    font-size: var(--font-size-xs);
    color: var(--color-text-secondary);
    font-weight: var(--font-weight-medium);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stat-card .stat-icon.records { background: rgba(37, 99, 235, 0.10); color: var(--color-accent); }
.stat-card .stat-icon.companies { background: rgba(16, 185, 129, 0.10); color: var(--color-success); }
.stat-card .stat-icon.plants { background: rgba(14, 172, 222, 0.10); color: var(--color-info); }
.stat-card .stat-icon.personal { background: rgba(124, 56, 237, 0.10); color: #7c3aed; }
.stat-card .stat-icon.admins { background: rgba(245, 158, 6, 0.12); color: var(--color-warning); }
.stat-card .stat-icon.users { background: rgba(168, 82, 82, 0.10); color: var(--color-danger); }

.chart-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
}

.chart-card:hover { box-shadow: var(--shadow-md); }

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

.chart-card .chart-header .label {
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: var(--font-weight-medium);
}

.chart-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.chart-filters .form-select {
    min-width: 90px;
    padding: 6px 10px;
    font-size: var(--font-size-xs);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-surface);
    transition: var(--transition-fast);
}

.chart-filters .form-select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(26, 58, 108, 0.08);
}

.chart-wrapper {
    position: relative;
    min-height: 180px;
}

.chart-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 150px;
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
    text-align: center;
    padding: 20px;
}

.dashboard-section {
    margin-top: 24px;
}

.dashboard-section .section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.1rem;
    font-weight: var(--font-weight-semibold);
    color: var(--color-primary);
    margin-bottom: 14px;
}

.dashboard-section .section-title .section-icon {
    font-size: 22px;
    margin-bottom: 0;
    color: var(--color-primary);
}

.activity-table th {
    background: var(--color-surface-alt);
    font-weight: var(--font-weight-semibold);
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 2px solid var(--color-border-strong);
}

.activity-table tbody tr:hover { background: var(--color-surface-hover); }

.activity-table .action-tag {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    background: var(--color-accent-soft);
    color: var(--color-primary);
}

.activity-table .event-user {
    font-weight: var(--font-weight-medium);
    color: var(--color-text);
}

.activity-table .event-time {
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
}

.impersonate-table th {
    background: var(--color-surface-alt);
    font-weight: var(--font-weight-semibold);
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 2px solid var(--color-border-strong);
}

.impersonate-row td {
    vertical-align: middle;
}

.impersonate-row .admin-name {
    font-weight: var(--font-weight-semibold);
    color: var(--color-text);
}

.impersonate-row .admin-email {
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
}

.impersonate-row .company-list {
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
}

.btn-impersonate {
    padding: 6px 14px;
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-medium);
    border-radius: var(--radius-sm);
}
