/* Common Styles for all pages */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
}

:root {
    --wine-dark: #722F37;
    --wine-light: #8B4552;
    --gold: #D4AF37;
    --cream: #FFF8E7;
    --dark: #2C1810;
}

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    background: linear-gradient(135deg, var(--cream) 0%, #F5E6D3 100%);
    color: var(--dark);
    line-height: 1.6;
    padding-top: 60px;
}

/* Navigation Menu Styles */
.nav-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--wine-dark);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
    width: 100%;
    max-width: 100%;
}

.nav-brand {
    color: var(--gold);
    font-size: 1.3rem;
    font-weight: bold;
    display: none;
}

.burger-menu {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.burger-menu span {
    width: 25px;
    height: 3px;
    background: var(--cream);
    margin: 3px 0;
    transition: all 0.3s ease;
    border-radius: 3px;
}

.burger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.burger-menu.active span:nth-child(2) {
    opacity: 0;
}

.burger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.nav-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    width: 100%;
}

.nav-links li {
    margin: 0;
}

.nav-links li a {
    color: var(--cream);
    text-decoration: none;
    font-size: 1.1rem;
    display: block;
    padding: 1.2rem 1.5rem;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
}

.nav-links li a:hover {
    color: var(--gold);
    border-bottom-color: var(--gold);
}

.nav-links li a.active {
    color: var(--gold);
    border-bottom-color: var(--gold);
}

/* Special styling for Quiz menu item - Eye-catching! */
.nav-links li a[href="quiz.html"] {
    background: linear-gradient(135deg, #00D4FF 0%, #0080FF 100%);
    color: white !important;
    font-weight: bold;
    border-radius: 8px;
    padding: 0.8rem 1.5rem;
    border-bottom: none !important;
    position: relative;
    overflow: hidden;
    animation: pulse 2s ease-in-out infinite;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.5);
}

.nav-links li a[href="quiz.html"]::before {
    content: "🎯 ";
    font-size: 1.2rem;
}

.nav-links li a[href="quiz.html"]::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shine 3s ease-in-out infinite;
}

.nav-links li a[href="quiz.html"]:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 212, 255, 0.8);
    background: linear-gradient(135deg, #0080FF 0%, #00D4FF 100%);
}

.nav-links li a[href="quiz.html"].active {
    background: linear-gradient(135deg, #0080FF 0%, #00D4FF 100%);
    color: white !important;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes shine {
    0% {
        left: -100%;
    }
    50%, 100% {
        left: 100%;
    }
}

/* Page Header */
.page-header {
    background: linear-gradient(135deg, var(--wine-dark) 0%, var(--dark) 100%);
    color: var(--cream);
    text-align: center;
    padding: 8rem 2rem 4rem;
    margin-bottom: 3rem;
    width: 100%;
    max-width: 100%;
}

.page-header h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--cream);
    margin-bottom: 1rem;
}

.page-header h1 span {
    color: var(--gold);
}

.page-header p {
    font-size: 1.2rem;
    color: var(--gold);
}

/* Footer */
footer {
    background: var(--dark);
    color: var(--cream);
    text-align: center;
    padding: 3rem 2rem;
    margin-top: 5rem;
}

footer p {
    margin-bottom: 0.5rem;
}

footer a {
    color: var(--gold);
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Responsive menu for mobile */
@media (max-width: 768px) {
    .nav-brand {
        display: block;
    }

    .burger-menu {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--wine-dark);
        flex-direction: column;
        gap: 0;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    }

    .nav-links.active {
        max-height: 400px;
    }

    .nav-links li {
        width: 100%;
        border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    }

    .nav-links li a {
        padding: 1rem 2rem;
        font-size: 1rem;
        border-bottom: none;
    }

    /* Keep Quiz menu item flashy on mobile */
    .nav-links li a[href="quiz.html"] {
        margin: 0.5rem 1rem;
        padding: 1rem 2rem;
        border-radius: 8px;
        animation: pulse 2s ease-in-out infinite;
    }

    body {
        padding-top: 60px;
    }

    .page-header {
        padding: 6rem 1rem 3rem;
    }
}
