/* Full published content. Loaded after the shared page styles. */
.published-content {
  min-width: 0;
  max-width: 100%;
  color: #35415f;
  font-size: 1rem;
  line-height: 1.8;
  overflow-wrap: anywhere;
}
.published-content > :first-child { margin-top: 0; }
.published-content :where(p, ul, ol, dl, blockquote) { max-width: 80ch; }
.published-content p { margin: 0 0 1.2rem; }
.published-content :where(h2, h3, h4, h5, h6) {
  color: #10172f;
  font-family: Space, Arial, sans-serif;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -.035em;
  margin: 2.25rem 0 1rem;
  scroll-margin-top: 8rem;
  text-wrap: balance;
}
.published-content h2 { font-size: clamp(1.75rem, 2.5vw, 2.4rem); }
.published-content h3 { font-size: clamp(1.4rem, 2vw, 1.8rem); }
.published-content h4 { font-size: 1.25rem; }
.published-content :where(h5, h6) { font-size: 1.1rem; }
.published-content :where(ul, ol) { margin: 0 0 1.5rem; padding-left: 1.5rem; }
.published-content li { margin-bottom: .65rem; padding-left: .2rem; }
.published-content li :where(ul, ol) { margin-top: .6rem; margin-bottom: .6rem; }
.published-content :where(strong, b, dt) { color: #10172f; }
.published-content dt { font-weight: 700; margin-top: 1rem; }
.published-content dd { margin: .3rem 0 1rem; }
.published-content a {
  color: #3443c8;
  text-decoration-thickness: 1px;
  text-underline-offset: .2em;
}
.published-content a:hover { color: #16227f; text-decoration-thickness: 2px; }
.published-content a:focus-visible {
  outline: 3px solid #3948cb;
  outline-offset: 4px;
}
.published-content :where(img, picture, figure) { max-width: 100%; }
.published-content img {
  display: block;
  width: auto;
  height: auto;
  margin: 1.5rem 0;
  border: 1px solid #d8def0;
  background: #f5f6fc;
}
.published-content figure { margin: 1.5rem 0; }
.published-content figcaption {
  max-width: 80ch;
  color: #586380;
  font-size: .875rem;
  line-height: 1.6;
  margin-top: .65rem;
}
.published-content blockquote {
  margin: 1.5rem 0;
  padding: 1rem 1.5rem;
  border-left: 4px solid #5965ee;
  background: #edf0ff;
}
.published-content pre {
  max-width: 100%;
  overflow-x: auto;
  padding: 1.25rem;
  background: #f3f5fc;
  border: 1px solid #d8def0;
  font-size: .9375rem;
  line-height: 1.7;
  white-space: pre-wrap;
}

/* The archive-table wrapper keeps wide source tables inside the page. */
.archive-table {
  max-width: 100%;
  overflow-x: auto;
  margin: 1.5rem 0 2rem;
  border: 1px solid #cdd5ed;
  background: #fff;
  scrollbar-width: thin;
  scrollbar-color: #8d9bd6 #edf0ff;
}
.archive-table:focus-visible { outline: 3px solid #3948cb; outline-offset: 4px; }
.published-content table, .archive-table table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: .9375rem;
  line-height: 1.65;
  text-align: left;
}
table.archive-table { display: block; }
.published-content caption, .archive-table caption {
  padding: 1rem;
  color: #10172f;
  font-size: 1rem;
  font-weight: 700;
  text-align: left;
}
.published-content :where(th, td), .archive-table :where(th, td) {
  min-width: 8rem;
  padding: 1rem 1.1rem;
  border-bottom: 1px solid #dce2f2;
  vertical-align: top;
  overflow-wrap: anywhere;
}
.published-content th, .archive-table th { background: #e9edff; color: #10172f; font-weight: 700; }
.published-content tbody tr:nth-child(even), .archive-table tbody tr:nth-child(even) { background: #f7f8fd; }
.published-content td :last-child, .archive-table td :last-child { margin-bottom: 0; }

/* Published faculty details retain readable text and uncropped portraits. */
.faculty-directory {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 1.75rem;
  min-width: 0;
}
.faculty-directory .person {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 1.5rem;
  border: 1px solid #cdd5ed;
  background: #fff;
}
.faculty-directory .faculty-photo {
  display: block;
  width: 100%;
  height: 15rem;
  max-width: 100%;
  object-fit: contain;
  object-position: center;
  margin: 0 0 1.25rem;
  padding: .5rem;
  border: 0;
  background: #edf0ff;
}
.faculty-directory .person h3 {
  margin: 0 0 .65rem;
  color: #10172f;
  font-size: 1.3rem;
  line-height: 1.3;
  letter-spacing: -.025em;
}
.faculty-directory .person p {
  margin: 0 0 .85rem;
  color: #4d5877;
  font-size: 1rem;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.faculty-directory .person p:last-child { margin-bottom: 0; }
.faculty-directory .person :where(dl, ul) { margin: .5rem 0 0; font-size: .9375rem; line-height: 1.65; }
.faculty-directory .person dt { color: #3443c8; font-size: .875rem; font-weight: 700; }
.faculty-directory .person dd { margin: .25rem 0 1rem; }

/* Department photographs and document images keep their original proportions. */
.archive-media-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: start;
  gap: 1.5rem;
  min-width: 0;
  margin: 1.75rem 0;
}
.archive-media-grid > :where(a, figure, div) { min-width: 0; margin: 0; }
.archive-media-grid img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  margin: 0;
  padding: .6rem;
  border: 1px solid #d1d9ef;
  background: #f3f5ff;
}
.archive-media-grid :where(figcaption, p) { font-size: .875rem; line-height: 1.6; margin: .7rem 0 0; }

/* A compact directory for the complete published placement collection. */
.placement-people {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1rem;
  min-width: 0;
  margin: 1.75rem 0;
}
.placement-people > :where(article, figure, .person) {
  min-width: 0;
  margin: 0;
  padding: .85rem;
  border: 1px solid #cdd5ed;
  background: #fff;
}
.placement-people img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 11rem;
  object-fit: contain;
  object-position: center;
  margin: 0 0 .8rem;
  padding: .25rem;
  border: 0;
  background: #edf0ff;
}
.placement-people :where(h3, h4, figcaption) {
  margin: 0 0 .4rem;
  color: #10172f;
  font-family: Space, Arial, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -.015em;
  overflow-wrap: anywhere;
}
.placement-people p { margin: .35rem 0 0; color: #55607e; font-size: .875rem; line-height: 1.55; }
.placement-posters {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 1.5rem;
  min-width: 0;
  margin: 1.75rem 0;
}
.placement-posters > :where(a, figure, div) { min-width: 0; margin: 0; }
.placement-posters img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  margin: 0;
  border: 1px solid #cdd5ed;
  background: #fff;
}
.placement-posters :where(figcaption, p) { margin: .75rem 0 0; color: #55607e; font-size: .875rem; line-height: 1.6; }

/* Expanded desktop menus stay inside the viewport and scroll independently. */
@media (min-width: 1101px) {
  #navigation .nav-panel {
    min-height: 0;
    max-height: 64vh;
    max-height: min(64vh, calc(100dvh - 150px));
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    scrollbar-width: thin;
    scrollbar-color: #8d9bd6 #edf0ff;
  }
  #navigation .nav-panel > * { min-width: 0; }
}
@media (max-width: 1200px) {
  .placement-people { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (max-width: 1000px) {
  .faculty-directory, .archive-media-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .placement-people { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .published-content :where(h2, h3, h4, h5, h6) { margin-top: 1.75rem; }
  .faculty-directory { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
  .faculty-directory .person { padding: 1.1rem; }
  .faculty-directory .faculty-photo { height: 13rem; }
  .faculty-directory .person h3 { font-size: 1.15rem; }
  .faculty-directory .person p { font-size: .9375rem; }
  .archive-media-grid { grid-template-columns: 1fr; }
  .placement-people { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; }
  .placement-posters { grid-template-columns: 1fr; }
}
@media (max-width: 460px) {
  .faculty-directory { grid-template-columns: 1fr; }
  .faculty-directory .faculty-photo { height: 16rem; }
  .placement-people { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .placement-people img { height: 10rem; }
  .placement-people > :where(article, figure, .person) { padding: .7rem; }
}
@media print {
  .published-content, .faculty-directory .person p { color: #111; }
  .archive-table { overflow: visible; border-color: #bbb; }
  .faculty-directory { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .placement-people { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .faculty-directory .person, .placement-people > *, .placement-posters > *, .archive-media-grid > * { break-inside: avoid; }
  .published-content :where(h2, h3, h4, h5, h6) { break-after: avoid; }
}
