/* Base tokens */
:root{
	/* Palette: minimalist neutrals */
	--bg: #FAFAFA;
	--surface: #FFFFFF;
	--surface-alt: #F4F4F4;
	--text: #1A1A1A;
	--muted: #6B6B6B;
	--border: #E5E5E5;
	--border-strong: #CCCCCC;

	--link: #1A1A1A;
	--link-hover: #000000;
	--link-visited: #5A5A5A;

	--focus: #1A1A1A;
	--focus-shadow: rgba(0,0,0,0.12);

	/* Typography: thin web-safe headers + matching body */
	--font-header: "Helvetica Neue", "HelveticaNeue", Helvetica, Arial, sans-serif;
	--font-body: "Helvetica Neue", "HelveticaNeue", Helvetica, Arial, sans-serif;
	--font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

	--fs-0: clamp(16px, 0.95vw + 12px, 18px);
	--fs-1: clamp(18px, 1.2vw + 12px, 22px);
	--fs-2: clamp(28px, 2.6vw + 14px, 48px);
	--fs-3: clamp(34px, 3.2vw + 16px, 60px);

	--lh: 1.7;
	--lh-tight: 1.15;

	/* Spacing */
	--s-1: 0.25rem;
	--s-2: 0.5rem;
	--s-3: 0.75rem;
	--s-4: 1rem;
	--s-5: 1.25rem;
	--s-6: 1.5rem;
	--s-8: 2rem;
	--s-10: 2.5rem;
	--s-12: 3rem;

	--radius-sm: 2px;

	/* Layout */
	--page-max: 1200px;
	--gutter: clamp(20px, 3vw, 40px);
	--nav-h: 60px;
}

*{ box-sizing: border-box; }

html{
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--nav-h) + 16px);
}

body{
	margin: 0;
	font-family: var(--font-body);
	font-size: var(--fs-0);
	font-weight: 400;
	line-height: var(--lh);
	color: var(--text);
	background: var(--bg);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

img{
	max-width: 100%;
	height: auto;
}

p{
	margin: 0 0 var(--s-5) 0;
}

h1, h2, h3{
	font-family: var(--font-header);
	color: var(--text);
	line-height: var(--lh-tight);
	letter-spacing: -0.02em;
	margin: 0 0 var(--s-4) 0;
}

h1{
	font-size: var(--fs-3);
	font-weight: 200;
	letter-spacing: -0.035em;
}

h2{
	font-size: var(--fs-2);
	font-weight: 100;
	letter-spacing: -0.03em;
	margin-bottom: var(--s-6);
}

h3{
	font-size: var(--fs-1);
	font-weight: 300;
	letter-spacing: -0.015em;
	margin-top: var(--s-6);
	margin-bottom: var(--s-3);
}

a{
	color: var(--link);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
	text-decoration-color: var(--border-strong);
	transition: color 160ms ease, text-decoration-color 160ms ease;
}

a:hover{
	color: var(--link-hover);
	text-decoration-color: currentColor;
}

a:visited{
	color: var(--link-visited);
}

a:focus-visible{
	outline: 2px solid var(--focus);
	outline-offset: 3px;
	box-shadow: 0 0 0 4px var(--focus-shadow);
	border-radius: var(--radius-sm);
}

abbr[title]{
	text-decoration: underline dotted;
	text-underline-offset: 3px;
	text-decoration-thickness: 1px;
	cursor: help;
}

/* Skip link */
.skip-link{
	position: fixed;
	top: 8px;
	left: 8px;
	z-index: 1000;
	padding: var(--s-2) var(--s-4);
	background: var(--text);
	color: var(--surface);
	text-decoration: none;
	border-radius: var(--radius-sm);
	transform: translateY(-150%);
	transition: transform 160ms ease;
}

.skip-link:focus,
.skip-link:focus-visible{
	transform: translateY(0);
	outline: 2px solid var(--focus);
	outline-offset: 2px;
	color: var(--surface);
}

/* Layout */
div#Page{
	display: flow-root;
	max-width: var(--page-max);
	margin-left: auto;
	margin-right: auto;
	padding: var(--gutter);
}

#Menu{
	width: 100%;
}

#ContactInformation{
	float: right;
	width: 30%;
	padding: 0;
}

#Content{
	float: left;
	width: 64%;
}

/* Content blocks: flat sections with thin top rule */
.ContentBlock{
	background: transparent;
	border: 0;
	border-top: 1px solid var(--border);
	border-radius: 0;
	margin-bottom: var(--s-10);
	padding: var(--s-8) 0 0 0;
}

.ContentBlock:first-of-type{
	border-top: 0;
	padding-top: var(--s-6);
}

#ContactInformation.ContentBlock{
	padding: 0;
	border-top: 0;
	overflow: hidden;
}

#ContactInformation div.Title,
div.Contact,
ul.Contact{
	display: block;
	list-style: none;
	margin: var(--s-5) 0 0 0;
	padding: 0;
	color: var(--muted);
	font-weight: 400;
}

#ContactInformation div.Title{
	color: var(--text);
	font-weight: 500;
}

#ContactInformation .Title a{
	color: var(--text);
	text-decoration-color: var(--border-strong);
}

#ContactInformation .Title a:hover{
	color: var(--link-hover);
	text-decoration-color: currentColor;
}

ul.Contact{
	padding-bottom: var(--s-6);
}

ul.Contact li{
	margin: 0 0 var(--s-2) 0;
}

#Footer{
	float: none;
	clear: both;
	max-width: var(--page-max);
	margin: 0 auto;
	padding: var(--s-8) var(--gutter) var(--s-10);
	color: var(--muted);
	font-size: 0.92rem;
	font-weight: 400;
	border-top: 1px solid var(--border);
}

/* Name / Photo (sidebar header) */
div#NameAndPhoto{
	position: relative;
	margin: 0;
	padding: 0;
	display: block;
}

div.Photo{
	position: relative;
	z-index: 1;
}

div.Photo img{
	width: 100%;
	display: block;
	filter: grayscale(15%);
}

div#Name{
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 2;
	width: 100%;
	background: rgba(0, 0, 0, 0.55);
	padding: var(--s-4);
	box-sizing: border-box;
}

div#Name h1{
	color: #FFFFFF;
	margin: 0;
	font-family: "Helvetica Neue", "HelveticaNeue", Helvetica, Arial, sans-serif;
	font-size: clamp(20px, 2.6vw, 32px);
	font-weight: 300;
	line-height: 1.15;
	letter-spacing: -0.02em;
	text-shadow: 0 2px 8px rgba(0, 0, 0, 0.55);
}

/* Navigation */
.Navigation{
	position: sticky;
	top: 0;
	z-index: 100;
	overflow: hidden;
	background: var(--surface);
	border: 0;
	border-bottom: 1px solid var(--border);
	border-radius: 0;
	margin-bottom: var(--s-8);
}

.Navigation a{
	float: left;
	display: block;
	color: var(--text);
	text-align: center;
	padding: 18px 18px;
	text-decoration: none;
	font-family: var(--font-header);
	font-size: 14px;
	font-weight: 400;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	border-bottom: 1px solid transparent;
	transition: color 160ms ease, border-color 160ms ease;
}

.Navigation a:hover{
	color: var(--link-hover);
	border-bottom-color: var(--text);
}

.Navigation a:focus-visible{
	outline: 2px solid var(--focus);
	outline-offset: -2px;
	box-shadow: none;
	border-radius: 0;
}

.Navigation a.Active,
.Navigation a.active{
	color: var(--text);
	font-weight: 500;
	border-bottom-color: var(--text);
}

.Navigation .icon{
	display: none;
}

.Navigation button.icon{
	background: none;
	border: 0;
	color: inherit;
	font: inherit;
	cursor: pointer;
	padding: 18px 18px;
}

.Navigation button.icon:focus-visible{
	outline: 2px solid var(--focus);
	outline-offset: -2px;
	box-shadow: none;
}

.Navigation .icon img{
	height: 1em;
	width: auto;
	vertical-align: middle;
	filter: brightness(0);
}

/* Students */
div.StudentGroup ul{
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	gap: clamp(14px, 1.6vw, 22px);
	list-style: none;
	margin: 0;
	padding: 0;
	width: 100%;
}

div.StudentGroup ul li{
	flex: 0 1 calc((100% - 4 * clamp(14px, 1.6vw, 22px)) / 5);
	min-width: 140px;
}

div.StudentGroup ul li div.NameAndPhoto{
	position: relative;
	width: 100%;
	margin-bottom: var(--s-4);
	border-radius: 50%;
}

div.StudentGroup ul li div.NameAndPhoto img{
	border-radius: 50%;
	width: 100%;
	display: block;
	border: 1px solid var(--border);
	filter: grayscale(20%);
	transition: filter 200ms ease;
}

div.StudentGroup ul li div.NameAndPhoto .placeholder{
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	border-radius: 50%;
	background: var(--surface-alt);
	border: 1px solid var(--border);
}

div.StudentGroup ul li div.NameAndPhoto:hover img,
div.StudentGroup ul li div.NameAndPhoto a:hover img{
	filter: grayscale(0%);
}

div.StudentGroup ul li div.NameAndPhoto span.name{
	display: block;
	width: 100%;
	margin-top: var(--s-3);
	padding: 0;
	background: transparent;
	color: var(--text);
	text-align: center;
	font-size: 0.9em;
	font-weight: 400;
	letter-spacing: 0.01em;
	border: 0;
}

div.StudentGroup ul li div.NameAndPhoto a{
	display: block;
	text-decoration: none;
	color: inherit;
	border-radius: 50%;
}

/* Publications year toggle */
div.PublicationYear{
	margin-top: var(--s-6);
}

div.PublicationYear h3{
	user-select: none;
	margin: var(--s-6) 0 var(--s-4) 0;
	font-weight: 300;
}

.YearToggle{
	display: inline-flex;
	align-items: baseline;
	gap: 0.4em;
	background: none;
	border: 0;
	padding: 0;
	margin: 0;
	font: inherit;
	color: inherit;
	cursor: pointer;
	text-align: left;
	letter-spacing: -0.01em;
}

.YearToggle:after{
	content: "+";
	font-weight: 300;
	color: var(--muted);
	font-size: 0.95em;
}

.YearToggle[aria-expanded="true"]:after{
	content: "−";
}

.YearToggle:hover{
	color: var(--link-hover);
}

.YearToggle:hover:after{
	color: var(--text);
}

.YearToggle:focus-visible{
	outline: 2px solid var(--focus);
	outline-offset: 4px;
	border-radius: var(--radius-sm);
}

div.PublicationYear.Collapsed div{
	display: none;
}

/* Bibliography */
.csl-bib-body{
	display: flex;
	flex-direction: column;
	gap: 0;
}

.csl-entry{
	margin: 0;
	padding: var(--s-5) 0;
	border: 0;
	border-bottom: 1px solid var(--border);
	border-radius: 0;
	background: transparent;
	display: flex;
	flex-direction: row;
	gap: var(--s-4);
	align-items: baseline;
}

.csl-entry:last-child{
	border-bottom: 0;
}

.csl-left-margin{
	flex: 0 0 auto;
	min-width: 3ch;
	font-variant-numeric: tabular-nums;
	color: var(--muted);
	font-weight: 500;
	font-size: 0.9em;
}

.csl-right-inline{
	flex: 1 1 auto;
	min-width: 0;
	color: var(--text);
}

.csl-right-inline a{
	word-break: break-word;
	overflow-wrap: anywhere;
}

.csl-right-inline em{
	color: var(--text);
	font-style: italic;
}

.csl-entry:focus-within{
	background: var(--surface-alt);
}

h4.PublicationTitle{
	font-family: var(--font-header);
	font-size: 1em;
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: -0.01em;
	color: var(--text);
	margin: 0 0 var(--s-2) 0;
}

.PublicationMeta{
	margin: var(--s-1) 0 0 0;
	color: var(--muted);
	font-size: 0.92em;
	line-height: 1.5;
}

.PublicationMeta span.date{
	font-variant-numeric: tabular-nums;
	color: var(--muted);
	font-weight: 500;
}

.PublicationMeta span.venue{
	color: var(--text);
	font-style: italic;
}

.PublicationMeta span.names{
	color: var(--text);
	font-weight: 400;
}

.PublicationMeta a.PublicationDoi{
	color: var(--link);
	text-decoration: underline;
	text-decoration-color: var(--border-strong);
	text-underline-offset: 3px;
	word-break: break-word;
	overflow-wrap: anywhere;
}

.PublicationMeta a.PublicationDoi:hover{
	color: var(--link-hover);
	text-decoration-color: currentColor;
}

.BibliographyStatus{
	color: var(--muted);
	font-style: italic;
	margin: var(--s-4) 0;
}

/* Course sections */
div.Course{
	margin-bottom: var(--s-6);
}

div.CourseDetail .Links{
	margin-bottom: var(--s-2);
}

p.Abstract{
	color: var(--text);
}

/* Responsive */
@media screen and (max-width: 900px){
	#ContactInformation{ width: 34%; }
	#Content{ width: 60%; }

	div.StudentGroup ul li{
		flex-basis: calc((100% - 2 * clamp(14px, 1.6vw, 22px)) / 3);
		min-width: 130px;
	}
}

@media screen and (max-width: 600px){
	html{ scroll-padding-top: calc(var(--nav-h) + 10px); }

	div#Page{ padding: var(--s-4); }

	#ContactInformation{
		float: none;
		width: 100%;
	}

	#Content{
		float: none;
		width: 100%;
	}

	.Navigation{
		border-radius: 0;
	}

	.Navigation a{
		padding: 16px 14px;
		font-size: 13px;
	}

	.Navigation a:not(.Active){ display: none; }

	.Navigation .icon{
		float: right;
		display: block;
	}

	.Navigation.responsive{
		position: sticky;
	}

	.Navigation.responsive .icon{
		position: absolute;
		right: 0;
		top: 0;
	}

	.Navigation.responsive a{
		float: none;
		display: block;
		text-align: left;
		padding-left: var(--s-5);
		border-bottom: 1px solid var(--border);
	}

	.Navigation.responsive a.Active,
	.Navigation.responsive a.active{
		border-bottom-color: var(--border);
		box-shadow: inset 3px 0 0 var(--text);
	}

	div.StudentGroup ul{
		flex-direction: column;
	}

	div.StudentGroup ul li{
		width: 100%;
		min-width: 0;
		flex-basis: 100%;
	}

	div.StudentGroup ul li div.NameAndPhoto{
		width: 60%;
		margin-left: auto;
		margin-right: auto;
	}

	div.StudentGroup ul li div.NameAndPhoto span.name{
		font-size: 1em;
	}

	.csl-entry{
		padding: var(--s-4) 0;
	}

	.csl-left-margin{
		min-width: auto;
	}
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
	html{ scroll-behavior: auto; }
	.Navigation a,
	div.StudentGroup ul li div.NameAndPhoto img,
	.skip-link{ transition: none; }
}
