/* =========================================================
   SOURCES & RECORDS PAGE SYSTEM
   Structure adapted from CornellSeven.
   Page HTML should use the same class system so layout stays
   centralized here instead of adding per-page CSS.
   ========================================================= */

/* HERO */

.case-file-hero {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 90px 0 64px;
}

.hero-label {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.case-file-hero h1 {
  margin-top: 14px;
  font-size: clamp(3rem, 8vw, 6.4rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
  text-transform: uppercase;
}

.hero-rule {
  width: 92px;
  height: 4px;
  margin: 28px 0;
  background: var(--blue-light);
}

.hero-copy {
  max-width: 800px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.8;
}

/* DOCUMENT INFORMATION */

.document-intro {
  background: transparent;
  border: 0;
}

.document-intro-inner {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  padding: 42px;
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  gap: 50px;
  align-items: center;
  border: 1px solid var(--border);
  background: var(--charcoal);
}

.document-title {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.document-subtitle {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.7;
}

.document-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid var(--border);
}

.meta-item {
  padding: 16px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.meta-item:nth-child(2n) {
  border-right: 0;
}

.meta-item:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.meta-label {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.meta-value {
  display: block;
  margin-top: 4px;
  font-size: 0.91rem;
  font-weight: 750;
}

/* ALLEGATION NOTICE */

.allegation-notice {
  width: min(1180px, calc(100% - 40px));
  margin: 30px auto 0;
  padding: 19px 22px;
  border-left: 4px solid var(--blue-light);
  background: rgba(36, 40, 46, 0.7);
  color: #cfd4d9;
  font-size: 0.9rem;
  line-height: 1.7;
}

.allegation-notice strong {
  color: var(--white);
}

/* OP-ED - HISTORICAL CONTEXT */

.op-ed-section {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  scroll-margin-top: 96px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--charcoal);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.op-ed-header {
  padding: 28px 30px 24px;
  border-bottom: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.3);
}

.op-ed-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.op-ed-title {
  margin-top: 8px;
  font-size: clamp(1.8rem, 4.5vw, 3rem);
  line-height: 1;
  letter-spacing: -0.045em;
  text-transform: uppercase;
}

.op-ed-title s,
.op-ed-subtitle s {
  text-decoration-thickness: 3px;
  text-decoration-color: currentColor;
}

.op-ed-subtitle {
  margin-top: 13px;
  color: #d4d9de;
  font-size: clamp(0.95rem, 1.8vw, 1.08rem);
  font-weight: 720;
  line-height: 1.55;
}

/* OP-ED SHARE BAR */

.op-ed-share-bar {
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.2);
}

.op-ed-share-label {
  margin-right: 3px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.op-ed-share-link,
.op-ed-share-button {
  min-height: 36px;
  padding: 7px 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.32);
  color: var(--white);
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.op-ed-share-link:hover,
.op-ed-share-button:hover {
  background: var(--blue);
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.op-ed-share-link:focus-visible,
.op-ed-share-button:focus-visible,
.op-ed-toggle:focus-visible,
.op-ed-reaction:focus-visible {
  outline: 2px solid var(--white);
  outline-offset: 3px;
}

.op-ed-share-status {
  min-height: 1em;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
}

/* OP-ED SCROLL / EXPAND */

.op-ed-scroll {
  max-height: 540px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 14px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.36) rgba(11, 13, 16, 0.2);
}

.op-ed-scroll::-webkit-scrollbar {
  width: 10px;
}

.op-ed-scroll::-webkit-scrollbar-track {
  background: rgba(11, 13, 16, 0.2);
}

.op-ed-scroll::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
  background-clip: padding-box;
}

.op-ed-scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.5);
  background-clip: padding-box;
}

.op-ed-scroll.is-expanded {
  max-height: none;
  overflow: visible;
  padding-right: 0;
}

.op-ed-content {
  padding: 28px 30px 30px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  gap: 36px;
  align-items: start;
}

.op-ed-copy {
  color: #d8dde2;
  font-size: 0.97rem;
  line-height: 1.82;
}

.op-ed-copy p + p {
  margin-top: 18px;
}

.op-ed-figure {
  margin: 0;
  position: sticky;
  top: 12px;
}

.op-ed-image-link {
  display: block;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background: var(--black);
  box-shadow: var(--shadow);
}

.op-ed-image {
  display: block;
  width: 100%;
  height: auto;
}

.op-ed-caption {
  margin-top: 10px;
  color: #8f98a2;
  font-size: 0.7rem;
  line-height: 1.5;
}

.op-ed-caption a,
.op-ed-sources a {
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.op-ed-contact-action {
  width: 100%;
  min-height: 42px;
  margin-top: 14px;
  padding: 9px 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid var(--border-strong);
  background: var(--blue);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 850;
  text-decoration: none;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.op-ed-contact-action:hover {
  background: var(--blue-light);
  border-color: rgba(255, 255, 255, 0.34);
  transform: translateY(-1px);
}

.op-ed-contact-action:focus-visible {
  outline: 2px solid var(--white);
  outline-offset: 3px;
}

.op-ed-sources {
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.75;
}

.op-ed-sources strong {
  color: var(--white);
}

.op-ed-sources a {
  margin-right: 12px;
}

.op-ed-toggle-wrap {
  padding: 18px 20px;
  display: flex;
  justify-content: center;
  border-top: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.18);
}

.op-ed-toggle {
  min-height: 44px;
  padding: 10px 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(11, 13, 16, 0.3);
  color: var(--white);
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 850;
  letter-spacing: 0.035em;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.op-ed-toggle:hover {
  background: rgba(11, 13, 16, 0.5);
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-2px);
}

.op-ed-toggle-arrow {
  font-size: 1rem;
  line-height: 1;
}

/* LIGHTWEIGHT PUBLIC QUICK REACTIONS */

.op-ed-reactions {
  padding: 15px 20px 17px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  border-top: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.24);
}

.op-ed-reaction-label {
  margin-right: 3px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.op-ed-reaction {
  min-width: 60px;
  min-height: 40px;
  padding: 7px 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.32);
  color: var(--white);
  cursor: pointer;
  line-height: 1;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.op-ed-reaction:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.op-ed-reaction.is-selected {
  border-color: rgba(255, 255, 255, 0.48);
  background: var(--blue);
}

.op-ed-reaction-emoji {
  font-size: 1.12rem;
  line-height: 1;
}

.op-ed-reaction-count {
  min-width: 1.2em;
  color: #dce2e8;
  font-size: 0.74rem;
  font-weight: 850;
  line-height: 1;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.op-ed-reaction.is-selected .op-ed-reaction-count {
  color: var(--white);
}

.op-ed-reaction-status {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
}

@media (max-width: 800px) {
  .op-ed-content {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .op-ed-figure {
    position: static;
    width: min(100%, 320px);
  }

  .op-ed-scroll {
    max-height: 500px;
  }
}

@media (max-width: 700px) {
  .op-ed-section {
    width: min(100% - 28px, 1180px);
  }

  .op-ed-header {
    padding: 23px 22px 20px;
  }

  .op-ed-share-bar,
  .op-ed-reactions {
    padding-left: 14px;
    padding-right: 14px;
  }

  .op-ed-share-label,
  .op-ed-reaction-label {
    width: 100%;
    margin-right: 0;
  }

  .op-ed-content {
    padding: 22px;
  }

  .op-ed-scroll {
    max-height: 460px;
    padding-right: 8px;
  }

  .op-ed-share-link,
  .op-ed-share-button {
    flex: 1 1 auto;
  }
}

/* PRIMARY SOURCE */

.additional-source {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  padding: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 34px;
  align-items: center;
  border: 1px solid var(--border);
  background: var(--charcoal);
}

.additional-source-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.additional-source h2 {
  margin-top: 8px;
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  line-height: 1;
  letter-spacing: -0.04em;
}

.additional-source-copy {
  margin-top: 18px;
  color: #d1d6db;
  line-height: 1.8;
}

.additional-source-copy p + p {
  margin-top: 14px;
}

.additional-source-note {
  margin-top: 18px;
  padding: 16px 18px;
  border-left: 3px solid var(--blue-light);
  background: rgba(11, 13, 16, 0.38);
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.65;
}

.additional-source-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 20px;
  min-height: 42px;
  padding: 9px 15px;
  border: 1px solid var(--border-strong);
  background: var(--blue);
  color: var(--white);
  font-size: 0.84rem;
  font-weight: 800;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.additional-source-action:hover {
  background: var(--blue-light);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.additional-source-image-link {
  display: block;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background: var(--black);
  box-shadow: var(--shadow);
}

.additional-source-image {
  display: block;
  width: 100%;
  height: auto;
}

/* CORNELLSEVEN.COM EXCLUSIVE - CONNECTIONS & SOURCE PACKETS */

.exclusive-connection-feature {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--charcoal);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.exclusive-connection-grid {
  padding: 30px;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(460px, 1.1fr);
  gap: 30px;
  align-items: start;
}

.exclusive-connection-copy {
  color: #d8dde2;
  font-size: 0.95rem;
  line-height: 1.82;
}

.exclusive-connection-copy h2 {
  margin-top: 8px;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.exclusive-connection-copy p + p {
  margin-top: 17px;
}

.exclusive-connection-label {
  color: #ffb4b7;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.exclusive-connection-note {
  margin-top: 22px;
  padding: 16px 18px;
  border-left: 3px solid var(--blue-light);
  background: rgba(11, 13, 16, 0.4);
  color: #cbd1d7;
  font-size: 0.8rem;
  line-height: 1.7;
}

.exclusive-connection-note strong {
  color: var(--white);
}

.exclusive-packet-column {
  min-width: 0;
  display: grid;
  gap: 18px;
}

.exclusive-packet-card {
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background: rgba(7, 10, 14, 0.48);
}

.exclusive-packet-head {
  padding: 15px 17px;
  border-bottom: 1px solid var(--border);
  background: rgba(143, 0, 6, 0.42);
}

.exclusive-packet-head strong {
  display: block;
  font-size: 0.88rem;
  line-height: 1.35;
}

.exclusive-packet-head span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 760;
  line-height: 1.45;
}

.exclusive-pdf-viewer {
  height: 600px;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  background: #11151b;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.34) rgba(11, 13, 16, 0.24);
  user-select: none;
  -webkit-user-select: none;
}

.exclusive-pdf-viewer::-webkit-scrollbar {
  width: 10px;
}

.exclusive-pdf-viewer::-webkit-scrollbar-track {
  background: rgba(11, 13, 16, 0.24);
}

.exclusive-pdf-viewer::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
  background-clip: padding-box;
}

.exclusive-pdf-pages {
  min-height: 100%;
  padding: 12px;
}

.exclusive-pdf-page {
  margin: 0 auto 12px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.42);
}

.exclusive-pdf-page:last-child {
  margin-bottom: 0;
}

.exclusive-pdf-page canvas {
  display: block;
  width: 100%;
  height: auto;
}

.exclusive-pdf-status {
  min-height: 180px;
  display: grid;
  place-items: center;
  padding: 24px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.65;
  text-align: center;
}

@media (max-width: 980px) {
  .exclusive-connection-grid {
    grid-template-columns: 1fr;
  }

  .exclusive-packet-column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .exclusive-pdf-viewer {
    height: 520px;
  }
}

@media (max-width: 700px) {
  .exclusive-connection-feature {
    width: min(100% - 28px, 1180px);
  }

  .exclusive-connection-grid {
    padding: 22px;
  }

  .exclusive-packet-column {
    grid-template-columns: 1fr;
  }

  .exclusive-pdf-viewer {
    height: 500px;
  }
}

/* COURT FILE DOCUMENT SELECTOR */

.court-file-switcher {
  width: min(1180px, calc(100% - 40px));
  margin: 30px auto 0;
  padding: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid var(--border);
  background: rgba(36, 40, 46, 0.72);
}

.court-file-switcher-copy {
  min-width: 0;
}

.court-file-switcher-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.court-file-switcher-title {
  margin-top: 5px;
  font-size: 1rem;
  font-weight: 850;
  letter-spacing: -0.015em;
}

.court-file-tabs {
  display: inline-flex;
  flex: 0 0 auto;
  padding: 4px;
  border: 1px solid var(--border);
  background: var(--charcoal);
}

.court-file-tab {
  min-height: 44px;
  padding: 9px 16px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  text-align: left;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}

.court-file-tab strong {
  display: block;
  color: inherit;
  font-size: 0.84rem;
  line-height: 1.15;
}

.court-file-tab span {
  display: block;
  margin-top: 3px;
  color: #89929c;
  font-size: 0.67rem;
  font-weight: 700;
}

.court-file-tab.is-active {
  background: var(--blue);
  color: var(--white);
}

.court-file-tab.is-active span {
  color: rgba(255, 255, 255, 0.68);
}

.court-file-tab:hover:not(.is-active),
.court-file-tab:focus-visible {
  background: rgba(255, 255, 255, 0.05);
  color: var(--white);
  outline: none;
}

/* SERVICE RECORD NAVIGATION */

.service-record-guide[hidden],
.complaint-guide[hidden],
.mode-switch[hidden],
.claims-section[hidden],
.allegation-notice[hidden] {
  display: none !important;
}

.service-record-guide {
  display: block;
}

.service-record-list {
  display: flex;
  flex-direction: column;
}

.service-record-button {
  width: 100%;
  padding: 17px 20px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: transparent;
  color: var(--white);
  cursor: pointer;
  text-align: left;
  transition:
    background 0.2s ease,
    border-color 0.2s ease;
}

.service-record-button:last-child {
  border-bottom: 0;
}

.service-record-button:hover,
.service-record-button:focus-visible {
  background: rgba(255, 255, 255, 0.035);
  outline: none;
}

.service-record-button.is-active {
  background: var(--blue);
}

.service-record-name {
  display: block;
  font-size: 0.91rem;
  font-weight: 850;
  line-height: 1.3;
}

.service-record-meta {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 720;
  line-height: 1.45;
}

.service-record-button.is-active .service-record-meta {
  color: rgba(255, 255, 255, 0.72);
}

.case-workspace.service-records-mode .section-navigation {
  display: none;
}

.case-controls.service-active {
  justify-content: flex-end;
}

/* TOP CONTROLS */

.case-controls {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.mode-switch {
  display: inline-flex;
  padding: 4px;
  border: 1px solid var(--border);
  background: var(--charcoal);
}

.mode-button {
  min-height: 42px;
  padding: 9px 17px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 800;
}

.mode-button.is-active {
  background: var(--blue);
  color: var(--white);
}

.document-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.document-action {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 15px;
  border: 1px solid var(--border-strong);
  color: var(--white);
  font-size: 0.84rem;
  font-weight: 800;
  transition:
    background 0.2s ease,
    border-color 0.2s ease;
}

.document-action:hover {
  background: var(--charcoal-light);
  border-color: rgba(255, 255, 255, 0.3);
}

/* MAIN WORKSPACE */

.case-workspace {
  width: min(1180px, calc(100% - 40px));
  margin: 24px auto 100px;
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.case-workspace.full-mode {
  grid-template-columns: 1fr;
}

.case-workspace.full-mode .guide-panel {
  display: none;
}

.case-workspace.full-mode .plain-language-panel {
  display: none;
}

/* KEY POINT SIDEBAR */

.guide-panel {
  position: sticky;
  top: 100px;
  border: 1px solid var(--border);
  background: var(--charcoal);
}

.guide-heading {
  padding: 22px;
  border-bottom: 1px solid var(--border);
}

.guide-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.guide-heading h2 {
  margin-top: 6px;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.key-point-list {
  display: flex;
  flex-direction: column;
}

.key-point {
  width: 100%;
  padding: 17px 20px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition:
    background 0.2s ease,
    border-color 0.2s ease;
}

.key-point:last-child {
  border-bottom: 0;
}

.key-point:hover {
  background: rgba(255, 255, 255, 0.035);
}

.key-point.is-active {
  background: var(--blue);
}

.key-point-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.key-point-title {
  color: var(--white);
  font-size: 0.91rem;
  font-weight: 800;
  line-height: 1.3;
}

.key-point-page {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.key-point.is-active .key-point-page {
  color: rgba(255, 255, 255, 0.7);
}

.key-point-description {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.77rem;
  line-height: 1.45;
}

.key-point.is-active .key-point-description {
  color: rgba(255, 255, 255, 0.72);
}

/* DOCUMENT SIDE */

.document-panel {
  width: 100%;
  min-width: 0;
}

.plain-language-panel {
  margin-bottom: 18px;
  padding: 26px;
  border: 1px solid var(--border);
  background: var(--charcoal);
}

.plain-language-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.plain-language-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.plain-language-title {
  margin-top: 7px;
  font-size: clamp(1.45rem, 3vw, 2rem);
  line-height: 1.15;
  letter-spacing: -0.035em;
}

.selected-page-badge {
  flex: 0 0 auto;
  padding: 7px 10px;
  border: 1px solid var(--border-strong);
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 800;
  white-space: nowrap;
}

.plain-language-meta {
  margin-top: 13px;
  color: #8f98a2;
  font-size: 0.78rem;
  font-weight: 700;
}

.plain-language-text {
  margin-top: 18px;
  color: #d1d6db;
  line-height: 1.8;
}

.plain-language-text p + p {
  margin-top: 14px;
}

.plain-language-source {
  margin-top: 19px;
  padding-top: 17px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.6;
}

/* GUIDED SECTION NAVIGATION */

.section-navigation {
  padding: 12px 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--border);
  background: var(--charcoal-light);
}

.section-navigation-label {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-navigation-buttons {
  display: flex;
  align-items: center;
  gap: 9px;
}

.section-nav-button {
  min-height: 38px;
  padding: 7px 11px;
  border: 1px solid var(--border);
  background: var(--charcoal);
  color: var(--white);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 800;
}

.section-nav-button:hover {
  background: var(--blue);
}

.case-workspace.full-mode .section-navigation {
  display: none;
}

/* PDF TOOLBAR */

.pdf-shell {
  width: 100%;
  max-width: 100%;
  border: 1px solid var(--border);
  background: var(--charcoal);
  overflow: hidden;
  scroll-margin-top: 96px;
}

.pdf-toolbar {
  min-height: 58px;
  padding: 9px 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--border);
  background: var(--charcoal-light);
}

.pdf-toolbar-left,
.pdf-toolbar-right {
  display: flex;
  align-items: center;
  gap: 9px;
}

.pdf-nav-button {
  min-width: 42px;
  min-height: 38px;
  padding: 7px 11px;
  border: 1px solid var(--border);
  background: var(--charcoal);
  color: var(--white);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 800;
}

.pdf-nav-button:hover {
  background: var(--blue);
}

.pdf-nav-button:disabled,
.section-nav-button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.pdf-nav-button:disabled:hover,
.section-nav-button:disabled:hover {
  background: var(--charcoal);
}

.current-location {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
}

.page-jump-form {
  display: flex;
  align-items: center;
  gap: 7px;
}

.page-jump-form label {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 700;
}

.page-input {
  width: 65px;
  min-height: 38px;
  border: 1px solid var(--border);
  border-radius: 0;
  outline: none;
  background: var(--charcoal);
  color: var(--white);
  padding: 6px 8px;
  text-align: center;
}

.page-input:focus {
  border-color: rgba(255, 255, 255, 0.45);
}

.pdf-frame {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 880px;
  border: 0;
  background: #e7e7e7;
}

.mobile-pdf-viewer {
  display: none;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  background: #e7e7e7;
}

.mobile-pdf-canvas {
  display: block;
  width: 100%;
  height: auto;
  margin: 0 auto;
  background: #ffffff;
}

.pdf-fallback {
  padding: 18px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.6;
}

.pdf-fallback a {
  color: var(--white);
  text-decoration: underline;
}

/* LEGAL CLAIMS MAP */

.claims-section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto 110px;
  padding-top: 10px;
}

.claims-header {
  max-width: 760px;
  margin-bottom: 30px;
}

.claims-header .section-label {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.claims-header h2 {
  margin-top: 8px;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1;
  letter-spacing: -0.04em;
}

.claims-header p {
  margin-top: 16px;
  color: var(--muted);
  line-height: 1.7;
}

.claims-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.claim-jump {
  min-height: 114px;
  padding: 18px;
  border: 1px solid var(--border);
  background: var(--charcoal);
  color: var(--white);
  text-align: left;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}

.claim-jump:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  background: var(--charcoal-light);
}

.claim-number {
  display: block;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.claim-name {
  display: block;
  margin-top: 7px;
  font-size: 0.94rem;
  font-weight: 800;
  line-height: 1.3;
}

.claim-page {
  display: block;
  margin-top: 7px;
  color: #8e97a1;
  font-size: 0.73rem;
  font-weight: 700;
}

.claims-note {
  margin-top: 20px;
  padding: 17px 19px;
  border-left: 3px solid var(--blue-light);
  background: rgba(36, 40, 46, 0.65);
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.7;
}

/* INDEPENDENT PUBLIC RECORD */

.public-records-section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto 110px;
  padding-top: 10px;
}

.public-records-header {
  max-width: 820px;
  margin-bottom: 34px;
}

.public-records-label {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.public-records-header h2 {
  margin-top: 8px;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1;
  letter-spacing: -0.045em;
}

.public-records-header p {
  margin-top: 18px;
  max-width: 760px;
  color: var(--muted);
  line-height: 1.78;
}

.record-section {
  overflow: hidden;
  margin-top: 28px;
  scroll-margin-top: 110px;
  border: 1px solid var(--border);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent),
    var(--charcoal);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.2);
}

.record-section:first-of-type {
  margin-top: 0;
}

.record-section-top {
  padding: 24px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.28);
}

.record-type {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 850;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.record-date {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  text-align: right;
}

.record-section-main {
  padding: 34px 34px 38px;
  display: grid;
  grid-template-columns: minmax(0, 0.64fr) minmax(0, 1.36fr);
  gap: 54px;
  align-items: start;
}

.record-number {
  color: rgba(255, 255, 255, 0.17);
  font-size: 4rem;
  font-weight: 900;
  line-height: 0.85;
  letter-spacing: -0.08em;
}

.record-title {
  margin-top: 18px;
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.record-source-name {
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.5;
}

.record-copy {
  color: #d8dde2;
  font-size: 1rem;
  line-height: 1.84;
}

.record-copy p + p {
  margin-top: 19px;
}

.record-excerpt + p {
  margin-top: 30px;
}

.case-developments-header {
  margin-top: 82px;
}

.record-excerpt {
  margin-top: 26px;
  padding: 22px 24px;
  border-left: 4px solid var(--blue-light);
  background: rgba(11, 13, 16, 0.48);
}

.record-excerpt-label {
  display: block;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.record-excerpt p {
  color: var(--white);
  font-size: 1.04rem;
  font-weight: 720;
  line-height: 1.7;
}

.stat-grid {
  margin-top: 26px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.4);
}

.stat-grid + p {
  margin-top: 30px;
}

.stat-item {
  padding: 24px;
}

.stat-item + .stat-item {
  border-left: 1px solid var(--border);
}

.stat-number {
  display: block;
  color: var(--white);
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.055em;
}

.stat-label {
  display: block;
  margin-top: 9px;
  color: var(--muted);
  font-size: 0.79rem;
  font-weight: 720;
  line-height: 1.55;
}

.record-note {
  margin-top: 24px;
  padding: 18px 20px;
  border: 1px solid var(--border);
  background: rgba(197, 5, 12, 0.15);
  color: #cbd1d7;
  font-size: 0.87rem;
  line-height: 1.7;
}

.record-note strong {
  color: var(--white);
}

.record-actions {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
}

.record-link {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 17px;
  border: 1px solid var(--border-strong);
  background: var(--blue);
  color: var(--white);
  font-size: 0.84rem;
  font-weight: 800;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.record-link:hover {
  background: var(--blue-light);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.record-link.secondary {
  background: transparent;
}

.record-link.secondary:hover {
  background: rgba(255, 255, 255, 0.05);
}

@media (max-width: 900px) {
  .record-section-main {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .record-number {
    font-size: 3.2rem;
  }
}

@media (max-width: 700px) {
  .public-records-section {
    width: min(100% - 28px, 1180px);
  }

  .record-section-top {
    padding: 19px 20px;
    align-items: flex-start;
  }

  .record-section-main {
    padding: 26px 22px 30px;
  }

  .stat-grid {
    grid-template-columns: 1fr;
  }

  .stat-item + .stat-item {
    border-left: 0;
    border-top: 1px solid var(--border);
  }

  .record-actions {
    display: grid;
  }

  .record-link {
    width: 100%;
  }
}

/* CHI PHI DOCUMENTED HISTORY */

.chapter-history {
  margin-top: 30px;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.28);
}

.chapter-history-item {
  display: grid;
  grid-template-columns: 115px minmax(0, 1fr);
  gap: 24px;
  padding: 24px;
  border-bottom: 1px solid var(--border);
}

.chapter-history-item:last-child {
  border-bottom: 0;
}

.chapter-history-year {
  color: var(--white);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.chapter-history-type {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.chapter-history-content h4 {
  font-size: 1.05rem;
  line-height: 1.35;
  letter-spacing: -0.015em;
}

.chapter-history-content p {
  margin-top: 9px;
  color: #cfd5db;
  font-size: 0.9rem;
  line-height: 1.75;
}

.chapter-history-content strong {
  color: var(--white);
}

@media (max-width: 700px) {
  .chapter-history-item {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 20px;
  }
}

/* MOBILE */

@media (max-width: 950px) {
  .document-intro-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .case-workspace {
    grid-template-columns: 1fr;
  }

  .guide-panel {
    position: static;
  }

  .service-record-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .service-record-button {
    border-right: 1px solid var(--border);
  }

  .key-point-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .key-point {
    border-right: 1px solid var(--border);
  }

  .claims-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pdf-frame {
    height: 740px;
  }
}

@media (max-width: 700px) {
  .case-file-hero,
  .document-intro-inner,
  .allegation-notice,
  .additional-source,
  .case-controls,
  .case-workspace,
  .claims-section {
    width: min(100% - 28px, 1180px);
  }

  .case-file-hero {
    padding: 70px 0 52px;
  }

  .additional-source {
    padding: 22px;
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .additional-source-action {
    width: 100%;
  }

  .document-meta {
    grid-template-columns: 1fr;
  }

  .meta-item,
  .meta-item:nth-child(2n),
  .meta-item:nth-last-child(-n + 2) {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .meta-item:last-child {
    border-bottom: 0;
  }

  .court-file-switcher {
    width: min(100% - 28px, 1180px);
    align-items: stretch;
    flex-direction: column;
  }

  .court-file-tabs {
    width: 100%;
  }

  .court-file-tab {
    flex: 1;
  }

  .case-controls {
    align-items: stretch;
  }

  .mode-switch,
  .document-actions {
    width: 100%;
  }

  .mode-switch .mode-button {
    flex: 1;
  }

  .document-action {
    flex: 1;
  }

  .service-record-list {
    grid-template-columns: 1fr;
  }

  .service-record-button {
    border-right: 0;
  }

  .key-point-list {
    grid-template-columns: 1fr;
  }

  .key-point {
    border-right: 0;
  }

  .plain-language-header {
    display: block;
  }

  .selected-page-badge {
    display: inline-block;
    margin-top: 15px;
  }

  .section-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    padding: 12px;
  }

  .section-navigation-label {
    grid-column: 1 / -1;
  }

  .section-navigation-buttons {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    gap: 10px;
  }

  .section-nav-button {
    width: 100%;
  }

  .pdf-toolbar {
    align-items: stretch;
    flex-direction: column;
    padding: 12px;
  }

  .pdf-toolbar-left {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    gap: 10px;
  }

  .pdf-toolbar-left .pdf-nav-button {
    width: 100%;
  }

  .current-location {
    grid-column: 1 / -1;
    width: 100%;
    text-align: center;
  }

  .pdf-toolbar-right {
    width: 100%;
  }

  .page-jump-form {
    width: 100%;
  }

  .page-input {
    flex: 1;
    min-width: 0;
  }

  body.mobile-pdf-ready .pdf-frame {
    display: none;
  }

  body.mobile-pdf-ready .mobile-pdf-viewer {
    display: block;
  }

  .claims-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .section-nav-button,
  .pdf-nav-button {
    font-size: 0.74rem;
  }
}

/* SOURCES & RECORDS HUB */

.source-hub {
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding: 82px 0 34px;
}

.source-hub-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid var(--border);
  background:
    linear-gradient(115deg, rgba(143, 0, 6, 0.96), rgba(11, 13, 16, 0.94) 68%),
    radial-gradient(circle at 86% 20%, rgba(197, 5, 12, 0.12), transparent 34%);
  box-shadow: var(--shadow);
}

.source-hub-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 44px;
  align-items: end;
}

.source-hub-kicker,
.source-library-kicker,
.drawer-kicker,
.latest-kicker {
  color: #ffb4b7;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.19em;
  text-transform: uppercase;
}

.source-hub h1 {
  max-width: 900px;
  margin-top: 12px;
  font-size: clamp(2.8rem, 7.3vw, 6rem);
  line-height: 0.95;
  letter-spacing: -0.055em;
  text-transform: uppercase;
}

.source-hub-copy {
  max-width: 780px;
  margin-top: 24px;
  color: #c7ced7;
  font-size: clamp(0.98rem, 1.8vw, 1.14rem);
  line-height: 1.8;
}

.source-hub-count {
  padding: 24px 18px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(5, 9, 15, 0.44);
  text-align: center;
}

.source-hub-count strong {
  display: block;
  font-size: clamp(3rem, 7vw, 4.6rem);
  line-height: 0.9;
  letter-spacing: -0.065em;
}

.source-hub-count span {
  display: block;
  margin-top: 11px;
  color: #d7dde5;
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.source-hub-count small {
  display: block;
  margin-top: 16px;
  padding-top: 15px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.55;
}

.source-category-grid {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.source-category-button {
  min-height: 118px;
  padding: 16px 12px;
  border: 1px solid var(--border);
  background: rgba(20, 27, 37, 0.76);
  color: var(--white);
  cursor: pointer;
  text-align: left;
  transition:
    transform 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease;
}

.source-category-button:hover,
.source-category-button:focus-visible,
.source-category-button.is-active {
  transform: translateY(-2px);
  border-color: rgba(197, 5, 12, 0.62);
  background: rgba(197, 5, 12, 0.86);
  outline: none;
}

.source-category-button .category-symbol {
  display: block;
  color: #ff9da1;
  font-size: 1.1rem;
  font-weight: 900;
}

.source-category-button .category-name {
  display: block;
  margin-top: 11px;
  font-size: 0.76rem;
  font-weight: 850;
  line-height: 1.35;
}

.source-category-button .category-count {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 0.71rem;
  font-weight: 800;
}

.latest-updates {
  margin-top: 18px;
  padding: 22px;
  border: 1px solid var(--border);
  background: rgba(19, 29, 41, 0.72);
}

.latest-updates-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 15px;
}

.latest-updates-head h2 {
  margin-top: 4px;
  font-size: clamp(1.35rem, 3vw, 2rem);
  letter-spacing: -0.03em;
}

.latest-updates-head p {
  color: var(--muted);
  font-size: 0.75rem;
}

.latest-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}

.latest-card {
  min-height: 150px;
  padding: 15px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  background: rgba(8, 14, 22, 0.6);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease;
}

.latest-card:hover,
.latest-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(130, 176, 232, 0.56);
  background: rgba(18, 37, 61, 0.72);
  outline: none;
}

.latest-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.latest-card-number {
  font-size: 1.04rem;
  font-weight: 900;
}

.latest-card-badge {
  padding: 3px 6px;
  border: 1px solid rgba(130, 176, 232, 0.42);
  color: #a8c9ef;
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.latest-card-title {
  margin-top: 13px;
  font-size: 0.79rem;
  font-weight: 850;
  line-height: 1.42;
}

.latest-card-date {
  margin-top: auto;
  padding-top: 13px;
  color: #8aa6c6;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.library-controls-shell {
  margin-top: 18px;
  padding: 20px;
  border: 1px solid var(--border);
  background: rgba(20, 27, 37, 0.78);
}

.library-controls-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1.4fr) repeat(3, minmax(150px, 0.55fr));
  gap: 10px;
}

.library-control,
.library-search {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--border-strong);
  background: rgba(11, 13, 16, 0.54);
  color: var(--white);
  outline: none;
}

.library-search {
  padding: 10px 14px;
}

.library-control {
  padding: 9px 11px;
  cursor: pointer;
}

.library-search:focus,
.library-control:focus {
  border-color: rgba(130, 176, 232, 0.7);
}

.library-control option {
  background: #161b22;
  color: var(--white);
}

.library-quick-actions {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.library-status {
  color: var(--muted);
  font-size: 0.77rem;
  font-weight: 760;
}

.library-action-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.library-action-button {
  min-height: 36px;
  padding: 7px 11px;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.36);
  color: var(--white);
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 820;
}

.library-action-button:hover,
.library-action-button:focus-visible {
  background: var(--blue);
  outline: none;
}

/* SEARCHABLE SOURCE LIBRARY */

.public-records-section {
  width: min(1240px, calc(100% - 40px));
  margin: 10px auto 72px;
  padding-top: 0;
}

.public-records-section > .public-records-header {
  display: none;
}

.source-library-heading {
  margin: 42px 0 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.source-library-heading h2 {
  margin-top: 5px;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1;
  letter-spacing: -0.045em;
}

.source-library-heading p {
  max-width: 620px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.7;
}

.record-library-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

/* ALL RECORDS ONLY:
       the entire record list becomes one scroll window when more than 7
       records are visible. The window height is calculated in JavaScript
       from the actual rendered height of the first 7 cards. */
.record-library-list.is-scroll-window {
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  padding-right: 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.34) rgba(11, 13, 16, 0.24);
}

.record-library-list.is-scroll-window > .record-section {
  flex: 0 0 auto;
}

.record-library-list.is-scroll-window::-webkit-scrollbar {
  width: 10px;
}

.record-library-list.is-scroll-window::-webkit-scrollbar-track {
  background: rgba(11, 13, 16, 0.24);
}

.record-library-list.is-scroll-window::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
  background-clip: padding-box;
}

.record-library-list.is-scroll-window::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.5);
  background-clip: padding-box;
}

.record-section {
  --record-accent: #315f93;
  margin-top: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-left: 4px solid var(--record-accent);
  background: rgba(24, 29, 36, 0.92);
  box-shadow: none;
  scroll-margin-top: 96px;
}

.record-section[data-category="evidence"] {
  --record-accent: #7158a8;
}
.record-section[data-category="criminal"] {
  --record-accent: #366da4;
}
.record-section[data-category="cornell"] {
  --record-accent: #547896;
}
.record-section[data-category="chi-phi"] {
  --record-accent: #6d5b42;
}
.record-section[data-category="defendants"] {
  --record-accent: #805476;
}
.record-section[data-category="public"] {
  --record-accent: #80535a;
}

.record-section[hidden] {
  display: none !important;
}

.record-section > .record-section-top {
  display: none;
}

.record-summary-toggle {
  width: 100%;
  padding: 16px 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  border: 0;
  background: transparent;
  color: var(--white);
  cursor: pointer;
  text-align: left;
}

.record-summary-toggle:hover,
.record-summary-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.03);
  outline: none;
}

.record-summary-main {
  min-width: 0;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.record-summary-number {
  color: #e9eef5;
  font-size: 1.05rem;
  font-weight: 900;
  line-height: 1.35;
}

.record-summary-title {
  display: block;
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  font-weight: 880;
  line-height: 1.4;
  letter-spacing: -0.012em;
}

.record-summary-source {
  display: block;
  margin-top: 5px;
  color: #9da8b4;
  font-size: 0.71rem;
  font-weight: 700;
  line-height: 1.45;
}

.record-summary-side {
  min-width: 210px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.record-summary-meta {
  text-align: right;
}

.record-summary-category {
  display: block;
  color: #c8cdd3;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.record-summary-date,
.record-summary-added {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 720;
  line-height: 1.35;
}

.record-summary-added.is-latest {
  color: #c8cdd3;
  font-weight: 850;
}

.record-summary-chevron {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  color: #cdd6df;
  font-size: 0.9rem;
  transition: transform 0.18s ease;
}

.record-section.is-open .record-summary-chevron {
  transform: rotate(180deg);
}

.record-section > .record-section-main {
  display: none;
  padding: 26px 28px 32px;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--border);
  background: rgba(7, 10, 14, 0.22);
}

.record-section.is-open > .record-section-main {
  display: grid;
}

.record-section > .record-section-main > div:first-child {
  display: none;
}

.record-section .record-copy {
  max-width: 940px;
  margin: 0 auto;
  color: #d8dde2;
  font-size: 0.96rem;
  line-height: 1.82;
}

.record-section.flash-record {
  animation: recordFlash 1.2s ease;
}

@keyframes recordFlash {
  0%,
  100% {
    box-shadow: none;
  }
  35% {
    box-shadow:
      0 0 0 2px rgba(197, 5, 12, 0.7),
      0 0 28px rgba(197, 5, 12, 0.25);
  }
}

.no-record-results {
  padding: 36px 24px;
  border: 1px dashed var(--border-strong);
  color: var(--muted);
  text-align: center;
  line-height: 1.7;
}

/* RECORD VIDEO EMBEDS */

.record-video-grid {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.record-video-card {
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.42);
}

.record-video-head {
  min-height: 92px;
  padding: 14px 15px;
  border-bottom: 1px solid var(--border);
  background: rgba(143, 0, 6, 0.28);
}

.record-video-head strong {
  display: block;
  font-size: 0.8rem;
  line-height: 1.45;
}

.record-video-head span {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 760;
}

.record-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #090b0e;
}

.record-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* PRIMARY DOCUMENT LIBRARY */

.primary-document-library {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 38px;
  scroll-margin-top: 96px;
}

.primary-document-library-head {
  padding: 28px 30px;
  border: 1px solid var(--border);
  background: rgba(143, 0, 6, 0.3);
}

.primary-document-library-head h2 {
  margin-top: 7px;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1;
  letter-spacing: -0.04em;
}

.primary-document-library-head p:last-child {
  max-width: 860px;
  margin-top: 15px;
  color: #cbd2da;
  font-size: 0.9rem;
  line-height: 1.75;
}

.primary-document-group {
  margin-top: 22px;
}

.primary-document-group-head {
  margin-bottom: 10px;
  padding: 0 2px;
}

.primary-document-group-head h3 {
  font-size: 1.08rem;
  letter-spacing: -0.015em;
}

.primary-document-group-head p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.55;
}

.primary-document-item {
  overflow: hidden;
  margin-top: 8px;
  border: 1px solid var(--border);
  background: rgba(20, 25, 32, 0.84);
  scroll-margin-top: 96px;
}

.primary-document-item > summary {
  padding: 17px 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  cursor: pointer;
  list-style: none;
}

.primary-document-item > summary::-webkit-details-marker {
  display: none;
}

.primary-document-item > summary:hover,
.primary-document-item > summary:focus-visible {
  background: rgba(255, 255, 255, 0.03);
  outline: none;
}

.primary-document-title {
  display: block;
  font-size: 0.95rem;
  font-weight: 880;
  line-height: 1.4;
}

.primary-document-meta {
  display: block;
  margin-top: 5px;
  color: #9da8b4;
  font-size: 0.69rem;
  font-weight: 720;
  line-height: 1.45;
}

.primary-document-chevron {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  color: #cdd6df;
  transition: transform 0.18s ease;
}

.primary-document-item[open] .primary-document-chevron {
  transform: rotate(180deg);
}

.primary-document-body {
  padding: 24px 26px 27px;
  border-top: 1px solid var(--border);
  background: rgba(7, 10, 14, 0.25);
}

.primary-document-body h4 {
  font-size: 1.02rem;
  line-height: 1.35;
}

.primary-document-body p {
  max-width: 940px;
  margin-top: 12px;
  color: #d3d9df;
  font-size: 0.9rem;
  line-height: 1.78;
}

.primary-document-why {
  max-width: 940px;
  margin-top: 18px;
  padding: 15px 17px;
  border-left: 3px solid var(--blue-light);
  background: rgba(143, 0, 6, 0.24);
  color: #cbd3dc;
  font-size: 0.82rem;
  line-height: 1.7;
}

.primary-document-why strong {
  color: var(--white);
}

.primary-document-body .record-actions {
  max-width: 940px;
  margin-top: 20px;
}

@media (max-width: 700px) {
  .record-video-grid {
    grid-template-columns: 1fr;
  }

  .record-video-head {
    min-height: 0;
  }

  .primary-document-library {
    width: min(100% - 28px, 1180px);
  }

  .primary-document-library-head {
    padding: 23px 20px;
  }

  .primary-document-item > summary {
    padding: 16px;
    gap: 12px;
  }

  .primary-document-body {
    padding: 20px 17px 23px;
  }
}

/* PRIMARY DOCUMENT AND CONTEXT DRAWERS */

.archive-drawer {
  width: min(1240px, calc(100% - 40px));
  margin: 18px auto 0;
  border: 1px solid var(--border);
  background: rgba(24, 29, 36, 0.78);
}

.archive-drawer:last-of-type {
  margin-bottom: 88px;
}

.archive-drawer > summary {
  padding: 22px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.archive-drawer > summary::-webkit-details-marker {
  display: none;
}

.archive-drawer > summary:hover,
.archive-drawer > summary:focus-visible {
  background: rgba(255, 255, 255, 0.025);
  outline: none;
}

.drawer-title {
  margin-top: 4px;
  font-size: clamp(1.15rem, 2.4vw, 1.65rem);
  font-weight: 880;
  letter-spacing: -0.025em;
}

.drawer-description {
  margin-top: 6px;
  max-width: 780px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.6;
}

.drawer-chevron {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  transition: transform 0.18s ease;
}

.archive-drawer[open] .drawer-chevron {
  transform: rotate(180deg);
}

.archive-drawer-content {
  padding: 0 0 30px;
  border-top: 1px solid var(--border);
}

.archive-drawer .case-file-hero {
  padding-top: 44px;
  padding-bottom: 30px;
}

.archive-drawer .case-workspace {
  margin-bottom: 58px;
}

.archive-drawer .claims-section {
  margin-bottom: 38px;
}

.archive-drawer .additional-source,
.archive-drawer .op-ed-section {
  width: min(1180px, calc(100% - 40px));
}

.archive-drawer .op-ed-section {
  margin-bottom: 14px;
}

.source-allegation-note {
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto 16px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  background: rgba(143, 0, 6, 0.25);
  color: #cbd3dc;
  font-size: 0.79rem;
  line-height: 1.7;
}

.source-allegation-note strong {
  color: var(--white);
}

@media (max-width: 1080px) {
  .source-category-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .latest-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .library-controls-grid {
    grid-template-columns: 1fr 1fr;
  }

  .library-search {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .source-hub,
  .public-records-section,
  .archive-drawer,
  .source-allegation-note {
    width: min(100% - 28px, 1240px);
  }

  .source-hub {
    padding-top: 62px;
  }

  .source-hub-hero {
    padding: 26px 22px;
  }

  .source-hub-hero-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .source-hub-count {
    max-width: 220px;
    text-align: left;
  }

  .source-hub-count strong,
  .source-hub-count span,
  .source-hub-count small {
    text-align: left;
  }

  .source-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .latest-grid {
    grid-template-columns: 1fr 1fr;
  }

  .library-controls-grid {
    grid-template-columns: 1fr;
  }

  .library-search {
    grid-column: auto;
  }

  .source-library-heading {
    display: block;
  }

  .source-library-heading p {
    margin-top: 12px;
  }

  .record-summary-toggle {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .record-summary-main {
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 10px;
  }

  .record-summary-side {
    min-width: 0;
    justify-content: space-between;
    padding-left: 54px;
  }

  .record-summary-meta {
    text-align: left;
  }

  .record-section > .record-section-main {
    padding: 22px 18px 26px;
  }

  .archive-drawer > summary {
    padding: 20px;
  }
}

@media (max-width: 520px) {
  .source-category-grid,
  .latest-grid {
    grid-template-columns: 1fr;
  }

  .source-category-button {
    min-height: 92px;
  }

  .latest-card {
    min-height: 126px;
  }

  .record-summary-side {
    padding-left: 0;
  }

  .record-summary-source {
    display: none;
  }
}

/* DIRECT STORY / SECTION LINKS */
.story-link-index {
  margin-top: 18px;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.42);
}

.story-link-index > summary {
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  cursor: pointer;
  list-style: none;
  color: var(--white);
  font-size: 0.82rem;
  font-weight: 850;
}

.story-link-index > summary::-webkit-details-marker {
  display: none;
}

.story-link-index > summary::after {
  content: "v";
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  transition: transform 0.18s ease;
}

.story-link-index[open] > summary::after {
  transform: rotate(180deg);
}

.story-link-index-body {
  padding: 20px;
  border-top: 1px solid var(--border);
}

.story-link-index-heading {
  color: #ffb4b7;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.story-link-index-heading:not(:first-child) {
  margin-top: 24px;
}

.section-link-grid,
.story-link-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.section-link-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.section-anchor-link,
.story-anchor-link {
  padding: 11px 12px;
  display: block;
  border: 1px solid var(--border);
  background: rgba(18, 37, 61, 0.35);
  color: #dce5ef;
  font-size: 0.72rem;
  font-weight: 760;
  line-height: 1.45;
  transition:
    background 0.18s ease,
    border-color 0.18s ease;
}

.section-anchor-link:hover,
.section-anchor-link:focus-visible,
.story-anchor-link:hover,
.story-anchor-link:focus-visible {
  border-color: rgba(197, 5, 12, 0.62);
  background: rgba(197, 5, 12, 0.68);
  outline: none;
}

.story-anchor-link strong {
  margin-right: 5px;
  color: #ff9da1;
  font-size: 0.66rem;
}

.record-permalink {
  background: transparent;
}

@media (max-width: 900px) {
  .section-link-grid,
  .story-link-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .section-link-grid,
  .story-link-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   UW–MADISON SOURCE LIBRARY CATEGORY OVERRIDES
   ========================================================= */

.record-section[data-category="incident"] {
  --record-accent: #c5050c;
}
.record-section[data-category="uw"] {
  --record-accent: #8f0006;
}
.record-section[data-category="aepi"] {
  --record-accent: #b5454a;
}
.record-section[data-category="law"] {
  --record-accent: #9a7748;
}
.record-section[data-category="history"] {
  --record-accent: #77818c;
}

.source-category-button[data-hub-category="incident"] .category-symbol {
  color: #ff9da1;
}
.source-category-button[data-hub-category="uw"] .category-symbol {
  color: #ffb4b7;
}
.source-category-button[data-hub-category="aepi"] .category-symbol {
  color: #efabad;
}
.source-category-button[data-hub-category="law"] .category-symbol {
  color: #dcc08f;
}
.source-category-button[data-hub-category="history"] .category-symbol {
  color: #c2cad2;
}

/* =========================================================
   SOURCES — GUIDED VIEW / FULL DOCUMENT MODE
   ========================================================= */

.case-workspace.is-full-view {
  grid-template-columns: 1fr;
}
.case-workspace.is-full-view .guide-panel,
.case-workspace.is-full-view .plain-language-panel,
.case-workspace.is-full-view .section-navigation {
  display: none;
}
.case-workspace.is-full-view .document-panel {
  grid-column: 1 / -1;
}

/* =========================================================
   SOURCES — PRIMARY SOURCE IMAGE DRAWER
   ========================================================= */

.primary-source-image-grid {
  width: min(var(--content-width), calc(100% - 40px));
  margin: 34px auto 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.primary-source-image-card {
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(11, 13, 16, 0.4);
}

.primary-source-image-card img {
  display: block;
  width: 100%;
  height: auto;
}
.primary-source-image-card figcaption {
  padding: 12px 14px;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.55;
}

/* Shared typography and progressive enhancement. */
.source-hub,
.archive-drawer,
.public-records-section {
  max-width: 1180px;
}
.source-hub-hero {
  padding: 0 0 44px;
  border: 0;
  box-shadow: none;
  background: none;
  overflow: visible;
}
.source-hub-hero h1 {
  margin-top: 18px;
  font-size: clamp(3.25rem, 8.2vw, 7rem);
}
.source-hub-hero h1::after {
  content: "";
  display: block;
  width: 92px;
  height: 4px;
  margin-top: 30px;
  background: var(--red);
}
.source-hub-kicker,
.source-library-kicker,
.drawer-kicker,
.latest-kicker {
  color: var(--muted);
}
.source-hub-count {
  background: var(--surface);
}
.source-hub-count small {
  color: var(--muted-light);
}
.case-file-hero h2 {
  font-size: clamp(2.4rem, 6vw, 5rem);
  line-height: 1;
  text-transform: uppercase;
}
.record-summary-added {
  color: var(--muted);
}
.record-summary-toggle:focus-visible {
  outline: 2px solid white;
  outline-offset: -4px;
}
body:not(.sources-enhanced) .record-section > .record-section-main {
  display: grid;
}
body:not(.sources-enhanced) .record-section > .record-section-top {
  display: flex;
  padding: 15px 25px;
}
body:not(.sources-enhanced) .source-category-grid,
body:not(.sources-enhanced) .library-controls-shell {
  display: none;
}
.primary-source-image-grid {
  width: 100%;
}
.archive-drawer {
  scroll-margin-top: 24px;
}
.library-controls-grid input,
.library-controls-grid select {
  width: 100%;
}
@media (max-width: 700px) {
  .source-hub {
    padding-top: 64px;
  }
  .source-hub-hero h1 {
    font-size: clamp(2.8rem, 13vw, 5rem);
  }
  .source-hub-hero {
    padding: 0 0 30px;
  }
  .source-hub-hero-grid {
    gap: 28px;
  }
}

.source-category-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
@media (max-width: 1000px) {
  .source-category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 600px) {
  .source-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
