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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f4f4f4;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* Site Header */
.site-header {
    background-color: #1A202C; /* Primary dark color */
    color: #fff;
    padding: 1rem 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Georgia', serif; /* A more classic, strong font for brand */
    font-size: 2.2rem;
    font-weight: bold;
    color: #FFD700; /* Secondary gold color */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    transition: color 0.3s ease;
}

.logo:hover {
    color: #fff;
}

.header-right-group {
    display: flex; /* Nav and actions side-by-side */
    align-items: center;
    gap: 1.5rem; /* Gap between nav and actions */
}

.main-nav ul {
    display: flex;
    gap: 1.5rem;
}

.main-nav a {
    color: #fff;
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.3s ease;
}

.main-nav a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background-color: #FFD700;
    transition: width 0.3s ease;
}

.main-nav a:hover {
    color: #FFD700;
}

.main-nav a:hover::after,
.main-nav a.active::after { /* Active state for current page */
    width: 100%;
}

.hamburger-menu {
    display: none; /* Hidden by default on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    position: relative;
    z-index: 1001;
}

.hamburger-menu span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #FFD700;
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

.hamburger-menu span:last-child {
    margin-bottom: 0;
}

/* Header Actions (Buttons) */
.header-actions {
    display: flex; /* Arrange buttons side-by-side */
    gap: 1rem;
    align-items: center;
}

.header-actions .btn {
    display: inline-block;
    padding: 0.6rem 1.2rem;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    transition: all 0.3s ease;
    white-space: nowrap; /* Prevent buttons from wrapping text */
}

.header-actions .btn-register {
    background-color: #FFD700; /* Gold */
    color: #1A202C; /* Dark text */
    border: 2px solid #FFD700;
}

.header-actions .btn-register:hover {
    background-color: #e0b000; /* Darker gold */
    color: #1A202C;
}

.header-actions .btn-login {
    background-color: transparent;
    color: #FFD700; /* Gold text */
    border: 2px solid #FFD700;
}

.header-actions .btn-login:hover {
    background-color: #FFD700;
    color: #1A202C;
}

/* Site Footer */
.site-footer {
    background-color: #1A202C; /* Primary dark color */
    color: #ddd;
    padding: 3rem 0;
    margin-top: 3rem;
    font-size: 0.9rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-column h3 {
    color: #FFD700;
    font-size: 1.2rem;
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 2px;
    background-color: #FFD700;
}

.footer-column p {
    margin-bottom: 0.8rem;
}

.footer-nav ul {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.footer-nav a {
    color: #ddd;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: #FFD700;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive Styles */
@media (max-width: 768px) {
    .header-container {
        padding: 0 1rem;
        display: grid;
        grid-template-columns: 1fr 1fr 1fr; /* Three equal columns */
        grid-template-areas:
            "hamburger logo right-placeholder"
            "actions actions actions"; /* Buttons span all three columns */
        gap: 0.5rem;
        align-items: center;
    }

    .hamburger-menu {
        display: block; /* Show hamburger on mobile */
        grid-area: hamburger;
        justify-self: start;
    }

    .logo {
        grid-area: logo;
        justify-self: center;
        font-size: 1.8rem; /* Adjust logo size for mobile */
    }

    .header-right-group {
        display: contents; /* Makes children direct grid items */
    }

    .main-nav {
        display: none; /* Hide by default on mobile */
        flex-direction: column;
        position: absolute;
        top: 100%; /* Position below header */
        left: 0;
        width: 100%;
        background-color: #1A202C;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
        padding: 1rem 0;
        max-height: 0; /* For smooth transition */
        overflow: hidden;
        transition: max-height 0.5s ease-out;
        z-index: 999; /* Ensure it's below hamburger but above other content */
    }

    .main-nav.open {
        display: flex; /* Show when open */
        max-height: 500px; /* Adjust as needed */
    }

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

    .main-nav li {
        width: 100%;
        text-align: center;
        padding: 0.5rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

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

    .main-nav a {
        display: block;
        padding: 1rem;
        font-size: 1.1rem;
    }

    .header-actions {
        grid-area: actions;
        justify-content: center; /* Center buttons within their full-width container */
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        /* Keep display: flex and gap for buttons inside */
    }

    /* Hamburger menu animation */
    .hamburger-menu.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

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

    .hamburger-menu.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-column h3::after {
        left: 50%;
        transform: translateX(-50%);
    }
}