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

:root {
  --bg: #F6F6F6;
  --bg-alt: #f2f1ee;
  --text: #1a1a18;
  --text-muted: #6b6b67;
  --text-light: #9e9e9a;
  --green: #8F8DFF;
  --border: #e5e4e0;
  --border-light: #eeede9;
  --white: #ffffff;
  --font: 'Commit Mono', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: 'Commit Mono', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --h1-size: 70px;  --h1-weight: 500; --h1-tracking: 1px;    --h1-lh: 1.1;
  --h2-size: 40px;  --h2-weight: 500; --h2-tracking: -1.5px; --h2-lh: 1.15;
  --h3-size: 26px;  --h3-weight: 500; --h3-tracking: -0.5px; --h3-lh: 1.3;
  --body-size: 15px; --body-weight: 400; --body-tracking: 0px; --body-lh: 1.5;
  --nav-w: 180px;
}

html { scroll-behavior: smooth; overflow-x: hidden; }

h1 { font-family: var(--font-heading); font-size: var(--h1-size); font-weight: var(--h1-weight); letter-spacing: var(--h1-tracking); line-height: var(--h1-lh); }
h2 { font-family: var(--font-heading); font-size: var(--h2-size); font-weight: var(--h2-weight); letter-spacing: var(--h2-tracking); line-height: var(--h2-lh); }
h3 { font-family: var(--font-heading); font-size: var(--h3-size); font-weight: var(--h3-weight); letter-spacing: var(--h3-tracking); line-height: var(--h3-lh); }

body {
  font-family: var(--font-body);
  font-size: var(--body-size);
  font-weight: var(--body-weight);
  letter-spacing: var(--body-tracking);
  line-height: var(--body-lh);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

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

/* ===== LEFT NAV ===== */
.sidenav {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--nav-w);
  background: var(--bg);
  border-right: 1px solid var(--border);
  z-index: 100;
  display: flex;
  flex-direction: column;
  padding: 32px 24px;
}

.sidenav-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 48px;
  text-decoration: none;
}

.sidenav-logo img {
  width: 1px;
  height: 1px;
  object-fit: contain;
  flex-shrink: 0;
}

.sidenav-logo span {
  font-family: 'Commit Mono', monospace;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.3px;
  color: var(--text);
}

.sidenav-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.sidenav-links li a {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  padding: 7px 10px;
  border-radius: 7px;
  transition: color 0.15s, background 0.15s;
}

.sidenav-links li a:hover {
  color: var(--text);
  background: var(--bg-alt);
}

.sidenav-links li a.active {
  color: var(--text);
  background: var(--bg-alt);
}

.sidenav-cta {
  margin-top: auto;
}

.sidenav-cta a {
  display: block;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--white);
  background: var(--text);
  padding: 9px 16px;
  border-radius: 100px;
  transition: background 0.15s;
  text-decoration: none;
}

.sidenav-cta a:hover { background: #333; }

/* ===== MAIN CONTENT ===== */
.page-wrap {
  margin-left: var(--nav-w);
  flex: 1;
  min-width: 0;
}

/* ===== HERO ===== */
.hero {
  padding: 100px 80px 80px;
  max-width: 900px;
}

.hero h1 {
  color: var(--text);
  margin-bottom: 36px;
}

.hero-body p {
  font-size: var(--body-size);
  color: var(--text-muted);
  line-height: var(--body-lh);
  max-width: 480px;
  margin-bottom: 14px;
}

.hero-body p:last-child { margin-bottom: 0; }

/* ===== DIVIDER ===== */
.divider { height: 1px; background: var(--border); }

/* ===== GOAL SECTIONS ===== */
.goal-section {
  padding: 80px;
}

.goal-layout {
  display: grid;
  grid-template-columns: 1fr 560px;
  gap: 80px;
  align-items: start;
}

.goal-layout.reverse {
  grid-template-columns: 425px 1fr;
}

.goal-layout.reverse .goal-content { order: 1; }
.goal-layout.reverse .goal-visual  { order: 2; }

.goal-number {
  font-family: 'Commit Mono', monospace;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-light);
  letter-spacing: 0.5px;
  margin-bottom: 18px;
}

.goal-content h2 {
  margin-bottom: 20px;
}

.goal-content p {
  font-size: var(--body-size);
  color: var(--text-muted);
  line-height: var(--body-lh);
  margin-bottom: 28px;
  max-width: 300px;
}

.goal-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  padding-bottom: 2px;
  transition: border-color 0.15s;
}

.goal-link:hover { border-color: var(--text); }
.goal-link .arrow { transition: transform 0.15s; }
.goal-link:hover .arrow { transform: translateX(3px); }

.goal-research-link {
  display: block;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}

.goal-research-link .label {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-light);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.goal-research-link .title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  line-height: 1.4;
}

.goal-research-link:hover .title { color: var(--green); }

.goal-visual {
  position: sticky;
  top: 40px;
  text-align: center;
}

.goal-visual img {
  width: 425px;
  max-width: 100%;
  height: 270px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.page-wrap img {
  filter: grayscale(100%);
  transition: filter 0.4s ease;
}

.page-wrap img:hover {
  filter: grayscale(0%);
}

.goal-layout:not(.reverse) .goal-visual img {
  width: 560px;
  max-width: 100%;
  height: 210px;
}

.goal-visual .img-caption {
  display: block;
  width: 100%;
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-light);
  text-align: center;
}

/* ===== JOIN SECTION ===== */
.join-section {
  padding: 80px;
}

.join-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.join-content h2 {
  margin-bottom: 20px;
}

.join-content p {
  font-size: var(--body-size);
  color: var(--text-muted);
  line-height: var(--body-lh);
  margin-bottom: 32px;
}

.join-content p a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--border);
  transition: text-decoration-color 0.15s;
}

.join-content p a:hover { text-decoration-color: var(--text); }

.btn-careers {
  display: inline-flex;
  align-items: center;
  background: var(--text);
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  padding: 11px 22px;
  border-radius: 100px;
  transition: background 0.15s;
  font-family: var(--font);
  text-decoration: none;
}

.btn-careers:hover { background: #333; }

.join-photos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.join-photos img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  border-radius: 10px;
}

.join-photos img:first-child { margin-top: 36px; }

/* ===== FOOTER ===== */
footer {
  border-top: 1px solid var(--border);
  padding: 36px 80px;
}

.footer-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 40px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-logo img { width: 1px; height: 1px; object-fit: contain; }
.footer-logo span { font-size: 14px; font-weight: 600; }

.footer-nav {
  display: flex;
  gap: 2px;
  list-style: none;
  justify-content: center;
  flex-wrap: wrap;
}

.footer-nav a {
  font-size: 13px;
  color: var(--text-muted);
  padding: 4px 10px;
  border-radius: 100px;
  transition: color 0.15s, background 0.15s;
}

.footer-nav a:hover { color: var(--text); background: var(--bg-alt); }

.footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.footer-social {
  display: flex;
  gap: 2px;
  list-style: none;
}

.footer-social a {
  font-size: 13px;
  color: var(--text-muted);
  padding: 4px 10px;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
}

.footer-social a:hover { color: var(--text); background: var(--bg-alt); }

.footer-bottom {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-legal {
  display: flex;
  gap: 2px;
  list-style: none;
}

.footer-legal a {
  font-size: 12px;
  color: var(--text-light);
  padding: 3px 8px;
  transition: color 0.15s;
}

.footer-legal a:hover { color: var(--text-muted); }

.footer-copy {
  font-size: 12px;
  color: var(--text-light);
  white-space: nowrap;
}

/* ===== ADMIN BADGE ===== */
.admin-badge {
  position: fixed;
  bottom: 18px;
  right: 18px;
  background: var(--text);
  color: var(--white);
  font-size: 12px;
  font-weight: 600;
  padding: 7px 15px;
  border-radius: 100px;
  z-index: 999;
  text-decoration: none;
  opacity: 0.5;
  transition: opacity 0.2s;
}

.admin-badge:hover { opacity: 1; }

/* ===== RESEARCH PAGE ===== */
.page-header {
  padding: 100px 80px 60px;
}

.page-header .eyebrow,
.team-header .eyebrow {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-light);
  letter-spacing: 0.5px;
  margin-bottom: 18px;
}

.page-header h1 {
  max-width: 780px;
  margin-bottom: 20px;
}

.page-header .byline {
  font-size: 14px;
  color: var(--text-muted);
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.research-body {
  padding: 0 80px 100px;
}

.research-intro {
  font-size: 19px;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 680px;
  margin-bottom: 72px;
  font-weight: 400;
}

.research-section {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 60px;
  padding: 56px 0;
  border-top: 1px solid var(--border);
}

.research-section-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-light);
  padding-top: 4px;
}

.research-section-content h3 {
  margin-bottom: 14px;
}

.research-section-content p {
  font-size: var(--body-size);
  color: var(--text-muted);
  line-height: var(--body-lh);
  margin-bottom: 14px;
}

.research-section-content p:last-child { margin-bottom: 0; }

.highlight {
  background: var(--bg-alt);
  border-left: 3px solid var(--green);
  padding: 18px 22px;
  border-radius: 0 8px 8px 0;
  margin-top: 20px;
  font-size: 15px;
  color: var(--text);
  line-height: 1.7;
}

/* ===== TEAM PAGE ===== */
.team-header {
  padding: 100px 80px 72px;
}

.team-header h1 {
  max-width: 680px;
}

.team-body {
  padding: 0 80px 100px;
}

.team-block {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 60px;
  padding: 56px 0;
  border-top: 1px solid var(--border);
}

.team-block-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-light);
}

.team-block-content h3 {
  margin-bottom: 16px;
}

.team-block-content p {
  font-size: var(--body-size);
  color: var(--text-muted);
  line-height: var(--body-lh);
  margin-bottom: 10px;
}

.team-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.team-pill {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 5px 14px;
  font-size: 13px;
  color: var(--text-muted);
}

/* ===== RESPONSIVE 1240 ===== */
@media (max-width: 1240px) {
  .goal-layout           { grid-template-columns: 1fr 1fr; }
  .goal-layout.reverse   { grid-template-columns: 1fr 1fr; }

  .goal-visual img,
  .goal-layout:not(.reverse) .goal-visual img { width: 100%; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
  :root {
    --nav-w: 0px;
    --h1-size: 50px; --h1-tracking: -1px;   --h1-lh: 1.08;
    --h2-size: 30px; --h2-tracking: -0.5px;  --h2-lh: 1.15;
    --h3-size: 18px; --h3-tracking: -0.2px;
  }

  /* ── Top bar nav ── */
  .sidenav {
    position: fixed;
    top: 0; left: 0; right: 0;
    width: 100%;
    height: 56px;
    flex-direction: row;
    align-items: center;
    padding: 0 20px;
    border-right: none;
    border-bottom: 1px solid var(--border);
    z-index: 100;
  }

  .sidenav-logo { margin-bottom: 0; }

  .sidenav-links {
    display: none;
  }

  .sidenav-cta { display: none; }

  /* ── Layout ── */
  .page-wrap { margin-left: 0; margin-top: 56px; width: 100%; max-width: 100vw; overflow-x: hidden; }

  .hero         { padding: 48px 20px 40px; max-width: none; }
  .goal-section { padding: 40px 20px; }
  .join-section { padding: 40px 20px; }
  .page-header  { padding: 48px 20px 32px; }
  .page-header h1 { max-width: 100%; }
  .research-body,
  .team-header,
  .team-body,
  footer        { padding-left: 20px; padding-right: 20px; }

  .goal-layout,
  .goal-layout.reverse,
  .join-layout { grid-template-columns: 1fr; gap: 32px; }

  .goal-layout.reverse .goal-content { order: 1; }
  .goal-layout.reverse .goal-visual  { order: 2; }

  .goal-visual { position: static; }
  .goal-visual img,
  .goal-layout:not(.reverse) .goal-visual img { width: 100%; height: 220px; }

  .goal-content p { max-width: none; }

  .hero-body p { max-width: none; }

  .research-section,
  .team-block { grid-template-columns: 1fr; gap: 12px; }

  .footer-inner { grid-template-columns: 1fr; gap: 20px; }
  .footer-right { align-items: flex-start; }
  .footer-nav { flex-direction: column; gap: 0; }

  .join-photos { grid-template-columns: 1fr 1fr; }
  .join-photos img { aspect-ratio: 4/3; }
  .join-photos img:first-child { margin-top: 0; }
}

/* ===== MOBILE NAV ===== */
.nav-burger {
  display: none;
}

.mobile-menu {
  display: none;
}

@media (max-width: 960px) {
  .nav-burger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    margin-left: auto;
    color: var(--text);
  }
  .nav-burger span {
    display: block;
    width: 22px;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
    transition: transform 0.22s ease, opacity 0.15s;
  }
  .nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-burger.open span:nth-child(2) { opacity: 0; }
  .nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .mobile-menu {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 56px;
    left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 12px 20px 20px;
    z-index: 99;
    transform: translateY(-110%);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.2s;
    pointer-events: none;
  }
  .mobile-menu.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }
  .mobile-menu ul {
    list-style: none;
    display: flex;
    flex-direction: column;
  }
  .mobile-menu ul li a {
    display: block;
    font-size: 15px;
    font-weight: 500;
    color: var(--text-muted);
    padding: 12px 8px;
    border-bottom: 1px solid var(--border);
  }
  .mobile-menu ul li:last-child a { border-bottom: none; }
  .mobile-menu ul li a.active,
  .mobile-menu ul li a:hover { color: var(--text); }
  .mobile-menu-cta {
    margin-top: 16px;
  }
  .mobile-menu-cta a {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    color: var(--white);
    background: var(--text);
    padding: 9px 20px;
    border-radius: 100px;
    text-decoration: none;
  }
}

/* ===== CAROUSEL ===== */
.carousel {
  overflow-x: auto;
  display: flex;
  gap: 12px;
  padding: 0 80px 20px;
  scroll-snap-type: x mandatory;
  scroll-padding-left: 80px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.carousel::-webkit-scrollbar { display: none; }
.carousel-item { flex-shrink: 0; scroll-snap-align: start; }
.carousel-item img {
  height: 400px;
  width: auto;
  border-radius: 10px;
  border: 1px solid var(--border);
  display: block;
  filter: none !important;
}
.carousel-caption { margin-top: 8px; font-size: 12px; color: var(--text-light); text-align: center; }
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 4px 0 16px;
}
.carousel-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border);
  transition: background 0.2s, transform 0.2s;
  cursor: pointer;
}
.carousel-dot.active {
  background: var(--text);
  transform: scale(1.3);
}
@media (max-width: 960px) {
  .carousel { padding-left: 20px; padding-right: 20px; scroll-padding-left: 20px; }
  .carousel-item img { height: 260px; }
}

/* ===== IMAGE BLOCKS ===== */
.image-blocks { padding: 0 80px 60px; display: flex; flex-direction: column; gap: 20px; }
.image-block img { width: 100%; border-radius: 10px; border: 1px solid var(--border); }
.image-block--half { max-width: 50%; }
.image-block-caption { margin-top: 10px; font-size: 12px; color: var(--text-light); text-align: center; }
@media (max-width: 960px) { .image-blocks { padding-left: 20px; padding-right: 20px; } .image-block--half { max-width: 100%; } }
