:root {
  --bg: #fffff8;
  --fg: #111111;
  --fg-muted: #555555;
  --rule: #cccccc;
  --link: #2166ac;
  --max-width: 42rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #191919;
    --fg: #e8e6e0;
    --fg-muted: #a8a49a;
    --rule: #3a3a3a;
    --link: #7db3e8;
  }
}

:root[data-theme="dark"] {
  --bg: #191919;
  --fg: #e8e6e0;
  --fg-muted: #a8a49a;
  --rule: #3a3a3a;
  --link: #7db3e8;
}

:root[data-theme="light"] {
  --bg: #fffff8;
  --fg: #111111;
  --fg-muted: #555555;
  --rule: #cccccc;
  --link: #2166ac;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  margin: 0 auto;
  max-width: var(--max-width);
  padding: 3rem 1.5rem 4rem;
  background: var(--bg);
  color: var(--fg);
  font-family: "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  font-size: 1.125rem;
  line-height: 1.6;
}

h1, h2, h3 {
  font-weight: 600;
  line-height: 1.25;
}

h1 { font-size: 1.6rem; margin-top: 2.5rem; }
h2 { font-size: 1.3rem; margin-top: 2.5rem; }
h3 { font-size: 1.1rem; }

p, ul, ol {
  margin: 1rem 0;
}

a {
  color: var(--link);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

a:hover {
  opacity: 0.75;
}

strong {
  font-weight: 700;
}

/* header */

.site-header {
  padding-bottom: 1.25rem;
}

.site-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-identity {
  align-items: center;
  border-bottom: none;
  color: var(--fg);
  display: flex;
  gap: 0.6rem;
}

.site-avatar {
  border-radius: 999px;
  display: block;
  height: 40px;
  object-fit: cover;
  width: 40px;
}

.site-name {
  font-size: 1.5rem;
  font-weight: 700;
}

#theme-toggle {
  background: none;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--fg);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  padding: 0.35rem 0.6rem;
}

.site-tagline, .site-links {
  color: var(--fg-muted);
  font-size: 0.95rem;
  margin: 0.4rem 0 0 3.1rem;
}

/* sticky nav bar */

.site-nav {
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
  margin-bottom: 2rem;
  padding: 0.75rem 0;
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-nav a {
  border-bottom: none;
  color: var(--fg-muted);
  margin-right: 1.1rem;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.site-nav a.active,
.site-nav a:hover {
  color: var(--fg);
  border-bottom: 1px solid currentColor;
}

/* main content */

.site-main ul {
  padding-left: 1.3rem;
}

.site-main li {
  margin: 0.4rem 0;
}

/* publications list */

.pub-list {
  list-style: none;
  padding: 0;
}

.pub-list .pub-extra {
  display: none;
}

.pub-list.pub-expanded .pub-extra {
  display: block;
}

.pub-toggle {
  background: none;
  border: 1px solid var(--rule);
  border-radius: 4px;
  color: var(--fg);
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  padding: 0.4rem 0.8rem;
}

.pub-list li {
  margin: 0 0 1.1rem 0;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--rule);
}

.pub-title {
  font-weight: 700;
  margin: 0 0 0.25rem;
}

.pub-link {
  border-bottom: none;
  font-weight: 400;
}

.pub-meta {
  color: var(--fg-muted);
  font-size: 0.9rem;
  margin: 0;
}

.pub-venue {
  font-style: italic;
}

/* experience */

.job {
  margin-bottom: 2rem;
}

.job-header {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25rem 1rem;
}

.job-title {
  font-weight: 700;
}

.job-dates {
  color: var(--fg-muted);
  font-size: 0.95rem;
  white-space: nowrap;
}

.job-org {
  color: var(--fg-muted);
  margin: 0.1rem 0 0.5rem;
}

/* footer */

.site-footer {
  border-top: 1px solid var(--rule);
  color: var(--fg-muted);
  font-size: 0.85rem;
  margin-top: 3rem;
  padding-top: 1.25rem;
}

/* venn svg on home page */

.venn-diagram {
  display: block;
  margin: 2rem auto;
  max-width: 100%;
  height: auto;
}

.venn-diagram text {
  fill: var(--fg);
  font-family: inherit;
  font-size: 0.95rem;
  text-anchor: middle;
}
