@font-face {
  font-family: "Graphik";
  src: url("assets/Graphik-Regular.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Graphik";
  src: url("assets/Graphik-Bold.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  font-size: 62.5%;
  color-scheme: light;
  --ink: #10112a;
  --muted: rgba(16, 17, 42, 0.62);
  --night: #ffffff;
  --panel: rgba(255, 255, 255, 0.96);
  --rule: rgba(0, 0, 50, 0.34);
  --icon-blue: #168dff;
  --question-glow: rgba(241, 249, 75, 0.95);
  --question-glow-hover: hsla(63, 100%, 64%, 0.95);
  --center-y: 57%;
}

* {
  box-sizing: border-box;
}

html {
  background: #fff;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: #fff;
  font-family: Graphik, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.9rem;
  line-height: 3rem;
  font-weight: 400;
  font-style: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -moz-font-feature-settings: "kern";
  -webkit-font-feature-settings: "kern";
  font-feature-settings: "kern";
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  font-variant-ligatures: common-ligatures;
  -webkit-text-size-adjust: 100%;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  left: 1.6rem;
  top: 1.6rem;
  z-index: 100;
  padding: 0.8rem 1.2rem;
  color: var(--night);
  background: var(--ink);
  transform: translateY(-180%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: none;
}

.site-links {
  position: absolute;
  inset: 1.8rem auto auto 2rem;
  z-index: 20;
  display: grid;
  gap: 0.15rem;
  width: max-content;
  font-size: 1.45rem;
  line-height: 1.45;
}

.site-links__label {
  margin-bottom: 0.35rem;
  color: var(--muted);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-links a {
  color: var(--ink);
  text-decoration-color: rgba(0, 0, 50, 0.38);
  text-underline-offset: 0.3rem;
}

.site-links a:hover,
.site-links a:focus-visible {
  color: #005fbd;
  text-decoration-color: currentColor;
}

.site-links__about,
.site-links__subnav {
  display: grid;
}

.site-links__subnav {
  gap: 0.05rem;
  margin: 0.15rem 0 0.25rem 0.9rem;
  font-size: 0.86em;
  line-height: 1.35;
}

.corner-icon {
  position: absolute;
  top: 2rem;
  right: 2rem;
  z-index: 20;
  width: clamp(8rem, 9vw, 13rem);
  aspect-ratio: 4013 / 3674;
  overflow: hidden;
  border: 0;
  background: transparent;
  color: var(--ink);
}

.corner-icon img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.exploration-stage {
  position: relative;
  width: 100%;
  min-height: clamp(76rem, 100svh, 108rem);
  overflow: hidden;
  isolation: isolate;
  background: #fff;
}

.intro-stack {
  position: absolute;
  top: 1.2rem;
  left: 0;
  z-index: 12;
  width: 100%;
  display: grid;
  justify-items: center;
  gap: 1.2rem;
}

.bubble-header {
  position: relative;
  display: grid;
  place-items: center;
  width: min(58vw, 86rem);
  height: clamp(8rem, 12vw, 15rem);
  margin-inline: auto;
  overflow: hidden;
}

.bubble-header__image {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 86rem;
  max-height: 15rem;
  border: 0;
  object-fit: contain;
}

.research-questions-page .intro-stack {
  z-index: 30;
}

/* The research title is exactly 3% larger than the base title footprint. */
.research-questions-page .bubble-header {
  width: min(59.74vw, 88.58rem);
  height: clamp(8.24rem, 12.36vw, 15.45rem);
  overflow: visible;
}

.research-questions-page .bubble-header__image {
  position: relative;
  z-index: 31;
}

.document-shell {
  position: relative;
  z-index: 11;
  width: 50%;
  min-width: 34rem;
  height: clamp(11rem, 18vh, 18rem);
  margin-inline: auto;
  justify-self: center;
  border: 1px solid var(--rule);
  background: var(--panel);
  backdrop-filter: blur(1rem);
}

.document-shell::after {
  content: "";
  position: absolute;
  right: 1.2rem;
  bottom: 0;
  left: 0;
  height: 2.8rem;
  background: linear-gradient(transparent, rgba(255, 255, 255, 0.98));
  pointer-events: none;
}

.document-viewer {
  height: 100%;
  overflow-y: auto;
  padding: 1.35rem 2rem 3.2rem;
  font-size: clamp(1.25rem, 0.9vw, 1.55rem);
  line-height: 1.42;
  scrollbar-color: var(--ink) transparent;
  scrollbar-width: thin;
}

.document-viewer:focus-visible {
  outline: 2px solid #005fbd;
  outline-offset: 0.4rem;
}

.document-viewer p {
  margin: 0 0 1.2rem;
}

.document-viewer h2 {
  margin: 0 0 1.2rem;
  font-size: 1.45rem;
  font-weight: 400;
  line-height: 1.3;
  text-decoration: underline;
  text-underline-offset: 0.25rem;
}

.document-viewer h3 {
  margin: 1.8rem 0 0.8rem;
  font-size: 1.55rem;
  line-height: 1.3;
}

.document-viewer a {
  color: #32778c;
  text-decoration: underline;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.2em;
}

.document-viewer a:hover,
.document-viewer a:focus-visible {
  color: #005fbd;
}

.document-section {
  margin-top: 2rem;
}

.document-more-link {
  display: inline-block;
  margin: 0.2rem 0 1rem;
}

.centerpiece {
  position: absolute;
  top: var(--center-y);
  left: 50%;
  z-index: 10;
  width: clamp(24rem, 25vw, 48rem);
  margin: 0;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.centerpiece img {
  display: block;
  width: 100%;
  max-height: 44vh;
  object-fit: contain;
  border: 0;
  background: transparent;
  box-shadow: none;
  filter: none;
}

.centerpiece figcaption {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

.connections {
  position: absolute;
  inset: 0;
  z-index: 3;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
  transition: opacity 120ms ease;
}

.connections.is-ready {
  opacity: 1;
}

.bezier-line {
  fill: none;
  stroke: #000;
  stroke-width: 1.1;
  vector-effect: non-scaling-stroke;
  stroke-linecap: round;
  stroke-linejoin: round;
  shape-rendering: geometricPrecision;
  opacity: 1;
}

.question-map {
  position: absolute;
  inset: 0;
  z-index: 9;
  pointer-events: none;
}

.question {
  position: absolute;
  display: block;
  width: clamp(15rem, 16vw, 25rem);
  color: var(--ink);
  font-size: clamp(1.2rem, 1.05vw, 1.75rem);
  line-height: 1.32;
  pointer-events: auto;
}

.question p {
  display: inline;
  margin: 0;
  text-wrap: balance;
}

/* Always-on SVG glow; hover raises its yellow saturation by 10% (capped at 100%). */
.question p {
  text-shadow: 10px 7px 14px var(--question-glow);
  transition: text-shadow 180ms ease;
}

.question:hover p,
.question:focus-within p {
  text-shadow: 10px 7px 14px var(--question-glow-hover);
}

.question-link-icon {
  display: inline-block;
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #0086ff;
  background: transparent;
  box-shadow: none;
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
  margin: 0 0 0 0.45rem;
  text-decoration: underline;
  text-decoration-thickness: 0.1em;
  text-underline-offset: 0.2em;
  text-shadow: none;
  vertical-align: baseline;
  transform: translateY(0.22rem);
  transition: color 160ms ease, text-shadow 160ms ease, transform 160ms ease;
}

.question-link-icon--emphatic {
  min-width: 0;
  border-radius: 0;
}

.question-link-icon:hover,
.question-link-icon:focus-visible {
  color: #005fbd;
  background: transparent;
  text-shadow: none;
  outline: none;
  transform: translateY(0.08rem) scale(1.04);
}

.question--intelligences { top: 34%; left: 2.5%; width: clamp(14rem, 11vw, 21rem); }
.question--information-understanding { top: 24%; left: 23%; width: clamp(16rem, 13vw, 22rem); }
.question--llms-brains { top: 24%; left: 57%; width: clamp(18rem, 16vw, 28rem); }
.question--internal-representations { top: 20%; left: 41%; width: clamp(17rem, 14vw, 24rem); }
.question--life-computational { top: 40%; left: 20%; width: clamp(16rem, 13vw, 22rem); }
.question--multiselectivity { top: 51%; left: 1.5%; width: clamp(18rem, 14vw, 25rem); }
.question--methods { top: 62%; left: 7%; width: clamp(17rem, 15vw, 28rem); }
.question--natural-engineered { top: 77%; left: 4%; width: clamp(16rem, 13vw, 25rem); }
.question--landauer { top: 82%; left: 23%; width: clamp(15rem, 12vw, 22rem); }
.question--simulation { top: 92%; left: 33%; width: clamp(13rem, 10vw, 16rem); }
.question--information-material { top: 83%; left: 44%; width: clamp(15rem, 11vw, 18rem); }
.question--noise { top: 92%; left: 56.5%; width: 9rem; }
.question--range { top: 26%; left: 81%; width: clamp(16rem, 12vw, 18rem); }
.question--memory { top: 37%; left: 61%; width: clamp(17rem, 14vw, 25rem); }
.question--hopfield { top: 50%; left: 79%; width: clamp(16rem, 14vw, 24rem); }
.question--subcellular { top: 65%; right: 1.5%; width: clamp(15rem, 13vw, 23rem); }
.question--tradeoffs { top: 80%; left: 68%; width: clamp(19rem, 16vw, 28rem); }

/* Home page: Word-document hierarchy in a responsive, readable column. */
.home-page {
  min-height: 100svh;
  padding-bottom: 8rem;
  background: #fff;
}

.home-title-banner {
  display: grid;
  place-items: center;
  position: relative;
  z-index: 10;
  width: min(44vw, 66rem);
  height: clamp(6rem, 8.7vw, 11.4rem);
  margin: 1.2rem auto 1in;
  overflow: visible;
}

.home-title-banner img {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: contain;
}

.home-slime-icon {
  position: absolute;
  top: 2rem;
  right: 2rem;
  z-index: 20;
  display: block;
  width: auto;
  height: clamp(17.7rem, 20.2vw, 27.8rem);
  max-width: clamp(11.4rem, 15.2vw, 19rem);
  border: 0;
  object-fit: contain;
}

.home-content {
  width: min(calc(100% - 4rem), 100rem);
  margin: 0 auto;
  color: var(--ink);
  font-size: 1.8rem;
  line-height: 1.65;
}

.home-section + .home-section {
  margin-top: clamp(5rem, 8vw, 9rem);
}

.home-section {
  scroll-margin-top: 3rem;
}

.home-section h1,
.home-section h2 {
  margin: 0 0 2rem;
  font-size: clamp(2.2rem, 2.4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.2;
}

.home-section p {
  max-width: 72ch;
  margin: 0 0 1.8rem;
}

.home-section a {
  color: #32778c;
  text-decoration: underline;
  text-underline-offset: 0.25rem;
}

.home-section a:hover,
.home-section a:focus-visible {
  color: #005fbd;
}

.research-statement p {
  text-align: justify;
  text-justify: inter-word;
}

.about-me-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(14rem, 22rem);
  gap: clamp(3rem, 6vw, 8rem);
  align-items: start;
}

.about-me-section .about-headshot {
  justify-self: end;
  width: min(100%, 22rem);
}

/* Shared subpage styles. */
.subpage {
  min-height: 100svh;
  padding: clamp(9rem, 13vw, 15rem) max(2rem, calc((100vw - 92rem) / 2)) 8rem;
  background: #fff;
}

.subpage .site-links,
.subpage .corner-icon {
  position: fixed;
}

.plain-page {
  width: min(100%, 100rem);
  margin: 0 auto;
  color: var(--ink);
  font-size: 1.8rem;
  line-height: 1.65;
}

.plain-page h1 {
  margin: 0 0 3rem;
  font-size: clamp(3.2rem, 5vw, 5.4rem);
  font-weight: 400;
  line-height: 1.05;
}

.plain-page p {
  max-width: 72ch;
  margin: 0 0 1.8rem;
}

.plain-page a {
  color: #006ec9;
  text-underline-offset: 0.3rem;
}

.about-page {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(14rem, 22rem);
  gap: clamp(3rem, 6vw, 8rem);
  align-items: start;
}

.about-headshot {
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  box-shadow: none;
}

.resume-page {
  width: min(100%, 110rem);
}

.resume-page > p {
  margin-bottom: 1.4rem;
}

.resume-pdf {
  display: block;
  width: 100%;
  height: max(68rem, calc(100svh - 22rem));
  border: 1px solid var(--rule);
  background: #fff;
}

.forthcoming-page {
  min-height: 45vh;
  display: grid;
  align-content: center;
}

.forthcoming-page p {
  margin: 0;
}

.topic-page {
  max-width: 78rem;
  margin: 0 auto;
}

.topic-page__eyebrow {
  margin: 0 0 1rem;
  color: #006ec9;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.topic-page h1 {
  max-width: 15ch;
  margin: 0 0 3rem;
  font-size: clamp(4.2rem, 8vw, 9rem);
  line-height: 0.94;
  letter-spacing: -0.055em;
  text-wrap: balance;
}

.topic-page__lede {
  max-width: 58ch;
  margin: 0 0 5rem;
  color: rgba(16, 17, 42, 0.78);
  font-size: clamp(1.9rem, 2.3vw, 2.7rem);
  line-height: 1.38;
}

.topic-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--rule);
  background: var(--rule);
}

.topic-card {
  min-height: 18rem;
  padding: clamp(2rem, 4vw, 4rem);
  background: var(--night);
}

.topic-card h2 {
  margin: 0 0 1.4rem;
  font-size: 2rem;
  line-height: 1.2;
}

.topic-card p,
.topic-card ul {
  margin: 0;
  color: rgba(16, 17, 42, 0.72);
  font-size: 1.6rem;
  line-height: 1.62;
}

.topic-card ul {
  padding-left: 1.8rem;
}

.home-link {
  display: inline-flex;
  margin-top: 4rem;
  color: #006ec9;
  text-underline-offset: 0.4rem;
}

@media (max-width: 900px) {
  :root { --center-y: 54%; }

  .site-links {
    grid-template-columns: repeat(4, auto);
    gap: 0.6rem 1.4rem;
    inset: 1.4rem auto auto 1.6rem;
  }

  .site-links__label {
    grid-column: 1 / -1;
    margin: 0;
  }

  .corner-icon {
    top: 1.4rem;
    right: 1.6rem;
  }

  .intro-stack {
    top: 8rem;
    width: 100%;
  }

  .bubble-header {
    width: 82vw;
  }

  .document-shell {
    width: 70%;
    min-width: 0;
  }

  .home-title-banner {
    width: 64vw;
    height: 9.4rem;
    margin-top: 11.5rem;
  }

  .home-slime-icon {
    top: 1.4rem;
    right: 1.6rem;
    height: 15.2rem;
  }

  .research-questions-page .bubble-header { width: 84.46vw; }
  .question--information-understanding { left: 15%; }
  .question--internal-representations { top: 24%; left: 39%; width: 18rem; }
  .question--llms-brains { left: 64%; width: 20rem; }
  .question--multiselectivity { left: 1%; }
  .question--landauer { left: 20%; }
  .question--range { left: 79%; }
  .question--hopfield { left: 75%; }
  .question--memory { left: 57%; }
}

@media (max-width: 680px) {
  body {
    font-size: 1.7rem;
    line-height: 2.7rem;
  }

  .exploration-stage {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: visible;
    padding: 17rem 1.6rem 5rem;
  }

  .site-links {
    position: absolute;
    grid-template-columns: repeat(2, auto);
    font-size: 1.3rem;
  }

  .corner-icon {
    position: absolute;
  }

  .intro-stack,
  .centerpiece,
  .question-map {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
    width: 100%;
    transform: none;
  }

  .intro-stack {
    order: 1;
    display: grid;
    gap: 1.5rem;
  }

  .bubble-header,
  .document-shell {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
    width: 100%;
    transform: none;
  }

  .document-shell {
    height: 18rem;
    margin-top: 0;
  }

  .bubble-header {
    height: 12rem;
  }

  .research-questions-page .bubble-header {
    width: 100%;
    height: 12.36rem;
  }

  .home-page {
    padding-bottom: 5rem;
  }

  .home-title-banner {
    width: calc(100% - 8rem);
    height: 8.5rem;
    margin: 17rem auto 1in;
  }

  .home-slime-icon {
    height: 15.2rem;
  }

  .home-content {
    width: 100%;
    padding: 0 1.6rem;
  }

  .about-me-section {
    grid-template-columns: 1fr;
  }

  .about-me-section .about-headshot {
    justify-self: start;
    width: min(60vw, 20rem);
  }

  .centerpiece {
    order: 2;
    margin-top: 3rem;
  }

  .question-map {
    order: 3;
    display: grid;
    gap: 1px;
    margin-top: 3rem;
    border: 1px solid var(--rule);
    background: var(--rule);
  }

  .connections {
    display: none;
  }

  .question {
    position: static;
    width: 100%;
    min-height: 11rem;
    padding: 2rem;
    background: var(--night);
    font-size: 1.65rem;
  }

  .topic-grid {
    grid-template-columns: 1fr;
  }

  .about-page {
    grid-template-columns: 1fr;
  }

  .about-headshot {
    width: min(60vw, 20rem);
  }

  .resume-pdf {
    height: 70svh;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
