:root {
  color-scheme: light;
  --ink: #202222;
  --paper: #f5f1e8;
  --fire: #e65332;
  --blue: #648c9b;
  --soft: #4e5554;
  --rule: #ccc8be;
  --display: 'Space Grotesk', system-ui, sans-serif;
  font-family: 'DM Sans', system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
img { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .24em; }
a:hover { text-decoration-thickness: .14em; }
a:focus-visible { outline: 2px solid currentColor; outline-offset: 5px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-family: var(--display); line-height: 1.03; letter-spacing: -.055em; }
h2 { font-size: clamp(2.5rem, 5.3vw, 5rem); }
h3 { font-size: clamp(2rem, 3.1vw, 3.15rem); }
.shell { width: min(100% - 2.5rem, 82rem); margin-inline: auto; }
.skip { position: absolute; top: .75rem; left: 1rem; z-index: 2; padding: .65rem; background: var(--paper); transform: translateY(-180%); }
.skip:focus { transform: translateY(0); }
.header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 6.2rem; border-bottom: 1px solid var(--rule); }
.brand { flex: 0 0 auto; }
.brand img { width: 10.2rem; height: auto; }
nav { display: flex; align-items: center; gap: clamp(.8rem, 3.4vw, 3rem); }
nav a { font-size: .95rem; font-weight: 700; text-decoration: none; }
nav a:hover { text-decoration: underline; }
.nav-contact { padding: .48rem .95rem; border: 1px solid var(--ink); }
.hero { display: grid; grid-template-columns: 1.2fr .92fr; align-items: center; gap: clamp(1.5rem, 4vw, 4.5rem); padding-block: clamp(2.75rem, 6vw, 6.5rem); }
.eyebrow { font: 700 .875rem/1.4 var(--display); text-transform: uppercase; letter-spacing: .085em; }
.hero-copy .eyebrow { display: flex; align-items: center; gap: .75rem; }
.brand-line { flex: 0 0 2.4rem; height: .2rem; background: linear-gradient(90deg, var(--blue) 64%, var(--fire) 64%); }
h1 { margin: 1.35rem 0; font-size: clamp(3.05rem, 5.55vw, 5.3rem); }
h1 span { color: #446b7a; }
.intro { max-width: 34ch; font-size: clamp(1.12rem, 1.65vw, 1.38rem); color: var(--soft); }
.button { display: inline-block; margin-top: 1.65rem; padding: .75rem 1.2rem; background: var(--ink); color: var(--paper); text-decoration: none; font-weight: 700; }
.button:hover { background: #39464a; }
.button:focus-visible { outline-color: var(--ink); }
.hero-art { position: relative; isolation: isolate; background: var(--ink); overflow: hidden; }
.hero-art img { width: 100%; height: auto; }
.grid { position: absolute; inset: .85rem; border: 1px solid #ffffff2b; background: linear-gradient(#ffffff10 1px, transparent 1px), linear-gradient(90deg, #ffffff10 1px, transparent 1px); background-size: 12.5% 12.5%; pointer-events: none; }
.grid::before, .grid::after { content: ''; position: absolute; width: 2.5rem; height: 2.5rem; }
.grid::before { inset: -1px auto auto -1px; border-top: 2px solid var(--blue); border-left: 2px solid var(--blue); }
.grid::after { inset: auto -1px -1px auto; border-right: 2px solid var(--fire); border-bottom: 2px solid var(--fire); }
.secondment { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem 1.2rem; border-block: 1px solid var(--rule); padding-block: 1rem; }
.secondment .eyebrow { color: #446b7a; }
.secondment a { font-weight: 700; }
.section { padding-block: clamp(3.5rem, 7.5vw, 7.5rem); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 2rem; }
.section-heading p:last-child:not(.eyebrow) { max-width: 33ch; color: var(--soft); }
.section .eyebrow, .footer .eyebrow { margin-bottom: .7rem; }
.work-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: .75rem; }
.project { display: flex; flex-direction: column; align-items: start; padding: clamp(1.2rem, 2.6vw, 2.5rem); min-height: 19rem; border-top: .25rem solid var(--blue); }
.project p:not(.eyebrow) { margin-block: 1rem 1.5rem; max-width: 40ch; }
.project a { margin-top: auto; }
.featured { background: var(--ink); color: var(--paper); border-color: var(--fire); }
.transport { background: #dce6e7; }
.health { background: #eee3d7; border-color: var(--fire); }
.text-link { font-weight: 700; }
.research { background: #e8e3d9; }
.papers { padding: 0; margin: 0; list-style: none; border-top: 1px solid #bfb9af; }
.papers li { display: grid; grid-template-columns: 4.5rem minmax(0, 1fr); gap: .5rem 1rem; align-items: baseline; padding-block: 1rem; border-bottom: 1px solid #bfb9af; }
.papers time { color: var(--soft); font-family: var(--display); font-weight: 600; }
.papers a { width: fit-content; font-family: var(--display); font-weight: 700; font-size: clamp(1.12rem, 2.15vw, 1.55rem); text-decoration: none; }
.papers a:hover { text-decoration: underline; }
.papers span { display: block; color: var(--soft); font: 400 1rem/1.5 'DM Sans', system-ui, sans-serif; margin-top: .2rem; }
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem 3rem; }
.about p:not(.eyebrow) { max-width: 53ch; margin-bottom: 1rem; font-size: 1.125rem; }
footer { background: var(--ink); color: var(--paper); }
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1.25rem; padding-block: clamp(2.5rem, 6vw, 5.5rem); }
.email { display: inline-block; margin-top: .8rem; font-size: clamp(1rem, 2vw, 1.35rem); overflow-wrap: anywhere; }
.footer-base { display: flex; justify-content: space-between; gap: 1rem; border-top: 1px solid #ffffff4a; padding-block: 1rem; }

@media (max-width: 55rem) {
  .hero { grid-template-columns: 1fr .77fr; }
  h1 { font-size: clamp(2.6rem, 6.5vw, 4.2rem); }
  .work-grid { grid-template-columns: 1fr 1fr; }
  .featured { grid-column: 1 / -1; min-height: 15rem; }
}
@media (max-width: 40rem) {
  .header { flex-wrap: wrap; padding-block: .45rem .85rem; gap: .3rem; }
  nav { justify-content: space-between; width: 100%; }
  .hero, .about, .work-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-art { max-width: 29rem; }
  .section-heading { align-items: start; flex-direction: column; }
  .project { min-height: 0; }
  .papers li { grid-template-columns: 3rem minmax(0, 1fr); gap: .65rem; }
}
