/* ===========================================================
   HEAT Lab — Hyporheic Exchange And Transport
   Clean, responsive academic theme.
   Palette: water teal-blue (primary) + warm amber (accent / "heat")
   =========================================================== */

:root {
  --ink:        #15232b;   /* near-black slate for text   */
  --ink-soft:   #45575f;   /* secondary text              */
  --muted:      #6b7b82;   /* captions / meta             */
  --line:       #e2e8ea;   /* hairlines / borders         */
  --bg:         #ffffff;   /* page background             */
  --bg-soft:    #f5f8f9;   /* alternating section bg      */
  --primary:    #0d5c70;   /* deep water teal             */
  --primary-d:  #084553;   /* darker teal (hovers)        */
  --accent:     #e8743b;   /* warm "heat" amber           */
  --accent-d:   #c95c27;
  --ring: 0 1px 2px rgba(15,35,43,.06), 0 8px 24px rgba(15,35,43,.06);
  --radius: 14px;
  --maxw: 1080px;
}

/* ---------- reset-ish ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: "Spectral", Georgia, "Times New Roman", serif;
  line-height: 1.2;
  color: var(--ink);
  margin: 0 0 .5em;
  font-weight: 600;
}
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--accent-d); text-decoration: underline; }
img { max-width: 100%; display: block; }
p { margin: 0 0 1rem; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 64px 0; }
.section.alt { background: var(--bg-soft); }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--accent-d);
  font-family: "Inter", sans-serif;
  margin: 0 0 .6rem;
}
.lead { font-size: 1.12rem; color: var(--ink-soft); }

/* ---------- top nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.88);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 66px; padding-top: 8px; padding-bottom: 8px; }
.brand { display: flex; align-items: center; gap: 12px; font-weight: 700; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand img { width: 64px; height: 64px; }
.brand .brand-name { font-family: "Spectral", serif; font-size: 1.18rem; letter-spacing: .01em; }
.brand .brand-sub { display:block; font-family:"Inter",sans-serif; font-size:.82rem; letter-spacing:.01em; text-transform:none; color: var(--muted); font-weight:600; line-height:1.3; }
@media (max-width: 620px) { .brand .brand-sub { display:none; } }
.flx { color: var(--accent-d); font-weight:700; }
.footer .flx { color: #f2925e; }
.nav-links { display: flex; gap: 4px; align-items: center; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  display: inline-block; padding: 8px 14px; border-radius: 8px;
  color: var(--ink-soft); font-weight: 500; font-size: .95rem;
}
.nav-links a:hover { background: var(--bg-soft); color: var(--primary); text-decoration: none; }
.nav-links a.active { color: var(--primary); font-weight: 600; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display:block; width:22px; height:2px; background: var(--ink); margin:4px 0; transition:.2s; }

/* ---------- hero ---------- */
.hero { padding: 72px 0 56px; background:
    radial-gradient(1200px 400px at 80% -10%, rgba(13,92,112,.08), transparent 60%),
    radial-gradient(900px 360px at 0% 10%, rgba(232,116,59,.07), transparent 55%); }
.hero-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 48px; align-items: center; }
.hero h1 { font-size: 2.7rem; margin-bottom: .25em; }
.hero .role { font-size: 1.05rem; color: var(--ink-soft); margin-bottom: 1.1rem; font-weight: 500; }
.hero .role strong { color: var(--primary); }
.hero .tagline { font-size: 1.22rem; color: var(--ink); font-family:"Spectral",serif; font-style: italic; margin-bottom: 1.4rem; }
.portrait {
  width: 100%; aspect-ratio: 1/1; border-radius: 20px; overflow: hidden;
  background: linear-gradient(135deg, var(--primary), var(--primary-d));
  box-shadow: var(--ring); display:flex; align-items:center; justify-content:center;
  color: #cfe6ec; position: relative;
}
.portrait img { width:100%; height:100%; object-fit: cover; object-position: center 25%; }
.portrait .ph { text-align:center; padding: 20px; }
.portrait .ph svg { width: 84px; height: 84px; opacity:.85; margin: 0 auto 10px; }
.portrait .ph small { font-size:.72rem; letter-spacing:.05em; opacity:.8; }

/* buttons */
.btn {
  display:inline-flex; align-items:center; gap:8px;
  padding: 11px 20px; border-radius: 10px; font-weight: 600; font-size: .95rem;
  border: 1px solid transparent; cursor: pointer;
}
.btn-primary { background: var(--primary); color:#fff; }
.btn-primary:hover { background: var(--primary-d); color:#fff; text-decoration:none; }
.btn-ghost { background:#fff; color: var(--primary); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--primary); text-decoration:none; }
.btn-row { display:flex; flex-wrap:wrap; gap:12px; margin-top: 6px; }

/* ---------- chips ---------- */
.chips { display:flex; flex-wrap:wrap; gap:8px; margin: 10px 0 0; padding:0; list-style:none; }
.chips li { background:#fff; border:1px solid var(--line); color: var(--ink-soft);
  padding:5px 12px; border-radius:999px; font-size:.84rem; }

/* ---------- cards ---------- */
.grid { display:grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background:#fff; border:1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--ring);
}
.card .num { font-family:"Spectral",serif; font-size: 1.6rem; color: var(--accent); line-height:1; }
.card h3 { margin: 10px 0 8px; font-size: 1.18rem; }
.card p { font-size: .96rem; color: var(--ink-soft); margin-bottom: .6rem; }
.card .fund { font-size:.8rem; color: var(--muted); border-top:1px solid var(--line); padding-top:10px; margin-top:12px; }
.card .fund b { color: var(--ink-soft); }

/* section heading */
.shead { max-width: 720px; margin-bottom: 36px; }
.shead h2 { font-size: 2rem; }

/* ---------- publications ---------- */
.pub-group { margin-bottom: 40px; }
.pub-group h3 { font-size: 1.25rem; color: var(--primary); border-bottom: 2px solid var(--line); padding-bottom: 8px; margin-bottom: 4px; }
.pub { padding: 16px 0; border-bottom: 1px solid var(--line); display:flex; gap:16px; }
.pub:last-child { border-bottom: 0; }
.pub .yr { flex:0 0 54px; font-family:"Spectral",serif; font-weight:600; color: var(--accent-d); font-size:1.05rem; }
.pub .body { flex:1; }
.pub .title { font-weight: 600; color: var(--ink); }
.pub .authors { color: var(--ink-soft); font-size:.95rem; }
.pub .venue { color: var(--muted); font-size:.92rem; font-style: italic; }
.pub .me { color: var(--primary); font-weight:700; }
.tag { display:inline-block; font-size:.7rem; font-weight:700; text-transform:uppercase; letter-spacing:.06em;
  padding:2px 8px; border-radius:6px; margin-left:6px; vertical-align:middle; }
.tag.review { background:#fff3e9; color: var(--accent-d); }
.tag.prep { background:#eef4f6; color: var(--primary); }
a.pub { text-decoration:none; color:inherit; padding-left:14px; padding-right:14px; margin-left:-14px; margin-right:-14px; border-radius:10px; transition: background .15s; }
a.pub:hover { background: var(--bg-soft); }
a.pub:hover .title { color: var(--primary); }
.pub .title .ext { color: var(--muted); font-weight:400; font-size:.85em; }

/* figure / conceptual diagram */
figure.figure { margin:0; }
figure.figure img { width:100%; border-radius: var(--radius); border:1px solid var(--line); box-shadow: var(--ring); display:block; }
figure.figure figcaption { color: var(--muted); font-size:.9rem; margin-top:12px; text-align:center; }

/* ---------- CV / timeline ---------- */
.timeline { border-left: 2px solid var(--line); padding-left: 26px; margin-left: 6px; }
.t-item { position: relative; padding-bottom: 26px; }
.t-item::before { content:""; position:absolute; left:-33px; top:6px; width:12px; height:12px;
  border-radius:50%; background: var(--accent); box-shadow: 0 0 0 4px #fff; }
.t-item .when { font-size:.82rem; color: var(--muted); font-weight:600; text-transform:uppercase; letter-spacing:.05em; }
.t-item h4 { margin:.15em 0 .15em; font-size:1.08rem; }
.t-item .where { color: var(--ink-soft); font-size:.95rem; }
.t-item p { font-size:.93rem; color: var(--ink-soft); margin:.4rem 0 0; }

.cols-2 { columns: 2; column-gap: 40px; }
.cols-2 li { break-inside: avoid; margin-bottom: 6px; }
ul.clean { list-style: none; padding:0; margin:0; }
ul.tick { list-style:none; padding:0; margin:0; }
ul.tick li { position:relative; padding-left:22px; margin-bottom:8px; color:var(--ink-soft); }
ul.tick li::before { content:""; position:absolute; left:0; top:9px; width:8px; height:8px; border-radius:2px; background:var(--accent); }

.skill-group { margin-bottom: 18px; }
.skill-group h4 { font-size:.78rem; text-transform:uppercase; letter-spacing:.1em; color:var(--muted); font-family:"Inter",sans-serif; margin-bottom:8px; }

/* ---------- news ---------- */
.news li { padding:12px 0; border-bottom:1px solid var(--line); display:flex; gap:16px; }
.news .date { flex:0 0 120px; color: var(--accent-d); font-weight:600; font-size:.9rem; }
.news .what { color: var(--ink-soft); }

/* ---------- callout / join ---------- */
.callout {
  background: linear-gradient(135deg, var(--primary), var(--primary-d));
  color:#eaf4f7; border-radius: var(--radius); padding: 40px; box-shadow: var(--ring);
}
.callout h2 { color:#fff; }
.callout p { color:#cfe6ec; }
.callout a { color:#fff; text-decoration: underline; }
.callout .btn-primary { background: var(--accent); }
.callout .btn-primary:hover { background: var(--accent-d); }

/* ---------- footer ---------- */
.footer { background: var(--ink); color: #aebfc6; padding: 48px 0 32px; }
.footer a { color:#dfeaee; }
.footer .f-grid { display:grid; grid-template-columns: 2fr 1fr 1fr; gap:32px; }
.footer h4 { color:#fff; font-size:1rem; margin-bottom:.6rem; }
.footer .f-brand { font-family:"Spectral",serif; font-size:1.2rem; color:#fff; }
.footer ul { list-style:none; padding:0; margin:0; }
.footer li { margin-bottom:6px; font-size:.92rem; }
.footer .copy { border-top:1px solid #2a3b43; margin-top:32px; padding-top:18px; font-size:.82rem; color:#7e9099; }

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .portrait { max-width: 280px; margin: 0 auto; order: -1; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .pi-grid { grid-template-columns: 1fr !important; }
  .pi-grid .portrait { max-width: 220px; margin: 0 0 16px; }
  .footer .f-grid { grid-template-columns: 1fr; }
  .cols-2 { columns: 1; }
  .nav-links {
    position: absolute; top: 66px; left:0; right:0; flex-direction: column; align-items: stretch;
    background:#fff; border-bottom:1px solid var(--line); padding: 8px 16px 16px; gap:0;
    display: none;
  }
  .nav-links.open { display:flex; }
  .nav-links a { padding: 12px 8px; border-bottom:1px solid var(--bg-soft); }
  .nav-toggle { display:block; }
  .hero h1 { font-size: 2.1rem; }
}
