/* mirandabaumann.com — single stylesheet. Colors are defined once per theme below. */

:root {
  --bg: #ffffff;
  --text: #1a1a1a;
  --muted: #555555;
  --rule: #e2e2e2;
  --accent: #5b2a86;
  --accent-soft: #8a5cb8;
  --accent-tint: #f5f0fa;
}

/* Dark values, applied when the device prefers dark and no manual choice says light. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1e1e1f;
    --text: #ededea;
    --muted: #b3b3ae;
    --rule: #3a3a3c;
    --accent: #c9a7f0;
    --accent-soft: #9d76cc;
    --accent-tint: #2a2433;
  }
}

/* Dark values, applied when chosen manually. */
:root[data-theme="dark"] {
  --bg: #1e1e1f;
  --text: #ededea;
  --muted: #b3b3ae;
  --rule: #3a3a3c;
  --accent: #c9a7f0;
  --accent-soft: #9d76cc;
  --accent-tint: #2a2433;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 100%;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body { margin: 0; }

.wrap {
  max-width: 46rem;
  margin: 0 auto;
  padding: 0 1.25rem;
}

a { color: var(--accent); text-underline-offset: 0.18em; text-decoration-thickness: 1px; overflow-wrap: anywhere; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--bg);
  color: var(--accent);
  padding: 0.5rem 0.75rem;
  border: 2px solid var(--accent);
  z-index: 10;
}
.skip-link:focus { top: 1rem; }

/* Header */
.site-header { padding-top: 3rem; }
.header-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}
.name {
  font-size: clamp(1.75rem, 5vw, 2.4rem);
  line-height: 1.2;
  margin: 0 0 0.6rem;
  letter-spacing: -0.01em;
  font-weight: 650;
}
/* Subtle static sheen: a thin purple rule beneath the name. */
.name::after {
  content: "";
  display: block;
  width: 4.5rem;
  height: 3px;
  margin-top: 0.7rem;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-soft) 60%, var(--accent));
}
.role { margin: 0; font-size: 1.125rem; font-weight: 600; }
.org { margin: 0; color: var(--muted); }

/* Theme toggle (hidden until JavaScript confirms it can work) */
.theme-toggle {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.35rem;
  padding: 0.35rem 0.7rem;
  font: inherit;
  font-size: 0.875rem;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 999px;
  cursor: pointer;
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-toggle[hidden] { display: none; }
.theme-toggle-track {
  position: relative;
  width: 2rem;
  height: 1.1rem;
  border-radius: 999px;
  background: var(--rule);
}
.theme-toggle-thumb {
  position: absolute;
  top: 0.15rem;
  left: 0.15rem;
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: var(--text);
}
.theme-toggle[aria-pressed="true"] .theme-toggle-track { background: var(--accent); }
.theme-toggle[aria-pressed="true"] .theme-toggle-thumb { left: 1.05rem; background: var(--bg); }

/* Navigation */
.site-nav { margin-top: 1.75rem; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0.6rem 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}
.site-nav a { text-decoration: none; font-weight: 500; font-size: 0.95rem; }
.site-nav a:hover { text-decoration: underline; }

/* Sections */
main section { padding-top: 2.5rem; scroll-margin-top: 1rem; }
h2 {
  font-size: 1.3rem;
  line-height: 1.3;
  margin: 0 0 1rem;
  font-weight: 650;
}
h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin: 1.75rem 0 0.75rem;
  font-weight: 600;
}
h2 + h3 { margin-top: 0; }
p { margin: 0 0 1rem; }

.plain-list { margin: 0; padding-left: 1.25rem; }
.plain-list li { margin-bottom: 0.35rem; }
.plain-list li::marker { color: var(--accent); }

.entry { margin-bottom: 1.1rem; }
.entry p { margin: 0; }
.entry-title { font-weight: 600; }
.entry-org { color: var(--text); }
.entry-date, .entry-note { color: var(--muted); font-size: 0.95rem; }
.entry-current {
  border-left: 3px solid var(--accent);
  background: var(--accent-tint);
  padding: 0.75rem 1rem;
  border-radius: 0 4px 4px 0;
}

/* Publications: unnumbered, with a hanging indent */
.pubs { list-style: none; margin: 0 0 1rem; padding: 0; }
.pubs li { margin-bottom: 1rem; padding-left: 1.5rem; text-indent: -1.5rem; }
.pubs cite { font-style: italic; }
.more { color: var(--muted); }

.link-list { list-style: none; margin: 0 0 1rem; padding: 0; }
.link-list li { margin-bottom: 0.5rem; display: flex; flex-wrap: wrap; gap: 0 0.75rem; }
.link-label { min-width: 8.5rem; font-weight: 600; }

/* Footer */
.site-footer {
  margin-top: 3.5rem;
  border-top: 1px solid var(--rule);
  padding: 1.5rem 0 2.5rem;
  color: var(--muted);
  font-size: 0.875rem;
}
.site-footer p { margin-bottom: 0.6rem; }

@media (max-width: 34rem) {
  .site-header { padding-top: 1.75rem; }
  .header-top { flex-direction: column-reverse; gap: 0.75rem; }
  .theme-toggle { margin-top: 0; align-self: flex-end; }
  .link-label { min-width: 0; width: 100%; }
}

@media print {
  .theme-toggle, .site-nav, .skip-link { display: none; }
  a { color: inherit; }
}
.not-found { padding-top: 3rem; }
