﻿/* ========================================
   CSS CUSTOM PROPERTIES (CSS VARIABLES)
   ======================================== */
:root {
    /* Color Palette */
    --bg: 248, 249, 250;
    --l-gray: 233, 236, 239;
    --white: 252, 252, 252;
    --primary: 74, 105, 189;
    --accent: 224, 122, 95;
    --border: 206, 212, 218;
    --success: 46, 204, 113;
    --warning: 255, 193, 7;
    --error: 220, 53, 69;
    
    /* Video Editing Theme Colors */
    --timeline-blue: 66, 153, 225;
    --playback-green: 72, 187, 120;
    --render-purple: 159, 122, 234;
    --warning-amber: 251, 191, 36;
    
    /* Gradients */
    --l-g-regular: linear-gradient(135deg, rgba(var(--primary), 0.85), rgba(var(--primary), 0.65), rgba(var(--success), 0.5));
    --l-g-regular-op: linear-gradient(135deg, rgba(var(--primary), 0.15), rgba(var(--success), 0.05), rgba(var(--accent), 0.05));
    --l-g-primary: linear-gradient(135deg, rgba(var(--primary), 0.9) 0%, rgb(var(--primary)) 100%);
    --l-g-primary-op: linear-gradient(135deg, rgba(var(--primary), 0.2) 0%, rgb(var(--primary),.1) 100%);
    --l-g-success: linear-gradient(135deg, rgb(var(--success)), rgba(var(--success), 0.7));
    --l-g-warning: linear-gradient(135deg, rgb(var(--warning)), rgba(var(--warning), 0.7));
    --l-g-error: linear-gradient(135deg, rgb(var(--error)), rgba(var(--error), 0.7));
    
    /* Auth Page Gradients */
    --auth-gradient-primary: linear-gradient(135deg, rgba(var(--primary), 0.08) 0%, rgba(var(--accent), 0.05) 50%, rgba(var(--success), 0.03) 100%);
    --auth-gradient-accent: linear-gradient(135deg, rgba(var(--timeline-blue), 0.1) 0%, rgba(var(--render-purple), 0.08) 100%);
    
    /* Text Colors */
    --text: 33, 37, 41;
    --l-text: 108, 117, 125;
    --w-text: 250, 250, 250;
    
    /* Typography - Fluid Scale */
    --font: 'Inter', serif;
    --fs-xxl: clamp(5rem, 8vw + 1rem, 8rem);
    --fs-xl: clamp(4rem, 6vw + 1rem, 6rem);
    --fs-l: 3.5rem;
    --fs-m: 1.8rem;
    --fs-m-sm: 1.5rem;
    --fs-reg: 1.125rem;
    --fs-small: .7rem;
    
    /* Fluid Typography Scale for Auth Pages */
    --font-size-xs: clamp(12px, 2.5vw, 14px);
    --font-size-sm: clamp(14px, 3vw, 16px);
    --font-size-base: clamp(16px, 3.5vw, 18px);
    --font-size-lg: clamp(18px, 4vw, 22px);
    --font-size-xl: clamp(24px, 5vw, 32px);
    --font-size-2xl: clamp(32px, 7vw, 48px);
    --font-size-3xl: clamp(48px, 10vw, 72px);
    --font-size-error-code: clamp(72px, 15vw, 120px);
    
    /* Font Weights */
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800;
    --font-weight-black: 900;
    
    /* Line Heights */
    --line-height-tight: 1.2;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.6;
    
    /* Spacing Scale (4px base unit) */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-7: 28px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    --space-14: 56px;
    --space-16: 64px;
    --space-20: 80px;
    --space-24: 96px;
    
    /* Border Radius */
    --radius-xs: 4px;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 20px;
    --radius-3xl: 24px;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
    --shadow-2xl: 0 25px 50px rgba(0, 0, 0, 0.25);
    --shadow-inner: inset 0 2px 4px rgba(0, 0, 0, 0.06);
    
    /* Colored Shadows */
    --shadow-primary: 0 8px 24px rgba(var(--primary), 0.35);
    --shadow-primary-sm: 0 4px 12px rgba(var(--primary), 0.25);
    --shadow-error: 0 8px 24px rgba(var(--error), 0.35);
    --shadow-success: 0 8px 24px rgba(var(--success), 0.35);
    --shadow-warning: 0 8px 24px rgba(var(--warning), 0.35);
    
    /* Transitions and Effects */
    --transition-fast: all 0.2s ease;
    --transition-normal: all 0.3s ease;
    --transition-slow: all 0.4s ease;
    --transition-bounce: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-hover: 0 4px 12px rgba(var(--primary), 0.15), 0 2px 6px rgba(var(--primary), 0.1);
    
    /* Animation Timing */
    --duration-fast: 150ms;
    --duration-normal: 300ms;
    --duration-slow: 500ms;
    --duration-slower: 800ms;
    
    /* Easing Functions */
    --ease-in: cubic-bezier(0.4, 0, 1, 1);
    --ease-out: cubic-bezier(0, 0, 0.2, 1);
    --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
    
    /* Additional Light Mode Specific */
    --shadow-soft: 0 8px 32px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04);
    --shadow-medium: 0 12px 40px rgba(0, 0, 0, 0.08), 0 6px 20px rgba(0, 0, 0, 0.05);
    --shadow-strong: 0 24px 64px rgba(0, 0, 0, 0.12), 0 12px 32px rgba(0, 0, 0, 0.08);
}

/* ========================================
   DARK THEME VARIABLES
   ======================================== */
[data-theme="dark"] {
    /* Color Palette - Dark Mode */
    --bg: 36, 36, 36;
    --l-gray: 35, 39, 42;
    --white: 70, 72, 74;
    --primary: 96, 125, 209;
    --accent: 244, 142, 115;
    --border: 55, 65, 81;
    --success: 74, 222, 128;
    --warning: 251, 191, 36;
    --error: 239, 68, 68;
    
    /* Video Editing Theme Colors - Dark Mode */
    --timeline-blue: 96, 165, 250;
    --playback-green: 96, 205, 144;
    --render-purple: 179, 146, 255;
    --warning-amber: 252, 211, 77;

    /* Gradients - Adjusted for Dark Mode */
    --l-g-regular: linear-gradient(135deg, rgba(var(--primary), 0.9), rgba(var(--primary), 0.7), rgba(var(--success), 0.6));
    --l-g-primary: linear-gradient(135deg, rgba(var(--primary), 0.95) 0%, rgb(var(--primary)) 100%);
    --l-g-success: linear-gradient(135deg, rgb(var(--success)), rgba(var(--success), 0.8));
    --l-g-warning: linear-gradient(135deg, rgb(var(--warning)), rgba(var(--warning), 0.8));
    --l-g-error: linear-gradient(135deg, rgb(var(--error)), rgba(var(--error), 0.8));
    
    /* Auth Page Gradients - Dark Mode */
    --auth-gradient-primary: linear-gradient(135deg, rgba(var(--primary), 0.12) 0%, rgba(var(--accent), 0.08) 50%, rgba(var(--success), 0.05) 100%);
    --auth-gradient-accent: linear-gradient(135deg, rgba(var(--timeline-blue), 0.15) 0%, rgba(var(--render-purple), 0.12) 100%);

    /* Text Colors - Dark Mode */
    --text: 226, 232, 240;
    --l-text: 198, 193, 194;
    --w-text: 250, 250, 250;
    
    /* Shadows - Dark Mode (deeper, more pronounced) */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.45);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.5);
    --shadow-2xl: 0 25px 50px rgba(0, 0, 0, 0.6);
    --shadow-soft: 0 8px 32px rgba(0, 0, 0, 0.25), 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-medium: 0 12px 40px rgba(0, 0, 0, 0.3), 0 6px 20px rgba(0, 0, 0, 0.2);
    --shadow-strong: 0 24px 64px rgba(0, 0, 0, 0.4), 0 12px 32px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 4px 12px rgba(var(--primary), 0.3), 0 2px 6px rgba(var(--primary), 0.2);
    --shadow-primary: 0 8px 24px rgba(var(--primary), 0.45);
    --shadow-primary-sm: 0 4px 12px rgba(var(--primary), 0.35);
    --shadow-error: 0 8px 24px rgba(var(--error), 0.45);
    --shadow-success: 0 8px 24px rgba(var(--success), 0.45);
    --shadow-warning: 0 8px 24px rgba(var(--warning), 0.45);
}

/* ========================================
   RESET AND BASE STYLES
   ======================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Responsive viewport setup - ensures proper scaling */
html {
    /* Note: Ensure <meta name="viewport" content="width=device-width, initial-scale=1.0"> is in HTML */
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

/* Theme Transition Support */
html {
    transition: background-color 0.3s ease;
    position: relative;
}

/* Theme transition overlay for smooth visual feedback */
html.theme-transitioning::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, 
                rgba(var(--primary), 0.05) 0%, 
                transparent 70%);
    pointer-events: none;
    z-index: 9998;
    animation: themeTransitionPulse 0.35s ease-in-out;
}

@keyframes themeTransitionPulse {
    0% { opacity: 0; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1.05); }
}

body {
    position: relative;
    font-family: var(--font), -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    color: rgb(var(--l-text));
    background: rgba(var(--bg), 1);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    min-width: 1024px;
    overflow-x: auto;
}

/* Theme-aware color transitions for all elements */
* {
    transition-property: background-color, border-color, color, box-shadow, fill, stroke;
    transition-duration: 0.3s;
    transition-timing-function: ease;
}

/* Enhanced transitions during theme switching */
html.theme-transitioning * {
    transition-property: background-color, border-color, color, box-shadow, fill, stroke, opacity !important;
    transition-duration: 0.35s !important;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Preserve specific transitions that should not be overridden */
.spinner,
.loading-placeholder::before,
.alert,
[class*="animation-"],
[class*="animate-"] {
    transition: initial !important;
}

/* ========================================
   TYPOGRAPHY
   ======================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: bold;
    font-family: var(--font);
    color: rgb(var(--text));
}

ul {
    list-style-type: none;
}

a {
    color: inherit;
    outline: none;
    text-decoration: none;
}

a.link {
    color: rgba(var(--primary), 0.8);
    cursor: pointer;
    font-style: italic;
    transition: color 0.3s ease-in-out;
}

a.link:hover {
    color: rgb(var(--primary));
}

img {
    object-fit: contain;
    width: 100%;
}

/* ========================================
   LAYOUT COMPONENTS
   ======================================== */
.block-ln {
    display: block;
    width: 100%;
}

.dashboard-container {
    position: relative;
    width: calc(100% - 270px);
    min-width: 1600px;
    height: fit-content;
    margin: 0 auto 300px auto;
    padding: 20px 20px 0 290px;
    transition: all 0.3s ease;
}

.nav-collapsed .dashboard-container {
    padding: 20px 20px 0 90px;
    width: calc(100% - 70px);
    min-width: 954px; /* 1024px viewport - 70px collapsed nav */
}

/* ========================================
   HEADER COMPONENTS
   ======================================== */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0 12px 0;
    margin-bottom: 24px;
    border-bottom: 1px solid rgb(var(--border));
    animation: headerSlideDown 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.dashboard-header h1,
.details-header h2,
.table-container .table-header h1 {
    margin-bottom: 12px;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    background: var(--l-g-regular);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

@keyframes headerSlideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   CARD COMPONENTS
   ======================================== */
.card {
    margin: 24px 0;
    padding: 20px;
    background: rgba(var(--white), 0.95);
    border: 1px solid rgba(var(--border), 0.15);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.card-title {
    margin-bottom: 12px;
    font-size: clamp(1.5rem, 3vw, 2.4rem);
    font-weight: 700;
    background: rgb(var(--text), .3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.card-title small {
    font-size: .9rem;
    color: rgba(var(--l-text), .6);
}

.card-heading-block {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid rgb(var(--border));
    padding-bottom: 8px;
    margin-bottom: 12px;
}

.card-heading-block .card-title {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.card-heading-block > div {
    display: flex;
    gap: 12px;
    align-items: center;
}

.max-width-1200 {
    max-width: 1200px;
}

/* ========================================
   BUTTON COMPONENTS
   ======================================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    outline:none;
    border:none;
    background-color: rgb(var(--l-gray));
    border-radius: 4px;
    color: rgb(var(--l-text));
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.4s ease;
}

.btn:hover {
    background-color: rgba(var(--primary), .3);
}

/* Button Variants */
    .btn.btn-red {
        background: rgba(var(--error), .3);
        color: rgba(var(--error));
    }

        .btn.btn-red:hover {
            background: rgba(var(--error), .4);
        }

.btn.btn-green {
    background: rgba(var(--success), .2);
}

.btn.btn-primary {
    background: rgba(var(--primary), .8);
    color: rgb(var(--w-text));
}

    .btn.btn-primary:hover {
        background: rgba(var(--primary));
    }

/* Main Button Component */
.main-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    background: var(--l-g-primary);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.3), 0 2px 4px rgba(var(--primary), 0.2);
    border: none;
    border-radius: 12px;
    color: rgb(var(--w-text));
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    min-width: 160px;
}

.main-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(var(--w-text), 0.2) 50%, transparent 100%);
    transition: left 0.5s ease;
}

.main-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(var(--primary), 0.4), 0 4px 8px rgba(var(--primary), 0.3);
}

.main-btn:hover::before {
    left: 100%;
}

.main-btn i {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.main-btn.btn-secondary {
    background: linear-gradient(135deg, rgba(var(--l-gray), 0.8) 0%, rgba(var(--l-gray), 0.6) 100%);
    box-shadow: 0 4px 12px rgba(var(--text), 0.1), 0 2px 4px rgba(var(--text), 0.05);
    color: rgb(var(--l-text));
}

    .main-btn.disabled {
        position: relative;
        background: rgba(var(--l-text),.4);
        cursor: help;
        overflow: visible;
    }

        .main-btn.disabled {
            position: relative;
            background: rgba(var(--l-text),.4);
            cursor: help;
            overflow: visible;
            isolation: isolate;
        }

        .main-btn.disabled .small-btn-text {
            position: absolute;
            display: none;
            width: 240px;
            right: calc(100% + 12px);
            top: 50%;
            transform: translateY(-50%);
            padding: .5rem 1rem;
            border-radius: 12px;
            text-align: center;
            font-size: .7rem;
            color: rgba(var(--white));
            background-color: rgba(var(--primary),.6);
            z-index: 10000;
            pointer-events: none;
            white-space: normal;
            line-height: 1.4;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
            opacity: 0;
            transition: opacity 0.15s ease 0.1s, visibility 0.15s ease 0.1s;
            visibility: hidden;
        }
            .main-btn.disabled:before {
                display: none;
            }
            .main-btn.disabled:hover .small-btn-text {
                display: block;
                opacity: 1;
                visibility: visible;
            }

        .main-btn.disabled .small-btn-text::after {
            content: '';
            position: absolute;
            left: 100%;
            top: 50%;
            display:block;
            transform: translateY(-50%);
            width: 0;
            height: 0;
            border-top: 6px solid transparent;
            border-bottom: 6px solid transparent;
            border-left: 6px solid rgba(var(--primary),.6);
        }
/* Close/X Button */
.x-btn,
.close-btn {
    padding: 0 4px;
    background: none;
    border: none;
    color: rgb(var(--l-text));
    font-size: 1.8rem;
    line-height: 1;
    cursor: pointer;
    outline: none;
    transition: all 0.2s ease;
}

.x-btn:hover,
.close-btn:hover {
    color: rgb(var(--text));
}

/* Utility Classes */
.table-header {
    display: flex;
    justify-content: space-between;
}

.text-center {
    text-align: center;
}

/* ========================================
   STATISTICS CARDS
   ======================================== */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    width: 100%;
    padding: 8px 0;
}

.stats-container .stat-card {
    position: relative;
    padding: 32px 24px;
    background: rgb(var(--white));
    border: 1px solid rgba(var(--border), 0.2);
    border-radius: 20px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    animation: statCardSlideIn 0.6s ease-out backwards;
}

.stats-container .stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--l-g-regular);
    border-radius: 20px 20px 0 0;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stats-container .stat-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(var(--primary), 0.15), 0 10px 20px rgba(var(--primary), 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    border-color: rgba(var(--primary), 0.3);
}

.stats-container .stat-card:hover::before {
    opacity: 1;
}

/* Animation Delays */
.stats-container .stat-card:nth-child(1) {
    animation-delay: 0.1s;
}

.stats-container .stat-card:nth-child(2) {
    animation-delay: 0.2s;
}

.stats-container .stat-card:nth-child(3) {
    animation-delay: 0.3s;
}

.stats-container .stat-card:nth-child(4) {
    animation-delay: 0.4s;
}

/* Stat Card Content */
.stat-card .stat-value {
    display: block;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 800;
    line-height: 1;
    margin-bottom: 12px;
    background: var(--l-g-regular);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
}

.stats-container .stat-card:hover .stat-value {
    transform: scale(1.1);
}

.stat-card .stat-label {
    font-size: 1rem;
    font-weight: 600;
    color: rgb(var(--l-text), .5);
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.stats-container .stat-card .stat-change {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 20px;
    display: inline-block;
    margin-top: 8px;
}

/* Stat Value Variants */
.stats-container .stat-card .stat-value.positive,
.stat-card.positive .stat-value {
    background: var(--l-g-success);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stats-container .stat-card .stat-value.warning,
.stat-card.warning .stat-value {
    background: var(--l-g-warning) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

.stats-container .stat-card .stat-value.negative,
.stat-card.negative .stat-value,
.stat-card.error .stat-value {
    background: var(--l-g-error) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

/* Stat Change Indicators */
.stat-change.positive {
    background: rgba(var(--success), 0.1);
    color: rgb(var(--success));
    border: 1px solid rgba(var(--success), 0.2);
}

.stat-change.negative {
    background: rgba(var(--error), 0.1);
    color: rgb(var(--error));
    border: 1px solid rgba(var(--error), 0.2);
}

/* Stats Card Header */
.stats-card-header i {
    font-size: 4rem;
    color: rgb(var(--primary));
    margin-bottom: 12px;
    background: rgba(var(--primary), .3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stats-card-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: rgb(var(--l-text));
    margin: 0;
}

.stats-card-body {
    position: relative;
}

.stats-card-body.legacy-format {
    margin-bottom: 12px;
}

/* Progress Bar */
.stat-card .progress-bar-container {
    background: rgba(var(--l-gray), 0.2);
    height: 8px;
    border-radius: 4px;
    position: relative;
    margin-top: 12px;
    overflow: hidden;
}

.stat-card .progress-bar {
    height: 100%;
    background: linear-gradient(135deg, rgba(var(--success), 0.4) 0%, rgba(var(--success), 0.5) 50%, rgb(var(--success)) 100%);
    border-radius: 4px;
    transition: width 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.stat-card .stat-card.warning .progress-bar {
    background: var(--l-g-warning) !important;
}

.stat-card .stat-card.error .progress-bar {
    background: var(--l-g-error) !important;
}

.stat-card .progress-bar-container span {
    position: absolute;
    right: 0;
    top: -18px;
    font-size: 0.8rem;
    color: rgb(var(--l-text));
    opacity: 0.8;
}

/* ========================================
   PILL COMPONENTS (STATUS INDICATORS)
======================================== */
.pill {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-width: 100px;
    padding: 2px 8px;
    border: 1px solid transparent;
    border-radius: 25px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
    cursor: default;
}

.pill::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.2) 50%, transparent 100%);
    transition: left 0.5s ease;
}

.pill:hover::before {
    left: 100%;
}

.pill-small {
    margin: 4px auto;
    font-size: .6rem;
}

/* Priority Pills */
.pill.priority-low {
    background: linear-gradient(135deg, rgba(var(--l-gray), 0.8), rgba(var(--l-gray), 0.6));
    color: rgb(var(--l-text));
    border-color: rgba(var(--l-gray), 0.3);
}

.pill.priority-medium {
    background: linear-gradient(135deg, rgba(var(--primary), 0.2), rgba(var(--primary), 0.1));
    color: rgb(var(--primary));
    border-color: rgba(var(--primary), 0.3);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.15);
}

.pill.priority-high {
    background: linear-gradient(135deg, rgba(var(--error), 0.2), rgba(var(--error), 0.1));
    color: rgb(var(--error));
    border-color: rgba(var(--error), 0.3);
    box-shadow: 0 4px 12px rgba(var(--error), 0.15);
}

.pill.status-blocked,
.pill.priority-urgent {
    background: linear-gradient(135deg, rgb(var(--error)), rgba(var(--error), 0.8));
    color: rgb(var(--w-text));
    border-color: rgb(var(--error));
    box-shadow: 0 4px 16px rgba(var(--error), 0.25);
    animation: urgentPulse 2s infinite ease-in-out;
}

/* Status Pills - Success States */
.pill.status-sent,
.pill.status-billable-true,
.pill.status-approved,
.pill.status-delivered,
.pill.status-active,
.pill.status-paid,
.pill.status-completed {
    background: linear-gradient(135deg, rgba(var(--success), 0.2), rgba(var(--success), 0.1));
    color: rgb(var(--success));
    border-color: rgba(var(--success), 0.3);
    box-shadow: 0 4px 12px rgba(var(--success), 0.15);
}

/* Status Pills - Neutral States */
.pill.status-new,
.pill.status-former,
.pill.status-not-started,
.pill.status-planning,
.pill.status-planned,
.pill.status-draft,
.pill.status-reimbursed,
.pill.status-partially-paid {
    background: linear-gradient(135deg, rgba(var(--l-gray), 0.8), rgba(var(--l-gray), 0.6));
    color: rgb(var(--l-text));
    border-color: rgba(var(--l-gray), 0.3);
}

/* Status Pills - In Progress States */
.pill.status-in-progress,
.pill.status-pending-activation,
.pill.status-pendingactivation,
.pill.status-pending-sent,
.pill.status-pending-partially-paid,
.pill.status-lead,
.pill.status-pending {
    background: linear-gradient(135deg, rgba(var(--primary), 0.2), rgba(var(--primary), 0.1));
    color: rgb(var(--primary));
    border-color: rgba(var(--primary), 0.3);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.15);
}

/* Status Pills - Warning States */
.pill.status-on-hold,
.pill.status-review,
.pill.status-review-needed,
.pill.status-overdue {
    background: linear-gradient(135deg, rgba(var(--warning), 0.2), rgba(var(--warning), 0.1));
    color: rgb(var(--warning));
    border-color: rgba(var(--warning), 0.3);
    box-shadow: 0 4px 12px rgba(var(--warning), 0.15);
}

/* Status Pills - Error States */
.pill.status-billable-false,
.pill.status-suspended,
.pill.status-rejected,
.pill.status-cancelled,
.pill.status-inactive {
    background: linear-gradient(135deg, rgba(var(--error), 0.2), rgba(var(--error), 0.1));
    color: rgb(var(--error));
    border-color: rgba(var(--error), 0.3);
    box-shadow: 0 4px 12px rgba(var(--error), 0.15);
}

/* ========================================
   STATUS SELECTOR (BUTTON BLOCKS)
   ======================================== */
.status-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-top: 8px;
}

.status-option {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 16px;
    background: rgba(var(--white), 0.8);
    border: 2px solid rgba(var(--border), 0.3);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    font-weight: 500;
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
}

.status-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(var(--primary), 0.1), rgba(var(--primary), 0.05));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.status-option:hover::before {
    opacity: 1;
}

.status-option span {
    position: relative;
    z-index: 1;
    color: rgb(var(--text));
    transition: all 0.3s ease;
}

.status-option:hover {
    border-color: rgba(var(--primary), 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.15);
}

.status-option.active {
    border-color: rgb(var(--primary));
    box-shadow: 0 4px 16px rgba(var(--primary), 0.2);
}

.status-option.active span {
    color: rgb(var(--primary));
    font-weight: 700;
}

@media (max-width: 768px) {
    .status-selector {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========================================
   TOOLTIP COMPONENT
   ======================================== */
.tooltip {
    position: relative;
    cursor: pointer;
}

.tooltip .tooltip-text {
    position: absolute;
    top: -4px;
    left: 50%;
    display: none;
    padding: 5px;
    background-color: rgb(var(--text), .85);
    border: 1px solid rgb(var(--primary));
    border-radius: 5px;
    font-size: var(--fs-small);
    color: rgb(var(--w-text));
    opacity: 0;
    transition: all .1s ease-in-out;
    width: 150px;
    z-index: 999;
}

.tooltip:hover .tooltip-text {
    display: block;
    opacity: 1;
    transform: translateX(-50%) translateY(-100%);
}

/* ========================================
   NOTIFICATION CONTAINER
   ======================================== */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
    max-width: 420px;
    width: 100%;
}

/* ========================================
   MODERN ALERT COMPONENT
   ======================================== */
.alert {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    margin: 0;
    width: auto;
    background: rgba(var(--white), 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(var(--border), 0.2);
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08), 0 6px 20px rgba(0, 0, 0, 0.05), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    opacity: 0;
    transform: translateX(100%) scale(0.95);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    pointer-events: auto;
    overflow: hidden;
    min-height: 70px;
    animation: alertSlideIn 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.alert::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.2) 50%, transparent 100%);
    transition: left 0.6s ease;
}

.alert:hover::after {
    left: 100%;
}

/* Alert Icon Container */
.alert::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    color: white;
    z-index: 1;
}

/* Success Alert */
.alert-success {
    border-left: 5px solid rgb(var(--success)) !important;
    background: linear-gradient(135deg, rgba(var(--success), 0.08) 0%, rgba(var(--white), 0.95) 20%) !important;
    box-shadow: 0 12px 40px rgba(var(--success), 0.12), 0 6px 20px rgba(var(--success), 0.08), inset 0 1px 0 rgba(var(--white), 0.3) !important;
}

.alert-success::before {
    content: '✓';
    background: linear-gradient(135deg, rgb(var(--success)), rgba(var(--success), 0.8));
    color: rgb(var(--w-text));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(var(--success), 0.3);
}

/* Warning Alert */
.alert-warning {
    border-left: 5px solid rgb(var(--warning)) !important;
    background: linear-gradient(135deg, rgba(var(--warning), 0.08) 0%, rgba(var(--white), 0.95) 20%) !important;
    box-shadow: 0 12px 40px rgba(var(--warning), 0.12), 0 6px 20px rgba(var(--warning), 0.08), inset 0 1px 0 rgba(var(--white), 0.3) !important;
}

.alert-warning::before {
    content: '⚠';
    background: linear-gradient(135deg, rgb(var(--warning)), rgba(var(--warning), 0.8));
    color: rgb(var(--w-text));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(var(--warning), 0.3);
}

/* Error Alert */
.alert-error {
    border-left: 5px solid rgb(var(--error)) !important;
    background: linear-gradient(135deg, rgba(var(--error), 0.08) 0%, rgba(var(--white), 0.95) 20%) !important;
    box-shadow: 0 12px 40px rgba(var(--error), 0.12), 0 6px 20px rgba(var(--error), 0.08), inset 0 1px 0 rgba(var(--white), 0.3) !important;
}

.alert-error::before {
    content: '✕';
    background: linear-gradient(135deg, rgb(var(--error)), rgba(var(--error), 0.8));
    color: rgb(var(--w-text));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(var(--error), 0.3);
}

/* Info Alert */
.alert-info {
    border-left: 5px solid rgb(var(--primary)) !important;
    background: linear-gradient(135deg, rgba(var(--primary), 0.08) 0%, rgba(var(--white), 0.95) 20%) !important;
    box-shadow: 0 12px 40px rgba(var(--primary), 0.12), 0 6px 20px rgba(var(--primary), 0.08), inset 0 1px 0 rgba(var(--white), 0.3) !important;
}

.alert-info::before {
    content: 'i';
    background: linear-gradient(135deg, rgb(var(--primary)), rgba(var(--primary), 0.8));
    color: rgb(var(--w-text));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    font-style: italic;
    box-shadow: 0 4px 12px rgba(var(--primary), 0.3);
}

/* Alert Message */
.alert-message {
    flex: 1 !important;
    margin-left: 40px !important;
    font-size: 1rem !important;
    font-weight: 500 !important;
    line-height: 1.5 !important;
    color: rgb(var(--text)) !important;
    word-wrap: break-word !important;
}

.alert-success .alert-message {
    color: rgba(var(--success), 0.9) !important;
}

.alert-warning .alert-message {
    color: rgba(var(--warning), 0.9) !important;
}

.alert-error .alert-message {
    color: rgba(var(--error), 0.9) !important;
}

.alert-info .alert-message {
    color: rgba(var(--primary), 0.9) !important;
}

/* Alert Close Button */
.alert-close {
    position: relative !important;
    width: 32px !important;
    height: 32px !important;
    background: rgba(var(--l-gray), 0.1) !important;
    border: 1px solid rgba(var(--border), 0.2) !important;
    border-radius: 50% !important;
    color: rgb(var(--l-text)) !important;
    font-size: 18px !important;
    font-weight: bold !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
    flex-shrink: 0 !important;
    outline: none !important;
    top: auto !important;
    right: auto !important;
    transform: none !important;
}

.alert-close:hover {
    background: rgba(var(--error), 0.1) !important;
    border-color: rgba(var(--error), 0.3) !important;
    color: rgb(var(--error)) !important;
    transform: scale(1.1) rotate(90deg) !important;
    box-shadow: 0 4px 12px rgba(var(--error), 0.15) !important;
}

.alert-close:active {
    transform: scale(0.95) !important;
}

/* Alert Hover Effects */
.alert:hover {
    transform: translateX(0) scale(1.02) !important;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12), 0 8px 24px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

.alert-success:hover {
    box-shadow: 0 16px 48px rgba(var(--success), 0.15), 0 8px 24px rgba(var(--success), 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

.alert-warning:hover {
    box-shadow: 0 16px 48px rgba(var(--warning), 0.15), 0 8px 24px rgba(var(--warning), 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

.alert-error:hover {
    box-shadow: 0 16px 48px rgba(var(--error), 0.15), 0 8px 24px rgba(var(--error), 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

.alert-info:hover {
    box-shadow: 0 16px 48px rgba(var(--primary), 0.15), 0 8px 24px rgba(var(--primary), 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

/* Alert Show State */
.alert.show {
    opacity: 1 !important;
    transform: translateX(0) scale(1) !important;
    visibility: visible !important;
}

/* Alert Removal Animation */
.alert.removing {
    opacity: 0 !important;
    transform: translateX(100%) scale(0.95) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* ========================================
   ERROR AND LOADING STATES
   ======================================== */
.critical-error {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    width: 100vw;
    height: 100vh;
    background-color: rgb(var(--accent), .3);
}

.critical-error h2 {
    padding: 20px;
    border-radius: 20px;
    background-color: rgb(var(--accent), .3);
    font-size: var(--fs-l);
    font-weight: bold;
    text-align: center;
}

.critical-error p {
    padding: 20px;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
    background-color: rgb(var(--accent), .3);
    font-size: var(--fs-m);
    font-weight: bold;
    text-align: center;
}

/* Loading Placeholders */
.loading-placeholder {
    background: linear-gradient(135deg, rgba(var(--l-gray), 0.3), rgba(var(--l-gray), 0.1));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(var(--border), 0.2);
    border-radius: 20px;
    padding: 48px 32px;
    text-align: center;
    color: rgb(var(--l-text));
    font-style: italic;
    font-size: 1.1rem;
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.loading-placeholder::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(var(--primary), 0.1) 50%, transparent 100%);
}

.table-no-data-message,
.table-row-error-message,
.table-loading-placeholder {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 60px 40px;
    font-size: 2rem;
    font-weight: 100;
    font-style: italic;
    height: 100px;
    background: linear-gradient(90deg, transparent 0%, rgba(var(--primary), 0.05) 50%, transparent 100%);
}
.table-row-error-message {
    background: linear-gradient(90deg, transparent 0%, rgba(var(--accent), 0.1) 50%, transparent 100%);
}
    .table-loading-placeholder::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent 0%, rgba(var(--primary), 0.1) 50%, transparent 100%);
    }

/* Error Messages */
.fatal-error-message,
.error-message,
.no-data-message {
    padding: 40px;
    margin-bottom: 30px;
    border-radius: 20px;
    background-color: rgb(var(--l-gray));
    text-align: center;
    color: rgb(var(--l-text));
    font-style: italic;
    font-size: 1.3em;
}

.fatal-error-message {
    margin: 30px;
}

/* ========================================
   LOADING INDICATORS
   ======================================== */
.local-loading-indicator {
    width: 100%;
    height: 100%;
    position: relative;
    top: 50%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.loading-screen,
.loading-indicator {
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    background-color: rgba(var(--l-gray), 0.9);
    z-index: 9999;
    backdrop-filter: blur(5px);
}

.loading-indicator {
    background-color: rgb(var(--bg));
}

.spinner {
    width: 60px;
    height: 60px;
    border: 8px solid rgba(var(--primary), 0.3);
    border-top-color: rgb(var(--primary));
    border-radius: 50%;
    animation: spin 1.8s linear infinite;
    margin-bottom: 16px;
}

/* ========================================
   TABLE COMPONENTS
   ======================================== */
.table-container {
    width: calc(100% - 20px);
    padding: 20px;
    margin-right: 20px;
    background-color: rgb(var(--white));
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Table responsive wrapper - for horizontal scrolling */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 0 1rem 0;
}

.table-container .table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(var(--border));
}

table {
    width: 100%;
    min-width: 600px; /* Ensures table doesn't become too cramped */
    border-collapse: collapse;
    box-shadow: 0 4px 4px rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    overflow: hidden;
}

table th,
table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid rgb(var(--border));
    font-size: 0.9rem;
}

table th {
    background: rgba(var(--primary), 0.1);
    padding: 20px 24px;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgb(var(--text));
    border-bottom: 2px solid rgba(var(--primary), 0.1);
    transition: .5s ease-in-out;
}

table th:hover {
    color: rgb(var(--primary));
}

table th .sort-icon {
    font-size: 0.8em;
    margin-left: 5px;
    opacity: 0.5;
}

table th.sorted-asc .sort-icon::after {
    content: ' ▲';
    opacity: 1;
}

table th.sorted-desc .sort-icon::after {
    content: ' ▼';
    opacity: 1;
}

table tbody tr {
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border-left: 4px solid transparent;
}

table tbody tr:nth-of-type(even) {
    background-color: rgba(var(--l-gray), .3);
}

table tbody tr:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.04), rgba(var(--primary), 0.08));
    border-left-color: rgba(var(--primary), 0.3);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
}

table tbody tr.non-hoverable-row:hover {
    background: rgb(var(--bg));
    border-left-color: transparent;
    transform: none;
    box-shadow: none;
}

table td {
    padding: 12px 20px;
    border-bottom: 1px solid rgba(var(--border), 0.1);
    vertical-align: middle;
}

table .block-ln {
    display: block;
    width: 100%;
    font-size: 0.7rem;
}

/* Table Buttons */

.table-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 12px;
    min-width: 36px;
    height: 36px;
    border: 1px solid rgba(var(--primary), 0.2);
    border-radius: 10px;
    color: rgb(var(--primary));
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
}
.table-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(var(--primary), 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
}

    .table-btn:hover {
        background: rgba(var(--l-text), .2);
    }

.table-btn i {
    font-size: 1.1rem;
    transition: transform 0.2s ease;
}

.table-btn:hover i {
    transform: scale(1.1);
}

/* Data Table Sort Arrows */
.data-table th .sort-arrow {
    font-size: 0.8em;
    margin-left: 5px;
    opacity: 0.5;
    display: inline-block;
}

.data-table th.sort-asc .sort-arrow,
.data-table th.sort-desc .sort-arrow {
    opacity: 1;
}

.sort-asc .sort-arrow::before {
    content: '▲';
}

.sort-desc .sort-arrow::before {
    content: '▼';
}

/* Enhanced Stats Section */
.chart-container {
    position: relative;
    min-height: 400px;
    margin: 16px 0;
    padding: 32px;
    overflow: hidden;
    background: rgb(var(--white));
    border: 1px solid rgba(var(--border), 0.15);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
}

    .chart-container::before {
        content: '';
        position: absolute;
        top: 0;
        bottom: 0;
        left: 0;
        width: 8px;
        background: var(--l-g-regular);
        border-radius: 20px 0 0 20px;
    }
/* ========================================
   PAGINATION COMPONENT
   ======================================== */
.pagination-container {
    display: flex;
    justify-content: end;
    align-items: center;
    margin-top: 25px;
    padding: 10px 0;
    width: 100%;
    text-align: center;
}

.pagination-container ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: inline-block;
}

.pagination-container li {
    display: inline-block;
    margin: 0 4px;
}

.pagination-container button {
    padding: 8px 14px;
    border: 1px solid rgba(var(--border), 0.4);
    background-color: rgb(var(--white));
    color: rgb(var(--primary));
    cursor: pointer;
    border-radius: 6px;
    font-size: 0.9em;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.pagination-container button:hover:not(:disabled) {
    background-color: rgba(var(--primary), 0.08);
    border-color: rgba(var(--primary), 0.3);
}

.pagination-container button.active {
    background-color: rgb(var(--primary));
    color: rgb(var(--w-text));
    border-color: rgb(var(--primary));
}

.pagination-container button:disabled {
    color: rgba(var(--l-text), 0.6);
    cursor: not-allowed;
    background-color: rgba(var(--l-gray), 0.3);
    border-color: rgba(var(--border), 0.2);
}

/* ========================================
   MODAL COMPONENTS
   ======================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(var(--text), 0.5) 0%, rgba(var(--primary), 0.3) 100%);
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                visibility 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                backdrop-filter 0.4s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.modal-overlay-visible {
    opacity: 1;
    visibility: visible;
}

/* Modal Container - Enhanced glassmorphism and depth */
.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    display: flex;
    flex-direction: column;
    min-width: 580px;
    max-width:900px;
    max-height: 90vh;
    background: linear-gradient(145deg, rgba(var(--white), 0.98) 0%, rgba(var(--white), 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(var(--border), 0.3);
    border-radius: 24px;
    box-shadow: 0 24px 64px rgba(var(--primary), 0.12), 0 12px 32px rgba(var(--text), 0.08), 0 6px 16px rgba(var(--text), 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    overflow: auto;
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, -50%) scale(0.92);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 1001;
}

.modal.modal-open {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.modal:hover::before {
    opacity: 1;
}

/* Modal Header - Enhanced visual hierarchy */
.modal-header {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 28px 32px;
    background: linear-gradient(135deg, 
                rgba(var(--primary), 0.1) 0%, 
                rgba(var(--bg), 0.4) 100%);
    border-bottom: 1px solid rgba(var(--border), 0.3);
    flex-shrink: 0;
    z-index: 1;
}

.modal-header h2 {
    color: rgb(var(--text));
    line-height: 1.3;
    font-size: 1.65rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, rgb(var(--l-text)) 0%, rgb(var(--primary)) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Enhanced Close Button */
.modal-header .x-btn,
.modal-header .close-btn {
    position: relative;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--l-gray), 0.3);
    border: 1px solid rgba(var(--border), 0.3);
    border-radius: 12px;
    cursor: pointer;
    font-size: 1.4rem;
    color: rgb(var(--l-text));
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
    padding: 0;
    line-height: 1;
}

.modal-header .x-btn::before,
.modal-header .close-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: linear-gradient(135deg, 
                rgba(var(--error), 0.2), 
                rgba(var(--error), 0.1));
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.modal-header .x-btn:hover,
.modal-header .close-btn:hover {
    background: linear-gradient(135deg, 
                rgba(var(--error), 0.15), 
                rgba(var(--error), 0.1));
    border-color: rgba(var(--error), 0.4);
    color: rgb(var(--error));
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(var(--error), 0.2),
                0 2px 8px rgba(var(--error), 0.15);
}

.modal-header .x-btn:hover::before,
.modal-header .close-btn:hover::before {
    width: 100%;
    height: 100%;
}

.modal-header .x-btn:active,
.modal-header .close-btn:active {
    transform: scale(0.95);
    box-shadow: 0 2px 8px rgba(var(--error), 0.2),
                inset 0 2px 4px rgba(var(--error), 0.1);
}

/* Modal Content - Enhanced readability and spacing */
.modal-content {
    padding: 32px;
    overflow-y: auto;
    overflow-x: hidden;
    flex-grow: 1;
    color: rgb(var(--text));
    font-size: 1rem;
    line-height: 1.6;
    scrollbar-width: thin;
    scrollbar-color: rgba(var(--primary), 0.3) transparent;
}

.modal-content::-webkit-scrollbar {
    width: 6px;
}

.modal-content::-webkit-scrollbar-track {
    background: rgba(var(--bg), 0.3);
    border-radius: 3px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, 
                rgba(var(--primary), 0.4), 
                rgba(var(--accent), 0.3));
    border-radius: 3px;
    border: 1px solid rgba(var(--primary), 0.2);
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, 
                rgba(var(--primary), 0.6), 
                rgba(var(--accent), 0.4));
}

.modal-content:has(#segmentTasksList) {
    overflow-y: visible;
}

.modal-content p {
    margin: 0 0 16px 0;
    color: rgb(var(--text));
    opacity: 0.9;
}

.modal-content p:last-child {
    margin-bottom: 0;
}

/* Modal Footer - Enhanced button layout and interactions */
.modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    padding: 24px 32px;
    background: linear-gradient(180deg, 
                rgba(var(--bg), 0.3) 0%, 
                rgba(var(--bg), 0.5) 100%);
    border-top: 1px solid rgba(var(--border), 0.3);
    flex-shrink: 0;
    position: relative;
}

.modal-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 32px;
    right: 32px;
    height: 1px;
    background: linear-gradient(90deg, 
                transparent 0%, 
                rgba(var(--primary), 0.2) 50%, 
                transparent 100%);
}

/* Enhanced Modal Buttons */
.modal-footer .btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    background: linear-gradient(135deg, 
                rgba(var(--primary), 0.95) 0%, 
                rgb(var(--primary)) 100%);
    box-shadow: 0 4px 16px rgba(var(--primary), 0.25),
                0 2px 8px rgba(var(--primary), 0.2);
    border: 1px solid rgba(var(--primary), 0.3);
    border-radius: 12px;
    color: rgb(var(--w-text));
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
    min-width: 120px;
    white-space: nowrap;
}

.modal-footer .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
                transparent 0%, 
                rgba(var(--w-text), 0.2) 50%, 
                transparent 100%);
    transition: left 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.modal-footer .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(var(--primary), 0.35),
                0 4px 12px rgba(var(--primary), 0.25);
    border-color: rgba(var(--primary), 0.5);
}

.modal-footer .btn:hover::before {
    left: 100%;
}

.modal-footer .btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.3),
                inset 0 2px 4px rgba(var(--text), 0.1);
}

    .modal-footer .btn.btn-primary {
        background: linear-gradient(135deg, rgba(var(--primary), 0.95) 0%, rgb(var(--primary)) 100%);
        color: rgb(var(--w-text));
    }

    .modal-footer .btn.btn-secondary,
    .modal-footer .btn:not(.btn-primary) {
        background: linear-gradient(135deg, rgba(var(--l-gray), 0.8) 0%, rgba(var(--l-gray), 0.95) 100%);
        color: rgb(var(--text));
        box-shadow: 0 4px 12px rgba(var(--text), 0.08), 0 2px 6px rgba(var(--text), 0.05);
        border: 1px solid rgba(var(--border), 0.4);
    }

    .modal-footer .btn.btn-red {
        background: rgba(var(--error), .3);
        color: rgba(var(--error));
    }

        .modal-footer .btn.btn-secondary:hover,
        .modal-footer .btn:not(.btn-primary):hover {
            background: linear-gradient(135deg, rgba(var(--l-gray), 0.9) 0%, rgba(var(--white), 0.98) 100%);
            box-shadow: 0 8px 20px rgba(var(--text), 0.12), 0 4px 10px rgba(var(--text), 0.08);
            border-color: rgba(var(--border), 0.6);
            color: rgb(var(--text));
        }

        .modal-footer .btn.btn-red:hover {
            background: rgba(var(--error), .3);
            box-shadow: 0 8px 20px rgba(var(--error), 0.4), 0 4px 8px rgba(var(--error), 0.3);
            color:rgba(var(--error));
        }

/* Error Modal - Enhanced visual communication */
.error-modal .modal::before {
    background: linear-gradient(135deg, 
                rgb(var(--error)), 
                rgba(var(--error), 0.8));
    opacity: 1;
}

.error-modal .modal-footer .btn {
    width: 100%;
    justify-content: center;
}

/* Modal Footer Pattern Classes - For standardization and reusability */
.modal-footer.standard-buttons,
.modal-footer.form-buttons {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
}

.modal-footer.delete-buttons {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
}

.modal-footer.close-only {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.modal-footer.space-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.modal-footer.centered-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
}

.error-modal-content,
.warning-modal-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 48px 32px;
    gap: 24px;
}

.error-modal-content .error-icon {
    position: relative;
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: rgb(var(--error));
    background: linear-gradient(135deg, 
                rgba(var(--error), 0.1), 
                rgba(var(--error), 0.05));
    border: 2px solid rgba(var(--error), 0.2);
    border-radius: 50%;
    animation: iconPulse 2s infinite ease-in-out;
    box-shadow: 0 8px 24px rgba(var(--error), 0.2),
                0 4px 12px rgba(var(--error), 0.15),
                inset 0 2px 4px rgba(var(--error), 0.1);
}

    .warning-modal-content .warning-icon {
        position: relative;
        width: 100px;
        height: 100px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: rgba(var(--l-text), 0.3);
        font-size: 8rem;
        width: 120px;
        height: 120px;
        animation: iconPulse 4s infinite ease-in-out;
    }

    .error-modal-content .modal-error-message,
    .warning-modal-content .modal-warning-message {
        color: rgba(var(--l-text));
        line-height: 1.5rem;
        letter-spacing: 0.4px;
        font-weight: 300;
        font-size: 1.3rem;
        max-width: 90%;
    }

.error-modal-content .modal-error-message strong,
.warning-modal-content .modal-warning-message strong {
    color: rgb(var(--error));
    font-weight: 700;
}

.warning-modal-content .modal-warning-message strong {
    color: rgb(var(--warning));
}

.warning-modal .modal::before {
    background: linear-gradient(135deg, 
                rgb(var(--warning)), 
                rgba(var(--warning), 0.8));
    opacity: 1;
}

@keyframes iconPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}
/* ========================================
   NAVIGATION COMPONENTS
======================================== */
.side-nav {
    width: 250px;
    height: 100%;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.85));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-right: 1px solid rgba(var(--border), 0.15);
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0;
    top: 0;
    z-index: 100;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    overflow: hidden;
}

/* Navigation Header */
.nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 16px;
    border-bottom: 1px solid rgba(var(--border), 0.12);
    background: linear-gradient(135deg, rgba(var(--primary), 0.03), rgba(var(--accent), 0.02));
    position: relative;
}

.nav-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 20px;
    right: 20px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(var(--primary), 0.2), transparent);
}

.logo-container {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-container img {
    height:40px;
    width:170px;
    object-fit: contain;
    padding: 0 0 0 0;
    filter: drop-shadow(0 2px 8px rgba(var(--primary), 0.15));
    transition: all 0.3s ease;
}

.logo-container img:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 4px 12px rgba(var(--primary), 0.25));
}

/* Toggle Navigation Button */
.toggle-nav-btn {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, rgba(var(--primary), 0.12), rgba(var(--primary), 0.08));
    border: 1px solid rgba(var(--primary), 0.15);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: rgb(var(--primary));
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    outline: none;
    position: relative;
    overflow: hidden;
}

.toggle-nav-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(var(--primary), 0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.toggle-nav-btn:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.18), rgba(var(--primary), 0.12));
    border-color: rgba(var(--primary), 0.25);
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.15), 0 2px 6px rgba(var(--primary), 0.1);
}

.toggle-nav-btn:hover::before {
    opacity: 1;
}

.toggle-nav-btn:active {
    transform: scale(0.95);
    box-shadow: 0 2px 8px rgba(var(--primary), 0.2), inset 0 2px 4px rgba(var(--primary), 0.1);
}

/* Navigation Content */
.nav-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(var(--primary), 0.3) transparent;
    position: relative;
}

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

.nav-content::-webkit-scrollbar {
    width: 6px;
}

.nav-content::-webkit-scrollbar-track {
    background: rgba(var(--bg), 0.3);
    border-radius: 3px;
    margin: 8px 0;
}

.nav-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, rgba(var(--primary), 0.4), rgba(var(--accent), 0.3));
    border-radius: 3px;
    border: 1px solid rgba(var(--primary), 0.2);
}

.nav-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.6), rgba(var(--accent), 0.4));
}

/* Navigation Footer */
.nav-footer {
    padding: 20px 0 16px 0;
    border-top: 1px solid rgba(var(--border), 0.12);
    background: linear-gradient(135deg, rgba(var(--primary), 0.02), rgba(var(--accent), 0.01));
    position: relative;
}

.nav-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 20px;
    right: 20px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(var(--primary), 0.15), transparent);
}

/* Navigation Menu */
.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-item {
    margin: 6px 0;
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    color: rgb(var(--l-text));
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin: 0 12px;
    font-weight: 500;
    font-size: 0.95rem;
    letter-spacing: 0.025em;
}

.nav-item.upgrade-cta .nav-link {
    background: linear-gradient(135deg, rgba(var(--primary), 0.12), rgba(var(--accent), 0.08));
    color: rgb(var(--d-text));
    border: 1px solid rgba(var(--primary), 0.25);
    position: relative;
}

.nav-item.upgrade-cta .nav-link::before {
    opacity: 1;
    background: linear-gradient(135deg, rgba(var(--primary), 0.18), rgba(var(--accent), 0.1));
}

.nav-item.upgrade-cta .nav-link:hover {
    transform: translateX(4px);
    box-shadow: 0 10px 18px -12px rgba(var(--primary), 0.6);
}

.nav-item.upgrade-cta .upgrade-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nav-item.upgrade-cta .upgrade-title {
    font-weight: 600;
    letter-spacing: 0.04em;
}

.nav-item.upgrade-cta .upgrade-subtitle {
    font-size: 0.7rem;
    opacity: 0.78;
}

.nav-item.upgrade-cta .nav-link i {
    background: linear-gradient(135deg, rgba(var(--primary), 0.6), rgba(var(--accent), 0.45));
    color: #fff;
    box-shadow: 0 6px 16px rgba(var(--primary), 0.24);
}

.nav-item.upgrade-cta .upgrade-indicator {
    position: absolute;
    left: 10px;
    top: 16px;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(var(--accent), 0.9);
    box-shadow: 0 0 0 0 rgba(var(--accent), 0.35);
    animation: upgradePulse 3.2s ease-in-out infinite;
}

@keyframes upgradePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(var(--accent), 0.6);
    }
    60% {
        box-shadow: 0 0 0 16px rgba(var(--accent), 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(var(--accent), 0);
    }
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(var(--primary), 0.08), rgba(var(--accent), 0.04));
    opacity: 0;
    transition: all 0.3s ease;
    border-radius: 12px;
    z-index: -1;
}

/* Navig
ation Link Icons and Text */
.nav-link i {
    font-size: 28px;
    min-width: 28px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    background: linear-gradient(135deg, rgba(var(--primary), 0.1), rgba(var(--accent), 0.05));
    border-radius: 8px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(var(--primary), 0.08);
}

.nav-text {
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    white-space: nowrap;
    font-weight: 500;
}

.submenu-indicator {
    margin-left: auto;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    opacity: 0.6;
}

.nav-item--expandable.is-expanded .submenu-indicator {
    transform: rotate(90deg);
    opacity: 1;
    color: rgb(var(--primary));
}

/* Navigation Link States */
.nav-link:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.12), rgba(var(--accent), 0.06));
    color: rgb(var(--primary));
    transform: translateX(2px);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.12), 0 2px 6px rgba(var(--primary), 0.08);
}

.nav-link:hover::before {
    opacity: 1;
}

.nav-link:hover i {
    background: linear-gradient(135deg, rgba(var(--primary), 0.2), rgba(var(--accent), 0.1));
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.15), 0 2px 6px rgba(var(--primary), 0.1);
    color: rgb(var(--primary));
}

.nav-item.active .nav-link {
    background: linear-gradient(135deg, rgba(var(--primary), 0.15), rgba(var(--accent), 0.08));
    color: rgb(var(--primary));
    font-weight: 600;
    box-shadow: 0 4px 16px rgba(var(--primary), 0.15), 0 2px 8px rgba(var(--primary), 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(var(--primary), 0.2);
}

.nav-item.active .nav-link::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 20%;
    height: 60%;
    width: 4px;
    background: linear-gradient(180deg, rgb(var(--primary)), rgba(var(--accent), 0.8));
    border-radius: 0 3px 3px 0;
    box-shadow: 0 2px 8px rgba(var(--primary), 0.3);
}

.nav-item.active .nav-link i {
    background: var(--l-g-regular);
    color: rgb(var(--w-text));
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(var(--primary), 0.25), 0 2px 8px rgba(var(--primary), 0.15);
}

/* Timer Active Indicator - Red pulsing icon when timer is running */
.nav-item[data-controller="management"][data-action="time-entries"] .nav-link i {
    transition: opacity 0.3s ease, transform 0.3s ease;
    position: relative;
}

.nav-link.timer-active i {
    color: rgb(220, 53, 69) !important;
    animation: timerPulse 1.5s ease-in-out infinite !important;
}

.nav-link.timer-active i::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2px;
    height: 10px;
    background: rgb(220, 53, 69);
    transform-origin: bottom center;
    transform: translate(-50%, -100%) rotate(0deg);
    border-radius: 1px;
    animation: timerHandRotate 2s linear infinite !important;
    box-shadow: 0 0 2px rgba(220, 53, 69, 0.5);
}

.nav-item.active .nav-link.timer-active i {
    color: rgb(220, 53, 69) !important;
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.2), rgba(220, 53, 69, 0.1)) !important;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.25), 0 2px 6px rgba(220, 53, 69, 0.15) !important;
    animation: timerPulse 1.5s ease-in-out infinite !important;
}

@keyframes timerPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.15);
        opacity: 0.8;
    }
}

.nav-item.active .nav-link.timer-active i::after {
    background: rgb(220, 53, 69);
    box-shadow: 0 0 2px rgba(220, 53, 69, 0.5);
}

@keyframes timerHandRotate {
    0% {
        transform: translate(-50%, -100%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -100%) rotate(360deg);
    }
}

[data-theme="dark"] .nav-link.timer-active i {
    color: rgb(239, 68, 68) !important;
    animation: timerPulseDark 1.5s ease-in-out infinite !important;
}

[data-theme="dark"] .nav-link.timer-active i::after {
    background: rgb(239, 68, 68);
    box-shadow: 0 0 2px rgba(239, 68, 68, 0.5);
}

[data-theme="dark"] .nav-item.active .nav-link.timer-active i {
    color: rgb(239, 68, 68) !important;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(239, 68, 68, 0.12)) !important;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3), 0 2px 6px rgba(239, 68, 68, 0.2) !important;
    animation: timerPulseDark 1.5s ease-in-out infinite !important;
}

@keyframes timerPulseDark {
	0%, 100% {
		transform: scale(1);
		opacity: 1;
	}
	50% {
		transform: scale(1.15);
		opacity: 0.85;
	}
}

.main-btn.timer-pulsing {
	color: rgb(var(--white)) !important;
	position: relative;
}

.main-btn.timer-pulsing::after {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: linear-gradient(135deg, rgb(220, 53, 69) 0%, rgba(220, 53, 69, 0.85) 100%);
	border-radius: 12px;
	opacity: 0;
	animation: timerFadeRed 3s ease-in-out infinite;
	pointer-events: none;
	z-index: 0;
}

.main-btn.timer-pulsing > * {
	position: relative;
	z-index: 1;
}

@keyframes timerFadeRed {
	0%, 100% {
		opacity: 0;
	}
	50% {
		opacity: 1;
	}
}

[data-theme="dark"] .main-btn.timer-pulsing::after {
	background: linear-gradient(135deg, rgb(239, 68, 68) 0%, rgba(239, 68, 68, 0.85) 100%);
	animation: timerFadeRedDark 3s ease-in-out infinite;
}

@keyframes timerFadeRedDark {
	0%, 100% {
		opacity: 0;
	}
	50% {
		opacity: 1;
	}
}

[data-theme="dark"] .nav-item.active .nav-link.timer-active i::after {
    background: rgb(239, 68, 68);
    box-shadow: 0 0 2px rgba(239, 68, 68, 0.5);
}

/* Navigation Submenu */
.nav-submenu {
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    padding-left: 20px;
    margin-top: 4px;
    position: relative;
}

.nav-submenu::before {
    content: '';
    position: absolute;
    left: 32px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, rgba(var(--primary), 0.3), rgba(var(--primary), 0.1));
    border-radius: 1px;
}

.nav-item--expandable.is-expanded .nav-submenu {
    max-height: 500px;
    padding-bottom: 8px;
}

.nav-submenu .nav-link {
    padding: 10px 16px 10px 24px;
    font-size: 0.9rem;
    font-weight: 500;
    margin: 2px 8px;
    border-radius: 0 10px 10px 0;
    position: relative;
}

.nav-submenu .nav-link i {
    width: 24px;
    height: 24px;
    font-size: 16px;
    background: linear-gradient(135deg, rgba(var(--accent), 0.1), rgba(var(--primary), 0.05));
}

.nav-submenu .nav-link:hover i {
    background: linear-gradient(135deg, rgba(var(--accent), 0.2), rgba(var(--primary), 0.1));
}

.nav-submenu .nav-item.active .nav-link {
    margin-left: 14px;
    background: linear-gradient(135deg, rgba(var(--accent), 0.12), rgba(var(--primary), 0.08));
    border-radius: 0 10px 10px 0;
}

.nav-submenu .nav-item.active .nav-link::before {
    display: none;
}

.nav-submenu .nav-item.active .nav-link i {
    background: var(--l-g-regular);
    color: rgb(var(--w-text));
}

/* Navigation Collapsed State */
.nav-collapsed .side-nav {
    width: 70px;
}

.nav-collapsed .nav-text,
.nav-collapsed .submenu-indicator,
.nav-collapsed .collapse-hidden {
    opacity: 0;
    visibility: hidden;
    width: 0;
    transform: translateX(-20px);
}

.nav-collapsed .collapse-hidden {
    overflow: hidden;
    height: 0;
}

.logo-container .tenant-name-logo {
    display: block;
    text-align: center;
    padding: 0.5rem;
    font-size: 1.2rem;
    font-weight: 700;
    color: rgb(var(--text));
}

.logo-container .tenant-initials-logo {
    display: none;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: 0 auto;
    border-radius: 12px;
    background: rgba(var(--primary), 0.12);
    color: rgb(var(--text));
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.nav-collapsed .logo-container .tenant-name-logo {
    display: none;
}

.nav-collapsed .logo-container .tenant-initials-logo {
    display: flex;
}

.nav-collapsed .logo-container img {
    display: none;
}

.nav-collapsed .nav-item {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
}

.nav-collapsed .nav-item .nav-link {
    background: none;
    border: none;
    box-shadow: none;
    margin: 4px;
    padding: 12px;
}

.nav-collapsed .nav-item .nav-link i {
    min-width: 32px;
    height: 32px;
    box-shadow: 0 2px 8px rgba(var(--primary), 0.08);
}

.nav-collapsed .nav-submenu {
    display: none;
}

/* ========================================
   THEME TOGGLE BUTTON
   ======================================== */
.theme-toggle-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    color: rgb(var(--l-text));
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin: 0 12px;
    font-weight: 500;
    font-size: 0.95rem;
    letter-spacing: 0.025em;
    background: transparent;
    border: none;
    cursor: pointer;
    width: calc(100% - 24px);
}

.theme-toggle-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(var(--primary), 0.08), rgba(var(--accent), 0.04));
    opacity: 0;
    transition: all 0.3s ease;
    border-radius: 12px;
    z-index: -1;
}

.theme-toggle-btn i {
    font-size: 20px;
    min-width: 28px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    background: linear-gradient(135deg, rgba(var(--primary), 0.1), rgba(var(--accent), 0.05));
    border-radius: 8px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(var(--primary), 0.08);
}

.theme-toggle-text {
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    white-space: nowrap;
    font-weight: 500;
}

.theme-toggle-btn:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.12), rgba(var(--accent), 0.06));
    color: rgb(var(--primary));
    transform: translateX(2px);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.12), 0 2px 6px rgba(var(--primary), 0.08);
}

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

.theme-toggle-btn:hover i {
    background: linear-gradient(135deg, rgba(var(--primary), 0.2), rgba(var(--accent), 0.1));
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(var(--primary), 0.15), 0 2px 6px rgba(var(--primary), 0.1);
    color: rgb(var(--primary));
}

.theme-toggle-btn:active {
    transform: scale(0.98);
}

/* Collapsed nav state */
.nav-collapsed .theme-toggle-btn {
    background: none;
    border: none;
    box-shadow: none;
    margin: 4px;
    padding: 12px;
    justify-content: center;
}

.nav-collapsed .theme-toggle-btn i {
    min-width: 32px;
    height: 32px;
    box-shadow: 0 2px 8px rgba(var(--primary), 0.08);
}

.nav-collapsed .theme-toggle-text {
    opacity: 0;
    visibility: hidden;
    width: 0;
    transform: translateX(-20px);
}

/* ========================================
   HELP MODAL STYLES
   ======================================== */
/* Floating Help Bubble */
.help-bubble {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    padding: 8px 20px;
    background: var(--l-g-regular);
    border-radius: 50px;
    color: rgb(var(--w-text));
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    z-index: 1000;
    transform: translateY(0);
    animation: helpBubbleSlideIn 0.5s ease-out 1s forwards;
}

    .help-bubble:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 25px rgba(var(--primary), 0.4);
        background: linear-gradient(135deg, rgba(var(--primary), 0.9) 0%, rgba(var(--accent), 0.8) 100%);
    }

    .help-bubble i {
        font-size: 18px;
        margin-right: 2px;
    }

/* Help modal */
.help-modal {
    width: 95%;
    max-width: 900px;
}

    .help-modal .modal-content {
        padding: 0;
        text-align: center;
    }

.help-content {
    padding: 2rem;
}

.help-video-selector {
    margin-top: 16px;
    display: none;
    flex-direction: column;
    gap: 8px;
}

    .help-video-selector label {
        margin-bottom: 12px;
        font-size: clamp(1.5rem, 3vw, 2.4rem);
        font-weight: 700;
        color: rgb(var(--text), .3);
        line-height: 1.2;
    }

    .help-video-selector select {
        display:block;
    }

.help-page-title {
    font-size: 1.8rem;
    color: rgb(var(--l-text));
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding-top:1rem;
    margin-top:2rem;
    border-top:1px solid rgba(var(--l-text),.2);
}

.help-page-description {
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.help-video-container {
    position: relative;
    background: rgba(var(--primary), 0.25);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.50), 0 4px 16px rgba(0, 0, 0, 0.2);
    margin: 0 auto;
    max-width: 100%;
    aspect-ratio: 16 / 9; /* Maintains video aspect ratio */
}

.help-video {
    width: 100%;
    height: 100%;
    max-width: 832px;
    max-height: 468px;
    border-radius: 14px;
}

.help-video-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    min-height: 300px;
    background: linear-gradient(135deg, rgba(var(--primary), 0.05) 0%, rgba(var(--success), 0.05) 100%);
    color: rgb(var(--primary));
    padding: 3rem;
}

    .help-video-placeholder i {
        font-size: 12rem;
        color: rgb(var(--primary));
        opacity: 0.5;
        animation: iconFloat 3s ease-in-out infinite;
    }

    .help-video-placeholder p {
        font-size: 1.2rem;
        font-weight: 600;
        color: rgb(var(--l-text));
    }

.help-actions {
    margin-top: 24px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

    .help-actions button {
        flex: 1;
        min-width: 200px;
    }

.help-contact-card {
    margin-top: 28px;
    padding: 20px 24px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(80, 140, 255, 0.12), rgba(120, 195, 255, 0.16));
    display: flex;
    gap: 16px;
    align-items: flex-start;
    border: 1px solid rgba(80, 140, 255, 0.18);
    box-shadow: 0 12px 24px -16px rgba(58, 114, 201, 0.45);
}

    .help-contact-card .help-contact-card-icon {
        width: 68px;
        height: 48px;
        border-radius: 12px;
        background-color: rgba(58, 114, 201, 0.12);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 24px;
        color: #3a72c9;
    }

    .help-contact-card .help-contact-card-content {
        display: flex;
        flex-direction: column;
        gap: 6px;
    }

        .help-contact-card .help-contact-card-content p {
            margin: 0;
            color: #44516b;
            line-height: 1.5;
        }

            .help-contact-card .help-contact-card-content p a {
                color: #2e6ef7;
                font-weight: 600;
            }

@keyframes iconFloat {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-8px);
    }
}

/* ========================================
   COMMENTS SECTION
   ======================================== */
.comments-section {
    border: 1px solid rgba(var(--border), 0.15) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08), 0 1px 4px rgba(0, 0, 0, 0.06) !important;
}

.comment {
    border: 1px solid rgba(var(--border), 0.12) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) !important;
}

    .comment:hover {
        border-color: rgba(var(--primary), 0.25) !important;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1) !important;
    }

/* ========================================
   SCROLLBAR STYLING
   ======================================== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: linear-gradient(135deg, rgba(var(--bg), 0.5), rgba(var(--l-gray), 0.3));
    border-radius: 4px;
    margin: 8px 0;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, rgba(var(--primary), 0.4), rgba(var(--accent), 0.3));
    border-radius: 4px;
    border: 1px solid rgba(var(--primary), 0.2);
    transition: all 0.3s ease;
}

.pill.clickable {
    cursor: pointer;
    user-select: none;
}

.pill.clickable:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

.pill.clickable:active {
    transform: scale(0.98);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.6), rgba(var(--accent), 0.4));
    box-shadow: 0 2px 8px rgba(var(--primary), 0.15);
}

/* ========================================
   ANIMATIONS AND KEYFRAMES
   ======================================== */
@keyframes buttonSlideIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes skeleton-loading {
    0% {
        opacity: 0.2;
    }

    100% {
        opacity: 1;
    }
}

@keyframes statCardSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes urgentPulse {

    0%,
    100% {
        box-shadow: 0 4px 16px rgba(var(--error), 0.25);
        transform: scale(1);
    }

    50% {
        box-shadow: 0 6px 20px rgba(var(--error), 0.4);
        transform: scale(1.02);
    }
}

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

    100% {
        left: 100%;
    }
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes alertSlideIn {
    from {
        opacity: 0;
        transform: translateX(100%) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@keyframes backgroundMorph {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
        filter: hue-rotate(0deg) brightness(1);
    }

    25% {
        transform: translate(30px, -40px) rotate(5deg) scale(1.05);
        filter: hue-rotate(10deg) brightness(1.1);
    }

    50% {
        transform: translate(-20px, 30px) rotate(-3deg) scale(0.95);
        filter: hue-rotate(20deg) brightness(1.05);
    }

    75% {
        transform: translate(40px, 20px) rotate(4deg) scale(1.02);
        filter: hue-rotate(15deg) brightness(1.08);
    }
}

@keyframes backgroundMorphAlt {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
        filter: hue-rotate(0deg) brightness(1);
    }

    20% {
        transform: translate(-35px, 25px) rotate(-4deg) scale(1.03);
        filter: hue-rotate(-8deg) brightness(1.06);
    }

    40% {
        transform: translate(25px, -35px) rotate(6deg) scale(0.97);
        filter: hue-rotate(-15deg) brightness(1.1);
    }

    60% {
        transform: translate(-30px, -20px) rotate(-5deg) scale(1.04);
        filter: hue-rotate(-12deg) brightness(1.04);
    }

    80% {
        transform: translate(40px, 35px) rotate(3deg) scale(0.98);
        filter: hue-rotate(-6deg) brightness(1.07);
    }
}

/* ========================================
   DARK MODE SPECIFIC OVERRIDES
   ======================================== */
[data-theme="dark"] .modal {
    background: linear-gradient(145deg, rgba(var(--white), 1) 0%, rgba(var(--white), 0.98) 100%);
    border-color: rgba(var(--border), 0.4);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4), 
                0 12px 32px rgba(0, 0, 0, 0.3), 
                0 6px 16px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .card {
    background: rgba(var(--white), 1);
    border-color: rgba(var(--border), 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25), 
                0 4px 16px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] .side-nav {
    background: linear-gradient(145deg, rgba(var(--white), 0.98), rgba(var(--white), 0.95));
    border-right-color: rgba(var(--border), 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 
                0 4px 16px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] table tbody tr:nth-of-type(even) {
    background-color: rgba(var(--l-gray), 0.4);
}

[data-theme="dark"] table tbody tr:hover {
    background: linear-gradient(135deg, rgba(var(--primary), 0.08), rgba(var(--primary), 0.12));
}

[data-theme="dark"] .loading-placeholder,
[data-theme="dark"] .table-loading-placeholder {
    background: linear-gradient(135deg, rgba(var(--l-gray), 0.5), rgba(var(--l-gray), 0.3));
    border-color: rgba(var(--border), 0.3);
}

[data-theme="dark"] .alert {
    background: rgba(var(--white), 0.98) !important;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3), 
                0 6px 20px rgba(0, 0, 0, 0.2) !important;
}

[data-theme="dark"] .stats-container .stat-card {
    background: rgb(var(--white));
    border-color: rgba(var(--border), 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25), 
                0 4px 16px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] .stats-container .stat-card:hover {
    box-shadow: 0 20px 40px rgba(var(--primary), 0.25), 
                0 10px 20px rgba(var(--primary), 0.15);
}

/* ========================================
   UPGRADE MODAL STYLES
   ======================================== */
.upgrade-modal {
    background: rgba(var(--white), 0.98);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15), 0 8px 32px rgba(var(--primary), 0.1);
    border: 1px solid rgba(var(--border), 0.2);
    backdrop-filter: blur(20px);
    max-width: 500px;
    width: 90%;
    margin: 0 auto;
    overflow: hidden;
}

.upgrade-modal .modal-header {
    background: linear-gradient(135deg, rgba(var(--primary), 0.1), rgba(var(--primary), 0.05));
    border-bottom: 1px solid rgba(var(--border), 0.2);
    padding: 1.5rem 2rem;
    text-align: center;
    position: relative;
}

.upgrade-modal .modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: rgb(var(--text));
    margin: 0;
    background: var(--l-g-regular);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.upgrade-modal-content {
    padding: 2rem;
    text-align: center;
}

.upgrade-icon {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
}

.upgrade-crown-icon {
    font-size: 3rem;
    color: rgb(var(--warning));
    background: linear-gradient(135deg, rgba(var(--warning), 0.1), rgba(var(--warning), 0.05));
    padding: 1rem;
    border-radius: 50%;
    box-shadow: 0 8px 24px rgba(var(--warning), 0.2);
    animation: iconPulse 2s infinite ease-in-out;
}

.modal-upgrade-message {
    font-size: 1.1rem;
    color: rgb(var(--text));
    line-height: 1.6;
    margin: 0;
    font-weight: 500;
}

.upgrade-modal .modal-footer {
    padding: 1.5rem 2rem;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    background: rgba(var(--bg), 0.5);
    border-top: 1px solid rgba(var(--border), 0.1);
}

.upgrade-btn {
    background: var(--l-g-success) !important;
    color: rgb(var(--w-text)) !important;
    border: none !important;
    padding: 0.875rem 2rem !important;
    border-radius: 12px !important;
    font-size: 1rem !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    cursor: pointer !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
    overflow: hidden !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.5rem !important;
    box-shadow: 0 4px 12px rgba(var(--success), 0.3) !important;
    min-width: 140px !important;
}

/* Vimeo Processing Component Styles */
.vimeo-status-message-container .vimeo-status-icon-wrapper {
    margin-bottom: 1.5rem;
    margin-top: 0;
}

.vimeo-status-message-container .vimeo-status-icon {
    font-size: 3rem !important;
    color: #0066cc !important;
    margin: 0 !important;
    animation: none !important;
    transform: none !important;
    display: block !important;
    background: none !important;
    -webkit-background-clip: unset !important;
    -webkit-text-fill-color: #0066cc !important;
    background-clip: unset !important;
}

.vimeo-status-message-container .main-btn i,
.vimeo-status-message-container .vimeo-check-again-btn i,
#filePreviewSection .vimeo-status-message-container .main-btn i,
#filePreviewSection .vimeo-status-message-container .vimeo-check-again-btn i {
    font-size: 1.1rem !important;
    margin: 0 !important;
    margin-right: 0.5rem !important;
    animation: none !important;
    transform: none !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    color: #ffffff !important;
    background: none !important;
    -webkit-background-clip: unset !important;
    -webkit-text-fill-color: #ffffff !important;
    background-clip: unset !important;
}

    .vimeo-status-message-container .vimeo-check-again-btn i.las.la-sync,
    #filePreviewSection .vimeo-status-message-container .vimeo-check-again-btn i.las.la-sync {
        display: inline-block !important;
        visibility: visible !important;
        opacity: 1 !important;
        font-size: 1.1rem !important;
        margin-right: 0.5rem !important;
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
        font-family: 'Line Awesome Free' !important;
        font-weight: 900 !important;
    }

        .vimeo-status-message-container .vimeo-check-again-btn i.las.la-sync:before,
        #filePreviewSection .vimeo-status-message-container .vimeo-check-again-btn i.las.la-sync:before {
            content: '\f021' !important;
            display: inline-block !important;
            visibility: visible !important;
            color: #ffffff !important;
            -webkit-text-fill-color: #ffffff !important;
        }
/* ========================================
   HELP SYSTEM STYLES
   ======================================== */
@import url('components/help-system.css');

/* ========================================
   RESPONSIVE BREAKPOINTS - DESKTOP FIRST
   ======================================== */

/* 2K and 4K Displays - Enhanced spacing and larger elements */
@media (min-width: 2560px) {
    .dashboard-container {
        max-width: 2400px;
        padding: 24px 24px 0 310px;
    }
    
    .stats-container {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
        gap: 32px;
    }
    
    .card {
        padding: 28px;
    }
}

/* Standard Full HD (1920x1080) - Default styles apply */
@media (min-width: 1920px) and (max-width: 2559px) {
    /* Base styles are optimized for this range */
}

/* Smaller Desktop and Laptops (1440p and below) */
@media (max-width: 1680px) {
    .dashboard-container {
        padding: 18px 18px 0 288px;
    }
    
    .stats-container {
        gap: 20px;
    }
    
    .stats-container .stat-card {
        padding: 28px 20px;
    }
}

/* Common Laptop Resolution (1366x768) */
@media (max-width: 1440px) {
    .dashboard-header h1,
    .details-header h2,
    .table-container .table-header h1 {
        font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    }
    
    .card-title {
        font-size: clamp(1.3rem, 2.5vw, 2rem);
    }
    
    .stats-container {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
        gap: 18px;
    }
    
    .modal {
        width: 92%;
        max-width: 540px;
    }
    
    .help-modal {
        width: 96%;
        max-width: 800px;
    }
}

/* Tight Laptop Screens (1366x768 and similar) */
@media (max-width: 1366px) {
    .dashboard-container {
        padding: 16px 16px 0 286px;
    }
    
    .nav-collapsed .dashboard-container {
        padding: 16px 16px 0 86px;
    }
    
    .stats-container {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        gap: 16px;
    }
    
    .stats-container .stat-card {
        padding: 24px 18px;
    }
    
    .card {
        padding: 18px;
        margin: 20px 0;
    }
    
    table th,
    table td {
        padding: 10px 12px;
        font-size: 0.85rem;
    }
    
    .table-container {
        padding: 16px;
    }
}

/* Smaller Desktop Displays */
@media (max-width: 1280px) {
    .dashboard-container {
        padding: 14px 14px 0 284px;
    }
    
    .nav-collapsed .dashboard-container {
        padding: 14px 14px 0 84px;
    }
    
    .stats-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }
    
    .dashboard-header {
        padding: 16px 0 10px 0;
        margin-bottom: 20px;
    }
    
    .modal-header {
        padding: 24px 28px;
    }
    
    .modal-content {
        padding: 28px;
    }
    
    .modal-footer {
        padding: 20px 28px;
    }
    
    .help-page-title {
        font-size: 2.2rem;
    }
}

/* Minimum Supported Width (1024px) */
@media (max-width: 1024px) {
    .dashboard-container {
        padding: 12px 12px 0 282px;
        min-width: 742px;
    }
    
    .nav-collapsed .dashboard-container {
        padding: 12px 12px 0 82px;
        min-width: 942px;
    }
    
    .stats-container {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .stats-container .stat-card {
        max-width: 100%;
        padding: 20px 16px;
    }
    
    .card {
        padding: 16px;
        margin: 16px 0;
    }
    
    .dashboard-header h1,
    .details-header h2,
    .table-container .table-header h1 {
        font-size: clamp(1.5rem, 3vw, 2rem);
        margin-bottom: 10px;
    }
    
    .card-title {
        font-size: clamp(1.2rem, 2.2vw, 1.6rem);
        margin-bottom: 10px;
    }
    
    table th,
    table td {
        padding: 8px 10px;
        font-size: 0.8rem;
    }
    
    .table-container {
        padding: 14px;
        width: calc(100% - 16px);
        margin-right: 16px;
    }
    
    .modal {
        width: 94%;
        max-width: 480px;
    }
    
    .modal-header {
        padding: 20px 24px;
    }
    
    .modal-header h2 {
        font-size: 1.4rem;
    }
    
    .modal-content {
        padding: 24px;
    }
    
    .modal-footer {
        padding: 18px 24px;
        gap: 10px;
    }
    
    .modal-footer .btn {
        padding: 12px 22px;
        font-size: 0.9rem;
        min-width: 100px;
    }
    
    .help-modal {
        width: 98%;
        max-width: 700px;
    }
    
    .help-page-title {
        font-size: 1.8rem;
    }
    
    .help-page-description {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .help-video-placeholder i {
        font-size: 8rem;
    }
    
    .help-video-placeholder p {
        font-size: 1rem;
    }
    
    .main-btn {
        padding: 0.875rem 1.75rem;
        font-size: 0.95rem;
        min-width: 140px;
    }
    
    .pagination-container {
        margin-top: 20px;
        padding: 8px 0;
    }
    
    .pagination-container button {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
}

/* Print Styles - Ensure proper printing */
@media print {
    body {
        min-width: auto;
        overflow: visible;
    }
    
    .side-nav,
    .help-bubble,
    .theme-toggle-btn,
    .modal-overlay,
    .alert,
    .notification-container {
        display: none !important;
    }
    
    .dashboard-container {
        width: 100% !important;
        padding: 0 !important;
        min-width: auto !important;
    }
    
    .stats-container {
        grid-template-columns: repeat(2, 1fr);
    }
    
    table {
        min-width: auto;
    }
    
    .table-container,
    .table-responsive {
        overflow: visible;
    }
}