/*
 * Shared header navigation: the hamburger button and the slide-over mobile menu.
 *
 * Every page linked to this file once carried its own copy of these rules
 * inline. They are the UNCONDITIONAL base rules and they must stay both
 * unconditional and here.
 *
 * Each page keeps its OWN breakpoint for revealing the button, because the
 * families genuinely differ - 768px for most pages, 1024px for excel-sms and
 * excel-stripe, whose nav is wider:
 *
 *     @media (max-width: 768px) {
 *         .nav-links      { display: none; }
 *         .mobile-menu-btn { display: flex; }
 *         .header-cta     { display: none; }
 *     }
 *
 * This file is linked from <head> BEFORE each page's inline <style>, so that
 * media query always wins on width no matter where it sits inside the page.
 * Re-declaring `.mobile-menu-btn { display: none }` inline would place an
 * unconditional rule after the media query - same specificity, later in source,
 * so it wins at every width and the hamburger disappears on phones, leaving the
 * header with no navigation at all. That was a real bug on 11 pages; splitting
 * the base rules out here is what makes it structurally impossible. deploy.sh
 * fails the deploy if an inline copy ever comes back.
 *
 * Colours and radii come from each page's own :root custom properties.
 */

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 8px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--surface);
    z-index: 999;
    padding: 80px 24px 24px;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
}

.mobile-menu.active {
    display: flex;
}

.mobile-menu a {
    display: block;
    padding: 16px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: background 0.2s;
}

.mobile-menu a:hover {
    background: var(--background);
}

.mobile-menu .btn {
    margin-top: 16px;
    text-align: center;
}
