/* chrome.css for /for/aging-parents/ : the preserved site chrome (tokens, banner, nav,
   footer, subscribe modal). A copy of /sc/parents/chrome.css with ONE change: the
   hamburger drawer rules apply at every width (the original wraps them in
   max-width:1023px), because this page's bar is a fixed minimal bar (wordmark, one
   CTA, a menu) and the seven site links live in the drawer on desktop too.
   Everything page specific is in page.css. */
/* chrome.css: the preserved site chrome (tokens, banner, nav, footer, subscribe modal),
   copied from /for/landing.css (read-only) so the page does not have to load the whole
   old stylesheet. Fonts swapped to the brand pair (Brygada 1918 + Lexend); em dash
   glyph in the modal list replaced. Generated by builds/parents/build.py. */
  /* ---------- Tokens ---------- */
  :root{
    /* === Apple page-width tokens (2026-08-12) - see
       CareHaven-blog/docs/PLAN-site-width-apple-standard.md
       Token is the CONTENT measure; outer = content + 2 x gutter (border-box). */
    --page-content:980px;
    --prose-content:840px;
    --gutter:22px;

    --bg:#FAF6F0;
    --bg-raised:#FFFFFF;
    --bg-subtle:#F4EFE7;
    --text:#2C2621;
    --text-2:#534A42;
    --text-3:#6B5F55; /* was #7D7065 (4.46:1 on cream); now 5.75:1, the home page's value */
    --bd:#EDE8E3;
    --bd-2:#D9D1C4;
    --hv:#7A8B5C;
    --hv-d:#5E6E45;
    --hv-l:#EEF2E5;
    --hv-l2:#E4EBD6;
    --amber:#C08B5C;
    --amber-l:#FBF0E6;
    --coral:#C25B4D;
    --coral-l:#FBEAE6;
    --coral-t:#9E3F33; /* coral for small text: 5.61:1 on --coral-l, 6.54:1 on white */
    --sky:#6B8CAE;
    --sky-l:#E7EEF6;
    --blossom:#D88BA1;
    --blossom-l:#FBEAEF;
    --shadow-sm:0 1px 2px rgba(44,38,33,.04), 0 4px 12px rgba(44,38,33,.05);
    --shadow-md:0 4px 12px rgba(44,38,33,.06), 0 16px 40px rgba(44,38,33,.08);
    --shadow-lg:0 8px 24px rgba(44,38,33,.08), 0 24px 64px rgba(44,38,33,.12);
    --nav-bg:rgba(250,246,240,.92);
    --radius:14px;
    --radius-lg:22px;
  }
  @media (max-width:833px){ :root{ --gutter:16px } }
  html[data-theme="dark"]{
    --bg:#1C1B18;
    --bg-raised:#262420;
    --bg-subtle:#2D2B27;
    --text:#F2EDE6;
    --text-2:#C0B8AE;
    --text-3:#A9A198; /* was #8E867E (4.32:1 on --bg-raised); now 6.08:1, the home page's value */
    --bd:#36332F;
    --bd-2:#48433D;
    --hv:#9DAE7A;
    --hv-d:#B8C68F;
    --hv-l:#2B3520;
    --hv-l2:#36402A;
    --amber-l:#3A2D20;
    --coral-l:#3A201D;
    --coral-t:#F0A99F; /* 7.75:1 on --coral-l, 8.03:1 on --bg-raised */
    --sky-l:#1F2A37;
    --blossom-l:#3A2027;
    --shadow-sm:0 1px 2px rgba(0,0,0,.3), 0 4px 12px rgba(0,0,0,.4);
    --shadow-md:0 4px 12px rgba(0,0,0,.4), 0 16px 40px rgba(0,0,0,.5);
    --shadow-lg:0 8px 24px rgba(0,0,0,.5), 0 24px 64px rgba(0,0,0,.6);
    --nav-bg:rgba(28,27,24,.92);
  }

/* scoped reset + link base (zero specificity so every chrome rule below wins) */
:where(.pre-release-banner,.nav,footer,.modal-backdrop) , :where(.pre-release-banner,.nav,footer,.modal-backdrop) *{margin:0;padding:0}
:where(.pre-release-banner,.nav,footer,.modal-backdrop) a{color:var(--hv-d);text-decoration:none;font-weight:600}
:where(.pre-release-banner,.nav,footer,.modal-backdrop) a:hover{color:var(--hv)}
:where(.nav,.modal-backdrop) button{font-family:inherit;border:none;background:none;cursor:pointer;color:inherit}
.container{max-width:calc(var(--page-content) + 2 * var(--gutter));margin:0 auto;padding-inline:max(var(--gutter),env(safe-area-inset-left)) max(var(--gutter),env(safe-area-inset-right))}

  /* ---------- Banner ---------- */
  .pre-release-banner{
    background:linear-gradient(180deg, var(--amber-l), var(--bg-subtle));
    color:var(--text-2);
    text-align:center;
    padding:10px 20px;
    font-size:13.5px;
    font-weight:600;
    border-bottom:1px solid var(--bd);
  }
  .pre-release-banner a{margin-left:6px}

  /* ---------- Nav ---------- */
  .nav{
    position:sticky;
    top:0;
    z-index:50;
    backdrop-filter:saturate(160%) blur(16px);
    -webkit-backdrop-filter:saturate(160%) blur(16px);
    background:var(--nav-bg);
    border-bottom:1px solid var(--bd);
  }
  .nav-inner{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding-block:14px;
    padding-inline:max(var(--gutter),env(safe-area-inset-left)) max(var(--gutter),env(safe-area-inset-right));
    max-width:calc(var(--page-content) + 2 * var(--gutter));
    margin:0 auto;
  }
  .brand{
    display:flex;
    align-items:center;
    gap:10px;
    font-family:var(--sc-font-display);
    font-weight:600;
    font-size:20px;
    letter-spacing:-.01em;
  }
  .brand-mark{
    width:32px;
    height:32px;
    background:transparent;
    display:inline-block;
    flex:none;
  }
  .brand-mark img{
    width:100%;
    height:100%;
    display:block;
  }
  .brand-tag{
    font-family:var(--sc-font-text);
    font-size:10px;
    font-weight:700;
    letter-spacing:1px;
    text-transform:uppercase;
    color:var(--amber);
    background:var(--amber-l);
    border-radius:999px;
    padding:3px 9px;
    margin-left:6px;
  }
  .nav-links{display:flex;gap:22px;align-items:center}
  .nav-links a{
    color:var(--text-2);
    font-weight:500;
    font-size:14.5px;
    transition:color .15s;
  }
  .nav-links a:hover{color:var(--hv-d)}
  .mobile-menu-toggle,
  .mobile-menu-backdrop,
  .mobile-menu-header{display:none}
  .nav-cta{
    background:var(--hv);
    color:#FAF6F0 !important;
    padding:8px 16px;
    border-radius:999px;
    font-weight:600;
    font-size:13.5px;
    transition:transform .15s, background .15s;
  }
  .nav-cta:hover{background:var(--hv-d);transform:translateY(-1px)}
  .theme-toggle{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:34px;
    height:34px;
    border-radius:50%;
    color:var(--text-2);
    transition:background .15s, color .15s;
  }
  .theme-toggle:hover{background:var(--bg-subtle);color:var(--hv-d)}
  .theme-toggle .moon{display:none}
  .theme-toggle .sun{display:none}
  html[data-theme="dark"] .theme-toggle .sun{display:block;width:16px;height:16px}
  html[data-theme="light"] .theme-toggle .moon{display:block;width:16px;height:16px}
  .theme-toggle-label{display:none}

  @media all{
    .nav-inner{padding-block:12px}
    .brand{font-size:19px}
    .brand-tag{display:none}
    .mobile-menu-toggle{
      display:inline-flex;
      align-items:center;
      justify-content:center;
      width:56px;
      height:44px;
      border:1px solid rgba(122,139,92,.18);
      border-radius:999px;
      color:var(--text);
      background:rgba(255,255,255,.58);
      box-shadow:var(--shadow-sm);
      cursor:pointer;
      -webkit-tap-highlight-color:transparent;
    }
    html[data-theme="dark"] .mobile-menu-toggle{
      background:rgba(38,36,32,.72);
      border-color:rgba(255,255,255,.08);
    }
    .mobile-menu-toggle span,
    .mobile-menu-toggle::before,
    .mobile-menu-toggle::after{
      content:"";
      display:block;
      width:18px;
      height:2px;
      border-radius:999px;
      background:currentColor;
      transition:transform .18s ease, opacity .18s ease;
    }
    .mobile-menu-toggle{
      flex-direction:column;
      gap:4px;
    }
    body.mobile-menu-open .mobile-menu-toggle::before{transform:translateY(6px) rotate(45deg)}
    body.mobile-menu-open .mobile-menu-toggle span{opacity:0}
    body.mobile-menu-open .mobile-menu-toggle::after{transform:translateY(-6px) rotate(-45deg)}
    .mobile-menu-backdrop{
      display:block;
      position:fixed;
      inset:0;
      /* Must sit BELOW .nav (z-index:50), which is its own stacking context
         (it sets both z-index and backdrop-filter). The drawer (.nav-links)
         lives inside .nav, so its z-index:60 is scoped to that context and
         cannot beat a root-level backdrop at 58 -- that let the backdrop
         paint over the menu links and swallow every tap, so tapping an item
         only closed the menu instead of navigating. Keeping the backdrop
         under .nav lets the drawer receive taps while still dimming the page. */
      z-index:49;
      background:rgba(28,27,24,.22);
      opacity:0;
      pointer-events:none;
      transition:opacity .2s ease;
    }
    body.mobile-menu-open .mobile-menu-backdrop{
      opacity:1;
      pointer-events:auto;
    }
    body.mobile-menu-open{overflow:hidden}
    .nav-links{
      position:fixed;
      top:calc(52px + env(safe-area-inset-top));
      left:14px;
      z-index:60;
      display:flex;
      flex-direction:column;
      align-items:stretch;
      gap:0;
      width:min(344px,calc(100vw - 28px));
      max-height:calc(100vh - 76px - env(safe-area-inset-top));
      overflow:auto;
      padding:14px 12px;
      border:1px solid rgba(255,255,255,.42);
      border-radius:28px;
      background:rgba(255,255,255,.96);
      backdrop-filter:saturate(160%) blur(22px);
      -webkit-backdrop-filter:saturate(160%) blur(22px);
      box-shadow:0 22px 54px rgba(44,38,33,.18);
      transform:translateX(calc(-100% - 28px));
      opacity:0;
      pointer-events:none;
      visibility:hidden;   /* closed drawer: not in the tab order */
      transition:transform .24s cubic-bezier(.2,.8,.2,1), opacity .18s ease, visibility 0s linear .24s;
    }
    html[data-theme="dark"] .nav-links{
      background:rgba(38,36,32,.96);
      border-color:rgba(255,255,255,.08);
      box-shadow:0 22px 54px rgba(0,0,0,.42);
    }
    body.mobile-menu-open .nav-links{
      transform:translateX(0);
      opacity:1;
      pointer-events:auto;
      visibility:visible;
      transition:transform .24s cubic-bezier(.2,.8,.2,1), opacity .18s ease, visibility 0s;
    }
    .mobile-menu-header{
      display:flex;
      align-items:center;
      gap:12px;
      padding:6px 4px 12px;
      order:-2;
    }
    .mobile-menu-header .menu-avatar{
      display:inline-flex;
      align-items:center;
      justify-content:center;
      width:40px;
      height:40px;
      border-radius:999px;
      background:var(--hv-l);
      color:var(--hv-d);
      font-family:var(--sc-font-display);
      font-weight:600;
    }
    .mobile-menu-header strong{
      display:block;
      color:var(--text);
      font-size:15px;
      line-height:1.15;
    }
    .mobile-menu-header span:last-child{
      display:block;
      color:var(--text-3);
      font-size:12px;
      line-height:1.2;
      margin-top:2px;
    }
    .nav-links a,
    .nav-links .theme-toggle{
      width:100%;
      min-height:52px;
      display:flex;
      align-items:center;
      justify-content:flex-start;
      gap:12px;
      padding:0 6px;
      border-radius:12px;
      color:var(--text);
      font-size:15px;
      font-weight:700;
      text-align:left;
    }
    .nav-links a + a,
    .nav-links a + .theme-toggle,
    .nav-links .theme-toggle + a{
      border-top:1px solid rgba(217,209,196,.55);
    }
    html[data-theme="dark"] .nav-links a + a,
    html[data-theme="dark"] .nav-links a + .theme-toggle,
    html[data-theme="dark"] .nav-links .theme-toggle + a{
      border-top-color:rgba(255,255,255,.08);
    }
    .nav-links a:hover,
    .nav-links .theme-toggle:hover{
      background:var(--bg-subtle);
      color:var(--hv-d);
      text-decoration:none;
    }
    .nav-links a::before,
    .nav-links .theme-toggle::before{
      content:attr(data-menu-icon);
      display:inline-flex;
      align-items:center;
      justify-content:center;
      width:30px;
      height:30px;
      flex:none;
      border-radius:8px;
      background:var(--hv-l);
      color:var(--hv-d);
      font-size:13px;
      font-weight:800;
    }
    .nav-links .theme-toggle::before{content:"☾"}
    html[data-theme="dark"] .nav-links .theme-toggle::before{content:"☀"}
    .nav-links .theme-toggle{
      height:auto;
      border-radius:12px;
      transition:none;
    }
    .nav-links .theme-toggle .moon,
    .nav-links .theme-toggle .sun{display:none !important}
    .theme-toggle-label{display:inline}
    .nav-cta{
      order:-1;
      min-height:44px !important;
      margin:0 0 8px;
      padding:0 14px !important;
      border-radius:10px;
      background:var(--hv-l);
      color:var(--hv-d) !important;
    }
    .nav-cta::before{
      content:"→" !important;
      background:rgba(122,139,92,.15) !important;
    }
  }

  /* ---------- Footer ---------- */
  footer{
    background:var(--bg-subtle);
    border-top:1px solid var(--bd);
    padding:48px 0 32px;
  }
  .footer-inner{
    display:flex;
    justify-content:space-between;
    align-items:center;
    flex-wrap:wrap;
    gap:18px;
    color:var(--text-3);
    font-size:14px;
  }
  .footer-links{display:flex;gap:18px;flex-wrap:wrap}
  .footer-links a{color:var(--text-2);font-weight:500}
  .footer-disclaimer{
    margin-top:28px;
    font-size:12.5px;
    color:var(--text-3);
    line-height:1.65;
    max-width:760px;
  }
  /* ---------- Subscribe modal ---------- */
  .modal-backdrop{
    position:fixed; inset:0;
    background:rgba(28,27,24,0.55);
    backdrop-filter:blur(6px); -webkit-backdrop-filter:blur(6px);
    display:none; align-items:center; justify-content:center;
    padding:20px; z-index:1000;
    opacity:0; transition:opacity .18s ease;
  }
  .modal-backdrop.is-open{ display:flex; opacity:1; }
  .modal-dialog{
    background:var(--bg-raised);
    color:var(--text);
    border-radius:var(--radius-lg);
    box-shadow:var(--shadow-lg);
    width:100%; max-width:480px;
    max-height:calc(100vh - 40px);
    max-height:calc(100dvh - 40px);
    overflow-y:auto;
    padding:32px;
    position:relative;
    transform:translateY(8px);
    transition:transform .18s ease;
    border:1px solid var(--bd);
  }
  .modal-backdrop.is-open .modal-dialog{ transform:translateY(0); }
  .modal-close{
    position:absolute; top:8px; right:8px;
    width:44px; height:44px; /* 44px hit area; glyph size and position unchanged */
    border:none; border-radius:8px;
    background:transparent; color:var(--text-3);
    cursor:pointer; font-size:20px; line-height:1;
    display:flex; align-items:center; justify-content:center;
  }
  .modal-close:hover{ background:var(--bg-subtle); color:var(--text); }
  .modal-eyebrow{
    text-transform:uppercase; letter-spacing:.12em;
    font-size:11px; font-weight:700;
    color:var(--hv-d); margin-bottom:8px;
  }
  .modal-title{
    font-family:var(--sc-font-display);
    font-size:26px; font-weight:600;
    margin:0 0 8px; color:var(--text); letter-spacing:-.01em;
  }
  .modal-sub{
    font-size:14.5px; line-height:1.55;
    color:var(--text-2); margin:0 0 20px;
  }
  .modal-form .field{ margin-bottom:14px; }
  .modal-form label{
    display:block; font-size:12px; font-weight:600;
    color:var(--text-2); margin-bottom:6px;
  }
  .modal-form label .req{ color:var(--coral-t); margin-left:2px; }
  .modal-form input[type=email],
  .modal-form input[type=text]{
    width:100%; box-sizing:border-box;
    padding:11px 13px;
    border-radius:10px;
    border:1px solid var(--bd-2);
    background:var(--bg);
    color:var(--text);
    font:inherit; font-size:15px;
  }
  .modal-form input[type=email]:focus,
  .modal-form input[type=text]:focus{
    outline:none;
    border-color:var(--hv);
    box-shadow:0 0 0 3px rgba(122,139,92,.18);
  }
  .modal-form .gdpr{
    display:flex; align-items:flex-start; gap:10px;
    padding:12px 14px; border-radius:10px;
    background:var(--bg-subtle);
    margin:6px 0 16px; cursor:pointer;
    font-size:13px; color:var(--text-2); line-height:1.5;
  }
  .modal-form .gdpr input[type=checkbox]{
    margin-top:3px; accent-color:var(--hv);
    width:16px; height:16px; flex-shrink:0;
  }
  .modal-form .submit{
    width:100%; padding:13px 18px;
    border-radius:12px;
    background:var(--hv-d); color:var(--bg); border:none;
    font:inherit; font-weight:600; font-size:15px;
    cursor:pointer; transition:background .15s ease;
  }
  .modal-form .submit:hover:not(:disabled){ background:#4A5738; }
  html[data-theme="dark"] .modal-form .submit{ background:var(--hv); color:var(--bg); }
  html[data-theme="dark"] .modal-form .submit:hover:not(:disabled){ background:var(--hv-d); }
  .modal-form .submit:disabled{ opacity:.6; cursor:default; }
  .modal-msg{
    margin-top:14px; padding:12px 14px;
    border-radius:10px; font-size:13.5px; line-height:1.55;
  }
  .modal-msg.success{
    background:var(--hv-l); color:var(--hv-d);
    border:1px solid rgba(122,139,92,.25);
  }
  .modal-msg.error{
    background:var(--coral-l); color:var(--coral-t);
    border:1px solid rgba(194,91,77,.2);
  }
  .modal-fineprint{
    margin-top:16px; font-size:11.5px;
    color:var(--text-3); line-height:1.55;
  }
  .modal-fineprint a{ color:var(--text-2); }
  /* Beta-mode "what happens next" explainer card. Calm color block
     so caregivers feel briefed rather than tricked. */
  .modal-beta-explainer{
    background:var(--hv-l);
    border-radius:10px;
    padding:14px 16px;
    margin:0 0 18px;
    font-size:14px;
    line-height:1.55;
    color:var(--text);
  }
  .modal-beta-explainer em{
    color:var(--text-2);
    font-style:normal;
    display:block;
    margin-top:6px;
    font-size:13px;
  }
  /* Beta-mode "what's actually expected of you" block. Sits ABOVE the
     TestFlight explainer so the reader sees the ask (use the app +
     leave honest feedback) before the install mechanics. The amber
     tint differentiates it from the sage beta-explainer below so the
     two blocks don't read as a single wall of color. */
  .modal-beta-role{
    background:var(--amber-l);
    border-left:3px solid var(--amber);
    border-radius:10px;
    padding:14px 16px;
    margin:0 0 14px;
    font-size:13.5px;
    line-height:1.55;
    color:var(--text);
  }
  .modal-beta-role strong{
    color:var(--text);
  }
  .modal-beta-role ul{
    margin:8px 0 6px;
    padding:0;
    list-style:none;
  }
  .modal-beta-role li{
    padding:2px 0;
    color:var(--text-2);
    font-style:italic;
    font-size:13px;
  }
  .modal-beta-role li::before{
    content:"• ";
    color:var(--text-3);
    font-style:normal;
  }
  .modal-skip-row{
    margin:10px 0 0;
    text-align:center;
    font-size:13px;
  }
  .modal-skip-link{
    color:var(--text-2);
    font-weight:500;
    text-decoration:underline;
    text-underline-offset:2px;
  }
  .modal-skip-link:hover{ color:var(--text); }

  /* Sign-up done: after a successful sign-up the script adds .is-done to the
     form, which leaves only the confirmation on screen. The heading, intro
     line, message and Mailchimp privacy note stay; the fields, consent tick,
     button and beta skip link are hidden so a quick glance cannot miss the
     message. The script removes .is-done when the pop-up is opened again. */
  .modal-form.is-done .field,
  .modal-form.is-done .gdpr,
  .modal-form.is-done .submit,
  .modal-form.is-done .modal-skip-row{ display:none; }

/* Pop-up fixes (round 2). 1: the close button is sticky, so it stays reachable when the dialog
   scrolls (it sits 8px from the top and right edges, as before). 2: beta mode is compacted and a
   little wider on desktop so the button and skip link fit a 900px-tall window. 4: both skip
   links get a 44px tap area. */
.modal-dialog{ --modal-pad:32px; }
.modal-dialog.modal-is-beta{ --modal-pad:24px; padding:24px; }
.modal-close{
  position:sticky; top:var(--modal-pad); right:auto; z-index:2;
  width:44px; height:44px;
  margin:0 0 -44px auto;
  transform:translate(calc(var(--modal-pad) - 8px), calc(8px - var(--modal-pad)));
  background:var(--bg-raised);
  box-shadow:0 0 0 3px var(--bg-raised);
}
.modal-skip-link{
  display:inline-flex; align-items:center;
  min-height:44px; padding:0 8px; font-size:14px;
}
.modal-dialog.modal-is-beta{ max-height:calc(100vh - 24px); max-height:calc(100dvh - 24px); }
@media (min-width:600px){
  .modal-dialog.modal-is-beta{ max-width:560px; }
}
.modal-dialog.modal-is-beta .modal-eyebrow{ margin-bottom:4px; }
.modal-dialog.modal-is-beta .modal-title{ font-size:24px; margin-bottom:6px; }
.modal-dialog.modal-is-beta .modal-sub{ margin-bottom:12px; }
.modal-dialog.modal-is-beta .modal-beta-role{ padding:10px 14px; margin-bottom:10px; font-size:13px; line-height:1.45; }
.modal-dialog.modal-is-beta .modal-beta-role ul{ margin:4px 0; }
.modal-dialog.modal-is-beta .modal-beta-role li{ padding:1px 0; }
.modal-dialog.modal-is-beta .modal-beta-explainer{ padding:10px 14px; margin-bottom:12px; font-size:13px; line-height:1.45; }
.modal-dialog.modal-is-beta .modal-beta-explainer em{ margin-top:4px; font-size:12.5px; }
.modal-dialog.modal-is-beta .modal-form .field{ margin-bottom:10px; }
.modal-dialog.modal-is-beta .modal-form label{ margin-bottom:4px; }
.modal-dialog.modal-is-beta .modal-form input[type=email],
.modal-dialog.modal-is-beta .modal-form input[type=text]{ padding:9px 13px; }
.modal-dialog.modal-is-beta .modal-form .gdpr{ margin:4px 0 12px; padding:10px 14px; }
.modal-dialog.modal-is-beta .modal-form .submit{ padding:12px 18px; }
.modal-dialog.modal-is-beta .modal-skip-row{ margin-top:2px; }
.modal-dialog.modal-is-beta .modal-fineprint{ margin-top:6px; }
/* Keep eyebrow and heading clear of the sticky close button so the heading wraps instead of running under it. */
.modal-eyebrow, .modal-title{ padding-right:36px; }
