/* Responsive and target-size invariants retained across route-split bundles. */
/* Sit page titles just under the fixed header instead of a second header-height of empty cream. */
:root{--header-h:64px}
body>header,header{position:fixed!important;top:0;left:0;right:0;z-index:10050!important}
main>section:first-child{padding-top:calc(var(--header-h,64px) + 12px)!important}
body[data-page="home"] main>section.hero,
section.hero,
.err404{padding-top:calc(var(--header-h,64px) + 16px)!important}
.art-divider{display:flex;align-items:center;justify-content:center;gap:22px;color:var(--gold);opacity:.6;padding:6px 0}
.art-divider::before,.art-divider::after{content:"";height:1px;width:90px;background:linear-gradient(90deg,transparent,var(--gold-2));border-radius:2px}
.art-divider::after{background:linear-gradient(90deg,var(--gold-2),transparent)}
.art-divider svg{width:19px;height:19px}
footer{background:var(--deep-2);color:rgba(251,239,224,.75);padding:56px 0 36px;position:relative;overflow:hidden;isolation:isolate}
footer::before{content:"";position:absolute;right:-120px;top:-140px;width:400px;height:400px;border:1.5px solid rgba(201,138,43,.25);border-radius:50%}
.foot-grid{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(0,.8fr) minmax(0,.8fr) minmax(0,1fr);gap:28px;position:relative;z-index:1}
.foot-brand{font-family:var(--serif);font-size:24px;color:#fff6ea;margin-bottom:12px}
footer h4{color:var(--gold-2);font-size:12.5px;letter-spacing:.16em;text-transform:uppercase;margin-bottom:16px}
footer a{color:rgba(251,239,224,.85)}
.foot-links{display:grid;gap:10px;font-size:15px}
.foot-links a{color:#fff6ea}
.foot-legal{border-top:1px solid rgba(224,172,84,.25);margin-top:36px;padding-top:20px;font-size:13px;position:relative;z-index:1;display:flex;justify-content:space-between;gap:12px 24px;line-height:1.55;flex-wrap:wrap}
.foot-legal,.foot-legal a{color:rgba(251,239,224,.78)}
.foot-links a.foot-demo{min-height:24px}
body[data-page="find-care"] .path-jumps{display:flex;flex-wrap:wrap;gap:10px;margin-top:22px;align-items:center}
body[data-page="find-care"] .path-jumps .pj-label{font-size:12px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--gold);margin-right:4px}
body[data-page="find-care"] .path-jumps a{display:inline-flex;align-items:center;gap:6px;min-height:40px;padding:9px 16px;border-radius:999px;border:1.5px solid var(--line-2);background:var(--card);color:var(--ink);font-size:14px;font-weight:600;text-decoration:none!important;transition:background .15s,border-color .15s,transform .15s,box-shadow .15s}
body[data-page="find-care"] .path-jumps a:hover{border-color:var(--gold);background:var(--gold-tint);color:var(--deep);transform:translateY(-1px);box-shadow:0 4px 12px rgba(201,138,43,.12)}
body[data-page="find-care"] .path-jumps a:focus-visible{outline:2.5px solid var(--gold);outline-offset:2px}
body[data-page="give"] .need-check{width:24px;height:24px}
@media(max-width:960px){
  .foot-grid{grid-template-columns:1fr 1fr}
  body[data-page="volunteer"] .vol-grid,
  body[data-page="about"] .about-grid{grid-template-columns:1fr}
  body[data-page="volunteer"] .roles-wide,
  body[data-page="volunteer"] .perks-3{grid-template-columns:1fr 1fr}
}
@media(max-width:680px){
  .foot-grid{grid-template-columns:1fr}
  body[data-page="volunteer"] .roles-wide,
  body[data-page="volunteer"] .perks-3{grid-template-columns:1fr}
}

/* Visual consistency: keep every public route on the same stable header geometry. */
.brand-name{white-space:nowrap}
.ghost{display:none!important}
@media(min-width:1181px){
  .nav{gap:16px}
  .brand{flex:none}
  .nav-links{gap:2px;flex-wrap:nowrap}
  .nav-links a{padding:8px 9px;font-size:14px;white-space:nowrap;border-radius:999px}
  .nav-actions{gap:6px;margin-left:6px;flex:none}
  .nav-portal{padding:7px 11px;font-size:13px}
  .nav-portal .nav-demo{display:none}
  .nav-cta{padding:9px 16px!important;font-size:13.5px!important}
}

/* FAQ base styles must stay in the route-critical bundle, including the custom marker. */
.faq-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:0}
details.faq{background:var(--card);border:1px solid var(--line-2);border-radius:16px;padding:20px 22px;box-shadow:var(--shadow);margin-bottom:12px}
details.faq summary{list-style:none;cursor:pointer;display:flex;align-items:center;gap:12px;font-family:var(--serif);font-size:18px;color:var(--ink);font-weight:500;line-height:1.3}
details.faq summary::marker{content:""}
details.faq summary::-webkit-details-marker{display:none}
details.faq summary .plus{margin-left:auto;width:22px;height:22px;border-radius:50%;background:var(--gold-tint);border:1px solid var(--gold-2);color:var(--deep);display:inline-flex;align-items:center;justify-content:center;font-size:14px;font-weight:700;transition:transform .22s ease;flex:none;font-family:var(--sans)}
details.faq[open] summary .plus{transform:rotate(45deg)}
details.faq .more-body{margin-top:12px;color:var(--muted);font-size:14.5px;line-height:1.6}
@media(max-width:960px){.faq-grid{grid-template-columns:1fr}}

/* The clinic map and profile are peers on desktop and a readable stack on small screens. */
@media(max-width:960px){
  body[data-page="clinics"] .clinic-panes{grid-template-columns:1fr}
  body[data-page="clinics"] .clinic-panes .map-shell,
  body[data-page="clinics"] .clinic-panes #clinicMap{height:380px;min-height:380px}
}

/* Turn the supplies spreadsheet into compact cards instead of clipping it on phones. */
@media(max-width:680px){
  body[data-page="give"] .needs-wrap{padding:10px;overflow:visible}
  body[data-page="give"] .need-check{width:24px!important;height:24px!important;min-width:24px;min-height:24px}
  body[data-page="give"] .needs-table{display:block;width:100%;min-width:0!important}
  body[data-page="give"] .needs-table thead{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip:rect(0 0 0 0)!important;white-space:nowrap!important}
  body[data-page="give"] .needs-table tbody{display:grid;gap:12px}
  body[data-page="give"] .needs-table tr.cat{display:block;margin-top:4px}
  body[data-page="give"] .needs-table tr.cat td{display:block;width:100%;padding:9px 12px;border:0;border-radius:10px}
  body[data-page="give"] .needs-table tr:not(.cat){display:grid;grid-template-columns:40px repeat(3,minmax(0,1fr));background:#FFFDF9;border:1px solid var(--line);border-radius:14px;overflow:hidden;box-shadow:0 4px 12px rgba(142,27,32,.05)}
  body[data-page="give"] .needs-table tr:not(.cat) td{display:block;min-width:0;border:0;padding:9px 10px;overflow-wrap:anywhere}
  body[data-page="give"] .needs-table tr:not(.cat) td:first-child{grid-row:1/3;display:flex;align-items:flex-start;justify-content:center;padding-top:14px}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(2){grid-column:2/-1;border-bottom:1px solid var(--line);font-size:14px}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(3),
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(4),
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(5){text-align:left!important;font-size:14px;font-weight:700;color:var(--deep)}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(3)::before,
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(4)::before,
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(5)::before{display:block;margin-bottom:2px;font-size:9.5px;font-weight:700;letter-spacing:.09em;text-transform:uppercase;color:var(--muted)}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(3)::before{content:"Needed"}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(4)::before{content:"Have"}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(5)::before{content:"Still needed"}
  body[data-page="give"] .needs-table tr:not(.cat) td:nth-child(6){grid-column:2/-1;padding-top:0}
  body[data-page="give"] .needs-table .stock-bar{min-width:0;width:100%}
  body[data-page="give"] .needs-bar{padding:14px;align-items:stretch}
  body[data-page="give"] .needs-bar .btn{width:100%;justify-content:center;text-align:center}
}

/* Leaflet's visual pins also need a full touch target on the certified mobile viewport. */
@media(max-width:680px){
  .leaflet-marker-icon.leaflet-interactive{min-width:24px!important;min-height:24px!important}
  body[data-page="clinics"] .map-legend{top:12px;right:12px;bottom:auto;left:auto;max-width:170px}
  body[data-page="clinics"] .leaflet-control-attribution{max-width:145px;white-space:normal;line-height:1.2;text-align:right}
}

/* Final icon-legibility pass: preserve the brand palette while keeping every glyph distinct. */
.ic{border:1.5px solid rgba(74,35,12,.24);box-shadow:0 4px 12px rgba(74,35,12,.1)}
.ic svg,.j-node svg,.trust-item svg,.foot-links svg,.step-ic svg{stroke-width:2.1}
.ic-red{border-color:#8E1B20}
.ic-deep{border-color:#B9822B}
.ic-gold{border-color:#E0AC54}
.ic-tint{background:#FFF7E8;border-color:#B9822B;color:#6E1418}
.trust-item{color:#6F564D}
.trust-item svg{color:#7A5518}
.art-divider{opacity:.9;color:#8A5A13}
.art-divider svg{color:#8A5A13}
.foot-links svg{color:#E9B75E}
.journey .j-node{border:2px solid rgba(255,246,234,.78)}
.journey .j-node.gold{background:#7A5518;color:#FFF6EA;border-color:#E0AC54}
.steps .step-ic{width:38px;height:38px;display:grid;place-items:center;border-radius:12px;background:#FFF7E8;color:#7A5518;border:1.5px solid #B9822B;box-shadow:0 4px 12px rgba(122,85,24,.1);top:18px;right:18px}
.steps .step-ic svg{width:20px;height:20px}
.f-field label svg{color:#7A5518;stroke-width:2.1}
details.faq{opacity:1!important}
details.faq .more-body{color:#5A4038!important;opacity:1!important}

/* Homepage audience paths: Patient vs Community. */
.hero-path{align-items:center}
.hero-path .path-copy{display:flex;flex-direction:column;align-items:flex-start;gap:1px;line-height:1.2;text-align:left}
.hero-path .path-who{font-size:10.5px;font-weight:800;letter-spacing:.14em;text-transform:uppercase;color:inherit}
.btn-red.hero-path .path-who,.btn-red.hero-path .path-do{color:#FFF6EA}
.hero-path .path-do{font-size:16px;font-weight:600}

/* Portrait: center page titles (eyebrow, h1, lede, gold rule) on every public route. */
@media (orientation: portrait){
  .hero-grid > .rv:first-child,
  main > section .wrap > .rv:first-child:has(> .eyebrow),
  .err404 .wrap > .rv:first-child{
    text-align:center
  }
  .hero-grid > .rv:first-child .lede,
  main > section .wrap > .rv:first-child:has(> .eyebrow) .lede,
  .err404 .wrap > .rv:first-child .lede{
    margin-left:auto;margin-right:auto
  }
  .hero-grid > .rv:first-child .gold-rule,
  main > section .wrap > .rv:first-child:has(> .eyebrow) .gold-rule,
  .err404 .wrap > .rv:first-child .gold-rule{
    margin-left:auto;margin-right:auto
  }
  .hero-ctas{justify-content:center}
  .hero-path .path-copy{align-items:center;text-align:center}
  .hero-grid > .rv:first-child .eyebrow,
  main > section .wrap > .rv:first-child:has(> .eyebrow) .eyebrow,
  .err404 .wrap > .rv:first-child .eyebrow,
  .foot-cta .eyebrow{justify-content:center}
  .foot-cta{flex-direction:column;text-align:center;align-items:center}
  .foot-cta p{margin-left:auto;margin-right:auto}
  .foot-cta-btns{justify-content:center}
  body[data-page="find-care"] .path-jumps{justify-content:center}
  .care-today{flex-direction:column;align-items:stretch}
  .care-today .ct-label,.care-today p{text-align:center}
  .care-today-actions{flex-direction:column;align-items:stretch;width:100%}
  .care-today .btn{
    width:100%;
    justify-content:center;
    min-height:52px;
    padding:16px 28px;
    font-size:17px;
    box-sizing:border-box
  }
}

/* Compact nav: keep Volunteer portal on the header bar (portrait and landscape). */
.nav-portal-persist{display:none}
@media (max-width:1180px){
  .nav{gap:8px;padding-left:16px;padding-right:12px}
  .brand-name{font-size:16.5px}
  .nav-portal-persist{
    display:inline-flex!important;
    margin-left:auto!important;
    width:auto!important;
    max-width:none!important;
    min-height:40px!important;
    height:auto!important;
    padding:7px 10px!important;
    font-size:12.5px!important;
    justify-content:center;
    flex:0 0 auto!important;
    white-space:nowrap;
    align-self:center
  }
  .nav-portal-persist .nav-demo{display:none}
  header .burger{margin-left:4px;flex:none}
}
@media (max-width:380px){
  .nav-portal-persist{font-size:12px;padding:7px 10px}
}
