/* ============================================================
   Memora — shared customer/public styles
   Provides the hamburger nav component + mobile utilities.
   Colour palette: bg #f6f2ec  dark #2b2b2b  brown #5d4226  light #efe5d6
   ============================================================ */

/* ── Nav wrapper ── */
.c-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    margin-bottom: 28px;
}

/* ── Brand / logo ── */
.c-brand {
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #2b2b2b;
    text-decoration: none;
    flex-shrink: 0;
    line-height: 1;
}
.c-brand:hover { color: #5d4226; }

/* ── Link area ── */
.c-nav-links {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}
.c-nav-links a {
    color: #2b2b2b;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
    white-space: nowrap;
}
.c-nav-links a:hover { color: #5d4226; }

/* Logout as plain text button */
.c-nav-logout {
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 700;
    font-size: 15px;
    color: #2b2b2b;
    padding: 0;
    font-family: inherit;
    white-space: nowrap;
}
.c-nav-logout:hover { color: #5d4226; }

/* Welcome greeting */
.c-nav-welcome {
    font-size: 14px;
    color: #666;
    font-weight: 600;
    white-space: nowrap;
}

/* CTA pill (Get started / dark button in nav) */
.c-nav-cta {
    display: inline-block;
    background: #2b2b2b;
    color: #fff !important;
    border-radius: 999px;
    padding: 10px 18px;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    white-space: nowrap;
}
.c-nav-cta:hover { opacity: 0.88; }

/* Ghost pill (secondary nav button) */
.c-nav-ghost {
    display: inline-block;
    background: #efe5d6;
    color: #5d4226 !important;
    border-radius: 999px;
    padding: 10px 18px;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    white-space: nowrap;
}
.c-nav-ghost:hover { background: #e2d4c0; }

/* ── Hamburger toggle (hidden on desktop) ── */
.c-nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    min-width: 44px;
    min-height: 44px;
    border-radius: 10px;
    -webkit-tap-highlight-color: transparent;
}
.c-nav-toggle:hover { background: #efe5d6; }
.c-nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #2b2b2b;
    border-radius: 2px;
}

/* ── Mobile breakpoint ── */
@media (max-width: 640px) {

    /* Narrative text scaling — inline px styles are too small on phones */
    p, li, td, th, label,
    .subtitle, .hero-text, .modal-tagline,
    .trust-list li, .step p, .panel p,
    .reassurance-item, .eyebrow {
        font-size: 18px !important;
        line-height: 1.7 !important;
    }

    /* Small helper text stays small — these are intentionally de-emphasised */
    small, .hint, .muted, .badge,
    [style*="font-size:11px"], [style*="font-size:12px"] {
        font-size: 13px !important;
    }

    /* Show hamburger */
    .c-nav-toggle {
        display: flex;
    }

    /* Dropdown panel */
    .c-nav-links {
        display: none;
        position: absolute;
        top: calc(100% + 8px);
        left: 0;
        right: 0;
        background: #fff;
        border-radius: 18px;
        box-shadow: 0 10px 32px rgba(0,0,0,0.14);
        padding: 8px;
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
        z-index: 500;
    }
    .c-nav-links.open {
        display: flex;
    }

    /* Each nav item row */
    .c-nav-links > a,
    .c-nav-links > form > .c-nav-logout {
        font-size: 16px;
        min-height: 48px;
        display: flex;
        align-items: center;
        padding: 0 14px;
        border-radius: 12px;
        white-space: normal;
        box-sizing: border-box;
    }
    .c-nav-links > a:hover,
    .c-nav-links > form > .c-nav-logout:hover {
        background: #f6f2ec;
        color: #5d4226;
    }

    /* Welcome line — smaller, muted */
    .c-nav-links > .c-nav-welcome {
        font-size: 12px;
        color: #aaa;
        min-height: 32px;
        display: flex;
        align-items: center;
        padding: 0 14px 0;
        border-bottom: 1px solid #f0ede8;
        margin-bottom: 4px;
        border-radius: 0;
    }

    /* Logout form full-width */
    .c-nav-links > form {
        display: block;
        width: 100%;
        margin: 0;
    }
    .c-nav-links > form > .c-nav-logout {
        width: 100%;
        text-align: left;
    }

    /* CTA + ghost pills — keep pill style but full-width in menu */
    .c-nav-links > .c-nav-cta,
    .c-nav-links > .c-nav-ghost {
        border-radius: 12px;
        padding: 0 14px;
        min-height: 48px;
        display: flex;
        align-items: center;
        width: 100%;
        box-sizing: border-box;
        font-size: 16px;
    }
}
