body {
    --primary-color: #004aad; /* Navy Blue from Logo */
    --primary-hover: #003399;
    --secondary-color: #ff7e21; /* Vibrant Orange from Logo */
    --accent-color: #ffb703;
    --danger-color: #ef4444;
    --bg-dark: #0f172a;
    --bg-card: #1e293b;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --border-color: #334155;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --poll-bg: #e7f3ff;
    --poll-text: #1c1e21;
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.1);
    
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

body.light-mode {
    --bg-dark: #f1f5f9;
    --bg-card: #ffffff;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(255, 255, 255, 0.5);
    --poll-bg: #f8fafc;
    --card-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    text-decoration: none;
}

body {
    /* Variables handled above */
}

.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 2.25rem;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

h1, h2, h3 {
    font-weight: 700;
    letter-spacing: -0.025em;
}

.gradient-text {
    color: var(--primary-color);
    font-weight: 800;
}

.brand-bb { color: var(--primary-color); }
.brand-quick { color: var(--secondary-color); }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    gap: 0.5rem;
    font-size: 0.95rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), #818cf8);
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.6);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
}

.form-control {
    width: 100%;
    background: rgba(15, 23, 42, 0.05); /* Subtle overlay for light mode */
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    color: var(--text-main);
    transition: border-color 0.3s;
}

body:not(.light-mode) .form-control {
    background: rgba(15, 23, 42, 0.6);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background: var(--bg-card);
    border-right: 1px solid var(--border-color);
    padding: 2.5rem 1.5rem;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.main-content {
    margin-left: 280px;
    padding: 0;
    transition: all 0.4s ease;
}

.top-header {
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 900;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 1.25rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left { display: flex; align-items: center; gap: 1rem; }
.header-breadcrumb { font-weight: 500; font-size: 0.95rem; color: var(--text-muted); }
.mobile-header-logo { display: none; }

.content-body {
    padding: 2.5rem 3rem;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-bottom: 0.5rem;
}

.sidebar-nav-link i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

.sidebar-nav-link:hover, .sidebar-nav-link.active {
    background: rgba(99, 102, 241, 0.08);
    color: var(--primary-color);
}

.sidebar-nav-link.active {
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.15) 0%, transparent 100%);
    border-left: 3px solid var(--primary-color);
}

.mobile-toggle {
    display: none;
    background: transparent;
    color: var(--text-main);
    width: 40px;
    height: 40px;
    border: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.25rem;
}

#sidebar-theme-item {
    display: none;
}

/* Responsive */
@media (max-width: 1024px) {
    #sidebar-theme-item {
        display: block;
    }
    .sidebar {
        left: -320px; 
        box-shadow: 20px 0 40px rgba(0,0,0,0.2);
    }
    
    .sidebar.active {
        left: 0;
    }
    
    .main-content {
        margin-left: 0;
    }

    .top-header {
        padding: 0.75rem 1.25rem;
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
    }

    .content-body {
        padding: 2rem 1.5rem;
    }

    .header-breadcrumb {
        display: none;
    }

    .header-left {
        justify-content: flex-start;
    }

    .mobile-header-logo {
        display: block;
        font-size: 1.4rem;
        font-weight: 800;
        text-align: center;
    }

    .header-right {
        display: flex;
        justify-content: flex-end;
    }
    
    .mobile-toggle {
        display: flex !important;
    }
}

.status-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-flex;
    align-items: center;
}

/* Status: Approved - High Legibility Green */
.status-approved { 
    background: #dcfce7; 
    color: #166534; 
}

/* Status: Created - Simple Blue Info */
.status-created { 
    background: #dbeafe; 
    color: #1e40af; 
}

.status-pending { background: rgba(148, 163, 184, 0.15); color: #475569; }
.status-success { background: #dcfce7; color: #166534; }
.status-danger { background: #fee2e2; color: #991b1b; }

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* Specific Poll UI representation */
.poll-container {
    background: var(--poll-bg);
    border-radius: 20px;
    padding: 1.5rem;
    color: var(--poll-text);
    max-width: 400px;
}

.poll-option {
    background: var(--bg-card);
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.2s;
}

.poll-option.completed {
    background: #dcfce7;
    border-color: #22c55e;
}

.poll-option.active {
    border-color: #3b82f6;
}

.table-container {
    width: 100%;
    overflow-x: auto;
    border-radius: 16px;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    vertical-align: middle;
}

.custom-table th {
    background: transparent;
    color: var(--text-muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.05em;
    padding: 1.25rem 1.5rem;
    border-bottom: 2px solid var(--border-color);
    text-align: left;
}

.custom-table td {
    padding: 1.25rem 1.5rem;
    color: var(--text-main);
    font-size: 0.9rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.custom-table tr:last-child td {
    border-bottom: none;
}

.custom-table tr:hover td {
    background: rgba(99, 102, 241, 0.02);
}

.amount-col {
    font-family: monospace;
    font-weight: 600;
}

/* Light Mode Specific Enhancements */
body.light-mode .glass-card {
    background: #ffffff;
    border-color: #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 20px 25px -5px rgba(0, 0, 0, 0.03);
}

body.light-mode .sidebar {
    background: #ffffff;
    border-right: 1px solid #e2e8f0;
}

body.light-mode .top-header {
    background: rgba(255, 255, 255, 0.8);
    border-bottom: 1px solid #e2e8f0;
}

body.light-mode .form-control {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #0f172a;
}

body.light-mode .form-control:focus {
    background: #ffffff;
    border-color: #6366f1;
}
