/* ==========================================================================
   Balu Cars CRM & HR System - Main Stylesheet
   Modern, Clean, Professional Business Theme
   ========================================================================== */

:root {
    --bg-main: #F5F7FA;
    --bg-card: #FFFFFF;
    --primary: #1E3A8A; /* Deep Blue Brand */
    --primary-hover: #172554;
    --primary-light: #EFF6FF;
    --accent: #EA580C; /* Vibrant Orange for Key Actions */
    --accent-hover: #C2410C;
    --accent-light: #FFF7ED;
    --success: #16A34A;
    --success-light: #DCFCE7;
    --warning: #D97706;
    --warning-light: #FEF3C7;
    --danger: #DC2626;
    --danger-light: #FEE2E2;
    --info: #0284C7;
    --info-light: #E0F2FE;
    --purple: #7C3AED;
    --purple-light: #F3E8FF;
    
    --text-primary: #0F172A;
    --text-secondary: #475569;
    --text-muted: #94A3B8;
    
    --border-color: #E2E8F0;
    --border-focus: #1E3A8A;
    
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-full: 9999px;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
    
    --sidebar-width: 260px;
    --header-height: 64px;
    --transition: all 0.2s ease-in-out;
}

/* Global Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Typography Hierarchy */
h1, .h1 { font-size: 24px; font-weight: 700; color: var(--text-primary); line-height: 1.3; }
h2, .h2 { font-size: 18px; font-weight: 600; color: var(--text-primary); line-height: 1.3; }
h3, .h3 { font-size: 16px; font-weight: 600; color: var(--text-primary); }
p, .text-body { font-size: 14px; color: var(--text-secondary); }
.text-xs { font-size: 12px; }
.text-sm { font-size: 13px; }
.text-muted { color: var(--text-muted); }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

/* Layout Structure */
.app-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background-color: #FFFFFF;
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    transition: var(--transition);
}

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

.logo-badge {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, var(--primary), #2563EB);
    color: #FFFFFF;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 2px 4px rgba(30, 58, 138, 0.25);
}

.brand-text h1 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.1;
    letter-spacing: -0.3px;
}

.brand-text span {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
}

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

.nav-item.active {
    background-color: var(--primary);
    color: #FFFFFF;
    box-shadow: 0 2px 4px rgba(30, 58, 138, 0.2);
}

.nav-item.active svg {
    stroke: #FFFFFF;
}

.nav-item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    stroke: currentColor;
}

.sidebar-footer {
    padding: 14px 18px;
    border-top: 1px solid var(--border-color);
    background: #FAFAFA;
}

.user-snippet {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-avatar {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-full);
    background: #E2E8F0;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 13px;
}

/* Main Content Area */
.main-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* Topbar Header */
.topbar {
    height: var(--header-height);
    background-color: #FFFFFF;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 90;
    box-shadow: var(--shadow-sm);
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
    max-width: 500px;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    color: var(--text-secondary);
}

.search-box {
    position: relative;
    width: 100%;
}

.search-box input {
    width: 100%;
    padding: 9px 14px 9px 38px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background-color: var(--bg-main);
    font-size: 13px;
    color: var(--text-primary);
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    background-color: #FFFFFF;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.search-box svg {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    color: var(--text-muted);
}

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

/* Quick Lead Header Button */
.btn-topbar-lead {
    background-color: var(--accent);
    color: #FFFFFF;
    border: none;
    border-radius: var(--radius-md);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(234, 88, 12, 0.25);
    transition: var(--transition);
}

.btn-topbar-lead:hover {
    background-color: var(--accent-hover);
    transform: translateY(-1px);
}

.notification-btn {
    position: relative;
    background: none;
    border: none;
    padding: 8px;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-btn:hover {
    background-color: var(--bg-main);
    color: var(--primary);
}

.unread-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background-color: var(--danger);
    color: #FFFFFF;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 5px;
    border-radius: var(--radius-full);
}

.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-left: 8px;
    border-left: 1px solid var(--border-color);
}

.user-role-tag {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 600;
}
.role-admin { background: #E0E7FF; color: #3730A3; }
.role-accountant { background: #FEF3C7; color: #92400E; }
.role-sales { background: #DCFCE7; color: #166534; }

.btn-logout {
    background: none;
    border: 1px solid var(--border-color);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.btn-logout:hover {
    background-color: var(--danger-light);
    color: var(--danger);
    border-color: #FECACA;
}

/* Page Content Container */
.page-content {
    padding: 24px 30px;
    flex: 1;
}

.page-header {
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.page-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
}

.page-header p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 4px;
}

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

/* Cards */
.card {
    background-color: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    padding: 20px;
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #F1F5F9;
}

.card-header h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

/* Metric / Stat Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: var(--transition);
}

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

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-icon svg {
    width: 24px;
    height: 24px;
}

.stat-info .num {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-info .lbl {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-top: 2px;
}

/* Home Quick Action Shortcut Cards */
.shortcuts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.shortcut-card {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 16px;
}

.shortcut-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.shortcut-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.shortcut-icon svg {
    width: 24px;
    height: 24px;
}

.shortcut-content h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.shortcut-content p {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* Tabs */
.tabs-container {
    display: flex;
    gap: 6px;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 20px;
    overflow-x: auto;
}

.tab-btn {
    background: none;
    border: none;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    white-space: nowrap;
}

.tab-btn:hover {
    color: var(--primary);
}

.tab-btn.active {
    color: var(--primary);
    font-weight: 600;
    border-bottom-color: var(--primary);
}

.tab-badge {
    background: #E2E8F0;
    color: var(--text-secondary);
    font-size: 11px;
    padding: 2px 7px;
    border-radius: var(--radius-full);
}

.tab-btn.active .tab-badge {
    background: var(--primary-light);
    color: var(--primary);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: var(--transition);
    text-decoration: none;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: 12px 24px;
    font-size: 15px;
}

.btn-primary {
    background-color: var(--primary);
    color: #FFFFFF;
}
.btn-primary:hover {
    background-color: var(--primary-hover);
}

.btn-accent {
    background-color: var(--accent);
    color: #FFFFFF;
}
.btn-accent:hover {
    background-color: var(--accent-hover);
}

.btn-secondary {
    background-color: #FFFFFF;
    color: var(--text-secondary);
    border-color: var(--border-color);
}
.btn-secondary:hover {
    background-color: var(--bg-main);
    color: var(--text-primary);
}

.btn-danger {
    background-color: var(--danger);
    color: #FFFFFF;
}
.btn-danger:hover {
    background-color: #B91C1C;
}

.btn-success {
    background-color: var(--success);
    color: #FFFFFF;
}
.btn-success:hover {
    background-color: #15803D;
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
    border: 1px solid transparent;
}

.badge-new { background: #EFF6FF; color: #1D4ED8; border-color: #BFDBFE; }
.badge-contacted { background: #E0F2FE; color: #0369A1; border-color: #BAE6FD; }
.badge-interested { background: #FEF3C7; color: #B45309; border-color: #FDE68A; }
.badge-visit-scheduled { background: #F3E8FF; color: #6D28D9; border-color: #DDD6FE; }
.badge-negotiation { background: #EEF2FF; color: #4338CA; border-color: #C7D2FE; }
.badge-won { background: #DCFCE7; color: #15803D; border-color: #BBF7D0; }
.badge-lost { background: #FEE2E2; color: #B91C1C; border-color: #FECACA; }

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

.table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.table th {
    background-color: #F8FAFC;
    color: #64748B;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
}

.table td {
    padding: 13px 16px;
    border-bottom: 1px solid var(--border-color);
    font-size: 13px;
    color: var(--text-primary);
    vertical-align: middle;
}

.table tr:hover td {
    background-color: #F8FAFC;
}

/* Forms */
.form-group {
    margin-bottom: 18px;
}

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.form-label .required {
    color: var(--danger);
    margin-left: 2px;
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background-color: #FFFFFF;
    font-size: 14px;
    color: var(--text-primary);
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.12);
}

textarea.form-control {
    min-height: 90px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

/* Expandable "More Details" Accordion */
.accordion-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 600;
    background: none;
    border: none;
    cursor: pointer;
    margin: 12px 0 16px 0;
    padding: 0;
}

.accordion-body {
    display: none;
    background: #F8FAFC;
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    margin-bottom: 16px;
}

.accordion-body.open {
    display: block;
}

/* Modals */
.modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(2px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-backdrop.active {
    display: flex;
}

.modal-content {
    background: #FFFFFF;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    animation: modalIn 0.2s ease-out;
}

@keyframes modalIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

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

.modal-header h2 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
}

.modal-close {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--text-muted);
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    background: #FAFAFA;
}

/* Kanban Board View */
.kanban-board {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 16px;
}

.kanban-column {
    background: #F1F5F9;
    border-radius: var(--radius-md);
    padding: 14px;
    display: flex;
    flex-direction: column;
    min-height: 450px;
}

.kanban-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.kanban-items {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 200px;
}

.kanban-card {
    background: #FFFFFF;
    border-radius: var(--radius-md);
    padding: 14px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    cursor: grab;
    transition: var(--transition);
}

.kanban-card:hover {
    box-shadow: var(--shadow-md);
    border-color: #CBD5E1;
}

.kanban-card.dragging {
    opacity: 0.5;
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: 48px 20px;
    color: var(--text-secondary);
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    background: var(--bg-main);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px auto;
    color: var(--text-muted);
}

.empty-state h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.empty-state p {
    font-size: 13px;
    max-width: 320px;
    margin: 0 auto 16px auto;
}

/* Toast Notifications (Top Center or Top Right) */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    background: #FFFFFF;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 280px;
    max-width: 400px;
    border-left: 4px solid var(--success);
    animation: toastSlide 0.25s ease-out;
}

.toast.toast-error {
    border-left-color: var(--danger);
}

.toast.toast-info {
    border-left-color: var(--info);
}

@keyframes toastSlide {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* REMINDER POPUP IN BOTTOM-RIGHT CORNER (Requirement #9) */
.reminder-stack {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    width: 380px;
    max-width: calc(100vw - 32px);
    max-height: min(540px, calc(100vh - 80px));
    background: #FFFFFF;
    border-radius: var(--radius-lg);
    box-shadow: 0 12px 35px -4px rgba(15, 23, 42, 0.22), 0 4px 12px -2px rgba(15, 23, 42, 0.12);
    border: 1px solid #CBD5E1;
    display: none;
    flex-direction: column;
    overflow: hidden;
    animation: reminderPop 0.25s ease-out;
}

.reminder-panel-header {
    background: linear-gradient(135deg, #1E3A8A 0%, #1E40AF 100%);
    color: #FFFFFF;
    padding: 10px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    user-select: none;
    flex-shrink: 0;
}

.reminder-panel-title {
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    letter-spacing: 0.2px;
}

.reminder-panel-count {
    background: var(--accent);
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: var(--radius-full);
}

.reminder-panel-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-reminder-header {
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-reminder-header:hover {
    background: rgba(255, 255, 255, 0.3);
}

.btn-reminder-collapse {
    background: none;
    border: none;
    color: #FFFFFF;
    cursor: pointer;
    font-size: 12px;
    padding: 2px 6px;
    line-height: 1;
    border-radius: 4px;
    transition: var(--transition);
}

.btn-reminder-collapse:hover {
    background: rgba(255, 255, 255, 0.2);
}

.reminder-scroll-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #F8FAFC;
}

/* Custom Sleek Scrollbar */
.reminder-scroll-body::-webkit-scrollbar {
    width: 6px;
}
.reminder-scroll-body::-webkit-scrollbar-track {
    background: #F1F5F9;
    border-radius: 4px;
}
.reminder-scroll-body::-webkit-scrollbar-thumb {
    background: #CBD5E1;
    border-radius: 4px;
}
.reminder-scroll-body::-webkit-scrollbar-thumb:hover {
    background: #94A3B8;
}

.reminder-card {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    border-left: 4px solid var(--accent);
    border-radius: var(--radius-md);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.04);
    padding: 12px 14px;
    position: relative;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.reminder-card:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.reminder-card.overdue {
    border-left-color: var(--danger);
}

@keyframes reminderPop {
    from { opacity: 0; transform: translateY(20px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

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

.reminder-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--accent);
    display: flex;
    align-items: center;
    gap: 6px;
    text-transform: uppercase;
}

.reminder-time {
    font-size: 11px;
    font-weight: 600;
    background: #FFF7ED;
    color: var(--accent);
    padding: 2px 7px;
    border-radius: var(--radius-full);
}

.reminder-body h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.reminder-body p {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
    line-height: 1.4;
}

.reminder-actions {
    display: flex;
    gap: 6px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.reminder-actions .btn {
    padding: 5px 8px;
    font-size: 11px;
    font-weight: 600;
    flex: 1;
    min-width: 65px;
    text-align: center;
}

/* Timeline Components */
.timeline {
    position: relative;
    padding-left: 24px;
    margin-top: 14px;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 5px;
    bottom: 5px;
    left: 7px;
    width: 2px;
    background: #E2E8F0;
}

.timeline-item {
    position: relative;
    margin-bottom: 18px;
}

.timeline-dot {
    position: absolute;
    left: -24px;
    top: 4px;
    width: 14px;
    height: 14px;
    border-radius: var(--radius-full);
    background: var(--primary);
    border: 3px solid #FFFFFF;
    box-shadow: 0 0 0 1px #CBD5E1;
}

.timeline-content {
    background: #F8FAFC;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 10px 14px;
}

.timeline-content .header {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

/* Attendance Color Grid Cells */
.att-cell {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 12px;
    margin: 1px;
}
.att-P { background: #DCFCE7; color: #15803D; } /* Present */
.att-A { background: #FEE2E2; color: #B91C1C; } /* Absent */
.att-HD { background: #FEF3C7; color: #B45309; } /* Half Day */
.att-PL { background: #EFF6FF; color: #1D4ED8; } /* Paid Leave */
.att-UL { background: #F1F5F9; color: #64748B; } /* Unpaid Leave */
.att-H { background: #F3E8FF; color: #6D28D9; } /* Holiday / Off */

/* Responsive Mobile Navigation */
@media (max-width: 900px) {
    .sidebar {
        transform: translateX(-100%);
    }
    .sidebar.open {
        transform: translateX(0);
        box-shadow: var(--shadow-xl);
    }
    .main-wrapper {
        margin-left: 0;
    }
    .menu-toggle {
        display: block;
    }
    .page-content {
        padding: 16px;
    }
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .topbar-left {
        max-width: 220px;
    }
    .user-profile-badge span {
        display: none;
    }
}
