body {
    background-color: #121212;
    color: #e0e0e0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0 20px 40px 20px;
    line-height: 1.6;
}

header.header {
    background-color: #1f1f1f;
    padding: 10px 0 0 0;
    margin-bottom: 30px;
    border-bottom: 1px solid #333;
    position: sticky;
    top: 0;
    z-index: 1000;
}

header.header h1 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    text-align: center;
}

nav ul {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 10px 10px;
    margin: 0;
    flex-wrap: wrap;
    background-color: #1f1f1f;
    border-bottom: 1px solid #333;
}

nav ul li {
    margin: 0 8px;
}

nav ul li a {
    color: #ffa500;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    padding: 6px 10px;
    border-radius: 4px;
    transition: background-color 0.3s ease, color 0.3s ease;
    display: inline-block;
}

nav ul li a:hover,
nav ul li a:focus {
    background-color: #ffa500;
    color: #121212;
}

nav ul li a.active {
    background-color: #ffb347;
    color: #121212;
}

@media (max-width: 600px) {
    nav ul {
        flex-direction: column;
        align-items: center;
        padding: 10px 0;
    }
    nav ul li {
        margin: 6px 0;
    }
}

main section {
    max-width: 900px;
    margin: 0 auto 40px auto;
}

h2 {
    font-size: 22px;
    margin-bottom: 15px;
    border-bottom: 2px solid #ffa500;
    padding-bottom: 5px;
}

h3 {
    font-size: 18px;
    margin-top: 25px;
    margin-bottom: 10px;
}

ul {
    padding-left: 20px;
}

p {
    max-width: 900px;
    margin: 0 auto 15px auto;
}

/* Citations styling */
#citations {
    max-width: 900px;
    margin: 0 auto 40px auto;
    padding-top: 20px;
    border-top: 2px solid #ffa500;
    color: #ccc;
}

#citations h2 {
    color: #ffa500;
    margin-bottom: 15px;
}

#citations a {
    color: #66aaff;
    text-decoration: none;
}

#citations a:hover,
#citations a:focus {
    text-decoration: underline;
}

/* Superscript styling */
sup {
    font-size: 0.7em;
    vertical-align: super;
}

sup a {
    color: #66aaff;
    text-decoration: none;
}

sup a:hover,
sup a:focus {
    text-decoration: underline;
}

footer {
    text-align: center;
    color: #888;
    margin-top: 50px;
    padding: 15px 0;
    border-top: 1px solid #333;
    font-size: 14px;
}

/* Hamburger button styling - move to right */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: #ffa500;
    font-size: 2em;
    padding: 0 12px;
    cursor: pointer;
    position: absolute;
    right: 10px; /* moved from left to right */
    top: 1px;
    z-index: 1100;
}

/* Collapsible nav for mobile */
@media (max-width: 700px) {
    nav {
        position: relative;
    }
    .nav-toggle {
        display: block;
    }
    nav ul {
        flex-direction: column;
        align-items: flex-start;
        position: absolute;
        top: 48px;
        right: 0; /* keep right aligned */
        width: 100vw;
        background: #1f1f1f;
        border-bottom: 1px solid #333;
        z-index: 1001;
        display: none; /* hidden by default on mobile */
    }
    nav ul.open {
        display: flex;
    }
    nav ul li {
        margin: 12px 20px;
    }
}

