/* Eco Engineering Services Marketing Reference Hub - Main Stylesheet */

/* CSS Variables - aligned with STYLING-GUIDE.md (SHAX palette) */
:root {
    /* Brand tokens - Eco Engineering blue palette */
    --primary-color: #045097; /* Deep Navy Blue */
    --primary-dark: #03356b;
    --primary-light: #2f7cc7;
    --primary-glow: rgba(4, 80, 151, 0.22);
    --secondary-color: #6BB9F0; /* Sky Blue */
    --secondary-dark: #3d91cc;
    --secondary-light: #9ed4ff;
    --secondary-glow: rgba(107, 185, 240, 0.22);

    /* CTA – Solar Yellow */
    --cta-color: #FFC928;
    --cta-color-dark: #e6b423;
    --cta-color-rgb: 255, 201, 40;

    /* Backgrounds */
    --bg-primary: #f8fafc;
    --bg-surface: #ffffff;
    --bg-off-white: #ffffff;
    --bg-cream: #f9f7f4;
    --bg-gradient: linear-gradient(180deg, #f0f7ff 0%, #f8fafc 50%, #ffffff 100%);
    --bg-hero: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(4, 80, 151, 0.12), transparent),
               radial-gradient(ellipse 60% 40% at 80% 50%, rgba(107, 185, 240, 0.09), transparent),
               linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);

    /* Gray palette */
    --gray-secondary: #94a3b8;
    --gray-secondary-dark: #64748b;
    --gray-secondary-light: #cbd5e1;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;

    /* Semantic */
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --border-subtle: rgba(226, 232, 240, 0.8);
    --bg-secondary: var(--gray-50);
    --bg-tertiary: var(--gray-100);
    --white: #ffffff;

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;
    --spacing-4xl: 6rem;

    /* Typography */
    --font-family: "Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-family-headings: "Plus Jakarta Sans", system-ui, var(--font-family);
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;

    /* Border radius */
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.25rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(15, 23, 42, 0.08), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(15, 23, 42, 0.15);
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px -1px rgba(0, 0, 0, 0.05);
    --shadow-card-hover: 0 10px 40px -10px rgba(4, 80, 151, 0.18), 0 4px 12px -4px rgba(15, 23, 42, 0.08);

    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);

    /* Z-index */
    --z-dropdown: 1000;
    --z-sticky: 1020;
    --z-fixed: 1030;
    --z-modal-backdrop: 1040;
    --z-modal: 1050;
    --z-tooltip: 1060;
    --z-toast: 1070;

    /* Backwards-compatible Eco brand aliases pointing to new tokens */
    --brand-white: var(--white);
    --brand-blue: var(--primary-color);
    /* Alias kept for backwards-compatibility: brand-orange now maps to secondary Sky Blue */
    --brand-orange: var(--secondary-color);
    --brand-grey: #D9D9D9;
    --accent-color: var(--primary-color);
    --accent-dark: #033056;
    --accent-light: #2f7cc7;
    --primary-color-rgb: 4, 80, 151;
    --secondary-color-rgb: 107, 185, 240;

    /* High contrast variants */
    --text-primary-high-contrast: #000000;
    --text-secondary-high-contrast: var(--gray-800);

    /* Elevation aliases (for existing rules) */
    --elevation-1: var(--shadow-sm);
    --elevation-2: var(--shadow-md);
    --elevation-3: var(--shadow-lg);
    --elevation-4: var(--shadow-xl);
    --elevation-5: var(--shadow-2xl);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    overflow-x: hidden;
    max-width: 100%;
    position: relative;
}

/* Page transition fade-in */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

body {
    animation: fadeIn 0.4s ease-out;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Desktop: Remove sidebar, use bottom navigation */
@media (min-width: 768px) {
    body {
        min-height: 100vh;
        padding-bottom: 72px; /* Space for bottom nav bar */
    }
    
    .main-header {
        display: none; /* Hide sidebar completely on desktop */
    }
    
.main-content-wrapper {
    margin-left: 0;
    width: 100%;
    max-width: 100%;
    flex: 1;
    min-width: 0;
    overflow-x: hidden;
}
    
main {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
}
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    box-sizing: border-box;
}

/* Global hub containers – use more of the viewport on small screens */
@media (max-width: 600px) {
    .main-content-wrapper .container {
        padding-left: var(--spacing-sm);
        padding-right: var(--spacing-sm);
    }
}

@media (min-width: 480px) {
    .container {
        padding: 0 var(--spacing-lg);
    }
}

@media (min-width: 768px) {
    .container {
        padding: 0 var(--spacing-xl);
    }
    
    .main-content-wrapper .container {
        padding: var(--spacing-xl) var(--spacing-xl);
    }
}

@media (min-width: 1440px) {
    .container {
        max-width: 1400px;
    }
    
    .main-content-wrapper .container {
        padding: var(--spacing-xl) var(--spacing-2xl);
    }
}

/* Brand Assets page – tighter mobile gutters, fuller width */
@media (max-width: 600px) {
    .page-brand-assets .container {
        padding-left: var(--spacing-xs);
        padding-right: var(--spacing-xs);
    }
    
    .page-brand-assets .resources-section {
        margin-left: 0;
        margin-right: 0;
    }
    
    .page-brand-assets .resource-card {
        padding: var(--spacing-lg) var(--spacing-sm);
        border-radius: var(--radius-lg);
    }
}

/* Very Small Screen Support (<320px) */
@media (max-width: 319px) {
    .container {
        padding: 0 var(--spacing-sm);
    }
    
    .main-content-wrapper .container {
        padding: var(--spacing-md) var(--spacing-sm);
    }
    
    html {
        font-size: 14px;
    }
    
    .hero-section {
        padding: var(--spacing-xl) 0;
    }
    
    .hero-logo {
        width: 80px;
        max-width: 100px;
    }
    
    .hero-title {
        font-size: clamp(1.5rem, 8vw, 2rem);
        margin-bottom: var(--spacing-md);
    }
    
    .hero-description {
        font-size: var(--font-size-sm);
        padding: 0 var(--spacing-xs);
    }
    
    .hero-stats {
        gap: var(--spacing-sm);
        padding: var(--spacing-sm) 0;
    }
    
    .hero-stat-number {
        font-size: var(--font-size-2xl);
    }
    
    .hero-stat-label {
        font-size: var(--font-size-xs);
    }
}

/* Ultra-Wide Screen Support (>1920px) */
@media (min-width: 1921px) {
    .container {
        max-width: 1600px;
    }
    
    .main-content-wrapper .container {
        padding: var(--spacing-2xl) var(--spacing-3xl);
    }
    
    .hero-content {
        max-width: 1200px;
    }
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-headings);
    font-weight: 600;
    line-height: 1.2;
    color: var(--text-primary);
    margin-bottom: var(--spacing-md);
}

h1 {
    font-size: clamp(1.75rem, 5vw, var(--font-size-4xl));
}

h2 {
    font-size: clamp(1.5rem, 4vw, var(--font-size-3xl));
}

h3 {
    font-size: clamp(1.25rem, 3vw, var(--font-size-2xl));
}

h4 {
    font-size: clamp(1.125rem, 2.5vw, var(--font-size-xl));
}

p {
    margin-bottom: var(--spacing-md);
    color: var(--text-secondary);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-dark);
}

/* Enhanced Focus States for Accessibility */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus,
[tabindex]:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Focus-visible for keyboard navigation (better UX) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
    box-shadow: 0 0 0 4px rgba(16, 110, 60, 0.2);
}

/* Remove focus outline for mouse users (but keep for keyboard) */
a:focus:not(:focus-visible),
button:focus:not(:focus-visible),
input:focus:not(:focus-visible),
textarea:focus:not(:focus-visible),
select:focus:not(:focus-visible),
[tabindex]:focus:not(:focus-visible) {
    outline: none;
}

/* Ensure all interactive elements are keyboard accessible */
.category-card:focus-visible,
.quick-access-card:focus-visible,
.resource-card:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
    box-shadow: 0 0 0 4px rgba(16, 110, 60, 0.2);
}

/* Skip link focus state */
.skip-link:focus,
.skip-link:focus-visible {
    top: var(--spacing-md);
    outline: 3px solid var(--white);
    outline-offset: 2px;
}

/* Screen reader only class */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Header - Desktop Sidebar / Mobile Overlay */
.main-header {
    background-color: var(--bg-primary);
    border-bottom: 1px solid var(--gray-200);
    position: sticky;
    top: 0;
    z-index: var(--z-sticky);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    backdrop-filter: blur(10px);
    background-color: rgba(254, 254, 254, 0.95);
}

/* Mobile: Slide-out menu */
@media (max-width: 767px) {
    /* Hide main header on mobile - using bottom navigation instead */
    .main-header {
        display: none !important;
    }
    
    /* Hide backdrop - not needed without slide-out menu */
    .nav-backdrop {
        display: none !important;
    }
    
    .main-content-wrapper {
        margin-left: 0;
        width: 100%;
    }
    
    body.menu-open {
        overflow: auto; /* Allow scrolling since menu is hidden */
    }
    
    /* Position logo section to accommodate close button overlay - compact */
    .main-header .logo-section {
        padding-top: calc(var(--spacing-sm) + 52px);
        padding-right: var(--spacing-md);
        padding-left: var(--spacing-md);
        padding-bottom: var(--spacing-sm);
        position: relative;
        border-bottom: 1px solid var(--gray-200);
        margin-bottom: var(--spacing-sm);
        flex-shrink: 0;
    }
    
    /* Mobile header content wrapper - consolidated with navigation.css */
    /* Styles moved to navigation.css to avoid conflicts */
    
    /* Center logo content on mobile with logo above text */
    .nav-menu > li.nav-menu-close .menu-logo {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 4px;
        text-decoration: none;
    }
    
    .nav-menu > li.nav-menu-close .menu-logo img {
        height: 36px;
        width: auto;
        order: -1;
    }
    
    .nav-menu > li.nav-menu-close .menu-logo-text {
        font-size: var(--font-size-sm);
        color: var(--primary-color);
        font-weight: 600;
    }
    
    /* Header buttons - Calendar and Home */
    .nav-menu > li.nav-menu-close .header-buttons {
        display: flex;
        flex-direction: row;
        gap: var(--spacing-sm);
        align-items: center;
        justify-content: center;
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a {
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: var(--radius-md);
        border: 2px solid;
        transition: all var(--transition-base);
        text-decoration: none;
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.calendar-icon {
        border-color: var(--secondary-color);
        color: var(--secondary-color);
        background-color: var(--white);
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.calendar-icon:hover {
        background-color: var(--secondary-color);
        color: var(--white);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(233, 133, 11, 0.3);
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.calendar-icon svg {
        width: 18px;
        height: 18px;
        stroke: currentColor;
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.calendar-icon:hover svg {
        stroke: var(--white);
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.home-icon {
        border-color: var(--primary-color);
        color: var(--primary-color);
        background-color: var(--white);
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.home-icon:hover,
    .nav-menu > li.nav-menu-close .header-buttons a.home-icon.active {
        background-color: var(--primary-color);
        color: var(--white);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(16, 110, 60, 0.3);
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.home-icon svg {
        width: 18px;
        height: 18px;
        stroke: currentColor;
    }
    
    .nav-menu > li.nav-menu-close .header-buttons a.home-icon:hover svg,
    .nav-menu > li.nav-menu-close .header-buttons a.home-icon.active svg {
        stroke: var(--white);
    }
    
    /* Close button positioning */
    .nav-menu > li.nav-menu-close .mobile-menu-close {
        position: absolute;
        top: var(--spacing-md);
        right: var(--spacing-md);
        width: 40px;
        height: 40px;
    }
    
    /* Full width container for mobile menu */
    .main-header .container {
        width: 100%;
        max-width: 100%;
        padding: 0;
    }
    
    .main-header .header-content {
        width: 100%;
        padding: 0;
        height: 100vh;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }
    
    .main-header .main-nav {
        flex: 1;
        width: 100%;
        padding: 0 var(--spacing-md);
        overflow-y: visible;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }
    
    .main-header .nav-menu {
        flex: 1;
        display: flex;
        flex-direction: column;
        overflow: visible;
        justify-content: flex-start;
        padding: 0;
        margin: 0;
        gap: 0;
    }
    
    /* Hide mobile menu close element on desktop */
    .main-header .nav-menu > li.nav-menu-close {
        display: none !important;
    }
    
    /* Create a flexible navigation container */
    .main-header .nav-menu > li:not(.desktop-only):not(.nav-menu-close):not(.mobile-only) {
        flex: 1;
        display: flex;
        align-items: center;
        margin-bottom: var(--spacing-xs);
    }
    
    /* Remove extra spacing from first navigation link */
    .main-header .nav-menu > li:not(.desktop-only):not(.nav-menu-close):not(.mobile-only):first-of-type {
        margin-top: 0;
    }
    
    .main-header .nav-menu > li:not(.desktop-only):not(.nav-menu-close):not(.mobile-only) > a {
        flex: 1;
        display: flex;
        align-items: center;
        min-height: 60px;
        padding: var(--spacing-md) var(--spacing-lg);
        border-radius: var(--radius-md);
        transition: all var(--transition-base);
    }
    
    /* Push desktop action buttons to bottom */
    .main-header .nav-menu > li.desktop-only:first-of-type {
        margin-top: auto;
        margin-bottom: var(--spacing-sm);
    }
    
    /* Ensure consistent spacing for desktop action buttons */
    .main-header .nav-menu > li.desktop-only {
        margin-bottom: var(--spacing-xs);
    }
    
    .main-header .nav-menu > li.desktop-only:last-child {
        margin-bottom: 0;
    }
}

/* Desktop: Bottom navigation bar layout */
@media (min-width: 768px) {
    body {
        min-height: 100vh;
        padding-bottom: 72px; /* Space for bottom nav bar */
    }
}

/* Mobile: Bottom navigation bar layout */
@media (max-width: 767px) {
    body {
        min-height: 100vh;
        padding-bottom: 60px; /* Space for bottom nav bar on mobile */
    }
}

/* Small screens with stacked navigation */
@media (max-width: 400px) {
    body {
        padding-bottom: 80px; /* Extra space for 2-row navigation */
    }
    
    .main-content-wrapper {
        padding-bottom: 0; /* Bottom padding handled by body */
    }
    
    .main-header {
        display: none; /* Hide sidebar completely on desktop */
    }
    
    .main-content-wrapper {
        margin-left: 0;
        width: 100%;
        flex: 1;
        min-width: 0;
        display: flex;
        flex-direction: column;
    }
    
    main {
        width: 100%;
        flex: 1;
        overflow-x: hidden;
    }
    
    .main-content-wrapper .container {
        width: 100%;
        max-width: 100%;
        padding: var(--spacing-xl) var(--spacing-xl);
        box-sizing: border-box;
    }
    
    /* Remove top padding when hero section is first */
    .main-content-wrapper .hero-section:first-child .container,
    .main-content > .hero-section:first-child .container {
        padding-top: 0;
    }
    
    /* Remove top padding from main-content-wrapper when hero is first */
    .main-content-wrapper > main > .hero-section:first-child {
        margin-top: 0;
    }
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-lg) 0;
    gap: var(--spacing-xl);
    flex-wrap: wrap;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-width: 0;
}

/* Remove container padding in sidebar */
@media (min-width: 768px) {
    .main-header .container {
        padding-left: 0;
        padding-right: 0;
        max-width: 100%;
        width: 100%;
    }
}

/* Desktop: Stack header content vertically */
@media (min-width: 768px) {
    /* Desktop: Hide header/sidebar completely */
    .header-content {
        display: none;
    }
    
    .logo-section {
        display: none;
    }
    
    .main-nav {
        display: none;
    }
}

.logo-section {
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    min-width: 0;
    max-width: 100%;
}

.logo-section a {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    text-decoration: none;
}

.logo-section a > div {
    display: flex;
    flex-direction: column;
}

.logo-section img {
    height: 50px;
    width: auto;
    max-width: min(200px, 100%);
    object-fit: contain;
    transition: transform var(--transition-fast);
}

/* Responsive Images */
img {
    max-width: 100%;
    height: auto;
    box-sizing: border-box;
}

.logo-section a:hover img {
    transform: scale(1.05);
}

@media (max-width: 767px) {
    .logo-section img {
        height: 40px;
    }
    
    .logo-section a {
        flex-direction: row;
        gap: var(--spacing-xs);
    }
    
    .site-logo {
        font-size: var(--font-size-xl);
    }
    
    .site-subtitle {
        font-size: var(--font-size-xs);
    }
    
    .hero-title {
        font-size: clamp(1.5rem, 8vw, 2.5rem);
    }
    
    .hero-description {
        font-size: clamp(var(--font-size-sm), 2.5vw, var(--font-size-base));
    }
    
    .main-content {
        padding: var(--spacing-lg) 0;
    }
    
    .section-title {
        font-size: clamp(1.25rem, 4vw, var(--font-size-2xl));
        margin-bottom: var(--spacing-xl);
    }
}

.site-logo {
    font-family: var(--font-family-headings);
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0;
}

.site-subtitle {
    font-size: var(--font-size-sm);
    color: var(--text-muted);
    font-weight: 400;
}

/* Navigation styles moved to css/navigation.css */


/* Main Content */
.main-content {
    min-height: calc(100vh - 200px);
    padding: 0;
}

/* Remove top padding when hero section is first */
.main-content > .hero-section:first-child {
    margin-top: 0;
    padding-top: var(--spacing-3xl);
}

/* Hero Section */
.hero-section {
    background: var(--bg-hero);
    background-size: 200% 200%;
    animation: heroGradientShift 15s ease infinite;
    padding: var(--spacing-3xl) 0;
    margin-top: 0 !important;
    margin-bottom: var(--spacing-3xl);
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
}

@keyframes heroGradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Ensure hero sections always reach the top - remove any top margin/padding */
.hero-section:first-child,
main > .hero-section:first-child,
.main-content > .hero-section:first-child,
.main-content-wrapper > main > .hero-section:first-child {
    margin-top: 0 !important;
}

/* Remove top padding from containers inside hero sections and make full width */
.hero-section .container {
    padding-top: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    padding-left: var(--spacing-xl);
    padding-right: var(--spacing-xl);
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* Ensure hero sections are full width at all breakpoints */
@media (min-width: 768px) {
    .hero-section .container {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: var(--spacing-xl);
        padding-right: var(--spacing-xl);
    }
}

@media (min-width: 1440px) {
    .hero-section .container {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: var(--spacing-2xl);
        padding-right: var(--spacing-2xl);
    }
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: min(500px, 30vw);
    height: min(500px, 30vw);
    background: radial-gradient(circle, rgba(4, 80, 151, 0.12) 0%, rgba(4, 80, 151, 0.04) 50%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: floatGradient 15s ease-in-out infinite;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: min(400px, 25vw);
    height: min(400px, 25vw);
    background: radial-gradient(circle, rgba(255, 201, 40, 0.1) 0%, rgba(255, 201, 40, 0.03) 50%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: floatGradient 18s ease-in-out infinite reverse;
}

@keyframes floatGradient {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }
    50% {
        transform: translate(20px, -30px) scale(1.1);
        opacity: 0.8;
    }
}

/* Animated floating particles */
.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.hero-particle {
    position: absolute;
    border-radius: 50%;
    opacity: 0.3;
    animation: floatParticle 12s ease-in-out infinite;
}

.hero-particle:nth-child(1) {
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    top: 20%;
    left: 10%;
    animation-delay: 0s;
    animation-duration: 14s;
}

.hero-particle:nth-child(2) {
    width: 6px;
    height: 6px;
    background: var(--secondary-color);
    top: 60%;
    right: 15%;
    animation-delay: 2s;
    animation-duration: 16s;
}

.hero-particle:nth-child(3) {
    width: 10px;
    height: 10px;
    background: var(--primary-color);
    bottom: 30%;
    left: 20%;
    animation-delay: 4s;
    animation-duration: 12s;
}

.hero-particle:nth-child(4) {
    width: 7px;
    height: 7px;
    background: var(--secondary-color);
    top: 40%;
    right: 25%;
    animation-delay: 1s;
    animation-duration: 15s;
}

.hero-particle:nth-child(5) {
    width: 9px;
    height: 9px;
    background: var(--primary-color);
    bottom: 20%;
    right: 10%;
    animation-delay: 3s;
    animation-duration: 13s;
}

@keyframes floatParticle {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.2;
    }
    25% {
        transform: translate(30px, -40px) scale(1.2);
        opacity: 0.4;
    }
    50% {
        transform: translate(-20px, -60px) scale(0.9);
        opacity: 0.3;
    }
    75% {
        transform: translate(40px, -30px) scale(1.1);
        opacity: 0.35;
    }
}

@media (max-width: 767px) {
    .hero-section::before {
        width: min(300px, 50vw);
        height: min(300px, 50vw);
    }
    
    .hero-section::after {
        width: min(250px, 40vw);
        height: min(250px, 40vw);
    }
}

@media (max-width: 319px) {
    .hero-section::before {
        width: min(200px, 60vw);
        height: min(200px, 60vw);
    }
    
    .hero-section::after {
        width: min(150px, 50vw);
        height: min(150px, 50vw);
    }
}

.hero-content {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    padding: 0 var(--spacing-md);
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
}

@media (min-width: 768px) {
    .hero-content {
        padding: 0;
    }
}

.hero-logo-wrapper {
    margin-bottom: var(--spacing-xl);
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInDown 0.6s ease-out;
}

/* Glassmorphism Icon Container */
.hero-icon-wrapper {
    margin-bottom: var(--spacing-xl);
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInDown 0.6s ease-out;
}

.hero-icon-container {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100px;
    height: 100px;
    padding: var(--spacing-lg);
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.1),
        0 2px 8px rgba(0, 0, 0, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.hero-icon-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(4, 80, 151, 0.08);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

.hero-icon-container:hover {
    transform: translateY(-8px) scale(1.05);
    box-shadow: 
        0 16px 48px rgba(4, 80, 151, 0.22),
        0 4px 16px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(4, 80, 151, 0.25);
}

.hero-icon-container:hover::before {
    opacity: 1;
}

.hero-icon-container svg {
    position: relative;
    z-index: 1;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 4px rgba(4, 80, 151, 0.2));
}

.hero-icon-container:hover svg {
    transform: scale(1.1);
    filter: drop-shadow(0 4px 8px rgba(4, 80, 151, 0.3));
    stroke: var(--primary-color);
}

@media (max-width: 767px) {
    .hero-icon-container {
        width: 80px;
        height: 80px;
        padding: var(--spacing-md);
    }
    
    .hero-icon-container svg {
        width: 48px;
        height: 48px;
    }
    
    /* Reduce particle animation on mobile for performance */
    .hero-particle {
        animation-duration: 20s;
    }
    
    /* Simplify gradient animations on mobile */
    .hero-section::before,
    .hero-section::after {
        animation-duration: 25s;
    }
}

@media (max-width: 480px) {
    .hero-icon-container {
        width: 70px;
        height: 70px;
        padding: var(--spacing-sm);
    }
    
    .hero-icon-container svg {
        width: 40px;
        height: 40px;
    }
    
    /* Hide some particles on very small screens */
    .hero-particle:nth-child(4),
    .hero-particle:nth-child(5) {
        display: none;
    }
}

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

.hero-logo {
    width: 120px;
    height: auto;
    max-width: 150px;
    filter: drop-shadow(0 4px 12px rgba(16, 110, 60, 0.2));
    transition: transform var(--transition-base);
    position: relative;
    z-index: 1;
}

@media (min-width: 768px) {
    .hero-logo {
        width: 150px;
    }
}

.hero-logo:hover {
    transform: scale(1.05);
}

/* Enhanced Homepage Logo with Glow Effect */
.hero-logo-enhanced {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.hero-logo-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(13, 107, 205, 0.2) 0%, rgba(255, 158, 0, 0.1) 50%, transparent 70%);
    border-radius: 50%;
    animation: logoGlowPulse 3s ease-in-out infinite;
    z-index: 0;
    pointer-events: none;
}

@media (min-width: 768px) {
    .hero-logo-glow {
        width: 220px;
        height: 220px;
    }
}

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

.hero-logo-enhanced:hover .hero-logo-glow {
    animation-duration: 1.5s;
    background: radial-gradient(circle, rgba(13, 107, 205, 0.25) 0%, rgba(255, 158, 0, 0.15) 50%, transparent 70%);
}

/* Homepage Hero Specific Styles */
.hero-homepage {
    padding: var(--spacing-3xl) 0 var(--spacing-2xl);
    position: relative;
}

.hero-homepage .hero-stats {
    margin-top: var(--spacing-xl);
    padding: var(--spacing-xl) var(--spacing-lg);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.7) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 4px 16px rgba(13, 107, 205, 0.1), 0 2px 8px rgba(255, 158, 0, 0.05);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.hero-homepage .hero-stats::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--brand-blue) 0%, var(--brand-orange) 100%);
    opacity: 0.6;
}

.hero-homepage .hero-stats:hover {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    box-shadow: 0 8px 24px rgba(13, 107, 205, 0.15), 0 4px 12px rgba(255, 158, 0, 0.1);
    transform: translateY(-4px);
}

.hero-homepage .hero-stat-item {
    transition: transform 0.3s ease;
}

.hero-homepage .hero-stat-item:hover {
    transform: translateY(-2px);
}

@media (min-width: 768px) {
    .hero-homepage {
        padding: var(--spacing-3xl) 0;
    }
    
    .hero-homepage .hero-stats {
        padding: var(--spacing-xl) var(--spacing-2xl);
    }
}

.hero-title {
    font-size: clamp(1.75rem, 8vw, 4.5rem);
    margin-bottom: var(--spacing-lg);
    background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-orange) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    animation: fadeInUp 0.6s ease-out 0.1s both;
    transition: transform 0.3s ease;
    position: relative;
}

.hero-title:hover {
    transform: translateY(-2px);
}

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

.hero-description {
    font-size: clamp(var(--font-size-base), 2.5vw, var(--font-size-lg));
    color: var(--text-secondary);
    margin-bottom: var(--spacing-2xl);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7; /* Improved readability */
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

/* Ensure sufficient contrast for all text on colored backgrounds */
.category-card,
.quick-access-card,
.resource-card {
    color: var(--text-primary); /* Ensure high contrast text */
}

.category-description,
.quick-access-description,
.resource-description {
    color: var(--text-secondary); /* Meets WCAG AA (7:1 contrast) */
}

.hero-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-2xl);
    padding: var(--spacing-lg) 0;
    flex-wrap: wrap;
    animation: fadeInUp 0.6s ease-out 0.3s both;
}

.hero-stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-xs);
}

.hero-stat-number {
    font-size: clamp(1.5rem, 5vw, var(--font-size-3xl));
    font-weight: 700;
    background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-orange) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    transition: transform 0.3s ease;
}

.hero-stat-item:hover .hero-stat-number {
    transform: scale(1.1);
    color: var(--primary-dark);
}

/* Animated stat numbers */
.hero-stat-number.animate {
    animation: numberPop 0.5s ease-out;
}

@keyframes numberPop {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.hero-stat-label {
    font-size: clamp(var(--font-size-xs), 2vw, var(--font-size-sm));
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hero-stat-divider {
    width: 1px;
    height: 40px;
    background: var(--gray-300);
    opacity: 0.5;
}

@media (max-width: 767px) {
    .hero-stat-divider {
        display: none;
    }
    
    .hero-stats {
        gap: var(--spacing-md);
    }
    
    .hero-stat-number {
        font-size: clamp(1.25rem, 6vw, var(--font-size-2xl));
    }
}

@media (max-width: 319px) {
    .hero-stats {
        gap: var(--spacing-sm);
        padding: var(--spacing-sm) 0;
    }
    
    .hero-stat-number {
        font-size: clamp(1rem, 8vw, 1.5rem);
    }
}

/* Scroll-triggered animations */
.hero-section.fade-in-on-scroll {
    opacity: 0;
    transition: opacity 0.6s ease-out;
}

.hero-section.fade-in-on-scroll.visible {
    opacity: 1;
    animation: heroFadeIn 0.8s ease-out forwards;
}

.hero-section.fade-in-on-scroll.visible .hero-content > * {
    animation: fadeInUp 0.6s ease-out forwards;
}

.hero-section.fade-in-on-scroll.visible .hero-icon-wrapper {
    animation-delay: 0.1s;
}

.hero-section.fade-in-on-scroll.visible .hero-title {
    animation-delay: 0.2s;
}

.hero-section.fade-in-on-scroll.visible .hero-description {
    animation-delay: 0.3s;
}

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

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .hero-section::before,
    .hero-section::after,
    .hero-particle,
    .hero-icon-container,
    .hero-title {
        animation: none !important;
        transition: none !important;
    }
    
    .hero-section.fade-in-on-scroll {
        opacity: 1 !important;
    }
    
    .hero-icon-container:hover {
        transform: none !important;
    }
}

@media (max-width: 319px) {
    .hero-stat-label {
        font-size: var(--font-size-xs);
    }
}

/* Section Styles */
.section-title {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    color: var(--text-primary);
}

/* Premium Section Titles */
.premium-section-title {
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--spacing-2xl);
    margin-top: var(--spacing-3xl);
    padding-bottom: var(--spacing-lg);
    position: relative;
    letter-spacing: -0.02em;
    line-height: 1.2;
    text-align: center;
}

.premium-section-title:first-child {
    margin-top: 0;
}

.premium-section-title::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--primary-color);
    border-radius: var(--radius-sm);
}

.premium-section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 2px;
    background: var(--secondary-color);
    border-radius: var(--radius-sm);
    opacity: 0.6;
}

/* Hub Overview / Stats Dashboard */
.hub-overview-section {
    margin-bottom: var(--spacing-3xl);
    padding: var(--spacing-2xl) 0;
}

.stats-dashboard {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
    max-width: 1000px;
    margin: 0 auto;
}

@media (min-width: 480px) {
    .stats-dashboard {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .stats-dashboard {
        grid-template-columns: repeat(4, 1fr);
    }
}

.stat-card {
    background: var(--bg-secondary);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    text-align: center;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-base);
}

.stat-card:hover::before {
    transform: scaleX(1);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(16, 110, 60, 0.12);
    border-color: var(--primary-color);
}

.stat-card-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto var(--spacing-md);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    border-radius: var(--radius-lg);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(16, 110, 60, 0.2);
}

.stat-card-number {
    font-size: var(--font-size-3xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--spacing-xs);
    line-height: 1;
}

.stat-card-label {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Categories Section */
.categories-section {
    margin-bottom: var(--spacing-3xl);
    padding: var(--spacing-2xl) 0;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
}

/* Category Grid */
.category-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
    width: 100%;
    max-width: 100%;
}

@media (min-width: 480px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-xl);
    }
}

@media (min-width: 768px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-xl);
    }
}

@media (min-width: 1024px) {
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1440px) {
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1921px) {
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
        max-width: 1600px;
        margin: 0 auto;
    }
}

@media (max-width: 319px) {
    .category-grid {
        gap: var(--spacing-md);
    }
}

/* Quick Access Section */
.quick-access-section {
    background-color: var(--bg-secondary);
    padding: var(--spacing-2xl) 0;
    border-radius: var(--radius-xl);
    margin-top: var(--spacing-3xl);
    margin-bottom: var(--spacing-3xl);
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
}

.quick-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--spacing-md);
}

.quick-link {
    padding: var(--spacing-md) var(--spacing-lg);
    background-color: var(--bg-primary);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    font-weight: 500;
    transition: all var(--transition-base);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.quick-link:hover {
    background-color: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 16px rgba(16, 110, 60, 0.2);
}

.quick-link:active {
    background-color: var(--primary-dark);
    transform: translateY(-1px);
}

.quick-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Sidebar Footer */
.sidebar-footer {
    margin-top: auto;
    padding: var(--spacing-xl) var(--spacing-lg) var(--spacing-lg);
    border-top: 1px solid var(--gray-200);
    text-align: left;
    flex-shrink: 0;
}

.sidebar-footer p {
    margin: 0;
    margin-bottom: var(--spacing-xs);
    font-size: var(--font-size-xs);
    color: var(--text-muted);
    line-height: 1.6;
}

.sidebar-footer p:last-child {
    margin-bottom: 0;
}

.footer-note {
    font-size: var(--font-size-xs);
    opacity: 0.75;
}

/* Hide sidebar footer on mobile */
@media (max-width: 767px) {
    .sidebar-footer {
        display: none;
    }
}

/* Legacy footer - hidden */
.main-footer {
    display: none;
}

/* Utility Classes */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.sr-only:focus {
    position: static;
    width: auto;
    height: auto;
    padding: inherit;
    margin: inherit;
    overflow: visible;
    clip: auto;
    white-space: normal;
}

.skip-link {
    position: absolute;
    top: -100px;
    left: var(--spacing-md);
    background: var(--primary-color);
    color: var(--white);
    padding: var(--spacing-md) var(--spacing-lg);
    text-decoration: none;
    z-index: 10000;
    border-radius: var(--radius-md);
    font-weight: 600;
    transition: top var(--transition-base);
    box-shadow: var(--shadow-lg);
}

.skip-link:focus,
.skip-link:focus-visible {
    top: var(--spacing-md);
    outline: 3px solid var(--white);
    outline-offset: 2px;
}

/* PWA Install Modal - aligned with Styling Guide modal pattern */
.install-modal {
    position: fixed;
    inset: 0;
    z-index: var(--z-modal);
    display: none;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg);
}

.install-modal[style*="display: block"],
.install-modal[style*="display:block"] {
    display: flex;
}

.install-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.install-modal-content {
    position: relative;
    background: var(--bg-surface);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-2xl);
    max-width: 480px;
    width: 100%;
    padding: 0;
    border: 1px solid var(--border-subtle);
    overflow: hidden;
}

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

.install-modal-header {
    padding: var(--spacing-xl);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    border-bottom: 1px solid var(--border-subtle);
}

.install-modal-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-lg);
    background: rgba(249, 250, 251, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.install-modal-icon svg {
    width: 24px;
    height: 24px;
    stroke: var(--secondary-color);
}

.install-modal-header h3 {
    margin: 0;
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--text-primary);
}

.install-modal-body {
    padding: var(--spacing-xl);
}

.install-modal-body p {
    margin: 0;
    font-size: var(--font-size-base);
    line-height: 1.8;
    color: var(--text-secondary);
    white-space: pre-line;
}

.install-modal-footer {
    padding: var(--spacing-lg) var(--spacing-xl);
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-subtle);
    display: flex;
    justify-content: flex-end;
}

.btn-modal-close {
    padding: var(--spacing-md) var(--spacing-xl);
    background: var(--bg-surface);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: var(--font-size-base);
    cursor: pointer;
    transition: all var(--transition-base);
    min-height: 44px;
}

.btn-modal-close:hover {
    background: var(--secondary-color);
    color: var(--white);
    border-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

/* Toast Notifications - Styling Guide pattern */
.toast {
    position: fixed;
    bottom: var(--spacing-xl);
    right: var(--spacing-xl);
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-primary);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    z-index: var(--z-toast);
    min-width: 300px;
    max-width: 500px;
    opacity: 0;
    transform: translateY(20px);
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

.toast-success {
    border-left: 4px solid var(--primary-color);
}

.toast-error {
    border-left: 4px solid #ef4444;
    color: #dc2626;
}

.toast-info {
    border-left: 4px solid var(--secondary-color);
}

@media (max-width: 767px) {
    .toast {
        right: var(--spacing-md);
        left: var(--spacing-md);
        min-width: auto;
        max-width: none;
    }
}

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

.mt-lg {
    margin-top: var(--spacing-lg);
}

.mb-lg {
    margin-bottom: var(--spacing-lg);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: calc(72px + var(--spacing-lg));
    right: var(--spacing-xl);
    width: 56px;
    height: 56px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 50%;
    box-shadow: 0 4px 16px rgba(16, 110, 60, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: var(--z-fixed);
    opacity: 0;
    transform: translateY(20px) scale(0.8);
    transition: all var(--transition-base);
    pointer-events: none;
}

.back-to-top.show {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 6px 20px rgba(16, 110, 60, 0.4);
}

.back-to-top:active {
    transform: translateY(-2px) scale(1);
}

.back-to-top:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
    box-shadow: 0 0 0 4px rgba(16, 110, 60, 0.2), 0 6px 20px rgba(16, 110, 60, 0.4);
}

.back-to-top svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
}

@media (max-width: 767px) {
    .back-to-top {
        bottom: calc(70px + var(--spacing-md) + env(safe-area-inset-bottom, 0px));
        right: var(--spacing-md);
        width: 48px;
        height: 48px;
    }
    
    .back-to-top svg {
        width: 18px;
        height: 18px;
    }
}

/* ========================================
   Premium Preloader Screen Styles - On-Brand Redesign
   ======================================== */

/* Preloader Overlay - Full Screen Coverage */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    min-width: 100%;
    min-height: 100%;
    display: flex !important;
    align-items: center;
    justify-content: center;
    z-index: 999999 !important;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.6s ease-out, visibility 0.6s ease-out;
    pointer-events: all;
    overflow: hidden;
    margin: 0;
    padding: 0;
    background: var(--white);
}

/* Hide body overflow when preloader is active */
body:has(#preloader:not(.fade-out)) {
    overflow: hidden !important;
    height: 100vh !important;
    position: fixed !important;
    width: 100% !important;
}

.preloader.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.preloader.fade-out .preloader-content {
    transform: scale(0.95);
    opacity: 0;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.preloader.fade-out .preloader-background {
    opacity: 0;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.preloader.fade-out .preloader-animation-area {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Animated Gradient Background - Eco brand (Deep Navy, Sky Blue) */
.preloader-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    min-width: 100vw;
    min-height: 100vh;
    background: linear-gradient(135deg, rgba(4, 80, 151, 0.08) 0%, rgba(107, 185, 240, 0.06) 50%, rgba(4, 80, 151, 0.06) 100%);
    background-size: 200% 200%;
    animation: gradientFlow 12s ease-in-out infinite;
    z-index: 0;
    margin: 0;
    padding: 0;
    pointer-events: none;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes gradientFlow {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Preloader Content Container - Clean Modern Design, brand typography */
.preloader-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--spacing-3xl) var(--spacing-xl);
    background: transparent;
    width: 100%;
    height: 100%;
    max-width: 100%;
    min-height: 100vh;
    font-family: var(--font-family);
    animation: contentFadeIn 0.8s ease-out;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    transform: scale(1);
    opacity: 1;
}

@keyframes contentFadeIn {
    from {
        opacity: 0;
        transform: scale(0.98) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Welcome Text - On-brand (Deep Navy) */
.preloader-welcome {
    font-size: var(--font-size-sm);
    font-weight: 600;
    letter-spacing: 0.2em;
    margin-bottom: var(--spacing-xl);
    color: var(--primary-dark);
    font-family: var(--font-family-headings);
    text-transform: uppercase;
    opacity: 0;
    animation: fadeInDown 0.6s ease-out 0.2s forwards;
}

/* Logo Wrapper with Enhanced Brand Glow */
.preloader-logo-wrapper {
    margin-bottom: var(--spacing-2xl);
    opacity: 0;
    animation: logoEntrance 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s forwards;
    position: relative;
    padding: var(--spacing-lg);
}

.preloader-logo-wrapper::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(4, 80, 151, 0.15) 0%, rgba(107, 185, 240, 0.1) 50%, transparent 70%);
    border-radius: 50%;
    animation: logoGlowPulse 3s ease-in-out infinite;
    z-index: -1;
}

.preloader-logo {
    width: 160px;
    height: auto;
    display: block;
    filter: drop-shadow(0 4px 20px rgba(4, 80, 151, 0.25));
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

@keyframes logoEntrance {
    0% {
        opacity: 0;
        transform: scale(0.7) translateY(30px);
    }
    60% {
        transform: scale(1.08) translateY(0);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@keyframes logoGlowPulse {
    0%, 100% {
        opacity: 0.6;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.15);
    }
}

/* App Name - Bold brand gradient (Deep Navy → Sky Blue) */
.preloader-app-name {
    font-size: clamp(1.75rem, 5vw, var(--font-size-4xl));
    font-weight: 700;
    margin-bottom: var(--spacing-3xl);
    letter-spacing: -0.02em;
    font-family: var(--font-family-headings);
    background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-orange) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    opacity: 0;
    animation: fadeInUp 0.8s ease-out 0.6s forwards;
    line-height: 1.2;
    position: relative;
}

/* Loading Indicator - Modern Brand-Colored Spinner */
.preloader-loading-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    opacity: 0;
    animation: fadeIn 0.6s ease-out 0.9s forwards;
    margin-bottom: var(--spacing-3xl);
}

/* Individual Loading Dots - Brand Colors */
.loading-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    animation: dotBounce 1.4s ease-in-out infinite;
    box-shadow: 0 2px 8px rgba(13, 107, 205, 0.3);
}

.loading-dot:nth-child(1) {
    background: var(--brand-blue);
    animation-delay: 0s;
}

.loading-dot:nth-child(2) {
    background: var(--brand-orange);
    animation-delay: 0.2s;
    box-shadow: 0 2px 8px rgba(107, 185, 240, 0.35);
}

.loading-dot:nth-child(3) {
    background: var(--brand-blue);
    animation-delay: 0.4s;
}

@keyframes dotBounce {
    0%, 100% {
        opacity: 0.5;
        transform: translateY(0) scale(0.9);
    }
    50% {
        opacity: 1;
        transform: translateY(-8px) scale(1.1);
    }
}

/* Animated Bottom Section */
.preloader-animation-area {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    padding: var(--spacing-3xl) var(--spacing-xl);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-xl);
    opacity: 0;
    animation: fadeInUp 0.8s ease-out 1.1s forwards;
    z-index: 2;
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateY(0);
}

/* Animated Particles Container - Brand Colors */
.animated-particles {
    position: relative;
    width: 100%;
    max-width: 600px;
    height: 120px;
    margin: 0 auto;
}

/* Individual Particles - Brand Color Gradients */
.particle {
    position: absolute;
    border-radius: 50%;
    opacity: 0.5;
    animation: floatParticle 10s ease-in-out infinite;
    filter: blur(1px);
}

.particle-1 {
    width: 70px;
    height: 70px;
    background: rgba(4, 80, 151, 0.28);
    top: 10%;
    left: 10%;
    animation-delay: 0s;
    animation-duration: 12s;
}

.particle-2 {
    width: 50px;
    height: 50px;
    background: rgba(107, 185, 240, 0.28);
    top: 30%;
    right: 15%;
    animation-delay: 1.5s;
    animation-duration: 14s;
}

.particle-3 {
    width: 60px;
    height: 60px;
    background: rgba(4, 80, 151, 0.22);
    bottom: 20%;
    left: 20%;
    animation-delay: 3s;
    animation-duration: 11s;
}

.particle-4 {
    width: 45px;
    height: 45px;
    background: rgba(107, 185, 240, 0.22);
    top: 50%;
    right: 25%;
    animation-delay: 0.8s;
    animation-duration: 13s;
}

.particle-5 {
    width: 55px;
    height: 55px;
    background: rgba(4, 80, 151, 0.18);
    bottom: 10%;
    right: 10%;
    animation-delay: 2.2s;
    animation-duration: 15s;
}

.particle-6 {
    width: 40px;
    height: 40px;
    background: rgba(107, 185, 240, 0.18);
    top: 15%;
    left: 50%;
    animation-delay: 1.8s;
    animation-duration: 12s;
}

@keyframes floatParticle {
    0%, 100% {
        transform: translate(0, 0) scale(1) rotate(0deg);
        opacity: 0.4;
    }
    25% {
        transform: translate(25px, -35px) scale(1.15) rotate(90deg);
        opacity: 0.7;
    }
    50% {
        transform: translate(-20px, -60px) scale(0.95) rotate(180deg);
        opacity: 0.6;
    }
    75% {
        transform: translate(35px, -25px) scale(1.1) rotate(270deg);
        opacity: 0.8;
    }
}

/* Tagline Text - On-brand secondary text */
.preloader-tagline {
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--text-secondary);
    font-family: var(--font-family);
    letter-spacing: 0.08em;
    text-align: center;
    margin: 0;
    opacity: 0;
    animation: fadeIn 1s ease-out 1.4s forwards;
    position: relative;
    z-index: 3;
}

.preloader-tagline::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--brand-blue);
    margin-right: var(--spacing-md);
    vertical-align: middle;
    opacity: 0.8;
    animation: pulse 2s ease-in-out infinite;
}

.preloader-tagline::after {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--brand-orange);
    margin-left: var(--spacing-md);
    vertical-align: middle;
    opacity: 0.8;
    animation: pulse 2s ease-in-out infinite 0.5s;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.6;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.2);
    }
}

/* Content Hidden State */
.content-hidden {
    opacity: 0 !important;
    visibility: hidden !important;
    transition: opacity 0.5s ease-in, visibility 0.5s ease-in;
    overflow: hidden;
}

.content-hidden.fade-in {
    opacity: 1;
    visibility: visible;
}

/* Preloader Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ========================================
   Responsive Styles
   ======================================== */

/* Small Mobile Devices */
@media (max-width: 480px) {
    .preloader-content {
        padding: var(--spacing-xl) var(--spacing-lg);
        max-width: 100%;
    }
    
    .preloader-welcome {
        font-size: var(--font-size-xs);
        margin-bottom: var(--spacing-lg);
        letter-spacing: 0.15em;
    }
    
    .preloader-logo-wrapper {
        padding: var(--spacing-md);
        margin-bottom: var(--spacing-xl);
    }
    
    .preloader-logo-wrapper::before {
        width: 140px;
        height: 140px;
    }
    
    .preloader-logo {
        width: 110px;
    }
    
    .preloader-app-name {
        font-size: clamp(1.5rem, 6vw, 2rem);
        margin-bottom: var(--spacing-2xl);
    }
    
    .loading-dot {
        width: 8px;
        height: 8px;
    }
    
    .preloader-loading-dots {
        gap: var(--spacing-xs);
        margin-bottom: var(--spacing-2xl);
    }
    
    .preloader-animation-area {
        padding: var(--spacing-xl) var(--spacing-lg);
        gap: var(--spacing-lg);
    }
    
    .animated-particles {
        height: 80px;
        max-width: 100%;
    }
    
    .particle-1 {
        width: 45px;
        height: 45px;
    }
    
    .particle-2 {
        width: 35px;
        height: 35px;
    }
    
    .particle-3 {
        width: 40px;
        height: 40px;
    }
    
    .particle-4 {
        width: 30px;
        height: 30px;
    }
    
    .particle-5 {
        width: 35px;
        height: 35px;
    }
    
    .particle-6 {
        width: 25px;
        height: 25px;
    }
    
    .preloader-tagline {
        font-size: var(--font-size-sm);
    }
    
    .preloader-tagline::before,
    .preloader-tagline::after {
        width: 6px;
        height: 6px;
    }
}

/* Mobile Devices */
@media (max-width: 767px) {
    .preloader-content {
        padding: var(--spacing-2xl) var(--spacing-lg);
        max-width: 100%;
    }
    
    .preloader-welcome {
        font-size: var(--font-size-sm);
        margin-bottom: var(--spacing-lg);
    }
    
    .preloader-logo-wrapper {
        padding: var(--spacing-md);
        margin-bottom: var(--spacing-xl);
    }
    
    .preloader-logo-wrapper::before {
        width: 160px;
        height: 160px;
    }
    
    .preloader-logo {
        width: 130px;
    }
    
    .preloader-app-name {
        font-size: clamp(1.75rem, 5vw, 2.5rem);
        margin-bottom: var(--spacing-2xl);
    }
    
    .loading-dot {
        width: 9px;
        height: 9px;
    }
    
    .preloader-loading-dots {
        gap: var(--spacing-xs);
        margin-bottom: var(--spacing-2xl);
    }
    
    .preloader-animation-area {
        padding: var(--spacing-2xl) var(--spacing-lg);
        gap: var(--spacing-lg);
    }
    
    .animated-particles {
        height: 100px;
    }
    
    .preloader-tagline {
        font-size: var(--font-size-sm);
    }
}

/* Tablet Devices */
@media (min-width: 768px) and (max-width: 1023px) {
    .preloader-content {
        padding: var(--spacing-3xl) var(--spacing-xl);
        max-width: 100%;
    }
    
    .preloader-logo-wrapper::before {
        width: 180px;
        height: 180px;
    }
    
    .preloader-logo {
        width: 150px;
    }
    
    .preloader-app-name {
        font-size: clamp(2rem, 4vw, 2.75rem);
    }
}

/* Desktop Devices */
@media (min-width: 1024px) {
    .preloader-content {
        padding: var(--spacing-3xl) var(--spacing-2xl);
        max-width: 100%;
    }
    
    .preloader-logo-wrapper::before {
        width: 220px;
        height: 220px;
    }
    
    .preloader-logo {
        width: 180px;
    }
    
    .preloader-app-name {
        font-size: clamp(2.25rem, 3vw, 3rem);
    }
}

/* Large Desktop Screens */
@media (min-width: 1920px) {
    .preloader-content {
        padding: var(--spacing-3xl) var(--spacing-2xl);
        max-width: 100%;
    }
    
    .preloader-logo-wrapper::before {
        width: 240px;
        height: 240px;
    }
    
    .preloader-logo {
        width: 200px;
    }
    
    .preloader-app-name {
        font-size: clamp(2.5rem, 2.5vw, 3.5rem);
    }
    
    .preloader-welcome {
        font-size: var(--font-size-base);
    }
    
    .preloader-animation-area {
        padding: var(--spacing-3xl) var(--spacing-2xl);
    }
    
    .animated-particles {
        height: 150px;
        max-width: 800px;
    }
    
    .preloader-tagline {
        font-size: var(--font-size-lg);
    }
}

/* ============================================
   LOGIN PAGE STYLES
   ============================================ */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #f0f7ff 0%, #f8fafc 45%, #ffffff 100%);
    padding: var(--spacing-lg);
    position: relative;
    overflow: hidden;
}

.login-container {
    width: 100%;
    max-width: 440px;
    position: relative;
    z-index: 1;
}

.login-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    z-index: 0;
}

.login-particle {
    position: absolute;
    border-radius: 50%;
    background: rgba(13, 107, 205, 0.08);
    animation: float 20s infinite ease-in-out;
    opacity: 0.6;
}

.login-particle:nth-child(2),
.login-particle:nth-child(4) {
    background: rgba(255, 158, 0, 0.08);
}

.login-particle:nth-child(1) {
    width: 80px;
    height: 80px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.login-particle:nth-child(2) {
    width: 120px;
    height: 120px;
    top: 60%;
    right: 10%;
    animation-delay: 2s;
}

.login-particle:nth-child(3) {
    width: 60px;
    height: 60px;
    bottom: 20%;
    left: 20%;
    animation-delay: 4s;
}

.login-particle:nth-child(4) {
    width: 100px;
    height: 100px;
    top: 30%;
    right: 20%;
    animation-delay: 6s;
}

.login-particle:nth-child(5) {
    width: 70px;
    height: 70px;
    bottom: 40%;
    right: 30%;
    animation-delay: 8s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(30px, -30px) rotate(120deg);
    }
    66% {
        transform: translate(-20px, 20px) rotate(240deg);
    }
}

.login-content {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: var(--spacing-3xl) var(--spacing-xl);
    box-shadow: var(--shadow-2xl);
    position: relative;
    z-index: 1;
    animation: fadeInUp 0.6s ease-out;
}

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

.login-logo-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: var(--spacing-xl);
}

.login-logo-glow {
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(13, 107, 205, 0.2) 0%, rgba(255, 158, 0, 0.1) 50%, transparent 70%);
    animation: logoGlowPulse 3s ease-in-out infinite;
}

.login-logo {
    width: 140px;
    height: auto;
    position: relative;
    z-index: 1;
}

.login-title {
    font-size: var(--font-size-3xl);
    font-weight: 700;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: var(--spacing-sm);
    font-family: var(--font-family-headings);
}

.login-tagline {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: var(--spacing-md);
    font-family: var(--font-family-headings);
}

.login-subtitle {
    font-size: var(--font-size-base);
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    line-height: 1.5;
}

.login-form {
    width: 100%;
}

.login-form-group {
    margin-bottom: var(--spacing-xl);
}

.login-label {
    display: block;
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
}

.login-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.login-input {
    width: 100%;
    padding: var(--spacing-md) var(--spacing-xl) var(--spacing-md) var(--spacing-md);
    font-size: var(--font-size-base);
    font-family: var(--font-family);
    color: var(--text-primary);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
    outline: none;
    padding-right: 50px;
    min-height: 44px;
}

.login-input:focus {
    border-color: var(--primary-color);
    background: var(--white);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 18%, transparent);
}

.login-input.error {
    border-color: #ef4444;
    background: #fef2f2;
}

.login-input.error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.login-toggle-password {
    position: absolute;
    right: var(--spacing-sm);
    background: transparent;
    border: none;
    padding: var(--spacing-sm);
    cursor: pointer;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: color var(--transition-fast);
    z-index: 1;
}

.login-toggle-password:hover {
    color: var(--primary-color);
}

.login-toggle-password:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.login-toggle-password svg {
    width: 20px;
    height: 20px;
}

.login-error {
    margin-top: var(--spacing-sm);
    font-size: var(--font-size-sm);
    color: #ef4444;
    display: none;
    min-height: 20px;
}

.login-error.show {
    display: block;
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-10px);
    }
    75% {
        transform: translateX(10px);
    }
}

.login-button {
    width: 100%;
    padding: var(--spacing-md) var(--spacing-xl);
    font-size: var(--font-size-base);
    font-weight: 600;
    font-family: var(--font-family);
    color: var(--white);
    background: var(--primary-color);
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    box-shadow: var(--shadow-md);
    min-height: 48px;
}

.login-button:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.login-button:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: var(--shadow-md);
}

.login-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.login-button-text {
    display: inline;
}

.login-button-loader {
    display: none;
    animation: spin 1s linear infinite;
}

.login-button-loader svg {
    width: 20px;
    height: 20px;
}

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

.login-presentation-link {
    margin-top: var(--spacing-xl);
    text-align: center;
    font-size: var(--font-size-sm);
}

.login-presentation-link a {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
}

.login-presentation-link a:hover {
    text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 767px) {
    .login-page {
        padding: var(--spacing-md);
    }
    
    .login-content {
        padding: var(--spacing-2xl) var(--spacing-lg);
    }
    
    .login-logo {
        width: 120px;
    }
    
    .login-logo-glow {
        width: 150px;
        height: 150px;
    }
    
    .login-title {
        font-size: var(--font-size-2xl);
    }
    
    .login-subtitle {
        font-size: var(--font-size-sm);
    }
}

/* Tablet Responsive */
@media (min-width: 768px) and (max-width: 1023px) {
    .login-content {
        padding: var(--spacing-3xl) var(--spacing-2xl);
    }
}

/* Desktop Responsive */
@media (min-width: 1024px) {
    .login-content {
        padding: var(--spacing-3xl) var(--spacing-2xl);
    }
}
