/* nsrf-content-pack.css
 * Layout for the pages built by the 31 Aug 2026 content import
 * (project pages, cluster cards, board bios, find-help cards, hub pages)
 * plus the Our Team portrait fix.
 *
 * Moved out of Customizer -> Additional CSS on 1 Sep 2026 so it lives with
 * the rest of the NSRF front-end code and is version-controlled by filemtime.
 * Enqueued by mu-plugins/nsrf-content-pack-styles.php at a late priority so it
 * still lands after Divi's cached customizer stylesheet, as it did before.
 */

/* ============ NSRF content pack + team photo fixes (31 Aug 2026, v2) ============ */

/* --- Our Team: larger, undistorted portrait circles --- */
.page-id-45 .et_pb_blurb .et_pb_blurb_content .et_pb_main_blurb_image .et_pb_image_wrap{width:clamp(170px,72%,210px)!important;aspect-ratio:1/1!important;height:auto!important;border-radius:50%;overflow:hidden;margin:0 auto}
.page-id-45 .et_pb_blurb .et_pb_blurb_content .et_pb_main_blurb_image .et_pb_image_wrap img{width:100%!important;height:100%!important;object-fit:cover;object-position:50% 22%;display:block}

/* --- Full-bleed default-template pages: give the content a real container --- */
#main-content > article > .entry-content:has(.nsrf-cp){max-width:1280px;margin-inline:auto;padding:0 clamp(20px,5vw,80px) 64px;box-sizing:border-box}
#main-content > article > .entry-content:has(.nsrf-cp) > .nsrf-title-fallback{margin-bottom:.4em}
article:has(> h1.entry-title) .entry-content .nsrf-title-fallback{display:none!important}

/* --- Content pack pages --- */
.nsrf-cp{max-width:860px;margin-inline:auto;padding-inline:clamp(16px,3vw,32px)}
#main-content > article > .entry-content .nsrf-cp{margin-inline:0;padding-inline:0}
.nsrf-cp-clusters,.nsrf-cp-researchhub,.nsrf-cp-board,.nsrf-cp-findinghelp,.nsrf-cp-currentprojects{max-width:none}
.nsrf-cp h2{margin-top:1.6em}
.nsrf-cp-lede{font-size:1.12rem;line-height:1.6;max-width:68ch;margin:0 0 1.2em}
.nsrf-cp-eyebrow{font-size:.82rem;letter-spacing:.06em;text-transform:uppercase;font-weight:600;margin-bottom:.4em}
.nsrf-cp-eyebrow a{text-decoration:none}

/* link lists */
.nsrf-cp-projectlist{list-style:none;padding:0;margin:1.2em 0;display:grid;gap:10px}
.nsrf-cp-projectlist--row{grid-template-columns:repeat(auto-fill,minmax(min(100%,220px),1fr))}
.nsrf-cp-projectlist li{list-style:none;border:1px solid rgba(7,16,80,.14);border-radius:8px;background:#fff}
.nsrf-cp-projectlist li::marker,.nsrf-cp-clustergrid li::marker{content:none}
.nsrf-cp-projectlist li a{display:block;padding:14px 18px;text-decoration:none;font-weight:600;color:#1B2D5B;transition:background .15s,border-color .15s}
.nsrf-cp-projectlist li a:hover,.nsrf-cp-projectlist li a:focus-visible{background:rgba(7,16,80,.06)}

/* cluster cards */
.nsrf-cp-clustergrid{list-style:none;padding:0;margin:1.6em 0 2.4em;display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,300px),1fr));gap:22px}
.nsrf-cp-clustercard{list-style:none;margin:0;padding:0}
.nsrf-cp-clustercard a{display:flex;flex-direction:column;height:100%;min-height:190px;padding:26px 26px 22px;background:#fff;border:1px solid rgba(7,16,80,.12);border-top:6px solid var(--c,#68083F);border-radius:14px;text-decoration:none;color:#1B2D5B;box-shadow:0 2px 10px rgba(7,16,80,.06);transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease}
.nsrf-cp-clustercard a:hover,.nsrf-cp-clustercard a:focus-visible{transform:translateY(-4px);box-shadow:0 12px 28px rgba(7,16,80,.14);border-color:var(--c,#68083F)}
.nsrf-cp-clustercard__name{display:block;font-weight:700;font-size:1.18rem;line-height:1.3;text-wrap:balance}
.nsrf-cp-clustercard__meta{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-top:auto;padding-top:22px;font-size:.9rem}
.nsrf-cp-clustercard__count{color:#4B5372;font-weight:500}
.nsrf-cp-clustercard__cta{color:var(--c,#68083F);font-weight:700;white-space:nowrap}
@media(prefers-reduced-motion:reduce){.nsrf-cp-clustercard a,.nsrf-cp-projectlist li a{transition:none}.nsrf-cp-clustercard a:hover{transform:none}}

/* board */
.nsrf-cp-bio{display:flex;gap:28px;align-items:flex-start;margin:2.2em 0;padding-top:1.6em;border-top:1px solid rgba(7,16,80,.12);max-width:1000px}
.nsrf-cp-bio__photo{flex:0 0 clamp(170px,24%,220px);margin:0}
.nsrf-cp-bio__photo img{width:100%;height:auto;aspect-ratio:4/5;object-fit:cover;object-position:50% 25%;border-radius:8px;display:block}
.nsrf-cp-bio__photo--none span{display:flex;align-items:center;justify-content:center;width:100%;aspect-ratio:4/5;border-radius:8px;background:#EEEFF3;color:#071050;font-family:Outfit,system-ui,sans-serif;font-weight:700;font-size:clamp(2.2rem,4vw,3.2rem);letter-spacing:.06em;line-height:1}
.nsrf-cp-bio__text h2{margin:0 0 .1em}
.nsrf-cp-bio__role{font-size:.9rem;font-weight:600;opacity:.75;margin:0 0 .8em}
@media(max-width:640px){.nsrf-cp-bio{flex-direction:column}.nsrf-cp-bio__photo{flex-basis:auto;width:min(70%,240px)}}

/* finding help */
.nsrf-cp-helpgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,300px),1fr));gap:18px;margin-top:1.6em}
.nsrf-cp-help{border:1px solid rgba(7,16,80,.14);border-radius:10px;padding:18px 20px;background:#fff}
.nsrf-cp-help__head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:.4em}
.nsrf-cp-help__head h2{margin:0;font-size:1.15rem}
.nsrf-cp-help__logo{max-width:90px;max-height:48px;width:auto;height:auto;flex:none}
.nsrf-cp-help p{margin:.35em 0;font-size:.95rem}

/* faq */
.nsrf-cp-faq h2{font-size:1.2rem;margin-top:1.8em}

/* training hub cards + button */
.nsrf-cp-tgrid{list-style:none;padding:0;margin:1.6em 0;display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,300px),1fr));gap:20px}
.nsrf-cp-tcard{list-style:none;margin:0}
.nsrf-cp-tcard::marker{content:none}
.nsrf-cp-tcard a{display:flex;flex-direction:column;gap:10px;height:100%;padding:24px;background:#fff;border:1px solid rgba(7,16,80,.12);border-left:6px solid #8A5E12;border-radius:12px;text-decoration:none;color:#1B2D5B;box-shadow:0 2px 10px rgba(7,16,80,.06);transition:transform .18s ease,box-shadow .18s ease}
.nsrf-cp-tcard a:hover,.nsrf-cp-tcard a:focus-visible{transform:translateY(-3px);box-shadow:0 12px 28px rgba(7,16,80,.14)}
.nsrf-cp-tcard__name{font-weight:700;font-size:1.1rem;line-height:1.3}
.nsrf-cp-tcard__desc{font-size:.95rem;line-height:1.55;color:#3D4560}
.nsrf-cp-button{display:inline-block;padding:12px 22px;background:#68083F;color:#fff!important;border-radius:6px;font-weight:700;text-decoration:none}
.nsrf-cp-button:hover{background:#3a2366}
.nsrf-cp-hub .nsrf-cp-projectlist li a strong{display:block;font-size:1.05rem}
.nsrf-cp-hub,.nsrf-cp-presskit,.nsrf-cp-traininghub{max-width:960px}

.nsrf-cp-button--ghost{background:transparent;color:#68083F!important;border:2px solid #68083F}
.nsrf-cp-button--ghost:hover{background:rgba(7,16,80,.08)}

/* --- Our Work cluster cards: whole card clickable, one tab stop ---------
   The heading is a real anchor (see nsrf-our-work-cards.php); this stretches
   its hit area over the Divi column without adding a second link. */
.et_pb_column:has(> .et_pb_blurb .nsrf-cluster-cardlink){position:relative}
.nsrf-cluster-cardlink{text-decoration:none;color:inherit}
.nsrf-cluster-cardlink::after{content:"";position:absolute;inset:0;z-index:1}
.et_pb_column:has(> .et_pb_blurb .nsrf-cluster-cardlink):hover{filter:brightness(1.06)}
.nsrf-cluster-cardlink:focus-visible{outline:3px solid currentColor;outline-offset:3px}

/* Anchor targets clear the sticky header (e.g. newsletters #most-recent). */
.nsrf-cp [id]{scroll-margin-top:130px}


/* --- Page title alignment on content-pack builder pages -----------------
   nsrf-frontend.css gives the injected fallback H1 its own content-column
   inset (padding-inline:max(32px, (100% - 1280px)/2)) because on a plain
   builder page .entry-content is full-bleed. Here .entry-content is already
   the 1280px box with the clamp inset above, so that padding stacks on top
   and the title lands ~32px right of the body text. Cancel it. */
body.et_pb_pagebuilder_layout .entry-content:has(.nsrf-cp) > h1.nsrf-title-fallback,
body.et_pb_pagebuilder_layout .entry-content:has(.nsrf-aag) > h1.nsrf-title-fallback{
  padding-inline:0!important;
  max-width:none!important;
}
