:root {
    --forest: #173c28;
    --forest-2: #0d2e1d;
    --cream: #f7f3ea;
    --paper: #fffdf8;
    --sage: #dce7df;
    --sage-2: #edf2ee;
    --gold: #f4b91b;
    --ink: #183627;
    --muted: #5d6c63;
    --border: rgba(23, 60, 40, 0.58);
    --font-display: Georgia, 'Times New Roman', serif;
    --font-body: Arial, Helvetica, sans-serif;
    --container: 1180px;
    --page-gutter: 1rem;
    --section-space: clamp(4rem, 7vw, 7.5rem);
    --radius-sm: 13px;
    --radius-md: 28px;
    --shadow: 0 20px 55px rgba(23, 60, 40, 0.1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
    margin: 0;
    overflow-x: hidden;
    background: var(--cream);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}
body.menu-open { overflow: hidden; }
img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
a { color: inherit; text-underline-offset: 0.18em; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.screen-reader-text { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
h1, h2, h3, h4 { margin: 0 0 0.65em; color: var(--forest); font-family: var(--font-display); font-weight: 500; line-height: 1.08; text-wrap: balance; }
h1 { font-size: clamp(2.55rem, 5.4vw, 5.25rem); letter-spacing: -0.035em; }
h2 { font-size: clamp(2rem, 3.4vw, 3.4rem); letter-spacing: -0.025em; }
h3 { font-size: clamp(1.15rem, 1.55vw, 1.45rem); }
p { margin: 0 0 1.2em; }

.container { width: min(calc(100% - (var(--page-gutter) * 2)), var(--container)); margin-inline: auto; }
.section { padding-block: var(--section-space); }
.section--white { background: rgba(255, 255, 255, 0.78); }
.kicker { margin-bottom: 0.7rem; color: var(--forest); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; }
.section-title { max-width: 860px; }
.section-title--narrow { max-width: 680px; }
.section-heading-centered { max-width: 820px; margin: 0 auto 3rem; text-align: center; }
.section-heading-centered--compact { margin-bottom: 2rem; }
.section-heading-centered p { max-width: 660px; margin-inline: auto; color: var(--muted); }

.skip-link { position: fixed; top: 0.75rem; left: 0.75rem; z-index: 9999; transform: translateY(-180%); padding: 0.75rem 1rem; background: white; color: var(--forest); box-shadow: var(--shadow); }
.skip-link:focus { transform: translateY(0); }

.site-header { position: sticky; top: 0; z-index: 1000; padding-block: 0.85rem; background: rgba(247, 243, 234, 0.92); backdrop-filter: blur(14px); border-bottom: 1px solid rgba(23, 60, 40, 0.06); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: 60px; padding: 0.15rem 1rem; background: rgba(255, 255, 255, 0.78); border: 1px solid rgba(23, 60, 40, 0.09); }
.brand { display: inline-flex; flex-direction: column; line-height: 1; }
.brand__fallback { display: inline-flex; flex-direction: column; text-decoration: none; }
.brand .custom-logo-link { display: block; }
.brand .custom-logo { width: auto; max-width: 210px; max-height: 52px; }
.brand__name { color: var(--forest); font-family: var(--font-display); font-size: 1.45rem; }
.brand__tagline { margin-top: 0.24rem; color: var(--muted); font-size: 0.58rem; letter-spacing: 0.08em; text-transform: uppercase; }
.primary-nav { display: flex; align-items: center; gap: 1.4rem; }
.primary-nav__links { display: flex; align-items: center; gap: 1.35rem; margin: 0; padding: 0; list-style: none; }
.primary-nav__links a { font-size: 0.78rem; font-weight: 600; text-decoration: none; }
.primary-nav__links a:hover, .primary-nav__links a:focus-visible { color: #38825b; }
.menu-toggle { display: none; align-items: center; gap: 0.6rem; border: 0; background: transparent; color: var(--forest); }
.menu-toggle__icon, .menu-toggle__icon::before, .menu-toggle__icon::after { display: block; width: 20px; height: 1px; background: currentColor; transition: transform 180ms ease; }
.menu-toggle__icon { position: relative; }
.menu-toggle__icon::before, .menu-toggle__icon::after { content: ''; position: absolute; left: 0; }
.menu-toggle__icon::before { top: -6px; }
.menu-toggle__icon::after { top: 6px; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; min-height: 44px; padding: 0.78rem 1.15rem; border: 0; border-radius: 999px; font-size: 0.78rem; font-weight: 700; text-decoration: none; transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease; }
.button:hover { transform: translateY(-2px); box-shadow: 0 9px 24px rgba(23, 60, 40, 0.16); }
.button--small { min-height: 36px; padding: 0.58rem 0.85rem; font-size: 0.7rem; }
.button--forest { background: var(--forest); color: #fff; }
.button--gold { background: var(--gold); color: var(--forest-2); }

.plus-list { display: grid; gap: 0.7rem; padding: 0; margin: 1.3rem 0 2rem; list-style: none; }
.plus-list li { position: relative; padding-left: 1.15rem; }
.plus-list li::before { content: '+'; position: absolute; left: 0; color: #37a66b; font-weight: 800; }
.plus-list--compact { gap: 0.45rem; font-size: 0.9rem; }

.site-footer {
    padding-block: clamp(3rem, 5vw, 4.25rem) 0;
    background: var(--forest-2);
    color: var(--cream);
}
.site-footer__inner { display: flex; flex-direction: column; gap: 0; }
.site-footer__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr));
    gap: 2.5rem;
    padding-bottom: clamp(2.25rem, 4vw, 3rem);
}
.site-footer__brand { max-width: 22rem; }
.site-footer__brand-link {
    display: inline-flex;
    flex-direction: column;
    text-decoration: none;
    line-height: 1;
}
.site-footer__brand-link:hover .site-footer__brand-name,
.site-footer__brand-link:focus-visible .site-footer__brand-name { color: var(--gold); }
.site-footer__brand-link:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.site-footer__brand-name {
    color: var(--cream);
    font-family: var(--font-display);
    font-size: 1.55rem;
    font-weight: 500;
}
.site-footer__brand-tagline {
    margin-top: 0.35rem;
    color: #a8bfb0;
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.site-footer__description {
    margin: 1.15rem 0 1.35rem;
    color: #a8bfb0;
    font-size: 0.86rem;
    line-height: 1.55;
}
.site-footer__cta { width: fit-content; }
.site-footer__cta:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.site-footer__heading {
    margin: 0 0 1rem;
    color: var(--cream);
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    line-height: 1.3;
    text-transform: uppercase;
}
.site-footer__list {
    display: grid;
    gap: 0.15rem;
    margin: 0;
    padding: 0;
    list-style: none;
}
.site-footer__list a {
    display: inline-flex;
    align-items: center;
    min-height: 2.25rem;
    color: #c5d6cb;
    font-size: 0.86rem;
    line-height: 1.35;
    text-decoration: none;
    transition: color 160ms ease;
}
.site-footer__list a:hover,
.site-footer__list a:focus-visible {
    color: var(--gold);
    text-decoration: underline;
}
.site-footer__list a:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.site-footer__serving {
    margin-top: 0.35rem;
    color: #a8bfb0;
    font-size: 0.82rem;
    line-height: 1.45;
}
.site-footer__bottom {
    padding-block: 1.15rem 1.35rem;
    border-top: 1px solid rgba(220, 231, 223, 0.14);
}
.site-footer__clarification {
    margin: 0 0 0.7rem;
    color: #8fa598;
    font-size: 0.74rem;
    line-height: 1.4;
}
.site-footer__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 1.5rem;
}
.site-footer__copyright {
    margin: 0;
    color: #8fa598;
    font-size: 0.74rem;
    line-height: 1.45;
}
.site-footer__privacy {
    flex-shrink: 0;
    color: #c5d6cb;
    font-size: 0.74rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}
.site-footer__privacy:hover,
.site-footer__privacy:focus-visible {
    color: var(--gold);
    text-decoration: underline;
}
.site-footer__privacy:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

@media (max-width: 860px) {
    html { scroll-padding-top: 74px; }
    .site-header { padding-block: 0.5rem; }
    .site-header__inner { min-height: 54px; }
    .menu-toggle { display: inline-flex; padding: 0.75rem; }
    .primary-nav {
        position: fixed;
        inset: 74px 1rem auto;
        display: none;
        align-items: stretch;
        flex-direction: column;
        gap: 0;
        padding: 1rem;
        background: var(--paper);
        border: 1px solid rgba(23, 60, 40, 0.14);
        box-shadow: var(--shadow);
    }
    .primary-nav.is-open { display: flex; }
    .primary-nav__links { align-items: stretch; flex-direction: column; gap: 0; }
    .primary-nav__links a { display: block; padding: 0.9rem 0.5rem; border-bottom: 1px solid rgba(23, 60, 40, 0.08); font-size: 0.95rem; }
    .primary-nav__cta { margin-top: 0.8rem; }
    .site-footer__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 2.25rem 2rem;
    }
    .site-footer__brand { max-width: none; }
}

/* Mobile page gutter — keeps every section, card, and image aligned to the
   same left/right edge instead of crowding the viewport edges. */
@media (max-width: 767px) {
    :root { --page-gutter: 20px; }
    .site-footer__grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .site-footer__meta {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 540px) {
    :root { --section-space: 4.25rem; }
    h1 { font-size: clamp(2.25rem, 12vw, 3.4rem); }
    h2 { font-size: clamp(1.8rem, 9vw, 2.55rem); }
    .brand__tagline { display: none; }
}

@media (max-width: 359px) {
    :root { --page-gutter: 16px; }
}

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

/* Temporary development build badge — remove before final launch. */
.sagecare-build-badge {
    position: fixed;
    right: 12px;
    bottom: 12px;
    z-index: 9999;
    padding: 6px 9px;
    border-radius: 6px;
    background: var(--forest);
    color: #fff;
    font-family: var(--font-body);
    font-size: 11px;
    line-height: 1.2;
    opacity: 0.85;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
    pointer-events: none;
}

@media (max-width: 540px) {
    .sagecare-build-badge { right: 8px; bottom: 8px; padding: 5px 7px; font-size: 10px; }
}
