/* ==========================================================================
   Foulkes Lab — site styles
   ========================================================================== */

:root {
	--ink: #0f2224;
	--ink-soft: #2d4447;
	--muted: #4a6064;
	--deep: #07343a;
	--deep-2: #0b454c;
	--teal: #0b7468;
	--teal-mid: #12968a;
	--bright: #2fc4ad;
	--mint: #e4f2ef;
	--paper: #f5f9f8;
	--line: #d5e4e1;
	--line-dark: rgba(255, 255, 255, 0.14);
	--blood: #c4283c;
	--blood-bright: #ff5a6a;
	--white: #fff;

	--font-sans: "IBM Plex Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	--font-serif: "IBM Plex Serif", Georgia, serif;
	--font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

	--radius: 16px;
	--radius-sm: 10px;
	--shadow-sm: 0 1px 2px rgba(7, 52, 58, 0.06);
	--shadow: 0 1px 2px rgba(7, 52, 58, 0.05), 0 10px 30px -12px rgba(7, 52, 58, 0.18);
	--container: 1200px;
	--gutter: clamp(1.25rem, 4vw, 2.5rem);
	--header-h: 76px;
	--ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* Base ------------------------------------------------------------------ */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-padding-top: calc(var(--header-h) + 24px);
}

@media (prefers-reduced-motion: no-preference) {
	html {
		scroll-behavior: smooth;
	}
}

body {
	margin: 0;
	background: var(--white);
	color: var(--ink);
	font-family: var(--font-sans);
	font-size: 1.0625rem;
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

img,
svg,
video,
iframe {
	max-width: 100%;
}

img {
	height: auto;
	display: block;
}

h1,
h2,
h3,
h4 {
	margin: 0 0 0.6em;
	font-weight: 600;
	line-height: 1.15;
	letter-spacing: -0.015em;
	color: var(--ink);
	text-wrap: balance;
}

h1 {
	font-size: clamp(2.25rem, 4.6vw, 3.5rem);
	letter-spacing: -0.025em;
}

h2 {
	font-size: clamp(1.75rem, 3vw, 2.375rem);
	letter-spacing: -0.02em;
}

h3 {
	font-size: 1.25rem;
}

p {
	margin: 0 0 1em;
}

a {
	color: var(--teal);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.18em;
}

a:hover {
	color: var(--deep);
}

:focus-visible {
	outline: 3px solid var(--bright);
	outline-offset: 2px;
	border-radius: 4px;
}

address {
	font-style: normal;
}

i,
em {
	font-style: italic;
}

strong {
	font-weight: 600;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	clip: auto;
	width: auto;
	height: auto;
	margin: 0;
	top: 12px;
	left: 12px;
	z-index: 1000;
	padding: 0.75rem 1rem;
	background: var(--white);
	color: var(--ink);
	box-shadow: var(--shadow);
	border-radius: var(--radius-sm);
}

.icon {
	width: 1.1em;
	height: 1.1em;
	flex: none;
}

/* Layout ---------------------------------------------------------------- */

.container {
	width: 100%;
	max-width: calc(var(--container) + var(--gutter) * 2);
	margin: 0 auto;
	padding: 0 var(--gutter);
}

.section {
	padding: clamp(4rem, 8vw, 6.5rem) 0;
}

.section--tight {
	padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(4rem, 7vw, 6rem);
}

.section--paper {
	background: var(--paper);
}

.section-head {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1.5rem;
	margin-bottom: clamp(2rem, 4vw, 3rem);
}

.section-head h2 {
	margin: 0;
	max-width: 22ch;
}

.section-note {
	margin: 0;
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.8125rem;
	letter-spacing: 0.02em;
}

.eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 0.6rem;
	margin: 0 0 0.9rem;
	color: var(--teal);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	font-weight: 500;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

/* A tiny banded chromosome segment marks every eyebrow. */
.eyebrow::before {
	content: "";
	width: 26px;
	height: 6px;
	border-radius: 3px;
	background: linear-gradient(90deg, currentColor 0 22%, transparent 22% 34%, currentColor 34% 48%, var(--blood) 48% 62%, currentColor 62% 100%);
	opacity: 0.9;
}

.eyebrow--light {
	color: var(--bright);
}

.eyebrow--light::before {
	background: linear-gradient(90deg, currentColor 0 22%, transparent 22% 34%, currentColor 34% 48%, var(--blood-bright) 48% 62%, currentColor 62% 100%);
}

.lead {
	font-size: clamp(1.125rem, 1.6vw, 1.3rem);
	line-height: 1.55;
	color: var(--ink-soft);
}

.band-rule {
	height: 6px;
	background: url("../img/band-strip.svg") center / 100% 100% no-repeat;
	opacity: 0.9;
}

.band-rule--dark {
	opacity: 0.55;
}

.genes {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 0 0.1rem;
	font-family: var(--font-mono);
	font-size: 0.8125rem;
	font-weight: 500;
	letter-spacing: 0.02em;
	color: var(--teal);
}

.genes i {
	font-style: italic;
}

/* Buttons and links ----------------------------------------------------- */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.55rem;
	min-height: 48px;
	padding: 0.75rem 1.35rem;
	border: 1.5px solid transparent;
	border-radius: 999px;
	font-family: var(--font-sans);
	font-size: 1rem;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease);
}

.btn .icon {
	transition: transform 0.2s var(--ease);
}

.btn:hover .icon-arrow-right {
	transform: translateX(3px);
}

.btn-primary {
	background: var(--teal);
	color: var(--white);
}

.btn-primary:hover {
	background: var(--deep);
	color: var(--white);
}

.btn-bright {
	background: var(--bright);
	color: var(--deep);
}

.btn-bright:hover {
	background: var(--white);
	color: var(--deep);
}

.btn-outline-light {
	border-color: rgba(255, 255, 255, 0.45);
	color: var(--white);
}

.btn-outline-light:hover {
	border-color: var(--white);
	background: rgba(255, 255, 255, 0.08);
	color: var(--white);
}

.link-arrow {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}

.link-arrow .icon {
	transition: transform 0.2s var(--ease);
}

.link-arrow:hover .icon-arrow-right {
	transform: translateX(3px);
}

/* Header ---------------------------------------------------------------- */

.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background: rgba(255, 255, 255, 0.94);
	backdrop-filter: saturate(1.4) blur(10px);
	-webkit-backdrop-filter: saturate(1.4) blur(10px);
	border-bottom: 1px solid transparent;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.admin-bar .site-header {
	top: 32px;
}

@media (max-width: 782px) {
	.admin-bar .site-header {
		top: 0;
	}
}

.site-header.is-scrolled {
	border-bottom-color: var(--line);
	box-shadow: var(--shadow-sm);
}

.site-header .container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	min-height: var(--header-h);
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 0.75rem;
	color: var(--ink);
	text-decoration: none;
	flex: none;
}

.brand:hover {
	color: var(--ink);
}

.brand-mark {
	width: 40px;
	height: 40px;
}

.brand-text {
	display: flex;
	flex-direction: column;
	line-height: 1.15;
}

.brand-name {
	font-size: 1.125rem;
	font-weight: 700;
	letter-spacing: -0.01em;
}

.brand-tag {
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.6875rem;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.primary-nav .menu {
	display: flex;
	align-items: center;
	gap: 0.25rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.primary-nav a {
	position: relative;
	display: block;
	padding: 0.5rem 0.7rem;
	border-radius: 8px;
	color: var(--ink-soft);
	font-size: 0.96875rem;
	font-weight: 500;
	text-decoration: none;
	transition: color 0.15s, background-color 0.15s;
}

.primary-nav a:hover {
	color: var(--ink);
	background: var(--paper);
}

.primary-nav .current-menu-item > a,
.primary-nav .current-page-ancestor > a,
.primary-nav .current_page_item > a {
	color: var(--teal);
}

.primary-nav .current-menu-item > a::after,
.primary-nav .current-page-ancestor > a::after,
.primary-nav .current_page_item > a::after {
	content: "";
	position: absolute;
	left: 0.7rem;
	right: 0.7rem;
	bottom: 0.15rem;
	height: 2px;
	border-radius: 2px;
	background: currentColor;
}

.primary-nav a.nav-cta {
	margin-left: 0.5rem;
	padding: 0.55rem 1.05rem;
	border-radius: 999px;
	background: var(--deep);
	color: var(--white);
}

.primary-nav a.nav-cta:hover {
	background: var(--teal);
	color: var(--white);
}

.primary-nav a.nav-cta::after {
	display: none;
}

.nav-toggle {
	display: none;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid var(--line);
	border-radius: 10px;
	background: var(--white);
	color: var(--ink);
	cursor: pointer;
}

.nav-toggle .icon {
	width: 22px;
	height: 22px;
}

.nav-toggle .icon-shut,
.nav-toggle[aria-expanded="true"] .icon-open {
	display: none;
}

.nav-toggle[aria-expanded="true"] .icon-shut {
	display: inline-flex;
}

@media (max-width: 1080px) {
	.js .nav-toggle {
		display: inline-flex;
	}

	.js .primary-nav {
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		display: none;
		padding: 0.5rem var(--gutter) 1.5rem;
		background: var(--white);
		border-bottom: 1px solid var(--line);
		box-shadow: var(--shadow);
		max-height: calc(100vh - var(--header-h));
		overflow-y: auto;
	}

	.js .primary-nav.is-open {
		display: block;
	}

	.primary-nav .menu {
		flex-direction: column;
		align-items: stretch;
		gap: 0;
	}

	.primary-nav a {
		padding: 0.85rem 0.25rem;
		border-bottom: 1px solid var(--line);
		border-radius: 0;
		font-size: 1.0625rem;
	}

	.primary-nav a:hover {
		background: none;
	}

	.primary-nav .current-menu-item > a::after,
	.primary-nav .current-page-ancestor > a::after,
	.primary-nav .current_page_item > a::after {
		top: 0.85rem;
		bottom: 0.85rem;
		left: -0.75rem;
		right: auto;
		width: 3px;
		height: auto;
	}

	.primary-nav a.nav-cta {
		margin: 1rem 0 0;
		padding: 0.85rem 1rem;
		text-align: center;
		border-bottom: 0;
	}

	.no-js .primary-nav .menu {
		flex-direction: row;
		flex-wrap: wrap;
	}
}

@media (max-width: 1180px) and (min-width: 1081px) {
	.brand-tag {
		display: none;
	}
}

@media (max-width: 420px) {
	.brand-tag {
		display: none;
	}
}

/* Home hero ------------------------------------------------------------- */

.hero {
	position: relative;
	overflow: hidden;
	background:
		radial-gradient(60rem 30rem at 85% 10%, rgba(47, 196, 173, 0.16), transparent 60%),
		radial-gradient(40rem 30rem at 0% 100%, rgba(11, 116, 104, 0.35), transparent 60%),
		var(--deep);
	color: var(--white);
}

.hero::after {
	content: "";
	position: absolute;
	inset: 0;
	background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
	background-size: 22px 22px;
	mask-image: linear-gradient(90deg, transparent 0%, #000 55%, #000 100%);
	-webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 55%, #000 100%);
	pointer-events: none;
}

.hero-grid {
	position: relative;
	z-index: 1;
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
	gap: clamp(2rem, 5vw, 4rem);
	align-items: center;
	padding-top: clamp(3.5rem, 7vw, 6rem);
	padding-bottom: clamp(3.5rem, 7vw, 6rem);
}

.hero h1 {
	color: var(--white);
	font-size: clamp(2.5rem, 5.4vw, 4.25rem);
	line-height: 1.04;
	letter-spacing: -0.03em;
	margin-bottom: 1.5rem;
}

.hero h1 em {
	display: block;
	margin-top: 0.15em;
	color: var(--bright);
	font-family: var(--font-serif);
	font-weight: 400;
	letter-spacing: -0.015em;
}

.hero-lead {
	max-width: 36rem;
	color: rgba(255, 255, 255, 0.82);
	font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
	line-height: 1.6;
	margin-bottom: 2rem;
}

.hero-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
}

.hero-art {
	display: flex;
	justify-content: center;
}

.karyogram {
	width: 100%;
	max-width: 540px;
	height: auto;
	overflow: visible;
}

.karyogram .k0 { fill: rgba(255, 255, 255, 0.1); }
.karyogram .k1 { fill: rgba(47, 196, 173, 0.3); }
.karyogram .k2 { fill: rgba(47, 196, 173, 0.5); }
.karyogram .k3 { fill: rgba(47, 196, 173, 0.72); }
.karyogram .k4 { fill: #2fc4ad; }
.karyogram .kv { fill: rgba(47, 196, 173, 0.6); }
.karyogram .ks { fill: rgba(255, 255, 255, 0.05); }
.karyogram .kc { fill: rgba(255, 255, 255, 0.35); }

.karyogram .k-outline {
	fill: none;
	stroke: rgba(255, 255, 255, 0.22);
	stroke-width: 1;
}

.karyogram .k-hit-band {
	fill: var(--blood-bright);
}

.karyogram .k-lead {
	stroke: var(--blood-bright);
	stroke-width: 1;
}

.karyogram .k-gene {
	fill: var(--white);
	font-family: var(--font-mono);
	font-size: 11.5px;
	font-style: italic;
	font-weight: 500;
}

.karyogram .k-band {
	fill: #8fdccf;
	font-family: var(--font-mono);
	font-size: 10px;
}

.karyogram .k-num {
	fill: rgba(255, 255, 255, 0.5);
	font-family: var(--font-mono);
	font-size: 11px;
}

@media (prefers-reduced-motion: no-preference) {
	.js .karyogram .k-chrom {
		opacity: 0;
		transform: translateY(14px);
		animation: k-rise 0.9s var(--ease) forwards;
		animation-delay: calc(var(--i) * 90ms + 150ms);
	}

	.js .karyogram .k-hit {
		opacity: 0;
		animation: k-fade 0.6s var(--ease) forwards;
		animation-delay: calc(var(--i) * 90ms + 900ms);
	}

	.karyogram .k-hit-band {
		animation: k-pulse 3.2s ease-in-out infinite;
		animation-delay: calc(var(--i) * 0.4s + 1.6s);
	}
}

@keyframes k-rise {
	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes k-fade {
	to {
		opacity: 1;
	}
}

@keyframes k-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.55; }
}

/* Inner page hero ------------------------------------------------------- */

.page-hero {
	position: relative;
	background:
		radial-gradient(50rem 22rem at 100% 0%, rgba(47, 196, 173, 0.12), transparent 60%),
		var(--paper);
}

.page-hero .container {
	padding-top: clamp(2.5rem, 5vw, 4rem);
	padding-bottom: clamp(2.25rem, 4.5vw, 3.5rem);
}

.page-hero h1 {
	max-width: 20ch;
	margin-bottom: 0.4em;
}

.page-hero .lead {
	max-width: 46rem;
	margin: 0;
}

.crumbs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
	margin: 0 0 1.25rem;
	padding: 0;
	list-style: none;
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.crumbs li + li::before {
	content: "/";
	margin-right: 0.35rem;
	color: var(--line);
}

.crumbs a {
	color: var(--muted);
	text-decoration: none;
}

.crumbs a:hover {
	color: var(--teal);
}

.crumbs [aria-current] {
	color: var(--teal);
}

/* About (home) ---------------------------------------------------------- */

.about-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
	gap: clamp(2rem, 6vw, 5rem);
	align-items: center;
}

.about-copy h2 {
	max-width: 18ch;
}

.about-copy p {
	color: var(--ink-soft);
}

.about-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.75rem;
	margin-top: 1.5rem;
}

.about-photo {
	position: relative;
	margin: 0;
}

.about-photo img {
	width: 100%;
	aspect-ratio: 3 / 2;
	object-fit: cover;
	border-radius: var(--radius);
	box-shadow: var(--shadow);
}

.about-photo::before {
	content: "";
	position: absolute;
	z-index: -1;
	left: -14px;
	top: -14px;
	width: 55%;
	height: 60%;
	border-radius: var(--radius);
	background: var(--mint);
}

.about-photo figcaption {
	margin-top: 0.75rem;
	color: var(--muted);
	font-size: 0.875rem;
}

/* Program cards (home) -------------------------------------------------- */

.program-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1.25rem;
}

.program-card {
	position: relative;
	display: flex;
	flex-direction: column;
	padding: 1.75rem 1.5rem 1.5rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
	color: var(--ink);
	text-decoration: none;
	transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s;
}

.program-card::before {
	content: "";
	position: absolute;
	top: 0;
	left: 1.5rem;
	right: 1.5rem;
	height: 3px;
	border-radius: 0 0 3px 3px;
	background: linear-gradient(90deg, var(--teal) 0 30%, var(--mint) 30% 42%, var(--teal-mid) 42% 58%, var(--blood) 58% 66%, var(--teal) 66% 100%);
	transform: scaleX(0.25);
	transform-origin: left;
	transition: transform 0.35s var(--ease);
}

.program-card:hover {
	color: var(--ink);
	border-color: transparent;
	box-shadow: var(--shadow);
	transform: translateY(-3px);
}

.program-card:hover::before {
	transform: none;
}

.program-num {
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	margin-bottom: 1.5rem;
}

.program-card h3 {
	margin: 0.5rem 0 0.6rem;
	font-size: 1.1875rem;
}

.program-card p {
	color: var(--ink-soft);
	font-size: 0.96875rem;
	line-height: 1.55;
}

.program-more {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	margin-top: auto;
	padding-top: 0.5rem;
	color: var(--teal);
	font-weight: 600;
	font-size: 0.9375rem;
}

/* Participate band (home) ----------------------------------------------- */

.join {
	position: relative;
	overflow: hidden;
	padding: clamp(3.5rem, 7vw, 5rem) 0;
	background: var(--deep);
	color: rgba(255, 255, 255, 0.85);
}

.join::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 6px;
	background: url("../img/band-strip.svg") center / 100% 100% no-repeat;
	opacity: 0.7;
}

.join-grid {
	display: grid;
	grid-template-columns: minmax(0, 1.3fr) auto;
	gap: 2rem 4rem;
	align-items: center;
}

.join h2 {
	color: var(--white);
	max-width: 22ch;
}

.join p {
	max-width: 44rem;
	margin: 0;
	font-size: 1.0625rem;
}

.join-actions {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

/* PI ------------------------------------------------------------------- */

.pi-feature,
.pi-profile {
	display: grid;
	grid-template-columns: minmax(0, 0.42fr) minmax(0, 1fr);
	gap: clamp(2rem, 5vw, 4.5rem);
	align-items: center;
}

.pi-profile {
	align-items: start;
}

.pi-photo {
	position: relative;
	margin: 0;
}

.pi-photo img,
.pi-photo .initials {
	width: 100%;
	aspect-ratio: 4 / 5;
	object-fit: cover;
	border-radius: var(--radius);
	box-shadow: var(--shadow);
}

.pi-photo::after {
	content: "";
	position: absolute;
	left: -14px;
	top: 18%;
	bottom: 18%;
	width: 6px;
	border-radius: 3px;
	background: linear-gradient(180deg, var(--teal) 0 20%, var(--mint) 20% 30%, var(--teal-mid) 30% 52%, var(--blood) 52% 60%, var(--teal) 60% 100%);
}

.pi-profile .pi-photo {
	position: sticky;
	top: calc(var(--header-h) + 2rem);
}

.pi-copy h2 {
	margin-bottom: 0.75rem;
}

.credentials {
	display: block;
	margin-top: 0.35rem;
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.875rem;
	font-weight: 500;
	letter-spacing: 0.02em;
}

.appointments {
	margin: 0 0 1.5rem;
	padding: 0;
	list-style: none;
	border-top: 1px solid var(--line);
}

.appointments li {
	padding: 0.6rem 0 0.6rem 1.25rem;
	border-bottom: 1px solid var(--line);
	position: relative;
	color: var(--ink-soft);
	font-size: 0.96875rem;
}

.appointments li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 1.05rem;
	width: 8px;
	height: 8px;
	border-radius: 2px;
	background: var(--bright);
}

.pi-feature .pi-copy > p {
	color: var(--ink-soft);
	margin-bottom: 1.75rem;
}

/* People --------------------------------------------------------------- */

.person-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 1.5rem;
}

.person-card {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.person-photo {
	position: relative;
	aspect-ratio: 4 / 4.2;
	background: var(--mint);
	overflow: hidden;
}

.person-photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 25%;
	transition: transform 0.6s var(--ease);
}

.person-card:hover .person-photo img {
	transform: scale(1.03);
}

.initials {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	background:
		repeating-linear-gradient(90deg, transparent 0 18px, rgba(11, 116, 104, 0.06) 18px 26px),
		var(--mint);
	color: var(--teal);
	font-size: clamp(2.5rem, 5vw, 3.5rem);
	font-weight: 600;
	letter-spacing: 0.02em;
}

.person-body {
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: 1.25rem 1.35rem 1.4rem;
}

.person-body h3 {
	margin: 0 0 0.2rem;
	font-size: 1.125rem;
}

.person-role {
	margin: 0 0 0.85rem;
	color: var(--teal);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	font-weight: 500;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.person-bio {
	color: var(--ink-soft);
	font-size: 0.9375rem;
	line-height: 1.6;
}

.person-bio p {
	margin-bottom: 0.75em;
}

.person-bio p:last-child {
	margin-bottom: 0;
}

.js .person-bio.is-clamped:not(.is-open) {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 5;
	overflow: hidden;
}

.js .person-bio.is-clamped:not(.is-open) p {
	display: inline;
}

.js .person-bio.is-clamped:not(.is-open) p + p::before {
	content: " ";
}

.bio-toggle {
	display: none;
	align-items: center;
	gap: 0.3rem;
	align-self: flex-start;
	margin-top: 0.6rem;
	padding: 0.25rem 0;
	border: 0;
	background: none;
	color: var(--teal);
	font: inherit;
	font-size: 0.875rem;
	font-weight: 600;
	cursor: pointer;
}

.js .bio-toggle {
	display: inline-flex;
}

.bio-toggle .icon {
	transition: transform 0.2s;
}

.bio-toggle[aria-expanded="true"] .icon {
	transform: rotate(180deg);
}

.bio-toggle .when-open,
.bio-toggle[aria-expanded="true"] .when-closed {
	display: none;
}

.bio-toggle[aria-expanded="true"] .when-open {
	display: inline;
}

.person-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1rem;
	margin: auto 0 0;
	padding-top: 1rem;
	font-size: 0.875rem;
	font-weight: 600;
}

.person-links a {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	text-decoration: none;
}

.person-grid--collab .person-photo {
	aspect-ratio: 1;
}

.person-grid--collab .person-role {
	color: var(--muted);
	font-family: var(--font-sans);
	font-size: 0.875rem;
	letter-spacing: 0;
	line-height: 1.45;
	text-transform: none;
}

/* Alumni ---------------------------------------------------------------- */

.alumni-list {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 0 2rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.alumni-list li {
	padding: 1.1rem 0;
	border-top: 1px solid var(--line);
	break-inside: avoid;
}

.alumni-list p {
	margin: 0;
}

.alum-name {
	font-weight: 600;
}

.alum-role {
	color: var(--ink-soft);
	font-size: 0.9375rem;
}

.alum-years {
	margin-left: 0.35rem;
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	white-space: nowrap;
}

.alum-now {
	margin-top: 0.3rem !important;
	color: var(--muted);
	font-size: 0.875rem;
	font-style: italic;
}

/* Research page --------------------------------------------------------- */

.research-layout,
.pubs-layout {
	display: grid;
	grid-template-columns: 260px minmax(0, 1fr);
	gap: clamp(2rem, 5vw, 4.5rem);
	align-items: start;
}

.pubs-layout {
	grid-template-columns: minmax(0, 1fr) 260px;
}

.research-toc,
.pubs-aside {
	position: sticky;
	top: calc(var(--header-h) + 2rem);
}

.toc-title {
	margin: 0 0 0.75rem;
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.75rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.research-toc ol {
	margin: 0 0 2rem;
	padding: 0;
	list-style: none;
	border-left: 2px solid var(--line);
	counter-reset: toc;
}

.research-toc li {
	counter-increment: toc;
}

.research-toc ol a {
	display: flex;
	gap: 0.6rem;
	margin-left: -2px;
	padding: 0.55rem 0 0.55rem 1rem;
	border-left: 2px solid transparent;
	color: var(--ink-soft);
	font-size: 0.9375rem;
	line-height: 1.4;
	text-decoration: none;
	transition: color 0.15s, border-color 0.15s;
}

.research-toc ol a::before {
	content: counter(toc, decimal-leading-zero);
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.75rem;
	padding-top: 0.15rem;
}

.research-toc ol a:hover,
.research-toc ol a.is-active {
	color: var(--teal);
	border-left-color: var(--teal);
}

.toc-cta {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 1rem 1.1rem;
	border-radius: var(--radius-sm);
	background: var(--deep);
	color: var(--white);
	font-weight: 600;
	font-size: 0.9375rem;
	line-height: 1.35;
	text-decoration: none;
}

.toc-cta:hover {
	background: var(--teal);
	color: var(--white);
}

.toc-cta .icon {
	width: 1.5em;
	height: 1.5em;
	color: var(--bright);
}

.research-intro {
	margin-bottom: 2.5rem;
}

.program {
	padding: 2.5rem 0 3rem;
	border-top: 1px solid var(--line);
}

.program:first-of-type {
	border-top: 0;
	padding-top: 0;
}

.program-head {
	margin-bottom: 1.75rem;
}

.program-head .program-num {
	display: inline-block;
	margin: 0 0.75rem 0 0;
	padding: 0.15rem 0.5rem;
	border-radius: 6px;
	background: var(--mint);
	color: var(--teal);
}

.program-head h2 {
	margin: 0.6rem 0 0.75rem;
}

.program-head .lead {
	margin: 0;
	max-width: 44rem;
}

/* Publications ---------------------------------------------------------- */

.pubs-intro {
	margin-bottom: 2rem;
}

.pubs-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem 1.5rem;
	margin-bottom: 2rem;
	padding-bottom: 1.5rem;
	border-bottom: 1px solid var(--line);
}

.pubs-search {
	position: relative;
	flex: 1 1 320px;
	max-width: 560px;
}

.pubs-search .icon {
	position: absolute;
	left: 1rem;
	top: 50%;
	transform: translateY(-50%);
	color: var(--muted);
}

.pubs-search input {
	width: 100%;
	min-height: 50px;
	padding: 0.75rem 1rem 0.75rem 2.75rem;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--paper);
	color: var(--ink);
	font: inherit;
	font-size: 1rem;
	transition: border-color 0.15s, background-color 0.15s;
}

.pubs-search input:focus {
	outline: none;
	border-color: var(--teal);
	background: var(--white);
	box-shadow: 0 0 0 4px rgba(47, 196, 173, 0.18);
}

.pubs-count {
	margin: 0;
	color: var(--muted);
	font-family: var(--font-mono);
	font-size: 0.8125rem;
}

.pubs-year {
	display: grid;
	grid-template-columns: 5.5rem minmax(0, 1fr);
	gap: 1.5rem;
	padding: 1.75rem 0;
	border-top: 1px solid var(--line);
}

.pubs-year:first-of-type {
	border-top: 0;
	padding-top: 0;
}

.pubs-year h2 {
	position: sticky;
	top: calc(var(--header-h) + 1.5rem);
	align-self: start;
	margin: 0;
	color: var(--teal);
	font-family: var(--font-mono);
	font-size: 1.375rem;
	font-weight: 500;
	letter-spacing: 0;
}

.paper-list,
.paper-cards {
	margin: 0;
	padding: 0;
	list-style: none;
}

.paper-list > li + li {
	margin-top: 1.5rem;
	padding-top: 1.5rem;
	border-top: 1px dashed var(--line);
}

.paper p {
	margin: 0;
}

.paper-year {
	margin-bottom: 0.6rem !important;
	color: var(--teal);
	font-family: var(--font-mono);
	font-size: 0.8125rem;
}

.paper-title {
	text-wrap: pretty;
	margin: 0 0 0.4rem;
	font-size: 1.0625rem;
	line-height: 1.4;
	letter-spacing: -0.005em;
}

.paper-title a {
	color: var(--ink);
	text-decoration: none;
	background-image: linear-gradient(var(--bright), var(--bright));
	background-size: 0 2px;
	background-position: 0 100%;
	background-repeat: no-repeat;
	transition: background-size 0.3s var(--ease), color 0.15s;
}

.paper-title a:hover {
	color: var(--teal);
	background-size: 100% 2px;
}

.paper-title .icon {
	display: inline-block;
	width: 0.9em;
	height: 0.9em;
	margin-left: 0.25em;
	vertical-align: -0.05em;
	color: var(--muted);
}

.paper-cite {
	color: var(--muted);
	font-size: 0.90625rem;
	line-height: 1.55;
}

.paper-cite strong {
	color: var(--ink);
	font-weight: 600;
}

.paper-doi {
	margin-top: 0.35rem !important;
	font-family: var(--font-mono);
	font-size: 0.78rem;
}

.paper-doi a {
	color: var(--muted);
	word-break: break-all;
}

.paper-cards {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1.25rem;
}

.paper-cards > li {
	padding: 1.5rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.pubs-empty {
	padding: 2rem 0;
	color: var(--muted);
}

.year-nav ul {
	display: flex;
	flex-wrap: wrap;
	gap: 0.4rem;
	margin: 0 0 2rem;
	padding: 0;
	list-style: none;
}

.year-nav a {
	display: inline-block;
	padding: 0.3rem 0.65rem;
	border: 1px solid var(--line);
	border-radius: 999px;
	color: var(--ink-soft);
	font-family: var(--font-mono);
	font-size: 0.8125rem;
	text-decoration: none;
}

.year-nav a:hover {
	border-color: var(--teal);
	color: var(--teal);
}

.aside-card {
	padding: 1.25rem 1.35rem;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	background: var(--paper);
}

.aside-card + .aside-card {
	margin-top: 1rem;
}

.aside-card p {
	margin-bottom: 0.5rem;
}

.aside-card p:last-child {
	margin-bottom: 0;
}

.aside-strong {
	font-weight: 600;
	line-height: 1.35;
}

.aside-card address {
	margin-bottom: 0.75rem;
	color: var(--ink-soft);
	font-size: 0.9375rem;
}

.aside-links {
	margin: 0;
	padding: 0;
	list-style: none;
}

.aside-links li + li {
	margin-top: 0.6rem;
}

.aside-links a {
	display: inline-flex;
	align-items: flex-start;
	gap: 0.5rem;
	font-size: 0.9375rem;
	font-weight: 500;
	line-height: 1.35;
	text-decoration: none;
}

.aside-links .icon {
	margin-top: 0.1em;
}

/* Sites ---------------------------------------------------------------- */

.site-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1.25rem;
}

.site-card {
	display: grid;
	grid-template-columns: 94px minmax(0, 1fr);
	gap: 1.5rem;
	padding: 1.75rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.site-logo {
	width: 94px;
	height: auto;
	border-radius: 10px;
}

.site-short {
	margin: 0 0 0.25rem;
	color: var(--teal);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	letter-spacing: 0.06em;
}

.site-card h3 {
	font-size: 1.125rem;
	line-height: 1.3;
	margin-bottom: 0.6rem;
}

.site-card address {
	color: var(--ink-soft);
	font-size: 0.9375rem;
	margin-bottom: 1rem;
}

.site-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.25rem;
	margin: 0;
	font-size: 0.9375rem;
	font-weight: 600;
}

.site-links a {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	text-decoration: none;
}

/* Contact -------------------------------------------------------------- */

.contact-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 340px;
	gap: clamp(2rem, 5vw, 4rem);
	align-items: start;
}

.contact-form-card {
	padding: clamp(1.5rem, 4vw, 2.5rem);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
	box-shadow: var(--shadow);
}

.contact-email {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-weight: 600;
	word-break: break-all;
}

/* Prose (page content) -------------------------------------------------- */

.prose {
	max-width: 46rem;
}

.prose > :first-child {
	margin-top: 0;
}

.prose h2 {
	margin-top: 2.25rem;
	font-size: clamp(1.5rem, 2.4vw, 1.875rem);
}

.prose h3 {
	margin-top: 2rem;
	font-size: 1.25rem;
}

.prose p,
.prose li {
	color: var(--ink-soft);
}

.prose ul,
.prose ol {
	padding-left: 1.25rem;
	margin: 0 0 1.25em;
}

.prose li + li {
	margin-top: 0.4em;
}

.entry-content--wide {
	max-width: none;
}

/* Default pages: text stays at reading width, grids and media use the full container. */
.prose--flow {
	max-width: none;
}

.prose--flow > * {
	max-width: 46rem;
}

.prose--flow > .fl-video-grid,
.prose--flow > .fl-grid,
.prose--flow > .wp-block-gallery,
.prose--flow > .alignwide,
.prose--flow > .alignfull {
	max-width: none;
}

/* Contact Form 7 -------------------------------------------------------- */

.wpcf7 form p {
	margin-bottom: 1.25rem;
}

.wpcf7 label {
	display: block;
	color: var(--ink);
	font-size: 0.9375rem;
	font-weight: 600;
}

.wpcf7 .wpcf7-form-control-wrap {
	display: block;
	margin-top: 0.4rem;
}

.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 select,
.wpcf7 textarea {
	width: 100%;
	min-height: 50px;
	padding: 0.75rem 1rem;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	background: var(--paper);
	color: var(--ink);
	font: inherit;
	font-weight: 400;
	transition: border-color 0.15s, background-color 0.15s, box-shadow 0.15s;
}

.wpcf7 textarea {
	min-height: 170px;
	resize: vertical;
}

.wpcf7 input:focus,
.wpcf7 select:focus,
.wpcf7 textarea:focus {
	outline: none;
	border-color: var(--teal);
	background: var(--white);
	box-shadow: 0 0 0 4px rgba(47, 196, 173, 0.18);
}

.wpcf7 .form-row {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0 1rem;
}

.wpcf7 .form-row--3 {
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.wpcf7 input[type="submit"] {
	display: inline-flex;
	min-height: 50px;
	padding: 0.8rem 1.6rem;
	border: 0;
	border-radius: 999px;
	background: var(--teal);
	color: var(--white);
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 0.2s;
}

.wpcf7 input[type="submit"]:hover {
	background: var(--deep);
}

.wpcf7 .wpcf7-spinner {
	vertical-align: middle;
}

.wpcf7-not-valid-tip {
	margin-top: 0.35rem;
	color: var(--blood);
	font-size: 0.875rem;
	font-weight: 500;
}

.wpcf7 form .wpcf7-response-output {
	margin: 1.25rem 0 0;
	padding: 0.9rem 1.1rem;
	border-radius: var(--radius-sm);
	font-size: 0.9375rem;
}

.form-note {
	color: var(--muted);
	font-size: 0.875rem;
}

/* Footer ---------------------------------------------------------------- */

.site-footer {
	background: var(--deep);
	color: rgba(255, 255, 255, 0.72);
	font-size: 0.9375rem;
}

.site-footer .container {
	padding-top: clamp(3rem, 6vw, 4.5rem);
}

.footer-grid {
	display: grid;
	grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
	gap: 2.5rem;
	padding-bottom: 3rem;
}

.footer-brand img {
	width: 44px;
	height: 44px;
	margin-bottom: 1rem;
}

.footer-name {
	margin-bottom: 0.5rem;
	color: var(--white);
	font-size: 1.125rem;
	font-weight: 700;
}

.footer-brand p {
	max-width: 30rem;
}

.site-footer h2 {
	margin: 0 0 0.9rem;
	color: var(--bright);
	font-family: var(--font-mono);
	font-size: 0.78rem;
	font-weight: 500;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.site-footer a {
	color: var(--white);
	text-decoration: none;
}

.site-footer a:hover {
	color: var(--bright);
}

.footer-email a {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-weight: 500;
	word-break: break-all;
}

.footer-site address {
	margin-bottom: 0.75rem;
}

.footer-directions {
	display: inline-flex;
	align-items: center;
	gap: 0.3rem;
	font-weight: 500;
}

.footer-menu {
	margin: 0;
	padding: 0;
	list-style: none;
}

.footer-menu li + li {
	margin-top: 0.4rem;
}

.footer-bottom {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.5rem 2rem;
	padding: 1.5rem 0 2rem;
	border-top: 1px solid var(--line-dark);
	font-size: 0.8125rem;
}

.footer-bottom p {
	margin: 0;
}

/* Reveal on scroll ------------------------------------------------------ */

@media (prefers-reduced-motion: no-preference) {
	.js .reveal {
		opacity: 0;
		transform: translateY(18px);
		transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
	}

	.js .reveal.is-visible {
		opacity: 1;
		transform: none;
	}
}

/* Responsive ------------------------------------------------------------ */

@media (max-width: 1080px) {
	.program-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.footer-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.alumni-list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 900px) {
	.hero-grid,
	.about-grid,
	.join-grid,
	.pi-feature,
	.pi-profile,
	.research-layout,
	.pubs-layout,
	.contact-layout {
		grid-template-columns: minmax(0, 1fr);
	}

	.hero-art {
		order: 2;
	}

	.karyogram {
		max-width: 460px;
	}

	.join-actions {
		flex-direction: row;
		flex-wrap: wrap;
	}

	.pi-feature .pi-photo,
	.pi-profile .pi-photo {
		position: relative;
		top: auto;
		max-width: 320px;
	}

	.research-toc,
	.pubs-aside {
		position: static;
	}

	.research-toc ol {
		margin-bottom: 1.5rem;
	}

	.pubs-aside {
		order: -1;
	}

	.pubs-aside .aside-card {
		display: none;
	}

	.year-nav ul {
		margin-bottom: 0;
	}

	.site-grid,
	.paper-cards {
		grid-template-columns: minmax(0, 1fr);
	}

	.section-head {
		flex-direction: column;
		align-items: flex-start;
	}
}

@media (max-width: 640px) {
	body {
		font-size: 1rem;
	}

	.program-grid,
	.alumni-list,
	.footer-grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.pubs-year {
		grid-template-columns: minmax(0, 1fr);
		gap: 0.75rem;
	}

	.pubs-year h2 {
		position: static;
	}

	.site-card {
		grid-template-columns: minmax(0, 1fr);
		gap: 1rem;
	}

	.site-logo {
		width: 72px;
	}

	.wpcf7 .form-row,
	.wpcf7 .form-row--3 {
		grid-template-columns: minmax(0, 1fr);
	}

	.hero-actions .btn,
	.join-actions .btn {
		width: 100%;
	}

	.about-photo::before {
		left: -8px;
		top: -8px;
	}
}

/* Print ---------------------------------------------------------------- */

@media print {
	.site-header,
	.site-footer,
	.hero-art,
	.research-toc,
	.pubs-aside,
	.pubs-toolbar,
	.bio-toggle {
		display: none !important;
	}

	.hero {
		background: none;
		color: var(--ink);
	}

	.hero h1 {
		color: var(--ink);
	}

	.js .reveal {
		opacity: 1 !important;
		transform: none !important;
	}

	.js .person-bio.is-clamped:not(.is-open) {
		display: block;
		-webkit-line-clamp: unset;
	}
}
