.staff-pagination {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0;
}
.staff-pagination button,
#staff-detail button,
.staff-record-button,
#staff-error button {
  font: inherit;
  padding: 0.65rem 1rem;
  border: 1px solid #c4ced7;
  border-radius: 0.4rem;
  background: #fff;
  color: #143049;
  cursor: pointer;
}
button:disabled {
  opacity: 0.5;
  cursor: default;
}
#staff-error {
  padding: 1rem;
  border-left: 4px solid #fd5739;
  background: #fff2ed;
  margin: 1rem 0;
}
#staff-notice {
  font-size: 0.95rem;
  color: #465a70;
}
#staff-detail {
  padding: 1.5rem;
  border: 1px solid #c4ced7;
  border-radius: 0.5rem;
  margin-top: 1.5rem;
  background: #fff;
}
#staff-detail article {
  padding: 1rem 0;
  border-bottom: 1px solid #ddd;
}
#staff-detail dl {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) 3fr;
  gap: 0.4rem 1rem;
}
#staff-detail dd {
  margin: 0;
  overflow-wrap: anywhere;
}
#staff-detail dt {
  font-weight: 600;
}
.staff-card .witness-badges span {
  white-space: normal;
}
.staff-card small {
  display: block;
  margin: 0.4rem 0;
}
#staff-freshness p {
  font-size: 0.95rem;
}
.staff-grid[aria-busy="true"] {
  opacity: 0.55;
}
#staff-coverage {
  padding-left: 1.1rem;
  font-size: 0.9rem;
}
.staff-record-button {
  text-align: left;
}
#staff-detail-close {
  float: right;
}
@media (max-width: 600px) {
  #staff-detail dl {
    display: block;
  }
  #staff-detail dd {
    margin-bottom: 0.7rem;
  }
  .staff-pagination {
    gap: 0.5rem;
  }
}
/* Directory cards keep sources within profiles instead of repeating the audit UI. */
.staff-toolbar {
  grid-template-columns: 2fr repeat(2, minmax(150px, 1fr));
}
.staff-toolbar select {
  max-width: 100%;
  width: 100%;
}
.staff-card {
  display: flex;
  gap: 1.1rem;
  padding: 1.3rem;
}
.staff-card-main {
  min-width: 0;
  width: 100%;
}
.staff-initials {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #edf2f6;
  color: #163550;
  font-weight: 700;
}
.staff-card h3 {
  font-size: 1.15rem;
  margin: 0;
  line-height: 1.35;
}
.staff-card h3 a {
  text-decoration: none;
  color: #143049;
}
.staff-role {
  margin: 0.3rem 0;
  font-size: 1rem;
  color: #465a70;
}
.staff-chamber {
  font-size: 0.78rem;
  font-weight: 700;
  background: #edf2f6;
  border-radius: 20px;
  padding: 0.3rem 0.65rem;
  white-space: nowrap;
  align-self: flex-start;
}
.staff-text-link {
  border: 0;
  padding: 0;
  background: none;
  color: #173c58;
  font: inherit;
  cursor: pointer;
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.staff-card .witness-org {
  margin: 0.5rem 0;
  font-size: 0.95rem;
}
.staff-card-period,
.staff-muted {
  font-size: 0.88rem;
  color: #526579;
  line-height: 1.55;
}
.staff-card-period {
  margin: 0.4rem 0;
}
.staff-card-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 0.7rem;
  font-size: 0.8rem;
  color: #526579;
}
.staff-card-footer a {
  font-weight: 700;
  color: #173c58;
}
#staff-office-list button {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
  padding: 0.7rem 0;
  border: 0;
  border-bottom: 1px solid #eee;
  background: none;
  font: inherit;
  font-size: 0.85rem;
  text-align: left;
  color: #143049;
  cursor: pointer;
}
#staff-office-list button:hover {
  text-decoration: underline;
}
.staff-profile-open > :not(#staff-detail) {
  display: none !important;
}
#staff-detail {
  margin-top: 0;
  padding: 1.6rem;
  background: white;
}
#staff-detail-close {
  float: none;
  margin-bottom: 1.5rem;
}
#staff-detail-title {
  font-size: 2rem;
  line-height: 1.2;
  margin: 0.5rem 0 1.3rem;
}
#staff-detail-header .staff-role {
  font-size: 1.1rem;
}
.staff-timeline {
  border-left: 2px solid #d7e1e8;
  padding-left: 1.2rem;
}
#staff-detail .staff-timeline article {
  padding: 1rem 0;
}
.staff-timeline h4 {
  font-size: 1.1rem;
  margin: 0 0 0.3rem;
}
.staff-timeline p {
  margin: 0.4rem 0;
}
.staff-timeline details {
  margin-top: 0.8rem;
}
.staff-timeline summary,
.witness-sidebar summary {
  cursor: pointer;
  font-weight: 600;
  color: #143049;
}
.staff-source-row {
  padding: 1rem;
  margin-top: 0.6rem;
  background: #f7f9fa;
  font-size: 0.85rem;
  overflow-wrap: anywhere;
}
#staff-detail .staff-source-row dl {
  grid-template-columns: 120px 1fr;
  font-size: 0.8rem;
}
#staff-detail-more {
  margin-top: 1.2rem;
}
.staff-card a:focus-visible,
.staff-text-link:focus-visible {
  outline: 2px solid #fd5739;
  outline-offset: 4px;
}
@media (max-width: 800px) {
  .staff-toolbar {
    grid-template-columns: 1fr 1fr;
  }
  .staff-card {
    padding: 1rem;
  }
  .staff-initials {
    display: none;
  }
  #staff-detail {
    padding: 1rem;
  }
  #staff-detail .staff-source-row dl {
    grid-template-columns: 1fr;
  }
  .staff-source-row dd {
    margin-bottom: 0.6rem;
  }
}
@media (max-width: 480px) {
  .staff-toolbar {
    grid-template-columns: 1fr;
  }
  .staff-card .witness-card-head {
    flex-direction: column;
    gap: 0.5rem;
  }
}
.staff-directory-page .nav .brand img {
  width: 158px;
  height: 50px;
  object-fit: cover;
}
.staff-profile-link,
.staff-text-link,
#staff-result-heading,
#staff-detail {
  scroll-margin-top: 230px;
}
#staff-office-list {
  padding: 0;
  border: 0;
  background: none;
}
@media (max-width: 1060px) {
  .staff-directory-page .witness-sidebar {
    position: static;
    max-height: none;
    overflow: visible;
    order: 2;
  }
  .staff-directory-page .witness-results {
    order: 1;
  }
}
