/* Prose pages: /privacy, /docs, /terms, /token. Long-read layout and type, prefixed pr-.
   Colours, fonts and widths come from the site.css tokens. Public facts sit on pastel;
   anything sealed or unlinked is drawn in the seal colour (--seal, ink until the design
   sheet defines it). No motion here. */

.pr {
  --pr-measure: 68ch;
  --pr-seal: var(--seal, var(--ink));
  --pr-top: 104px; /* clears the floating nav when a chapter link lands */
  padding-bottom: 24px;
}

/* ------------------------------------------------------------ header -- */

.pr-head {
  padding-bottom: 32px;
  border-bottom: 1px solid var(--line);
}
.pr-kicker {
  margin: 0 0 20px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--ink-2);
}
.pr-head h1 {
  margin: 0 0 20px;
  font-size: clamp(40px, 6.4vw, 72px);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.04em;
}
.pr-lead {
  max-width: 38em;
  margin: 0 0 16px;
  font-size: clamp(18px, 1.6vw, 21px);
  line-height: 1.5;
  color: var(--ink-2);
}
.pr-meta {
  margin: 0;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-2);
}
.pr-ca { margin: 24px 0 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.pr-ca .mono { font-size: 15px; }

/* ------------------------------------------------------ chapter grid -- */

.pr-grid {
  display: grid;
  grid-template-columns: 184px minmax(0, 1fr);
  gap: 64px;
  margin-top: 48px;
}
.pr-toc {
  position: sticky;
  top: var(--pr-top);
  align-self: start;
  font-size: 14px;
}
.pr-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 1px solid var(--line);
}
.pr-toc li { margin: 0; }
.pr-toc a {
  display: block;
  margin-left: -1px;
  padding: 7px 0 7px 16px;
  border-left: 2px solid transparent;
  color: var(--ink-2);
  text-decoration: none;
}
.pr-toc a:hover,
.pr-toc a:focus-visible { color: var(--ink); border-left-color: var(--v); }

.pr-body { min-width: 0; max-width: var(--pr-measure); }
.pr-body section { margin: 0 0 64px; scroll-margin-top: var(--pr-top); }
.pr-body section:last-child { margin-bottom: 0; }
.pr-body h2 {
  margin: 0 0 18px;
  font-size: clamp(26px, 2.6vw, 34px);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.025em;
}
.pr-body h3 {
  margin: 32px 0 10px;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  scroll-margin-top: var(--pr-top);
}
.pr-body p,
.pr-body li,
.pr-body dd { font-size: 17px; line-height: 1.65; }
.pr-body p { margin: 0 0 14px; }
.pr-body a { text-decoration-color: var(--v); text-decoration-thickness: 1px; }
.pr-body a:hover { text-decoration-thickness: 2px; }
.pr-body code {
  padding: 1px 5px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  font-size: 0.86em;
  overflow-wrap: anywhere;
}
.pr-body [data-mount] { margin: 20px 0 8px; }

/* lists: a hairline between items reads calmer than bullets at this length */
.pr-list,
.pr-steps { margin: 0 0 16px; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.pr-list > li,
.pr-steps > li { margin: 0; padding: 14px 0; border-bottom: 1px solid var(--line); }
.pr-steps { counter-reset: pr-step; }
.pr-steps > li {
  position: relative;
  padding-left: 2.75em;
  counter-increment: pr-step;
}
.pr-steps > li::before {
  content: counter(pr-step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 17px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-2);
}
.pr-list strong,
.pr-steps strong { font-weight: 600; }

/* definition lists: a term chip beside its sentence */
.pr-dl { margin: 0 0 16px; border-top: 1px solid var(--line); }
.pr-dl dt { margin: 0; padding-top: 14px; }
.pr-dl dd { margin: 6px 0 0; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.pr-dl .tag {
  display: inline-block;
  padding: 2px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink);
}

/* two-column fact tables; rows stack at phone width */
.pr-table {
  width: 100%;
  margin: 8px 0 20px;
  border-collapse: collapse;
  font-size: 15px;
}
.pr-table caption {
  padding: 0 0 10px;
  text-align: left;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-2);
}
.pr-table th,
.pr-table td {
  padding: 12px 0;
  border-top: 1px solid var(--line);
  vertical-align: top;
  text-align: left;
  line-height: 1.5;
}
.pr-table tr:last-child th,
.pr-table tr:last-child td { border-bottom: 1px solid var(--line); }
.pr-table th { width: 34%; padding-right: 24px; font-weight: 500; color: var(--ink-2); }
.pr-table .num,
.pr-body .num {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  font-size: 0.94em;
  white-space: nowrap;
}

.pr-note {
  margin: 24px 0 0;
  padding-left: 16px;
  border-left: 3px solid var(--v);
  font-weight: 500;
}
.pr-ledger-line {
  margin-top: 24px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  font-size: 15px;
}

.pr-sources { margin: 0 0 16px; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.pr-sources li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 2px 16px;
  margin: 0;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}
.pr-sources span {
  min-width: 0;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
  overflow-wrap: anywhere;
}

/* ------------------------------------------- public on pastel, sealed in ink -- */

.pr-ledger {
  max-width: 52rem;
  margin: 40px 0 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--paper);
  overflow: hidden;
}
.pr-ledger figcaption {
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-2);
}
.pr-ledger ul { margin: 0; padding: 0; list-style: none; }
.pr-ledger li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 20px;
  margin: 0;
  padding: 13px 20px;
  border-bottom: 1px solid var(--line);
  font-size: 16px;
}
.pr-ledger li:last-child { border-bottom: 0; }
.pr-ledger li > span:first-child { flex: 1 1 11em; min-width: 0; }
.pr-open,
.pr-seal {
  flex: none;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1;
}
.pr-open {
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--ground);
  color: var(--ink);
}
/* the redaction bar: the value is withheld, the word says why */
.pr-seal {
  min-width: 11em;
  padding: 6px 12px;
  border-radius: 4px;
  background: var(--pr-seal);
  color: var(--paper);
  text-align: right;
}

.pr-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 0 0 20px;
}
.pr-pair > div { padding: 20px 22px; border-radius: 14px; }
.pr-pair p { margin: 0; font-size: 16px; }
.pr-sealed { background: var(--pr-seal); color: var(--paper); }
.pr-public { border: 1px solid var(--line); background: var(--paper); }

/* --------------------------------------------------------------- phone -- */

@media (max-width: 860px) {
  .pr-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; margin-top: 32px; }
  .pr-toc { position: static; }
  .pr-toc ol { display: flex; flex-wrap: wrap; gap: 8px; border-left: 0; }
  .pr-toc a {
    margin: 0;
    padding: 6px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--paper);
  }
  .pr-toc a:hover,
  .pr-toc a:focus-visible { border-color: var(--v); }
}

@media (max-width: 560px) {
  .pr-head h1 { font-size: 42px; letter-spacing: -0.035em; }
  .pr-body p,
  .pr-body li,
  .pr-body dd { font-size: 16px; }
  .pr-body section { margin-bottom: 48px; }
  .pr-pair { grid-template-columns: minmax(0, 1fr); }
  .pr-ledger li { padding: 12px 16px; }
  .pr-seal { min-width: 8em; }
  .pr-table tr { display: block; padding: 10px 0; border-top: 1px solid var(--line); }
  .pr-table tr:last-child { border-bottom: 1px solid var(--line); }
  .pr-table th,
  .pr-table td { display: block; width: auto; padding: 0; border: 0; }
  .pr-table tr:last-child th,
  .pr-table tr:last-child td { border: 0; }
  .pr-table th { margin-bottom: 4px; padding-right: 0; }
  .pr-table .num { white-space: normal; overflow-wrap: anywhere; }
  .pr-sources li { flex-direction: column; align-items: flex-start; }
}
