/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --text: #1a1a1a;
  --text-secondary: #555;
  --text-tertiary: #888;
  --accent: #8b4513;
  --accent-light: #a0522d;
  --rule: #ddd;
  --bg: #fefdfb;
  --bg-subtle: #f9f7f4;
  --font-serif: 'IBM Plex Serif', Georgia, serif;
  --font-sans: 'IBM Plex Sans', -apple-system, Helvetica Neue, sans-serif;
  --font-mono: 'IBM Plex Mono', Menlo, monospace;
}

html { font-size: 17px; }

body {
  font-family: var(--font-serif);
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  max-width: 740px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
  -webkit-font-smoothing: antialiased;
}

/* ── Links ── */
a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
a:hover { border-bottom-color: var(--accent-light); }

/* ── Header ── */
header {
  text-align: center;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--rule);
}

h1 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 2.2rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.25rem;
}

.tagline {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.contact {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: var(--text-secondary);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem 1.2rem;
}

/* ── Sections ── */
section { margin-bottom: 2.5rem; }

h2 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 1.2rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--rule);
}

/* ── About ── */
#about p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 0.8rem;
}
#about p:last-child {
  font-style: italic;
  margin-bottom: 0;
}

/* ── Positions ── */
.position {
  margin-bottom: 1.8rem;
}
.position:last-child { margin-bottom: 0; }

.position-header { margin-bottom: 0.6rem; }

.position-header h3 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 1.05rem;
  line-height: 1.3;
}

.dept {
  font-weight: 300;
  color: var(--text-secondary);
}
.dept::before { content: "— "; }

.role {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 0.9rem;
  color: var(--text);
}

.meta {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: 0.82rem;
  color: var(--text-tertiary);
}

.position-summary {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 0.8rem;
}

/* ── Subgroups (Duke details) ── */
.subgroup {
  margin-bottom: 1rem;
}
.subgroup:last-child { margin-bottom: 0; }

.subgroup h4 {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 0.82rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.35rem;
}

/* ── Lists ── */
ul {
  list-style: none;
  padding: 0;
}

li {
  font-size: 0.88rem;
  color: var(--text-secondary);
  padding-left: 1rem;
  position: relative;
  margin-bottom: 0.3rem;
}
li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--rule);
}

/* ── Highlights ── */
.highlight {
  font-size: 0.88rem;
  color: var(--text-secondary);
  font-style: italic;
  padding-left: 1rem;
  margin-top: 0.4rem;
  border-left: 2px solid var(--rule);
}

/* ── Publication ── */
.citation {
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ── Civic Table ── */
table {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  border-collapse: collapse;
}

tr { border-bottom: 1px solid var(--bg-subtle); }
tr:last-child { border-bottom: none; }

td { padding: 0.4rem 0; }

.civic-role {
  font-weight: 500;
  width: 120px;
  color: var(--text);
}

.civic-date {
  text-align: right;
  color: var(--text-tertiary);
  font-size: 0.82rem;
  white-space: nowrap;
}

/* ── Skills Grid ── */
.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem 2rem;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.skill-label {
  font-weight: 500;
  color: var(--text);
  display: inline;
}
.skill-label::after { content: " — "; font-weight: 300; color: var(--text-tertiary); }

/* ── Other ── */
#other ul { margin: 0; }
#other li { font-size: 0.9rem; }

/* ── Footer ── */
footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  text-align: center;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--text-tertiary);
}

/* ── Print ── */
@media print {
  body { max-width: 100%; padding: 0; font-size: 11pt; }
  a { color: var(--text); border: none; }
  a[href]::after { content: none; }
  h2 { break-after: avoid; }
  .position { break-inside: avoid; }
}

/* ── Mobile ── */
@media (max-width: 600px) {
  html { font-size: 15px; }
  body { padding: 2rem 1.2rem 3rem; }
  h1 { font-size: 1.8rem; }
  .skills-grid { grid-template-columns: 1fr; }
  .civic-role { width: 90px; }
}
