/* IN-ChildPain — stylesheet.
   Identity: deep ink-teal from the project logo + a warm "sun" accent (the sun rising behind the child in the logo),
   on warm paper; serif headings for an academic voice, Manrope for text. A sibling of the StEPP-UPP site, not a copy.
   The only script is a tiny self-hosted one that assembles e-mail addresses. */

:root {
  --ink: #0f3447;          /* logo ink-teal: headings, buttons, footer */
  --ink-deep: #0a2533;
  --accent: #b8431f;       /* burnt orange: the "sun" */
  --accent-dark: #983515;
  --accent-soft: #f8e6da;
  --text: #1c2b36;
  --muted: #52646f;
  --paper: #ffffff;
  --warm: #fbf7f0;         /* warm paper for hero and alternate sections */
  --mist: #eef3f4;
  --line: #e3dccf;
  --line-cool: #d6e0e3;
  --radius: 8px;
  --font-head: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  --font-body: "Manrope", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--text); font-family: var(--font-body); font-size: 1.0625rem; line-height: 1.7; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: var(--accent); }
a:hover { color: var(--accent-dark); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.18; text-wrap: balance; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: clamp(2.1rem, 4.4vw, 3.4rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.05rem); }
h3 { font-size: 1.22rem; font-weight: 700; }
p { margin: 0 0 1.05em; }
ul, ol { padding-left: 1.3em; }
.wrap { width: min(1120px, 100% - 48px); margin-inline: auto; }
.reading { max-width: 72ch; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: #fff; padding: .6em 1em; border-radius: 6px; z-index: 100; font-weight: 700; }
.skip:focus { left: 8px; }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.97); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); }
.brand img { width: 52px; height: 52px; }
.brand span { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; letter-spacing: .005em; line-height: 1.1; }
.brand small { display: block; font-family: var(--font-body); font-weight: 600; font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }
.nav { display: flex; gap: 4px; align-items: center; }
.nav a { text-decoration: none; color: var(--ink); font-weight: 600; font-size: .97rem; padding: .5em .35em; margin-left: 1.15rem; border-bottom: 2px solid transparent; }
.nav a:hover { border-bottom-color: var(--line-cool); color: var(--ink); }
.nav a[aria-current="page"] { border-bottom-color: var(--accent); }
.nav-toggle { position: absolute; opacity: 0; pointer-events: none; }
.burger { display: none; cursor: pointer; padding: 10px; border-radius: 6px; }
.burger span, .burger span::before, .burger span::after { display: block; width: 24px; height: 2px; background: var(--ink); position: relative; content: ""; border-radius: 2px; }
.burger span::before { position: absolute; top: -7px; }
.burger span::after { position: absolute; top: 7px; }

/* ---------- hero (home) ---------- */
.hero { background: var(--warm); border-bottom: 1px solid var(--line); padding: clamp(44px, 7vw, 96px) 0; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.eyebrow { font-family: var(--font-body); font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--accent-dark); margin: 0 0 1.1rem; }
.eyebrow::before { content: ""; display: inline-block; width: 26px; height: 2px; background: var(--accent); vertical-align: middle; margin-right: .75em; }
.hero h1 { max-width: 20ch; margin-bottom: .5em; }
.hero .lead { font-size: 1.2rem; max-width: 50ch; color: var(--text); }
.hero-art { justify-self: end; width: 100%; max-width: 560px; }
.net { width: 100%; height: auto; display: block; }
.net line { stroke: var(--ink); stroke-opacity: .2; stroke-width: 1.3; }
.net .n { fill: var(--ink); }
.net .hot { fill: var(--accent); }
.net .ring { fill: none; stroke: var(--accent); stroke-opacity: .5; stroke-width: 1.3; }
.net .ray { stroke: var(--accent); stroke-opacity: .55; stroke-width: 1.6; stroke-linecap: round; }
.net .glow { fill: var(--accent-soft); }

.page-hero { background: var(--warm); border-bottom: 1px solid var(--line); padding: 44px 0 38px; }
.page-hero h1 { margin: 0; max-width: 24ch; }
.page-hero .eyebrow { margin-bottom: .7rem; }

.actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 1.9rem; }
.btn { display: inline-flex; align-items: center; gap: .55em; font-family: var(--font-body); font-weight: 700; font-size: .96rem; text-decoration: none; padding: .85em 1.45em; border-radius: 6px; border: 2px solid transparent; transition: background .15s ease, color .15s ease, border-color .15s ease; }
.btn-gold { background: var(--accent); color: #fff; }
.btn-gold:hover { background: var(--accent-dark); color: #fff; }
.btn-line { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-line:hover { background: var(--ink); color: #fff; }
.btn-ghost { border-color: rgba(255,255,255,.7); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn .arrow::after { content: "→"; }

/* ---------- sections ---------- */
section.block { padding: clamp(46px, 6.5vw, 84px) 0; }
section.block.tint { background: var(--warm); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 62ch; margin-bottom: 2rem; }
.section-head p { color: var(--muted); font-size: 1.1rem; }

.facts { display: grid; grid-template-columns: repeat(3, 1fr); background: var(--paper); border-bottom: 1px solid var(--line); }
.fact { padding: 30px 32px; border-right: 1px solid var(--line); }
.fact:last-child { border-right: 0; }
.fact strong { display: block; font-family: var(--font-head); font-size: clamp(2.2rem, 4vw, 3rem); line-height: 1; color: var(--ink); margin-bottom: .45rem; }
.fact span { color: var(--muted); font-weight: 500; font-size: .98rem; display: block; max-width: 30ch; }
.facts-wrap { background: var(--paper); }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card { background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--ink); border-radius: var(--radius); padding: 28px; }
.card .num { font-family: var(--font-head); font-weight: 700; color: var(--accent); font-size: 1.5rem; margin-bottom: .5rem; display: block; line-height: 1; }
.card h3 { margin-bottom: .5em; }
.card p { margin: 0; }

.split { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.avatars { display: flex; flex-wrap: wrap; gap: 8px; margin: 1.4rem 0 1.6rem; list-style: none; padding: 0; }
.avatars .avatar { width: 60px; height: 60px; box-shadow: 0 0 0 3px var(--paper), 0 0 0 4px var(--line); }

.callout { background: var(--ink); color: #fff; border-radius: var(--radius); padding: clamp(28px, 4vw, 44px); display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; border-left: 6px solid var(--accent); }
.callout h2, .callout h3 { color: #fff; margin-bottom: .35em; }
.callout p { margin: 0; color: rgba(255,255,255,.9); max-width: 60ch; }

.funding { display: grid; grid-template-columns: auto 1fr; gap: clamp(20px, 4vw, 48px); align-items: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px); }
.funding img { width: min(300px, 70vw); }
.funding-stack { grid-template-columns: 1fr; text-align: center; justify-items: center; }
.after-card { margin-top: 1.6rem; }
.funding p { margin: 0 0 1em; }
.funding p:last-child { margin: 0; }
.pill { display: inline-block; font-family: var(--font-body); font-size: .7rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; padding: .22em .75em; border-radius: 999px; vertical-align: middle; border: 1px solid var(--muted); color: var(--muted); background: #f3f1ec; margin-left: .6em; }
.call { border: 1px solid var(--line); border-left: 5px solid var(--muted); border-radius: var(--radius); padding: 22px 26px; margin-top: 1.4rem; background: var(--warm); }
.call h3 { margin: 0 0 .35em; font-size: 1.15rem; }
.call p { margin: 0 0 .5em; }
.call p:last-child { margin: 0; }

/* ---------- people ---------- */
.avatar { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; object-position: center 22%; background: var(--mist); flex: none; }
.avatar-initials { display: inline-grid; place-items: center; background: var(--ink); color: #fff; font-family: var(--font-head); font-weight: 700; font-size: 1.7rem; letter-spacing: .03em; }
.members { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 22px; list-style: none; padding: 0; margin: 0; }
.member { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .15s ease, box-shadow .15s ease; }
.member:hover { border-color: var(--accent); box-shadow: 0 6px 22px rgba(15,52,71,.10); }
.member a { display: block; padding: 26px 24px; text-decoration: none; color: inherit; height: 100%; }
.member .avatar { margin-bottom: 1rem; box-shadow: 0 0 0 3px var(--paper), 0 0 0 5px var(--accent-soft); }
.member h3 { margin: 0 0 .15em; }
.role { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--accent-dark); background: var(--accent-soft); padding: .15em .7em; border-radius: 4px; margin-bottom: .6rem; }
.member p { margin: 0; color: var(--muted); font-size: .95rem; line-height: 1.55; }
.member .more { margin-top: .9rem; color: var(--ink); font-weight: 800; font-size: .9rem; }
.member .more::after { content: " →"; color: var(--accent); }

.profile { display: grid; grid-template-columns: 240px 1fr; gap: clamp(28px, 5vw, 64px); align-items: start; }
.profile-photo { position: sticky; top: 108px; }
.profile-photo .avatar { width: 220px; height: 220px; box-shadow: 0 0 0 5px var(--paper), 0 0 0 7px var(--accent-soft); }
.profile-photo .avatar-initials { font-size: 3.4rem; }
.profile h2 { font-size: 1.35rem; margin-top: 2rem; padding-top: 1.2rem; border-top: 1px solid var(--line); }
.profile h2:first-child { margin-top: 0; border-top: 0; padding-top: 0; }
.pubs { padding-left: 1.4em; }
.pubs li { margin-bottom: .95em; padding-left: .3em; font-size: .98rem; line-height: 1.6; }
.pubs li::marker { color: var(--accent); font-weight: 700; }
.back { display: inline-block; margin-bottom: 1.5rem; font-weight: 700; text-decoration: none; }
.back::before { content: "← "; color: var(--accent); }

/* ---------- prose ---------- */
.prose h2 { margin-top: 2.2rem; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { max-width: 72ch; }
.prose strong { color: var(--ink); }
.contact-card { background: var(--warm); border: 1px solid var(--line); border-left: 5px solid var(--accent); border-radius: var(--radius); padding: 26px 30px; max-width: 520px; }
.contact-card p { margin: 0 0 .3em; }
.legal h2 { font-size: 1.3rem; margin-top: 2.2rem; }
.legal h3 { font-size: 1.05rem; margin-top: 1.4rem; }
.legal address { font-style: normal; margin: 0 0 1.2em; }

/* draft markers: visible in drafts; a release build refuses to finish while any remain */
.todo { background: #fff2b8; color: #5a4300; padding: .1em .45em; border-radius: 4px; border: 1px dashed #c79a00; font-weight: 600; }

/* ---------- footer ---------- */
.site-footer { background: var(--ink-deep); color: rgba(255,255,255,.86); padding: 56px 0 30px; }
.site-footer a { color: #fff; text-decoration-color: rgba(255,255,255,.35); }
.site-footer a:hover { color: #ffd9c4; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.foot-brand { display: flex; align-items: center; gap: 14px; margin-bottom: 1rem; }
.foot-brand img { width: 52px; height: 52px; background: #fff; border-radius: 6px; padding: 3px; }
.foot-brand strong { font-family: var(--font-head); color: #fff; font-size: 1.2rem; }
.site-footer h2 { font-family: var(--font-body); font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; color: #ffb48f; margin-bottom: .9rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .45rem; }
.site-footer p { font-size: .95rem; }
.fine { border-top: 1px solid rgba(255,255,255,.16); margin-top: 36px; padding-top: 20px; font-size: .88rem; color: rgba(255,255,255,.72); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }

/* e-mail addresses are assembled by /assets/js/mail.js; without JavaScript the CSS below still shows them */
.obf-mail::before { content: attr(data-u) "@" attr(data-d); }
.obf-mail.is-link::before { content: none; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero-grid, .split, .callout, .funding, .profile { grid-template-columns: 1fr; }
  .hero-art { justify-self: center; max-width: 420px; }
  .cards { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .fact { border-right: 0; border-bottom: 1px solid var(--line); padding: 22px 24px; }
  .fact:last-child { border-bottom: 0; }
  .profile-photo { position: static; }
  .foot-grid { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 860px) {
  .burger { display: block; }
  .nav { position: absolute; left: 0; right: 0; top: 100%; background: #fff; flex-direction: column; align-items: stretch; padding: 8px 24px 20px; border-bottom: 1px solid var(--line); box-shadow: 0 16px 30px rgba(15,52,71,.10); display: none; gap: 0; }
  .nav a { margin: 0; padding: .85em .2em; border-bottom: 1px solid var(--line); }
  .nav a[aria-current="page"] { border-bottom-color: var(--accent); }
  .nav-toggle:checked ~ .nav { display: flex; }
  .nav-toggle:focus-visible ~ .burger { outline: 3px solid var(--accent); }
  .brand small { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
@media print {
  .site-header, .actions, .site-footer, .callout, .hero-art { display: none; }
  .hero, .page-hero { background: none; padding: 0; border: 0; }
  body { font-size: 11pt; } a { color: #000; }
}
