﻿/* --- MODERN & CLEAN EDUCATIONAL THEME --- */

:root {
    --primary-blue: #004a99;   /* A professional, academic blue */
    --accent-blue: #007bff;     /* A brighter blue for hovers and accents */
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --text-dark: #212529;
    --text-secondary: #6c757d;
    --border-color: #dee2e6;
    --header-height: 75px;
    --font-primary: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 10px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.1); /* Stronger shadow */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-light);
    font-family: var(--font-primary);
    color: var(--text-dark);
    padding-top: calc(35px + var(--header-height)); /* Top bar + Main header */
    transition: padding-top 0.3s ease; /* Smooth transition for padding */
}

/* 1. HEADER - TWO-TIER STRUCTURE */
.header-uni {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--bg-white);
    transition: all 0.3s ease;
}

/* TOP BAR (Contact info, Socials) */
.header-top-bar {
    height: 35px;
    background-color: #f1f3f5;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    font-size: 0.85rem;
    overflow: hidden; /* Hide content when height is 0 */
    transition: all 0.3s ease;
}

.top-bar-contact a, .top-bar-socials a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s ease;
    margin-left: 20px;
}
.top-bar-contact a:hover, .top-bar-socials a:hover {
    color: var(--primary-blue);
}
.top-bar-contact i, .top-bar-socials i {
    margin-right: 5px;
}

/* MAIN HEADER (Logo, Nav) */
.header-main {
    height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    box-shadow: var(--shadow-sm);
    transition: height 0.3s ease;
}

.logo-block {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}
.logo-img {
    height: 50px;
    transition: height 0.3s ease;
}
.logo-text {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-blue);
    line-height: 1.2;
    transition: all 0.3s ease;
}

.navbar-main {
    flex-grow: 1;
    display: flex;
    justify-content: center;
}

.navbar-nav {
    display: flex !important;             /* Force flex display */
    flex-direction: row !important;       /* Force horizontal layout */
    list-style: none;
    gap: 5px; /* Gap for visual separation, padding will handle spacing */
    align-items: center; /* Vertically center items */
}

.nav-link {
    padding: 10px 18px;
    border-radius: 6px;
    color: var(--text-dark);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.25s ease;
}
.nav-link:hover {
    background-color: var(--accent-blue);
    color: var(--bg-white);
    transform: translateY(-2px);
}
.nav-link.active {
    background-color: var(--primary-blue);
    color: var(--bg-white);
}

/* === SCROLLED STATE === */
.header-scrolled .header-top-bar {
    height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    visibility: hidden;
}
.header-scrolled .header-main {
    height: 60px; /* New, smaller height */
    box-shadow: var(--shadow-md); /* Add more shadow when scrolled */
}
.header-scrolled .logo-img {
    height: 40px; /* Smaller logo */
}
.header-scrolled .logo-text {
    font-size: 1rem;
    font-weight: 600;
}
body.scrolled {
    padding-top: 60px; /* Adjust body padding to match smaller header */
}

/* 2. MAIN CONTENT */
.container.body-content {
    background: var(--bg-white);
    max-width: 1140px;
    margin: 40px auto;
    padding: 40px;
    border-radius: 8px; /* Slightly softer radius */
    box-shadow: var(--shadow-lg); /* Use the new stronger shadow */
    border-top: 5px solid var(--primary-blue); /* Add the accent border */
}

/* 3. FOOTER */
.main-footer {
    background: var(--primary-blue);
    color: #adb5bd;
    padding: 60px 0 0 0;
    margin-top: 40px; /* Add some space above footer */
}
.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    text-align: left; /* Align text to the left in columns */
}
.footer-col h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--bg-white);
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}
.footer-col h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background: var(--accent-blue);
}
.footer-col p, .footer-col ul {
    list-style: none;
    padding: 0;
}
.footer-col a {
    color: #adb5bd;
    text-decoration: none;
    transition: color 0.2s;
    line-height: 2.2;
}
.footer-col a:hover {
    color: var(--bg-white);
}

.footer-logo-block {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: white;
    margin-bottom: 15px;
}
.footer-logo-block .logo-img {
    height: 45px;
}
.footer-about {
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 20px;
}
.contact-list li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 15px;
}
.contact-list i {
    margin-right: 15px;
    margin-top: 5px;
    color: var(--accent-blue);
}
.map-container {
    border-radius: 8px;
    overflow: hidden;
    height: 200px;
}
.map-container iframe {
    filter: grayscale(1);
    transition: filter 0.3s;
}
.map-container:hover iframe {
    filter: grayscale(0);
}

.footer-bottom {
    border-top: 1px solid #003d80;
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
    font-size: 0.9rem;
    color: #ced4da;
}
.footer-socials a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    color: white;
    margin-right: 10px;
    transition: background-color 0.2s ease;
}
.footer-socials a:hover {
    background: var(--accent-blue);
}

/* RESPONSIVE TOGGLE */
.mobile-nav-toggle { display: none; }

@media (max-width: 992px) {
    .navbar-main {
        display: none; /* Hide nav by default on mobile */
        position: absolute;
        top: 110px; /* 35px top bar + 75px main header */
        left: 0;
        width: 100%;
        background: var(--bg-white);
        box-shadow: var(--shadow-md);
    }
    .header-uni.nav-open .navbar-main {
        display: block; /* Show when nav is open */
    }
    .header-uni.nav-open .navbar-nav {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }
    .header-uni.nav-open .nav-link {
        width: 100%;
        padding: 15px 30px;
        border-radius: 0;
    }
    .mobile-nav-toggle { 
        display: block; 
        background: none; border: none; font-size: 24px;
        cursor: pointer;
        color: var(--text-dark);
    }
}
