:root {
  color-scheme: light;
  --background: #fff;
  --text: #494e52;
  --muted: #626b73;
  --link: #24778e;
  --link-hover: #206a7f;
  --border: #f0f1f2;
  --footer: #f2f3f3;
  --footer-border: #bdc1c4;
  --blank: #eff1f2;
  --blank-title: #e6f1f4;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --background: #25282b;
  --text: #e3e6e8;
  --muted: #afb7bc;
  --link: #73c4dc;
  --link-hover: #a5dbea;
  --border: #363b3f;
  --footer: #202326;
  --footer-border: #454b50;
  --blank: #34393d;
  --blank-title: #2e4148;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--background);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-size: 18px;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--link); text-underline-offset: 3px; overflow-wrap: anywhere; }
a:hover { color: var(--link-hover); }
button { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 5px;
  border-radius: 2px;
}
[hidden] { display: none !important; }
.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 10;
  padding: 10px 16px;
  background: var(--background);
  border: 1px solid var(--link);
}
.skip-link:focus { top: 10px; }
.masthead { border-bottom: 1px solid var(--border); }
.header-inner {
  max-width: 1280px;
  min-height: 70px;
  margin: 0 auto;
  padding: 8px 18px;
  display: flex;
  align-items: center;
  gap: 40px;
}
.brand { margin-right: 16px; min-width: 0; font-weight: 700; }
.header-inner a { color: var(--text); text-decoration: none; }
.primary-nav { display: flex; align-items: center; gap: 36px; flex-shrink: 0; }
.primary-nav a { position: relative; padding: 13px 0; white-space: nowrap; }
.primary-nav a::after {
  content: "";
  position: absolute;
  bottom: 5px;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--link);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 150ms ease;
}
.primary-nav a:hover::after, .primary-nav a[aria-current="page"]::after { transform: scaleX(1); }
.theme-toggle {
  margin-left: auto;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  cursor: pointer;
}
.theme-toggle:hover { background: var(--blank); }
.icon { width: 17px; height: 17px; flex-shrink: 0; vertical-align: -2px; }
.theme-toggle .icon { width: 21px; height: 21px; }
.site-layout {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 36px 18px 70px;
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 54px;
  flex: 1;
  align-items: start;
}
.sidebar { position: sticky; top: 30px; font-size: 13.5px; overflow-wrap: anywhere; }
.portrait-frame {
  width: 175px;
  height: 175px;
  padding: 5px;
  border: 1px solid var(--border);
  border-radius: 50%;
  margin-bottom: 17px;
}
.portrait-image, .portrait-blank { width: 100%; height: 100%; border-radius: 50%; }
.portrait-image { display: block; object-fit: cover; }
.portrait-blank { background: var(--blank); }
.profile-name { margin: 0 0 8px; font-size: 18px; line-height: 1.4; }
.profile-bio { margin: 0 0 18px; line-height: 1.5; white-space: pre-line; }
.profile-empty { margin: 8px 0 24px; }
.profile-empty .blank-line { height: 8px; margin-bottom: 13px; }
.profile-empty .name-blank { width: 140px; height: 12px; }
.profile-empty .bio-blank { width: 115px; }
.profile-details { margin: 0; padding: 0; list-style: none; }
.profile-details li { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; }
.profile-details a { display: inline-flex; align-items: center; gap: 8px; color: var(--text); text-decoration: none; }
.profile-details a:hover { text-decoration: underline; }
.contact-toggle { display: none; }
.page-content { min-width: 0; max-width: 950px; }
.page-content:focus { outline: none; }
h1, .section-heading { margin: 0 0 24px; font-size: 28px; line-height: 1.3; font-weight: 700; }
.section-heading { margin-top: 40px; }
p { margin: 0 0 20px; }
.section-copy { overflow-wrap: anywhere; }
.section-copy ul { padding-left: 22px; }
.section-copy li { margin-bottom: 9px; }
.empty-copy { padding: 6px 0 16px; }
.empty-copy.compact { padding-bottom: 0; }
.blank-line {
  display: block;
  height: 8px;
  margin-bottom: 17px;
  background: var(--blank);
  border-radius: 2px;
}
.blank-line.full { width: 94%; }
.blank-line.wide { width: 83%; }
.blank-line.medium { width: 65%; }
.blank-line.short { width: 43%; }
.empty-record { margin: 37px 0 48px; }
.empty-record:first-child { margin-top: 34px; }
.blank-line.title-line { width: 73%; height: 15px; background: var(--blank-title); margin-bottom: 22px; }
.blank-line.title-line.shorter { width: 59%; }
.metadata-line { margin-bottom: 28px; }
.teaching-placeholder { margin-bottom: 56px; }
.record { margin: 30px 0 40px; overflow-wrap: anywhere; }
.record h2 { margin: 0 0 12px; font-size: 22px; line-height: 1.3; }
.record h2 a { color: var(--link); }
.record p { margin-bottom: 14px; }
.record-metadata { font-size: 16px; }
.record-authors { font-size: 16px; }
.record-links { display: flex; flex-wrap: wrap; gap: 16px; font-size: 15px; }
body[data-page="publications"] .record { margin: 0 0 26px; }
body[data-page="publications"] .record h2 { margin-bottom: 0; font-size: 18px; line-height: 1.5; }
body[data-page="publications"] .record p { margin-bottom: 0; font-size: inherit; }
body[data-page="publications"] .record-links { margin-top: 3px; font-size: inherit; }
.site-footer { background: var(--footer); border-top: 1px solid var(--footer-border); color: var(--muted); }
.footer-inner { max-width: 1280px; margin: 0 auto; padding: 26px 18px 28px; font-size: 12px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 20px; margin-bottom: 18px; font-size: 14px; }
.site-footer a { color: inherit; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-inner p { margin: 0 0 4px; }
.footer-social { margin-bottom: 12px; }
.noscript-note { padding: 0 18px; font-size: 14px; }

@media (max-width: 1023px) {
  .site-layout { grid-template-columns: 185px minmax(0, 1fr); gap: 35px; }
}
@media (max-width: 767px) {
  body { font-size: 16px; }
  .header-inner { min-height: 64px; padding: 8px 20px; gap: 22px; font-size: 15px; }
  .brand { margin-right: 0; max-width: 34%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .primary-nav { gap: 22px; }
  .theme-toggle { width: 36px; height: 36px; }
  .site-layout { display: block; padding: 26px 22px 55px; }
  .sidebar { position: static; display: grid; grid-template-columns: 90px minmax(0, 1fr); column-gap: 20px; margin-bottom: 38px; }
  .portrait-frame { width: 90px; height: 90px; grid-row: 1 / 3; margin: 0; padding: 3px; }
  .profile-content { align-self: center; }
  .profile-name { font-size: 17px; }
  .profile-bio { margin-bottom: 6px; }
  .profile-empty { margin: 8px 0; }
  .contacts { grid-column: 2; }
  .contact-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 0;
    border: 0;
    color: var(--muted);
    background: transparent;
    font-size: 13px;
    cursor: pointer;
  }
  .contact-toggle .icon { width: 12px; height: 12px; }
  .contact-toggle[aria-expanded="true"] .icon { transform: rotate(180deg); }
  .contacts .profile-details { display: none; padding-top: 10px; }
  .contacts.is-open .profile-details { display: block; }
  .profile-details li, .profile-details a { line-height: 1.6; }
  h1, .section-heading { font-size: 25px; margin-bottom: 22px; }
  .section-heading { margin-top: 34px; }
  .record h2 { font-size: 21px; }
  .empty-record { margin-bottom: 42px; }
  .footer-inner { padding: 23px 22px; }
}
@media (max-width: 380px) {
  .header-inner { gap: 14px; padding-inline: 16px; font-size: 14px; }
  .primary-nav { gap: 15px; }
  .site-layout { padding-inline: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
@media print {
  .masthead, .site-footer, .skip-link, .contact-toggle { display: none; }
  body { background: white; color: black; }
  .site-layout { padding-top: 0; }
  .sidebar { position: static; }
  .contacts .profile-details { display: block; }
}
