/* Shared site styles. Page-specific layouts live in their own stylesheets. */
:root {
    --navbar-height: 72px;
    --accent: #fa1e4e;
    --page-background: #0e0e0e;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--page-background);
    color: #fff;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

a {
    text-decoration: none;
}

button {
    font: inherit;
}

img {
    max-width: 100%;
}

picture {
    display: block;
}

[id] {
    scroll-margin-top: 20px;
}

:focus-visible {
    outline: 2px solid #ffa923;
    outline-offset: 5px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: fixed;
    top: 8px;
    left: 8px;
    z-index: 1100;
    padding: 10px 16px;
    background: #fff;
    color: #111;
    transform: translateY(-150%);
}

.skip-link:focus {
    transform: translateY(0);
}

/* Normal page flow lets the navbar scroll away;
dropdowns stay anchored to it. */
.navbar {
    position: relative;
    min-height: 72px;
    padding: 20px 40px;
    z-index: 1000;
    background: rgba(14, 14, 14, 0.95);
    backdrop-filter: blur(6px);
    line-height: 1.2;
}

.navdiv {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo a {
    color: var(--accent);
    font-size: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.navbar ul {
    display: flex;
    align-items: center;
    gap: 24px;
    list-style: none;
}

.navbar li a {
    display: inline-block;
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.navbar a:hover {
    color: #ffa923;
}

.navbar a[aria-current="page"] {
    text-decoration: underline;
    text-underline-offset: 6px;
}

.hamburger {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 8px;
    border: 1px solid #333;
    border-radius: 8px;
    background: #191919;
    color: #fff;
    cursor: pointer;
}

.hamburger:hover {
    background: #242424;
    border-color: #666;
}

.hamburger span {
    width: 25px;
    height: 3px;
    border-radius: 2px;
    background: currentColor;
    transition: transform 0.3s, opacity 0.3s;
}

.hamburger[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.hamburger[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.btn {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 600;
    transition: background 0.3s, color 0.3s, transform 0.2s;
}

.btn:hover {
    background: #fff;
    color: #0e0e0e;
}

.btn.secondary {
    background: transparent;
    border: 2px solid var(--accent);
}

.btn.secondary:hover {
    background: var(--accent);
    color: #fff;
}

.highlight {
    color: var(--accent);
}

.footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    padding: 20px 50px;
    background: #0e0e0e;
    border-top: 1px solid #222;
    line-height: normal;
}

.footer .copyright {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer .copyright img {
    display: block;
    width: 30px;
    height: auto;
}

.footer p {
    font-size: 0.9rem;
    color: #ccc;
}

.footer ul {
    display: flex;
    gap: 20px;
    list-style: none;
}

.footer a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    color: #fff;
    transition: color 0.3s, background 0.3s;
}

.social-link svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.footer a:hover {
    color: var(--accent);
}

@media (max-width: 768px) {
    /* The expanded fallback menu remains usable if JavaScript is unavailable. */
    .navbar {
        padding: 14px 20px;
        backdrop-filter: none;
    }

    .navdiv {
        min-height: 44px;
        flex-wrap: wrap;
        gap: 12px;
    }

    .logo {
        max-width: calc(100% - 56px);
    }

    .logo a {
        font-size: clamp(1rem, 5.5vw, 1.5rem);
    }

    .navbar ul {
        flex-basis: 100%;
        flex-direction: column;
        gap: 0;
    }

    .navbar li {
        width: 100%;
    }

    .navbar li a {
        padding: 16px 20px;
        width: 100%;
        text-align: center;
    }

    .nav-ready .hamburger {
        display: flex;
        position: fixed;
        top: 14px;
        right: 20px;
        z-index: 1100;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
    }

    .nav-ready #nav-links {
        display: none;
        position: fixed;
        top: calc(var(--navbar-height) + 8px);
        right: 20px;
        width: min(280px, calc(100vw - 32px));
        max-height: calc(100vh - var(--navbar-height) - 24px);
        max-height: calc(100dvh - var(--navbar-height) - 24px);
        overflow-y: auto;
        background: rgba(14, 14, 14, 0.98);
        border: 1px solid #333;
        border-radius: 10px;
        padding: 6px;
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
        align-items: stretch;
    }

    .nav-ready #nav-links.active {
        display: flex;
    }

    .nav-ready #nav-links a {
        min-height: 44px;
        padding: 12px 16px;
        font-size: 16px;
        text-align: left;
        border-radius: 6px;
    }

    .nav-ready #nav-links a:hover {
        background: #242424;
    }

    .footer {
        flex-direction: column;
        justify-content: center;
        gap: 18px;
        padding: 28px 20px calc(28px + env(safe-area-inset-bottom, 0px));
        text-align: center;
        background: #111;
        border-color: #2a2a2a;
    }

    .footer .copyright {
        justify-content: center;
        gap: 10px;
    }

    .footer .copyright img {
        width: 28px;
    }

    .footer p {
        font-size: 0.875rem;
        line-height: 1.5;
    }

    .footer ul {
        justify-content: center;
        gap: 12px;
    }

    .footer a {
        width: 44px;
        height: 44px;
        border: 1px solid #333;
        border-radius: 12px;
        background: #1b1b1b;
        color: #eee;
    }

    .social-link svg {
        width: 21px;
        height: 21px;
    }

    .footer a:hover {
        background: #242424;
        border-color: var(--accent);
        color: var(--accent);
    }

}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }

}
