/* =============================================
   AMAC Navigation Prototype - Option A
   Revenue-Balanced Navigation

   Enhanced with Tailwind CSS Design System Patterns
   - Spacing scale (4px base unit)
   - Extended color palette with shades
   - Typography scale
   - Shadow system
   - Border radius tokens
   - Ring utilities for focus states
   ============================================= */

/* -----------------------------------------
   1. DESIGN TOKENS (Tailwind-Inspired)
   ----------------------------------------- */
:root {
    /* ========== SPACING SCALE (4px base) ========== */
    --space-px: 1px;
    --space-0: 0;
    --space-0-5: 0.125rem;  /* 2px */
    --space-1: 0.25rem;     /* 4px */
    --space-1-5: 0.375rem;  /* 6px */
    --space-2: 0.5rem;      /* 8px */
    --space-2-5: 0.625rem;  /* 10px */
    --space-3: 0.75rem;     /* 12px */
    --space-3-5: 0.875rem;  /* 14px */
    --space-4: 1rem;        /* 16px */
    --space-5: 1.25rem;     /* 20px */
    --space-6: 1.5rem;      /* 24px */
    --space-7: 1.75rem;     /* 28px */
    --space-8: 2rem;        /* 32px */
    --space-9: 2.25rem;     /* 36px */
    --space-10: 2.5rem;     /* 40px */
    --space-11: 2.75rem;    /* 44px */
    --space-12: 3rem;       /* 48px */
    --space-14: 3.5rem;     /* 56px */
    --space-16: 4rem;       /* 64px */
    --space-20: 5rem;       /* 80px */
    --space-24: 6rem;       /* 96px */
    --space-28: 7rem;       /* 112px */
    --space-32: 8rem;       /* 128px */

    /* ========== TYPOGRAPHY SCALE (AMAC Brand) ========== */
    /*
     * Brand Typography:
     * - Primary Serif: Merriweather (headlines, titles, quotes)
     * - Secondary Sans: Open Sans (body, UI, navigation)
     * - Body: 18px, Headings: 48/36/28px, Callouts: 20px
     * - Nav items: 16px minimum
     */

    /* Font Families (per amac_brand.txt) */
    --font-serif: "Merriweather", Georgia, serif;
    --font-sans: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI",
        Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

    /* Font Sizes (AMAC Brand Scale) */
    --text-xs: 0.75rem;     /* 12px - fine print */
    --text-sm: 0.875rem;    /* 14px - small text, labels */
    --text-base: 1rem;      /* 16px - nav items minimum */
    --text-lg: 1.125rem;    /* 18px - body text (brand standard) */
    --text-xl: 1.25rem;     /* 20px - callouts, stressed text */
    --text-2xl: 1.5rem;     /* 24px - small headings */
    --text-3xl: 1.75rem;    /* 28px - H3 subsection */
    --text-4xl: 2.25rem;    /* 36px - H2 section */
    --text-5xl: 3rem;       /* 48px - H1 hero */
    --text-6xl: 3.75rem;    /* 60px - display */

    /* Line Heights (optimized for 50+ readability) */
    --leading-none: 1;
    --leading-tight: 1.2;      /* headings */
    --leading-snug: 1.375;
    --leading-normal: 1.5;     /* body text minimum */
    --leading-relaxed: 1.625;  /* body text preferred for seniors */
    --leading-loose: 2;

    /* Font Weights (AMAC Brand: 400/600/700) */
    --font-normal: 400;     /* regular body text */
    --font-medium: 500;     /* headings (brand spec) */
    --font-semibold: 600;   /* semi-bold for emphasis */
    --font-bold: 700;       /* bold for CTAs, strong emphasis */

    /* Letter Spacing (improved for uppercase readability) */
    --tracking-tight: -0.025em;
    --tracking-normal: 0;
    --tracking-wide: 0.05em;    /* uppercase text standard */
    --tracking-wider: 0.075em;  /* small uppercase labels */
    --tracking-widest: 0.1em;   /* extra-small uppercase */

    /* ========== COLOR PALETTE ========== */
    /* Base Colors (from amac-us-css.txt) */
    --color-text: #333333;
    --color-bg: #ffffff;
    --color-link: #cc3366;
    --color-link-hover: #333366;

    /* Liberty Blue Scale */
    --blue-50: #e6eef8;
    --blue-100: #c0d4ed;
    --blue-200: #96b8e1;
    --blue-300: #6c9cd5;
    --blue-400: #4d86cc;
    --blue-500: #2e71c3;
    --blue-600: #2969bd;
    --blue-700: #235eb5;
    --blue-800: #1d54ae;
    --blue-900: #002868;  /* Liberty Blue - Primary */
    --blue-950: #001a44;

    /* Patriot Red Scale */
    --red-50: #fce8ec;
    --red-100: #f8c5cf;
    --red-200: #f39eaf;
    --red-300: #ee778f;
    --red-400: #ea5a77;
    --red-500: #e63d5f;
    --red-600: #d83757;
    --red-700: #c62f4d;
    --red-800: #b42743;
    --red-900: #e21d37;  /* AMAC Logo Red - Primary */
    --red-950: #8a0622;

    /* Constitution Gold Scale */
    --gold-50: #faf6f1;
    --gold-100: #f2e9dc;
    --gold-200: #e9d9c5;
    --gold-300: #dfc9ae;
    --gold-400: #d8bd9d;
    --gold-500: #C49A6C;  /* Constitution Gold - Primary */
    --gold-600: #b88c5e;
    --gold-700: #a87b4d;
    --gold-800: #986b3d;
    --gold-900: #7a522a;

    /* Slate Scale (Neutrals) */
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-800: #1e293b;
    --slate-900: #0f172a;

    /* Gray Scale */
    --gray-50: #fafafa;
    --gray-100: #f5f5f5;
    --gray-200: #e5e5e5;
    --gray-300: #d4d4d4;
    --gray-400: #a3a3a3;
    --gray-500: #737373;
    --gray-600: #525252;
    --gray-700: #404040;
    --gray-800: #262626;
    --gray-900: #171717;

    /* Semantic Colors */
    --color-liberty-blue: var(--blue-900);
    --color-patriot-red: var(--red-900);
    --color-constitution-gold: var(--gold-500);
    --color-slate-blue: #4A6FA5;

    /* UI Colors */
    --color-white: #FFFFFF;
    --color-cream: #F8F7F2;
    --color-charcoal: #333333;

    /* ========== SHADOWS ========== */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    --shadow-inner: inset 0 2px 4px 0 rgb(0 0 0 / 0.05);

    /* ========== BORDER RADIUS ========== */
    --radius-none: 0;
    --radius-sm: 0.125rem;   /* 2px */
    --radius: 0.25rem;       /* 4px */
    --radius-md: 0.375rem;   /* 6px */
    --radius-lg: 0.5rem;     /* 8px */
    --radius-xl: 0.75rem;    /* 12px */
    --radius-2xl: 1rem;      /* 16px */
    --radius-3xl: 1.5rem;    /* 24px */
    --radius-full: 9999px;

    /* ========== TRANSITIONS ========== */
    --duration-75: 75ms;
    --duration-100: 100ms;
    --duration-150: 150ms;
    --duration-200: 200ms;
    --duration-300: 300ms;
    --duration-500: 500ms;
    --duration-700: 700ms;
    --duration-1000: 1000ms;

    --ease-linear: linear;
    --ease-in: cubic-bezier(0.4, 0, 1, 1);
    --ease-out: cubic-bezier(0, 0, 0.2, 1);
    --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);

    /* ========== RING (Focus) ========== */
    --ring-offset-width: 2px;
    --ring-offset-color: var(--color-white);
    --ring-color: var(--gold-500);
    --ring-width: 3px;

    /* ========== Z-INDEX SCALE ========== */
    --z-0: 0;
    --z-10: 10;
    --z-20: 20;
    --z-30: 30;
    --z-40: 40;
    --z-50: 50;
    --z-auto: auto;

    /* ========== LAYOUT ========== */
    --container-width: 1280px;
    --nav-height-upper: 36px;      /* Compact utility bar */
    --nav-height-main: 80px;       /* Substantial primary nav (enterprise standard) */
    --nav-height-mobile-tab: 64px;
    --nav-padding-desktop: 48px;   /* Generous horizontal padding */

    /* ========== BREAKPOINTS (reference) ========== */
    /* sm: 640px, md: 768px, lg: 1024px, xl: 1280px, 2xl: 1536px */
}

/* -----------------------------------------
   2. RESET & BASE STYLES
   ----------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

body {
    font-family: var(--font-sans);
    font-size: var(--text-lg);  /* 18px - AMAC brand standard for body */
    font-weight: var(--font-normal);
    line-height: var(--leading-relaxed);  /* 1.625 - optimized for 50+ readability */
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-width: 100%;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--duration-150) var(--ease-in-out);
}

a:focus-visible {
    outline: var(--ring-width) solid var(--ring-color);
    outline-offset: var(--ring-offset-width);
    border-radius: var(--radius-sm);
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

button:focus-visible {
    outline: var(--ring-width) solid var(--ring-color);
    outline-offset: var(--ring-offset-width);
    border-radius: var(--radius-sm);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Container */
.container {
    max-width: var(--container-width);
    margin-inline: auto;
    padding-inline: var(--space-5);
    width: 100%;
}

/* -----------------------------------------
   3. SKIP LINK (Accessibility)
   ----------------------------------------- */
.skip-link {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--color-liberty-blue);
    color: var(--color-white);
    padding: var(--space-3) var(--space-6);
    font-weight: var(--font-semibold);
    font-size: var(--text-sm);
    z-index: 9999;
    border-radius: 0 0 var(--radius) var(--radius);
    transition: top var(--duration-200) var(--ease-out);
}

.skip-link:focus {
    top: 0;
}

/* -----------------------------------------
   4. PROMO STRIP (Membership CTA)
   Thin, attention-grabbing, converts visitors
   ----------------------------------------- */
.promo-strip {
    background-color: var(--color-liberty-blue);
    padding: var(--space-2) 0;
    text-align: center;
    position: relative;
    z-index: 1002;
}

.promo-strip .container {
    padding-inline: var(--nav-padding-desktop);
    max-width: 100%;
}

.promo-text {
    color: var(--color-white);
    font-size: 13px;
    font-weight: var(--font-normal);
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    flex-wrap: wrap;
}

.promo-text strong {
    font-weight: var(--font-bold);
    color: var(--gold-300);
}

.promo-cta {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    color: var(--color-white);
    font-weight: var(--font-semibold);
    background-color: var(--color-patriot-red);
    padding: var(--space-1) var(--space-3);
    border-radius: var(--radius-sm);
    margin-left: var(--space-2);
    transition: all var(--duration-150) var(--ease-in-out);
}

.promo-cta:hover {
    background-color: var(--red-700);
    transform: translateX(2px);
}

.promo-arrow {
    width: 14px;
    height: 14px;
    fill: currentColor;
    transition: transform var(--duration-150) var(--ease-in-out);
}

.promo-cta:hover .promo-arrow {
    transform: translateX(2px);
}

/* -----------------------------------------
   5. UPPER UTILITY NAV (Enterprise Dark Bar)
   Professional, compact, clearly secondary
   ----------------------------------------- */
.upper-nav {
    background-color: #1a1a1a;  /* Near-black for authority */
    height: var(--nav-height-upper);
    position: relative;
    z-index: 1001;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.upper-nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding-inline: var(--nav-padding-desktop);
    max-width: 100%;
}

.upper-nav-group {
    display: flex;
    align-items: center;
    gap: var(--space-6);
}

.upper-nav a,
.upper-nav button {
    color: rgba(255,255,255,0.85);
    font-size: 13px;               /* Smaller, clearly utility */
    font-weight: var(--font-medium);
    letter-spacing: 0.3px;
    display: inline-flex;
    align-items: center;
    gap: var(--space-1-5);
    padding: var(--space-1) 0;
    border-radius: 0;
    transition: color var(--duration-150) var(--ease-in-out);
}

.upper-nav a:hover,
.upper-nav button:hover {
    color: var(--color-white);
}

/* Separator between utility items */
/* Utility bar label and separator */
.utility-label {
    color: rgba(255,255,255,0.75);  /* Improved contrast (#2) */
    font-size: 13px;
    font-weight: var(--font-medium);
    letter-spacing: 0.3px;
    margin-right: var(--space-2);
}

.utility-separator {
    color: rgba(255,255,255,0.2);  /* Lighter separators (#6) */
    margin: 0 var(--space-2);
}

/* Visual divider between left and right groups (#3) */
.upper-nav-left {
    gap: var(--space-1);
    padding-right: var(--space-6);
    border-right: 1px solid rgba(255,255,255,0.15);
    margin-right: var(--space-2);
}

/* External link with persistent icon (#1) */
.external-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.external-link::after {
    content: '';
    display: inline-block;
    width: 10px;
    height: 10px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M14 3h7v7h-2V6.41L8.41 17 7 15.59 17.59 5H14V3zM5 5h7V3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7H5V5z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0.4;
    transition: opacity var(--duration-150) var(--ease-in-out);
}

.external-link:hover::after {
    opacity: 1;
}

.icon-external {
    width: 14px;
    height: 14px;
    fill: currentColor;
    opacity: 0.7;
}

.icon-search {
    width: 18px;
    height: 18px;
    fill: currentColor;
    opacity: 1;
}

.search-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1-5);
}

.search-text {
    display: none;  /* Icon only in utility bar for cleaner look */
}

.login-link {
    opacity: 0.9;
}

/* Join AMAC Button (Primary CTA - enhanced prominence #4) */
.btn-join {
    background-color: var(--color-patriot-red);
    color: var(--color-white) !important;
    padding: var(--space-2) var(--space-5) !important;  /* Slightly larger */
    border-radius: var(--radius);
    font-weight: var(--font-bold);
    text-transform: uppercase;
    font-size: var(--text-xs);
    letter-spacing: var(--tracking-wide);
    transition: all var(--duration-150) var(--ease-in-out);
    box-shadow: 0 0 0 1px rgba(255,255,255,0.2), var(--shadow-sm);  /* Subtle border glow */
}

.btn-join:hover {
    background-color: var(--red-950);
    transform: translateY(-1px);
    box-shadow: 0 0 12px rgba(226, 29, 55, 0.4), var(--shadow-md);  /* Red glow on hover */
    color: var(--color-white) !important;
}

/* -----------------------------------------
   5. MAIN HEADER NAV (Enterprise Primary Nav)
   Substantial, authoritative, professional
   ----------------------------------------- */
.main-header {
    background-color: var(--color-white);
    height: var(--nav-height-main);
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);  /* Subtle, professional shadow */
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--gray-200);
}

.main-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding-inline: var(--nav-padding-desktop);
    max-width: none;  /* Full width with padding */
}

/* Logo - Commands attention */
.brand-logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: opacity var(--duration-150) var(--ease-in-out);
}

.brand-logo:hover {
    opacity: 0.85;
}

.brand-logo-img {
    width: 130px;   /* Larger for authority */
    height: auto;
}

/* Navigation List */
.nav-list {
    display: flex;
    align-items: center;
    gap: var(--space-1);  /* Tighter, controlled spacing */
    height: 100%;
}

.nav-item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

/* Nav Links - Authority Typography */
.nav-link {
    font-size: 15px;               /* Professional size */
    font-weight: var(--font-medium);  /* 500 - not light, not heavy */
    letter-spacing: 0.3px;
    color: #1a1a1a;                /* Near-black for authority */
    padding: var(--space-2) var(--space-4);
    height: 100%;
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    border-bottom: 3px solid transparent;
    transition: color var(--duration-200) var(--ease-in-out),
                border-color var(--duration-200) var(--ease-in-out);
    min-height: var(--space-11);
}

.nav-link:hover,
.nav-link:focus {
    color: var(--color-liberty-blue);
}

/* Active/expanded state - subtle underline */
.nav-link[aria-expanded="true"],
.nav-link.active {
    color: var(--color-liberty-blue);
    border-bottom-color: var(--color-liberty-blue);
}

.chevron {
    width: 16px;
    height: 16px;
    fill: currentColor;
    opacity: 0.5;   /* Subtle, not prominent */
    transition: transform var(--duration-200) var(--ease-out),
                opacity var(--duration-200) var(--ease-out);
}

.nav-link:hover .chevron {
    opacity: 0.7;
}

/* Rotate chevron when dropdown is expanded */
.nav-link[aria-expanded="true"] .chevron {
    transform: rotate(180deg);
    opacity: 0.7;
}

/* Visual affordance that nav items with dropdowns are clickable */
.nav-link[aria-haspopup="true"] {
    cursor: pointer;
}

/* -----------------------------------------
   6. DROPDOWN MENUS (Professional Enterprise Style)
   Clean, crisp, organized
   ----------------------------------------- */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--color-white);
    min-width: 220px;
    border: 1px solid #e5e5e5;
    border-top: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);  /* Professional shadow */
    border-radius: 0 0 var(--radius) var(--radius);
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity var(--duration-150) var(--ease-out),
                transform var(--duration-150) var(--ease-out),
                visibility var(--duration-150) var(--ease-out);
    pointer-events: none;
    padding: var(--space-2) 0;
}

/* Align last nav item dropdown to right edge to prevent cutoff */
.nav-item:last-child .dropdown {
    left: auto;
    right: 0;
}

/* Show dropdown via aria-expanded */
.nav-link[aria-expanded="true"] + .dropdown,
.nav-item:focus-within .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown a {
    display: flex;
    align-items: center;
    padding: var(--space-2) var(--space-5);  /* Reduced vertical padding */
    color: var(--color-charcoal);
    font-size: 14px;
    font-weight: var(--font-normal);
    line-height: var(--leading-tight);  /* Tighter line height */
    transition: background-color var(--duration-150) var(--ease-in-out),
                color var(--duration-150) var(--ease-in-out);
}

.dropdown a:hover,
.dropdown a:focus {
    background-color: var(--gray-50);
    color: var(--color-liberty-blue);
}

.dropdown-divider {
    height: 1px;
    background-color: var(--gray-100);
    margin: var(--space-2) var(--space-4);
}

.dropdown-cta {
    color: var(--color-patriot-red) !important;
    font-weight: var(--font-semibold) !important;
}

.dropdown-cta:hover {
    background-color: var(--red-50) !important;
    color: var(--color-patriot-red) !important;
}

/* -----------------------------------------
   7. MOBILE MENU TOGGLE
   ----------------------------------------- */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: var(--space-12);
    height: var(--space-12);
    gap: 5px;
    border-radius: var(--radius-md);
    transition: background-color var(--duration-150) var(--ease-in-out);
}

.mobile-menu-toggle:hover {
    background-color: var(--slate-100);
}

.hamburger-line {
    width: var(--space-6);
    height: 3px;
    background-color: var(--color-liberty-blue);
    border-radius: var(--radius-full);
    transition: all var(--duration-200) var(--ease-out);
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* -----------------------------------------
   8. MOBILE NAVIGATION DRAWER
   ----------------------------------------- */
.mobile-nav-overlay {
    position: fixed;
    inset: 0;
    background-color: rgb(0 0 0 / 0.5);
    backdrop-filter: blur(4px);
    z-index: 1998;
    opacity: 0;
    visibility: hidden;
    transition: all var(--duration-300) var(--ease-out);
}

.mobile-nav-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100vh;
    height: 100dvh;
    background-color: var(--color-white);
    z-index: 1999;
    box-shadow: var(--shadow-2xl);
    transition: right var(--duration-300) var(--ease-out);
    overflow-y: auto;
    overscroll-behavior: contain;
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-4) var(--space-5);
    border-bottom: 1px solid var(--gray-200);
    background-color: var(--color-liberty-blue);
}

.mobile-nav-title {
    font-weight: var(--font-bold);
    font-size: var(--text-lg);
    color: var(--color-white);
}

.mobile-nav-close {
    width: var(--space-11);
    height: var(--space-11);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    border-radius: var(--radius-md);
    transition: background-color var(--duration-150) var(--ease-in-out);
}

.mobile-nav-close:hover {
    background-color: var(--blue-800);
}

.mobile-nav-close svg {
    width: var(--space-6);
    height: var(--space-6);
    fill: currentColor;
}

.mobile-nav-list {
    padding: var(--space-4) 0;
}

.mobile-nav-list a {
    display: flex;
    align-items: center;
    padding: var(--space-4) var(--space-6);
    font-size: var(--text-lg);
    font-weight: var(--font-semibold);
    color: var(--color-liberty-blue);
    border-bottom: 1px solid var(--gray-100);
    min-height: var(--space-14);  /* 56px - generous touch target for seniors */
    transition: all var(--duration-150) var(--ease-in-out);
}

.mobile-nav-list a:hover {
    background-color: var(--slate-50);
    padding-left: var(--space-7);
}

.mobile-nav-divider {
    height: 1px;
    background-color: var(--gray-200);
    margin: var(--space-4) 0;
}

.mobile-join-btn {
    background-color: var(--color-patriot-red) !important;
    color: var(--color-white) !important;
    margin: var(--space-4) var(--space-6);
    border-radius: var(--radius-md);
    text-align: center;
    font-weight: var(--font-bold);
}

/* -----------------------------------------
   9. MOBILE BOTTOM TAB BAR
   ----------------------------------------- */
.mobile-tab-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--nav-height-mobile-tab);
    background-color: var(--color-white);
    box-shadow: 0 -4px 12px rgb(0 0 0 / 0.1);
    z-index: 1000;
    justify-content: space-around;
    align-items: center;
    padding-bottom: env(safe-area-inset-bottom);
    border-top: 1px solid var(--gray-200);
}

.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-1);
    padding: var(--space-2);
    min-width: var(--space-16);
    min-height: var(--space-14);  /* 56px - generous touch target for seniors */
    color: var(--gray-600);       /* improved contrast */
    border-radius: var(--radius-lg);
    transition: all var(--duration-150) var(--ease-in-out);
}

.tab-item:hover,
.tab-item:focus,
.tab-item.active {
    color: var(--color-patriot-red);
    background-color: var(--red-50);
}

.tab-icon {
    width: var(--space-6);
    height: var(--space-6);
    fill: currentColor;
}

.tab-label {
    font-size: var(--text-xs);
    font-weight: var(--font-semibold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
}

/* -----------------------------------------
   10. HERO SECTION
   ----------------------------------------- */
.hero-section {
    position: relative;
    color: var(--color-white);
    min-height: 500px;
    display: flex;
    align-items: center;
}

.hero-background {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgb(0 40 104 / 0.88) 0%, rgb(0 26 77 / 0.78) 100%);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: var(--space-20) var(--space-5);
    width: 100%;
}

.hero-title {
    font-family: var(--font-serif);  /* Merriweather for headlines */
    font-size: var(--text-5xl);      /* 48px - H1 hero per brand */
    font-weight: var(--font-bold);   /* 700 - per brand serif weights */
    line-height: var(--leading-tight);  /* 1.2 for headings */
    margin-bottom: var(--space-4);
    color: var(--color-white);
    letter-spacing: var(--tracking-tight);
}

.hero-subtitle {
    font-size: var(--text-xl);
    max-width: 600px;
    margin-inline: auto;
    margin-bottom: var(--space-8);
    opacity: 0.95;
    line-height: var(--leading-relaxed);
}

.hero-ctas {
    display: flex;
    gap: var(--space-4);
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-4) var(--space-8);
    font-size: var(--text-base);
    font-weight: var(--font-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    border-radius: var(--radius-md);
    transition: all var(--duration-200) var(--ease-out);
    min-height: var(--space-11);
    box-shadow: var(--shadow);
}

.btn-primary {
    background-color: var(--color-patriot-red);
    color: var(--color-white);
}

.btn-primary:hover {
    background-color: var(--red-950);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: transparent;
    color: var(--color-white);
    border: 2px solid var(--color-white);
    box-shadow: none;
}

.btn-secondary:hover {
    background-color: var(--color-white);
    color: var(--color-liberty-blue);
    box-shadow: var(--shadow-lg);
}

/* -----------------------------------------
   11. PROTOTYPE INFO SECTION
   ----------------------------------------- */
.prototype-info {
    padding: var(--space-16) 0;
    background-color: var(--color-white);
}

.info-card {
    background-color: var(--slate-50);
    padding: var(--space-10);
    border-radius: var(--radius-xl);
    border-left: 4px solid var(--color-constitution-gold);
    box-shadow: var(--shadow);
}

.info-card h2 {
    font-family: var(--font-serif);  /* Merriweather for headlines */
    font-size: var(--text-4xl);      /* 36px - H2 section per brand */
    font-weight: var(--font-bold);   /* 700 - per brand */
    line-height: var(--leading-tight);
    color: var(--color-liberty-blue);
    margin-bottom: var(--space-4);
}

.info-card h3 {
    font-family: var(--font-serif);  /* Merriweather for headlines */
    font-size: var(--text-3xl);      /* 28px - H3 subsection per brand */
    font-weight: var(--font-bold);   /* 700 - per brand */
    color: var(--color-liberty-blue);
    margin-top: var(--space-6);
    margin-bottom: var(--space-3);
}

.info-card p {
    margin-bottom: var(--space-4);
    line-height: var(--leading-relaxed);
}

.info-card ul {
    list-style: disc;
    padding-left: var(--space-6);
}

.info-card li {
    margin-bottom: var(--space-2);
    line-height: var(--leading-relaxed);
}

/* -----------------------------------------
   12. SCROLL TEST SECTION
   ----------------------------------------- */
.scroll-test {
    padding: var(--space-16) 0;
    background-color: var(--slate-50);
}

.scroll-test h2 {
    font-family: var(--font-serif);  /* Merriweather for headlines */
    font-size: var(--text-4xl);      /* 36px - H2 section per brand */
    font-weight: var(--font-bold);   /* 700 - per brand */
    line-height: var(--leading-tight);
    color: var(--color-liberty-blue);
    margin-bottom: var(--space-4);
}

.placeholder-content {
    display: grid;
    gap: var(--space-6);
    margin-top: var(--space-8);
}

.placeholder-block {
    height: 200px;
    background: linear-gradient(135deg, var(--gray-200) 0%, var(--gray-300) 100%);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-inner);
}

/* -----------------------------------------
   13. FOOTER - Classic Multi-Column Fat Footer
   ----------------------------------------- */
.site-footer {
    margin-top: var(--space-16);
}

/* Newsletter Section */
.footer-newsletter {
    background: linear-gradient(135deg, var(--color-patriot-red) 0%, var(--red-700) 100%);
    padding: var(--space-10) 0;
}

.footer-newsletter .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-6);
}

.newsletter-content {
    flex: 1;
    min-width: 250px;
}

.newsletter-title {
    color: var(--color-white);
    font-size: var(--text-2xl);
    font-weight: var(--font-bold);
    margin-bottom: var(--space-1);
}

.newsletter-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: var(--text-lg);
}

.newsletter-form {
    flex: 2;
    min-width: 300px;
}

.newsletter-fields {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
}

.newsletter-fields input {
    flex: 1;
    min-width: 150px;
    padding: var(--space-3) var(--space-4);
    font-size: var(--text-base);
    border: 2px solid transparent;
    border-radius: var(--radius);
    background-color: var(--color-white);
    color: var(--color-charcoal);
    transition: border-color var(--duration-150) var(--ease-in-out);
}

.newsletter-fields input:focus {
    outline: none;
    border-color: var(--color-constitution-gold);
}

.newsletter-fields input::placeholder {
    color: var(--gray-500);  /* improved contrast for placeholder text */
}

.btn-subscribe {
    padding: var(--space-3) var(--space-8);
    font-size: var(--text-base);
    font-weight: var(--font-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    color: var(--color-liberty-blue);
    background-color: var(--color-constitution-gold);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all var(--duration-150) var(--ease-in-out);
}

.btn-subscribe:hover {
    background-color: var(--gold-400);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Main Footer */
.footer-main {
    background-color: var(--color-liberty-blue);
    padding: var(--space-16) 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: var(--space-10);
}

.footer-column {
    /* Column base styles */
}

.footer-brand {
    /* Brand column */
}

.footer-logo {
    display: inline-block;
    margin-bottom: var(--space-5);
}

.footer-logo img {
    width: 160px;
    height: auto;
}

.footer-mission {
    color: rgba(255, 255, 255, 0.9);  /* improved contrast for seniors */
    font-size: var(--text-base);       /* larger text for readability */
    line-height: var(--leading-relaxed);
}

.footer-heading {
    color: var(--color-constitution-gold);
    font-size: var(--text-sm);
    font-weight: var(--font-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    margin-bottom: var(--space-4);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: var(--space-2);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.9);  /* improved contrast for seniors */
    font-size: var(--text-base);       /* larger text for readability */
    transition: color var(--duration-150) var(--ease-in-out);
}

.footer-links a:hover {
    color: var(--color-white);
}

/* Social Icons */
.footer-social {
    margin-top: var(--space-6);
}

.footer-social .footer-heading {
    margin-bottom: var(--space-3);
}

.social-icons {
    display: flex;
    gap: var(--space-3);
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: var(--space-11);   /* 44px - WCAG touch target minimum */
    height: var(--space-11);  /* 44px - WCAG touch target minimum */
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-full);
    color: var(--color-white);
    transition: all var(--duration-150) var(--ease-in-out);
}

.social-icons a:hover {
    background-color: var(--color-constitution-gold);
    color: var(--color-liberty-blue);
    transform: translateY(-2px);
}

.social-icons svg {
    width: var(--space-5);
    height: var(--space-5);
}

/* Sub-Footer */
.footer-bottom {
    background-color: var(--blue-950);
    padding: var(--space-5) 0;
}

.footer-bottom-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
}

.copyright {
    color: rgba(255, 255, 255, 0.85);  /* improved contrast */
    font-size: var(--text-sm);
}

.footer-legal {
    display: flex;
    gap: var(--space-6);
}

.footer-legal a {
    color: rgba(255, 255, 255, 0.85);  /* improved contrast */
    font-size: var(--text-sm);
    transition: color var(--duration-150) var(--ease-in-out);
}

.footer-legal a:hover {
    color: var(--color-white);
}

/* -----------------------------------------
   14. RESPONSIVE STYLES
   ----------------------------------------- */

/* Large Desktop (>= 1280px) */
@media (min-width: 1280px) {
    .container {
        padding-inline: var(--space-8);
    }
}

/* Tablet (768px - 1023px) */
@media (max-width: 1023px) {
    .nav-list {
        gap: var(--space-1);
    }

    .nav-link {
        padding-inline: var(--space-3);
        font-size: var(--text-base);
    }

    .brand-logo-img {
        width: 90px;
    }
}

/* Mobile (< 768px) */
@media (max-width: 767px) {
    /* Hide desktop nav */
    .nav-list {
        display: none;
    }

    /* Show mobile toggle */
    .mobile-menu-toggle {
        display: flex;
    }

    /* Show bottom tab bar */
    .mobile-tab-bar {
        display: flex;
    }

    /* Adjust upper nav */
    .upper-nav-left {
        display: none;
    }

    .search-text {
        display: none;
    }

    .upper-nav-group {
        gap: var(--space-3);
    }

    /* Adjust main header */
    .main-header {
        height: var(--space-16);
    }

    .brand-logo-img {
        width: 80px;
    }

    /* Hero adjustments */
    .hero-section {
        min-height: 400px;
    }

    .hero-content {
        padding: var(--space-12) var(--space-5) var(--space-28);
    }

    .hero-title {
        font-size: var(--text-3xl);
    }

    .hero-subtitle {
        font-size: var(--text-lg);
    }

    /* Add padding to main content for bottom tab bar */
    main {
        padding-bottom: calc(var(--nav-height-mobile-tab) + var(--space-5));
    }

    /* Info card */
    .info-card {
        padding: var(--space-6);
    }

    .info-card h2 {
        font-size: var(--text-2xl);
    }

    .prototype-info,
    .scroll-test {
        padding: var(--space-10) 0;
    }

    /* Footer responsive */
    .footer-newsletter .container {
        flex-direction: column;
        text-align: center;
    }

    .newsletter-content {
        text-align: center;
    }

    .newsletter-fields {
        flex-direction: column;
    }

    .newsletter-fields input {
        min-width: 100%;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--space-8);
        text-align: center;
    }

    .footer-logo {
        margin-left: auto;
        margin-right: auto;
    }

    .social-icons {
        justify-content: center;
    }

    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-legal {
        justify-content: center;
    }
}

/* Small Mobile (< 375px) */
@media (max-width: 374px) {
    .upper-nav a,
    .upper-nav button {
        font-size: var(--text-xs);
        padding: var(--space-1-5) var(--space-0-5);
    }

    .btn-join {
        padding: var(--space-1-5) var(--space-3) !important;
        font-size: 11px;
    }

    .tab-label {
        font-size: 10px;
    }

    .hero-title {
        font-size: var(--text-2xl);
    }
}

/* -----------------------------------------
   14. PRINT STYLES
   ----------------------------------------- */
@media print {
    .upper-nav,
    .main-header,
    .mobile-tab-bar,
    .mobile-nav,
    .mobile-nav-overlay {
        display: none !important;
    }

    .skip-link {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    .hero-section {
        min-height: auto;
        padding: var(--space-8);
    }

    .hero-overlay {
        background: var(--gray-100);
    }

    .hero-title,
    .hero-subtitle {
        color: var(--gray-900);
    }
}

/* -----------------------------------------
   15. UTILITY CLASSES (Tailwind-style)
   ----------------------------------------- */
/* Visually Hidden (SR-only) */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus Ring Utility */
.focus-ring:focus-visible {
    outline: var(--ring-width) solid var(--ring-color);
    outline-offset: var(--ring-offset-width);
}

/* Truncate Text */
.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Transition Utilities */
.transition-all {
    transition-property: all;
    transition-timing-function: var(--ease-in-out);
    transition-duration: var(--duration-150);
}

.transition-colors {
    transition-property: color, background-color, border-color;
    transition-timing-function: var(--ease-in-out);
    transition-duration: var(--duration-150);
}

.transition-transform {
    transition-property: transform;
    transition-timing-function: var(--ease-out);
    transition-duration: var(--duration-200);
}
