/* UASS University - New Academic Design System */

/* 1. ROOT VARIABLES ================================================== */
@import url('https://fonts.googleapis.com/css2?family=Merriweather:wght@400;700&family=Inter:wght@400;500;700&display=swap');

:root {
    /* Color Palette */
    --primary-color: #003366; /* Deep Navy Blue */
    --secondary-color: #A4B0BD; /* Steel Blue/Grey */
    --accent-color: #FFD700; /* Gold */
    --background-color: #FFFFFF; /* White */
    --surface-color: #F8F9FA; /* Light Grey for cards/sections */
    --text-color: #212529; /* Dark Grey for text */
    --heading-color: var(--primary-color);
    --link-color: var(--primary-color);
    --link-hover-color: var(--accent-color);
    --border-color: #DEE2E6;
    
    /* Typography */
    --font-heading: 'Merriweather', serif;
    --font-body: 'Inter', sans-serif;
    
    /* Spacing */
    --space-xs: 0.25rem; /* 4px */
    --space-sm: 0.5rem;  /* 8px */
    --space-md: 1rem;    /* 16px */
    --space-lg: 1.5rem;  /* 24px */
    --space-xl: 2rem;    /* 32px */
    --space-2xl: 4rem;   /* 64px */
    
    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    
    /* Transitions */
    --transition: 300ms ease-in-out;
}

/* 2. BASE & RESET STYLES ============================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    overflow-x: hidden;
    scroll-behavior: smooth;
    padding-top: 80px; /* Added to prevent fixed navbar from overlapping content */
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--space-2xl) 0;
}

/* 3. TYPOGRAPHY ====================================================== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--heading-color);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: var(--space-lg);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: var(--space-md);
}

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

a:hover {
    color: var(--link-hover-color);
    text-decoration: underline;
}

/* 4. NAVIGATION ====================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    padding: var(--space-md) 0;
    z-index: 1000;
    transition: all var(--transition);
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-md);
    padding: var(--space-sm) 0;
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.logo-img {
    height: 40px; /* Slightly smaller logo */
    width: auto;
    transition: transform var(--transition);
}
.logo-img:hover {
    transform: scale(1.05);
}

.nav-logo h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem; /* Slightly smaller logo text */
    color: var(--primary-color);
    margin: 0;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: var(--space-md); /* Further reduced gap for better spacing */
}

.nav-link {
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 0.9rem; /* Slightly smaller font size */
    color: var(--primary-color);
    padding-bottom: var(--space-sm);
    border-bottom: 2px solid transparent;
    transition: all var(--transition);
    white-space: nowrap; /* Prevent text wrapping */
}

.nav-link:hover, .nav-link.active {
    color: var(--accent-color);
    border-bottom-color: var(--accent-color);
    text-decoration: none;
}

.nav-actions {
    display: flex;
    gap: var(--space-md);
    align-items: center;
}

.search-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.25rem;
    cursor: pointer;
    transition: color var(--transition);
}
.search-btn:hover {
    color: var(--accent-color);
}

.hamburger {
    display: none;
    cursor: pointer;
}

.hamburger .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--primary-color);
    transition: all 0.3s ease-in-out;
}

/* 5. BUTTONS ========================================================= */
.btn {
    display: inline-block;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 1rem;
    padding: var(--space-sm) var(--space-lg);
    border-radius: var(--radius-sm);
    border: 2px solid transparent;
    cursor: pointer;
    text-align: center;
    transition: all var(--transition);
    text-decoration: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--background-color);
    border-color: var(--primary-color);
}
.btn-primary:hover {
    background-color: #002244; /* Darker navy */
    border-color: #002244;
    color: var(--background-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    text-decoration: none;
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-secondary:hover {
    background-color: var(--primary-color);
    color: var(--background-color);
    text-decoration: none;
}

.btn-accent {
    background-color: var(--accent-color);
    color: var(--primary-color);
    border-color: var(--accent-color);
}
.btn-accent:hover {
    background-color: #E6C300; /* Darker Gold */
    border-color: #E6C300;
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    text-decoration: none;
}

/* 6. HERO SECTION ==================================================== */
.hero {
    position: relative;
    padding: var(--space-2xl) 0;
    color: var(--background-color);
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: url('https://tcglivenew.s3.amazonaws.com/images/school/fea2564a-0b65-46d9-b2b9-31cc7f361a25.jpg') no-repeat center center/cover;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 51, 102, 0.7); /* Dark blue overlay */
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3.5rem;
    color: var(--background-color);
    font-weight: 700;
    margin-bottom: var(--space-lg);
}

.hero p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: var(--space-xl);
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: var(--space-lg);
    margin-top: var(--space-xl);
}

.hero-buttons .btn-primary {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: var(--primary-color);
}
.hero-buttons .btn-primary:hover {
    background-color: #E6C300;
    border-color: #E6C300;
    color: var(--primary-color);
}
.hero-buttons .btn-secondary {
    border-color: var(--background-color);
    color: var(--background-color);
}
.hero-buttons .btn-secondary:hover {
    background-color: var(--background-color);
    color: var(--primary-color);
}


/* 7. SECTION STYLES ================================================== */
.section-header {
    text-align: center;
    margin-bottom: var(--space-2xl);
}
.section-header h2 {
    position: relative;
    display: inline-block;
    padding-bottom: var(--space-md);
}
.section-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background-color: var(--accent-color);
}
.section-header p {
    max-width: 700px;
    margin: var(--space-md) auto 0;
    font-size: 1.1rem;
    color: var(--text-color);
}

/* 8. CARD COMPONENTS (Generic) ======================================= */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-xl);
}

.card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    transition: all var(--transition);
    box-shadow: var(--shadow-sm);
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.card h3 {
    margin-top: 0;
    color: var(--primary-color);
}

.card .learn-more {
    font-weight: 700;
    margin-top: var(--space-md);
    display: inline-block;
}

/* Applying generic card to program cards */
.program-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    text-align: center;
    transition: all var(--transition);
    box-shadow: var(--shadow-sm);
}
.program-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}
.program-icon {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: var(--space-md);
}
.program-card h3 {
    font-size: 1.25rem;
}

/* 9. FOOTER ========================================================== */
.footer {
    background-color: var(--primary-color);
    color: var(--background-color);
    padding-top: var(--space-2xl);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-xl);
    padding-bottom: var(--space-2xl);
}

.footer-section h3, .footer-section h4 {
    font-family: var(--font-heading);
    color: var(--accent-color);
    margin-bottom: var(--space-lg);
}

.footer-section p, .footer-section ul {
    color: rgba(255, 255, 255, 0.8);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: var(--space-sm);
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    transition: all var(--transition);
}
.footer-section a:hover {
    color: var(--accent-color);
    text-decoration: none;
    padding-left: var(--space-sm);
}

.social-links {
    display: flex;
    gap: var(--space-lg);
    margin-top: var(--space-md);
}
.social-links a {
    font-size: 1.5rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
    padding: var(--space-lg) 0;
}

/* 9.5. 404 PAGE ======================================================== */
.main-404 {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: calc(100vh - 200px); /* Adjust 200px based on header/footer height */
    padding: var(--space-2xl) 0;
}

.content-404 h1 {
    font-size: 8rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: var(--space-sm);
    line-height: 1;
}

.content-404 h2 {
    font-size: 2.5rem;
    color: var(--heading-color);
    margin-bottom: var(--space-md);
}

.content-404 p {
    font-size: 1.1rem;
    max-width: 500px;
    margin: 0 auto var(--space-xl);
}

.content-404 .btn {
    background-color: var(--primary-color);
    color: var(--background-color);
    border-color: var(--primary-color);
}

.content-404 .btn:hover {
    background-color: var(--accent-color);
    color: var(--primary-color);
    border-color: var(--accent-color);
    text-decoration: none;
    }


/* 10. RESPONSIVE DESIGN =============================================== */
@media (max-width: 1200px) { /* Adjusted breakpoint to 1200px for better mobile navigation */
    .nav-menu {
        display: flex; /* Changed from none to flex by default */
        flex-direction: column;
        align-items: center;
        background-color: var(--background-color);
        position: fixed; /* Changed from absolute */
        top: 80px; /* Height of the navbar, adjust if needed */
        left: 0;
        width: 100%;
        padding: var(--space-lg) 0;
        box-shadow: var(--shadow-lg);
        transform: translateX(-100%); /* Start off-screen */
        transition: transform 0.3s ease-in-out;
        z-index: 999; /* Ensure it's below the navbar but above other content */
    }
    .nav-menu.active {
        transform: translateX(0); /* Slide in */
    }
    .hamburger {
        display: block;
        z-index: 1001; /* Ensure hamburger is on top */
    }
    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }
    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .nav-logo h1 {
        font-size: 1.5rem; /* Adjust logo size on smaller screens */
    }
}

@media (max-width: 768px) {
    h1, .hero h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    .hero p { font-size: 1.1rem; }
    .hero-buttons { flex-direction: column; align-items: center; }
}

/* Keeping some utility classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: var(--background-color);
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
    z-index: 999;
}
.scroll-to-top:hover {
    background-color: var(--accent-color);
    color: var(--primary-color);
    transform: scale(1.1);
    }
.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Minimal styling for other existing components to avoid breaking them */
.featured-programs, .innovation-showcase, .news-events, .campus-gallery,
.student-stories, .featured-faculty, .innovation-labs, .campus-showcase, .live-stats {
    background-color: var(--background-color);
        padding: var(--space-2xl) 0;
    }
    
.student-stories {
    background-color: var(--surface-color);
    }
    
.news-item img, .gallery-item img, .faculty-image img, .lab-image img, .innovation-image img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
}

/* 11. CARD IMAGE FIX ================================================== */
.card-grid .card img {
    width: 100%;
    height: 200px; /* Fixed height for uniformity */
    object-fit: cover; /* Crop while keeping aspect ratio */
    border-radius: var(--radius-sm);
}

/* Removing old complex styles to prevent conflicts */
.hero-background, .hero-badge, .hero-features, .hero-stats {
    display: none;
}

/* Scroll to Top Button */ 