/* Long text in the school's hand: a contents lane, a reading lane, numbered clauses. Loaded after site.css. */

/* The contents list: stepped-key numbers, each link a full-size touch target. */
.Statute-contents { padding-block-end: 1rem; }
.Statute-label {
  margin-block-end: 0.5rem;
  font-weight: 500;
  font-variation-settings: "wght" 500;
}
.Statute-list { display: grid; margin: 0; padding: 0; list-style: none; counter-reset: clause; }
.Statute-list > li { counter-increment: clause; }
.Statute-list a {
  display: grid;
  grid-template-columns: 2rem minmax(0, 1fr);
  align-items: center;
  column-gap: 0.75rem;
  min-block-size: 2.75rem;
  font-size: var(--size-of-small-type);
  line-height: 1.3;
  text-decoration: none;
}
.Statute-list a::before {
  --depth-of-the-step: 0.4rem;
  content: counter(clause);
  display: grid;
  place-items: center;
  inline-size: 2rem;
  block-size: 2rem;
  background: var(--colour-of-the-ochre);
  color: var(--colour-of-the-ink);
  font-size: 0.9rem;
  clip-path: polygon(0 0, calc(100% - var(--depth-of-the-step)) 0, calc(100% - var(--depth-of-the-step)) var(--depth-of-the-step), 100% var(--depth-of-the-step), 100% 100%, 0 100%);
}
.Statute-list a:hover { text-decoration: underline; text-decoration-color: var(--colour-of-the-ochre); text-decoration-thickness: 0.1875rem; }

/* The reading lane: clause numbers come from a counter on each heading. */
.Statute-text { counter-reset: clause; }
.Statute-text > :first-child { margin-block-start: 0; }
.Statute-text > h2 { scroll-margin-block-start: 1rem; }
.Statute-text > h2::before { counter-increment: clause; content: counter(clause) ". "; }
.Statute-text a { font-weight: 500; font-variation-settings: "wght" 500; }
.Statute-text code {
  padding-inline: 0.35em;
  background: var(--colour-of-the-deep-slate);
  color: var(--colour-of-the-pale-ink);
  font-size: 0.9em;
  overflow-wrap: anywhere;
}
.Statute-text .Key { font-weight: 500; font-variation-settings: "wght" 500; }

/* The pinned call key on a phone: a small plate of solid ochre inside a solid slate edge of its
   own, so the reading lane passes beneath a ground rather than lying on the key's letters.
   The plate is drawn on the element itself and on its shoulder, both opaque, both square-cornered
   so no cut corner lets a letter of the page through. Small type, small padding; the touch
   target stays 2.75rem tall. The reading lane ends well clear of it. */
@media (max-width: 47.99em) {
  .Dial {
    inset-inline-end: 0.75rem;
    inset-block-end: 0.75rem;
    z-index: 9;
    min-block-size: 2.75rem;
    padding-block: 0.4375rem;
    padding-inline: 0.75rem;
    padding-inline-end: 1rem;
    font-size: 0.9375rem;
    line-height: 1.2;
    background: var(--colour-of-the-ochre);
    color: var(--colour-of-the-ink);
    box-shadow: 0 0 0 0.1875rem var(--colour-of-the-deep-slate);
    transition: none;
  }
  .Dial::before { clip-path: none; background: var(--colour-of-the-ochre); }
  .Dial:hover, .Dial[data-state="pressed"] { translate: none; }
  .Statute-text { padding-block-end: clamp(2.5rem, 9vh, 6.5rem); }
}

/* Lanes on a wide window: contents in three columns, text in six. */
@media (min-width: 56em) {
  .Statute-text { grid-column: 4 / span 6; }
}
