/* Import Professional Typography - Must be at top */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ===================================
   ENHANCED COLOR SYSTEM - PROJECTIONLAB INSPIRED
   =================================== */

:root {
    /* ProjectionLab-Inspired Primary Colors */
    --projectionlab-primary: #1867C0;    /* Deep professional blue */
    --projectionlab-secondary: #26A6A2;  /* Sophisticated teal */
    --projectionlab-accent: #F59E0B;     /* Warm amber accent */
    
    /* Enhanced Primary Blue Scale */
    --primary-50: #eff6ff;
    --primary-100: #dbeafe;
    --primary-200: #bfdbfe;
    --primary-300: #93c5fd;
    --primary-400: #60a5fa;
    --primary-500: #3b82f6;  /* Keep existing for compatibility */
    --primary-600: var(--projectionlab-primary);  /* Enhanced with ProjectionLab */
    --primary-700: #1d4ed8;
    --primary-800: #1e40af;
    --primary-900: #1e3a8a;
    
    /* Enhanced Teal/Cyan Scale */
    --accent-50: #f0fdfa;
    --accent-100: #ccfbf1;
    --accent-200: #99f6e4;
    --accent-300: #5eead4;
    --accent-400: var(--projectionlab-secondary);  /* ProjectionLab teal */
    --accent-500: #06b6d4;  /* Keep existing */
    --accent-600: #0891b2;
    --accent-700: #0e7490;
    --accent-800: #155e75;
    --accent-900: #164e63;
    
    /* Enhanced Semantic Colors */
    --success-50: #ecfdf5;
    --success-100: #d1fae5;
    --success-200: #a7f3d0;
    --success-300: #6ee7b7;
    --success-400: #34d399;
    --success-500: #10b981;
    --success-600: #059669;
    --success-700: #047857;
    --success-800: #065f46;
    --success-900: #064e3b;
    
    --warning-50: #fffbeb;
    --warning-100: #fef3c7;
    --warning-200: #fde68a;
    --warning-300: #fcd34d;
    --warning-400: #fbbf24;
    --warning-500: var(--projectionlab-accent);  /* Use ProjectionLab amber */
    --warning-600: #d97706;
    --warning-700: #b45309;
    --warning-800: #92400e;
    --warning-900: #78350f;
    
    --error-50: #fef2f2;
    --error-100: #fee2e2;
    --error-200: #fecaca;
    --error-300: #fca5a5;
    --error-400: #f87171;
    --error-500: #ef4444;
    --error-600: #dc2626;
    --error-700: #b91c1c;
    --error-800: #991b1b;
    --error-900: #7f1d1d;
    
    /* Professional Grays */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    
    /* ProjectionLab-Inspired Gradients */
    --gradient-primary: linear-gradient(135deg, var(--projectionlab-primary), var(--projectionlab-secondary));
    --gradient-primary-soft: linear-gradient(135deg, var(--primary-50), var(--accent-50));
    --gradient-hero: linear-gradient(135deg, var(--projectionlab-primary) 0%, var(--primary-600) 50%, var(--projectionlab-secondary) 100%);
    --gradient-card: linear-gradient(135deg, rgba(24, 103, 192, 0.05) 0%, rgba(38, 166, 162, 0.05) 100%);
    
    /* Surface Colors */
    --surface-primary: #ffffff;
    --surface-secondary: var(--gray-50);
    --surface-accent: var(--gradient-primary-soft);
    --surface-elevated: rgba(255, 255, 255, 0.95);
    
    /* Text Colors - Enhanced for Readability */
    --text-primary: var(--gray-900);      /* #111827 - High contrast */
    --text-secondary: var(--gray-700);    /* #374151 - Better contrast than gray-600 */
    --text-tertiary: var(--gray-600);     /* #4b5563 - For less important text */
    --text-muted: var(--gray-500);        /* #6b7280 - Very light text */
    --text-inverse: #ffffff;
    --text-on-brand: #ffffff;              /* White text on brand colors */
    --text-brand: var(--projectionlab-primary);
    --text-brand: var(--projectionlab-primary);
    --text-accent: var(--projectionlab-secondary);
    
    /* Border Colors */
    --border-light: var(--gray-200);
    --border-medium: var(--gray-300);
    --border-strong: var(--gray-400);
    --border-brand: var(--projectionlab-primary);
    --border-accent: var(--projectionlab-secondary);
    
    /* Shadow System (Enhanced) */
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-brand: 0 10px 15px -3px rgba(24, 103, 192, 0.2), 0 4px 6px -4px rgba(24, 103, 192, 0.1);
    --shadow-accent: 0 10px 15px -3px rgba(38, 166, 162, 0.2), 0 4px 6px -4px rgba(38, 166, 162, 0.1);
    
    /* Interactive States */
    --hover-overlay: rgba(24, 103, 192, 0.05);
    --focus-ring: var(--projectionlab-primary);
    --selection-bg: rgba(24, 103, 192, 0.1);
    --selection-text: var(--projectionlab-primary);
    
    /* Enhanced Typography System - ProjectionLab Style */
    --font-family-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    --font-family-mono: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    
    /* Font Weight Scale */
    --font-weight-light: 300;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800;
    --font-weight-black: 900;
    
    /* Font Size Scale */
    --font-size-xs: 0.75rem;     /* 12px */
    --font-size-sm: 0.875rem;    /* 14px */
    --font-size-base: 1rem;      /* 16px */
    --font-size-lg: 1.125rem;    /* 18px */
    --font-size-xl: 1.25rem;     /* 20px */
    --font-size-2xl: 1.5rem;     /* 24px */
    --font-size-3xl: 1.875rem;   /* 30px */
    --font-size-4xl: 2.25rem;    /* 36px */
    --font-size-5xl: 3rem;       /* 48px */
    --font-size-6xl: 3.75rem;    /* 60px */
    --font-size-7xl: 4.5rem;     /* 72px */
    
    /* Line Height Scale */
    --leading-tight: 1.1;
    --leading-snug: 1.2;
    --leading-normal: 1.4;
    --leading-relaxed: 1.6;
    --leading-loose: 1.8;
    
    /* Letter Spacing */
    --tracking-tighter: -0.05em;
    --tracking-tight: -0.025em;
    --tracking-normal: 0em;
    --tracking-wide: 0.025em;
    --tracking-wider: 0.05em;
    
    /* Typography Utilities */
    --text-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.1);
    --text-shadow-md: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

/* Enhanced Typography Base - ProjectionLab Inspired */
body {
    font-family: var(--font-family-primary);
    font-size: var(--font-size-base);
    line-height: var(--leading-normal);
    color: var(--text-primary);
    font-weight: var(--font-weight-normal);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Typography Scale System */
.text-xs { font-size: var(--font-size-xs); }
.text-sm { font-size: var(--font-size-sm); }
.text-base { font-size: var(--font-size-base); }
.text-lg { font-size: var(--font-size-lg); }
.text-xl { font-size: var(--font-size-xl); }
.text-2xl { font-size: var(--font-size-2xl); }
.text-3xl { font-size: var(--font-size-3xl); }
.text-4xl { font-size: var(--font-size-4xl); }
.text-5xl { font-size: var(--font-size-5xl); }
.text-6xl { font-size: var(--font-size-6xl); }

/* Font Weight Utilities */
.font-light { font-weight: var(--font-weight-light); }
.font-normal { font-weight: var(--font-weight-normal); }
.font-medium { font-weight: var(--font-weight-medium); }
.font-semibold { font-weight: var(--font-weight-semibold); }
.font-bold { font-weight: var(--font-weight-bold); }
.font-extrabold { font-weight: var(--font-weight-extrabold); }
.font-black { font-weight: var(--font-weight-black); }

/* Line Height Utilities */
.leading-tight { line-height: var(--leading-tight); }
.leading-snug { line-height: var(--leading-snug); }
.leading-normal { line-height: var(--leading-normal); }
.leading-relaxed { line-height: var(--leading-relaxed); }
.leading-loose { line-height: var(--leading-loose); }

/* Letter Spacing Utilities */
.tracking-tighter { letter-spacing: var(--tracking-tighter); }
.tracking-tight { letter-spacing: var(--tracking-tight); }
.tracking-normal { letter-spacing: var(--tracking-normal); }
.tracking-wide { letter-spacing: var(--tracking-wide); }
.tracking-wider { letter-spacing: var(--tracking-wider); }

/* Enhanced Heading Styles - ProjectionLab Inspired */
h1, .h1 {
    font-size: clamp(var(--font-size-3xl), 5vw, var(--font-size-6xl));
    font-weight: var(--font-weight-extrabold);
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tight);
    color: var(--text-primary);
    margin-bottom: 1rem;
}

h2, .h2 {
    font-size: clamp(var(--font-size-2xl), 4vw, var(--font-size-4xl));
    font-weight: var(--font-weight-bold);
    line-height: var(--leading-snug);
    letter-spacing: var(--tracking-tight);
    color: var(--text-primary);
    margin-bottom: 0.875rem;
}

h3, .h3 {
    font-size: clamp(var(--font-size-xl), 3vw, var(--font-size-2xl));
    font-weight: var(--font-weight-semibold);
    line-height: var(--leading-snug);
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

h4, .h4 {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-semibold);
    line-height: var(--leading-normal);
    color: var(--text-primary);
    margin-bottom: 0.625rem;
}

h5, .h5 {
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--leading-normal);
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

h6, .h6 {
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    line-height: var(--leading-normal);
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
}

/* Enhanced Paragraph Styles */
p, .text-body {
    font-size: var(--font-size-base);
    line-height: var(--leading-relaxed);
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.text-large {
    font-size: var(--font-size-lg);
    line-height: var(--leading-relaxed);
    color: var(--text-primary);
}

.text-small {
    font-size: var(--font-size-sm);
    line-height: var(--leading-normal);
    color: var(--text-tertiary);
}

/* Specialized Text Styles */
.text-brand {
    color: var(--text-brand);
    font-weight: var(--font-weight-semibold);
}

.text-accent {
    color: var(--text-accent);
    font-weight: var(--font-weight-semibold);
}

.text-muted {
    color: var(--text-tertiary);
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: var(--font-weight-bold);
}

/* Display Text for Heroes */
.display-xl {
    font-size: clamp(var(--font-size-4xl), 8vw, var(--font-size-7xl));
    font-weight: var(--font-weight-black);
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tighter);
    text-shadow: var(--text-shadow-sm);
}

.display-lg {
    font-size: clamp(var(--font-size-3xl), 6vw, var(--font-size-6xl));
    font-weight: var(--font-weight-extrabold);
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tight);
}

.display-md {
    font-size: clamp(var(--font-size-2xl), 5vw, var(--font-size-5xl));
    font-weight: var(--font-weight-bold);
    line-height: var(--leading-snug);
    letter-spacing: var(--tracking-tight);
}

/* ===================================
   GLOBAL NAVIGATION SYSTEM
   =================================== */

/* Global Navigation Component */
.global-nav {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: all 0.3s ease;
}

/* ===================================
   AUTHENTICATION MODAL STYLES
   =================================== */

/* Auth Modal */
.auth-modal, .user-type-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.auth-modal-content {
    position: relative;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 450px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

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

.auth-modal-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
}

.auth-modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--gray-500);
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.auth-modal-close:hover {
    background: var(--gray-100);
    color: var(--gray-700);
}

.auth-modal-body {
    padding: 24px;
}

.auth-modal-body p {
    color: var(--gray-600);
    line-height: 1.6;
    margin-bottom: 24px;
}

/* Google Sign In Button */
.auth-google-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px 24px;
    background: white;
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--gray-700);
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 24px;
}

.auth-google-btn:hover {
    border-color: var(--primary-500);
    box-shadow: 0 4px 12px rgba(103, 126, 234, 0.15);
    transform: translateY(-1px);
}

/* Auth Benefits */
.auth-benefits {
    background: var(--gray-50);
    border-radius: 8px;
    padding: 20px;
}

.auth-benefits h4 {
    color: var(--gray-900);
    font-weight: 600;
    margin-bottom: 12px;
}

.auth-benefits ul {
    list-style: none;
    padding: 0;
}

.auth-benefits li {
    color: var(--gray-700);
    line-height: 1.6;
    margin-bottom: 8px;
    padding-left: 0;
}

/* User Type Selection */
.user-type-options {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.user-type-option {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.user-type-option:hover {
    border-color: var(--primary-500);
    box-shadow: 0 8px 25px rgba(103, 126, 234, 0.15);
    transform: translateY(-2px);
}

.user-type-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.user-type-option h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.user-type-option p {
    color: var(--gray-600);
    line-height: 1.5;
    margin: 0;
}

/* Mobile Responsive */
@media (max-width: 640px) {
    .auth-modal-content {
        margin: 20px;
        max-width: none;
        width: calc(100% - 40px);
    }
    
    .auth-modal-body {
        padding: 20px;
    }
    
    .user-type-options {
        gap: 12px;
    }
    
    .user-type-option {
        padding: 16px;
    }
}

/* ===================================
   DASHBOARD STYLES
   =================================== */

/* Dashboard Header */
.dashboard-header {
    background: var(--gray-50);
    padding: 40px 20px;
    border-bottom: 1px solid var(--gray-200);
}

.dashboard-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.dashboard-welcome h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.dashboard-welcome p {
    color: var(--gray-600);
    font-size: 1.1rem;
}

/* Dashboard Layout */
.dashboard-layout {
    padding: 40px 20px;
}

.dashboard-grid {
    display: grid;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Dashboard Stats */
.dashboard-stats h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 24px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.2s ease;
}

.stat-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-300);
}

.stat-icon {
    font-size: 2rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-100);
    border-radius: 12px;
}

.stat-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0;
}

.stat-content p {
    color: var(--gray-600);
    margin: 4px 0 0 0;
    font-size: 0.9rem;
}

/* Saved Calculations */
.saved-calculations .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.saved-calculations h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
}

.calculations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
}

.calculation-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.2s ease;
}

.calculation-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-300);
}

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

.calculation-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
    flex: 1;
    margin-right: 12px;
}

.calculation-actions {
    display: flex;
    gap: 8px;
}

.load-btn, .delete-btn {
    padding: 6px 12px;
    border: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.load-btn {
    background: var(--primary-500);
    color: white;
}

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

.delete-btn {
    background: var(--gray-200);
    color: var(--gray-600);
    width: 28px;
    height: 28px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delete-btn:hover {
    background: var(--red-100);
    color: var(--red-600);
}

.calculation-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.detail-label {
    color: var(--gray-600);
    font-size: 0.9rem;
}

.detail-value {
    color: var(--gray-900);
    font-weight: 500;
    font-size: 0.9rem;
}

/* Empty States */
.calculations-empty, .calculations-loading {
    text-align: center;
    padding: 60px 20px;
    background: var(--gray-50);
    border-radius: 12px;
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.calculations-empty h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.calculations-empty p {
    color: var(--gray-600);
    margin-bottom: 24px;
}

/* Professional Tools */
.professional-tools h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 24px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.tool-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    transition: all 0.2s ease;
}

.tool-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-300);
}

.tool-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.tool-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.tool-card p {
    color: var(--gray-600);
    margin-bottom: 20px;
    line-height: 1.5;
}

.tool-btn {
    padding: 8px 16px;
    background: var(--gray-200);
    border: none;
    border-radius: 6px;
    color: var(--gray-500);
    font-size: 0.9rem;
    cursor: not-allowed;
}

/* Quick Actions */
.quick-actions h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 24px;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.action-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
    cursor: pointer;
    display: block;
}

.action-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-300);
    transform: translateY(-2px);
    text-decoration: none;
    color: inherit;
}

.action-icon {
    font-size: 2rem;
    margin-bottom: 12px;
}

.action-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.action-card p {
    color: var(--gray-600);
    margin: 0;
    line-height: 1.5;
}

/* Navigation Updates */
.nav-logout {
    background: var(--gray-200);
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    color: var(--gray-700);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nav-logout:hover {
    background: var(--gray-300);
}

/* ===================================
   MODERN DASHBOARD STYLES
   =================================== */

/* Dashboard Hero Section */
.dashboard-hero {
    background: white;
    padding: 40px 0;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.welcome-section {
    display: flex;
    align-items: center;
    gap: 24px;
}

.user-avatar .avatar-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--primary-500);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.welcome-text h1 {
    font-size: 2rem;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.welcome-text p {
    color: var(--gray-600);
    margin-bottom: 16px;
}

.user-stats-inline {
    display: flex;
    gap: 32px;
}

.inline-stat {
    text-align: left;
}

.stat-number {
    display: block;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-600);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gray-500);
}

.hero-actions {
    display: flex;
    gap: 16px;
}

.cta-primary.large, .cta-secondary.large {
    padding: 16px 32px;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-icon {
    font-size: 1.2em;
}

/* Modern Stats Section */
.stats-section {
    margin-bottom: 48px;
    padding: 48px 0;
    background: var(--gray-50);
}

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

.section-header h2 {
    font-size: 1.5rem;
    color: var(--gray-900);
}

.view-toggle {
    display: flex;
    gap: 8px;
    background: white;
    border: 1px solid var(--gray-200);
    padding: 4px;
    border-radius: 8px;
}

.toggle-btn {
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.toggle-btn.active {
    background: var(--primary-500);
    color: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Modern Stat Cards */
.modern-stat-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    transition: all 0.2s ease;
}

.modern-stat-card:hover {
    border-color: var(--primary-300);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

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

.stat-icon-modern {
    font-size: 2rem;
    padding: 12px;
    border-radius: 8px;
    background: white;
    border: 1px solid var(--gray-200);
}

.modern-stat-card.primary .stat-icon-modern {
    background: white;
    border-color: var(--primary-200);
    color: var(--primary-600);
}

.modern-stat-card.success .stat-icon-modern {
    background: white;
    border-color: var(--success-200);
    color: var(--success-600);
}

.modern-stat-card.warning .stat-icon-modern {
    background: white;
    border-color: var(--warning-200);
    color: var(--warning-600);
}

.modern-stat-card.info .stat-icon-modern {
    background: white;
    border-color: var(--gray-200);
    color: var(--gray-600);
}

.stat-trend {
    font-size: 0.875rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 4px;
}

.stat-trend.positive {
    color: var(--success-600);
    background: var(--success-50);
}

.stat-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 4px;
    background: var(--primary-100);
    color: var(--primary-700);
}

.stat-main h3 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.stat-main p {
    color: var(--gray-600);
    margin-bottom: 16px;
}

.stat-progress {
    margin-top: 16px;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--gray-200);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: var(--primary-500);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.stat-progress small {
    color: var(--gray-500);
    font-size: 0.8rem;
}

.stat-action {
    margin-top: 16px;
}

.stat-link {
    color: var(--primary-600);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
}

.stat-link:hover {
    text-decoration: underline;
}

/* Enhanced Calculations Section */
.calculations-section {
    margin-bottom: 48px;
    padding: 48px 0;
    background: white;
}

.header-content {
    flex: 1;
}

.header-content h2 {
    font-size: 1.5rem;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.header-content p {
    color: var(--gray-600);
    font-size: 0.95rem;
}

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

.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box input {
    padding: 12px 16px 12px 40px;
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    width: 240px;
    font-size: 0.9rem;
    transition: border-color 0.2s ease;
}

.search-box input:focus {
    border-color: var(--primary-500);
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-icon {
    position: absolute;
    left: 12px;
    color: var(--gray-400);
}

.calculations-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 24px 0;
    padding: 16px;
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
}

.filter-tabs {
    display: flex;
    gap: 8px;
}

.filter-tab {
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-tab.active {
    background: var(--primary-500);
    color: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.view-controls {
    display: flex;
    gap: 4px;
}

.view-btn {
    padding: 8px 12px;
    border: 1px solid var(--gray-300);
    background: white;
    border-radius: 6px;
    font-size: 1rem;
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-btn.active {
    background: var(--primary-500);
    color: white;
    border-color: var(--primary-500);
}

.calculations-loading {
    text-align: center;
    padding: 60px 20px;
}

.loading-animation {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

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

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

/* Professional Tools Enhanced */
.professional-section {
    padding: 48px 0;
    background: white;
    margin-bottom: 48px;
}

.professional-section .section-header {
    align-items: flex-start;
}

.pro-badge {
    background: var(--primary-500);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pro-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.pro-tool-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.pro-tool-card:hover {
    border-color: var(--primary-300);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.pro-tool-card.coming-soon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--warning-500);
}

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

.tool-icon-large {
    font-size: 3rem;
    padding: 16px;
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
}

.coming-soon-badge {
    background: var(--warning-100);
    color: var(--warning-600);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.pro-tool-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.pro-tool-card p {
    color: var(--gray-600);
    line-height: 1.6;
    margin-bottom: 16px;
}

.tool-features {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 20px;
}

.feature {
    font-size: 0.875rem;
    color: var(--gray-600);
}

.tool-btn {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--gray-300);
    background: white;
    border-radius: 8px;
    font-weight: 500;
    color: var(--gray-500);
    cursor: not-allowed;
}

/* Modern Quick Actions */
.actions-section {
    margin-bottom: 48px;
    padding: 48px 0;
    background: var(--gray-50);
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.action-card-modern {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: all 0.2s ease;
    position: relative;
}

.action-card-modern:hover {
    border-color: var(--primary-300);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.action-card-modern.primary {
    border-left: 4px solid var(--primary-500);
}

.action-card-modern.secondary {
    border-left: 4px solid var(--success-500);
}

.action-card-modern.tertiary {
    border-left: 4px solid var(--accent-500);
}

.action-card-modern.quaternary {
    border-left: 4px solid var(--warning-500);
}

.action-icon-modern {
    font-size: 2rem;
    padding: 12px;
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    flex-shrink: 0;
}

.action-content {
    flex: 1;
}

.action-content h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 6px;
}

.action-content p {
    color: var(--gray-600);
    line-height: 1.5;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.action-meta {
    font-size: 0.8rem;
    color: var(--gray-500);
    font-weight: 500;
}

.action-arrow {
    font-size: 1.5rem;
    color: var(--gray-400);
    margin-left: auto;
    transition: transform 0.2s ease;
}

.action-card-modern:hover .action-arrow {
    transform: translateX(4px);
    color: var(--primary-500);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .hero-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
        text-align: left;
    }
    
    .welcome-section {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .user-avatar .avatar-circle {
        width: 60px;
        height: 60px;
        font-size: 20px;
    }
    
    .hero-actions {
        width: 100%;
        flex-direction: column;
    }
    
    .cta-primary.large, .cta-secondary.large {
        justify-content: center;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .header-actions {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 12px;
    }
    
    .search-box input {
        width: 100%;
    }
    
    .calculations-controls {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
    
    .pro-tools-grid {
        grid-template-columns: 1fr;
    }
    
    .quick-actions-grid {
        grid-template-columns: 1fr;
    }
    
    .action-card-modern {
        padding: 20px;
    }
    
    .dashboard-header .container {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .saved-calculations .section-header {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }
    
    .calculations-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tools-grid, .actions-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .calculation-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .calculation-actions {
        justify-content: flex-end;
    }
}

/* ===================================
   SAVE CALCULATION STYLES  
   =================================== */

.save-calculation-section {
    margin-top: 30px;
    padding: 20px;
    background: var(--gray-50);
    border-radius: 12px;
    border: 1px solid var(--gray-200);
    text-align: center;
}

.save-btn {
    width: 100%;
    padding: 12px 24px;
    background: var(--primary-500);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 8px;
}

.save-btn:hover {
    background: var(--primary-600);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(103, 126, 234, 0.3);
}

.save-btn:active {
    transform: translateY(0);
}

.save-description {
    color: var(--gray-600);
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.4;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .save-calculation-section {
        margin-top: 20px;
        padding: 16px;
    }
    
    .save-btn {
        padding: 10px 20px;
        font-size: 0.95rem;
    }
}

/* ===================================
   AUTHENTICATION INTEGRATION STYLES
   =================================== */

/* Premium Feature Cards */
.feature-card.premium {
    border: 2px solid var(--primary-200);
    background: linear-gradient(135deg, var(--primary-50) 0%, white 100%);
    position: relative;
}

.feature-card.premium::before {
    content: "✨ Premium";
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--primary-500);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

.feature-cta {
    background: var(--primary-500);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 12px;
}

.feature-cta:hover {
    background: var(--primary-600);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(103, 126, 234, 0.3);
}

/* CTA Buttons Grid */
.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.cta-buttons .cta-primary,
.cta-buttons .cta-secondary {
    flex: 1;
    min-width: 200px;
    max-width: 300px;
}

/* Auth Button Styling */
.auth-signin-btn {
    background: var(--gray-200);
    color: var(--gray-700);
    border: 2px solid var(--gray-300);
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.auth-signin-btn:hover {
    background: var(--primary-100);
    border-color: var(--primary-300);
    color: var(--primary-700);
    text-decoration: none;
}

.auth-signin-btn.large {
    padding: 12px 24px;
    font-size: 1rem;
}

/* Navigation CTA Button */
.nav-cta.auth-signin-btn {
    font-size: 0.9rem;
    padding: 6px 12px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-buttons .cta-primary,
    .cta-buttons .cta-secondary {
        flex: none;
        width: 100%;
        max-width: none;
    }
    
    .feature-card.premium::before {
        font-size: 0.65rem;
        padding: 3px 6px;
    }
}

/* ===================================
   FOOTER STYLES
   =================================== */

.main-footer {
    background: var(--gray-900);
    color: white;
    padding: 60px 20px 30px;
    margin-top: 0;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    margin-bottom: 40px;
}

.footer-brand h3 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 12px;
    color: white;
}

.footer-brand p {
    color: var(--gray-300);
    font-size: 1rem;
}

.footer-links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.footer-column h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: white;
}

.footer-column a {
    display: block;
    color: var(--gray-300);
    text-decoration: none;
    margin-bottom: 8px;
    transition: color 0.2s ease;
}

.footer-column a:hover {
    color: var(--primary-400);
}

.footer-disclaimer {
    grid-column: 1 / -1;
    background: var(--gray-800);
    padding: 24px;
    border-radius: 8px;
    margin-top: 32px;
}

.footer-disclaimer h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--gray-200);
}

.footer-disclaimer p {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--gray-300);
}

.footer-bottom {
    border-top: 1px solid var(--gray-700);
    padding-top: 24px;
    text-align: center;
    max-width: 1200px;
    margin: 0 auto;
}

.version-info {
    display: flex;
    justify-content: center;
    gap: 16px;
    font-size: 0.9rem;
    color: var(--gray-400);
}

.version-text {
    font-weight: 600;
}

/* Responsive Footer */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .footer-links {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .version-info {
        flex-direction: column;
        gap: 8px;
    }
}

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

.nav-brand h1 {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-700);
    margin: 0;
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-link {
    font-weight: 500;
    color: var(--gray-700);
    text-decoration: none;
    transition: color 0.2s ease;
    font-size: 1rem;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-600);
}

.nav-cta {
    background: var(--primary-600);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 1rem;
}

.nav-cta:hover {
    background: var(--primary-700);
    transform: translateY(-1px);
}

/* Enhanced Mobile Navigation Toggle - ProjectionLab Style */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 4px;
    padding: 12px;
    border-radius: 8px;
    transition: all 0.2s ease;
    position: relative;
    z-index: 1001;
    min-width: 48px;
    min-height: 48px;
    justify-content: center;
    align-items: center;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.nav-toggle:hover {
    background: var(--hover-overlay);
}

.nav-toggle:focus-visible {
    outline: 2px solid var(--focus-ring);
    outline-offset: 2px;
}

.nav-toggle span {
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

/* Animated hamburger to X transformation */
.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
    background: var(--text-brand);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
    background: var(--text-brand);
}

/* Enhanced Mobile Navigation */
@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: var(--surface-elevated);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 32px;
        padding: 80px 32px 32px;
        z-index: 1000;
        transform: translateX(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: none;
        border: none;
    }
    
    .nav-links.active {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        display: flex;
    }
    
    .nav-links .nav-link {
        font-size: 1.25rem;
        font-weight: 600;
        color: var(--text-primary);
        text-decoration: none;
        padding: 16px 24px;
        border-radius: 12px;
        transition: all 0.2s ease;
        text-align: center;
        min-width: 200px;
        border: 2px solid transparent;
        position: relative;
    }
    
    .nav-links .nav-link:hover,
    .nav-links .nav-link.active {
        background: var(--gradient-card);
        border-color: var(--border-brand);
        color: var(--text-brand);
        transform: translateY(-2px);
        box-shadow: var(--shadow-brand);
    }
    
    .nav-links .nav-cta {
        background: var(--gradient-primary);
        color: var(--text-inverse);
        border: none;
        padding: 16px 32px;
        border-radius: 12px;
        font-size: 1rem;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s ease;
        box-shadow: var(--shadow-brand);
        min-width: 200px;
        text-align: center;
    }
    
    .nav-links .nav-cta:hover {
        transform: translateY(-2px);
        box-shadow: var(--shadow-xl);
    }
    
    .nav-toggle {
        display: flex;
    }
    
    /* Mobile navigation backdrop */
    .nav-links.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }
    
    .nav-container {
        padding: 0 20px;
    }
}

/* ===================================
   LANDING PAGE LAYOUT STYLES
   =================================== */

/* Hero Section - Enhanced Contrast */
.hero {
    min-height: 85vh;
    background: linear-gradient(135deg, #ffffff 0%, var(--gray-50) 100%);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    padding: 80px 20px;
    position: relative;
    border-bottom: 1px solid var(--gray-200);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    margin-bottom: 24px;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--gray-900);
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2.5vw, 1.5rem);
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.4;
    font-weight: 500;
}

.hero-cta {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.cta-primary {
    background: var(--projectionlab-primary);
    color: var(--text-on-brand);
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.125rem;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 180px;
    border: none;
    cursor: pointer;
}

.cta-primary:hover {
    background: #1554A3;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(24, 103, 192, 0.4);
}

.cta-primary.large {
    padding: 20px 40px;
    font-size: 1.25rem;
}

.cta-secondary {
    background: transparent;
    color: var(--text-primary);
    padding: 16px 32px;
    border-radius: 12px;
    border: 2px solid var(--projectionlab-primary);
    font-weight: 600;
    font-size: 1.125rem;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 140px;
}

.cta-secondary:hover {
    background: var(--projectionlab-primary);
    color: var(--text-on-brand);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Removed hero-benefits, benefit, benefit-icon, and benefit-label styles as these elements were removed from HTML */

.hero-visual {
    background: white;
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--gray-200);
}

.feature-preview h3 {
    font-size: 1.5rem;
    margin-bottom: 24px;
    text-align: center;
    color: var(--gray-800);
    font-weight: 700;
}

.preview-card {
    background: var(--gray-50);
    color: var(--gray-900);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--gray-200);
}

.preview-metric {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gray-200);
}

.metric-label {
    font-weight: 500;
    color: var(--gray-600);
}

.metric-value {
    font-weight: 700;
    font-size: 1.125rem;
}

.metric-value.positive {
    color: var(--success-600);
}

.metric-value.negative {
    color: var(--error-500);
}

.preview-insight {
    background: var(--success-50);
    color: var(--success-600);
    padding: 16px;
    border-radius: 8px;
    margin-top: 16px;
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Section Layouts */
.section {
    padding: 80px 20px;
}

/* Specific section styling instead of nth-child rule */
.features.section {
    background: var(--gray-50);
    color: var(--gray-900);
}

.features.section .section-header h2 {
    color: var(--gray-900) !important;
    font-weight: 800;
}

.features.section .section-header p {
    color: var(--gray-600) !important;
    font-weight: 500;
}

.perfect-for.section {
    background: white;
    color: var(--gray-900);
}

.perfect-for.section .section-header h2 {
    color: var(--gray-900) !important;
    font-weight: 800;
}

.perfect-for.section .section-header p {
    color: var(--gray-600) !important;
    font-weight: 500;
}

.how-it-works.section {
    background: var(--gray-50);
    color: var(--gray-900);
}

.how-it-works.section .section-header h2 {
    color: var(--gray-900) !important;
    font-weight: 800;
}

.how-it-works.section .section-header p {
    color: var(--gray-600) !important;
    font-weight: 500;
}

.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px;
}

.section-header h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--gray-900);
    margin-bottom: 16px;
    line-height: 1.2;
}

.section-header p {
    font-size: 1.25rem;
    color: var(--gray-600);
    line-height: 1.5;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 32px;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-card {
    background: white;
    padding: 32px;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid var(--gray-200);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
    border-color: var(--primary-300);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: block;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 16px;
}

.feature-card p {
    color: var(--gray-600);
    line-height: 1.6;
    font-size: 1rem;
}

/* Perfect For Grid */
.perfect-for-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.perfect-for-card {
    background: white;
    padding: 32px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid var(--gray-200);
}

.perfect-for-card.primary {
    border-color: var(--primary-300);
    background: linear-gradient(135deg, var(--primary-50) 0%, white 100%);
}

.perfect-for-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
    border-color: var(--primary-300);
}

.card-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
    display: block;
}

.perfect-for-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 12px;
}

.perfect-for-card p {
    color: var(--gray-600);
    line-height: 1.5;
    margin-bottom: 20px;
}

.perfect-for-card ul {
    list-style: none;
    padding: 0;
}

.perfect-for-card li {
    color: var(--gray-700);
    margin-bottom: 8px;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
}

.perfect-for-card li:before {
    content: "✓";
    color: var(--success-500);
    font-weight: bold;
    margin-right: 8px;
}

/* How It Works */
.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
    max-width: 1000px;
    margin: 0 auto;
}

.step {
    text-align: center;
    position: relative;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--primary-600);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0 auto 24px;
}

.step h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 12px;
}

.step p {
    color: var(--gray-600);
    line-height: 1.5;
}

/* CTA Section */
.cta-section.section {
    background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-700) 100%);
    color: white;
    text-align: center;
}

.cta-content h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    margin-bottom: 16px;
}

.cta-content p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-note {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-top: 16px;
}

/* ===================================
   CALCULATOR PAGE LAYOUT STYLES
   =================================== */

.calculator-header {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    color: var(--gray-900);
    padding: 40px 20px;
    text-align: center;
    border-bottom: 1px solid var(--gray-200);
}

.calculator-header h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    margin-bottom: 12px;
    color: var(--gray-900);
}

.calculator-header p {
    font-size: 1.25rem;
    color: var(--gray-600);
    margin-bottom: 30px;
}

.calculator-layout {
    background: white;
    padding: 40px 20px;
    min-height: calc(100vh - 200px);
}

.calculator-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.input-panel,
.results-panel {
    background: white;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    height: fit-content;
}

.input-panel {
    position: sticky;
    top: 92px; /* Nav height + margin */
}

/* Professional Color System */
:root {
  /* Primary Brand Colors */
  --primary-50: #eff6ff;
  --primary-100: #dbeafe;
  --primary-200: #bfdbfe;
  --primary-300: #93c5fd;
  --primary-400: #60a5fa;
  --primary-500: #3b82f6;
  --primary-600: #2563eb;
  --primary-700: #1d4ed8;
  --primary-800: #1e40af;
  --primary-900: #1e3a8a;

  /* Success Colors */
  --success-50: #ecfdf5;
  --success-500: #10b981;
  --success-600: #059669;

  /* Warning Colors */
  --warning-50: #fffbeb;
  --warning-500: #f59e0b;

  /* Error Colors */
  --error-50: #fef2f2;
  --error-500: #ef4444;

  /* Accent Colors */
  --accent-300: #67e8f9;
  --accent-500: #06b6d4;
  --accent-700: #0891b2;

  /* Neutral Colors */
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;

  /* Surface Colors */
  --surface-primary: #ffffff;
  --surface-secondary: var(--gray-50);

  /* Text Colors */
  --text-primary: var(--gray-900);
  --text-secondary: var(--gray-600);
  --text-inverse: #ffffff;

  /* Border Colors */
  --border-light: var(--gray-200);
  --border-medium: var(--gray-300);

  /* Shadow System */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: white;
    min-height: 100vh;
    color: #1f2937;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-size: 16px;
    line-height: 1.6;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    color: white;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.1;
}

header > * {
    position: relative;
    z-index: 1;
}

header h1 {
    font-size: 3rem;
    margin-bottom: 16px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

header p {
    font-size: 1.25rem;
    font-weight: 400;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto;
}

/* Tool Explanation Section - Calculator Page */
.tool-explanation {
    margin-top: 20px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.tool-explanation .how-it-works summary {
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    padding: 15px 20px;
    background: white;
    border-radius: 10px;
    border: 2px solid var(--primary-200);
    transition: all 0.3s ease;
    text-align: center;
    list-style: none;
    color: var(--gray-900);
}

.tool-explanation .how-it-works summary:hover {
    background: var(--primary-50);
    border-color: var(--primary-400);
    transform: translateY(-2px);
}

.tool-explanation .how-it-works[open] summary {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    border-bottom: none;
}

.tool-explanation .explanation-content {
    background: white;
    color: var(--gray-900);
    padding: 25px;
    border-radius: 0 0 10px 10px;
    border: 2px solid var(--primary-200);
    border-top: none;
}

/* Clean How It Works Section Styling */
.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    max-width: 1200px;
    margin: 0 auto;
}

.step {
    background: white;
    border-radius: 16px;
    padding: 32px 24px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 2px solid var(--gray-200);
    transition: all 0.3s ease;
    position: relative;
}

.step:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
    border-color: var(--primary-300);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: var(--primary-500);
    color: white;
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.step-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 16px;
    line-height: 1.2;
}

.step-content p {
    color: var(--gray-600);
    line-height: 1.5;
    font-size: 1rem;
}

/* Remove old how-it-works details/summary styling on landing page only */
.how-it-works.section summary,
.how-it-works.section[open] summary,
.how-it-works.section .explanation-content {
    display: none;
}

/* Calculator Page Explanation Cards */
.tool-explanation .explanation-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.tool-explanation .explanation-card {
    background: var(--gray-50);
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid var(--primary-500);
    border: 1px solid var(--gray-200);
}

.tool-explanation .explanation-card h4 {
    color: var(--primary-600);
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.tool-explanation .explanation-card p {
    font-size: 0.9rem;
    line-height: 1.4;
    color: var(--gray-700);
}

.tool-explanation .explanation-steps {
    margin-bottom: 25px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
}

.tool-explanation .explanation-steps h4 {
    color: var(--primary-600);
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 600;
}

.tool-explanation .explanation-steps ol {
    padding-left: 20px;
}

.tool-explanation .explanation-steps li {
    margin-bottom: 8px;
    line-height: 1.5;
    font-size: 0.95rem;
    color: var(--gray-700);
}

.tool-explanation .explanation-perfect-for {
    background: white;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
}

.tool-explanation .explanation-perfect-for h4 {
    color: var(--primary-600);
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 600;
}

.tool-explanation .perfect-for-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.tool-explanation .perfect-for-grid div {
    padding: 10px;
    background: var(--gray-50);
    border-radius: 6px;
    font-size: 0.9rem;
    line-height: 1.4;
    color: var(--gray-700);
}

/* ===================================
   EDUCATION PAGE LAYOUT STYLES
   =================================== */

.education-header {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    color: var(--gray-900);
    padding: 60px 20px;
    text-align: center;
    border-bottom: 1px solid var(--gray-200);
}

.education-header h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.1;
    color: var(--gray-900);
}

.education-header p {
    font-size: clamp(1.125rem, 2.5vw, 1.5rem);
    color: var(--gray-600);
    line-height: 1.4;
}

.education-layout {
    background: white;
    padding: 60px 20px;
    min-height: 70vh;
}

.education-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px;
}

.education-intro h2 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: var(--gray-800);
    line-height: 1.3;
}

.education-cta {
    background: var(--gray-50);
    border-radius: 16px;
    padding: 40px;
    text-align: center;
    margin: 60px 0 40px;
    border: 2px solid var(--gray-200);
}

.education-cta h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 16px;
}

.education-cta p {
    color: var(--gray-600);
    font-size: 1.125rem;
    margin-bottom: 24px;
    line-height: 1.5;
}

.education-disclaimer {
    background: var(--gray-100);
    border-radius: 12px;
    padding: 32px;
    border-left: 4px solid var(--warning-500);
    margin-top: 40px;
}

.education-disclaimer h4 {
    color: var(--gray-800);
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.education-disclaimer p {
    color: var(--gray-700);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Education Content Items */
.metric-item,
.return-item,
.risk-item,
.tip-item,
.context-item,
.financing-item {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gray-200);
}

.metric-item:last-child,
.return-item:last-child,
.risk-item:last-child,
.tip-item:last-child,
.context-item:last-child,
.financing-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.return-item p,
.tip-item p {
    margin-top: 8px;
    color: var(--gray-600);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Investment Insights Panel */
.insights-panel {
    background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-700) 100%);
    color: var(--text-inverse);
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.insights-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M20 20c0-11.046-8.954-20-20-20v20h20z'/%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.1;
}

.insights-panel > * {
    position: relative;
    z-index: 1;
}

.insights-panel h3 {
    margin-bottom: 16px;
    font-size: 1.5rem;
    font-weight: 700;
}

.insight-item {
    background: rgba(255, 255, 255, 0.1);
    border-left: 4px solid rgba(255, 255, 255, 0.8);
    padding: 12px 16px;
    margin-bottom: 8px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
    transition: all 0.2s ease;
}

.insight-item:last-child {
    margin-bottom: 0;
}

.insight-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(4px);
}

.insight-item.positive {
    border-left-color: var(--success-500);
    background: rgba(16, 185, 129, 0.2);
}

.insight-item.warning {
    border-left-color: var(--warning-500);
    background: rgba(245, 158, 11, 0.2);
}

.insight-item.negative {
    border-left-color: var(--error-500);
    background: rgba(239, 68, 68, 0.2);
}

.insight-item.info {
    border-left-color: var(--primary-300);
    background: rgba(59, 130, 246, 0.2);
}

.insight-icon {
    font-size: 1.1rem;
    margin-right: 8px;
}

.insight-text {
    font-size: 0.95rem;
    line-height: 1.4;
}

.insight-text strong {
    font-weight: 600;
}


/* Educational Content Section */
.education-section {
    background: var(--surface-primary);
    margin-top: 40px;
    padding: 40px 0;
    border-top: 3px solid var(--primary-500);
}

/* Education Link Section for Calculator Page */
.education-link-section {
    background: var(--gray-50);
    margin-top: 40px;
    padding: 60px 0;
}

.education-link-section .education-cta {
    margin: 0;
}

.education-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.education-section h2 {
    text-align: center;
    color: var(--text-primary);
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
}

.education-intro {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.125rem;
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.education-card {
    background: var(--surface-primary);
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow-md);
    border: 2px solid var(--border-light);
    border-left: 4px solid var(--primary-500);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.education-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-200);
}

.education-card h3 {
    color: var(--primary-700);
    font-size: 1.25rem;
    margin-bottom: 16px;
    font-weight: 700;
}

.education-content > div {
    margin-bottom: 15px;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.education-content > div:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.metric-item strong,
.return-item strong,
.risk-item strong,
.tip-item strong,
.context-item strong,
.financing-item strong {
    color: #333;
    display: block;
    margin-bottom: 5px;
}

.metric-item,
.risk-item,
.tip-item,
.context-item,
.financing-item {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #555;
}

.return-item p {
    margin-top: 8px;
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
}

.education-disclaimer {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 20px;
    margin-top: 30px;
}

.education-disclaimer h4 {
    color: #856404;
    font-size: 1.1rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.education-disclaimer p {
    color: #856404;
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

.calculator-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    min-height: 70vh;
}

.input-panel, .results-panel {
    background: var(--surface-primary);
    padding: 24px;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
}

.input-panel:hover, .results-panel:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.input-panel {
    max-height: fit-content;
}

.input-panel h2 {
    color: var(--text-primary);
    margin-bottom: 20px;
    font-size: 1.875rem;
    font-weight: 700;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-100);
}

.input-panel h3 {
    color: var(--primary-700);
    margin: 20px 0 12px 0;
    font-size: 1.25rem;
    font-weight: 600;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 6px;
}

.form-group {
    margin-bottom: 16px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: 0.025em;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    font-weight: 400;
    background: var(--surface-primary);
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.form-group input[readonly] {
    background: var(--surface-secondary);
    color: var(--text-secondary);
    border-color: var(--border-light);
    cursor: not-allowed;
}

/* Required field styling */
.form-group label.required::after {
    content: " *";
    color: var(--error-500);
    font-weight: 700;
}

/* Field state styling - simplified to remove colored borders and backgrounds */
.form-group input.field-empty-required,
.form-group input.field-filled-required,
.form-group input.field-optional {
    /* Use default styling - no special borders or backgrounds */
}

/* Labels for different field states - removed as we're keeping it simple */

/* Input Mode Selector Styling */
.input-mode-selector {
    display: flex;
    margin-top: 12px;
    background: var(--surface-secondary);
    border-radius: 8px;
    padding: 4px;
    gap: 4px;
    border: 1px solid var(--border-light);
}

.mode-option {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    margin: 0;
    border: none;
}

.mode-option:hover {
    background: var(--primary-50);
    color: var(--text-primary);
}

.mode-option.active {
    background: var(--primary-500);
    color: var(--text-inverse);
    box-shadow: var(--shadow-sm);
}

.mode-option input[type="radio"] {
    display: none;
}

.mode-option span {
    white-space: nowrap;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-500);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.calculate-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.3s ease;
}

.calculate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.results-panel h2 {
    color: var(--text-primary);
    margin-bottom: 20px;
    font-size: 1.875rem;
    font-weight: 700;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-100);
}

.welcome-message,
.error-message {
    text-align: center;
    padding: 50px 20px;
    color: #888;
    font-size: 1.1rem;
}

.error-message {
    color: #dc3545;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 10px;
}

.investment-summary,
.mortgage-summary {
    background: linear-gradient(135deg, #e8f4f8 0%, #d4e7ed 100%);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 25px;
    border-left: 4px solid #667eea;
}

.investment-summary {
    border-left: 4px solid #28a745;
    background: linear-gradient(135deg, #e8f5e8 0%, #d4edd4 100%);
}

.investment-summary h4,
.mortgage-summary h4 {
    color: #667eea;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.investment-summary h4 {
    color: #28a745;
}

.investment-details p,
.mortgage-details p {
    margin: 8px 0;
    color: #555;
}

.investment-details strong,
.mortgage-details strong {
    color: #333;
}

/* Left Panel Investment Comparison */
#leftComparisonContainer {
    margin-top: 30px;
    padding: 25px;
    background: linear-gradient(135deg, #f0f8ff 0%, #e6f3ff 100%);
    border-radius: 15px;
    border: 2px solid #667eea;
}

#leftComparisonContainer h3 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.3rem;
    text-align: center;
}

.left-comparison-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.left-comparison-item {
    background: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.3s ease;
}

.left-comparison-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.left-comparison-item.property {
    border-left: 4px solid #28a745;
}

.left-comparison-item.savings {
    border-left: 4px solid #ffc107;
}

.left-comparison-item.asx {
    border-left: 4px solid #6f42c1;
}

.left-comparison-item h4 {
    margin: 0 0 10px 0;
    font-size: 1rem;
    color: #333;
}

.left-comparison-item p {
    margin: 5px 0;
    font-size: 1.3rem;
    font-weight: 700;
    color: #333;
}

.left-comparison-item small {
    color: #666;
    font-size: 0.85rem;
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.summary-card {
    background: var(--surface-primary);
    border: 2px solid var(--border-light);
    padding: 24px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.2s ease;
}

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

.summary-card h3 {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.summary-card .value {
    font-size: 1.875rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.2;
}

.summary-card.positive {
    border-color: var(--success-500);
    background: var(--success-50);
}

.summary-card.positive .value {
    color: var(--success-600);
}

.summary-card.negative {
    border-color: var(--error-500);
    background: var(--error-50);
}

.summary-card.negative .value {
    color: var(--error-500);
}

.charts-container {
    margin: 30px 0;
}

.chart-wrapper {
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9ff;
    border-radius: 10px;
}

.chart-wrapper h4 {
    color: #667eea;
    margin-bottom: 15px;
    text-align: center;
}

.comparison-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.comparison-item {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8ecff 100%);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
}

.comparison-item h4 {
    color: #667eea;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.comparison-item p {
    font-size: 1.2rem;
    font-weight: 700;
    color: #333;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 0.9rem;
}

.data-table th,
.data-table td {
    padding: 10px;
    text-align: right;
    border-bottom: 1px solid #e1e5e9;
}

.data-table th {
    background: #f8f9ff;
    color: #667eea;
    font-weight: 600;
}

.data-table tbody tr:hover {
    background: #f8f9ff;
}

/* Responsive Design */
@media (max-width: 768px) {
    .calculator-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-top: 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    header {
        padding: 32px 0;
    }
    
    header h1 {
        font-size: 2.25rem;
    }
    
    header p {
        font-size: 1.125rem;
    }
    
    .input-panel, .results-panel {
        padding: 20px;
    }
    
    .summary-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .insights-panel {
        padding: 16px;
        margin-bottom: 16px;
    }
    
    .education-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .education-section {
        margin-top: 32px;
        padding: 32px 0;
    }
    
    #leftComparisonContainer {
        margin-top: 20px;
        padding: 16px;
    }
    
    .left-comparison-item {
        padding: 15px;
    }
    
    .left-comparison-item h4 {
        font-size: 0.9rem;
    }
    
    .left-comparison-item p {
        font-size: 1.1rem;
    }
    
    .container {
        padding: 16px;
    }
}

@media (max-width: 480px) {
    .summary-cards {
        grid-template-columns: 1fr;
    }
    
    header h1 {
        font-size: 1.875rem;
    }
    
    header p {
        font-size: 1rem;
    }
    
    .input-panel, .results-panel {
        padding: 20px;
    }
    
    .form-group input,
    .form-group select {
        padding: 14px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .mode-option {
        padding: 8px 12px;
        font-size: 0.8rem;
    }
    
    .insights-panel h3 {
        font-size: 1.25rem;
    }
    
    .insight-item {
        padding: 12px 16px;
    }
}

/* Loading state */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
    font-size: 1.1rem;
    color: #667eea;
}

.loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid #e1e5e9;
    border-top: 2px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

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

/* ===================================
   ENHANCED HEADING CONTRAST & ACCESSIBILITY
   Session improvements for optimal readability
   =================================== */

/* Global Section Header Fixes */
.section-header,
.section-header * {
    color: inherit !important;
}

.section-header h1,
.section-header h2,
.section-header h3,
h1, h2, h3, h4, h5, h6 {
    color: #111827 !important; /* gray-900, near-black */
    font-weight: 800 !important;
    line-height: 1.1 !important;
}

.section-header p {
    color: #374151 !important; /* gray-700 for good readability */
    font-weight: 600 !important;
}

/* Features Section - Light background, ensure dark text */
.features.section .section-header h2,
.features.section h1,
.features.section h2,
.features.section h3 {
    color: #111827 !important; /* near-black */
}

.features.section .section-header p,
.features.section p {
    color: #374151 !important; /* dark gray */
}

/* Perfect For Section - Light background, ensure dark text */
.perfect-for.section .section-header h2,
.perfect-for.section h1,
.perfect-for.section h2,
.perfect-for.section h3 {
    color: #111827 !important; /* near-black */
}

.perfect-for.section .section-header p,
.perfect-for.section p {
    color: #374151 !important; /* dark gray */
}

/* How It Works Section - White background, ensure dark text */
.how-it-works.section .section-header h2,
.how-it-works.section h1,
.how-it-works.section h2,
.how-it-works.section h3 {
    color: #111827 !important; /* near-black */
}

.how-it-works.section .section-header p,
.how-it-works.section p {
    color: #374151 !important; /* dark gray */
}

/* Hero section headings */
.hero-title,
.hero h1 {
    color: #111827 !important; /* near-black */
    font-weight: 800 !important;
}

.hero-subtitle,
.hero p {
    color: #374151 !important; /* dark gray */
    font-weight: 600 !important;
}

/* Feature cards */
.feature-card h3 {
    color: #111827 !important; /* near-black */
    font-weight: 700 !important;
}

.feature-card p {
    color: #374151 !important; /* dark gray */
    font-weight: 500 !important;
}

/* Feature preview */
.feature-preview h3 {
    color: #111827 !important; /* near-black */
    font-weight: 700 !important;
}

/* Step content */
.step-content h3,
.step h3 {
    color: #111827 !important; /* near-black */
    font-weight: 700 !important;
}

.step-content p,
.step p {
    color: #374151 !important; /* dark gray */
    font-weight: 500 !important;
}

/* Perfect for cards */
.perfect-for-card h3 {
    color: #111827 !important; /* near-black */
    font-weight: 700 !important;
}

.perfect-for-card p {
    color: #374151 !important; /* dark gray */
    font-weight: 500 !important;
}

/* Navigation brand */
.nav-brand h1 {
    color: #1867C0 !important; /* brand blue for navigation */
    font-weight: 800 !important;
}

/* Exception: Premium cards and CTA sections with dark backgrounds keep white text */
.feature-card.premium,
.feature-card.premium * {
    color: white !important;
}

.cta-section,
.cta-section * {
    color: white !important;
}

.footer,
.footer * {
    color: white !important;
}

/* Specific fix for footer brand description text */
.footer-brand p,
.main-footer .footer-brand p {
    color: #111827 !important; /* same as other headers */
    font-weight: 600 !important;
}

/* Make disclaimer heading match disclaimer body text color */
.footer-disclaimer h4 {
    color: var(--gray-300) !important; /* same as disclaimer body text */
}

/* Accessibility - Ensure minimum contrast ratios */
.section-header {
    font-weight: 800 !important;
    line-height: 1.1 !important;
    letter-spacing: -0.01em !important;
}

/* Strengthen font weights for better readability */
h1, .h1 {
    font-weight: 800 !important;
    font-size: clamp(28px, 5vw, 48px) !important;
}

h2, .h2 {
    font-weight: 800 !important;
    font-size: clamp(24px, 4vw, 36px) !important;
}

h3, .h3 {
    font-weight: 700 !important;
    font-size: clamp(20px, 3vw, 28px) !important;
}

/* Mobile responsiveness - ensure darker text on smaller screens if backgrounds get lighter */
@media (max-width: 640px) {
    .section-header h1,
    .section-header h2,
    .section-header h3,
    h1, h2, h3, h4, h5, h6 {
        color: #0f172a !important; /* even darker for mobile */
    }
}