/*
Theme Name: Koppa Lab
Description: Bespoke component-based theme for Koppa Lab. Requires Advanced Custom Fields PRO.
Version: 1.17.0
Requires PHP: 8.0
Text Domain: koppa
*/

/* Self-hosted variable fonts, subset to Latin + Latin Extended (OFL, see assets/fonts). */
@font-face { font-family: "Source Sans 3"; src: url(assets/fonts/source-sans-3.woff2) format("woff2"); font-weight: 200 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Source Sans 3"; src: url(assets/fonts/source-sans-3-italic.woff2) format("woff2"); font-weight: 200 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url(assets/fonts/source-serif-4.woff2) format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }

:root {
	--teal: #02b2ae;
	--teal-dark: #00807d;
	--teal-light: #e8f5f6;
	--yellow: #f7c41a;
	--yellow-dark: #e0ad00;
	--ink: #1d2b30;
	--muted: #5c6b70;
	--charcoal: #404146;
	--white: #fff;
	--radius: 6px;
	--shadow: 0 10px 30px rgb(0 0 0 / .08);
	--sans: "Source Sans 3", system-ui, sans-serif;
	--serif: "Source Serif 4", Georgia, serif;
	--header-h: 114px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font: 400 1rem/1.6 var(--sans); color: var(--ink); background: var(--white); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal-dark); }
h1, h2, h3 { margin: 0 0 .5em; line-height: 1.15; font-weight: 300; }
h1 strong, h2 strong, h3 strong { font-weight: 700; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
.container { width: min(1180px, 100% - 32px); margin-inline: auto; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--yellow); color: var(--ink); padding: 8px 16px; }
.skip-link:focus { top: 16px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: .6em; padding: .75em 1.6em; border: 2px solid transparent; border-radius: 999px; background: none; font: 600 .875rem/1 var(--sans); text-decoration: none; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.btn--sm { padding: .6em 1.3em; font-size: .8125rem; }
.btn--block { width: 100%; justify-content: center; }
.btn--yellow { background: var(--yellow); color: var(--ink); }
.btn--yellow:hover { background: var(--yellow-dark); }
.btn--teal { background: var(--teal); color: var(--white); }
.btn--teal:hover { background: var(--teal-dark); }
.btn--outline { border-color: var(--teal); color: var(--teal-dark); }
.btn--outline:hover { background: var(--teal); color: var(--white); }
.btn--outline-light { border-color: var(--white); color: var(--white); }
.btn--outline-light:hover { background: var(--white); color: var(--teal-dark); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn-row--center { justify-content: center; }
.btn-row:empty { display: none; }

/* ---------- Header ----------
   Transparent over a hero, solid white + sticky once scrolled (.is-stuck, set in main.js).
   Pages without a hero get the solid header from the start. */
.site-header { position: sticky; top: var(--wp-admin--admin-bar--height, 0px); z-index: 50; color: var(--white); border-bottom: 1px solid rgb(255 255 255 / .35); transition: background .25s, box-shadow .25s, border-color .25s; }
.has-hero .site-header { position: fixed; left: 0; right: 0; }
body:not(.has-hero) .site-header, .site-header.is-stuck, .nav-open .site-header { background: var(--white); color: var(--ink); border-color: transparent; box-shadow: 0 2px 20px rgb(0 0 0 / .08); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); gap: 24px; transition: min-height .25s; }
/* Logo is an inline SVG using currentColor: white over the hero/footer, teal on the solid header. */
.site-logo { display: block; color: var(--white); text-decoration: none; transition: color .25s; }
.site-logo svg { display: block; height: 46px; width: auto; }
body:not(.has-hero) .site-header .site-logo, .is-stuck .site-logo, .nav-open .site-header .site-logo { color: var(--teal); }
.site-nav { display: flex; align-items: center; gap: 23px; }
.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav > ul { display: flex; gap: 21px; }
.site-nav li { position: relative; }
.site-nav a:not(.btn) { color: inherit; text-decoration: none; font-size: 1.0625rem; }
.site-nav a:not(.btn):hover, .site-nav .current-menu-item > a:not(.btn) { text-decoration: underline; text-underline-offset: 4px; }
/* Thin chevron: white over the hero, teal on the solid header. */
.chevron, .site-nav .menu-item-has-children > a::after { content: ""; display: inline-block; width: 7px; height: 7px; margin: 0 0 3px 9px; border: solid currentColor; border-width: 0 1.6px 1.6px 0; transform: rotate(45deg); vertical-align: middle; }
body:not(.has-hero) .site-nav .menu-item-has-children > a::after, .is-stuck .site-nav .menu-item-has-children > a::after, .nav-open .site-nav .menu-item-has-children > a::after { border-color: var(--teal); }

.lang { position: relative; }
.lang__toggle { display: inline-flex; align-items: center; height: 61px; padding: 0 29px 0 28px; border: 0; border-radius: 999px; background: rgb(255 255 255 / .22); color: var(--white); font: 400 1.0625rem/1 var(--sans); white-space: nowrap; transition: background .25s; }
button.lang__toggle { cursor: pointer; }
.lang__toggle .chevron { margin-left: 8px; }
body:not(.has-hero) .lang__toggle, .is-stuck .lang__toggle, .nav-open .lang__toggle { background: var(--teal); }
.lang__menu { position: absolute; top: calc(100% + 6px); right: 0; min-width: 160px; margin: 0; padding: 8px 0; list-style: none; background: var(--white); color: var(--ink); border-radius: var(--radius); box-shadow: var(--shadow); opacity: 0; visibility: hidden; transition: .15s; }
.lang:hover .lang__menu, .lang:focus-within .lang__menu { opacity: 1; visibility: visible; }
.site-nav .lang__menu a { display: block; padding: 6px 16px; }
/* Google Translate (see main.js): our switcher replaces its top banner, so hide that, its hover tooltips and the offset it adds to <body>. */
body { top: 0 !important; }
body > .skiptranslate, iframe.skiptranslate, #goog-gt-tt, .goog-te-balloon-frame { display: none !important; }
.goog-text-highlight { background: none !important; box-shadow: none !important; }

.site-nav__donate { gap: 41px; height: 62px; padding: 0 22px 0 28px; font-size: 1.05rem; }
.site-nav__donate svg { flex: none; }
.site-nav .sub-menu { position: absolute; top: 100%; left: -16px; min-width: 240px; padding: 12px 0; background: var(--white); color: var(--ink); border-radius: var(--radius); box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s; }
.site-nav li:hover > .sub-menu, .site-nav li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.site-nav .sub-menu a:not(.btn) { display: block; padding: 6px 16px; }
/* Third level (Global Programs → sector → programs) flies out to the right; its parent's chevron points right. */
.site-nav .sub-menu .sub-menu { top: -12px; left: 100%; }
.site-nav .sub-menu .menu-item-has-children > a { position: relative; padding-right: 40px; }
.site-nav .sub-menu .menu-item-has-children > a::after { position: absolute; right: 18px; top: 50%; margin: 0; transform: translateY(-50%) rotate(-45deg); }
.menu-item__desc { display: inline-block; width: 280px; margin-top: 2px; font-size: .8125rem; line-height: 1.4; color: #5b6a72; } /* inline-block so the link's hover underline skips it */
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; color: inherit; }
.submenu-toggle { display: none; } /* mobile only, see the 1140px query */
.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { display: block; width: 24px; height: 2px; background: currentColor; position: relative; transition: .2s; }
.nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; position: absolute; }
.nav-toggle__bars::before { top: -7px; }
.nav-toggle__bars::after { top: 7px; }
.nav-open .nav-toggle__bars { background: transparent; }
.nav-open .nav-toggle__bars::before { top: 0; transform: rotate(45deg); }
.nav-open .nav-toggle__bars::after { top: 0; transform: rotate(-45deg); }

@media (max-width: 1140px) { /* header switches to the menu panel below the width the full nav needs */
	:root { --header-h: 80px; }
	.site-logo svg { height: 40px; }
	.lang { align-self: flex-start; margin-top: 8px; }
	.lang__toggle { height: 48px; }
	.lang__menu { display: none; position: static; opacity: 1; visibility: visible; box-shadow: none; padding: 4px 0 0 16px; }
	.lang__toggle[aria-expanded="true"] + .lang__menu { display: block; }
	.lang__toggle[aria-expanded="true"] .chevron { transform: rotate(-135deg); margin-bottom: -3px; }
	.site-nav__donate { height: 52px; }
	.nav-toggle { display: block; }
	.site-nav { display: none; position: absolute; inset: 100% 0 auto; flex-direction: column; align-items: stretch; max-height: calc(100vh - 100%); overflow-y: auto; padding: 8px 16px 24px; background: var(--white); border-top: 1px solid #e3ecee; }
	.nav-open .site-nav { display: flex; }
	.site-nav > ul { flex-direction: column; gap: 0; }
	.site-nav a:not(.btn) { display: block; padding: 10px 0; font-size: 1rem; }
	/* Sub-menus collapse behind a chevron button (added by main.js) beside the parent link. */
	.site-nav .menu-item-has-children { display: flex; flex-wrap: wrap; align-items: center; }
	.site-nav .menu-item-has-children > a { flex: 1; }
	.site-nav .menu-item-has-children > a::after { display: none; }
	.submenu-toggle { display: grid; place-items: center; width: 44px; height: 44px; margin-right: -12px; padding: 0; border: 0; background: none; color: var(--teal); cursor: pointer; }
	.submenu-toggle .chevron { margin: -4px 0 0; transition: transform .2s; }
	.submenu-toggle[aria-expanded="true"] .chevron { transform: rotate(-135deg); margin-top: 4px; }
	.site-nav .sub-menu { display: none; flex-basis: 100%; position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; min-width: 0; padding: 0 0 8px 16px; }
	.submenu-toggle[aria-expanded="true"] + .sub-menu { display: block; }
	.site-nav .sub-menu a:not(.btn) { padding: 6px 0; }
	.menu-item__desc { display: block; width: auto; }
	.site-nav .btn { align-self: flex-start; margin-top: 8px; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 8vw, 110px) 0; }
.section--teal { background: var(--teal) url(assets/img/pattern-teal.jpg) center / cover; color: var(--white); }
.section__header { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.section__header--split { display: flex; justify-content: space-between; align-items: center; gap: 16px; max-width: none; text-align: left; }
.section__header--split .section__heading { margin: 0; }
.section__heading { font-size: clamp(2.25rem, 4.6vw, 3.6rem); }
.section__heading--serif { font-family: var(--serif); font-size: clamp(1.75rem, 3.5vw, 2.5rem); text-align: center; margin-bottom: 40px; }
.eyebrow { color: var(--teal); font-size: .8125rem; margin-bottom: .5em; }
.lead { font-size: 1.25rem; font-weight: 300; color: var(--muted); }
.tag { display: inline-block; padding: 2px 12px; margin-bottom: 12px; border-radius: 999px; background: var(--teal-light); color: var(--teal-dark); font-size: .6875rem; }

/* Tiles: shared card style; teal is the "featured" variant. */
.tile { padding: 24px; border-radius: var(--radius); background: var(--white); color: var(--ink); box-shadow: var(--shadow); }
.tile__title { font-size: 1rem; font-weight: 400; color: var(--teal-dark); margin-bottom: .6em; }
.tile__text { font-size: .8125rem; color: var(--muted); margin: 0; }
.tile__text p:last-child { margin: 0; }
.tile-grid { display: grid; gap: 20px; }
.tile-grid--3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.tile-grid--2 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

.tile-grid--3 > .tile:nth-child(odd),
.tile-grid--2 > .tile:nth-child(4n+1),
.tile-grid--2 > .tile:nth-child(4n),
.story-grid:not(.story-grid--dark, .story-grid--numbered) .story-grid__col:first-child .tile:first-child,
.story-grid:not(.story-grid--dark, .story-grid--numbered) .story-grid__col:last-child .tile:last-child { background: var(--teal-dark); color: var(--white); }
.tile-grid--3 > .tile:nth-child(odd) :is(.tile__title, .tile__text),
.tile-grid--2 > .tile:nth-child(4n+1) :is(.tile__title, .tile__text),
.tile-grid--2 > .tile:nth-child(4n) :is(.tile__title, .tile__text),
.story-grid:not(.story-grid--dark, .story-grid--numbered) .story-grid__col:first-child .tile:first-child :is(.tile__title, .tile__text),
.story-grid:not(.story-grid--dark, .story-grid--numbered) .story-grid__col:last-child .tile:last-child :is(.tile__title, .tile__text) { color: var(--white); }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: max(680px, 100svh); display: flex; align-items: center; color: var(--white); background: var(--teal); overflow: hidden; }
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, var(--teal) 25%, rgb(2 178 174 / .55) 55%, rgb(2 178 174 / .1)), linear-gradient(0deg, var(--teal) 0, transparent 30%); }
.hero__inner { position: relative; z-index: 2; padding: calc(var(--header-h) + 40px) 0 58px; }
.hero__heading { font-size: clamp(2.5rem, 5.7vw, 5.125rem); line-height: 1.08; margin-bottom: .25em; }
.hero__text { max-width: 560px; font-size: clamp(1rem, 1.32vw, 1.1875rem); line-height: 1.7; margin-bottom: 2.4em; }
.hero .btn-row { gap: 18px; }
.hero .btn { justify-content: center; padding: 1.25em 2.1em; font-size: 1rem; }
.hero .btn:first-child { min-width: 176px; }

/* ---------- Stat intro ----------
   Proportions measured from the design. The graphic is sized in em off one font-size
   so it scales as a unit (16px = desktop design size). */
.stat-intro { padding: clamp(72px, 10vw, 140px) 0 clamp(72px, 10vw, 150px); background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 2000 1260' preserveAspectRatio='none'%3E%3Cpath d='M0 460C350 430 520 105 830 105s420 315 670 335c200 10 350-20 500-55V1260H0z' fill='%2302b2ae' fill-opacity='.07'/%3E%3C/svg%3E") top / 100% 100% no-repeat, linear-gradient(160deg, #f5fafc 0%, #eef7f9 45%, #d5eeee 100%); }
.stat-intro__top { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 40px; align-items: start; margin-bottom: clamp(48px, 8vw, 112px); }
.stat-intro .eyebrow { font-size: clamp(1rem, 1.4vw, 1.175rem); font-weight: 600; margin-bottom: .6em; }
.stat-intro__heading { font-size: clamp(2.75rem, 5.5vw, 4.15rem); font-weight: 700; line-height: 1.05; margin-bottom: .5em; }
.stat-intro .lead { max-width: 500px; margin: 0; font-size: clamp(1.25rem, 2.3vw, 1.975rem); line-height: 1.54; font-weight: 300; color: #5d6a72; }
.stat-intro .lead strong { font-weight: 400; color: #4c5a62; }

.stat-intro__visual { display: flex; align-items: flex-start; gap: 1.3em; margin-top: -3.4em; font-size: clamp(11px, 1.12vw, 16px); }
.stat-circle { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.1em; flex: none; width: 19.7em; aspect-ratio: 1; border-radius: 50%; background: var(--teal); color: var(--white); text-align: center; }
.stat-circle strong { font-size: 3.35em; font-weight: 700; line-height: 1.05; max-width: 5ch; }
.stat-circle span { font-size: 1em; font-weight: 600; padding: .55em .95em; border-radius: .25em; background: var(--teal-dark); }
.stat-chip { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .45em; flex: none; width: 8.95em; height: 5.55em; margin-top: 7.6em; padding: 0 .95em; border-radius: .65em; background: var(--teal-dark); color: var(--white); text-align: center; }
.stat-chip strong { font-size: .975em; font-weight: 700; }
.stat-chip span { align-self: stretch; font-size: .8em; font-weight: 600; padding: .6em .4em; border-radius: .35em; background: var(--teal); }
/* Elbow connector + dot */
.stat-chip::before { content: ""; position: absolute; top: 100%; left: 4.15em; width: 3.75em; height: 5.1em; border: solid #4a5257; border-width: 0 0 1px 1px; }
.stat-chip::after { content: ""; position: absolute; top: 9.85em; left: 7.05em; width: 1.8em; aspect-ratio: 1; border-radius: 50%; background: var(--teal-dark); }

.stat-intro .tile-grid { gap: clamp(16px, 1.8vw, 21px); }
.stat-intro .tile { min-height: 186px; padding: 2.1rem 2.4rem; border-radius: 12px; box-shadow: 0 24px 48px -16px rgb(0 60 70 / .2); }
.stat-intro .tile__title { font-size: clamp(1.25rem, 1.8vw, 1.45rem); margin-bottom: .45em; }
.stat-intro .tile__text { font-size: .95rem; line-height: 1.52; color: #3f474b; }
.stat-intro .tile__text strong { font-weight: 600; }

/* ---------- Story grid ----------
   Proportions measured from the design: three equal columns, the photo matches the card stack height. */
.story-grid { padding: clamp(64px, 7vw, 96px) 0; }
.story-grid .section__header { max-width: 800px; margin-bottom: clamp(40px, 5vw, 72px); }
.story-grid .section__heading { margin-bottom: .45em; }
.story-grid .section__header p { font-size: clamp(1.0625rem, 1.6vw, 1.3rem); line-height: 1.58; margin: 0; }
.story-grid__layout { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 19px; }
.story-grid__col:last-child { grid-column: 3; }
.story-grid__col { display: grid; grid-auto-rows: 1fr; gap: 19px; }
.story-grid .tile { min-height: 210px; padding: 38px 37px; border-radius: 11px; box-shadow: 0 16px 40px -18px rgb(0 50 60 / .35); }
.story-grid .tag { margin-bottom: 14px; padding: .65em 1em; font-size: .95rem; line-height: 1.3; }
.story-grid .tile__title { font-size: clamp(1.0625rem, 1.5vw, 1.2rem); margin-bottom: .55em; }
.story-grid .tile__text { font-size: .95rem; line-height: 1.47; color: #3f474b; }
/* Absolutely positioned in its grid cell so the photo never sizes the row; the cards do. */
.story-grid__image { position: absolute; grid-column: 2 / 3; grid-row: 1 / 2; top: -4px; left: 0; width: 100%; height: calc(100% + 8px); object-fit: cover; border-radius: 11px; }
/* Numbered (Operating Model): white cards with a big serif number; the image is a diagram, so it's shown whole. */
.story-grid--numbered .tile { position: relative; }
.story-grid--numbered .tile__title { padding-right: 3em; font-size: clamp(1.25rem, 1.8vw, 1.5rem); }
.tile__number { position: absolute; top: 26px; right: 32px; font: 400 clamp(2.5rem, 4vw, 3.5rem)/1 var(--serif); color: #a6dedc; }
.story-grid--numbered .story-grid__image { object-fit: contain; border-radius: 0; }
@media (max-width: 900px) {
	/* Columns hold cards 1+3 and 2+4; flatten them so the cards stack 1, 2, 3, 4. */
	.story-grid--numbered .story-grid__layout { display: flex; flex-direction: column; }
	.story-grid--numbered .story-grid__col { display: contents; }
	.story-grid--numbered .story-grid__col:first-child .tile:nth-child(2) { order: 3; }
	.story-grid--numbered .story-grid__col:last-child .tile:nth-child(1) { order: 2; }
	.story-grid--numbered .story-grid__col:last-child .tile:nth-child(2) { order: 4; }
	.story-grid--numbered .story-grid__col:first-child .tile:nth-child(1) { order: 1; }
	.story-grid--numbered .story-grid__image { max-width: 420px; align-self: center; aspect-ratio: 1; }
}

/* ---------- Quotes ---------- */
/* Proportions measured from the design. */
.quotes { padding: clamp(72px, 9vw, 132px) 0 clamp(80px, 11vw, 160px); background: #e6f5f9 url(assets/img/gradient-light.jpg) center / cover; text-align: center; } /* .quotes--image swaps this for the chosen photo */
.quotes__icon { width: 64px; height: 64px; margin: 0 auto 28px; background: url(assets/img/quote.png) center / contain no-repeat; }
.quote blockquote { margin: 0 auto 24px; max-width: 980px; font: 400 clamp(1.375rem, 2.6vw, 2.25rem)/1.43 var(--serif); color: #2b2b2b; }
.quote figcaption { font-size: clamp(1rem, 1.4vw, 1.23rem); font-weight: 700; color: #2b2b2b; }
.quotes .btn-row { margin-top: clamp(40px, 5vw, 72px); }
.quotes .btn { gap: 1.35em; padding: 1.25em 1.9em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); }

/* ---------- Slider (scroll-snap) ---------- */
.slider { position: relative; display: flex; align-items: center; gap: 16px; }
.slider__track { flex: 1; display: grid; grid-auto-flow: column; grid-auto-columns: 100%; gap: 24px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.slider__track::-webkit-scrollbar { display: none; }
.slider__slide { scroll-snap-align: start; margin: 0; }
.slider__arrow { flex: none; display: grid; place-items: center; width: 58px; height: 58px; padding: 0; border: 1px solid #e6eef1; border-radius: 50%; background: var(--white); color: var(--ink); box-shadow: 0 4px 14px rgb(0 40 50 / .06); cursor: pointer; transition: background .2s, border-color .2s; }
.slider__arrow:hover { background: var(--yellow); border-color: var(--yellow); }

/* ---------- Feature grid ----------
   Proportions measured from the design. */
.feature-grid { padding: clamp(64px, 8vw, 118px) 0; background: var(--teal-dark) url(assets/img/pattern-teal-dark.jpg) center / cover; }
.feature-grid__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 583px); gap: 48px; align-items: center; }
.feature-grid .section__heading { line-height: 1.24; margin-bottom: 30px; }
.feature-grid__layout > div:first-child p { max-width: 480px; margin: 0; font-size: clamp(1.0625rem, 1.4vw, 1.18rem); line-height: 1.59; }
.feature-grid .btn-row { margin-top: 40px; }
.feature-grid .btn { gap: 1.25em; padding: 1.2em 2.9em; font-size: clamp(.9375rem, 1.2vw, 1.0625rem); }
.feature-grid .tile-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 19px; }
.feature-grid .tile { min-height: 163px; padding: 30px 38px; border-radius: 10px; box-shadow: 0 16px 36px -18px rgb(0 30 40 / .4); }
.feature-grid .tile__title { font-size: clamp(1.25rem, 1.6vw, 1.375rem); font-weight: 500; margin-bottom: .5em; }
.feature-grid .tile__text { font-size: .9375rem; line-height: 1.5; color: #3f474b; }
.feature-grid .tile-grid--2 > .tile:nth-child(4n+1),
.feature-grid .tile-grid--2 > .tile:nth-child(4n) { background: var(--teal); }

/* ---------- Cards / programs ----------
   Proportions measured from the design. Cards are shared with archive pages. */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 19px; }
.card { display: flex; flex-direction: column; background: var(--white); border-radius: 13px; overflow: hidden; box-shadow: 0 22px 44px -22px rgb(0 50 70 / .22); }
.card__image { width: 100%; aspect-ratio: 1.64; object-fit: cover; }
.card__body { display: flex; flex-direction: column; align-items: flex-start; flex: 1; padding: 20px 38px 22px; }
.card .eyebrow { font-size: clamp(1.0625rem, 1.4vw, 1.2rem); line-height: 1.3; margin-bottom: 16px; }
.card__title { font-size: clamp(1.25rem, 1.6vw, 1.375rem); font-weight: 400; line-height: 1.33; color: #1d2b3a; margin-bottom: 39px; }
.card .btn { margin-top: auto; gap: 1.25em; padding: 1.27em 1.68em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); border-width: 1.5px; }

.programs { padding: clamp(64px, 8vw, 110px) 0 clamp(72px, 9vw, 122px); background: #e8f4f8; }
.programs .section__header { margin-bottom: clamp(32px, 4vw, 51px); }
.programs .section__heading { margin: 0; }
.programs .section__header .btn { gap: 1.25em; padding: 1.23em 3.1em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); }
.programs .card-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }

/* ---------- Stats ----------
   Proportions measured from the design. Flat teal (no pattern) per design. */
.stats { padding: clamp(64px, 7vw, 95px) 0 clamp(72px, 8vw, 114px); background: var(--teal); }
.stats .section__heading--serif { font-size: clamp(2.25rem, 4.2vw, 3.25rem); font-weight: 500; line-height: 1.15; margin-bottom: clamp(32px, 4vw, 54px); }
.stats .slider { gap: 21px; }
.stats .slider__arrow { width: 62px; height: 62px; border-color: transparent; }
/* Vertical padding lets card shadows show inside the scrolling track. */
.stats__track { grid-auto-columns: calc((100% - 44px) / 3); gap: 22px; padding-block: 30px; margin-block: -30px; }
.stat-card { min-height: 194px; padding: 30px 38px; border-radius: 9px; background: var(--teal-dark); color: var(--white); box-shadow: 0 22px 40px -20px rgb(0 40 50 / .45); }
/* Cards alternate green / white (white / green with "Start with a white card"). */
.stat-card:nth-child(even), .stats--white-first .stat-card:nth-child(odd) { background: var(--white); color: #2b2b2b; }
.stat-card:nth-child(even) .stat-card__value, .stats--white-first .stat-card:nth-child(odd) .stat-card__value { color: var(--teal); }
.stats--white-first .stat-card:nth-child(even) { background: var(--teal-dark); color: var(--white); }
.stats--white-first .stat-card:nth-child(even) .stat-card__value { color: inherit; }

/* Photo background under a teal wash. */
.stats--image { position: relative; overflow: clip; }
.stats--image::before { content: ""; position: absolute; inset: 0; z-index: 1; background: rgb(2 178 174 / .84); }
.stats__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.stats--image .container { position: relative; z-index: 2; }

/* Feature layout: photo with the heading on it, stats in a 2-column grid; every 5th from the 3rd spans both columns. */
.stats--feature { background: var(--teal-dark) url(assets/img/pattern-teal-dark.jpg) center / cover; }
.stats__feature { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 20px; }
.stats__photo { position: relative; min-height: 380px; overflow: hidden; border-radius: 12px; }
.stats__photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.stats__photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgb(0 0 0 / .55), transparent 55%); }
.stats__photo-heading { position: absolute; inset: auto 32px 28px; z-index: 1; margin: 0; font-size: clamp(2rem, 3.4vw, 2.9rem); line-height: 1.1; color: var(--white); }
.stats__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.stats__grid .stat-card { min-height: 0; padding: 26px 32px; }
.stats__grid .stat-card:nth-child(5n+3) { grid-column: 1 / -1; }
.stats__grid .stat-card:nth-child(n) { background: var(--white); color: #2b2b2b; }
.stats__grid .stat-card:nth-child(n) .stat-card__value { color: var(--teal); }
.stats__grid .stat-card:is(:nth-child(5n+2), :nth-child(5n+4)) { background: #7f97a3; color: var(--white); }
.stats__grid .stat-card:nth-child(5n+3) { background: var(--teal); color: var(--white); }
.stats__grid .stat-card:is(:nth-child(5n+2), :nth-child(5n+3), :nth-child(5n+4)) .stat-card__value { color: inherit; }
.stats__grid .stat-card:nth-child(5n) { background: #eaf6f8; }
@media (max-width: 900px) {
	.stats__feature { grid-template-columns: 1fr; }
	.stats__photo { min-height: 300px; }
}
.stat-card__value { display: block; font: 400 clamp(1.875rem, 2.7vw, 2.4rem)/1.2 var(--serif); margin-bottom: 8px; }
.stat-card p { font-size: .9375rem; line-height: 1.52; margin: 0; }

/* ---------- Donate ----------
   Proportions measured from the design. The form mirrors the Donorbox widget, so it uses the system UI font. */
.donate { padding: clamp(64px, 7vw, 91px) 0 clamp(64px, 7vw, 97px); background: var(--charcoal) url(assets/img/pattern-grey.jpg) center / cover; color: var(--white); }
.donate__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 510px); gap: 48px; align-items: center; }
.donate__heading { font-size: clamp(2.5rem, 4.6vw, 3.6rem); line-height: 1.2; margin-bottom: 36px; }
.donate__heading strong { font-size: 1.04em; }
.donate__layout > div:first-child p { max-width: 430px; margin: 0; font-size: .95rem; line-height: 1.5; }
.donate .btn-row { margin-top: 28px; }
.donate .btn-row .btn { gap: 1.25em; padding: 1.24em 1.6em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); }

.donate__embed { min-width: 0; }
.donate__panel { padding: 31px clamp(24px, 6vw, 84px) 29px; background: var(--white); color: #1f2328; border-radius: 14px; box-shadow: var(--shadow); }
/* Header donate popup: the same panel in a native <dialog> */
.donate-modal { width: min(560px, 100% - 32px); max-height: calc(100% - 32px); padding: 0; border: 0; border-radius: 14px; background: none; overflow: visible; }
.donate-modal::backdrop { background: rgb(0 128 128 / .3); }
body:has(.donate-modal[open]) { overflow: hidden; }
.donate-modal :is(.donate__panel, .donate__embed) { max-height: calc(100dvh - 32px); overflow: auto; padding-top: 40px; }
.donate-modal .donate__embed { padding: 56px 16px 16px; border-radius: 14px; background: var(--white); }
.donate-modal .donate-modal__close { top: 12px; right: 12px; width: 40px; height: 40px; }

.donate-form { display: grid; font: 400 15px/1.3 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.donate-form fieldset { display: grid; gap: 0; min-width: 0; margin: 0; padding: 0; border: 0; }
.donate-form legend { display: flex; align-items: center; justify-content: center; gap: 7px; width: 100%; margin-bottom: 22px; font-size: 17px; font-weight: 500; }
.donate-form input:focus-visible + span, .donate-form :is(select, textarea):focus-visible, .donate-form__other:focus-within { outline: 3px solid var(--yellow); outline-offset: 1px; }

.pills { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 3px; margin-bottom: 22px; border-radius: 8px; background: #f1f2f3; }
.amounts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 8px; }
.pill input { position: absolute; opacity: 0; }
.pill span { display: grid; place-items: center; height: 34px; border: 1px solid transparent; border-radius: 6px; font-weight: 600; cursor: pointer; }
.pill--amount span { height: 44px; background: #f1f2f3; font-size: 14px; }
.pill input:checked + span { border-color: var(--teal); background: #dff6f5; }
.pill span:hover { border-color: #b9e6e4; }

.donate-form__other { display: flex; align-items: center; gap: 8px; height: 43px; padding: 0 13px; border-radius: 6px; background: #f1f2f3; color: #5b6168; }
.donate-form__other > span:first-child { font-size: 20px; font-weight: 500; }
.donate-form__other > span:last-child { font-size: 14px; font-weight: 600; color: #1f2328; }
.donate-form__other input { flex: 1; min-width: 0; border: 0; background: none; font-family: inherit; font-size: 20px; font-weight: 500; line-height: 1; color: #1f2328; }
.donate-form__other input::placeholder { color: #5b6168; }
.donate-form__other input:focus { outline: none; }
.donate-form__other input::-webkit-inner-spin-button { display: none; }

.donate-form__label { margin: 23px 0 5px; font-weight: 600; }
.donate-form select { appearance: none; height: 41px; padding: 0 40px 0 13px; border: 1px solid #cfd4d8; border-radius: 6px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%231f2328' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m1.5 1.5 4.5 4.5 4.5-4.5'/%3E%3C/svg%3E") no-repeat right 14px center; font: inherit; font-size: 15.5px; color: #5b6168; }

.donate-form__note { margin-top: 12px; }
.donate-form__note label { display: inline-flex; align-items: center; gap: 10px; font-size: 15.5px; cursor: pointer; }
.donate-form__note input { width: 16px; height: 16px; margin: 0; accent-color: var(--teal); }
.donate-form__note textarea { display: none; width: 100%; margin-top: 10px; padding: 8px 12px; border: 1px solid #cfd4d8; border-radius: 6px; font: inherit; }
.donate-form__note:has(input:checked) textarea { display: block; }

.donate-form__submit { height: 46px; margin-top: 27px; border: 0; border-radius: 6px; background: var(--teal); color: var(--white); font-family: inherit; font-size: 15px; font-weight: 600; cursor: pointer; transition: background .2s; }
.donate-form__submit:hover { background: var(--teal-dark); }
.donate-form__submit:disabled { background: #a8dcda; cursor: not-allowed; }


/* ---------- Page header ---------- */
.page-header { padding: clamp(56px, 7vw, 96px) 0 clamp(56px, 7vw, 100px); background: var(--teal) url(assets/img/pattern-teal.jpg) center / cover; color: var(--white); }
.page-header__heading { font-size: clamp(2.5rem, 5vw, 3.75rem); font-weight: 700; margin-bottom: .4em; }
.page-header__text { max-width: 820px; margin: 0; font-size: clamp(1.0625rem, 1.5vw, 1.25rem); line-height: 1.6; }
.page-header__heading:has(strong) { font-weight: 300; } /* "*Contact*\nKoppa Lab": bold first line, light second */
.page-header .btn-row { margin-top: 36px; }
.page-header .btn { gap: 1.25em; padding: 1.3em 1.9em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); }
/* With an image: the photo fills the right half and fades into the teal behind the text. */
.page-header--image { position: relative; display: flex; align-items: center; min-height: clamp(320px, 30vw, 440px); overflow: hidden; }
.page-header__bg { position: absolute; inset: 0 0 0 auto; width: 58%; height: 100%; object-fit: cover; mask-image: linear-gradient(90deg, transparent, rgb(0 0 0 / .6) 30%, #000 65%); }
.page-header__inner { position: relative; z-index: 1; }
.page-header--image .page-header__text { max-width: min(560px, 48%); }
@media (max-width: 700px) {
	.page-header--image { flex-direction: column; align-items: stretch; padding-top: 0; }
	.page-header__bg { position: static; width: 100%; height: auto; aspect-ratio: 16 / 9; margin-bottom: 32px; mask-image: linear-gradient(0deg, transparent, #000 45%); }
	.page-header--image .page-header__text { max-width: none; }
}

/* ---------- Contact form ---------- */
.contact { background: #e7f5f9; scroll-margin-top: var(--header-h); }
.contact__header { margin-bottom: 40px; text-align: center; }
.contact__heading { margin-bottom: .3em; font-size: clamp(2rem, 3vw, 2.6rem); font-weight: 700; }
.contact__header p { margin: 0; font-size: clamp(1.0625rem, 1.4vw, 1.2rem); }
.contact__notice { margin-bottom: 28px; padding: 16px 22px; border-left: 4px solid var(--teal); border-radius: 10px; background: var(--white); }
.contact__notice--error { border-color: #c2412d; }
.contact-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 20px; }
/* Block flow, not grid gap: password managers (e.g. LastPass) inject an icon element after the input, which a gap would space out. */
.contact-form__field { display: block; font-size: clamp(1.0625rem, 1.3vw, 1.2rem); font-weight: 500; letter-spacing: -.01em; color: #24343c; }
.contact-form__field--full, .contact-form__note, .contact-form__submit { grid-column: 1 / -1; }
.contact-form :is(input, select, textarea) { display: block; width: 100%; margin-top: 12px; height: 58px; padding: 0 20px; border: 1px solid transparent; border-radius: 999px; background: var(--white); font: 400 1rem/1.4 var(--sans); color: var(--ink); }
.contact-form textarea { height: auto; min-height: 126px; padding: 16px 20px; border-radius: 18px; resize: vertical; }
.contact-form select { appearance: none; padding-right: 56px; background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%231d2b30' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m1.5 1.5 4.5 4.5 4.5-4.5'/%3E%3C/svg%3E") no-repeat right 28px center; cursor: pointer; }
.contact-form ::placeholder { color: #a3adb3; }
.contact-form :is(input, select, textarea):focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgb(2 178 174 / .25); }
.contact-form__hp { position: absolute; left: -9999px; }
.contact-form__note { margin: 10px 0 0; text-align: center; font-size: clamp(1.0625rem, 1.4vw, 1.25rem); color: var(--teal); }
.contact-form__submit { height: 66px; font-size: 1.1rem; }

/* ---------- Insights (filters, results, pagination) ---------- */
.filter-bar__search { flex: 3 1 360px; }
.filter-bar__submit { display: grid; place-items: center; padding: 4px; border: 0; background: none; color: inherit; cursor: pointer; }
.filter-bar__select { flex: 1 1 180px; }
.filter-bar__select select { appearance: none; width: 100%; min-height: 63px; padding: 0 56px 0 30px; border: 1px solid var(--white); border-radius: 999px; background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m1.5 1.5 4.5 4.5 4.5-4.5'/%3E%3C/svg%3E") no-repeat right 28px center; color: var(--white); font: 600 1.0625rem/1 var(--sans); cursor: pointer; }
.filter-bar__select select:focus-visible { outline: 3px solid var(--yellow); }
.filter-bar__select option { color: var(--ink); }
.insights { scroll-margin-top: var(--header-h); }
.insights__count { margin-bottom: 28px; font-size: clamp(1.0625rem, 1.4vw, 1.25rem); }
.insights__grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 20px; }
.card-grid-section .card-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 20px; }
.card__date { margin-bottom: 12px; font-size: .95rem; color: var(--teal-dark); }
.insights .card__title { margin-bottom: 12px; }
.insights .card__date { margin-bottom: 28px; }
.pagination { display: grid; grid-template-columns: 1fr auto 1fr; grid-template-areas: "prev pages next"; align-items: center; gap: 16px; margin-top: clamp(48px, 6vw, 80px); }
.pagination__prev { grid-area: prev; justify-self: start; border: 1px solid var(--ink); color: var(--ink); }
.pagination__next { grid-area: next; justify-self: end; background: #1d2530; color: var(--white); }
.pagination .btn { gap: 1em; padding: 1.25em 1.9em; font-size: 1rem; }
.pagination__prev:hover { background: var(--ink); color: var(--white); }
.pagination__next:hover { background: var(--teal-dark); }
.pagination__pages { grid-area: pages; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 22px; margin: 0; padding: 0; list-style: none; }
.pagination__pages a { display: grid; place-items: center; width: 60px; aspect-ratio: 1; border: 1px solid var(--ink); border-radius: 50%; color: var(--ink); font-size: 1.125rem; text-decoration: none; transition: background .2s, color .2s; }
.pagination__pages a:hover, .pagination__pages a[aria-current] { background: var(--ink); color: var(--white); }

/* ---------- Media + tiles ---------- */
.media-tiles { background: radial-gradient(ellipse 45% 60% at 80% 0, rgb(2 178 174 / .32), transparent 70%), #e7f5f9; }
.media-tiles__layout { display: grid; grid-template-columns: minmax(0, 510px) minmax(0, 610px); justify-content: space-between; align-items: center; gap: 48px; }
.media-tiles__heading { margin-bottom: clamp(32px, 4vw, 56px); font-size: clamp(2.5rem, 4.2vw, 3.6rem); line-height: 1.15; }
.media-tiles__image { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; object-position: center 30%; border-radius: 14px; } /* fixed shape so portrait photos don't stretch the section */
.media-tiles__tiles { display: grid; gap: 20px; }
.media-tiles .tile { padding: 30px 40px; border-radius: 10px; box-shadow: 0 24px 48px -20px rgb(0 60 70 / .22); }
.media-tiles .tile__title { margin-bottom: .4em; font-size: clamp(1.25rem, 1.7vw, 1.5rem); }
.media-tiles .tile__text { font-size: .95rem; line-height: 1.5; color: #3f474b; }
.media-tiles .tile:nth-child(odd) { background: var(--teal); }
.media-tiles .tile:nth-child(odd) :is(.tile__title, .tile__text) { color: var(--white); }
.media-tiles--serif .tile { padding: 34px 40px 40px; }
.media-tiles--serif .tile__title { font: 400 clamp(1.75rem, 2.6vw, 2.4rem)/1.2 var(--serif); color: var(--teal); }

/* ---------- Case studies ---------- */
.case-studies { background: var(--teal-dark) url(assets/img/pattern-teal-dark.jpg) center / cover; color: var(--white); }
.case-studies .section__header { margin-bottom: clamp(32px, 4vw, 46px); }
.case-studies__heading { margin: 0; font-size: clamp(2.25rem, 3.6vw, 3.25rem); font-weight: 400; }
.case-studies__arrows { display: flex; gap: 18px; }
.case-studies .slider__track { grid-auto-columns: 100%; }
.case-study { display: grid; grid-template-columns: minmax(0, 600fr) minmax(0, 665fr); overflow: hidden; border-radius: 16px; background: var(--white); color: var(--ink); }
.case-study__image { width: 100%; height: 100%; min-height: 300px; object-fit: cover; }
.case-study__body { align-self: center; padding: clamp(32px, 4vw, 60px); }
.case-study .eyebrow { font-size: clamp(1rem, 1.3vw, 1.125rem); margin-bottom: 12px; }
.case-study__text { margin-bottom: 36px; font-size: clamp(1.125rem, 1.6vw, 1.45rem); line-height: 1.45; color: #1d2b3a; }
.case-study .btn { gap: 1.25em; padding: 1.2em 1.9em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); border-width: 1px; }

/* ---------- Call to action ---------- */
.cta { padding: clamp(56px, 6vw, 84px) 0; background: var(--teal-dark); color: var(--white); text-align: center; }
.cta__heading { margin-bottom: .5em; font-size: clamp(2rem, 3vw, 2.5rem); }
.cta__text { margin: 0; font-size: clamp(1.0625rem, 1.4vw, 1.25rem); }
.cta .btn { gap: 1.25em; padding: 1.25em 1.9em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); }

/* ---------- Card grid (reports) ---------- */
.card-grid-section { background: #f4f9fc; }
.card-grid-section .section__header { margin-bottom: clamp(32px, 4vw, 66px); }
.btn--outline-dark { border: 1px solid var(--ink); color: var(--ink); gap: 1.25em; padding: 1.25em 2.6em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); }
.btn--outline-dark:hover { background: var(--ink); color: var(--white); }

/* ---------- Content (centered variant), quotes over a photo, story grid on dark teal ---------- */
.content--centered { background: #e7f5f9; }
.content--centered .prose { max-width: 900px; text-align: center; }
.prose .content__heading { margin-bottom: .9em; font-size: clamp(2.25rem, 3.6vw, 3.1rem); font-weight: 300; }
.prose .content__heading strong { font-weight: 700; }
.quotes--image { position: relative; overflow: clip; background: var(--teal); } /* clip, not hidden: hidden would become the parallax scroll container */
.quotes--image::before { content: ""; position: absolute; inset: 0; z-index: 1; background: rgb(2 178 174 / .85); }
.quotes__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Parallax: the photo is taller than the section and main.js shifts it as the section scrolls past. */
.quotes__bg[data-parallax] { inset: -35% 0 auto; height: 170%; will-change: transform; } /* 35% spare above and below covers the ±20% shift in main.js */
.quotes--image .container { position: relative; z-index: 2; }
.quotes--image :is(blockquote, figcaption) { color: var(--white); }
.story-grid--dark { background: var(--teal-dark) url(assets/img/pattern-teal-dark.jpg) center / cover; color: var(--white); }
.story-grid--dark .section__header { max-width: 1000px; }

/* ---------- Trusted by ---------- */
.trusted-by { padding: 28px 0; background: var(--white); }
.trusted-by__inner { display: flex; align-items: center; gap: 16px 40px; }
.trusted-by__label { flex: none; margin: 0; font-size: 1.0625rem; font-weight: 600; }
/* Marquee: two copies of the list, each at least as wide as the strip, slide left by one copy then repeat. */
.trusted-by__marquee { flex: 1; min-width: 0; overflow: hidden; container-type: inline-size; mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); }
.trusted-by__track { display: flex; width: max-content; animation: marquee calc(var(--count, 5) * 4s) linear infinite; }
.trusted-by__marquee:hover .trusted-by__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.trusted-by__logos { list-style: none; margin: 0; padding: 0 48px 0 0; display: flex; align-items: center; justify-content: space-around; gap: 48px; min-width: 100cqw; }
.trusted-by__logos li { flex: none; }
.trusted-by__logos img { width: auto; max-width: 190px; height: auto; max-height: 56px; }
@media (prefers-reduced-motion: reduce) {
	.trusted-by__track { animation: none; width: auto; }
	.trusted-by__logos { flex-wrap: wrap; justify-content: flex-start; gap: 16px 48px; min-width: 0; }
	.trusted-by__logos[aria-hidden] { display: none; }
}
@media (max-width: 700px) {
	.trusted-by__inner { flex-direction: column; align-items: stretch; }
	.trusted-by__label { text-align: center; }
	.trusted-by__logos { gap: 32px; padding-right: 32px; }
	.trusted-by__logos img { max-width: 140px; max-height: 44px; }
}

/* ---------- Text + image (Our Mission) ---------- */
.media-text { background: url(assets/img/curve.jpg) center bottom / cover no-repeat, #fff; }
.media-text__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.media-text .eyebrow { font-size: clamp(1rem, 1.4vw, 1.175rem); font-weight: 600; }
.media-text__heading { font-size: clamp(2.25rem, 4.6vw, 3.6rem); line-height: 1.12; }
.media-text__text { max-width: 480px; margin: 0; font-size: clamp(1rem, 1.3vw, 1.125rem); line-height: 1.6; color: #4c5a62; }
.media-text__image { width: 100%; max-width: 560px; justify-self: end; }

/* ---------- Filter bar + grouped sections (Team, Program List) ----------
   Proportions measured from the design. Sections alternate light blue / off-white; one straight after the bar gets a soft teal glow. */
.filter-bar { padding: 42px 0; background: var(--teal-dark); }
.filter-bar__inner { display: flex; flex-wrap: wrap; gap: 16px; }
.filter-bar__link { flex: 1 1 150px; display: grid; place-items: center; min-height: 67px; padding: 0 16px; border: 1px solid var(--white); border-radius: 999px; background: rgb(255 255 255 / .32); color: var(--white); font-size: 1.0625rem; font-weight: 600; text-decoration: none; transition: background .2s, color .2s; }
.filter-bar__link:hover { background: var(--white); color: var(--teal-dark); }
.team-search { flex: 2.2 1 280px; display: flex; align-items: center; min-height: 63px; padding: 0 28px 0 30px; border-radius: 999px; background: var(--white); color: var(--ink); }
.team-search:focus-within { outline: 3px solid var(--yellow); }
.team-search input { flex: 1; min-width: 0; border: 0; background: none; font: 600 1.0625rem/1 var(--sans); color: inherit; }
.team-search input::placeholder { color: var(--ink); }
.team-search input:focus { outline: none; }
.team-search svg { flex: none; }

.group-section { background: #e7f5f9; scroll-margin-top: var(--header-h); }
.group-section--alt { background: #f4f9fc; }
.filter-bar + .group-section { background: radial-gradient(ellipse 45% 40% at 85% 0, rgb(2 178 174 / .38), transparent), #e7f5f9; }
.group-section__heading { margin-bottom: clamp(32px, 4vw, 52px); font-size: clamp(2.25rem, 3.6vw, 3.1rem); font-weight: 400; letter-spacing: -.02em; text-align: center; color: #2b2b2b; }
.group-section .eyebrow { margin-bottom: .6em; font-size: clamp(1rem, 1.3vw, 1.1875rem); font-weight: 600; text-align: center; }

/* ---------- Program list ---------- */
.banner-image { width: 100%; height: clamp(240px, 34vw, 517px); object-fit: cover; }
.program-list .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 20px; }
.program-list .card { border-radius: 16px; box-shadow: none; }
.program-list .card__image { aspect-ratio: 617 / 302; }
.program-list .card__body { padding: 40px; }
.program-list .card__title { margin-bottom: .45em; font-size: clamp(1.25rem, 1.6vw, 1.45rem); }
.card__excerpt { margin-bottom: 24px; font-size: .95rem; line-height: 1.6; color: #3f474b; }
.program-list .card .btn { font-size: clamp(1rem, 1.3vw, 1.125rem); border-width: 1px; }

/* ---------- Single program ---------- */
.breadcrumb { margin-bottom: 18px; font-size: .9375rem; }
.breadcrumb a { color: inherit; text-underline-offset: 3px; }
.breadcrumb span { margin: 0 6px; opacity: .6; }
.program-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 360px); gap: clamp(40px, 6vw, 88px); align-items: start; }
.program-facts { position: sticky; top: calc(var(--header-h) + 24px); padding: 32px; border-radius: 16px; background: #f4f9fc; }
.program-facts__heading { margin-bottom: 20px; font-size: 1.375rem; font-weight: 600; }
.program-facts dl { margin: 0; }
.program-facts dt { font-size: .8125rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--teal-dark); }
.program-facts dd { margin: 2px 0 18px; padding-bottom: 18px; border-bottom: 1px solid #dde9ee; line-height: 1.5; }
.program-facts dd:last-of-type { margin-bottom: 0; padding-bottom: 0; border-bottom: 0; }
.program-facts .btn { margin-top: 28px; padding-block: 1.1em; font-size: 1rem; }

/* ---------- Team ---------- */
.team-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 29px; }
.team-card { display: flex; flex-direction: column; align-items: center; padding: 40px clamp(24px, 4vw, 52px); border-radius: 22px; background: var(--white); text-align: center; box-shadow: 0 30px 60px -30px rgb(0 60 80 / .25); }
.team-card[hidden] { display: none; }
.team-card__photo { width: min(244px, 70%); aspect-ratio: 1; margin-bottom: 34px; border-radius: 50%; object-fit: cover; }
.team-card__name { margin-bottom: .2em; font-size: clamp(1.625rem, 2.4vw, 2.1rem); font-weight: 400; color: #2b2b2b; }
.team-role { margin-bottom: .55em; font-size: clamp(1.0625rem, 1.4vw, 1.25rem); color: var(--teal); }
.team-pronouns { margin-bottom: .6em; font-size: clamp(1.0625rem, 1.4vw, 1.2rem); color: #7f95a3; }
.team-card__excerpt { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; margin: 0; font-size: clamp(1rem, 1.3vw, 1.125rem); line-height: 1.65; color: #3f474b; }
.team-actions { display: flex; align-items: center; gap: 16px; margin-top: 32px; }
.team-card .team-actions { margin-top: auto; padding-top: 32px; }
.team-actions .btn { gap: 1.25em; padding: 1.2em 1.95em; font-size: clamp(.9375rem, 1.2vw, 1.05rem); border-width: 1.5px; }
.team-linkedin { display: block; flex: none; border-radius: 50%; color: var(--ink); transition: background .2s; }
.team-linkedin:hover { background: var(--teal-light); }
.team-linkedin svg { display: block; width: 54px; height: auto; }

/* Popup: padding sits on the inner box so a click on the dialog itself is a backdrop click (main.js). */
.team-modal { width: min(1252px, 100% - 32px); max-height: calc(100% - 32px); padding: 0; border: 0; border-radius: 24px; color: var(--ink); box-shadow: 0 30px 80px -20px rgb(0 50 60 / .4); }
.team-modal::backdrop { background: rgb(0 128 128 / .3); }
body:has(.team-modal[open]) { overflow: hidden; }
.team-modal__inner { position: relative; display: grid; grid-template-columns: minmax(0, 554px) minmax(0, 1fr); gap: 40px; align-items: center; padding: 40px; }
.team-modal__photo { width: 100%; aspect-ratio: 554 / 606; border-radius: 24px; object-fit: cover; }
.team-modal__body { max-width: 520px; padding: 40px 0; }
.team-modal__name { margin-bottom: .3em; font-size: clamp(1.75rem, 2.6vw, 2.25rem); font-weight: 500; color: #1d2b3a; }
.team-modal .team-role, .team-modal .team-pronouns { font-size: clamp(1.0625rem, 1.5vw, 1.3rem); }
.team-modal .team-pronouns { margin-bottom: 1em; }
.team-modal__bio { font-size: .95rem; line-height: 1.6; color: #3f474b; }
.team-modal__bio p { margin: 0 0 .9em; }
.team-modal__bio p:last-child { margin-bottom: 0; }
.team-modal__close { position: absolute; top: 40px; right: 40px; display: grid; place-items: center; width: 54px; height: 54px; padding: 0; border: 1px solid #9fe0de; border-radius: 50%; background: #e3f6f7; color: var(--teal-dark); cursor: pointer; transition: background .2s; }
.team-modal__close:hover { background: #c9eeee; }

@media (max-width: 900px) {
	.team-modal__inner { grid-template-columns: 1fr; gap: 24px; padding: 24px; }
	.team-modal__photo { max-width: 360px; aspect-ratio: 1; }
	.team-modal__body { padding: 0; }
	.team-modal__close { top: 24px; right: 24px; }
}
@media (max-width: 700px) {
	.team-grid, .program-list .card-grid { grid-template-columns: 1fr; }
	.contact-form { grid-template-columns: 1fr; }
	.pagination { grid-template-columns: 1fr 1fr; grid-template-areas: "pages pages" "prev next"; }
	.pagination__pages a { width: 48px; }
	.case-studies .section__header { flex-direction: row; align-items: center; }
	.media-tiles .tile { padding: 26px 28px; }
	.program-list .card__body { padding: 28px 24px; }
	.filter-bar { padding: 24px 0; }
	.filter-bar__link { min-height: 52px; }
	.team-search { min-height: 52px; }
}

/* ---------- Light variants of reused components ---------- */
.stats--light { background: #e8f4f8; }
.stats--light .stats__heading { color: var(--ink); }
.stats__heading:not(.section__heading--serif) { text-align: center; margin-bottom: clamp(32px, 4vw, 54px); }
.stats__footer { margin: clamp(32px, 4vw, 48px) 0 0; text-align: center; font-size: 1.0625rem; }
.stats .btn-row { margin-top: 24px; }
.story-grid--light { background: #f4f9fc; }

/* ---------- Global reach (tabs) ---------- */
.global-reach { background: var(--teal) url(assets/img/pattern-gradient.jpg) center / cover; color: var(--white); }
.global-reach .section__header p { font-size: clamp(1rem, 1.4vw, 1.15rem); line-height: 1.6; margin: 0; }
.global-reach__tabs { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 16px; }
.global-reach__tab { display: grid; justify-items: center; gap: 4px; padding: 20px 12px; border: 0; border-radius: 10px; background: rgb(255 255 255 / .18); color: var(--white); font: inherit; cursor: pointer; transition: background .2s; }
.global-reach__tab:hover { background: rgb(255 255 255 / .28); }
.global-reach__tab[aria-selected="true"] { background: var(--charcoal); }
.global-reach__tab strong { font-size: 1.0625rem; }
.global-reach__tab span:last-child { font-size: .875rem; opacity: .85; }
.global-reach__icon { display: grid; place-items: center; width: 40px; height: 40px; margin-bottom: 6px; border-radius: 50%; background: var(--white); color: var(--teal-dark); }
.global-reach__icon svg { display: block; }
.global-reach__panel { padding: clamp(24px, 3vw, 40px); border-radius: 12px; background: var(--white); color: var(--ink); box-shadow: var(--shadow); }
.global-reach__intro { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: start; }
.global-reach__name { font-size: clamp(1.375rem, 2vw, 1.75rem); font-weight: 600; margin-bottom: 4px; }
.global-reach__count { margin-bottom: 14px; color: var(--teal-dark); font-size: .9375rem; }
.global-reach__countries { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; max-width: 640px; }
.global-reach__countries li { display: inline-flex; align-items: center; gap: .45em; padding: 4px 14px 4px 11px; border-radius: 999px; background: var(--teal-light); color: var(--teal-dark); font-size: .875rem; }
.global-reach__countries li::before { /* Font Awesome location-dot */
	content: ""; width: .75em; height: 1em; flex: none; background: currentColor;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 384 512'%3E%3Cpath d='M215.7 499.2C267 435 384 279.4 384 192 384 86 298 0 192 0S0 86 0 192c0 87.4 117 243 168.3 307.2 12.3 15.3 35.1 15.3 47.4 0zM192 128a64 64 0 1 1 0 128 64 64 0 1 1 0-128z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.global-reach__map { width: 200px; height: auto; }
.global-reach__label { margin: 28px 0 14px; font-size: 1rem; font-weight: 600; }
.global-reach__programs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.global-reach__program { padding: 22px 24px; border-radius: 10px; background: #f4f9fc; }
.global-reach__program h5 { margin: 0 0 8px; font-size: 1.0625rem; font-weight: 600; color: var(--teal-dark); }
.global-reach__program h5 .tag { margin: 0 0 0 6px; vertical-align: middle; }
.global-reach__program p { margin: 0; font-size: .9375rem; line-height: 1.5; color: #4c5a62; }
.global-reach__program-countries { margin-top: 10px !important; color: var(--teal-dark) !important; }

/* ---------- Prose ---------- */
.prose { max-width: 760px; }
.prose h1 { font-size: clamp(2rem, 4vw, 2.75rem); font-weight: 700; }
.prose__image { border-radius: var(--radius); margin-bottom: 32px; }
.prose { font-size: clamp(1rem, 1.2vw, 1.0625rem); line-height: 1.7; color: #3f474b; }
.prose h2 { margin: 1.6em 0 .5em; font-size: clamp(1.625rem, 2.4vw, 2rem); font-weight: 400; color: var(--ink); }
.prose h3 { margin: 1.4em 0 .4em; font-size: 1.25rem; font-weight: 600; color: var(--ink); }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { margin: 0 0 1em; padding-left: 1.25em; }
.prose li { margin-bottom: .4em; }
.prose li::marker { color: var(--teal); }
.prose blockquote { margin: 1.6em 0; padding-left: 24px; border-left: 3px solid var(--teal); font: 400 1.25rem/1.5 var(--serif); color: var(--ink); }

/* ---------- Footer ----------
   Proportions measured from the design: left zone (logo + menus) | divider | right zone (socials + newsletter). */
.site-footer { background: var(--teal) url(assets/img/koppa-icon.svg) no-repeat right -196px top -96px / 635px; color: var(--white); }
.site-footer a { color: inherit; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer__main { display: grid; grid-template-columns: minmax(0, 1fr) 1px minmax(0, 423px); column-gap: 69px; row-gap: 63px; padding: clamp(48px, 5vw, 73px) 0 clamp(56px, 6vw, 84px); }
.site-footer__main::before { content: ""; grid-column: 2; grid-row: 1 / 3; margin-top: 9px; background: rgb(255 255 255 / .3); }
.site-footer__logo { grid-column: 1; grid-row: 1; align-self: center; justify-self: start; }
.site-footer__logo svg { width: 282px; height: auto; }
.socials { grid-column: 3; grid-row: 1; align-self: center; list-style: none; margin: 0; padding: 0; display: flex; gap: 17px; }
.socials a { display: block; border-radius: 50%; transition: opacity .2s; }
.socials a:hover { opacity: .75; }
.socials svg { display: block; width: 50px; height: auto; }
.site-footer h2 { font-size: 1.1rem; font-weight: 700; line-height: 1.2; margin-bottom: 8px; }
.site-footer__menus { grid-column: 1; grid-row: 2; display: grid; grid-template-columns: 202px auto; }
.footer-menu ul { list-style: none; margin: 0; padding: 0; display: grid; }
.footer-menu a { font-size: .9375rem; font-weight: 300; line-height: 1.64; }
.footer-menu--footer_programs ul { grid-template-columns: repeat(2, 224px); grid-auto-flow: column; grid-template-rows: repeat(4, auto); }
.newsletter { grid-column: 3; grid-row: 2; }
.newsletter p { margin: 0; font-size: .925rem; font-weight: 300; line-height: 1.64; }
.newsletter form { display: flex; align-items: center; height: 54px; margin-top: 34px; padding: 0 8px 0 18px; border-radius: 999px; background: #f5f5f5; }
.newsletter input { flex: 1; min-width: 0; border: 0; background: none; font: 400 17px/1.2 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); }
.newsletter input::placeholder { color: #8a8f94; }
.newsletter input:focus { outline: none; }
.newsletter form:focus-within { outline: 3px solid var(--yellow); }
.newsletter button { display: grid; place-items: center; flex: none; width: 38px; height: 38px; padding: 0; border: 0; border-radius: 50%; background: #1d2530; color: var(--white); cursor: pointer; }
.newsletter button svg { width: 18px; height: 18px; }
.site-footer__bottom { background: #e8f4f8; color: var(--ink); font-size: clamp(.875rem, 1.1vw, .95rem); }
.site-footer__bottom .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; min-height: 56px; padding: 12px 0; }
.site-footer__bottom p { margin: 0; }
.site-footer__credit { color: #6b7680; }
.site-footer .site-footer__credit a { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
	.stat-intro__top, .feature-grid__layout, .donate__layout, .media-text__layout, .program-body { grid-template-columns: 1fr; }
	.program-facts { position: static; }
	.media-tiles__layout, .case-study { grid-template-columns: 1fr; }
	.case-study__image { min-height: 0; aspect-ratio: 16 / 10; }
	.media-tiles__image { max-width: 560px; }
	.media-text__image { justify-self: center; }
	.site-footer__main { grid-template-columns: 1fr; row-gap: 40px; }
	.site-footer__main::before { display: none; }
	.site-footer__main > * { grid-column: 1; grid-row: auto; }
	.stat-intro__visual { justify-content: center; margin-top: 0; }
	.story-grid__layout { grid-template-columns: 1fr; }
	.story-grid__image { position: static; grid-column: auto; grid-row: auto; height: auto; aspect-ratio: 4 / 3; order: -1; }
	.story-grid__col:last-child { grid-column: auto; }
	.story-grid .tile { min-height: 0; }
	.stats__track { grid-auto-columns: 85%; }
	.global-reach__programs { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
	.media-text { background: linear-gradient(160deg, #f5fafc 0%, #eef7f9 45%, #d5eeee 100%); }
	.global-reach__intro { grid-template-columns: 1fr; }
	.global-reach__map { width: 140px; }
	.site-footer { background-size: 380px; background-position: right -150px top -40px; }
	.feature-grid .tile-grid--2 { grid-template-columns: 1fr; }
	.feature-grid .tile { min-height: 0; }
	.stat-intro { background: linear-gradient(160deg, #f5fafc 0%, #eef7f9 45%, #d5eeee 100%); } /* wave distorts on tall mobile layout */
	.slider__arrow { display: none; }
	.section__header--split { flex-direction: column; align-items: flex-start; }
	.site-footer__menus { grid-template-columns: 1fr; row-gap: 32px; }
	.footer-menu--footer_programs ul { grid-template-columns: 1fr; grid-auto-flow: row; grid-template-rows: none; }
	.site-footer__logo svg { width: 220px; }
}
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	* { transition: none !important; }
}

/* ---------- Single insight (downloads) ---------- */
.insight-header { padding: clamp(40px, 5vw, 56px) 0; background: var(--teal) url(assets/img/pattern-teal.jpg) center / cover; color: var(--white); }
.insight-header__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 560px); gap: 48px; align-items: center; }
.insight-header__back { display: inline-block; margin-bottom: 28px; font-size: .875rem; color: inherit; text-underline-offset: 3px; }
.insight-header__category { margin-bottom: .4em; font-size: 1rem; font-weight: 600; color: var(--yellow); }
.insight-header__title { margin: 0; font-size: clamp(2rem, 3.4vw, 2.75rem); font-weight: 700; line-height: 1.2; }
.insight-header .btn-row { margin-top: 32px; }
.insight-header__image { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 12px; }

.insight-body__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 360px); gap: clamp(40px, 8vw, 120px); align-items: start; }
.insight-body__layout--single { grid-template-columns: minmax(0, 760px); }
.insight-stats { position: sticky; top: calc(var(--header-h) + 24px); padding: 36px clamp(24px, 3vw, 40px); border-radius: 12px; background: #e7f5f9; }
.insight-stats dl { margin: 0 0 28px; }
.insight-stats dt { font-size: .8125rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--teal-dark); }
.insight-stats dd { margin: 10px 0 22px; padding-bottom: 22px; border-bottom: 1px solid #c9e3ea; font-size: 1.25rem; line-height: 1.4; }
.insight-stats dd:last-of-type { margin-bottom: 0; padding-bottom: 0; border-bottom: 0; }
.insight-stats .btn, .insight-header .btn { gap: 1.25em; padding: 1.15em 1.9em; font-size: .95rem; }

/* Download / language menu: native <details>, so it opens without JS and Esc-free close is by clicking again. */
.download-menu { position: relative; display: inline-block; }
.download-menu summary { list-style: none; }
.download-menu summary::-webkit-details-marker { display: none; }
.download-menu .chevron { margin: 0 0 3px; transition: transform .2s; }
.download-menu[open] .chevron { transform: rotate(-135deg); margin: 3px 0 0; }
.download-menu ul { position: absolute; z-index: 5; top: calc(100% + 8px); left: 0; min-width: 100%; margin: 0; padding: 8px 0; list-style: none; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); }
.download-menu a { display: block; padding: 8px 20px; color: var(--ink); text-decoration: none; white-space: nowrap; }
.download-menu a:hover { background: var(--teal-light); }

.related { background: #e7f5f9; }
.related__heading { margin-bottom: clamp(32px, 4vw, 48px); text-align: center; color: #2b2b2b; }
.related__track { grid-auto-columns: calc((100% - 40px) / 3); gap: 20px; padding-block: 24px; margin-block: -24px; }
.related .card { height: 100%; }

@media (max-width: 900px) {
	.insight-header__layout, .insight-body__layout { grid-template-columns: 1fr; }
	.insight-header__image { order: -1; }
	.insight-stats { position: static; }
	.related__track { grid-auto-columns: 85%; }
}
