/* One paper and ink palette, shared by every page and detail panel. */
:root {
  --bg: #f4f2eb;
  --paper: #f4f2eb;
  --ink: #282722;
  --muted: #65625a;
  --line: #cec9bd;
  --accent: #4d5548;
  --soft: #e9e5da;
  --header-height: 104px;
}
html { background: var(--bg); scrollbar-gutter: stable; }
body { min-height: 100svh; display: flex; flex-direction: column; isolation: isolate; }
body::before {
  content: ''; position: fixed; inset: 0; z-index: 10; pointer-events: none;
  background: url('assets/paper-grain.svg') repeat;
  opacity: .24; mix-blend-mode: multiply;
}
.site-header, .site-footer { width: 89%; margin-left: auto; margin-right: auto; }
.site-header { flex: none; }
main { flex: 1; min-height: 0; }
.site-footer { flex: none; }
.view { background: transparent; }
.view[aria-hidden="true"] { pointer-events: none; }
.home-hero.original-home { background: transparent; min-height: calc(100svh - var(--header-height) - 73px); }
.original-home .hero-copy h1 { color: var(--ink); }
.original-home .hero-description { color: var(--muted); }
.site-header, .site-footer, .faculty-profile, .archive-toolbar { border-color: var(--line); }
.eyebrow, .detail-label { color: var(--muted); }
.tag { border-radius: 2px; }
.load-more, .search-field { border-radius: 0; }
.segmented { background: var(--soft); }
.segmented button.active { background: var(--paper); box-shadow: none; }
.topic-orbit.active .topic-circle { box-shadow: 0 0 0 5px #d9d4c64d; }
.member-initial { background: var(--soft); color: var(--muted); }
dialog { background: var(--paper); }
dialog::backdrop { background: #27262050; }

/* The same reserved scrollbar width and measured header keep About still. */
#view-about .orbit-stage {
  background: transparent;
  height: calc(100svh - var(--header-height));
  min-height: 440px;
}
#view-about .map-node text { stroke: var(--bg); }
#view-about .map-node .node-ring,
#view-about .map-node:hover .node-ring { fill: var(--bg); }
#view-about .map-node.is-pointed .node-ring,
#view-about .map-node:focus-visible .node-ring { fill: var(--area-color); }
#view-about .center-sun { fill: var(--ink); }
#view-about .center-node text, #view-about .area-node .map-label { fill: var(--ink); }
#view-about .topic-node .map-label { fill: var(--muted); }
#view-about .map-summary, #view-about .map-caption { color: var(--muted); }
#view-about .map-controls, #view-about .map-paper-preview { background: var(--paper); border-color: var(--line); }

/* Contact links are siblings of profile buttons, never nested controls. */
.member-card { display: flex; flex-direction: column; }
.member-profile {
  display: flex; flex: 1; flex-direction: column; align-items: flex-start;
  width: 100%; padding: 0; text-align: left; min-width: 0;
}
.member-profile .member-details { min-height: 3.6em; }
.member-contacts {
  display: grid; grid-template-rows: repeat(2, minmax(22px, auto));
  align-content: start; gap: 3px; width: 100%; min-height: 47px; margin-top: 17px;
}
.member-contacts a, .profile-contacts a {
  width: fit-content; max-width: 100%; font-size: 13px; line-height: 1.65;
  overflow-wrap: anywhere; text-decoration: underline; text-decoration-thickness: 1px;
  text-underline-offset: 4px; text-decoration-color: #9a968a;
  transition: color 220ms, text-decoration-color 220ms;
}
.member-contacts a:hover, .profile-contacts a:hover { color: var(--accent); text-decoration-color: currentColor; }
.profile-contacts { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 17px; }
.member-card .member-link { text-align: left; padding-top: 16px; }
.member-card:focus-within .member-link { border-color: var(--accent); }
.member-card:focus-within .member-photo { border-color: var(--accent); }
/* Start the master's group on a fresh row, retaining the final alumni pair. */
.alumni-row[data-degree-group="phd"] + .alumni-row[data-degree-group="masters"] { grid-column: 1; }
@media (max-width: 760px) {
  .site-header, .site-footer { width: 88%; }
  .member-contacts a { font-size: 12px; }
  .member-contacts { min-height: 58px; }
  .original-home .hero-description { font-size: 15px; }
}

/* Contact location map */
#view-contact .contact-map{margin-top:32px;width:100%;overflow:hidden;border:1px solid var(--line)}
.contact-map iframe{display:block;width:100%;height:450px;border:0}
@media(max-width:760px){.contact-map iframe{height:340px}}

/* Website author credit */
.site-footer { flex-wrap: wrap; }
.footer-credit { white-space: nowrap; }
.footer-credit a { color: inherit; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line); }
.footer-credit a:hover, .footer-credit a:focus-visible { color: var(--ink); text-decoration-color: currentColor; }
@media (max-width: 760px) {
  .site-footer .footer-credit { flex-basis: 100%; text-align: right; padding-top: 0; }
}
