/* ============================================================
   WordPress adaptations — loaded after template.css.
   template.css is the prototype stylesheet, unchanged; keep
   site-specific changes here so it can be swapped wholesale.
   ============================================================ */

/* ---- Block wrappers ----
   Core blocks wrap a few elements differently from the prototype
   markup (figure instead of div, etc.). Neutralise the extra
   browser defaults without outranking the template's own rules. */
:where(figure.wp-block-table, figure.wp-block-image) { margin: 0; }
.wp-block-image img { display: block; max-width: 100%; height: auto; }
.gp-portrait img { width: 100%; }
.wp-block-table > table { width: 100%; }

/* Admin bar offsets live in gp-chrome.css, alongside the sticky header. */

/* ---- Generic pages and posts (anything other than the home page) ---- */
.tc-prose > * + * { margin-top: 20px; }
.tc-prose p,
.tc-prose li {
  font-family: var(--font-family-body);
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  max-width: 820px;
}
.tc-prose h2 { font-family: var(--font-family-display); font-size: var(--font-size-h2); line-height: var(--line-height-h2); font-weight: var(--font-weight-bold); margin-top: 40px; }
.tc-prose h3 { font-family: var(--font-family-display); font-size: var(--font-size-h3); line-height: var(--line-height-h3); font-weight: var(--font-weight-bold); margin-top: 30px; }
.tc-prose ul { list-style: disc; padding-left: 1.25em; }
.tc-prose ol { list-style: decimal; padding-left: 1.25em; }
.tc-prose a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.tc-entry .list__lead a { text-decoration: underline; text-underline-offset: 3px; }

/* ---- Accessibility helper used by WordPress ---- */
.screen-reader-text {
  border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
  height: 1px; margin: -1px; overflow: hidden; padding: 0;
  position: absolute; width: 1px; word-wrap: normal !important;
}

/* ---- Print (the rail's download button calls window.print) ---- */
@media print {
  #wpadminbar { display: none !important; }
  html { margin-top: 0 !important; }
}
