/* ============================================================
   Escalante City SWDO Data Archiving Information System
   Light Theme — Orange Accent — Compact UI
   ============================================================ */

/* ---- Google Font Import ---- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ---- CSS Variables / Design Tokens ---- */
:root {
    /* Orange Palette */
    --orange-50: #fff7ed;
    --orange-100: #ffedd5;
    --orange-200: #fed7aa;
    --orange-300: #fdba74;
    --orange-400: #fb923c;
    --orange-500: #f97316;
    --orange-600: #ea580c;
    --orange-700: #c2410c;
    --orange-800: #9a3412;
    --orange-900: #7c2d12;

    --primary: #f97316;
    --primary-dark: #ea580c;
    --primary-light: #fb923c;
    --primary-lighter: #fff7ed;
    --primary-gradient: linear-gradient(135deg, #f97316 0%, #fb923c 50%, #fdba74 100%);
    --primary-gradient-bold: linear-gradient(135deg, #ea580c 0%, #f97316 100%);

    --secondary: #1e293b;
    --secondary-light: #334155;

    --accent: #0ea5e9;
    --accent-light: #38bdf8;

    --success: #22c55e;
    --success-light: #4ade80;
    --success-bg: #f0fdf4;
    --warning: #eab308;
    --warning-light: #facc15;
    --warning-bg: #fefce8;
    --danger: #ef4444;
    --danger-light: #f87171;
    --danger-bg: #fef2f2;
    --info: #3b82f6;
    --info-bg: #eff6ff;

    /* Backgrounds */
    --bg-body: #f8fafc;
    --bg-white: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #fffbf5;
    --bg-input: #ffffff;
    --bg-sidebar: #1e293b;
    --bg-sidebar-hover: #334155;

    /* Text */
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --text-light: #cbd5e1;
    --text-white: #ffffff;
    --text-orange: #ea580c;

    /* Borders */
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;
    --border-orange: #fed7aa;

    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -1px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);
    --shadow-orange: 0 4px 14px rgba(249, 115, 22, 0.2);
    --shadow-card-hover: 0 8px 25px rgba(0, 0, 0, 0.08);

    /* Radius */
    --radius-xs: 4px;
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 50px;

    /* Layout Dimensions */
    --sidebar-width: 250px;
    --header-height: 56px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s ease;
    --transition-slow: 0.4s ease;
}

/* ---- Reset & Base ---- */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-body);
    color: var(--text-primary);
    margin: 0;
    padding: 0;
    font-size: 13px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: var(--primary);
    transition: color var(--transition-fast);
}
a:hover {
    color: var(--primary-dark);
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: var(--bg-body); }
::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ============================================================
   LOGIN PAGE
   ============================================================ */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #fff7ed 0%, #ffffff 40%, #f8fafc 100%);
    position: relative;
    overflow: hidden;
}

.login-page::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    animation: loginFloat 20s ease-in-out infinite;
}

.login-page::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -15%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.05) 0%, transparent 70%);
    border-radius: 50%;
    animation: loginFloat 15s ease-in-out infinite reverse;
}

@keyframes loginFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(20px, -20px) scale(1.05); }
}

.login-container {
    width: 100%;
    max-width: 400px;
    margin: 1rem;
    position: relative;
    z-index: 1;
}

.login-card {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 2.5rem 2rem;
    box-shadow: var(--shadow-xl);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}
.login-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl), var(--shadow-orange);
}

.login-logo {
    text-align: center;
    margin-bottom: 1.75rem;
}
.login-logo .logo-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-gradient);
    border-radius: var(--radius-lg);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: white;
    margin-bottom: 0.75rem;
    box-shadow: var(--shadow-orange);
}
.login-logo h1 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 0.2rem;
    line-height: 1.4;
}
.login-logo p {
    color: var(--text-secondary);
    font-size: 0.75rem;
    margin: 0;
}

.login-card .form-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.3rem;
}

.login-card .form-control {
    background: var(--bg-white);
    border: 1.5px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.6rem 0.85rem;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.login-card .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
    outline: none;
}
.login-card .form-control::placeholder {
    color: var(--text-muted);
    font-size: 0.78rem;
}

.login-card .input-group-text {
    background: var(--bg-body);
    border: 1.5px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.95rem;
    padding: 0.6rem 0.75rem;
}

.btn-login {
    background: var(--primary-gradient-bold);
    border: none;
    padding: 0.7rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    color: white;
    width: 100%;
    cursor: pointer;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}
.btn-login:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-orange);
    color: white;
}
.btn-login:active {
    transform: translateY(0);
}

/* ============================================================
   LAYOUT: SIDEBAR + CONTENT
   ============================================================ */
.app-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ---- Sidebar ---- */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-normal);
    overflow: hidden;
}

.sidebar-brand {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    display: flex;
    align-items: center;
    gap: 0.6rem;
    min-height: var(--header-height);
}
.sidebar-brand .brand-icon {
    width: 34px;
    height: 34px;
    background: var(--primary-gradient);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    flex-shrink: 0;
}
.sidebar-brand .brand-text {
    font-weight: 700;
    font-size: 0.78rem;
    color: var(--text-white);
    line-height: 1.3;
    white-space: nowrap;
}
.sidebar-brand .brand-text small {
    display: block;
    font-weight: 400;
    font-size: 0.62rem;
    color: var(--text-muted);
    opacity: 0.7;
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 0.6rem 0;
}

.nav-section-title {
    padding: 0.6rem 1rem 0.3rem;
    font-size: 0.58rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: rgba(148, 163, 184, 0.5);
}

.nav-item {
    padding: 0 0.5rem;
    margin-bottom: 1px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 0.65rem;
    border-radius: var(--radius-sm);
    color: rgba(203, 213, 225, 0.8);
    font-size: 0.78rem;
    font-weight: 500;
    transition: all var(--transition-fast);
    white-space: nowrap;
}
.nav-link i {
    font-size: 0.95rem;
    width: 18px;
    text-align: center;
    flex-shrink: 0;
    opacity: 0.7;
}
.nav-link:hover {
    background: rgba(249, 115, 22, 0.1);
    color: var(--orange-300);
}
.nav-link:hover i {
    opacity: 1;
}
.nav-link.active {
    background: rgba(249, 115, 22, 0.15);
    color: var(--orange-400);
    font-weight: 600;
}
.nav-link.active i {
    color: var(--orange-400);
    opacity: 1;
}

.sidebar-footer {
    padding: 0.65rem 1rem;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.sidebar-user {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.sidebar-user .user-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--primary-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.7rem;
    color: white;
    flex-shrink: 0;
}
.sidebar-user .user-name {
    font-weight: 600;
    font-size: 0.72rem;
    color: var(--text-white);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.sidebar-user .user-role {
    font-size: 0.6rem;
    color: var(--orange-400);
    font-weight: 500;
}

/* ---- Main Content ---- */
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--bg-body);
    transition: margin-left var(--transition-normal);
}

/* ---- Top Header ---- */
.top-header {
    height: var(--header-height);
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 0 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 500;
    box-shadow: var(--shadow-xs);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sidebar-toggle {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.15rem;
    cursor: pointer;
    padding: 0.2rem;
    display: none;
    transition: color var(--transition-fast);
    border-radius: var(--radius-xs);
}
.sidebar-toggle:hover { color: var(--primary); }

.page-title-header h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
}
.page-title-header p {
    margin: 0;
    font-size: 0.68rem;
    color: var(--text-muted);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header-btn {
    background: var(--bg-body);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    transition: all var(--transition-fast);
    font-size: 0.9rem;
}
.header-btn:hover {
    background: var(--primary-lighter);
    color: var(--primary);
    border-color: var(--border-orange);
}
.header-btn .badge {
    position: absolute;
    top: -3px;
    right: -3px;
    font-size: 0.55rem;
    padding: 1px 5px;
    background: var(--primary);
    border-radius: 10px;
    color: white;
    font-weight: 700;
}

/* ---- Content Area ---- */
.content-area {
    flex: 1;
    padding: 1.25rem;
}

/* ---- Page Header ---- */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    gap: 0.75rem;
}
.page-header h2 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0;
    color: var(--text-primary);
}
.page-header h2 i {
    color: var(--primary) !important;
}

/* ============================================================
   STAT CARDS
   ============================================================ */
.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1rem 1.15rem;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    cursor: default;
}
.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-card-hover);
    border-color: var(--border-orange);
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2.5px;
}
.stat-card.primary::before { background: var(--primary-gradient); }
.stat-card.success::before { background: linear-gradient(135deg, #22c55e, #4ade80); }
.stat-card.warning::before { background: linear-gradient(135deg, #eab308, #facc15); }
.stat-card.danger::before { background: linear-gradient(135deg, #ef4444, #f87171); }
.stat-card.info::before { background: linear-gradient(135deg, #0ea5e9, #38bdf8); }
.stat-card.secondary::before { background: linear-gradient(135deg, #6366f1, #818cf8); }

.stat-card .stat-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    margin-bottom: 0.65rem;
}
.stat-card.primary .stat-icon { background: var(--orange-50); color: var(--primary); }
.stat-card.success .stat-icon { background: var(--success-bg); color: var(--success); }
.stat-card.warning .stat-icon { background: var(--warning-bg); color: var(--warning); }
.stat-card.danger .stat-icon { background: var(--danger-bg); color: var(--danger); }
.stat-card.info .stat-icon { background: var(--info-bg); color: var(--accent); }
.stat-card.secondary .stat-icon { background: #eef2ff; color: #6366f1; }

.stat-card .stat-number {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
    margin-bottom: 0.15rem;
}
.stat-card .stat-label {
    font-size: 0.68rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* ============================================================
   DATA CARDS / PANELS
   ============================================================ */
.data-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 1.25rem;
    box-shadow: var(--shadow-xs);
    transition: box-shadow var(--transition-normal);
}
.data-card:hover {
    box-shadow: var(--shadow-sm);
}
.data-card-header {
    padding: 0.85rem 1.15rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg-body);
}
.data-card-header h5 {
    margin: 0;
    font-weight: 700;
    font-size: 0.82rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.data-card-header h5 i {
    color: var(--primary);
    font-size: 0.9rem;
}
.data-card-body {
    padding: 1.15rem;
}
.data-card-body.no-padding {
    padding: 0;
}

/* ============================================================
   TABLES
   ============================================================ */
.table-dark-custom {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}
.table-dark-custom thead th {
    background: var(--bg-body);
    border-bottom: 1px solid var(--border-color);
    padding: 0.55rem 0.85rem;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    white-space: nowrap;
    position: sticky;
    top: 0;
}
.table-dark-custom tbody td {
    padding: 0.55rem 0.85rem;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-primary);
    font-size: 0.78rem;
    vertical-align: middle;
}
.table-dark-custom tbody tr {
    transition: background var(--transition-fast);
}
.table-dark-custom tbody tr:hover {
    background: var(--orange-50);
}
.table-dark-custom tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================================
   STATUS BADGES
   ============================================================ */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.2px;
    text-transform: uppercase;
}
.status-badge.active { background: var(--success-bg); color: #15803d; }
.status-badge.inactive { background: var(--warning-bg); color: #a16207; }
.status-badge.closed { background: var(--danger-bg); color: #b91c1c; }
.status-badge.archived { background: #eef2ff; color: #4338ca; }
.status-badge.review { background: #ecfeff; color: #0e7490; }
.status-badge.primary { background: var(--orange-50); color: var(--orange-700); }
.status-badge.danger { background: var(--danger-bg); color: #b91c1c; }

/* ============================================================
   BUTTONS — COMPACT
   ============================================================ */
.btn-primary-custom {
    background: var(--primary-gradient-bold);
    border: none;
    color: white;
    padding: 0.5rem 1.15rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.85rem;
    transition: all var(--transition-normal);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    white-space: nowrap;
}
.btn-primary-custom:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-orange);
    color: white;
}
.btn-primary-custom:active {
    transform: translateY(0);
}

.btn-outline-custom {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 0.5rem 1.15rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    font-size: 0.85rem;
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    white-space: nowrap;
}
.btn-outline-custom:hover {
    background: var(--orange-50);
    border-color: var(--border-orange);
    color: var(--primary);
}

.btn-sm-action {
    width: 26px;
    height: 26px;
    border-radius: var(--radius-xs);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
    background: var(--bg-white);
    color: var(--text-muted);
    transition: all var(--transition-fast);
    font-size: 0.7rem;
    cursor: pointer;
}
.btn-sm-action:hover {
    border-color: var(--border-orange);
    color: var(--primary);
    background: var(--orange-50);
    transform: scale(1.08);
}
.btn-sm-action.edit:hover { background: var(--info-bg); color: var(--info); border-color: #bfdbfe; }
.btn-sm-action.delete:hover { background: var(--danger-bg); color: var(--danger); border-color: #fecaca; }
.btn-sm-action.view:hover { background: var(--success-bg); color: var(--success); border-color: #bbf7d0; }

/* ============================================================
   FORMS — COMPACT
   ============================================================ */
.form-control, .form-select {
    background: var(--bg-white) !important;
    border: 1.5px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    padding: 0.55rem 0.85rem !important;
    border-radius: var(--radius-sm) !important;
    font-size: 0.88rem !important;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast) !important;
    height: auto !important;
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.08) !important;
    outline: none !important;
}
.form-control::placeholder { color: var(--text-muted) !important; font-size: 0.75rem !important; }

.form-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.3rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

textarea.form-control {
    min-height: 60px !important;
}

.form-check-input {
    width: 14px;
    height: 14px;
    border: 1.5px solid var(--border-color);
    border-radius: 3px;
}
.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}
.form-check-input:focus {
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.08);
}
.form-check-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* ============================================================
   MODALS
   ============================================================ */
.modal-content {
    background: var(--bg-white) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: var(--radius-lg) !important;
    box-shadow: var(--shadow-xl) !important;
}
.modal-header {
    border-bottom: 1px solid var(--border-color) !important;
    padding: 0.85rem 1.15rem !important;
}
.modal-header .modal-title {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.88rem;
}
.modal-header .modal-title i {
    color: var(--primary);
}
.modal-header .btn-close {
    font-size: 0.6rem;
    opacity: 0.5;
}
.modal-body {
    padding: 1.15rem !important;
}
.modal-footer {
    border-top: 1px solid var(--border-color) !important;
    padding: 0.75rem 1.15rem !important;
}

/* ============================================================
   ALERTS
   ============================================================ */
.alert-custom {
    border-radius: var(--radius-md);
    padding: 0.55rem 1rem;
    font-size: 0.78rem;
    border: none;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 500;
}
.alert-custom.success {
    background: var(--success-bg);
    color: #15803d;
    border-left: 3px solid var(--success);
}
.alert-custom.error {
    background: var(--danger-bg);
    color: #b91c1c;
    border-left: 3px solid var(--danger);
}
.alert-custom.warning {
    background: var(--warning-bg);
    color: #a16207;
    border-left: 3px solid var(--warning);
}
.alert-custom.info {
    background: var(--info-bg);
    color: #1d4ed8;
    border-left: 3px solid var(--info);
}

/* ============================================================
   ACTIVITY / TIMELINE
   ============================================================ */
.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-light);
}
.activity-item:last-child { border-bottom: none; }
.activity-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    flex-shrink: 0;
}
.activity-icon.login { background: var(--info-bg); color: var(--info); }
.activity-icon.create { background: var(--success-bg); color: var(--success); }
.activity-icon.update { background: var(--orange-50); color: var(--primary); }
.activity-icon.delete { background: var(--danger-bg); color: var(--danger); }
.activity-icon.logout { background: var(--bg-body); color: var(--text-muted); }
.activity-icon.login_failed { background: var(--danger-bg); color: var(--danger); }
.activity-content .activity-text {
    font-size: 0.72rem;
    color: var(--text-primary);
    line-height: 1.4;
}
.activity-content .activity-time {
    font-size: 0.62rem;
    color: var(--text-muted);
    margin-top: 1px;
}

/* ============================================================
   PAGINATION
   ============================================================ */
.custom-pagination .page-link {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.7rem;
    padding: 0.25rem 0.55rem;
    transition: all var(--transition-fast);
    font-weight: 500;
}
.custom-pagination .page-link:hover {
    background: var(--orange-50);
    border-color: var(--border-orange);
    color: var(--primary);
}
.custom-pagination .page-item.active .page-link {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    box-shadow: var(--shadow-orange);
}
.custom-pagination .page-item.disabled .page-link {
    background: var(--bg-body);
    border-color: var(--border-color);
    color: var(--text-muted);
}

/* ============================================================
   DETAIL ITEMS
   ============================================================ */
.detail-item {
    margin-bottom: 0.75rem;
}
.detail-item .detail-label {
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 0.1rem;
    font-weight: 600;
}
.detail-item .detail-value {
    font-size: 0.82rem;
    color: var(--text-primary);
    font-weight: 500;
}

/* ============================================================
   SEARCH BOX
   ============================================================ */
.search-box {
    position: relative;
}
.search-box input {
    padding-left: 2rem !important;
}
.search-box .search-icon {
    position: absolute;
    left: 0.65rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.75rem;
    z-index: 5;
}

/* ============================================================
   FILTER BAR
   ============================================================ */
.filter-bar {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 0.85rem 1rem;
    margin-bottom: 1.25rem;
    box-shadow: var(--shadow-xs);
}

/* ============================================================
   EMPTY STATE
   ============================================================ */
.empty-state {
    text-align: center;
    padding: 2.5rem 1.25rem;
}
.empty-state i {
    font-size: 2.5rem;
    color: var(--orange-200);
    margin-bottom: 0.75rem;
}
.empty-state h5 {
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 0.3rem;
    font-size: 0.88rem;
}
.empty-state p {
    color: var(--text-muted);
    font-size: 0.75rem;
}

/* ============================================================
   NOTIFICATIONS
   ============================================================ */
.notification-dropdown {
    width: 320px;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    max-height: 360px;
    overflow-y: auto;
}
.notification-dropdown .dropdown-header {
    padding: 0.6rem 0.85rem;
    border-bottom: 1px solid var(--border-color);
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.75rem;
    background: var(--bg-body);
}
.notification-item {
    padding: 0.55rem 0.85rem;
    border-bottom: 1px solid var(--border-light);
    transition: background var(--transition-fast);
    cursor: pointer;
}
.notification-item:hover {
    background: var(--orange-50);
}
.notification-item.unread {
    border-left: 3px solid var(--primary);
    background: var(--orange-50);
}
.notification-item .notif-title {
    font-weight: 600;
    font-size: 0.72rem;
    color: var(--text-primary);
}
.notification-item .notif-message {
    font-size: 0.65rem;
    color: var(--text-secondary);
    margin-top: 1px;
}
.notification-item .notif-time {
    font-size: 0.58rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ============================================================
   CHARTS
   ============================================================ */
.chart-container {
    position: relative;
    width: 100%;
    height: 240px;
}

/* ============================================================
   TAGS
   ============================================================ */
.tag {
    display: inline-block;
    padding: 1px 7px;
    border-radius: var(--radius-full);
    font-size: 0.62rem;
    font-weight: 600;
    background: var(--orange-50);
    color: var(--orange-700);
    margin: 1px;
    border: 1px solid var(--orange-100);
}

/* ============================================================
   PULSE DOT
   ============================================================ */
.pulse-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
    animation: pulse 2s infinite;
}
.pulse-dot.green { background: var(--success); }
.pulse-dot.yellow { background: var(--warning); }
.pulse-dot.red { background: var(--danger); }

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.4); }
}

/* ============================================================
   PROGRESS BAR
   ============================================================ */
.progress-custom {
    height: 4px;
    background: var(--border-light);
    border-radius: 2px;
    overflow: hidden;
}
.progress-custom .progress-bar {
    border-radius: 2px;
    background: var(--primary-gradient);
    transition: width 1s ease;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 992px) {
    .sidebar {
        transform: translateX(-100%);
    }
    .sidebar.show {
        transform: translateX(0);
        box-shadow: var(--shadow-xl);
    }
    .sidebar-toggle {
        display: block;
    }
    .main-content {
        margin-left: 0;
    }
    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.3);
        z-index: 999;
        backdrop-filter: blur(2px);
    }
    .sidebar-overlay.show {
        display: block;
    }
}

@media (max-width: 768px) {
    .content-area {
        padding: 0.85rem;
    }
    .stat-card .stat-number {
        font-size: 1.25rem;
    }
    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .notification-dropdown {
        width: 280px;
    }
}

@media (max-width: 576px) {
    .login-card {
        padding: 1.75rem 1.25rem;
    }
    .login-logo h1 {
        font-size: 0.95rem;
    }
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fadeIn {
    animation: fadeIn 0.35s ease forwards;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-slideUp {
    animation: slideUp 0.4s ease forwards;
}

.animate-on-load {
    opacity: 0;
    transform: translateY(10px);
}

/* ============================================================
   INTERACTIVE HOVER EFFECTS
   ============================================================ */

/* Table row click highlight */
.table-dark-custom tbody tr {
    cursor: pointer;
    position: relative;
}
.table-dark-custom tbody tr::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0;
    background: var(--primary);
    transition: width var(--transition-fast);
    border-radius: 0 2px 2px 0;
}
.table-dark-custom tbody tr:hover::after {
    width: 2px;
}

/* Card focus ring */
.data-card:focus-within {
    border-color: var(--border-orange);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.06);
}

/* Profile avatar hover */
.sidebar-user:hover .user-avatar {
    transform: scale(1.1);
    transition: transform var(--transition-fast);
}

/* Interactive stat cards */
.stat-card {
    cursor: pointer;
}
.stat-card:active {
    transform: translateY(-1px) scale(0.99);
}

/* Smooth link underlines */
.data-card-body a:not(.btn-primary-custom):not(.btn-outline-custom):not(.btn-sm-action) {
    position: relative;
}
.data-card-body a:not(.btn-primary-custom):not(.btn-outline-custom):not(.btn-sm-action)::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--primary);
    transition: width var(--transition-fast);
}
.data-card-body a:not(.btn-primary-custom):not(.btn-outline-custom):not(.btn-sm-action):hover::after {
    width: 100%;
}

/* Focus styles for accessibility */
.form-control:focus, .form-select:focus, .btn-primary-custom:focus, .btn-outline-custom:focus {
    outline: none;
}
.btn-primary-custom:focus-visible, .btn-outline-custom:focus-visible {
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.25);
}

/* Ripple effect on buttons */
.btn-primary-custom, .btn-outline-custom, .btn-login {
    position: relative;
    overflow: hidden;
}
.btn-primary-custom::after, .btn-login::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s, height 0.4s;
}
.btn-primary-custom:active::after, .btn-login:active::after {
    width: 200px;
    height: 200px;
}
