:root {
    /* Dark Mode Colors (Default) */
    --primary-color: #1e293b;         
    --primary-light: #334155;         
    --primary-dark: #0f172a;          
    --secondary-color: #38bdf8;       
    --accent-color: #f472b6;          
    --danger-color: #f43f5e;          
    --warning-color: #fbbf24;         
    --success-color: #22d3ee;         

    --bg-primary: #0a0f1a;            
    --bg-secondary: #181f2a;          
    --bg-tertiary: #232b3b;           
    --bg-card: rgba(24, 31, 42, 0.92);
    --bg-glass: rgba(10, 15, 26, 0.92);

    --text-primary: #f1f5f9;          
    --text-secondary: #94a3b8;        
    --text-muted: #64748b;            

    --border-color: rgba(51, 65, 85, 0.7);
    --border-light: rgba(203, 213, 225, 0.08);

    --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.10);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.18), 0 2px 4px -1px rgba(0,0,0,0.12);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.22), 0 4px 6px -2px rgba(0,0,0,0.10);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.25), 0 10px 10px -5px rgba(0,0,0,0.10);

    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
}

/* Light Mode Colors */
[data-theme="light"] {
    --primary-color: #0ea5e9;         
    --primary-light: #38bdf8;         
    --primary-dark: #0284c7;          
    --secondary-color: #2563eb;       
    --accent-color: #ec4899;          
    --danger-color: #ef4444;          
    --warning-color: #f59e0b;         
    --success-color: #10b981;         

    --bg-primary: #f5f7fa;            /* Softer, slightly grayish */
    --bg-secondary: #eef2f6;          /* Warmer light gray */
    --bg-tertiary: #e3e8ef;           /* Muted gray-blue */
    --bg-card: rgba(255, 255, 255, 0.85);  /* Less opaque */
    --bg-glass: rgba(248, 250, 252, 0.85); /* Softer glass effect */

    --text-primary: #1e293b;          /* Softer than pure black */
    --text-secondary: #64748b;        /* Warmer gray */
    --text-muted: #94a3b8;            /* Lighter muted text */

    --border-color: rgba(203, 213, 225, 0.5);  /* Softer borders */
    --border-light: rgba(148, 163, 184, 0.12); /* Very subtle */

    --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.04);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.06), 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.09), 0 10px 10px -5px rgba(0,0,0,0.04);
}

/* Light mode specific background - Apple-style liquid glass */
[data-theme="light"] body {
    background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf3 50%, #f5f7fa 100%);
    position: relative;
}

[data-theme="light"] body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(99, 102, 241, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.06) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(59, 130, 246, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
    animation: liquidShift 20s ease-in-out infinite;
}

@keyframes liquidShift {
    0%, 100% { 
        background-position: 0% 0%, 100% 100%, 40% 60%;
        opacity: 1;
    }
    50% { 
        background-position: 100% 100%, 0% 0%, 60% 40%;
        opacity: 0.8;
    }
}

* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

body {
    background: linear-gradient(135deg, var(--bg-primary) 0%, #0c1426 50%, var(--bg-primary) 100%);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
    
    
    -webkit-overflow-scrolling: touch;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
    overscroll-behavior: contain;
    touch-action: manipulation;
}


* {
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}


p, span, div, h1, h2, h3, h4, h5, h6, a, li {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}


.container, .navbar, .footer, .header {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-perspective: 1000px;
    perspective: 1000px;
}


body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(37, 99, 235, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(16, 185, 129, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(245, 158, 11, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}


.navbar {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-light);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
}

.navbar:hover {
    backdrop-filter: blur(25px);
    border-bottom-color: rgba(56, 189, 248, 0.2);
}

/* Light Mode - Apple Liquid Glass Effect for navbar */
[data-theme="light"] .navbar {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(40px) saturate(180%);
    border-bottom: 1px solid rgba(203, 213, 225, 0.6);
    box-shadow: 
        0 4px 24px -2px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.9) inset;
}

[data-theme="light"] .navbar:hover {
    backdrop-filter: blur(50px) saturate(200%);
    border-bottom-color: rgba(99, 102, 241, 0.3);
    box-shadow: 
        0 6px 32px -4px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(255, 255, 255, 1) inset;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-logo-container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0.5rem;
    border-radius: var(--radius-lg);
}

.nav-logo-container:hover {
    transform: scale(1.05);
    background: rgba(37, 99, 235, 0.1);
    box-shadow: 0 0 30px rgba(37, 99, 235, 0.3);
}

.nav-logo-img {
    height: 40px;
    width: auto;
    transition: all 0.3s ease;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Theme Toggle Button */
.theme-toggle {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.theme-toggle::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.theme-toggle:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.15);
}

.theme-toggle:hover::before {
    opacity: 1;
}

.theme-toggle svg {
    width: 1.25rem;
    height: 1.25rem;
    transition: all 0.3s ease;
}

.theme-toggle:active {
    transform: translateY(-1px) scale(1);
}

/* Hide/show icons based on theme */
.theme-toggle .sun-icon {
    display: none;
}

.theme-toggle .moon-icon {
    display: block;
}

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

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

/* Theme toggle animation */
.theme-toggle svg {
    animation: iconRotate 0.5s ease;
}

@keyframes iconRotate {
    0% {
        transform: rotate(0deg) scale(0);
        opacity: 0;
    }
    50% {
        transform: rotate(180deg) scale(0.8);
        opacity: 0.5;
    }
    100% {
        transform: rotate(360deg) scale(1);
        opacity: 1;
    }
}

.logout-btn {
    background: rgba(244, 63, 94, 0.08);
    color: var(--danger-color);
    border: 1px solid rgba(244, 63, 94, 0.25);
    padding: 0.5rem 1rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    margin-left: 0.5rem;
    position: relative;
    overflow: hidden;
}

.logout-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(244, 63, 94, 0.15), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 10px;
}

.logout-btn:hover {
    background: rgba(244, 63, 94, 0.15);
    border-color: rgba(244, 63, 94, 0.4);
    color: #ff6b7a;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(244, 63, 94, 0.2);
}

.logout-btn:hover::before {
    opacity: 1;
}

[data-theme="light"] .logout-btn {
    background: rgba(244, 63, 94, 0.06);
    border-color: rgba(244, 63, 94, 0.3);
    color: #dc2626;
}

[data-theme="light"] .logout-btn:hover {
    background: rgba(244, 63, 94, 0.12);
    border-color: rgba(244, 63, 94, 0.45);
    color: #b91c1c;
}

/* Desktop User Display */
.desktop-user-display {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
    margin-right: 1rem;
    background: rgba(56, 189, 248, 0.08);
    border: 1px solid rgba(56, 189, 248, 0.2);
    border-radius: var(--radius-md);
    backdrop-filter: blur(10px);
}

.desktop-user-info {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.35rem 0.65rem;
    background: rgba(99, 102, 241, 0.08);
    border-radius: 10px;
    border: 1px solid rgba(99, 102, 241, 0.15);
    transition: all 0.3s ease;
    min-width: 110px;
}

.desktop-user-info:hover {
    background: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.25);
    transform: translateY(-1px);
}

[data-theme="light"] .desktop-user-info {
    background: rgba(99, 102, 241, 0.05);
    border-color: rgba(99, 102, 241, 0.2);
}

[data-theme="light"] .desktop-user-info:hover {
    background: rgba(99, 102, 241, 0.08);
    border-color: rgba(99, 102, 241, 0.3);
}

.desktop-user-name {
    color: var(--text-primary);
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0.01em;
}

.desktop-user-name.loading {
    opacity: 0.7;
    animation: pulse 1.5s ease-in-out infinite;
}

.desktop-user-fund {
    color: var(--success-color);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    white-space: nowrap;
    line-height: 1.3;
    text-align: left;
    opacity: 0.95;
}

[data-theme="light"] .desktop-user-fund {
    color: #059669;
}

.desktop-user-fund.loading {
    background: linear-gradient(90deg, 
        var(--border-light) 25%, 
        rgba(34, 211, 238, 0.3) 50%, 
        var(--border-light) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
    height: 1rem;
    width: 80px;
    display: inline-block;
    -webkit-text-fill-color: initial;
    color: transparent;
}

.docs-btn {
    background: rgba(148, 163, 184, 0.08);
    color: var(--text-secondary) !important;
    border: 1px solid rgba(148, 163, 184, 0.15);
    padding: 0.5rem 1rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.8rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    position: relative;
    margin: 0;
    backdrop-filter: blur(10px);
    white-space: nowrap;
}

.docs-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 10px;
    padding: 1px;
    background: linear-gradient(135deg, transparent, rgba(99, 102, 241, 0.2), transparent);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: subtract;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.docs-btn:hover {
    color: var(--text-primary) !important;
    background: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.3);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.15);
}

.docs-btn:hover::before {
    opacity: 1;
}

[data-theme="light"] .docs-btn {
    background: rgba(148, 163, 184, 0.06);
    border-color: rgba(148, 163, 184, 0.2);
}

[data-theme="light"] .docs-btn:hover {
    background: rgba(99, 102, 241, 0.08);
    border-color: rgba(99, 102, 241, 0.35);
}

.docs-btn.active {
    color: var(--text-primary) !important;
    background: linear-gradient(135deg, 
        rgba(99, 102, 241, 0.15), 
        rgba(139, 92, 246, 0.12)
    );
    font-weight: 600;
    position: relative;
    box-shadow: 0 2px 12px rgba(56, 189, 248, 0.15);
    border: 1px solid rgba(56, 189, 248, 0.2);
}

.docs-btn.active::before {
    opacity: 1;
}

.docs-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 40%;
    height: 2px;
    background: linear-gradient(90deg, var(--secondary-color), var(--accent-color));
    border-radius: 2px;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        width: 0;
        opacity: 0;
    }
    to {
        width: 40%;
        opacity: 1;
    }
}


@media (max-width: 1024px) {
    .docs-btn {
        padding: 0.35rem 0.6rem !important;
        font-size: 0.8rem !important;
        font-weight: 500 !important;
    }
    
    .logout-btn {
        padding: 0.35rem 0.6rem;
        font-size: 0.8rem;
        font-weight: 500;
    }
    
    .theme-toggle {
        width: 2.25rem;
        height: 2.25rem;
    }
    
    .theme-toggle svg {
        width: 1.1rem;
        height: 1.1rem;
    }
    
    .nav-brand {
        font-size: 1.3rem !important;
        font-weight: 700 !important;
    }
}

/* Extra small mobile devices - additional adjustments */
@media (max-width: 480px) {
    /* Mobile menu button already shown via max-width: 1024px rule */
    
    .nav-menu-mobile {
        display: block !important;
        position: relative;
    }
    
    .nav-brand {
        font-size: 1.25rem !important;
        font-weight: 700 !important;
        letter-spacing: 0.5px;
    }
    
    .nav-logo-img {
        height: 35px;
    }
}


.nav-menu-mobile {
    display: none;
}

/* Modern Desktop Menu Style */
.nav-menu-desktop {
    display: none;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, 
        rgba(30, 41, 59, 0.95) 0%, 
        rgba(15, 23, 42, 0.95) 100%);
    backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 16px;
    padding: 0.5rem 0.75rem;
    box-shadow: 
        0 4px 24px -2px rgba(0, 0, 0, 0.12),
        0 8px 16px -4px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-menu-desktop::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, 
        rgba(99, 102, 241, 0.08) 0%, 
        rgba(139, 92, 246, 0.05) 50%,
        rgba(59, 130, 246, 0.08) 100%
    );
    border-radius: 16px;
    pointer-events: none;
    opacity: 0.6;
}

.nav-menu-desktop:hover {
    border-color: rgba(148, 163, 184, 0.2);
    box-shadow: 
        0 8px 32px -4px rgba(0, 0, 0, 0.16),
        0 12px 24px -6px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* Light mode adjustments for desktop menu */
[data-theme="light"] .nav-menu-desktop {
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.98) 0%, 
        rgba(248, 250, 252, 0.98) 100%);
    border: 1px solid rgba(203, 213, 225, 0.6);
    box-shadow: 
        0 4px 24px -2px rgba(0, 0, 0, 0.08),
        0 8px 16px -4px rgba(0, 0, 0, 0.04),
        inset 0 1px 0 rgba(255, 255, 255, 1);
}

[data-theme="light"] .nav-menu-desktop::before {
    background: linear-gradient(135deg, 
        rgba(99, 102, 241, 0.04) 0%, 
        rgba(139, 92, 246, 0.03) 50%,
        rgba(59, 130, 246, 0.04) 100%
    );
}

[data-theme="light"] .nav-menu-desktop:hover {
    border-color: rgba(148, 163, 184, 0.4);
    box-shadow: 
        0 8px 32px -4px rgba(0, 0, 0, 0.12),
        0 12px 24px -6px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 1);
}



.mobile-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.375rem;
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    position: relative;
    z-index: 1002;
}

.hamburger-line {
    width: 1.75rem;
    height: 2.5px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Light mode - make hamburger darker and more visible */
[data-theme="light"] .hamburger-line {
    background: var(--primary-dark);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

.mobile-menu-btn.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active .hamburger-line:nth-child(2) {
    opacity: 0;
    transform: translateX(-10px);
}

.mobile-menu-btn.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.mobile-dropdown {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile browsers */
    background: var(--bg-primary);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-100%);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1001;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    /* Hide scrollbar */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.mobile-dropdown::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding-top: 80px;
}

.mobile-user-header {
    padding: 2rem 2rem 1.5rem;
    background: var(--bg-card);
    border-bottom: 2px solid var(--border-light);
    text-align: center;
    position: relative;
}

.mobile-user-header::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--secondary-color), var(--accent-color));
    border-radius: 2px;
}

.mobile-user-name {
    font-size: 1.125rem;
    font-weight: 600;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mobile-user-name.loading {
    background: linear-gradient(90deg, 
        var(--border-light) 25%, 
        rgba(56, 189, 248, 0.3) 50%, 
        var(--border-light) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 6px;
    height: 1.5rem;
    width: 120px;
    display: inline-block;
    -webkit-text-fill-color: initial;
    color: transparent;
    margin: 0 auto;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.mobile-user-fund {
    font-size: 1rem;
    font-weight: 500;
    color: var(--success-color);
    text-align: center;
    margin-top: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(34, 211, 238, 0.1);
    border-radius: var(--radius-md);
    border: 1px solid rgba(34, 211, 238, 0.2);
    white-space: pre-line; /* Support multi-line display */
    line-height: 1.6;
}

.mobile-user-fund.loading {
    background: linear-gradient(90deg, 
        var(--border-light) 25%, 
        rgba(34, 211, 238, 0.3) 50%, 
        var(--border-light) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 6px;
    height: 2rem;
    width: 140px;
    margin: 0.5rem auto 0;
    display: block;
    color: transparent;
}

.mobile-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

.mobile-menu-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 2rem 0;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 1.25rem 2rem;
    color: var(--text-primary);
    text-decoration: none;
    border: none;
    background: none;
    font-size: 1.125rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-bottom: 1px solid var(--border-light);
    position: relative;
}

.menu-item-text {
    position: relative;
    z-index: 1;
}

.mobile-menu-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-item:active {
    background: rgba(56, 189, 248, 0.05);
    transform: scale(0.98);
}

.mobile-menu-item.active {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.12), rgba(37, 99, 235, 0.08));
}

.mobile-menu-item.active::before {
    opacity: 1;
}

.mobile-menu-item.active .menu-item-text {
    color: var(--secondary-color);
    font-weight: 600;
}

.mobile-logout {
    color: var(--danger-color);
    margin-top: auto;
    border-top: 2px solid var(--border-light);
    border-bottom: none;
}

.mobile-logout:active {
    background: rgba(244, 63, 94, 0.1);
    color: var(--danger-color);
}


/* Mobile/Tablet: Show hamburger menu */
@media (max-width: 1024px) {
    .mobile-menu-btn {
        display: flex !important;
    }
    
    .nav-menu-mobile {
        display: flex !important;
    }
    
    .nav-menu-desktop {
        display: none !important;
    }
    
    /* Completely remove logo container on mobile - no interaction */
    .nav-logo-desktop {
        display: none !important;
        pointer-events: none;
    }
    
    .nav-logo {
        gap: 0;
    }
    
    /* Adjust nav brand spacing and make it clickable */
    .nav-brand {
        font-size: 1.25rem;
        margin-left: 0;
        padding: 0.5rem 0;
    }
    
    .navbar {
        padding: 0.75rem 0;
    }
    
    .nav-container {
        padding: 0 1rem;
    }
    
    /* Hide page header logo on mobile */
    .header-compact .logo-container-compact {
        display: none;
    }
}

@media (max-width: 480px) {
    .mobile-menu-item {
        padding: 1rem 1.25rem;
        font-size: 1rem;
        min-height: 48px;
        display: flex;
        align-items: center;
    }
    
    .nav-logo-img {
        height: 35px;
    }
    
    .nav-logo {
        display: flex;
        align-items: center;
        gap: 0.75rem;
    }
    
    .nav-brand {
        font-size: 1.125rem;
    }
    
    
    html {
        -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
        text-size-adjust: 100%;
        height: 100%;
        overflow-x: hidden;
    }
    
    body {
        height: 100%;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-y: contain;
        scroll-snap-type: none;
        will-change: scroll-position;
        scroll-behavior: auto;
    }
    
    
    .container {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: auto;
        scroll-snap-align: none;
        padding-top: 100px;
        padding-bottom: 0;
        min-height: auto;
    }
    
    
    .navbar {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1000;
        background: var(--bg-glass);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
    
    
    .footer {
        margin-bottom: 0;
        position: relative;
        z-index: 1;
        margin-top: 1rem;
    }
    
    
    .table-wrapper {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;
        scroll-snap-type: x mandatory;
    }
    
    
    .navbar, .footer {
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
        will-change: transform;
    }
    
    
    .fade-in-up, .stats-grid, .table-container {
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
        will-change: transform, opacity;
    }
    
    
    .header {
        margin-top: 2rem;
        padding-top: 1rem;
    }
    
    
    body {
        padding-bottom: env(safe-area-inset-bottom, 0px);
        min-height: 100vh;
    }
    
    
    .logo-container {
        padding-top: 1rem;
    }
    
    
    .page-title {
        margin-top: 1.5rem;
    }
    
    
    .dashboard-section {
        margin-bottom: 1rem;
    }
    
    .money-achievement-wide {
        margin: 0 auto 0.5rem auto;
    }
    
    
    .footer {
        padding-bottom: env(safe-area-inset-bottom, 20px);
    }
    
    
    html {
        height: 100%;
        overflow-x: hidden;
    }
    
    body {
        min-height: 100%;
        display: flex;
        flex-direction: column;
    }
    
    .container {
        flex: 1;
    }
}


@media (max-width: 1024px) {
    
    img {
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
    }
    
    
    button, a {
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
        -webkit-touch-callout: none;
        touch-action: manipulation;
    }
    
    
    .nav-logo-container, .footer-logo-container {
        -webkit-tap-highlight-color: rgba(56, 189, 248, 0.3);
        touch-action: manipulation;
        user-select: none;
        -webkit-user-select: none;
        transition: opacity 0.15s ease;
        min-height: 48px;
        min-width: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: var(--radius-md);
        cursor: pointer;
        position: relative;
        z-index: 100;
    }
    
    .nav-logo-container:active, .footer-logo-container:active {
        opacity: 0.7 !important;
        transform: scale(0.98);
    }
    
    
    .nav-logo-img, .footer-logo-img {
        pointer-events: none;
        user-select: none;
        -webkit-user-select: none;
    }
    
    
    * {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
        text-rendering: optimizeLegibility;
    }
    
    
    .container {
        padding-top: 90px;
        padding-bottom: 0;
    }
    
    
    .header {
        margin-top: 1.5rem;
    }
    
    
    .dashboard-section {
        margin-bottom: 1rem;
    }
    
    .money-achievement-wide {
        margin: 0 auto 0.75rem auto;
    }
}


/* Desktop: Show modern menu, hide hamburger */
@media (min-width: 1025px) {
    .navbar {
        position: sticky;
        background: var(--bg-glass);
    }
    
    .container {
        padding-top: 0;
        padding-bottom: 0;
    }
    
    .nav-menu-desktop {
        display: flex !important;
    }
    
    .mobile-menu-btn,
    .nav-menu-mobile {
        display: none !important;
    }
}


.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

/* Compact header for non-homepage pages */
.header-compact {
    text-align: center;
    margin-bottom: 2.5rem;
    margin-left: auto;
    margin-right: auto;
    max-width: 800px;
    position: relative;
    padding: 2rem 0 1rem;
    background: linear-gradient(135deg, 
        rgba(56, 189, 248, 0.03), 
        rgba(16, 185, 129, 0.02)
    );
    border-radius: var(--radius-2xl);
    border: 1px solid rgba(51, 65, 85, 0.1);
    backdrop-filter: blur(10px);
}

/* Light Mode - Header Compact Background */
[data-theme="light"] .header-compact {
    background: linear-gradient(135deg, 
        rgba(250, 251, 252, 0.9), 
        rgba(245, 247, 250, 0.85)
    );
    border: 1px solid rgba(203, 213, 225, 0.25);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.header-compact .logo-container-compact {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.header-compact .logo-main-compact {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem;
    background: rgba(24, 31, 42, 0.4);
    border-radius: var(--radius-xl);
    border: 1px solid rgba(56, 189, 248, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.header-compact .logo-main-compact:hover {
    transform: scale(1.05);
    border-color: rgba(56, 189, 248, 0.2);
    box-shadow: 0 4px 20px rgba(56, 189, 248, 0.1);
}

/* Light Mode - Header Logo Box */
[data-theme="light"] .header-compact .logo-main-compact {
    background: rgba(250, 251, 252, 0.7);
    border: 1px solid rgba(203, 213, 225, 0.3);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .header-compact .logo-main-compact:hover {
    border-color: rgba(37, 99, 235, 0.25);
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.1);
    background: rgba(255, 255, 255, 0.85);
}

.header-compact .logo-img-compact {
    height: 80px;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.header-compact .page-title-compact {
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

.header-compact .page-description {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.5;
}

.organization-name {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 2rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    opacity: 0.8;
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
}

.logo-main {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    padding: 1rem;
    border-radius: var(--radius-2xl);
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-main::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: var(--radius-2xl);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.logo-main:hover {
    transform: scale(1.05) translateY(-5px);
}

.logo-main:hover::before {
    opacity: 0.1;
}

.logo-img {
    height: 140px;
    width: auto;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.3));
}

/* Footer Navigation Styles */
.footer-nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    padding: 0.25rem 0;
    position: relative;
    display: inline-block;
}

.footer-nav-link:hover {
    color: var(--primary-color);
    transform: translateY(-1px);
}

.footer-nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.footer-nav-link:hover::after {
    width: 100%;
}




.page-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-align: center;
    line-height: 1.1;
}

.section-title {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2rem;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
}


.card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-2xl);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-xl);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border-color: rgba(37, 99, 235, 0.3);
}


.table-container {
    margin-bottom: 4rem;
    border-radius: var(--radius-2xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-light);
}

/* Light Mode - Apple Liquid Glass Effect for table container */
[data-theme="light"] .table-container {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 8px 32px -4px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.95) inset,
        0 1px 4px rgba(255, 255, 255, 0.3) inset;
}

.table-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 1.5rem 2rem;
    font-size: 1.25rem;
    font-weight: 700;
    text-align: center;
    position: relative;
}

.table-wrapper {
    max-height: 600px;
    overflow: auto;
    position: relative;
}

/* Subtle scrollbar styling */
.table-wrapper::-webkit-scrollbar {
    height: 6px;
    width: 6px;
}

.table-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.table-wrapper::-webkit-scrollbar-thumb {
    background: var(--secondary-color);
    border-radius: 3px;
    opacity: 0.6;
}

.table-wrapper::-webkit-scrollbar-thumb:hover {
    opacity: 0.8;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.data-table th {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 1rem 0.75rem;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 10;
}

.data-table th:first-child {
    position: sticky;
    left: 0;
    z-index: 15;
    background: var(--primary-color);
    color: white;
    min-width: 80px;
    font-weight: 700;
}

.data-table th:nth-child(2) {
    position: sticky;
    left: 80px;
    z-index: 12;
    background: var(--primary-light);
    color: white;
    min-width: 200px;
    text-align: left;
}



.data-table td {
    padding: 0.875rem 0.75rem;
    text-align: center;
    border-bottom: 1px solid var(--border-light);
    transition: all 0.2s ease;
    color: var(--text-secondary);
}

.data-table tr {
    transition: all 0.2s ease;
    cursor: pointer;
}



.data-table td:first-child {
    position: sticky;
    left: 0;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-weight: 600;
    z-index: 5;
}

.data-table td:nth-child(2) {
    position: sticky;
    left: 80px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    text-align: left;
    font-weight: 500;
    z-index: 3;
}

.data-table tr:hover td {
    background: rgba(37, 99, 235, 0.05);
}

.data-table tr:hover td:first-child,
.data-table tr:hover td:nth-child(2) {
    background: rgba(37, 99, 235, 0.2);
}

/* Modern Download Icon Styles */
.table-action svg {
    transition: all 0.3s ease;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.table-action:hover svg {
    transform: translateY(-1px);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}

/* File and Folder Icon Styles */
.documents-list svg,
#documentsList svg {
    transition: all 0.3s ease;
    color: white;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
}

/* Icon hover animations */
.documents-list li:hover svg,
#documentsList li:hover svg {
    transform: scale(1.1) rotate(2deg);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* Download Button Pulse Animation */
@keyframes download-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(37, 99, 235, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0);
    }
}

.table-action:active {
    animation: download-pulse 0.6s ease-out;
}


.dashboard-section {
    margin-bottom: 2rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-light);
    padding: 2rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(37, 99, 235, 0.3);
}

/* Light Mode - Apple Liquid Glass Effect for stat cards */
[data-theme="light"] .stat-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 
        0 8px 32px -4px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.9) inset,
        0 1px 3px rgba(255, 255, 255, 0.25) inset;
}

[data-theme="light"] .stat-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-xl);
    background: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.08), transparent 70%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

[data-theme="light"] .stat-card:hover {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(50px) saturate(200%);
    box-shadow: 
        0 16px 48px -8px rgba(99, 102, 241, 0.15),
        0 0 0 1px rgba(255, 255, 255, 1) inset,
        0 2px 6px rgba(255, 255, 255, 0.4) inset;
}

[data-theme="light"] .stat-card:hover::after {
    opacity: 1;
}

.stat-title {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
    font-family: 'Inter', monospace;
    word-break: break-all;
    overflow-wrap: anywhere;
    max-width: 100%;
    
    display: block;
    width: 100%;
    text-align: center;
    font-variant-numeric: tabular-nums;
    letter-spacing: -1px;
    line-height: 1.1;
    
    font-size: clamp(1.2rem, 6vw, 2.5rem);
}


.target-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    align-items: start;
}

.target-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-light);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.target-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

/* Light Mode - Apple Liquid Glass Effect for target cards */
[data-theme="light"] .target-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 8px 32px -4px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.95) inset,
        0 1px 4px rgba(255, 255, 255, 0.3) inset;
}

[data-theme="light"] .target-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(139, 92, 246, 0.06), transparent 70%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

[data-theme="light"] .target-card:hover {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(50px) saturate(200%);
    box-shadow: 
        0 16px 48px -8px rgba(139, 92, 246, 0.15),
        0 0 0 1px rgba(255, 255, 255, 1) inset,
        0 2px 6px rgba(255, 255, 255, 0.4) inset;
}

[data-theme="light"] .target-card:hover::after {
    opacity: 1;
}

.target-card-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 1.5rem;
    font-size: 1.125rem;
    font-weight: 700;
    text-align: center;
}

.target-card-content {
    padding: 2rem;
}


.chart-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    padding: 2rem;
}

.chart-wrapper {
    position: relative;
    width: 100%;
    max-width: 350px;
    height: 350px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
}


.achievement-container {
    text-align: center;
    padding: 2rem;
}

.achievement-display {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(37, 99, 235, 0.1));
    border-radius: var(--radius-xl);
    padding: 3rem 2rem;
    border: 1px solid rgba(16, 185, 129, 0.2);
    position: relative;
    overflow: hidden;
}

.achievement-display::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.progress-container {
    width: 100%;
    max-width: 400px;
    margin: 0 auto 2rem auto;
    position: relative;
}

.progress-track {
    width: 100%;
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    border-radius: 4px;
    transition: width 2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: progress-shine 2s infinite;
}

@keyframes progress-shine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.achievement-amount {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--secondary-color);
    margin-bottom: 1rem;
    font-family: 'Inter', monospace;
}

.achievement-label {
    font-size: 1.125rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 1rem;
}

.achievement-percentage {
    font-size: 1.25rem;
    color: var(--secondary-color);
    font-weight: 700;
}


.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: var(--text-muted);
    gap: 1rem;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error {
    text-align: center;
    padding: 3rem;
    color: var(--danger-color);
    background: rgba(239, 68, 68, 0.1);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(239, 68, 68, 0.2);
}


.footer {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-light);
    margin-top: 4rem;
    padding: 2.5rem 0 1.5rem;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 2rem;
    margin-bottom: 1.5rem;
    align-items: start;
}

.footer-info {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-company-title {
    color: var(--text-primary);
    margin: 0;
    font-weight: 600;
    font-size: 1.25rem;
    line-height: 1.3;
}

.footer-description {
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
    font-size: 0.9rem;
    max-width: 400px;
}

.footer-navigation {
    margin-top: 0.5rem;
}

.footer-nav-title {
    color: var(--text-primary);
    margin: 0 0 0.6rem 0;
    font-weight: 600;
    font-size: 0.95rem;
}

.footer-nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem 1.2rem;
}

.footer-logo {
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
}

.footer-logo-container {
    display: inline-block;
    transition: all 0.3s ease;
    padding: 0.4rem;
    border-radius: var(--radius-lg);
}

.footer-logo-container:hover {
    transform: scale(1.05);
    background: rgba(37, 99, 235, 0.1);
}

.footer-logo-img {
    height: 55px;
    width: auto;
}

/* Desktop only - larger footer logo */
@media (min-width: 1025px) {
    .footer-logo-img {
        height: 80px;
    }
}

.footer-bottom {
    border-top: 1px solid var(--border-light);
    padding-top: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.license-info {
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
}

.copyright {
    color: var(--text-muted);
    font-size: 0.875rem;
}


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

.fade-in-up {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Additional mobile styles for very small screens */
@media (max-width: 480px) {
    .container {
        padding: 1rem 0.75rem;
        margin-top: 2.5rem;
    }
    
    .header-compact {
        margin-top: 4rem;
        margin-left: auto;
        margin-right: auto;
        max-width: 800px;
        width: calc(100% - 0.1rem);
        padding: 1.25rem 0.75rem 1rem;
        min-height: auto;
    }
    
    .header-compact .logo-img-compact {
        height: 50px;
    }
    
    .header-compact .page-title-compact {
        font-size: 1.25rem;
        margin-bottom: 0.75rem;
    }
    
    .header-compact .page-description {
        font-size: 0.85rem;
        padding: 0 0.25rem;
    }
}

.target-analysis-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.money-achievement-wide {
    grid-column: 1 / -1;
    width: 100%;
    max-width: 100%;
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-xl);
    padding: 2.5rem 2rem 2rem 2rem;
    margin: 0 auto 1rem auto;
}


@media (max-width: 1024px) {
    .container {
        padding: 2rem 1.5rem;
    }

    .target-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid.target-analysis-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }

    .money-achievement-wide {
        padding: 2rem 1rem 1.5rem 1rem;
    }
}

@media (max-width: 1024px) {
    .mobile-menu {
        display: flex;
    }

    .nav-container {
        padding: 0 1rem;
    }

    .container {
        padding: 1.5rem 1rem;
        margin-top: 2rem;
    }

    .header {
        margin-bottom: 3rem;
    }

    .header-compact {
        margin-top: 3rem;
        margin-bottom: 2rem;
        margin-left: auto;
        margin-right: auto;
        max-width: 800px;
        width: calc(100% - 0.15rem);
        padding: 1.5rem 1rem 1rem;
    }

    .header-compact .logo-img-compact {
        height: 60px;
    }

    .header-compact .page-title-compact {
        font-size: 1.5rem;
    }

    .header-compact .page-description {
        font-size: 0.9rem;
        padding: 0 0.5rem;
    }

    .logo-img {
        height: 100px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .target-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .data-table th,
    .data-table td {
        padding: 0.5rem 0.25rem;
        font-size: 0.75rem;
    }

    .data-table th:first-child,
    .data-table td:first-child {
        min-width: 60px;
    }

    .data-table th:nth-child(2),
    .data-table td:nth-child(2) {
        min-width: 150px;
        left: 60px;
    }

    .footer {
        margin-top: 3rem;
        padding: 2rem 0 1.5rem;
    }

    .footer-container {
        padding: 0 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        text-align: center;
    }

    .footer-info {
        order: 2;
    }

    .footer-logo {
        order: 1;
        justify-content: center;
    }

    .footer-company-title {
        font-size: 1.1rem;
    }

    .footer-description {
        font-size: 0.85rem;
        max-width: none;
    }

    .footer-nav-title {
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
    }

    .footer-nav-links {
        justify-content: center;
        gap: 0.6rem 1rem;
    }

    .footer-nav-link {
        font-size: 0.8rem;
    }

    .footer-bottom {
        padding-top: 1.25rem;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .target-analysis-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .money-achievement-wide {
        padding: 1.5rem 0.5rem 1rem 0.5rem;
    }
    .stat-value {
        font-size: 2rem;
        word-break: break-all;
        max-width: 100%;
        overflow-wrap: anywhere;
        letter-spacing: -1px;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 0.5rem;
    }

    .footer {
        margin-top: 2.5rem;
        padding: 1.5rem 0 1rem;
    }

    .footer-container {
        padding: 0 0.8rem;
    }

    .footer-content {
        gap: 1.2rem;
    }

    .footer-company-title {
        font-size: 1rem;
    }

    .footer-description {
        font-size: 0.8rem;
        line-height: 1.4;
    }

    .footer-nav-title {
        font-size: 0.85rem;
        margin-bottom: 0.4rem;
    }

    .footer-nav-links {
        gap: 0.5rem 0.8rem;
    }

    .footer-nav-link {
        font-size: 0.75rem;
        padding: 0.2rem 0;
    }

    .footer-logo-img {
        height: 50px;
    }

    .footer-bottom {
        padding-top: 1rem;
    }

    .license-info {
        font-size: 0.75rem;
    }

    .container {
        padding: 1rem 0.5rem;
    }

    .data-table th:first-child,
    .data-table td:first-child {
        min-width: 50px;
    }

    .data-table th:nth-child(2),
    .data-table td:nth-child(2) {
        min-width: 120px;
        left: 50px;
    }

    .stat-card,
    .target-card-content,
    .achievement-container {
        padding: 1.5rem;
    }
}

.stat-value {
    word-break: break-all;
    overflow-wrap: anywhere;
    max-width: 100%;
}

/* Simple Table Styles - Mobile Friendly */
.simple-table-section {
    margin: 2rem 0;
    padding: 0; /* Remove padding from section */
    display: flex;
    justify-content: center;
}

.simple-table-outer-container {
    max-width: 1800px; /* Match total-expense-container and other major containers */
    width: 100%;
    margin: 0 auto;
    padding: 0 2rem; /* Side padding for PC - matches total-expense-container */
}

.simple-table-container {
    width: 100%;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.simple-table-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    padding: 2rem 3rem; /* More generous padding on PC */
    border-bottom: 1px solid var(--border-color);
}

.simple-table-header h3 {
    color: white;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
    text-align: center;
}

.simple-table-content {
    padding: 0;
}

.simple-loading, .simple-error {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    gap: 1rem;
    color: var(--text-secondary);
    font-size: 1rem;
}

.simple-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.simple-error {
    color: var(--danger-color);
}

.simple-table-wrapper {
    overflow-x: auto;
    max-height: 600px;
    overflow-y: auto;
}

.simple-table {
    width: 100%;
    min-width: 100%; /* Ensure table takes full width */
    table-layout: auto; /* Let content size naturally but expand to full width */
    border-collapse: collapse;
    font-size: 0.9rem;
}

.simple-table th {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-weight: 600;
    padding: 1.2rem 1.5rem; /* More generous padding on desktop */
    text-align: left;
    border-bottom: 2px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 10;
    white-space: nowrap; /* Prevent header wrapping */
}

.simple-table td {
    padding: 1rem 1.5rem; /* More generous padding on desktop */
    border-bottom: 1px solid var(--border-light);
    color: var(--text-secondary);
    vertical-align: middle;
    white-space: nowrap; /* Prevent cell wrapping for better desktop presentation */
}

.simple-table tbody tr {
    transition: background-color 0.2s ease;
}

.simple-table tbody tr:hover {
    background-color: rgba(37, 99, 235, 0.03);
}

.simple-table tbody tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.02);
}

/* Mobile Responsive for Simple Table */
@media (max-width: 1024px) {
    .simple-table-section {
        margin: 1.5rem 0;
    }
    
    .simple-table-outer-container {
        width: calc(100% - 1rem); /* Less margin on mobile */
        padding: 0 0.5rem;
    }
    
    .simple-table-header {
        padding: 1rem 1.5rem;
    }
    
    .simple-table-header h3 {
        font-size: 1.25rem;
    }
    
    .simple-table {
        font-size: 0.8rem;
        min-width: auto; /* Remove min-width constraint on mobile */
    }
    
    .simple-table th,
    .simple-table td {
        padding: 0.75rem 0.5rem;
        white-space: normal; /* Allow wrapping on mobile */
    }
    
    .simple-loading, .simple-error {
        padding: 2rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .simple-table-outer-container {
        width: calc(100% - 0.5rem); /* Minimal margin on smallest screens */
        padding: 0 0.25rem;
    }
    
    .simple-table-header {
        padding: 0.75rem 1rem;
    }
    
    .simple-table-header h3 {
        font-size: 1.1rem;
    }
    
    .simple-table {
        font-size: 0.75rem;
        min-width: auto; /* Remove min-width constraint on smallest screens */
    }
    
    .simple-table th,
    .simple-table td {
        padding: 0.5rem 0.25rem;
        white-space: normal; /* Allow wrapping on smallest screens */
    }
}

/* Total Expense Box Styles */
.total-expense-section {
    margin: 3rem 0 2rem 0;
    display: flex;
    justify-content: center;
}

.total-expense-container {
    max-width: 1800px;
    width: 100%;
    padding: 0 2rem;
}

.total-expense-card {
    background: linear-gradient(135deg, 
        var(--bg-card) 0%, 
        rgba(24, 31, 42, 0.98) 30%,
        rgba(30, 41, 59, 0.95) 70%,
        var(--bg-secondary) 100%);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 3rem;
    box-shadow: 
        var(--shadow-lg),
        0 0 30px rgba(56, 189, 248, 0.05),
        inset 0 1px 0 rgba(203, 213, 225, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.total-expense-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(
        circle at 20% 20%, 
        rgba(56, 189, 248, 0.08) 0%, 
        transparent 50%
    ),
    radial-gradient(
        circle at 80% 80%, 
        rgba(16, 185, 129, 0.06) 0%, 
        transparent 50%
    );
    pointer-events: none;
    z-index: 0;
}

.total-expense-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-color), var(--secondary-color));
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    z-index: 1;
}

.total-expense-card:hover {
    transform: translateY(-4px);
    box-shadow: 
        var(--shadow-xl),
        0 0 40px rgba(56, 189, 248, 0.1),
        inset 0 1px 0 rgba(203, 213, 225, 0.15);
    border-color: rgba(244, 114, 182, 0.2);
}

/* Light Mode - Apple Liquid Glass Total Expense Card */
[data-theme="light"] .total-expense-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 12px 40px -8px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(255, 255, 255, 0.95) inset,
        0 2px 6px rgba(255, 255, 255, 0.35) inset;
}

[data-theme="light"] .total-expense-card::before {
    background: radial-gradient(
        circle at 20% 20%, 
        rgba(37, 99, 235, 0.08) 0%, 
        transparent 50%
    ),
    radial-gradient(
        circle at 80% 80%, 
        rgba(16, 185, 129, 0.06) 0%, 
        transparent 50%
    );
}

[data-theme="light"] .total-expense-card:hover {
    box-shadow: 
        var(--shadow-xl),
        0 0 40px rgba(37, 99, 235, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.7);
    border-color: rgba(37, 99, 235, 0.25);
}

.expense-achievement-label {
    font-size: 1.125rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
}

.expense-achievement-amount {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    background: linear-gradient(135deg, var(--text-primary), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    font-family: 'Inter', monospace;
    position: relative;
    z-index: 2;
}

.expense-achievement-subtitle {
    font-size: 1.125rem;
    color: var(--text-muted);
    font-weight: 600;
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.expense-achievement-subtitle::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--accent-color);
    border-radius: 50%;
    opacity: 0.7;
}

.expense-loading {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    color: var(--text-secondary);
    position: relative;
    z-index: 2;
}

.expense-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--border-light);
    border-top: 3px solid var(--secondary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}



/* Mobile Responsive */
@media (max-width: 1024px) {
    .total-expense-container {
        padding: 0 0.075rem;
        max-width: 1800px;
        width: calc(100% - 0.0015rem);
    }
    
    .total-expense-card {
        padding: 2rem 1.5rem;
    }
    
    .expense-achievement-amount {
        font-size: clamp(1.8rem, 4vw, 2.5rem);
    }
    
    .expense-achievement-label {
        font-size: 1rem;
        margin-bottom: 1.25rem;
    }
    
    .expense-achievement-subtitle {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .total-expense-section {
        margin: 1.5rem 0 2.5rem 0;
    }
    
    .total-expense-container {
        padding: 0 0.04rem;
        max-width: 1800px;
        width: calc(100% - 0.0008rem);
    }
    
    .total-expense-card {
        padding: 1.5rem;
    }
    
    .expense-achievement-amount {
        font-size: clamp(1.5rem, 4vw, 2rem);
        margin-bottom: 0.75rem;
    }
    
    .expense-achievement-label {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
    
    .expense-achievement-subtitle {
        font-size: 0.9rem;
    }
}

/* Loading Screen Styles - Modern Design */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(135deg, var(--bg-primary) 0%, #0c1426 50%, var(--bg-primary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.8s ease-out, visibility 0.8s ease-out;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

/* Light Mode - Apple Glass Loading Screen */
[data-theme="light"] .loading-screen {
    background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf3 50%, #f5f7fa 100%);
    position: relative;
}

[data-theme="light"] .loading-screen::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(circle at 30% 30%, rgba(99, 102, 241, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(139, 92, 246, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(59, 130, 246, 0.06) 0%, transparent 50%);
    pointer-events: none;
    animation: liquidShiftLoading 15s ease-in-out infinite;
}

@keyframes liquidShiftLoading {
    0%, 100% { 
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
    50% { 
        opacity: 0.8;
        transform: scale(1.1) rotate(5deg);
    }
}

.loading-container {
    text-align: center;
    position: relative;
    padding: 3rem;
    background: transparent;
    border-radius: var(--radius-2xl);
}

/* Light Mode - Glass Container */
[data-theme="light"] .loading-container {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 20px 60px -10px rgba(0, 0, 0, 0.15),
        0 0 0 1px rgba(255, 255, 255, 0.95) inset,
        0 4px 12px rgba(255, 255, 255, 0.4) inset;
}

.logo-container {
    position: relative;
    display: inline-block;
    margin-bottom: 3rem;
}

.loading-logo {
    height: 140px;
    width: auto;
    position: relative;
    z-index: 2;
    animation: logoFloat 3s ease-in-out infinite;
    filter: drop-shadow(0 10px 20px rgba(56, 189, 248, 0.1));
}

[data-theme="light"] .loading-logo {
    filter: drop-shadow(0 10px 30px rgba(99, 102, 241, 0.2));
}

.loading-pulse {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulseGlow 2s ease-in-out infinite;
}

[data-theme="light"] .loading-pulse {
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.08) 50%, transparent 70%);
}

.loading-content {
    position: relative;
}

.loading-text {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
    animation: textGlow 2s ease-in-out infinite alternate;
}

[data-theme="light"] .loading-text {
    color: #1e293b;
    text-shadow: 0 2px 8px rgba(99, 102, 241, 0.15);
}

.loading-subtext {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 2rem;
    opacity: 0.8;
}

[data-theme="light"] .loading-subtext {
    color: #64748b;
    opacity: 0.9;
}

.loading-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.loading-dots span {
    width: 12px;
    height: 12px;
    background: var(--secondary-color);
    border-radius: 50%;
    animation: dotBounce 1.4s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.5);
}

[data-theme="light"] .loading-dots span {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.loading-dots span:nth-child(1) { animation-delay: -0.32s; }
.loading-dots span:nth-child(2) { animation-delay: -0.16s; }
.loading-dots span:nth-child(3) { animation-delay: 0s; }

/* Main content hidden by default */
.main-content {
    display: none;
}

.main-content.show {
    display: block;
    animation: fadeInUp 0.6s ease-out;
}

/* Modern Loading Animations */
@keyframes logoFloat {
    0%, 100% {
        transform: translateY(0px) scale(1);
    }
    50% {
        transform: translateY(-10px) scale(1.02);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        opacity: 0.4;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 0.8;
        transform: translate(-50%, -50%) scale(1.1);
    }
}

@keyframes textGlow {
    0% {
        text-shadow: 0 0 20px rgba(56, 189, 248, 0.3);
    }
    100% {
        text-shadow: 0 0 30px rgba(56, 189, 248, 0.6);
    }
}

@keyframes dotBounce {
    0%, 80%, 100% {
        transform: scale(0.8) translateY(0);
        opacity: 0.7;
    }
    40% {
        transform: scale(1.2) translateY(-20px);
        opacity: 1;
    }
}

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

/* PC View - Consistent Box Widths (Documents and Expense pages only) */
@media (min-width: 1025px) {
    /* Apply consistent width only to documents and expense pages, not dashboard */
    body:not([data-page="dashboard"]) .container {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    /* Consistent width for documents and expense page content boxes only */
    body:not([data-page="dashboard"]) .header-compact,
    body:not([data-page="dashboard"]) .table-container {
        max-width: 1800px;
        width: 100%;
        padding-left: 2rem;
        padding-right: 2rem;
        margin-left: auto;
        margin-right: auto;
    }
    
    /* Ensure Total Expense container matches header width exactly (expense page only) */
    body:not([data-page="dashboard"]) .total-expense-section {
        width: 100%;
        display: flex;
        justify-content: center;
    }
    
    body:not([data-page="dashboard"]) .total-expense-container {
        max-width: 1800px !important;
        width: 100% !important;
        padding-left: 2rem !important;
        padding-right: 2rem !important;
        margin-left: auto !important;
        margin-right: auto !important;
        box-sizing: border-box !important;
    }
    
    /* Remove inline styles for table containers on PC (documents and expense pages only) */
    body:not([data-page="dashboard"]) .table-container[style*="max-width: 800px"] {
        max-width: 1800px !important;
        margin: 0 auto 4rem auto !important;
    }
}

/* Mobile width adjustments - override PC view for expense page */
@media (max-width: 1024px) {
    /* Reset expense page boxes to match document page mobile width */
    body[data-page="expense"] .header-compact,
    body[data-page="expense"] .table-container,
    body[data-page="expense"] .total-expense-container {
        max-width: 800px !important;
        width: calc(100% - 0.15rem) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    body[data-page="expense"] .header-compact {
        width: calc(100% - 0.15rem) !important;
        padding: 1.5rem 1rem 1rem !important;
    }
    
    body[data-page="expense"] .total-expense-section {
        margin: 3rem 0 2rem 0;
        display: flex;
        justify-content: center;
    }
    
    body[data-page="expense"] .total-expense-container {
        width: calc(100% - 0.075rem) !important;
        padding: 0 0.075rem !important;
    }
}

@media (max-width: 480px) {
    /* Smaller mobile devices - match document page sizing exactly */
    body[data-page="expense"] .header-compact,
    body[data-page="expense"] .table-container,
    body[data-page="expense"] .total-expense-container {
        max-width: 800px !important;
        width: calc(100% - 0.1rem) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0.75rem !important;
        padding-right: 0.75rem !important;
    }
    
    body[data-page="expense"] .header-compact {
        width: calc(100% - 0.1rem) !important;
        padding: 1.25rem 0.75rem 1rem !important;
    }
    
    body[data-page="expense"] .total-expense-container {
        width: calc(100% - 0.04rem) !important;
        padding: 0 0.04rem !important;
    }
}

/* Mobile adjustments for loading screen */
@media (max-width: 1024px) {
    .loading-logo {
        height: 120px;
    }
    
    .loading-pulse {
        width: 160px;
        height: 160px;
    }
    
    .loading-text {
        font-size: 1.3rem;
        letter-spacing: 1px;
    }
    
    .loading-subtext {
        font-size: 0.9rem;
        padding: 0 2rem;
    }
    
    .loading-dots span {
        width: 10px;
        height: 10px;
    }
}

/* Expense Table Specific Styles - Fixed layout, no scrolling */
.expense-table {
    width: 100%;
    table-layout: fixed; /* Fixed layout prevents overflow */
    border-collapse: collapse;
    margin: 0 auto; /* Center the table */
}

/* Prevent any scrolling for expense table */
body[data-page="expense"] .table-wrapper {
    overflow: hidden; /* No horizontal or vertical scrolling */
    max-width: 100%;
}

.expense-table th,
.expense-table td {
    position: static; /* Remove sticky positioning */
    padding: 0.75rem 0.5rem;
    text-align: center;
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Break long words */
    overflow: hidden; /* Hide any overflow */
    vertical-align: middle; /* Center content vertically */
}

/* Column width specifications - All fixed to fit within container */
.expense-table th:first-child,
.expense-table td:first-child {
    width: 15%; /* 70% smaller: 50% - 35% = 15% */
    text-align: center;
    font-weight: 600;
}

.expense-table th:nth-child(2),
.expense-table td:nth-child(2) {
    width: 55%; /* Larger middle column for main content */
    text-align: left;
}

.expense-table th:nth-child(3),
.expense-table td:nth-child(3) {
    width: 30%; /* Balanced third column */
    text-align: center; /* Center instead of right to prevent overflow */
    font-weight: 600;
}

/* Additional measures to prevent horizontal scrolling */
.expense-table * {
    box-sizing: border-box !important;
}

body[data-page="expense"] .table-container {
    overflow: hidden !important;
    max-width: 100vw !important; /* Never exceed viewport width */
    padding: 0 !important; /* Remove any padding that causes overflow */
}

body[data-page="expense"] .data-table {
    margin: 0 !important;
    border: none !important;
}

/* Mobile viewport constraints for expense page */
@media (max-width: 1024px) {
    body[data-page="expense"] {
        overflow-x: hidden !important; /* Hide any horizontal overflow */
        width: 100vw !important; /* Full viewport width */
    }
    
    body[data-page="expense"] .container {
        max-width: 100vw !important;
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        box-sizing: border-box !important;
    }
}

@media (max-width: 480px) {
    body[data-page="expense"] {
        overflow-x: hidden !important;
        width: 100vw !important;
    }
    
    body[data-page="expense"] * {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
}

/* Mobile specific adjustments for expense table - all columns visible */
@media (max-width: 1024px) {
    body[data-page="expense"] .table-wrapper {
        overflow: hidden; /* Ensure no overflow on mobile */
        padding: 0; /* Remove any padding that might cause overflow */
        width: 100%;
        margin: 0;
    }
    
    .expense-table {
        width: 100%; /* Ensure table takes full width */
        max-width: 100%; /* Never exceed container */
        margin: 0;
        border-spacing: 0;
    }
    
    .expense-table th,
    .expense-table td {
        padding: 0.4rem 0.1rem; /* Minimal padding for mobile */
        font-size: 0.7rem; /* Smaller font for mobile */
        box-sizing: border-box; /* Include padding in width calculation */
        text-align: left !important; /* All content left-aligned */
        white-space: normal; /* Allow text wrapping */
        word-wrap: break-word; /* Break long words */
        line-height: 1.2; /* Tighter line height */
    }
    
    .expense-table th:first-child,
    .expense-table td:first-child {
        width: 20%; /* Readable first column */
        font-size: 0.65rem;
        padding: 0.4rem 0.05rem; /* Minimal padding */
        text-align: left !important;
    }
    
    .expense-table th:nth-child(2),
    .expense-table td:nth-child(2) {
        width: 45%; /* Main content column */
        font-size: 0.7rem;
        padding: 0.4rem 0.1rem;
        text-align: left !important;
    }
    
    .expense-table th:nth-child(3),
    .expense-table td:nth-child(3) {
        width: 35%; /* Third column with adequate space */
        font-size: 0.7rem;
        padding: 0.4rem 0.05rem; /* Minimal padding */
        text-align: left !important; /* Changed from center to left */
    }
}

@media (max-width: 480px) {
    body[data-page="expense"] .container {
        padding: 0.5rem !important; /* Minimal container padding */
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }
    
    body[data-page="expense"] .table-container {
        padding: 0; /* Remove container padding */
        margin: 0; /* Remove any margins */
        width: 100%;
        max-width: 100%;
    }
    
    body[data-page="expense"] .table-wrapper {
        overflow: hidden; /* Force no overflow */
        width: 100%; /* Full width */
        max-width: 100%; /* Never exceed container width */
        padding: 0;
        margin: 0;
    }
    
    .expense-table {
        width: 100%; /* Full table width */
        max-width: 100%; /* Never exceed container */
        border-spacing: 0; /* Remove any border spacing */
        table-layout: fixed; /* Force fixed layout */
    }
    
    .expense-table th,
    .expense-table td {
        padding: 0.3rem 0.05rem; /* Ultra minimal padding for smallest screens */
        font-size: 0.65rem; /* Very small font */
        box-sizing: border-box; /* Include padding in width */
        text-align: left !important; /* All content left-aligned */
        white-space: normal; /* Allow text wrapping */
        word-wrap: break-word; /* Break long words */
        line-height: 1.1; /* Very tight line height */
        overflow: hidden; /* Hide any overflow content */
    }
    
    .expense-table th:first-child,
    .expense-table td:first-child {
        width: 25%; /* Adequate space for first column */
        font-size: 0.6rem; /* Extra small font */
        padding: 0.3rem 0.03rem; /* Ultra minimal padding */
        text-align: left !important;
    }
    
    .expense-table th:nth-child(2),
    .expense-table td:nth-child(2) {
        width: 40%; /* Main content area */
        font-size: 0.65rem;
        padding: 0.3rem 0.05rem;
        text-align: left !important;
    }
    
    .expense-table th:nth-child(3),
    .expense-table td:nth-child(3) {
        width: 35%; /* Third column with proper space */
        font-size: 0.65rem;
        padding: 0.3rem 0.03rem; /* Ultra minimal padding */
        text-align: left !important; /* Left-aligned for consistency */
    }
}