/* Death & Dying staging site. System fonts only, no files from other companies.
   Colors follow the approved mockups (muted blues and greens). Text pairs were chosen for WCAG AA contrast. */
:root{--bg:#F3F6F6;--surface:#FFFFFF;--ink:#23343B;--muted:#4E626A;--accent:#3F6B73;--on-accent:#FFFFFF;--line:#CCD9DC;--p1:#E1EAEC;
--crisis-bg:#23343B;--crisis-ink:#FFFFFF;--t1:#DCE8EA;--t2:#D3E3D8;--t3:#C7DCE2;--t4:#E0E9D6;--t5:#D6E1EC;--scrim:rgba(24,38,43,.82);
--sky1:#C9D9DD;--sky2:#EEF1EC;--focus:#1F4E8C}
:root[data-theme=dark]{--bg:#1F2E29;--surface:#25362F;--ink:#EEE9DD;--muted:#B9C2B8;--accent:#D9B46A;--on-accent:#1F2E29;--line:#3A5048;--p1:#25362F;
--crisis-bg:#141E1A;--crisis-ink:#EEE9DD;--t1:#2C4249;--t2:#2E463B;--t3:#2A4350;--t4:#364A3C;--t5:#2D3F50;--scrim:rgba(12,20,17,.86);--sky1:#18241F;--sky2:#2E433B;--focus:#9CC3FF}
@media (prefers-color-scheme:dark){:root:not([data-theme=light]){--bg:#1F2E29;--surface:#25362F;--ink:#EEE9DD;--muted:#B9C2B8;--accent:#D9B46A;--on-accent:#1F2E29;--line:#3A5048;--p1:#25362F;
--crisis-bg:#141E1A;--crisis-ink:#EEE9DD;--t1:#2C4249;--t2:#2E463B;--t3:#2A4350;--t4:#364A3C;--t5:#2D3F50;--scrim:rgba(12,20,17,.86);--sky1:#18241F;--sky2:#2E433B;--focus:#9CC3FF}}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--ink);font-family:'Avenir Next',Avenir,system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;font-size:1rem;line-height:1.55}
a{color:inherit;text-decoration:none}
:focus-visible{outline:3px solid var(--focus);outline-offset:2px;border-radius:2px}
ul,ol{list-style:none;margin:0;padding:0}
h1,h2,h3,p{margin:0}
img{max-width:100%;height:auto;display:block}
.serif{font-family:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,serif;font-weight:400}
.cap{font-size:.78rem;font-weight:700;letter-spacing:.09em;text-transform:uppercase;color:var(--muted)}
.m{font-size:.8rem;color:var(--muted)}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.skip{position:absolute;left:8px;top:-60px;background:var(--accent);color:var(--on-accent);padding:10px 14px;border-radius:4px;z-index:10}
.skip:focus{top:8px}
.wrap{max-width:1180px;margin:0 auto;padding:0 24px}
main:focus{outline:none}

.crisis{background:var(--crisis-bg);color:var(--crisis-ink);font-size:.9rem}
.crisis .wrap{display:flex;flex-wrap:wrap;justify-content:space-between;gap:4px 20px;padding-top:9px;padding-bottom:9px}
.crisis a{text-decoration:underline}

.hdr{background:var(--surface);border-bottom:1px solid var(--line)}
.hdr-in{display:flex;flex-wrap:wrap;align-items:center;gap:4px 14px;min-height:68px}
.logo{font-family:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,serif;font-size:1.6rem;letter-spacing:.02em;white-space:nowrap}
.logo{display:block;line-height:0}
.logo .lg{display:block;height:63px;width:auto}
.logo .lg-d{display:none}
:root[data-theme=dark] .logo .lg-l{display:none}
:root[data-theme=dark] .logo .lg-d{display:block}
@media (prefers-color-scheme:dark){:root:not([data-theme=light]) .logo .lg-l{display:none}:root:not([data-theme=light]) .logo .lg-d{display:block}}
@media (max-width:700px){.logo .lg{height:52px}}
.menu{display:flex;flex-wrap:wrap;align-items:center}
.menu a{display:block;padding:12px 8px;font-size:.92rem;font-weight:600}
.menu a:hover{text-decoration:underline}
.tools{margin-left:auto;border-left:1px solid var(--line);padding-left:8px}
.tools .tool{color:var(--accent)}
.iconbtn{display:inline-flex;align-items:center;justify-content:center;min-width:44px;min-height:44px;margin-left:4px;border:1px solid var(--muted);border-radius:6px;background:transparent;color:var(--ink);cursor:pointer;padding:0 8px;font:inherit}
.iconbtn[hidden]{display:none}
.menu a.iconbtn{display:inline-flex;padding:0 8px}

.hero{position:relative;padding:72px 0 80px;background:linear-gradient(180deg,var(--sky1),var(--sky2));overflow:hidden}
.hero-img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:.9}
.hero .wrap{position:relative}
.hero h1{font-size:clamp(1.5rem,3.2vw,2.15rem);line-height:1.2;max-width:1100px}
.hero .stats{margin-top:12px;color:var(--ink)}
.block{margin-top:34px}
.block>.cap{display:block;margin-bottom:12px}
.lede{color:var(--muted);margin:14px 0}

.tiles{display:grid;grid-template-columns:repeat(auto-fill,minmax(190px,1fr));gap:14px}
.tile{display:flex;flex-direction:column;min-height:100%;border:1px solid var(--line);border-radius:10px;overflow:hidden;background:var(--t1)}
.tile.t2{background:var(--t2)}.tile.t3{background:var(--t3)}.tile.t4{background:var(--t4)}.tile.t5{background:var(--t5)}
.tile img,.tile .ph-img{width:100%;aspect-ratio:3/2;object-fit:cover;background:var(--p1)}
.tile .l{font-size:1.35rem;line-height:1.22;padding:14px 14px 4px}
.tile .m{padding:0 14px 14px;margin-top:auto}
.tile:hover .l{text-decoration:underline}

.feature{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(0,1fr);gap:20px}
.lead{position:relative;display:flex;align-items:flex-end;min-height:260px;border-radius:10px;overflow:hidden;background:#17252B;color:#F3F6F6}
.lead img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.lead-t{position:relative;display:block;width:100%;padding:70px 28px 24px;background:linear-gradient(to bottom,transparent,var(--scrim))}
.lead-t .cap{color:#F3F6F6;display:block}
.lead-t .serif{display:block;font-size:clamp(1.5rem,3vw,2.1rem);line-height:1.18;margin-top:6px}

.layout{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:32px;margin-top:28px;margin-bottom:44px;align-items:start}
.layout:not(:has(.rail)){grid-template-columns:minmax(0,1fr)}
.home-grid{margin-top:34px}
.content>h1{font-size:2.1rem;line-height:1.2;margin-bottom:10px}
.topics{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:30px 28px;margin-top:12px}
.topic{border-top:2px solid var(--ink);padding-top:8px}
.topic-h{display:flex;justify-content:space-between;align-items:baseline;gap:10px}
.topic-h h2{font-size:1.45rem}
.topic-h a:hover{text-decoration:underline}

.lk{display:flex;justify-content:space-between;gap:16px;padding:10px 0;font-size:1rem;line-height:1.4;border-top:1px solid var(--line)}
.lk:hover span:first-child{text-decoration:underline}
.lk .m{white-space:nowrap}
.lk.faq{color:var(--accent);font-weight:600}
.list .lk:last-child{border-bottom:1px solid var(--line)}
.more{display:inline-block;margin-top:8px;font-size:.9rem;font-weight:600;color:var(--accent)}
.more:hover{text-decoration:underline}

.card{background:var(--surface);border:1px solid var(--line);border-radius:10px;padding:18px 18px 14px;margin-bottom:18px}
.card>h2.serif{font-size:1.5rem;margin-bottom:6px}
.card>h2.cap{margin-bottom:8px}
.rail .card:first-child{border-top:3px solid var(--accent)}
.pop{counter-reset:p}
.pop li{counter-increment:p;border-top:1px solid var(--line);padding:10px 0 10px 30px;position:relative}
.pop li:first-child{border-top:0}
.pop li::before{content:counter(p);position:absolute;left:0;top:8px;font-family:'Iowan Old Style',Georgia,serif;font-size:1.35rem;color:var(--accent)}
.pop a span:first-child{display:block}
.pop a:hover span:first-child{text-decoration:underline}
.lookup{display:block;border-top:1px solid var(--line);padding:11px 0}
.lookup .serif{display:block;font-size:1.3rem}
.lookup:hover .serif{text-decoration:underline}

.search{display:flex}
.search input{flex:1;min-width:0;height:46px;padding:0 14px;border:1px solid var(--muted);border-right:0;border-radius:6px 0 0 6px;font:inherit;background:var(--surface);color:var(--ink)}
.search button{height:46px;padding:0 18px;border:0;border-radius:0 6px 6px 0;background:var(--accent);color:var(--on-accent);font:inherit;font-weight:600;cursor:pointer}
.search.big{max-width:560px;margin:14px 0}

.crumbs{margin-bottom:14px;font-size:.88rem;color:var(--muted)}
.crumbs ol{display:flex;flex-wrap:wrap;gap:4px}
.crumbs li+li::before{content:"›";margin-right:4px}
.crumbs a{text-decoration:underline}
.meta{color:var(--muted);font-size:.92rem;margin-bottom:18px}
.hero-fig{margin:0 0 22px}
.hero-fig img{width:100%;border-radius:8px}
.hero-fig figcaption{font-size:.8rem;color:var(--muted);margin-top:6px}
.prose{font-size:1.1rem;line-height:1.7;max-width:70ch}
.prose h2{font-family:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,serif;font-weight:400;font-size:1.6rem;margin:1.7em 0 .4em;line-height:1.25}
.prose h3{font-size:1.2rem;margin:1.4em 0 .3em}
.prose p,.prose ul,.prose ol,.prose blockquote{margin:0 0 1em}
.prose ul{list-style:disc;padding-left:1.4em}.prose ol{list-style:decimal;padding-left:1.5em}.prose li{margin:.25em 0}
.prose a{color:var(--accent);text-decoration:underline}
.prose blockquote{border-left:3px solid var(--accent);padding:.2em 0 .2em 1em;color:var(--muted)}
.notice{border:1px solid var(--accent);border-left-width:5px;border-radius:6px;background:var(--surface);padding:14px 16px;margin:14px 0;max-width:70ch}
.notice p+p{margin-top:6px}
.az{display:flex;flex-wrap:wrap;gap:4px;margin:10px 0 20px}
.az a{display:inline-flex;align-items:center;justify-content:center;min-width:36px;min-height:36px;border:1px solid var(--line);border-radius:6px;background:var(--surface);font-weight:600;color:var(--accent)}
dl{margin:0 0 20px}
dt{font-weight:700;margin-top:14px}
dd{margin:2px 0 0;max-width:70ch}
.faqs details{background:var(--surface);border:1px solid var(--line);border-radius:8px;padding:0 16px;margin-bottom:10px}
.faqs summary{cursor:pointer;padding:14px 0;font-weight:600}
.faqs details[open] summary{border-bottom:1px solid var(--line);margin-bottom:10px}
.faqs .prose{font-size:1rem;padding-bottom:6px}

.foot{margin-top:30px;border-top:1px solid var(--line);background:var(--surface)}
.foot .closing{font-family:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,serif;font-size:1.6rem;text-align:center;max-width:820px;margin:0 auto;padding:44px 0 26px;text-wrap:balance}
.flinks{display:flex;flex-wrap:wrap;gap:8px 26px;padding:16px 0 30px;font-size:.9rem;border-top:1px solid var(--line)}
.flinks a:hover{text-decoration:underline}

@media (max-width:900px){.layout{grid-template-columns:minmax(0,1fr)}.feature{grid-template-columns:minmax(0,1fr)}.tools{margin-left:0;border-left:0;padding-left:0}}
@media (prefers-reduced-motion:no-preference){a,button{transition:color .15s,background-color .15s}}
@media print{.crisis,.hdr,.rail,.foot,.skip{display:none}.layout{display:block}body{background:#fff;color:#000}}

/* icons, painted sky and empty-state rows (from the approved mockup) */
.ico{flex:none;display:block;fill:none;stroke:var(--accent);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.topic-h{align-items:center}
.topic-h .ico{margin-right:2px}
.topic-h h2{flex:1}
.sech{display:flex;align-items:center;gap:12px}
.sky{position:absolute;inset:0;width:100%;height:100%;display:block}
.s-bg{fill:url(#none)}
.hero .s-bg{fill:var(--sky1)}
.s-cloud{fill:#fff}:root[data-theme=dark] .s-cloud{fill:#4A5C52}
.s-glow{fill:#F3E6D0}:root[data-theme=dark] .s-glow{fill:#E2B666}
.s-h1{fill:#B6C3C0}.s-h2{fill:#A3B3A5}.s-h3{fill:#7F937F}
:root[data-theme=dark] .s-h1{fill:#2A3B33}:root[data-theme=dark] .s-h2{fill:#1E2C26}:root[data-theme=dark] .s-h3{fill:#141E1A}
@media (prefers-color-scheme:dark){:root:not([data-theme=light]) .s-cloud{fill:#4A5C52}:root:not([data-theme=light]) .s-glow{fill:#E2B666}:root:not([data-theme=light]) .s-h1{fill:#2A3B33}:root:not([data-theme=light]) .s-h2{fill:#1E2C26}:root:not([data-theme=light]) .s-h3{fill:#141E1A}}
.hero{padding:72px 0 120px}
.ph-img{display:flex;align-items:center;justify-content:center;background:var(--p1)}
.ph-img .ico{opacity:.8}
.ph-row{padding:10px 0;border-top:1px solid var(--line);color:var(--muted);font-style:italic}
.card ul>.ph-row:first-child{border-top:0}
.feature.no-lead{grid-template-columns:minmax(0,1fr)}

/* approved article page details */
.logo .amp{color:var(--accent);font-style:italic}
.crumbs{text-transform:uppercase;letter-spacing:.09em;font-size:.76rem;font-weight:700}
.crumbs a{text-decoration:none}.crumbs a:hover{text-decoration:underline}
.crumbs li+li::before{content:"/";margin:0 6px 0 2px}
.prose{font-family:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,serif;font-size:1.12rem;line-height:1.75}
.prose a{color:var(--accent)}
.body-fig{margin:1.4em 0}
.body-fig img{width:100%;border-radius:8px}
.body-fig figcaption{font-family:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,serif;font-size:.8rem;color:var(--muted);margin-top:6px}
.foot{margin-top:30px;border-top:0;background:var(--surface)}
.closing-band{background:var(--t1);border-top:1px solid var(--line)}
.foot .closing{padding:40px 24px;margin:0 auto}
.shelf{border-top:1px solid var(--line);border-bottom:1px solid var(--line)}
.shelf .wrap{display:flex;flex-wrap:wrap;align-items:center;gap:8px 28px;padding-top:18px;padding-bottom:18px}
.shelf-i{font-size:1.1rem}
.shelf-shop{margin-left:auto;margin-top:0}
.flinks{border-top:0}
.layout:has(.rail) .prose{max-width:none}

/* photo hero: keep the headline readable over the sky and keep the bench in view */
.hero.has-img{min-height:400px;padding-bottom:0;background:var(--sky1)}
.hero.has-img .hero-img{object-position:50% 62%;opacity:1}
.hero.has-img::after{content:"";position:absolute;inset:0;pointer-events:none;z-index:0;background:linear-gradient(to bottom,color-mix(in srgb,var(--bg) 92%,transparent) 0%,color-mix(in srgb,var(--bg) 78%,transparent) 32%,color-mix(in srgb,var(--bg) 0%,transparent) 60%,color-mix(in srgb,var(--bg) 70%,transparent) 100%)}
.hero.has-img .wrap{z-index:1}

.hero-fig img{aspect-ratio:16/9;object-fit:cover}

/* back to top (plain link, works without JavaScript) */
.totop-wrap{display:flex;justify-content:center;padding-top:8px;padding-bottom:30px}
.totop{display:inline-flex;align-items:center;gap:8px;min-height:44px;padding:0 20px;border:1px solid var(--accent);border-radius:999px;background:var(--surface);color:var(--accent);font-weight:600;font-size:.95rem}
.totop:hover{background:var(--accent);color:var(--on-accent)}
@media (prefers-reduced-motion:no-preference){html{scroll-behavior:smooth}}
@media print{.totop-wrap{display:none}}

/* glossary: the A to Z row stays in view while scrolling */
.az{position:sticky;top:0;z-index:5;margin:0 0 20px;padding:10px 0;background:var(--bg);border-bottom:1px solid var(--line)}
.content [id^="letter-"],.content dl>div[id]{scroll-margin-top:112px}
@media (max-width:700px){.az{flex-wrap:nowrap;overflow-x:auto;-webkit-overflow-scrolling:touch}.az a{flex:none}}

/* glossary entries: links must look like links, and paragraphs need breathing room */
dd a{color:var(--accent);text-decoration:underline}
dd p{margin:0 0 .7em}
dd p:last-child{margin-bottom:0}
.seasonal[hidden]{display:none}
.seasonal{margin-top:20px}
.seasonal .lead{min-height:220px}
/* FAQ page top note: small, upright and easy to read */
.faq-note{font-family:'Avenir Next',Avenir,system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;font-size:.9rem;line-height:1.6;color:var(--muted);max-width:68ch;margin:6px 0 20px}
.faq-note p{margin:0}
.faq-note em{font-style:normal}
/* author credit at the end of an article: small and quiet */
.byline{font-size:.875rem;color:var(--muted);margin:32px 0 0;padding-top:12px;border-top:1px solid var(--line);max-width:68ch}
