:root {
  --ink: #102737;
  --ink-soft: #526574;
  --paper: #f7f8f4;
  --white: #ffffff;
  --navy: #0b2438;
  --blue: #176b87;
  --cyan: #67c8c3;
  --lime: #d5e66b;
  --line: #d9e0df;
  --serif: "Newsreader", Georgia, serif;
  --sans: "DM Sans", -apple-system, BlinkMacSystemFont, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
}

a { color: inherit; }

.navbar {
  min-height: 78px;
  padding: 0;
  color: var(--ink);
  background: rgba(247, 248, 244, 0.94);
  border-bottom: 1px solid rgba(16, 39, 55, 0.1);
  backdrop-filter: blur(14px);
}

.navbar > .container-fluid {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding-right: 1.5rem;
  padding-left: 1.5rem;
}

.navbar-brand {
  color: var(--ink) !important;
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.navbar-nav .nav-link {
  color: var(--ink) !important;
  font-size: 0.89rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active { color: var(--blue) !important; }

.navbar-toggler { color: var(--ink); border-color: transparent !important; }
.navbar-toggler:focus { box-shadow: 0 0 0 2px rgba(23, 107, 135, .22); }
.navbar-toggler-icon {
  position: relative;
  height: 18px;
  background-image: none !important;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
}
.navbar-toggler-icon::after {
  content: "";
  position: absolute;
  top: 7px;
  right: 0;
  left: 0;
  border-top: 2px solid var(--ink);
}

#quarto-content { padding: 0; }

main.content { margin: 0 auto; padding: 0; width: 100%; max-width: 1180px; min-width: 0; }

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 3rem;
  align-items: center;
  min-height: 0;
  padding: 4.5rem clamp(1.5rem, 5%, 3.5rem);
  overflow: hidden;
  color: white;
  background:
    radial-gradient(circle at 74% 36%, rgba(103, 200, 195, 0.16), transparent 25%),
    linear-gradient(135deg, #0b2438 0%, #11354a 68%, #0d4456 100%);
}

.hero::after {
  content: "";
  position: absolute;
  right: -6rem;
  bottom: -10rem;
  width: 34rem;
  height: 34rem;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 50%;
}

.hero-copy { position: relative; z-index: 1; max-width: 850px; }

.eyebrow {
  margin: 0 0 1.25rem;
  color: var(--cyan);
  font-size: 0.76rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1.hero-title,
h1.page-title {
  max-width: 850px;
  margin: 0 0 2rem;
  font-family: var(--serif);
  font-size: clamp(2.25rem, 3.5vw, 3.25rem);
  font-weight: 500;
  line-height: 1.12;
  text-wrap: balance;
  letter-spacing: -0.045em;
}

.hero-title > p:not(.eyebrow) {
  max-width: 760px;
  color: rgba(255,255,255,.78);
  font-family: var(--sans);
  font-size: 1.08rem;
  line-height: 1.7;
}

.hero-actions { margin-top: 1.75rem; }
.hero-actions > p { display: flex; gap: .8rem; flex-wrap: wrap; margin: 0; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: .7rem 1.15rem;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 2px;
  font-size: .9rem;
  font-weight: 700;
  text-decoration: none;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.button:hover { transform: translateY(-2px); }
.button-primary { color: var(--navy); background: var(--lime); border-color: var(--lime); }
.button-secondary { color: white; background: transparent; }
.button-secondary:hover { background: rgba(255,255,255,.08); }

.hero-mark { position: relative; z-index: 1; justify-self: end; width: 100%; max-width: 280px; }

.matrix {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  padding: 14%;
  border: 1px solid rgba(255,255,255,.18);
  transform: rotate(-4deg);
}

.matrix > p { display: contents; }
.matrix span { aspect-ratio: 1; background: rgba(255,255,255,.07); }
.matrix span.active { background: var(--cyan); box-shadow: 0 0 28px rgba(103,200,195,.28); }

.matrix-label {
  margin-top: 1.8rem;
  color: rgba(255,255,255,.45);
  font-family: var(--serif);
  font-size: 1.3rem;
  text-align: right;
}

.content-shell { width: min(1180px, calc(100% - 3rem)); margin: 0 auto; }

.section-intro { display: grid; grid-template-columns: 1fr 2fr; gap: 4rem; padding: 7rem 0 3rem; }

.section-intro h2,
.split-heading h2,
.contact-copy h2,
.note-panel h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.8rem, 2.5vw, 2.4rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.035em;
}

.focus-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.focus-card { min-height: 320px; padding: 2rem; border-right: 1px solid var(--line); }
.focus-card:last-child { border-right: 0; }
.card-number, .pub-year { color: var(--blue); font-size: .75rem; font-weight: 700; letter-spacing: .12em; }
.focus-card h3 { margin: 5rem 0 .8rem; font-family: var(--serif); font-size: 1.8rem; font-weight: 500; }
.focus-card p { color: var(--ink-soft); font-size: .96rem; line-height: 1.65; }

.split-section { display: grid; grid-template-columns: .8fr 1.2fr; gap: 6rem; padding: 8rem 0; }
.timeline { border-top: 1px solid var(--line); }
.timeline-item { display: grid; grid-template-columns: 130px 1fr; gap: 1.5rem; padding: 1.7rem 0; border-bottom: 1px solid var(--line); }
.timeline-date { color: var(--blue); font-size: .78rem; font-weight: 700; }
.timeline-item h3 { margin: 0; font-size: 1rem; }
.timeline-item p { margin: .25rem 0 0; color: var(--ink-soft); font-size: .93rem; }

.contact-band {
  display: grid;
  grid-template-columns: 1.3fr .7fr;
  gap: 4rem;
  align-items: end;
  margin-bottom: 7rem;
  padding: 4rem;
  color: white;
  background: var(--navy);
}

.contact-details { padding-left: 2rem; border-left: 1px solid rgba(255,255,255,.18); color: rgba(255,255,255,.67); font-size: .94rem; }
.contact-link { display: block; margin-bottom: 1rem; color: var(--lime); font-size: 1.05rem; font-weight: 700; text-decoration: none; }

.page-hero { padding: 4rem clamp(1.5rem, 5%, 3.5rem); color: white; background: var(--navy); }
.page-hero > p:not(.eyebrow) { max-width: 700px; color: rgba(255,255,255,.7); font-size: 1.06rem; }
h1.page-title { margin-bottom: 1.5rem; font-size: clamp(2.25rem, 3.5vw, 3.25rem); }
.page-hero a { color: var(--lime); }

.research-content { padding: 4rem 0 8rem; }
.research-row { display: grid; grid-template-columns: 130px 1fr; gap: 3rem; padding: 3.5rem 0; border-bottom: 1px solid var(--line); }
.research-index { color: var(--cyan); font-family: var(--serif); font-size: 3.5rem; line-height: 1; }
.research-body { max-width: 780px; }
.research-body h2 { margin: 0 0 1rem; font-family: var(--serif); font-size: 2.3rem; font-weight: 500; }
.research-body p { color: var(--ink-soft); }
.research-body p:last-child { font-size: .9rem; }
.note-panel { margin-top: 5rem; padding: 4rem; background: #e9efec; }
.note-panel h2 { margin-bottom: 1.4rem; font-size: 2.5rem; }
.note-panel p { max-width: 850px; margin-bottom: 0; }

.publication-list { padding: 2rem 0 8rem; }
.publication { display: grid; grid-template-columns: 100px minmax(0, 1fr); column-gap: 2rem; align-items: start; padding: 2.3rem 0; border-bottom: 1px solid var(--line); }
.publication > p:first-child { margin: .25rem 0 0; }
.publication > section { grid-column: 2; min-width: 0; }
.publication h3 { margin: 0; font-family: var(--serif); font-size: 1.65rem; font-weight: 500; line-height: 1.2; }
.publication p { margin: .55rem 0 0; color: var(--ink-soft); font-size: .9rem; }
.publication .paper-link { display: inline-block; color: var(--blue); font-size: .82rem; font-weight: 700; text-decoration: none; }
.publication .paper-link::after { content: " ↗"; }

.nav-footer { padding: 2rem 4vw; color: var(--ink-soft); background: #edf0ed; border-top: 0; font-size: .8rem; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; padding-top: 3rem; padding-bottom: 3rem; }
  .hero-mark { display: none; }
  .section-intro, .split-section, .contact-band { grid-template-columns: 1fr; gap: 2rem; }
  .focus-grid { grid-template-columns: 1fr; }
  .focus-card { min-height: 240px; border-right: 0; border-bottom: 1px solid var(--line); }
  .focus-card:last-child { border-bottom: 0; }
  .focus-card h3 { margin-top: 3rem; }
  .contact-details { padding: 2rem 0 0; border-top: 1px solid rgba(255,255,255,.18); border-left: 0; }
  .publication { grid-template-columns: 70px minmax(0, 1fr); }
}

@media (max-width: 600px) {
  body { font-size: 16px; }
  .navbar { min-height: 66px; padding: 0 1rem; }
  .hero { padding: 4.75rem 1.5rem 4.5rem; }
  h1.hero-title { font-size: 2.25rem; line-height: 1.02; }
  .hero-title > p:not(.eyebrow) { font-size: 1rem; line-height: 1.65; }
  .content-shell { width: min(100% - 2rem, 1180px); }
  .section-intro { padding-top: 5rem; }
  .split-section { padding: 5rem 0; }
  .timeline-item { grid-template-columns: 1fr; gap: .4rem; }
  .contact-band, .note-panel { margin-left: -1rem; margin-right: -1rem; padding: 2.3rem 1.5rem; }
  .page-hero { padding: 4.75rem 1.5rem 3.75rem; }
  h1.page-title { font-size: 2.45rem; line-height: 1.02; }
  .research-row { grid-template-columns: 1fr; gap: 1rem; padding: 2.5rem 0; }
  .research-index { font-size: 2rem; }
  .publication { grid-template-columns: 1fr; gap: .55rem; }
  .publication > section { grid-column: 1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button { transition: none; }
}
