/**
 * Ipak Yo'li Innovatsiyalar Universiteti - Main Stylesheet
 * Silk Road Innovations University - Custom CSS
 * 
 * @author    University IT Department
 * @copyright 2025 Ipak Yo'li Innovatsiyalar Universiteti
 * @license   MIT
 * @version   1.0.0
 */

/* =============================================================================
   CSS VARIABLES - DESIGN SYSTEM
   ============================================================================= */

:root {
    /* Primary Colors */
    --color-primary: #001F3F;
    --color-primary-dark: #00152A;
    --color-primary-light: #003366;
    --color-primary-rgb: 0, 31, 63;
    
    /* Secondary Colors (Gold) */
    --color-secondary: #D4AF77;
    --color-secondary-dark: #B8956A;
    --color-secondary-light: #E5C88A;
    --color-secondary-rgb: 212, 175, 119;
    
    /* Accent Colors */
    --color-accent: #00A8E8;
    --color-accent-dark: #0086B6;
    --color-accent-light: #33C3FF;
    
    /* Neutral Colors */
    --color-white: #FFFFFF;
    --color-gray-50: #F8FAFC;
    --color-gray-100: #F1F5F9;
    --color-gray-200: #E2E8F0;
    --color-gray-300: #CBD5E1;
    --color-gray-400: #94A3B8;
    --color-gray-500: #64748B;
    --color-gray-600: #475569;
    --color-gray-700: #334155;
    --color-gray-800: #1E293B;
    --color-gray-900: #0F172A;
    --color-black: #000000;
    
    /* Semantic Colors */
    --color-success: #10B981;
    --color-warning: #F59E0B;
    --color-error: #EF4444;
    --color-info: #3B82F6;
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-display: 'Playfair Display', Georgia, serif;
    --font-uzbek: 'Noto Sans', sans-serif;
    
    /* Font Sizes */
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;
    --text-5xl: 3rem;
    --text-6xl: 3.75rem;
    --text-7xl: 4.5rem;
    
    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;
    
    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.375rem;
    --radius-lg: 0.5rem;
    --radius-xl: 0.75rem;
    --radius-2xl: 1rem;
    --radius-3xl: 1.5rem;
    --radius-full: 9999px;
    
    /* Shadows */
    --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);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-gold: 0 10px 40px -10px rgba(212, 175, 119, 0.5);
    --shadow-primary: 0 10px 40px -10px rgba(0, 31, 63, 0.5);
    
    /* Transitions */
    --transition-fast: 150ms ease-in-out;
    --transition-base: 250ms ease-in-out;
    --transition-slow: 350ms ease-in-out;
    --transition-slower: 500ms ease-in-out;
    
    /* Z-Index Scale */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;
    --z-popover: 600;
    --z-tooltip: 700;
    --z-toast: 800;
}

/* Dark Mode Variables */
[data-theme="dark"] {
    --color-primary: #0A2540;
    --color-primary-dark: #051524;
    --color-primary-light: #143D5C;
    
    --color-gray-50: #0F172A;
    --color-gray-100: #1E293B;
    --color-gray-200: #334155;
    --color-gray-300: #475569;
    --color-gray-400: #64748B;
    --color-gray-500: #94A3B8;
    --color-gray-600: #CBD5E1;
    --color-gray-700: #E2E8F0;
    --color-gray-800: #F1F5F9;
    --color-gray-900: #F8FAFC;
}

/* =============================================================================
   BASE STYLES
   ============================================================================= */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

body {
    font-family: var(--font-primary);
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--color-gray-800);
    background-color: var(--color-white);
    overflow-x: hidden;
}

body[data-theme="dark"] {
    color: var(--color-gray-200);
    background-color: var(--color-gray-900);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-primary);
}

body[data-theme="dark"] h1,
body[data-theme="dark"] h2,
body[data-theme="dark"] h3,
body[data-theme="dark"] h4,
body[data-theme="dark"] h5,
body[data-theme="dark"] h6 {
    color: var(--color-gray-100);
}

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

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

/* Selection */
::selection {
    background-color: var(--color-secondary);
    color: var(--color-primary);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--color-gray-100);
}

::-webkit-scrollbar-thumb {
    background: var(--color-gray-400);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-gray-500);
}

/* =============================================================================
   UTILITY CLASSES
   ============================================================================= */

/* Container */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding-left: var(--space-4);
    padding-right: var(--space-4);
}

@media (min-width: 640px) {
    .container {
        padding-left: var(--space-6);
        padding-right: var(--space-6);
    }
}

@media (min-width: 1024px) {
    .container {
        padding-left: var(--space-8);
        padding-right: var(--space-8);
    }
}

/* Section Spacing */
.section {
    padding-top: var(--space-16);
    padding-bottom: var(--space-16);
}

@media (min-width: 768px) {
    .section {
        padding-top: var(--space-20);
        padding-bottom: var(--space-20);
    }
}

@media (min-width: 1024px) {
    .section {
        padding-top: var(--space-24);
        padding-bottom: var(--space-24);
    }
}

/* Text Gradient */
.text-gradient {
    background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Glass Effect */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

body[data-theme="dark"] .glass {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* =============================================================================
   MEGA HEADER — 3-TIER NAVIGATION
   ============================================================================= */

.mega-header {
    position: relative;
    z-index: var(--z-fixed);
    transition: transform var(--transition-base);
}

.mega-header.header-hidden .topbar,
.mega-header.header-hidden .middlebar {
    max-height: 0;
    overflow: hidden;
    padding-top: 0;
    padding-bottom: 0;
    border-bottom: none;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.2s ease, padding 0.3s ease;
}

/* ===== TOP BAR ===== */
.topbar {
    background: var(--color-primary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.8rem;
    max-height: 200px;
    transition: max-height 0.3s ease, opacity 0.2s ease, padding 0.3s ease;
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 36px;
    gap: var(--space-4);
}

/* Marquee */
.topbar-marquee {
    flex: 1;
    overflow: hidden;
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}

.marquee-track {
    display: flex;
    width: max-content;
    animation: topbar-scroll 40s linear infinite;
}

.marquee-track:hover {
    animation-play-state: paused;
}

@keyframes topbar-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.marquee-content {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding-right: var(--space-12);
    color: rgba(255, 255, 255, 0.75);
    white-space: nowrap;
    font-weight: 400;
    letter-spacing: 0.01em;
}

.marquee-icon {
    color: var(--color-secondary);
    margin-right: var(--space-1);
    font-size: 0.7rem;
}

.marquee-separator {
    color: var(--color-secondary);
    opacity: 0.5;
    margin: 0 var(--space-3);
    font-size: 0.5rem;
}

/* Quick Links */
.topbar-links {
    display: none;
    align-items: center;
    gap: 0;
    flex-shrink: 0;
}

@media (min-width: 768px) {
    .topbar-links {
        display: flex;
    }
}

.topbar-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.78rem;
    font-weight: 500;
    transition: color var(--transition-fast);
    white-space: nowrap;
}

.topbar-link:hover {
    color: var(--color-white);
}

.topbar-link i {
    font-size: 0.7rem;
    color: var(--color-secondary);
}

.topbar-divider {
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, 0.15);
}

/* Language in top bar */
.topbar-lang {
    position: relative;
}

.topbar-lang-btn {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

.topbar-lang-btn span {
    text-transform: lowercase;
    font-weight: 600;
}

.topbar-lang-arrow {
    font-size: 0.55rem;
    transition: transform var(--transition-fast);
    margin-left: 2px;
}

.topbar-lang-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    width: 150px;
    background: var(--color-white);
    border-radius: var(--radius-lg);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--color-gray-100);
    padding: 4px 0;
    z-index: 100;
}

.topbar-lang-option {
    display: block;
    padding: 8px 16px;
    font-size: var(--text-sm);
    color: var(--color-gray-500);
    transition: background var(--transition-fast);
}

.topbar-lang-option:hover {
    background: var(--color-gray-50);
}

.topbar-lang-option.active {
    color: var(--color-gray-800);
    font-weight: 600;
    background: var(--color-gray-50);
}

body[data-theme="dark"] .topbar-lang-dropdown {
    background: var(--color-gray-800);
    border-color: var(--color-gray-700);
}

body[data-theme="dark"] .topbar-lang-option {
    color: var(--color-gray-300);
}

body[data-theme="dark"] .topbar-lang-option:hover {
    background: var(--color-gray-700);
}

body[data-theme="dark"] .topbar-lang-option.active {
    color: var(--color-white);
    background: var(--color-gray-700);
}

/* ===== MIDDLE BAR ===== */
.middlebar {
    background: var(--color-white);
    border-bottom: 1px solid var(--color-gray-100);
    padding: var(--space-3) 0;
    max-height: 200px;
    transition: max-height 0.3s ease, opacity 0.2s ease, padding 0.3s ease;
}

body[data-theme="dark"] .middlebar {
    background: var(--color-gray-900);
    border-bottom-color: var(--color-gray-800);
}

.middlebar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-6);
}

/* Logo / Brand in middlebar */
.middlebar-brand {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    flex-shrink: 0;
}

.middlebar-logo {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: var(--text-xl);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
    box-shadow: 0 4px 15px rgba(212, 175, 119, 0.3);
    overflow: hidden;
}

/* Real logo image inside middlebar */
.middlebar-logo.middlebar-logo-img {
    background: none !important;
    box-shadow: none !important;
    border-radius: 50% !important;
    width: 54px !important;
    height: 54px !important;
    min-width: 54px;
    min-height: 54px;
    border: 2px solid var(--color-gray-200);
    padding: 0;
}

.middlebar-logo.middlebar-logo-img img {
    width: 54px !important;
    height: 54px !important;
    max-width: 54px !important;
    max-height: 54px !important;
    object-fit: cover !important;
    border-radius: 50% !important;
    display: block !important;
}

.middlebar-brand:hover .middlebar-logo {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(212, 175, 119, 0.4);
}

.middlebar-brand-text {
    display: none;
}

@media (min-width: 640px) {
    .middlebar-brand-text {
        display: block;
    }
}

.middlebar-title {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.2;
    letter-spacing: -0.01em;
}

body[data-theme="dark"] .middlebar-title {
    color: var(--color-gray-100);
}

.middlebar-subtitle {
    font-size: 0.68rem;
    color: var(--color-gray-500);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Contact Items */
.middlebar-contacts {
    display: none;
    align-items: center;
    gap: var(--space-6);
}

@media (min-width: 1024px) {
    .middlebar-contacts {
        display: flex;
    }
}

.middlebar-contact-item {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.middlebar-contact-link {
    transition: opacity var(--transition-fast);
}

.middlebar-contact-link:hover {
    opacity: 0.8;
}

.middlebar-contact-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 31, 63, 0.06);
    color: var(--color-primary);
    font-size: var(--text-sm);
    flex-shrink: 0;
}

body[data-theme="dark"] .middlebar-contact-icon {
    background: rgba(212, 175, 119, 0.1);
    color: var(--color-secondary);
}

.middlebar-contact-info {
    display: flex;
    flex-direction: column;
}

.middlebar-contact-label {
    font-size: 0.68rem;
    color: var(--color-gray-400);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1;
    margin-bottom: 2px;
}

.middlebar-contact-value {
    font-size: var(--text-sm);
    color: var(--color-gray-700);
    font-weight: 500;
    line-height: 1.3;
    max-width: 260px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body[data-theme="dark"] .middlebar-contact-value {
    color: var(--color-gray-200);
}

.middlebar-contact-divider {
    width: 1px;
    height: 36px;
    background: var(--color-gray-200);
}

body[data-theme="dark"] .middlebar-contact-divider {
    background: var(--color-gray-700);
}

/* ===== BOTTOM BAR (Main Navigation) ===== */
.bottombar {
    background: var(--color-primary);
    position: relative;
    z-index: var(--z-fixed);
    transition: all var(--transition-base);
}

.bottombar-sticky {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    box-shadow: 0 4px 30px rgba(0, 31, 63, 0.15);
    will-change: transform;
}

/* Prevent layout shift when bottombar becomes fixed:
   without this spacer the content jumps up by 64px,
   which changes scrollY, re-triggers the sticky check,
   and creates an infinite shake/vibration loop. */
body.bottombar-is-sticky {
    padding-top: 64px;
}

.bottombar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    gap: var(--space-4);
}

/* Bottombar mini brand — hidden by default, visible only in sticky */
.bottombar-brand {
    display: none !important;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    text-decoration: none;
    opacity: 0;
    transform: translateX(-12px);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.bottombar-brand-logo {
    width: 40px !important;
    height: 40px !important;
    max-width: 40px !important;
    max-height: 40px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 2px solid rgba(212, 175, 119, 0.4);
    transition: border-color var(--transition-fast);
    flex-shrink: 0;
}

.bottombar-brand-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.bottombar-brand-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-white);
    white-space: nowrap;
    letter-spacing: -0.01em;
    line-height: 1.1;
    transition: color var(--transition-fast);
}

.bottombar-brand-subtitle {
    font-size: 0.55rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
    line-height: 1.2;
    transition: color var(--transition-fast);
}

.bottombar-brand:hover .bottombar-brand-logo {
    border-color: var(--color-secondary);
}

.bottombar-brand:hover .bottombar-brand-title {
    color: var(--color-secondary-light);
}

.bottombar-brand:hover .bottombar-brand-subtitle {
    color: rgba(255, 255, 255, 0.8);
}

/* Divider between brand and nav */
.bottombar-brand-divider {
    display: none !important;
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
    margin-right: var(--space-2);
}

/* Show brand + divider only in sticky state with slide-in animation */
.bottombar-sticky .bottombar-brand {
    display: flex !important;
    opacity: 1;
    transform: translateX(0);
}

.bottombar-sticky .bottombar-brand-divider {
    display: block !important;
}

/* Navigation Links */
.bottombar-nav {
    display: none;
    align-items: center;
    gap: 2px;
}

@media (min-width: 1024px) {
    .bottombar-nav {
        display: flex;
    }
}

.nav-dropdown-wrapper {
    position: relative;
}

.bottombar-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: var(--space-3) var(--space-5);
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    font-size: var(--text-base);
    transition: all var(--transition-fast);
    white-space: nowrap;
    position: relative;
    border-bottom: 2px solid transparent;
}

.bottombar-link:hover {
    color: var(--color-white);
    background: rgba(255, 255, 255, 0.08);
}

.bottombar-link.active {
    color: var(--color-white);
    border-bottom-color: var(--color-secondary);
}

.bottombar-link-icon {
    font-size: 0.55rem;
    opacity: 0.6;
    transition: transform var(--transition-fast);
}

.nav-dropdown-wrapper:hover .bottombar-link-icon {
    transform: rotate(45deg);
}

/* Dropdown Menus */
.nav-mega-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: var(--color-white);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
    border: 1px solid var(--color-gray-100);
    border-top: 3px solid var(--color-secondary);
    padding: var(--space-2) 0;
    z-index: 100;
}

body[data-theme="dark"] .nav-mega-dropdown {
    background: var(--color-gray-800);
    border-color: var(--color-gray-700);
    border-top-color: var(--color-secondary);
}

.mega-dropdown-item {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: 10px 20px;
    color: var(--color-gray-600);
    font-size: var(--text-sm);
    font-weight: 500;
    transition: all var(--transition-fast);
}

.mega-dropdown-item:hover {
    background: var(--color-gray-50);
    color: var(--color-primary);
    padding-left: 24px;
}

body[data-theme="dark"] .mega-dropdown-item {
    color: var(--color-gray-300);
}

body[data-theme="dark"] .mega-dropdown-item:hover {
    background: var(--color-gray-700);
    color: var(--color-white);
}

.mega-dropdown-item i {
    width: 16px;
    text-align: center;
    color: var(--color-secondary);
    font-size: 0.85rem;
}

/* Bottom bar Actions (right side) */
.bottombar-actions {
    display: none;
    align-items: center;
    gap: 4px;
}

@media (min-width: 1024px) {
    .bottombar-actions {
        display: flex;
    }
}

/* Search */
.bottombar-search {
    position: relative;
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.search-input-wrapper.search-expanded {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.2);
}

.search-input {
    width: 160px;
    padding: 7px 12px;
    background: transparent;
    border: none;
    outline: none;
    color: var(--color-white);
    font-size: var(--text-sm);
    font-family: inherit;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.search-toggle-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: color var(--transition-fast);
    font-size: var(--text-sm);
}

.search-toggle-btn:hover {
    color: var(--color-white);
}

/* Icon Buttons */
.bottombar-icon-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-lg);
    color: rgba(255, 255, 255, 0.7);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: var(--text-sm);
}

.bottombar-icon-btn:hover {
    color: var(--color-white);
    background: rgba(255, 255, 255, 0.1);
}

/* Grid Menu Button */
.bottombar-grid-btn {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-primary-dark);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
    padding: 0;
}

.bottombar-grid-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.grid-dots {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
}

.grid-dots span {
    width: 4px;
    height: 4px;
    border-radius: 1px;
    background: var(--color-white);
    transition: background var(--transition-fast);
}

/* Mega Menu Panel */
.mega-menu-panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-white);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    border-top: 3px solid var(--color-secondary);
    z-index: 99;
    padding: var(--space-8) 0;
}

body[data-theme="dark"] .mega-menu-panel {
    background: var(--color-gray-900);
}

.mega-menu-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-4);
}

@media (min-width: 768px) {
    .mega-menu-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

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

.mega-menu-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-4);
    border-radius: var(--radius-xl);
    transition: all var(--transition-fast);
    text-align: center;
}

.mega-menu-item:hover {
    background: var(--color-gray-50);
    transform: translateY(-2px);
}

body[data-theme="dark"] .mega-menu-item:hover {
    background: var(--color-gray-800);
}

.mega-menu-item-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 31, 63, 0.06);
    color: var(--color-primary);
    font-size: var(--text-lg);
    transition: all var(--transition-fast);
}

body[data-theme="dark"] .mega-menu-item-icon {
    background: rgba(212, 175, 119, 0.1);
    color: var(--color-secondary);
}

.mega-menu-item:hover .mega-menu-item-icon {
    background: var(--color-primary);
    color: var(--color-white);
    box-shadow: var(--shadow-primary);
}

.mega-menu-item span {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-gray-600);
    line-height: 1.2;
}

body[data-theme="dark"] .mega-menu-item span {
    color: var(--color-gray-300);
}

/* ===== Mobile Menu Button ===== */
.mobile-menu-btn {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: var(--space-2);
    background: none;
    border: none;
    cursor: pointer;
}

@media (min-width: 1024px) {
    .mobile-menu-btn {
        display: none;
    }
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--color-white);
    transition: all var(--transition-base);
    border-radius: var(--radius-full);
}

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

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

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

/* ===== Mobile Navigation Panel ===== */
.navbar-mobile {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--color-white);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    padding: var(--space-4);
    gap: var(--space-1);
    transform: translateX(100%);
    transition: transform var(--transition-base);
    overflow-y: auto;
    z-index: calc(var(--z-fixed) + 10);
}

body[data-theme="dark"] .navbar-mobile {
    background: var(--color-gray-900);
}

.navbar-mobile.active {
    transform: translateX(0);
}

@media (min-width: 1024px) {
    .navbar-mobile {
        display: none !important;
    }
}

.navbar-mobile-header {
    padding-bottom: var(--space-4);
    margin-bottom: var(--space-2);
    border-bottom: 1px solid var(--color-gray-100);
}

body[data-theme="dark"] .navbar-mobile-header {
    border-bottom-color: var(--color-gray-800);
}

/* Nav Links (for mobile panel) */
.nav-link {
    padding: var(--space-2) var(--space-3);
    color: var(--color-gray-700);
    font-weight: 500;
    font-size: var(--text-sm);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
    position: relative;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.nav-link-icon {
    margin-right: 10px;
    width: 18px;
    text-align: center;
    color: var(--color-gray-400);
}

.navbar-mobile .nav-link {
    color: var(--color-gray-700);
    padding: var(--space-3) var(--space-4);
    font-size: var(--text-base);
    border-radius: var(--radius-lg);
}

.navbar-mobile .nav-link:hover {
    background: var(--color-gray-50);
}

body[data-theme="dark"] .navbar-mobile .nav-link {
    color: var(--color-gray-200);
}

.navbar-mobile .nav-link.active {
    color: var(--color-primary);
    background: rgba(0, 31, 63, 0.05);
    font-weight: 600;
}

.navbar-mobile .nav-link.active .nav-link-icon {
    color: var(--color-primary);
}

body[data-theme="dark"] .navbar-mobile .nav-link.active {
    color: var(--color-secondary);
    background: rgba(212, 175, 119, 0.1);
}

.navbar-mobile .nav-link.active::after {
    display: none;
}

/* Mobile Contact Info */
.navbar-mobile-contacts {
    margin-top: var(--space-4);
    padding-top: var(--space-4);
    border-top: 1px solid var(--color-gray-100);
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

body[data-theme="dark"] .navbar-mobile-contacts {
    border-top-color: var(--color-gray-800);
}

.mobile-contact-item {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-2) var(--space-4);
    color: var(--color-gray-500);
    font-size: var(--text-sm);
}

.mobile-contact-item i {
    color: var(--color-secondary);
    width: 18px;
    text-align: center;
}

.navbar-mobile-cta {
    margin-top: var(--space-4);
    padding-top: var(--space-4);
    border-top: 1px solid var(--color-gray-200);
}

body[data-theme="dark"] .navbar-mobile-cta {
    border-top-color: var(--color-gray-800);
}

.navbar-mobile-cta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: var(--space-3) var(--space-4);
    background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
    color: var(--color-primary);
    font-weight: 600;
    font-size: var(--text-base);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
    box-shadow: var(--shadow-gold);
}

.navbar-mobile-cta-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 25px rgba(212, 175, 119, 0.4);
}

/* =============================================================================
   HERO SECTION
   ============================================================================= */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--color-primary);
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(0, 31, 63, 0.85) 0%,
        rgba(0, 31, 63, 0.65) 50%,
        rgba(0, 31, 63, 0.85) 100%
    );
    z-index: 1;
}

.hero-bg-pattern {
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(212, 175, 119, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 168, 232, 0.1) 0%, transparent 50%),
        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='%23D4AF77' fill-opacity='0.03'%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.5;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: left;
    padding: var(--space-8) 0;
    max-width: 800px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: rgba(212, 175, 119, 0.2);
    border: 1px solid rgba(212, 175, 119, 0.3);
    border-radius: var(--radius-full);
    color: var(--color-secondary);
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: 130px; /* Increased to push title down further */
    animation: fadeInDown 0.8s ease-out;
}

.hero-badge-icon {
    width: 8px;
    height: 8px;
    background: var(--color-secondary);
    border-radius: var(--radius-full);
    animation: pulse 2s infinite;
}

.hero-title {
    font-size: var(--text-4xl);
    font-weight: 800;
    color: var(--color-white);
    margin-top: 130px; /* Replaces the gap previously provided by badge, increased to clear building text */
    margin-bottom: var(--space-4);
    line-height: 1.1;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

@media (min-width: 640px) {
    .hero-title {
        font-size: var(--text-5xl);
    }
}

@media (min-width: 768px) {
    .hero-title {
        font-size: var(--text-6xl);
    }
}

@media (min-width: 1024px) {
    .hero-title {
        font-size: var(--text-7xl);
    }
}

.hero-title-accent {
    color: var(--color-secondary);
}

.hero-slogan {
    font-size: var(--text-xl);
    color: var(--color-gray-300);
    margin-bottom: var(--space-8);
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

@media (min-width: 768px) {
    .hero-slogan {
        font-size: var(--text-2xl);
    }
}

.hero-cta {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    align-items: flex-start;
    animation: fadeInUp 0.8s ease-out 0.6s both;
}

@media (min-width: 640px) {
    .hero-cta {
        flex-direction: row;
        justify-content: flex-start;
    }
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-6);
    margin-top: var(--space-16);
    padding-top: var(--space-8);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    animation: fadeInUp 0.8s ease-out 0.8s both;
    max-width: 800px;
}

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

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

.hero-stat-value {
    font-size: var(--text-3xl);
    font-weight: 800;
    color: var(--color-secondary);
    line-height: 1;
}

@media (min-width: 768px) {
    .hero-stat-value {
        font-size: var(--text-4xl);
    }
}

.hero-stat-label {
    font-size: var(--text-sm);
    color: var(--color-gray-400);
    margin-top: var(--space-2);
}

/* Hero Layout Grid */
.hero-layout-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
    width: 100%;
}
@media (min-width: 1024px) {
    .hero-layout-grid {
        flex-direction: row;
        gap: 6rem;
    }
}

/* Hero Circular Badge Custom Classes */
.hero-circular-badge-container {
    display: none;
    flex: 1;
    justify-content: center;
    align-items: center;
    position: relative;
}
@media (min-width: 1024px) {
    .hero-circular-badge-container {
        display: flex;
    }
}
.hero-circular-badge {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 320px;
    height: 320px;
}
.circular-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    color: rgba(255, 255, 255, 0.9);
}
.circular-text {
    font-size: 11px;
    letter-spacing: 3px;
    fill: currentColor;
    font-weight: 700;
    text-transform: uppercase;
}
.circular-logo-wrapper {
    position: absolute;
    width: 144px;
    height: 144px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 50px rgba(212, 175, 119, 0.3);
}
.circular-logo-inner {
    width: 112px;
    height: 112px;
    background: linear-gradient(to top right, var(--color-secondary), var(--color-secondary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 20px rgba(0,0,0,0.1);
}
.animate-spin-slow {
    animation: spin-slow 20s linear infinite;
}
@keyframes spin-slow {
    100% { transform: rotate(360deg); }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: var(--space-8);
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    animation: bounce 2s infinite;
}

.scroll-indicator-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, var(--color-secondary), transparent);
}

/* =============================================================================
   BUTTONS
   ============================================================================= */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    font-size: var(--text-base);
    font-weight: 600;
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

/* Ensure text and icons stay above the background animation */
.btn > * {
    position: relative;
    z-index: 2;
}

.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s;
}

.btn:hover::before {
    transform: translateX(100%);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
    color: var(--color-primary);
    box-shadow: var(--shadow-gold);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 50px -10px rgba(212, 175, 119, 0.6);
}

.btn-secondary {
    background: transparent;
    color: var(--color-white);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--color-white);
}

.btn-outline {
    background: transparent;
    color: var(--color-primary);
    border: 2px solid var(--color-primary);
    transition: color 0.7s ease, border-color 0.7s ease;
}

.btn-outline::after {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--color-primary);
    z-index: -1;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-outline:hover {
    color: var(--color-white);
    border-color: var(--color-primary);
}

.btn-outline:hover::after {
    transform: scaleX(1);
}

.btn-lg {
    padding: var(--space-4) var(--space-8);
    font-size: var(--text-lg);
}

.btn-sm {
    padding: var(--space-2) var(--space-4);
    font-size: var(--text-sm);
}

.btn-icon {
    width: 20px;
    height: 20px;
}

/* =============================================================================
   CARDS
   ============================================================================= */

.card {
    background: var(--color-white);
    border-radius: var(--radius-2xl);
    overflow: hidden;
    transition: all var(--transition-base);
    border: 1px solid var(--color-gray-200);
}

body[data-theme="dark"] .card {
    background: var(--color-gray-800);
    border-color: var(--color-gray-700);
}

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

.card-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 10;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card-content {
    padding: var(--space-6);
}

.card-title {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: var(--space-2);
}

body[data-theme="dark"] .card-title {
    color: var(--color-gray-100);
}

.card-description {
    color: var(--color-gray-600);
    font-size: var(--text-sm);
    line-height: 1.6;
}

body[data-theme="dark"] .card-description {
    color: var(--color-gray-400);
}

/* 3D Card Effect */
.card-3d {
    perspective: 1000px;
}

.card-3d-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform var(--transition-base);
    transform-style: preserve-3d;
}

.card-3d:hover .card-3d-inner {
    transform: rotateY(5deg) rotateX(5deg);
}

/* =============================================================================
   SECTION HEADERS
   ============================================================================= */

.section-header {
    text-align: center;
    margin-bottom: var(--space-12);
}

.section-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-secondary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: var(--space-4);
}

.section-label::before,
.section-label::after {
    content: '';
    width: 24px;
    height: 2px;
    background: var(--color-secondary);
}

.section-title {
    font-size: var(--text-3xl);
    font-weight: 800;
    color: var(--color-primary);
    margin-bottom: var(--space-4);
}

@media (min-width: 768px) {
    .section-title {
        font-size: var(--text-4xl);
    }
}

.section-description {
    font-size: var(--text-lg);
    color: var(--color-gray-600);
    max-width: 600px;
    margin: 0 auto;
}

body[data-theme="dark"] .section-description {
    color: var(--color-gray-400);
}

/* =============================================================================
   FORMS
   ============================================================================= */

.form-group {
    margin-bottom: var(--space-6);
}

.form-label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-gray-700);
    margin-bottom: var(--space-2);
}

body[data-theme="dark"] .form-label {
    color: var(--color-gray-300);
}

.form-label-required::after {
    content: ' *';
    color: var(--color-error);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: var(--space-3) var(--space-4);
    font-size: var(--text-base);
    color: var(--color-gray-800);
    background: var(--color-white);
    border: 2px solid var(--color-gray-200);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

body[data-theme="dark"] .form-input,
body[data-theme="dark"] .form-select,
body[data-theme="dark"] .form-textarea {
    color: var(--color-gray-200);
    background: var(--color-gray-800);
    border-color: var(--color-gray-700);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--color-secondary);
    box-shadow: 0 0 0 3px rgba(212, 175, 119, 0.2);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--color-gray-400);
}

.form-input.error,
.form-select.error,
.form-textarea.error {
    border-color: var(--color-error);
}

.form-input.error:focus,
.form-select.error:focus,
.form-textarea.error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

.form-error {
    font-size: var(--text-sm);
    color: var(--color-error);
    margin-top: var(--space-1);
}

.form-hint {
    font-size: var(--text-xs);
    color: var(--color-gray-500);
    margin-top: var(--space-1);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

/* File Upload */
.file-upload {
    position: relative;
    border: 2px dashed var(--color-gray-300);
    border-radius: var(--radius-xl);
    padding: var(--space-8);
    text-align: center;
    transition: all var(--transition-fast);
    cursor: pointer;
}

.file-upload:hover {
    border-color: var(--color-secondary);
    background: rgba(212, 175, 119, 0.05);
}

.file-upload.dragover {
    border-color: var(--color-secondary);
    background: rgba(212, 175, 119, 0.1);
}

.file-upload-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.file-upload-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto var(--space-4);
    color: var(--color-gray-400);
}

.file-upload-text {
    font-size: var(--text-sm);
    color: var(--color-gray-600);
    margin-bottom: var(--space-2);
}

.file-upload-hint {
    font-size: var(--text-xs);
    color: var(--color-gray-400);
}

/* Checkbox & Radio */
.form-checkbox,
.form-radio {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    cursor: pointer;
}

.form-checkbox-input,
.form-radio-input {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: var(--color-primary);
}

.form-checkbox-label,
.form-radio-label {
    font-size: var(--text-sm);
    color: var(--color-gray-700);
}

/* =============================================================================
   PROGRESS BAR (Multi-step Form)
   ============================================================================= */

.progress-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: var(--space-8);
    position: relative;
}

.progress-steps::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--color-gray-200);
    z-index: 0;
}

body[data-theme="dark"] .progress-steps::before {
    background: var(--color-gray-700);
}

.progress-step {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
}

.progress-step-number {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-white);
    border: 2px solid var(--color-gray-300);
    border-radius: var(--radius-full);
    font-weight: 600;
    color: var(--color-gray-500);
    transition: all var(--transition-base);
}

body[data-theme="dark"] .progress-step-number {
    background: var(--color-gray-800);
    border-color: var(--color-gray-600);
    color: var(--color-gray-400);
}

.progress-step.active .progress-step-number,
.progress-step.completed .progress-step-number {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--color-white);
}

.progress-step.completed .progress-step-number {
    background: var(--color-success);
    border-color: var(--color-success);
}

.progress-step-label {
    font-size: var(--text-xs);
    font-weight: 500;
    color: var(--color-gray-500);
    text-align: center;
}

.progress-step.active .progress-step-label {
    color: var(--color-primary);
    font-weight: 600;
}

body[data-theme="dark"] .progress-step.active .progress-step-label {
    color: var(--color-secondary);
}

/* Progress Bar Line */
.progress-bar {
    height: 4px;
    background: var(--color-gray-200);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: var(--space-6);
}

body[data-theme="dark"] .progress-bar {
    background: var(--color-gray-700);
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--color-secondary) 0%, var(--color-primary) 100%);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

/* =============================================================================
   ALERTS & MESSAGES
   ============================================================================= */

.alert {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    margin-bottom: var(--space-4);
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: var(--color-success);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.2);
    color: var(--color-warning);
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: var(--color-error);
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    color: var(--color-info);
}

.alert-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: var(--space-4);
    right: var(--space-4);
    z-index: var(--z-toast);
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4) var(--space-6);
    background: var(--color-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    animation: slideInRight 0.3s ease-out;
    max-width: 400px;
}

body[data-theme="dark"] .toast {
    background: var(--color-gray-800);
}

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

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

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

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

/* =============================================================================
   LOADING SPINNER
   ============================================================================= */

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--color-gray-200);
    border-top-color: var(--color-secondary);
    border-radius: var(--radius-full);
    animation: spin 1s linear infinite;
}

.spinner-sm {
    width: 20px;
    height: 20px;
    border-width: 2px;
}

.spinner-lg {
    width: 60px;
    height: 60px;
    border-width: 4px;
}

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

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: var(--z-modal);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-content {
    text-align: center;
    color: var(--color-white);
}

.loading-text {
    margin-top: var(--space-4);
    font-size: var(--text-lg);
}

/* =============================================================================
   MODAL
   ============================================================================= */

.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: var(--z-modal-backdrop);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    background: var(--color-white);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-2xl);
    z-index: var(--z-modal);
    max-width: 90vw;
    max-height: 90vh;
    overflow: auto;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

body[data-theme="dark"] .modal {
    background: var(--color-gray-800);
}

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

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

body[data-theme="dark"] .modal-header {
    border-color: var(--color-gray-700);
}

.modal-title {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--color-primary);
}

body[data-theme="dark"] .modal-title {
    color: var(--color-gray-100);
}

.modal-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-lg);
    color: var(--color-gray-500);
    transition: all var(--transition-fast);
}

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

.modal-body {
    padding: var(--space-6);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: var(--space-3);
    padding: var(--space-6);
    border-top: 1px solid var(--color-gray-200);
}

body[data-theme="dark"] .modal-footer {
    border-color: var(--color-gray-700);
}

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

.footer {
    background: var(--color-primary);
    color: var(--color-white);
    padding-top: var(--space-16);
    padding-bottom: var(--space-8);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-8);
    margin-bottom: var(--space-12);
}

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

@media (min-width: 1024px) {
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr 1fr;
    }
}

.footer-brand {
    max-width: 300px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-4);
}

.footer-logo-icon {
    width: 48px;
    height: 48px;
    background: var(--color-secondary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-weight: 700;
    font-size: var(--text-xl);
}

.footer-logo-text {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    font-weight: 700;
}

.footer-description {
    color: var(--color-gray-400);
    font-size: var(--text-sm);
    line-height: 1.6;
    margin-bottom: var(--space-4);
}

.footer-social {
    display: flex;
    gap: var(--space-3);
}

.footer-social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    color: var(--color-white);
    transition: all var(--transition-fast);
}

.footer-social-link:hover {
    background: var(--color-secondary);
    color: var(--color-primary);
}

.footer-title {
    font-size: var(--text-lg);
    font-weight: 700;
    margin-bottom: var(--space-4);
    color: var(--color-secondary);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.footer-link {
    color: var(--color-gray-400);
    font-size: var(--text-sm);
    transition: color var(--transition-fast);
}

.footer-link:hover {
    color: var(--color-white);
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    color: var(--color-gray-400);
    font-size: var(--text-sm);
    margin-bottom: var(--space-3);
}

.footer-contact-icon {
    width: 20px;
    height: 20px;
    color: var(--color-secondary);
    flex-shrink: 0;
}

.footer-bottom {
    padding-top: var(--space-8);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-4);
    text-align: center;
}

@media (min-width: 640px) {
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
    }
}

.footer-copyright {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

.footer-legal {
    display: flex;
    gap: var(--space-6);
}

.footer-legal-link {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
    transition: color var(--transition-fast);
}

.footer-legal-link:hover {
    color: var(--color-white);
}

/* =============================================================================
   ANIMATIONS
   ============================================================================= */

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

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

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

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

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

@keyframes slideInUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

@keyframes slideInDown {
    from {
        transform: translateY(-100%);
    }
    to {
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

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

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

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

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

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

/* Animation Classes */
.animate-fadeIn {
    animation: fadeIn 0.6s ease-out forwards;
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease-out forwards;
}

.animate-fadeInDown {
    animation: fadeInDown 0.6s ease-out forwards;
}

.animate-fadeInLeft {
    animation: fadeInLeft 0.6s ease-out forwards;
}

.animate-fadeInRight {
    animation: fadeInRight 0.6s ease-out forwards;
}

.animate-scaleIn {
    animation: scaleIn 0.4s ease-out forwards;
}

.animate-bounce {
    animation: bounce 2s infinite;
}

.animate-pulse {
    animation: pulse 2s infinite;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* Animation Delays */
.delay-100 { animation-delay: 100ms; }
.delay-200 { animation-delay: 200ms; }
.delay-300 { animation-delay: 300ms; }
.delay-400 { animation-delay: 400ms; }
.delay-500 { animation-delay: 500ms; }
.delay-600 { animation-delay: 600ms; }
.delay-700 { animation-delay: 700ms; }
.delay-800 { animation-delay: 800ms; }

/* =============================================================================
   UTILITY CLASSES
   ============================================================================= */

/* Display */
.hidden { display: none !important; }
.block { display: block; }
.inline { display: inline; }
.inline-block { display: inline-block; }
.flex { display: flex; }
.inline-flex { display: inline-flex; }

/* Progress Scroll To Top */
.progress-wrap {
    position: fixed;
    right: 30px;
    bottom: 30px;
    height: 50px;
    width: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: inset 0 0 0 2px rgba(0, 31, 63, 0.05); /* very light inner border */
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
    background-color: var(--color-white);
}
.progress-wrap.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.progress-wrap svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.progress-wrap svg.progress-circle {
    transform: rotate(-90deg); /* Start at 12 o'clock */
}
.progress-wrap svg path {
    fill: none;
}
/* The empty track background (optional, but looks premium) */
.progress-wrap svg.progress-circle-bg path {
    stroke: rgba(0, 31, 63, 0.1);
    stroke-width: 4;
}
/* The filling progress */
.progress-wrap svg.progress-circle path.progress-path {
    stroke: var(--color-primary);
    stroke-width: 4;
    stroke-linecap: round; /* Rounded edges for professional look */
    box-sizing: border-box;
    stroke-dasharray: 308; 
    stroke-dashoffset: 308;
}
.progress-wrap i {
    z-index: 2;
    font-size: 1.25rem; /* 20px */
    color: var(--color-primary);
    transition: all 300ms ease;
    margin-top: -2px; /* Visual center tweak */
}
.progress-wrap:hover {
    transform: translateY(-4px);
    box-shadow: inset 0 0 0 2px rgba(0, 31, 63, 0.1), 0 5px 15px rgba(0, 31, 63, 0.1);
}
.progress-wrap:hover svg.progress-circle path.progress-path {
    stroke: var(--color-secondary);
}
.progress-wrap:hover i {
    color: var(--color-secondary);
}
.grid { display: grid; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }

/* Text Alignment */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }

/* Font Weight */
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

/* Text Transform */
.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }

/* Visibility */
.visible { visibility: visible; }
.invisible { visibility: hidden; }

/* Overflow */
.overflow-hidden { overflow: hidden; }
.overflow-auto { overflow: auto; }
.overflow-scroll { overflow: scroll; }

/* Cursor */
.cursor-pointer { cursor: pointer; }
.cursor-not-allowed { cursor: not-allowed; }

/* User Select */
.select-none { user-select: none; }
.select-all { user-select: all; }

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

/* =============================================================================
   PRINT STYLES
   ============================================================================= */

@media print {
    .mega-header,
    .footer,
    .scroll-indicator,
    .no-print {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    .hero {
        min-height: auto;
        padding: 2rem 0;
    }
    
    .card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ccc;
    }
}

/* =============================================================================
   PROFILE ENHANCEMENTS: TIMELINE & NOTIFICATIONS
   ============================================================================= */

/* Vertical Timeline */
.timeline-container {
    position: relative;
    padding-left: 2.5rem;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 0.875rem;
    top: 0.5rem;
    bottom: 0.5rem;
    width: 2px;
    background: var(--color-gray-200);
}

.timeline-step {
    position: relative;
    padding-bottom: 2rem;
}

.timeline-step:last-child {
    padding-bottom: 0;
}

.timeline-icon {
    position: absolute;
    left: -2.5rem;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    background: var(--color-white);
    border: 2px solid var(--color-gray-300);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    z-index: 1;
    transition: all var(--transition-base);
}

.timeline-step.active .timeline-icon {
    border-color: var(--color-primary);
    color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(var(--color-primary-rgb), 0.1);
}

.timeline-step.completed .timeline-icon {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--color-white);
}

.timeline-step.completed + .timeline-step::before {
    background: var(--color-primary);
}

/* Notifications badge */
.notification-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background-color: var(--color-error);
    color: white;
    font-size: 10px;
    font-weight: 700;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--color-white);
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

/* Notification card */
.notification-item {
    transition: transform var(--transition-fast), background var(--transition-fast);
}

.notification-item.unread {
    background-color: rgba(var(--color-primary-rgb), 0.03);
    border-left: 3px solid var(--color-primary);
}

.notification-item:hover {
    background-color: var(--color-gray-50);
}


/* =============================================================================
   SEARCH & LIVE RESULTS STYLES
   ============================================================================= */

.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f8fafc;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-xl);
    padding: 0 4px;
    transition: all var(--transition-base);
    width: 44px;
    height: 44px;
    overflow: hidden;
}

.search-input-wrapper.search-expanded {
    width: 280px;
    background: rgba(0, 0, 0, 0.2);
    border-color: var(--color-secondary);
    box-shadow: 0 0 15px rgba(212, 175, 119, 0.3);
}

@media (min-width: 640px) {
    .search-input-wrapper.search-expanded {
        width: 350px;
    }
}

.search-input {
    background: transparent;
    border: none;
    color: white;
    font-size: 0.9rem;
    padding-left: 12px;
    width: 100%;
    height: 100%;
    outline: none !important;
}

.search-toggle-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-secondary);
    flex-shrink: 0;
    transition: transform var(--transition-fast);
}

.search-toggle-btn:hover {
    transform: scale(1.1);
    color: var(--color-white);
}