/* The breadcrumb is defined once, in assets/css/v21-system.css (v22 §14). */
/* ============================================================================
   v21-credits.css — the attribution register.
   Consumes only tokens from v21-system.css.

   WHY THIS PAGE LOOKS LIKE A REGISTER AND NOT AN ESSAY
     credits.html is where several licences are actually discharged, and the
     prose version made "what is used, where, by whom, under what terms" a
     reading exercise. The four facts every record must answer are now in a
     fixed position on every entry, so a reader — or a rights holder checking
     us — finds them in the same place each time. The prose is kept underneath,
     verbatim, because in several cases the exact wording IS the obligation.
   ============================================================================ */

/* ------------------------------------------------------------------ shell -- */
.cr-h1 { font-family: var(--v-display); font-weight: 400; font-size: var(--v-t-h2);
  line-height: 1.1; color: var(--v-ink); margin: 0 0 var(--v-4); text-wrap: balance; }
.cr-lede { font-size: var(--v-t-body); line-height: 1.72; color: var(--v-ink-2);
  max-width: 60ch; margin: 0 0 var(--v-5); }

/* the one-line statement of scale, so the page is honest about its own size */
.cr-count { font-family: var(--v-ui); font-size: var(--v-t-xs); color: var(--v-ink-3);
  margin: 0 0 var(--v-7); padding-bottom: var(--v-5);
  border-bottom: 1px solid var(--v-ivory-3); }
.cr-count b { font-weight: 600; color: var(--v-ink-2); font-variant-numeric: tabular-nums; }

/* --------------------------------------------------------------- layout ---- */
.cr-layout { display: grid; gap: clamp(28px, 4vw, 64px);
  grid-template-columns: 210px minmax(0, 1fr); align-items: start; }

.cr-nav { position: sticky; top: 88px; }
.cr-nav h2 { font-family: var(--v-sc); font-size: var(--v-t-eyebrow); letter-spacing: .15em;
  text-transform: uppercase; color: var(--v-bronze); margin: 0 0 var(--v-3); font-weight: 400; }
.cr-nav ol { list-style: none; margin: 0; padding: 0; counter-reset: cr; }
.cr-nav li { counter-increment: cr; }
.cr-nav a { display: flex; gap: var(--v-2); align-items: baseline; padding: 6px 0;
  font-family: var(--v-ui); font-size: var(--v-t-sm); color: var(--v-ink-2);
  text-decoration: none; line-height: 1.35; }
.cr-nav a::before { content: counter(cr, decimal-leading-zero);
  font-size: .68rem; color: var(--v-bronze-soft); font-variant-numeric: tabular-nums;
  flex: 0 0 auto; }
.cr-nav a:hover { color: var(--v-maroon); }

/* ------------------------------------------------------------- category ---- */
.cr-cat { padding-bottom: var(--v-8); }
.cr-cat + .cr-cat { border-top: 1px solid var(--v-ivory-3); padding-top: var(--v-7); }
.cr-cat-h { font-family: var(--v-display); font-size: var(--v-t-h3); font-weight: 400;
  line-height: 1.2; color: var(--v-ink); margin: 0 0 var(--v-3);
  scroll-margin-top: 96px; }
.cr-cat-i { font-size: var(--v-t-sm); line-height: 1.72; color: var(--v-ink-2);
  max-width: 66ch; margin: 0 0 var(--v-6); }

/* --------------------------------------------------------------- record ---- */
.cr-rec { border-top: 1px solid var(--v-ivory-3); padding: var(--v-5) 0 var(--v-2);
  scroll-margin-top: 96px; }
.cr-rec:first-of-type { border-top: 0; padding-top: 0; }
.cr-head { display: flex; flex-wrap: wrap; gap: var(--v-2) var(--v-4);
  align-items: baseline; justify-content: space-between; margin-bottom: var(--v-4); }
.cr-n { font-family: var(--v-display); font-size: 1.14rem; font-weight: 400;
  line-height: 1.32; color: var(--v-ink); margin: 0; max-width: 54ch; }
.cr-ver { font-family: var(--v-ui); font-size: var(--v-t-xs); color: var(--v-ink-3);
  font-variant-numeric: tabular-nums; }

/* Delivery is a fact about reach, so it is stated as a word and never as colour
   alone. The tint only reinforces what the label already says. */
.cr-badge { font-family: var(--v-sc); font-size: .64rem; letter-spacing: .11em;
  text-transform: uppercase; padding: 5px 11px; border-radius: 999px;
  border: 1px solid var(--v-ivory-3); color: var(--v-ink-3); white-space: nowrap;
  flex: 0 0 auto; }
.cr-badge-ship { border-color: var(--v-bronze-soft); color: var(--v-bronze); }
.cr-badge-opt  { border-color: #e6c9b4; color: var(--v-saffron); }

.cr-fields { display: grid; gap: 1px; margin: 0; background: var(--v-ivory-3);
  border: 1px solid var(--v-ivory-3); border-radius: var(--v-radius-s); overflow: hidden;
  grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cr-f { background: var(--v-paper); padding: var(--v-4); }
.cr-f dt { font-family: var(--v-sc); font-size: var(--v-t-eyebrow); letter-spacing: .13em;
  text-transform: uppercase; color: var(--v-ink-3); margin-bottom: 5px; }
.cr-f dd { overflow-wrap: anywhere; margin: 0; font-size: var(--v-t-sm); line-height: 1.62; color: var(--v-ink); }
.cr-f dd a { color: var(--v-maroon); text-decoration: underline; text-underline-offset: 3px; }
/* "Required of us" is the field a rights holder came to read */
.cr-f-ob { background: var(--v-ivory-2); }
.cr-f-ob dd { color: var(--v-ink-2); }

.cr-note { font-size: var(--v-t-sm); line-height: 1.72; color: var(--v-ink-2);
  max-width: 68ch; margin: var(--v-4) 0 0; padding-left: var(--v-4);
  border-left: 2px solid var(--v-bronze-soft); }

.cr-detail { margin-top: var(--v-4); }
.cr-detail p { font-size: var(--v-t-sm); line-height: 1.75; color: var(--v-ink-2);
  max-width: 70ch; margin: 0 0 var(--v-3); }
.cr-detail ul { margin: 0 0 var(--v-3); padding-left: 1.15em; }
.cr-detail li { font-size: var(--v-t-sm); line-height: 1.7; color: var(--v-ink-2);
  max-width: 70ch; margin-bottom: 5px; }
.cr-detail a { color: var(--v-maroon); text-decoration: underline; text-underline-offset: 3px; }
.cr-detail code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .86em; background: var(--v-ivory-2); padding: 1px 5px; border-radius: 4px; }
/* the verbatim licence string — it is quoted, so it is set apart */
.cr-detail .mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .82rem; line-height: 1.65; color: var(--v-ink); background: var(--v-ivory-2);
  border-left: 2px solid var(--v-bronze-soft); padding: var(--v-3) var(--v-4);
  max-width: 70ch; }

/* ---------------------------------------------------------- corrections ---- */
.cr-end { background: var(--v-ivory-2); border-radius: var(--v-radius);
  padding: clamp(22px, 2.6vw, 34px); margin-top: var(--v-4); }
.cr-end p { font-size: var(--v-t-sm); line-height: 1.75; color: var(--v-ink-2);
  max-width: 62ch; margin: 0 0 var(--v-4); }
.cr-end p:last-child { margin-bottom: 0; }
.cr-upd { font-family: var(--v-ui); font-size: var(--v-t-xs); color: var(--v-ink-3);
  margin: var(--v-7) 0 0; padding-top: var(--v-4); border-top: 1px solid var(--v-ivory-3); }

/* ------------------------------------------------------------ responsive --- */
@media (max-width: 900px) {
  /* Gate 7: 1fr is minmax(auto, 1fr), so the column could not shrink below its
     longest unbreakable string and the page scrolled sideways by 27 px at
     320 px — the WCAG 1.4.10 reflow width. minmax(0, 1fr) lets it shrink, and
     long URLs in the records now wrap instead. */
  .cr-layout { grid-template-columns: minmax(0, 1fr); }
  .cr-nav { position: static; padding-bottom: var(--v-5);
    border-bottom: 1px solid var(--v-ivory-3); }
  .cr-nav ol { display: flex; flex-wrap: wrap; gap: var(--v-2) var(--v-4); }
  .cr-nav a { padding: 4px 0; }
}
@media (max-width: 560px) {
  .cr-fields { grid-template-columns: minmax(0, 1fr); }
  /* the longest badge ("Consulted; facts used, prose not reproduced") is wider
     than a 320 px screen on one line */
  .cr-badge { white-space: normal; flex-shrink: 1; max-width: 100%; }
  .cr-head { justify-content: flex-start; }
}

/* v27 — a licence reproduced verbatim (the wording is the obligation). It must
   wrap on a phone: pre-wrap keeps the original line breaks, overflow-wrap
   breaks a long URL rather than scrolling the page sideways. */
.cr-licence { font-family: var(--v-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);
  font-size: var(--v-t-xs); line-height: 1.6; color: var(--v-ink-2);
  white-space: pre-wrap; overflow-wrap: anywhere; max-width: 100%;
  background: var(--v-ivory-2, transparent); border: 1px solid var(--v-ivory-3);
  border-radius: 4px; padding: var(--v-3) var(--v-4); margin: var(--v-3) 0; }
/* v27: a badge may wrap at any width below a wide desktop — the longer
   delivery labels overflowed a 640 px window by 13 px */
@media (max-width: 1100px) {
  .cr-badge { white-space: normal; flex-shrink: 1; max-width: 100%; }
}
