/* Shared spacing and reading patterns, built around the approved department pages. */
:root { --maxw: 1280px; --gutter: 32px; --fs-h1: 42px; --fs-h2: 28px; --fs-h3: 21px; --fs-card-title: 21px; --band: 32px; }
main h1 { overflow-wrap: anywhere; }
.section { padding-block: 28px 16px; }
.section-head { padding-block: 28px 24px; }
.section-head h1 { max-width: 28ch; margin-bottom: 12px; }
.section-head .lede { font-size: 19px; line-height: 1.5; }
.breadcrumb { padding-block: 12px; }
.cardsection { padding-block: 28px; }
.cardsection__title { margin-bottom: 20px; }
.cardgrid { background: transparent; border: 0; gap: 20px; }
.cardgrid > .linkcard { border: 1px solid var(--border); padding: 20px; min-width: 0; }
.linkcard__title { font-size: 21px; line-height: 1.3; }
.linkcard__desc { line-height: 1.45; }
.prose { max-width: 74ch; font-size: 17px; line-height: 1.6; overflow-wrap: anywhere; }
.prose > p { max-width: 74ch; margin-block: 0 16px; }
.prose > * + * { margin-top: 16px; }
.prose h2 { font-size: 26px; line-height: 1.25; font-weight: 600; margin: 30px 0 14px; padding-bottom: 9px; border-bottom: 1px solid var(--border); }
.prose h3 { font-size: 21px; line-height: 1.3; margin: 24px 0 12px; }
.prose h2 + *, .prose h3 + * { margin-top: 12px; }
.prose li + li { margin-top: 7px; }
.prose ul, .prose ol { margin-bottom: 20px; }
.prose table { font-size: 16px; line-height: 1.5; }
.prose th, .prose td { padding: 8px 10px; }
.prose thead th { text-transform: none; letter-spacing: 0; font-size: 15px; }
.prose figure.wp-block-table { margin-block: 18px 22px; }
.prose .wp-block-button__link { border-radius: 2px; }
.page-updated { margin-top: 24px; }
.railhelp { margin-top: 24px; padding: 18px; background: var(--tint); border: 1px solid var(--border); }
.rail__block { margin-bottom: 24px; }
.rail__block--tint { background: var(--tint); border: 1px solid var(--border); }
.rail__label { font-size: 14px; letter-spacing: 0; text-transform: none; border-bottom: 1px solid var(--border); padding-bottom: 10px; }
.helppanel { margin-block: 24px; padding: 22px 24px; background: var(--tint); border: 1px solid var(--border); }
.helppanel__title { font-size: 21px; line-height: 1.3; }
.helppanel__body { font-size: 16px; }

/* Native information first; photo and help form a useful supporting column. */
.reading-page { padding-top: 28px; padding-bottom: 32px; }
.reading-page__head { border-bottom: 1px solid var(--border); padding-bottom: 24px; margin-bottom: 24px; }
.reading-page__head h1 { max-width: 28ch; margin: 0 0 12px; font-size: clamp(30px, 3.3vw, 42px); line-height: 1.12; }
.reading-page__head .lede { max-width: 65ch; margin: 0; font-size: 19px; line-height: 1.5; }
.reading-page__layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; grid-template-rows: auto 1fr; gap: 24px 36px; align-items: start; }
.reading-page__main { grid-column: 1; grid-row: 1 / 3; min-width: 0; }
.reading-page__main .prose { max-width: none; }
.reading-page__main .prose > :is(ul,ol,blockquote) { max-width: 74ch; }
.reading-page__contents { grid-column: 2; grid-row: 1; min-width: 0; }
.reading-page__aside { grid-column: 2; grid-row: 1; min-width: 0; }
.reading-page__layout--contents .reading-page__aside { grid-row: 2; }
.reading-page__layout--solo { grid-template-columns: minmax(0, 1fr); }
.reading-page__layout--solo .reading-page__main { max-width: 82ch; }
.reading-page__contents .contents__list a { font-size: 15px; min-height: 44px; padding: 10px 0; }
.reading-page__contents .contents__list a::before { display: none; }
.reading-page__photo .mfai-photo__image, .reading-page__photo .mfai-photo-placeholder { width: 100%; height: auto; aspect-ratio: 4 / 3 !important; max-height: 230px; object-fit: cover; }
.reading-page__photo .mfai-photo__caption { font-size: 13px; }
.reading-page__aside .railhelp:first-child { margin-top: 0; }

/* Editorial and individual profile layouts. */
.story { grid-template-columns: minmax(0, 1fr) 280px; gap: 36px; padding-block: 28px 24px; }
.story__main { max-width: none; min-width: 0; }
.story__main h1 { max-width: 26ch; font-size: clamp(30px, 3.3vw, 42px); line-height: 1.15; }
.story__main .lede { max-width: 65ch; font-size: 19px; }
.story__rail { padding-left: 24px; }
.story__image.mfai-photo { margin: 20px 0 24px; }
.story__image :is(.mfai-photo__image,.mfai-photo-placeholder) { aspect-ratio: 16 / 9 !important; max-height: 300px; object-fit: cover; }
.storynav { gap: 24px; padding-top: 20px; margin-top: 28px; }
.storynav a { font-size: 18px; }
.profile { grid-template-columns: minmax(0, 1fr) 280px; gap: 36px; }
.profile__main { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; max-width: none; align-items: start; }
.profile__main:not(:has(.profile__portrait)) { grid-template-columns: 1fr; }
.profile__portrait.mfai-photo { max-width: 200px; margin: 0; }
.profile__portrait :is(.mfai-photo__image,.mfai-photo-placeholder) { height: 250px; aspect-ratio: 4 / 5 !important; object-fit: cover; }
.profile__rail { padding-left: 24px; }
.single-mfai_person .cardgrid { grid-template-columns: repeat(4,minmax(0,1fr)); }
.single-mfai_person .cardgrid .linkcard__title { font-size: 18px; }
.single-mfai_person .cardgrid .linkcard__desc { font-size: 15px; }
.mission-profile .missiondetail { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 32px; }
.mission-profile .missiondetail--contact-only { grid-template-columns: minmax(0,1fr); max-width: 760px; }
.mission-news__head { border-bottom: 1px solid var(--border); }
.mission-news__title { border-bottom: 0; padding-bottom: 0; margin-bottom: 0; }
.mission-profile .missiondetail__contact { padding: 24px; border: 1px solid var(--border); background: var(--tint); }
.mission-profile .missiondetail__main { min-width: 0; }
.mission-profile .missiondetail__photo { margin-bottom: 24px; }
.missiondetail__photo :is(.mfai-photo__image,.mfai-photo-placeholder) { aspect-ratio: 16 / 9 !important; max-height: 280px; object-fit: cover; }
.mission-profile .missiondetail__contact p { font-size: 17px; line-height: 1.55; margin-bottom: 14px; }

/* Team hierarchy stays intact; its introductory photograph becomes secondary. */
.people-intro { display: grid; grid-template-columns: minmax(0,1fr) 320px; gap: 32px; align-items: start; padding-block: 24px; }
.people-intro--without-photo { grid-template-columns: minmax(0,1fr); }
.people-intro .prose > :last-child { margin-bottom: 0; }
.people-intro__photo :is(.mfai-photo__image,.mfai-photo-placeholder) { aspect-ratio: 16 / 9 !important; max-height: 200px; object-fit: cover; }
.orgchart { margin-top: 8px; padding-top: 24px; }
.orgchart__head { margin-bottom: 20px; }
.orgchart__tier + .orgchart__tier { padding-top: 24px; }

/* The footer retains its native menu and contact connections. */
.site-footer { margin-top: 32px; padding-block: 32px 24px; }
.site-footer__grid { gap: 28px; grid-template-columns: 1.6fr 1fr 1fr 1.1fr; }
.site-footer__logo { height: 64px; margin-bottom: 14px; }
.site-footer__legal { margin-top: 28px; padding-top: 18px; }
.site-footer__about { flex-direction: row; flex-wrap: wrap; gap: 8px 16px; margin-top: 16px; }
.site-footer__links { gap: 7px; }
.site-footer__col-label { text-transform: none; font-size: 15px; letter-spacing: 0; margin-bottom: 12px; }
.site-footer__legal-links { gap: 12px 20px; }

@media (max-width: 1000px) {
  :root { --gutter: 24px; }
  .profile__main { grid-template-columns: 150px minmax(0,1fr); gap: 20px; }
  .profile__portrait :is(.mfai-photo__image,.mfai-photo-placeholder) { height: 190px; }
  .single-mfai_person .cardgrid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 800px) {
  :root { --gutter: 20px; }
  .masthead__tools { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 12px; width: 100%; }
  .masthead__tools .searchbox { width: auto; min-width: 0; }
  .masthead__tools > .btn { padding-inline: 12px; font-size: 12px; white-space: nowrap; }
  .masthead__links { grid-column: 1 / -1; }
  .reading-page__layout { display: flex; flex-direction: column; gap: 24px; }
  .reading-page__main, .reading-page__contents, .reading-page__aside { width: 100%; }
  .reading-page__contents .contents__list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0 20px; }
  .reading-page__photo { max-width: 420px; }
  .reading-page__aside .railhelp { max-width: 420px; }
  .story, .profile { grid-template-columns: minmax(0,1fr); gap: 24px; }
  .story__rail, .profile__rail { border-left: 0; border-top: 1px solid var(--border); padding: 24px 0 0; }
  .story__rail { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; }
  .mission-profile .missiondetail { grid-template-columns: minmax(0,1fr); gap: 24px; }
  .mission-profile .missiondetail__contact { padding: 20px; }
  .people-intro { grid-template-columns: minmax(0,1fr); gap: 20px; }
  .people-intro__photo { max-width: 420px; }
  .site-footer__grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px; }
  .site-footer__grid > :first-child, .site-footer__grid > :last-child { grid-column: 1 / -1; }
  .site-footer__grid > :first-child { display: grid; grid-template-columns: 64px minmax(0,1fr); gap: 0 16px; }
  .site-footer__logo { grid-column: 1; grid-row: 1 / 3; width: 64px; height: auto; margin: 0; }
  .site-footer__name, .site-footer__motto { grid-column: 2; }
  .site-footer__about { grid-column: 1 / -1; }
  .site-footer__legal { gap: 14px; }
}
@media (max-width: 480px) {
  .section-head h1 { font-size: 32px; }
  .section-head .lede, .reading-page__head .lede { font-size: 18px; }
  .prose h2 { font-size: 24px; }
  .prose table { font-size: 15px; }
  /* Keep simple label/value tables readable without hiding values off-screen. */
  .reading-page .wp-block-table table:has(> thead > tr > :nth-child(2):last-child) { min-width: 0; }
  .reading-page .wp-block-table table:has(> thead > tr > :nth-child(2):last-child) :is(th,td):first-child { min-width: 112px; }
  .reading-page .wp-block-table table:has(> thead > tr > :nth-child(2):last-child) :is(th,td):last-child { min-width: 86px; }
  .reading-page__contents .contents__list { grid-template-columns: 1fr; }
  .story__rail { grid-template-columns: minmax(0,1fr); }
  .profile__main { display: block; }
  .profile__portrait.mfai-photo { float: left; width: 112px; margin: 0 18px 12px 0; }
  .profile__portrait :is(.mfai-photo__image,.mfai-photo-placeholder) { height: 140px; }
  .profile__main::after { content: ''; display: table; clear: both; }
  .profile__main .prose { overflow-wrap: anywhere; }
  .helppanel { padding: 20px; }
  .single-mfai_person .cardgrid { grid-template-columns: minmax(0,1fr); }
}
