/* =============================================
   SUTHERLAND ECOLOGY — Academic Style
   Clean, high-contrast, scientific
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=DM+Mono:wght@300;400&display=swap');

:root {
  --white:     #f6f7f5;      /* cool linen background */
  --bg:        #e4eae6;      /* sage green panels */
  --border:    #d4d9d5;
  --text:      #1a1a1a;
  --muted:     #4a4a4a;
  --faint:     #787878;
  --accent:    #3d6b68;      /* slate teal accent */
  --accent-bg: #dde8e7;
  --nav-h:     56px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  font-size: 15px;
  line-height: 1.7;
  background: var(--white);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* ── NAV ─────────────────────────────────────── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: var(--white);
  border-bottom: 1px solid var(--border);
  display: grid !important;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 2.5rem;
}

nav .nav-brand { justify-self: start; }
nav .nav-links { justify-self: center; margin: 0; padding: 0; }
nav .nav-hamburger { justify-self: end; }

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .01em;
  color: var(--text);
  text-decoration: none;
  line-height: 1;
}

.nav-brand svg {
  display: block;
}



.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-size: .82rem;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  transition: color .15s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
}

.nav-links a.active {
  font-weight: 500;
}

.nav-links li {
  list-style: none;
  padding: 0;
}

.nav-links li::before {
  content: none;
}

/* ── HAMBURGER MENU ──────────────────────────── */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: .3rem;
  z-index: 200;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}

.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.nav-drawer {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0; right: 0;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 1.2rem 1.5rem;
  z-index: 99;
  flex-direction: column;
  gap: 0;
  box-shadow: 0 4px 16px rgba(0,0,0,.08);
}

.nav-drawer.open { display: flex; }

.nav-drawer a {
  font-size: .9rem;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  padding: .7rem 0;
  border-bottom: 1px solid var(--border);
  transition: color .15s;
}

.nav-drawer a:last-child { border-bottom: none; }
.nav-drawer a:hover,
.nav-drawer a.active { color: var(--accent); font-weight: 500; }

/* ── MAIN ────────────────────────────────────── */
main { flex: 1; }

/* ── FOOTER ──────────────────────────────────── */
footer {
  border-top: 1px solid var(--border);
  padding: 1.4rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* links centred via flex on .nav-links */
  gap: 1rem;
  background: var(--bg);
}

.footer-copy {
  font-size: .75rem;
  color: var(--faint);
}

/* ── PAGE HEADER ─────────────────────────────── */
.page-header {
  padding: 1.2rem 2.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.page-header h1 {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -.01em;
}

.page-header p {
  font-size: .85rem;
  color: var(--muted);
  margin-top: .3rem;
}

/* ── HERO ────────────────────────────────────── */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--border);
}

.hero-left {
  padding: 2.5rem 3rem 2.5rem 2.5rem;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-eyebrow {
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 600;
  line-height: 1.15;
  color: var(--text);
  letter-spacing: -.02em;
  margin-bottom: 1.5rem;
}

.hero-desc {
  font-size: .95rem;
  line-height: 1.75;
  color: var(--muted);
  max-width: 480px;
}

.hero-right {
  padding: 2.5rem 2.5rem 2.5rem 3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0;
  background: var(--bg);
}

.hero-stat {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
}

.hero-stat:first-child { border-top: 1px solid var(--border); }

.hero-stat-label {
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: .4rem;
}

.hero-stat-text {
  font-size: .92rem;
  color: var(--text);
  line-height: 1.6;
}

/* ── SECTION ─────────────────────────────────── */
.section {
  max-width: 1080px;
  margin: 0 auto;
  padding: 3rem 2.5rem;
}

.section-wide {
  max-width: 1080px;
  margin: 0 auto;
  padding: 1.8rem 2.5rem;
}

/* ── TYPOGRAPHY ──────────────────────────────── */
h2 {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 2.5rem 0 1rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--border);
}

h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: .3rem;
}

p {
  font-size: .93rem;
  line-height: 1.75;
  color: var(--muted);
  margin-bottom: .9rem;
}

ul {
  list-style: none;
  padding: 0;
  margin-bottom: .9rem;
}

ul li {
  font-size: .93rem;
  line-height: 1.75;
  color: var(--muted);
  padding-left: 1rem;
  position: relative;
  margin-bottom: .15rem;
}

ul li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--accent);
}

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color .15s;
}

a:hover { border-bottom-color: var(--accent); }

/* ── PROFILE (Chris) ─────────────────────────── */
.profile-grid {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 3rem;
  align-items: start;
  margin-top: 1rem;
}

.profile-img {
  width: 160px;
  height: 200px;
  object-fit: cover;
  object-position: top;
  display: block;
  border: 1px solid var(--border);
}

.profile-img-placeholder {
  width: 160px;
  height: 200px;
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .72rem;
  color: var(--faint);
  font-family: 'DM Mono', monospace;
  text-align: center;
  line-height: 1.8;
}

.profile-name {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: .2rem;
  letter-spacing: -.01em;
}

.profile-role {
  font-size: .8rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

/* ── TEAM CARDS ──────────────────────────────── */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  margin-top: 1rem;
  align-items: stretch;
}

.team-card {
  background: var(--white);
  padding: 1.3rem 1.3rem 1.1rem;
  display: flex;
  flex-direction: column;
  transition: background .15s;
}

.team-card:hover { background: var(--bg); }

/* name sits above the photo row */
.team-name {
  font-size: .92rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: .6rem;
  line-height: 1.3;
}

/* photo row: photo col left, meta right */
.team-card-top {
  display: flex;
  gap: .9rem;
  align-items: flex-start;
  margin-bottom: .85rem;
}

/* photo + optional institution stacked vertically */
.team-photo-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  gap: .35rem;
}

.team-photo {
  width: 72px;
  height: 72px;
  border-radius: 4px;
  object-fit: cover;
  object-position: top;
  border: 1px solid var(--border);
}

.team-photo-placeholder {
  width: 72px;
  height: 72px;
  border-radius: 4px;
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .5rem;
  color: var(--faint);
  font-family: 'DM Mono', monospace;
  text-align: center;
  line-height: 1.6;
}

.team-meta { flex: 1; min-width: 0; }

.team-institution {
  font-size: .75rem;
  color: var(--muted);
  margin-bottom: .05rem;
  line-height: 1.4;
}

.team-school {
  font-size: .7rem;
  color: var(--faint);
  margin-bottom: .3rem;
  line-height: 1.4;
}

.team-role {
  font-size: .65rem;
  font-weight: 500;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: .12rem;
}

.team-years {
  font-family: 'DM Mono', monospace;
  font-size: .65rem;
  color: var(--faint);
}

.team-desc {
  font-size: .82rem;
  line-height: 1.65;
  color: var(--muted);
  margin-bottom: .85rem;
  flex: 1;
}

/* icon pill grid */
.team-links {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-top: auto;
}

.team-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 1;
  color: var(--muted);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--white);
  transition: border-color .15s, color .15s, background .15s;
}

.team-link:hover {
  border-color: currentColor;
  background: #f8f8f8;
}

/* Brand colours */
.team-link.link-github  { color: #24292e; }
.team-link.link-web      { color: #3d6b68; }
.team-link.link-linkedin { color: #0077b5; }
.team-link.link-twitter  { color: #000000; }
.team-link.link-bluesky  { color: #0085ff; }
.team-link.link-rg       { color: #00ccbb; }
.team-link.link-scholar  { color: #4285f4; }
.team-link.link-orcid    { color: #a6ce39; }

.team-link svg {
  width: 13px; height: 13px;
  fill: currentColor;
  flex-shrink: 0;
}

/* greyed-out inactive pill */
.team-link-inactive {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 1;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--white);
  opacity: .22;
  cursor: default;
}

.team-link-inactive svg {
  width: 13px; height: 13px;
  fill: var(--faint);
  flex-shrink: 0;
}

/* ── ALUMNI ──────────────────────────────────── */
.alumni-section { margin-top: 3.5rem; }

.alumni-list { margin-top: 1rem; }

.alumni-row {
  display: grid;
  grid-template-columns: 220px 1fr auto;
  gap: .6rem 2rem;
  align-items: baseline;
  padding: .75rem 0;
  border-bottom: 1px solid var(--border);
}

.alumni-row:first-child { border-top: 1px solid var(--border); }

.alumni-name {
  font-size: .9rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  border-bottom: none;
  transition: color .15s;
}

a.alumni-name:hover { color: var(--accent); border-bottom: none; }

.alumni-project {
  font-size: .85rem;
  color: var(--muted);
  line-height: 1.5;
}

.alumni-years {
  font-family: 'DM Mono', monospace;
  font-size: .72rem;
  color: var(--faint);
  white-space: nowrap;
}

/* ── PUBLICATIONS ────────────────────────────── */
.pub-statement {
  border-left: 3px solid var(--accent);
  padding: 1.2rem 1.5rem;
  background: var(--accent-bg);
  margin: 1.5rem 0 2.5rem;
}

.pub-statement p {
  font-size: .92rem;
  line-height: 1.75;
  color: var(--text);
  margin: 0;
}

.pub-icon-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 1.5rem 0;
}

.pub-icon-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
  color: var(--muted);
  transition: color .15s;
  border: none;
  min-width: 80px;
}

.pub-icon-link:hover { color: var(--accent); }
.pub-icon-link:hover .pub-icon { border-color: var(--accent); background: var(--accent-bg); }

.pub-icon {
  width: 56px; height: 56px;
  border: 1px solid var(--border);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .15s, background .15s;
  background: var(--white);
}

.pub-icon svg { width: 26px; height: 26px; }

.pub-icon-label {
  font-size: .68rem;
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ── CONTACT ─────────────────────────────────── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.contact-form { display: grid; gap: 1rem; }

.form-group { display: flex; flex-direction: column; gap: .4rem; }

label {
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
}

input, textarea {
  width: 100%;
  padding: .65rem .8rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 3px;
  font-family: 'Inter', sans-serif;
  font-size: .88rem;
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}

input:focus, textarea:focus { border-color: var(--accent); }
textarea { min-height: 120px; resize: vertical; }

.btn-submit {
  font-family: 'Inter', sans-serif;
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .04em;
  background: var(--accent);
  color: var(--white);
  border: none;
  border-radius: 3px;
  padding: .7rem 1.6rem;
  cursor: pointer;
  transition: opacity .15s;
  align-self: start;
}

.btn-submit:hover { opacity: .85; }


/* ── NEWS ────────────────────────────────────── */
.news-section {
  max-width: 1080px;
  margin: 0 auto;
  padding: 3rem 2.5rem;
  border-top: 1px solid var(--border);
}

.news-section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 1.2rem;
}

.news-section-header h2 {
  margin: 0;
  padding: 0;
  border: none;
}

.news-see-all {
  font-family: 'DM Mono', monospace;
  font-size: .68rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color .15s;
}

.news-see-all:hover { border-bottom-color: var(--accent); }

.news-list { width: 100%; }

.news-row {
  display: grid;
  grid-template-columns: 90px 80px 1fr auto;
  gap: .5rem 1.2rem;
  align-items: baseline;
  padding: .8rem 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
}

.news-row:first-child { border-top: 1px solid var(--border); }
.news-row:hover .news-headline { color: var(--accent); }

.news-date {
  font-family: 'DM Mono', monospace;
  font-size: .68rem;
  color: var(--faint);
  letter-spacing: .05em;
  white-space: nowrap;
}

.news-tag {
  display: inline-block;
  font-family: 'DM Mono', monospace;
  font-size: .6rem;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: .2rem .55rem;
  border-radius: 3px;
  white-space: nowrap;
}

.tag-paper     { background: #dde8e7; color: #3d6b68; }
.tag-milestone { background: #e8f0dd; color: #4a6b2a; }
.tag-event     { background: #e8e4dd; color: #6b4e2a; }

.news-headline {
  font-size: .9rem;
  color: var(--text);
  line-height: 1.5;
  transition: color .15s;
}

.news-arrow {
  font-size: .8rem;
  color: var(--faint);
  transition: color .15s;
}

.news-row:hover .news-arrow { color: var(--accent); }

/* news page full list */
.news-page-list { max-width: 860px; margin: 0 auto; padding: 2.5rem 2.5rem; }

@media (max-width: 600px) {
  .news-row {
    grid-template-columns: 70px 70px 1fr;
    gap: .4rem .8rem;
  }
  .news-arrow { display: none; }
  .news-section { padding: 2rem 1.2rem; }
  .news-page-list { padding: 2rem 1.2rem; }
}

/* ── RESPONSIVE ──────────────────────────────── */
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .hero-left { border-right: none; border-bottom: 1px solid var(--border); padding: 3rem 1.5rem; }
  .hero-right { padding: 2rem 1.5rem; background: var(--bg); }
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .profile-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}

@media (max-width: 600px) {
  nav { padding: 0 1.2rem; }
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
  .page-header { padding: 1rem 1.2rem; }
  .section, .section-wide { padding: 2.5rem 1.2rem; }
  .alumni-row { grid-template-columns: 1fr auto; }
  .alumni-project { grid-column: 1 / -1; }
}
