/* ============================================================
   Academic website template — Glenn White
   ------------------------------------------------------------
   Seager-style structure: sticky nav, hero banner, image cards.
   Plain CSS, no frameworks, no external fonts, no trackers.
   The whole look is driven by the variables in :root below —
   change --navy and --accent and the entire site re-themes.
   ============================================================ */

:root {
  --paper: #fbfaf7;          /* page background          */
  --tint:  #f3f1ea;          /* alternating section bg   */
  --ink:   #23262d;          /* main text                */
  --muted: #5c6470;          /* secondary text           */
  --navy:  #0c1c30;          /* hero / footer            */
  --navy2: #13273f;          /* hero gradient partner    */
  --accent: #d9a441;         /* gold accent              */
  --accent-deep: #a97b1e;    /* darker gold for text     */
  --link:  #20558a;
  --card:  #ffffff;
  --line:  #e4e1d8;
  --shadow: 0 1px 3px rgba(15,25,40,.08), 0 10px 26px rgba(15,25,40,.07);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ---------- base ---------- */

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

h1, h2, h3, h4 { font-family: var(--serif); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 4.5vw, 3.2rem); font-weight: 600; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.15rem; }
p  { margin: 0 0 1em; }
a  { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
ul  { padding-left: 1.2em; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

.section { padding: 60px 0; }
.section.tint { background: var(--tint); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { margin-bottom: 34px; }
.section-head p { color: var(--muted); max-width: 46em; }

.kicker {
  display: block;
  font-family: var(--sans);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin-bottom: 8px;
}

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--navy); color: #fff; padding: 10px 16px; z-index: 100;
}
.skip-link:focus { left: 12px; top: 12px; }

a:focus-visible, button:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

/* ---------- navigation ---------- */

.site-nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,250,247,.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  max-width: 1080px; margin: 0 auto; padding: 10px 24px;
  display: flex; align-items: center; gap: 20px;
}

.brand {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--serif); font-size: 1.12rem; color: var(--ink);
  white-space: nowrap;
}
.brand:hover { text-decoration: none; }

.brand-mark {
  width: 38px; height: 38px; border-radius: 50%;
  background: linear-gradient(135deg, var(--navy), var(--navy2));
  color: var(--accent);
  font-size: .95rem; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
  letter-spacing: .02em;
}

.nav-links {
  list-style: none; display: flex; gap: 4px; margin: 0 0 0 auto; padding: 0;
  overflow-x: auto; -webkit-overflow-scrolling: touch;
}
.nav-links a {
  display: block; padding: 8px 11px;
  font-size: .92rem; color: var(--ink); border-radius: 6px; white-space: nowrap;
}
.nav-links a:hover { background: rgba(12,28,48,.07); text-decoration: none; }
.nav-links a[aria-current="page"] { color: var(--navy); font-weight: 600; box-shadow: inset 0 -2px 0 var(--accent); }

/* ---------- hero (home) ---------- */

.hero {
  color: #fff;
  background-color: var(--navy); /* shows through if hero.svg is missing */
  background-image:
    linear-gradient(rgba(9,20,35,.66), rgba(9,20,35,.80)),
    url("../images/hero.svg");
  background-size: cover;
  background-position: center;
  padding: 28px 0 24px;
}

.hero h1 { margin-bottom: .25em; }
.hero .hero-sub {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(1.1rem, 2.2vw, 1.35rem); color: #f0e6cf;
  white-space: nowrap; margin: 0 0 1.1em;
}
.hero .hero-note { color: #c9d3e0; font-size: 1rem; margin-bottom: .6em; }

.btn {
  display: inline-block; padding: 11px 22px; border-radius: 8px;
  font-weight: 600; font-size: .95rem; margin: 4px 8px 4px 0;
}
.btn:hover { text-decoration: none; }
.btn-solid { background: var(--accent); color: var(--navy); }
.btn-solid:hover { background: #e6b455; }
.btn-ghost { border: 1.5px solid rgba(255,255,255,.75); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.12); }
.btn-dark { background: var(--navy); color: #fff; }
.btn-dark:hover { background: var(--navy2); }

/* ---------- page banner (subpages) ---------- */

.page-banner {
  color: #fff;
  background: linear-gradient(120deg, var(--navy), var(--navy2));
  padding: 52px 0 46px;
}
.page-banner h1 { font-size: clamp(1.9rem, 3.6vw, 2.6rem); margin-bottom: .15em; }
.page-banner p { color: #c9d3e0; max-width: 40em; margin: 0; }

/* ---------- cards & grids ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex; flex-direction: column;
}
.card img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.card-body { padding: 18px 20px 20px; }
.card-body h3 { margin-bottom: .35em; }
.card-body p { font-size: .95rem; color: var(--muted); margin-bottom: .6em; }
.card-body .more { font-size: .9rem; font-weight: 600; color: var(--accent-deep); }

/* ---------- about / portrait ---------- */

.two-col {
  display: grid;
  grid-template-columns: minmax(240px, 320px) 1fr;
  gap: 40px; align-items: start;
}
.portrait {
  border-radius: 10px;
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 5; object-fit: cover; width: 100%;
}
@media (max-width: 720px) {
  .two-col { grid-template-columns: 1fr; }
  .portrait { max-width: 320px; }
  .hero .hero-sub { white-space: normal; }
}

/* ---------- media strip (outreach) ---------- */

.media-strip {
  display: flex; flex-wrap: wrap; gap: 14px;
  align-items: center; margin-top: 26px;
}
.media-strip img {
  height: 150px; width: auto; max-width: 100%;
  border-radius: 8px; box-shadow: var(--shadow);
}
@media (max-width: 560px) {
  .media-strip img { height: 110px; }
}

/* ---------- publications ---------- */

.pub {
  padding: 14px 0;
  border-bottom: 1px dashed var(--line);
}
.pub .pub-title { font-weight: 700; }
.pub .pub-title a { color: var(--ink); }
.pub .pub-title a:hover { color: var(--link); }
.pub .pub-authors { font-size: .95rem; }
.pub .pub-meta { color: var(--muted); font-size: .9rem; }
.pub .pub-links { font-size: .88rem; margin-top: 4px; }
.pub .pub-links a { margin-right: 12px; }

.pub-type {
  display: inline-block;
  font-family: var(--sans);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent-deep);
  border: 1px solid var(--accent);
  border-radius: 20px;
  padding: 1px 9px;
  vertical-align: 2px;
  white-space: nowrap;
}

.pub-controls {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin: 0 0 26px;
}
.pub-controls input[type="search"] {
  flex: 1 1 220px;
  padding: 8px 14px;
  border: 1px solid var(--line); border-radius: 8px;
  background: var(--card); color: var(--ink);
  font-size: .95rem; font-family: var(--sans);
}
.pub-controls input[type="search"]:focus {
  outline: 3px solid var(--accent); outline-offset: 1px;
}

.chip {
  padding: 7px 13px;
  border: 1px solid var(--line); border-radius: 20px;
  background: var(--card); color: var(--ink);
  font-size: .85rem; font-family: var(--sans);
  cursor: pointer;
}
.chip:hover { border-color: var(--accent); }
.chip-on { background: var(--navy); color: #fff; border-color: var(--navy); }

.year-head {
  font-family: var(--serif); font-size: 1.35rem; color: var(--navy);
  margin: 38px 0 4px; padding-bottom: 6px; border-bottom: 2px solid var(--accent);
}

/* ---------- timeline (career) ---------- */

.timeline { list-style: none; margin: 0; padding: 0 0 0 22px; border-left: 2px solid var(--accent); }
.timeline li { position: relative; padding: 0 0 22px 18px; }
.timeline li::before {
  content: ""; position: absolute; left: -28px; top: 7px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--accent); border: 2px solid var(--paper);
  box-shadow: 0 0 0 2px var(--accent-deep);
}
.timeline .tl-when { font-weight: 700; color: var(--accent-deep); font-size: .9rem; }
.timeline .tl-what { font-family: var(--serif); font-size: 1.05rem; }

/* ---------- group ---------- */

.person { display: flex; gap: 16px; align-items: center; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.person:last-child { border-bottom: none; }
.avatar {
  width: 58px; height: 58px; border-radius: 50%; flex: 0 0 auto;
  background: linear-gradient(135deg, var(--navy), var(--navy2));
  color: var(--accent); font-family: var(--serif); font-size: 1.15rem; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.person .p-name { font-weight: 700; }
.person .p-role { color: var(--muted); font-size: .9rem; }

/* ---------- teaching ---------- */

.course {
  background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--accent);
  border-radius: 8px; padding: 16px 20px; box-shadow: var(--shadow);
}
.course .course-code { font-size: .8rem; font-weight: 700; letter-spacing: .08em; color: var(--accent-deep); text-transform: uppercase; }
.course h3 { margin: 2px 0 4px; }

/* ---------- tables ---------- */

table.plain { width: 100%; border-collapse: collapse; font-size: .95rem; }
table.plain th, table.plain td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.plain th { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* ---------- contact ---------- */

.contact-block { max-width: 620px; }
.contact-block dt { font-weight: 700; margin-top: 18px; }
.contact-block dd { margin-left: 0; }

/* ---------- footer ---------- */

.site-footer {
  background: var(--navy); color: #c9d3e0;
  padding: 40px 0 46px; margin-top: 40px;
  text-align: center; font-size: .95rem;
}
.site-footer a { color: #f0d9a8; }
.site-footer .fine { color: #7d8ba0; font-size: .82rem; margin-top: 18px; }
.footer-links a { margin: 0 8px; }

/* ---------- small screens ---------- */

@media (max-width: 720px) {
  .nav-inner { flex-wrap: wrap; gap: 6px; }
  .nav-links { margin-left: 0; width: 100%; }
  .hero { padding: 24px 0 22px; }
  .section { padding: 44px 0; }
}

/* ---------- print ---------- */

@media print {
  .site-nav, .site-footer, .btn { display: none; }
  body { font-size: 12pt; color: #000; background: #fff; }
}
