/* ===========================
   ROOT & RESET
   =========================== */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;1,400&family=DM+Sans:wght@300;400;500&display=swap');

:root {
  --off-white: #f7f5f2;
  --white: #ffffff;
  --ink: #1a1a1a;
  --ink-light: #555550;
  --rule: #d8d5d0;
  --accent: #2d5a3d;
  --accent-light: #e8f0eb;
  --accent-mid: #4a8c62;
  --tag-bg: #eef2ef;
  --nav-h: 68px;
  --section-gap: 100px;
  --reading-width: 720px;
  --wide-width: 1100px;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  background: var(--off-white);
  color: var(--ink);
  line-height: 1.7;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* ===========================
   TYPOGRAPHY
   =========================== */
h1, h2, h3, h4 {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  line-height: 1.2;
}

.serif-italic {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-weight: 400;
}

.eyebrow {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ===========================
   LAYOUT HELPERS
   =========================== */
.container {
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 32px;
}

.container--narrow {
  max-width: var(--reading-width);
  margin: 0 auto;
  padding: 0 32px;
}

.section { padding: var(--section-gap) 0; }

.section--ruled {
  border-top: 1px solid var(--rule);
}

.section--tinted {
  background: var(--white);
}

/* ===========================
   NAV
   =========================== */
#site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: rgba(247, 245, 242, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

#site-nav.scrolled {
  border-bottom-color: var(--rule);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 32px;
}

.nav-logo {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.nav-logo span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 36px;
  align-items: center;
}

.nav-links a {
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--ink-light);
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--ink); }

.nav-links .nav-cta a {
  background: var(--accent);
  color: var(--white);
  padding: 8px 18px;
  border-radius: 2px;
  font-weight: 500;
  letter-spacing: 0.06em;
  transition: background 0.2s;
}

.nav-links .nav-cta a:hover {
  background: var(--accent-mid);
  color: var(--white);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--ink);
  transition: 0.3s;
}

/* ===========================
   HERO
   =========================== */
#hero {
  padding-top: calc(var(--nav-h) + 80px);
  padding-bottom: 100px;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 32px;
}

.hero-kicker {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.hero-kicker-line {
  display: block;
  width: 32px;
  height: 1px;
  background: var(--accent);
}

.hero-title {
  font-size: clamp(2.4rem, 4.5vw, 3.8rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 28px;
}

.hero-title em {
  font-style: italic;
  color: var(--accent);
}

.hero-intro {
  font-size: 1.05rem;
  color: var(--ink-light);
  line-height: 1.8;
  max-width: 480px;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  border-radius: 2px;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}

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

.btn--primary:hover {
  background: var(--accent-mid);
}

.btn--ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.btn--ghost:hover {
  background: var(--accent-light);
}

.hero-image-stack {
  position: relative;
  height: 480px;
}

.hero-img-main {
  position: absolute;
  top: 0; right: 0;
  width: 85%;
  height: 85%;
  object-fit: cover;
  border-radius: 3px;
}

.hero-img-inset {
  position: absolute;
  bottom: 0; left: 0;
  width: 55%;
  height: 58%;
  object-fit: cover;
  border-radius: 3px;
  border: 6px solid var(--off-white);
  box-shadow: 0 12px 40px rgba(0,0,0,0.12);
}

/* Placeholder image blocks for demo */
.img-placeholder {
  background: linear-gradient(135deg, #c8ddd0 0%, #a8c5b4 50%, #88ab96 100%);
  border-radius: 3px;
}

.img-placeholder--dark {
  background: linear-gradient(135deg, #3d6b52 0%, #2d5a3d 100%);
}

/* ===========================
   STATS BAR
   =========================== */
.stats-bar {
  background: var(--white);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 40px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.stat-item {
  text-align: center;
  padding: 0 24px;
  border-right: 1px solid var(--rule);
}

.stat-item:last-child { border-right: none; }

.stat-number {
  font-family: 'Playfair Display', serif;
  font-size: 2.4rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-light);
}

/* ===========================
   RESEARCH
   =========================== */
.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 56px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--rule);
}

.section-header-left {}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  letter-spacing: -0.02em;
  margin-top: 10px;
}

.section-link {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: gap 0.2s;
}

.section-link:hover { gap: 14px; }

.research-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
}

.research-card {
  background: var(--white);
  padding: 36px 32px;
  position: relative;
  transition: background 0.2s;
  cursor: default;
}

.research-card:hover {
  background: var(--accent-light);
}

.research-card-num {
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  font-weight: 600;
  color: var(--rule);
  line-height: 1;
  margin-bottom: 20px;
  transition: color 0.2s;
}

.research-card:hover .research-card-num {
  color: var(--accent-mid);
}

.research-card h3 {
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.research-card p {
  font-size: 0.88rem;
  color: var(--ink-light);
  line-height: 1.75;
}

/* ===========================
   TEAM
   =========================== */
.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.team-card {
  cursor: default;
}

.team-photo {
  width: 100%;
  aspect-ratio: 3/4;
  margin-bottom: 18px;
  overflow: hidden;
  border-radius: 2px;
}

.team-photo img,
.team-photo .img-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.team-card:hover .team-photo img,
.team-card:hover .team-photo .img-placeholder {
  transform: scale(1.03);
}

.team-name {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.team-role {
  font-size: 0.78rem;
  color: var(--ink-light);
  letter-spacing: 0.04em;
}

.team-pi .team-photo {
  aspect-ratio: 1/1;
}

/* ===========================
   PUBLICATIONS
   =========================== */
.pub-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.pub-item {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 24px;
  padding: 28px 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
}

.pub-item:first-child {
  border-top: 1px solid var(--rule);
}

.pub-year {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 400;
  color: var(--ink-light);
  padding-top: 4px;
}

.pub-content {}

.pub-title {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 6px;
}

.pub-authors {
  font-size: 0.82rem;
  color: var(--ink-light);
  margin-bottom: 6px;
}

.pub-authors strong {
  color: var(--ink);
  font-weight: 500;
}

.pub-journal {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--accent);
  background: var(--tag-bg);
  padding: 3px 10px;
  border-radius: 2px;
}

/* ===========================
   NEWS
   =========================== */
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.news-card {
  background: var(--white);
  border-radius: 2px;
  overflow: hidden;
}

.news-card-img {
  width: 100%;
  aspect-ratio: 16/10;
  overflow: hidden;
}

.news-card-img .img-placeholder {
  width: 100%;
  height: 100%;
  transition: transform 0.4s;
}

.news-card:hover .news-card-img .img-placeholder {
  transform: scale(1.04);
}

.news-card-body {
  padding: 24px 24px 28px;
}

.news-date {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-light);
  margin-bottom: 10px;
}

.news-card-title {
  font-size: 1rem;
  margin-bottom: 10px;
  line-height: 1.35;
}

.news-card-excerpt {
  font-size: 0.84rem;
  color: var(--ink-light);
  line-height: 1.7;
}

/* ===========================
   JOIN / CTA BAND
   =========================== */
.cta-band {
  background: var(--accent);
  color: var(--white);
  padding: 80px 0;
  text-align: center;
}

.cta-band .eyebrow {
  color: rgba(255,255,255,0.6);
  margin-bottom: 16px;
}

.cta-band h2 {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.cta-band p {
  font-size: 1rem;
  color: rgba(255,255,255,0.75);
  max-width: 520px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

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

.btn--white:hover {
  background: var(--off-white);
}

.btn--outline-white {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(255,255,255,0.4);
}

.btn--outline-white:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.7);
}

.cta-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===========================
   FOOTER
   =========================== */
footer {
  background: var(--ink);
  color: rgba(255,255,255,0.6);
  padding: 64px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 64px;
  margin-bottom: 56px;
}

.footer-brand-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 12px;
}

.footer-brand-desc {
  font-size: 0.84rem;
  line-height: 1.7;
  max-width: 280px;
  margin-bottom: 24px;
}

.footer-col-title {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  margin-bottom: 16px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  font-size: 0.84rem;
  color: rgba(255,255,255,0.55);
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--white); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.76rem;
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 1024px) {
  .team-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  :root { --section-gap: 64px; }

  .nav-links { display: none; flex-direction: column; position: absolute; top: var(--nav-h); left: 0; right: 0; background: var(--off-white); border-bottom: 1px solid var(--rule); padding: 24px 32px; gap: 20px; }
  .nav-links.open { display: flex; }
  .nav-toggle { display: flex; }

  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-image-stack { height: 320px; }
  .hero-title { font-size: 2.2rem; }

  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .stat-item { border-right: none; border-bottom: 1px solid var(--rule); padding-bottom: 24px; }
  .stat-item:nth-child(2n) { border-right: none; }
  .stat-item:nth-child(3), .stat-item:nth-child(4) { border-bottom: none; }

  .research-grid { grid-template-columns: 1fr; }
  .news-grid { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }

  .section-header { flex-direction: column; align-items: flex-start; gap: 16px; }

  .pub-item { grid-template-columns: 60px 1fr; gap: 16px; }

  .footer-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}

@media (max-width: 480px) {
  .container, .container--narrow { padding: 0 20px; }
  .nav-inner { padding: 0 20px; }
  .hero-grid { padding: 0 20px; }
  .team-grid { grid-template-columns: 1fr 1fr; gap: 20px; }
}
