/* ============================================================
   doc-ll.css — the plain document pages

   About, Terms and Privacy share this file. They are the same kind
   of page: a title and a text to be read once, with nothing to
   search, rank or chart. So they get one treatment — a single
   reading measure, ruled sections, and no cards.

   Replaces what those pages were borrowing: legislator.css's
   profile card and label list on About, and the inline <style>
   blocks on Terms and Privacy.
   ============================================================ */

.doc-head {
  padding: 30px 0 0;
}

.doc-head .ll-h1 {
  max-width: 18ch;
}

/* a dateline under the title, where a document has one */
.doc-dateline {
  margin: 14px 0 0;
  color: var(--ll-ink-4);
  font-size: 0.9rem;
}

/* --- label and text ---------------------------------------------
   About is a colophon: a list of terms and what each one means. A
   definition list says that outright, and the label column keeps
   the text to a readable measure without a wrapper to centre it.
   ---------------------------------------------------------------- */
.doc-defs {
  margin: 34px 0 0;
  border-top: 1px solid var(--ll-line-strong);
}

.doc-defs dt {
  padding-top: 20px;
  color: var(--ll-accent);
  font-size: 0.95rem;
  font-weight: 700;
}

.doc-defs dd {
  margin: 6px 0 0;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--ll-line);
  color: var(--ll-ink-2);
  font-size: 1rem;
  line-height: 1.62;
}

.doc-defs dd:last-child {
  border-bottom: 0;
}

.doc-defs dd strong {
  color: var(--ll-ink);
}

.doc-defs a {
  color: var(--ll-accent);
  text-decoration: underline;
  text-decoration-color: var(--ll-accent-wash);
  text-underline-offset: 2px;
}

.doc-defs a:hover {
  text-decoration-color: var(--ll-accent);
}

/* two columns once there is room: the label sits beside its text
   rather than above it, which is how a reference page is set */
@media (min-width: 820px) {
  /* The second column is set to a reading measure rather than to the
     page: past about 75 characters the eye loses the start of the
     next line. Narrowing the column instead of the text keeps each
     row's rule a single unbroken line. */
  .doc-defs {
    display: grid;
    grid-template-columns: 200px minmax(0, 72ch);
    column-gap: 36px;
    /* the container is capped to the two columns as well, so the rule
       across the top ends where the rules between the rows do */
    max-width: calc(236px + 72ch);
  }

  .doc-defs dt {
    grid-column: 1;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--ll-line);
  }

  .doc-defs dd {
    grid-column: 2;
    margin: 0;
    padding-top: 20px;
  }

  /* the rule runs the full width of the row, so the last pair ends
     the list cleanly on both sides */
  .doc-defs dt:last-of-type,
  .doc-defs dd:last-of-type {
    border-bottom: 0;
  }
}

/* --- the source list --------------------------------------------- */
.doc-sources {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* where a sentence introduces the list, or follows it, the list needs
   air on that side rather than running straight on from the prose */
.doc-defs dd > .doc-sources:not(:first-child) {
  margin-top: 10px;
}

.doc-after {
  margin: 12px 0 0;
}

.doc-sources li {
  padding: 3px 0;
}

.doc-note {
  color: var(--ll-ink-4);
  font-size: 0.9rem;
}

/* --- running text ------------------------------------------------
   Terms and Privacy are read top to bottom, so they are set at one
   measure with ruled headings, the same marker the rest of the site
   puts above a section.
   ---------------------------------------------------------------- */
.doc-body {
  max-width: 72ch;
  margin-top: 30px;
}

.doc-body h2 {
  margin: 44px 0 0;
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.018em;
}

.doc-body h2::before {
  content: "";
  display: block;
  width: 30px;
  height: 3px;
  margin-bottom: 13px;
  background: var(--ll-accent);
}

.doc-body h2:first-child {
  margin-top: 0;
}

.doc-body h3 {
  margin: 26px 0 0;
  font-size: 1.03rem;
  font-weight: 700;
}

.doc-body p,
.doc-body li {
  color: var(--ll-ink-2);
  font-size: 1rem;
  line-height: 1.68;
}

.doc-body p {
  margin: 12px 0 0;
}

.doc-body ul,
.doc-body ol {
  margin: 12px 0 0;
  padding-left: 22px;
}

.doc-body li {
  margin-top: 6px;
}

.doc-body a {
  color: var(--ll-accent);
  text-decoration: underline;
  text-decoration-color: var(--ll-accent-wash);
  text-underline-offset: 2px;
}

.doc-body a:hover {
  text-decoration-color: var(--ll-accent);
}

.doc-body strong {
  color: var(--ll-ink);
}

/* a section of a long document, ruled off from the next */
.doc-body section + section {
  margin-top: 40px;
  padding-top: 36px;
  border-top: 1px solid var(--ll-line);
}
