/* Global Styles & Desktop First */
:root {
    --primary-color: #0A2463;
    --secondary-color: #FFD700;
    --text-color: #ffffff;
    --button-hover-bg: #e6c200;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    color: #333;
    line-height: 1.6;
    padding-top: 80px; /* Default desktop header height */
}

.site-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background-color: var(--primary-color);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column; /* Default to column, overridden for desktop top bar */
    min-height: 80px;
}

.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    min-height: 80px;
}

.logo {
    font-size: 28px;
    font-weight: bold;
    color: var(--secondary-color);
    text-decoration: none;
    display: block; /* Ensure visibility */
    padding: 0;
    order: 1; /* Desktop: Logo first */
    white-space: nowrap;
}

.main-nav {
    display: flex; /* Desktop: visible */
    flex-direction: row; /* Desktop: horizontal */
    flex: 1;
    justify-content: center;
    align-items: center;
    padding: 0 20px;
}

.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 15px;
}

.main-nav li a {
    color: var(--text-color);
    text-decoration: none;
    padding: 10px 15px;
    display: block;
    white-space: nowrap;
    transition: color 0.3s ease, background-color 0.3s ease;
}

.main-nav li a:hover, .main-nav li a.active {
    color: var(--secondary-color);
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.desktop-nav-buttons {
    display: flex; /* Desktop: visible */
    gap: 10px;
    order: 3; /* Desktop: buttons last */
}

/* Buttons Base Style */
.btn {
    display: inline-block;
    padding: 10px 18px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    white-space: nowrap;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    box-shadow: 0 4px 10px rgba(255, 215, 0, 0.4);
}

.btn-primary:hover {
    background-color: var(--button-hover-bg);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 215, 0, 0.6);
}

.btn-secondary {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.btn-secondary:hover {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 215, 0, 0.6);
}

.btn-tertiary {
    background-color: #3f51b5; /* Example third color */
    color: var(--text-color);
    box-shadow: 0 4px 10px rgba(63, 81, 181, 0.4);
}

.btn-tertiary:hover {
    background-color: #303f9f;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(63, 81, 181, 0.6);
}

.hamburger-menu, .mobile-buttons-area, .mobile-menu-overlay {
    display: none; /* Hidden on desktop */
}

/* Footer Styles */
.site-footer {
    background-color: var(--primary-color);
    color: var(--text-color);
    padding: 40px 20px;
    font-size: 14px;
}

.footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto 30px auto;
    gap: 30px;
}

.footer-column {
    flex: 1;
    min-width: 200px;
}

.footer-column h3 {
    color: var(--secondary-color);
    font-size: 18px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--secondary-color);
    padding-bottom: 10px;
}

.footer-column p {
    margin: 0;
    color: #ccc;
}

.footer-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-nav li {
    margin-bottom: 10px;
}

.footer-nav a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #aaa;
}

/* Mobile Styles */
@media (max-width: 768px) {
    body {
        padding-top: calc(60px + 60px); /* Mobile header-top + mobile-buttons-area height */
    }

    body.no-scroll {
        overflow: hidden;
    }

    .site-header {
        flex-direction: column;
        min-height: auto;
    }

    .header-top {
        padding: 10px 15px;
        min-height: 60px;
        justify-content: space-between;
    }

    .logo {
        font-size: 24px;
        flex: 1;
        text-align: center;
        order: 2;
        margin-left: -40px; /* Offset for hamburger button */
        display: block; /* Ensure visibility */
    }

    .hamburger-menu {
        display: flex; /* Visible on mobile */
        order: 1;
        z-index: 1001;
        position: relative;
        background: none;
        border: none;
        cursor: pointer;
        flex-direction: column;
        justify-content: space-around;
        width: 30px;
        height: 25px;
        padding: 0;
    }

    .hamburger-menu .bar {
        width: 100%;
        height: 3px;
        background-color: var(--secondary-color);
        transition: all 0.3s ease;
    }

    .hamburger-menu.active .bar:nth-child(1) { transform: translateY(11px) rotate(45deg); }
    .hamburger-menu.active .bar:nth-child(2) { opacity: 0; }
    .hamburger-menu.active .bar:nth-child(3) { transform: translateY(-11px) rotate(-45deg); }

    .desktop-nav-buttons {
        display: none; /* Hidden on mobile */
    }

    .mobile-buttons-area {
        display: flex; /* Visible on mobile */
        justify-content: center;
        align-items: center;
        gap: 10px;
        padding: 10px 15px;
        background-color: var(--primary-color);
        width: 100%;
        box-sizing: border-box;
        min-height: 60px;
        position: relative;
        z-index: 999; /* Below hamburger, above main content */
        box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    }

    .main-nav {
        display: none; /* Hidden by default on mobile */
        flex-direction: column;
        position: fixed;
        top: 0; /* Will be adjusted by JS to be below header/buttons */
        left: 0;
        width: 80%;
        max-width: 300px; /* Limit menu width */
        height: 100vh;
        background-color: var(--primary-color);
        transform: translateX(-100%); /* Off-screen */
        transition: transform 0.3s ease;
        z-index: 1001; /* Above overlay and buttons */
        overflow-y: auto;
        padding-top: calc(60px + 60px); /* Space for header-top and mobile-buttons-area */
        box-shadow: 2px 0 5px rgba(0,0,0,0.2);
    }

    .main-nav.active {
        display: flex; /* Show menu */
        transform: translateX(0); /* On-screen */
    }

    .main-nav ul {
        flex-direction: column;
        width: 100%;
    }

    .main-nav li {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .main-nav li:last-child {
        border-bottom: none;
    }

    .main-nav li a {
        padding: 15px 20px;
        font-size: 18px;
        text-align: left;
        color: var(--text-color);
    }

    .mobile-menu-overlay {
        display: none; /* Hidden by default */
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0,0,0,0.5);
        z-index: 998; /* Below menu, above content */
        transition: opacity 0.3s ease;
        opacity: 0;
    }

    .mobile-menu-overlay.active {
        display: block;
        opacity: 1;
    }

    .footer-container {
        flex-direction: column;
        gap: 20px;
    }

    .footer-column {
        min-width: unset;
    }

    .footer-column h3 {
        text-align: center;
    }

    .footer-nav ul {
        text-align: center;
    }
}
