/* Pergage final visual pass, 9 Nov 2026. Loaded last. Visual only: no copy, no layout restructure.
   1. Active / hover nav underline hugs the word (was drawn across the 16px pill padding, 12px below the text).
   2. Jump links: section headings land clear of the fixed header (were 0-28px under the logo pill).
   3. Pyramid 761-900px: use the stacked phone layout (two columns squeezed the panels to ~110px, one word per line). */

/* 1. Nav underline: size and place it on the text box, not the 44px tap target */
html body .nav__links a{background-origin:content-box!important;background-position:0 calc(100% + 5px)!important}

/* 2. Anchor landing: heading text ~24px below the real header bottom (header pill is 109 / 97 / 102 / 70px tall at 1440 / 1024 / 768 / 390) */
:root{--jump-nav:110px}
@media (max-width:980px){:root{--jump-nav:104px}}
@media (max-width:480px){:root{--jump-nav:72px}}
html body main>section[id],
html body main>section.approach{scroll-margin-top:calc(var(--jump-nav) + 38px - var(--sec-pt))!important}

/* 3. Pyramid at tablet widths: same stacked layout as phones (pyramid whole, then the four panels) */
@media (min-width:761px) and (max-width:900px){
  html body .pyr{grid-template-columns:minmax(0,1fr)!important;grid-auto-rows:auto;gap:0!important}
  html body .pyr__shape{height:92px;min-height:92px;padding-bottom:12px;margin:2px auto;width:100%;max-width:460px}
  html body .pyr__row:nth-child(1) .pyr__shape{grid-row:1}
  html body .pyr__row:nth-child(2) .pyr__shape{grid-row:2}
  html body .pyr__row:nth-child(3) .pyr__shape{grid-row:3}
  html body .pyr__row:nth-child(4) .pyr__shape{grid-row:4;margin-bottom:26px}
  html body .pyr__row:nth-child(1) .pyr__text{grid-row:5}
  html body .pyr__row:nth-child(2) .pyr__text{grid-row:6}
  html body .pyr__row:nth-child(3) .pyr__text{grid-row:7}
  html body .pyr__row:nth-child(4) .pyr__text{grid-row:8}
  html body .pyr__shape--4{padding-bottom:6px}
  html body .pyr__text{margin:4px 0}
}
