/* grid.css: the hairline-grid system Programs and Our Story share (the founder, 7 Nov 2026: "share the exact same crisp,
   architectural hairline-grid design system and typography", from the reference he pasted). One home for it: the hero
   eyebrow, the ribbon of three between two hairlines, the 1px-gap grid (cards on the ground colour over a hairline
   background, 16px corners), the section head and the sign-off. Tokens from system.css; loaded after it on the two pages. */

.z-light body { background: var(--z-bg); }
.hg-wrap { width: min(1180px, 100% - 2 * var(--z-margin)); margin-inline: auto; }

/* the hero: eyebrow, the light serif title with one italic phrase and the terra full stop, one line under */
.hg-hero { padding: calc(env(safe-area-inset-top, 0px) + 124px) 0 var(--z-gap-3); text-align: center; }
.hg-hero .hg-wrap { width: auto; max-width: 820px; } /* the panel already holds the page margin */
.hg-eyebrow { display: block; margin: 0 0 var(--z-gap-2); font: 600 12px/1.4 var(--z-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--z-ink-3); }
.hg-title { font: var(--z-t-h1); letter-spacing: -0.025em; color: var(--z-ink); margin: 0 auto; text-wrap: balance; }
.hg-title em { font-style: italic; }
.hg-lead { margin: var(--z-gap-3) auto 0; font: 300 clamp(19px, 1rem + .6vw, 24px)/1.4 var(--z-serif); color: var(--z-ink); max-width: 30em; text-wrap: balance; }
.hg-hero-act { margin: var(--z-gap-3) 0 0; }

.hg-body { padding: var(--z-gap-4) 0 var(--z-gap-5); }

/* the ribbon: three items with icons between a top and a bottom hairline */
.hg-ribbon { list-style: none; margin: 0 0 var(--z-gap-4); padding: 18px 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px clamp(24px, 4vw, 56px); border-block: 1px solid var(--z-hair); }
.hg-ribbon li { display: inline-flex; align-items: center; gap: 10px; font: 500 15px/20px var(--z-sans); color: var(--z-ink-2); }
.hg-ribbon svg { flex: none; width: 18px; height: 18px; color: var(--z-terra-ink); }
@media (max-width: 560px) { .hg-ribbon { flex-direction: column; align-items: flex-start; padding: 14px 2px; gap: 10px; } }

/* the grid: gap-px on a hairline background, rounded, overflow hidden; each cell sits on the ground colour */
.hg-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--z-hair); border: 1px solid var(--z-hair); border-radius: var(--z-r-card); overflow: hidden; }
.hg-grid > * { background: var(--z-bg); padding: clamp(24px, 1rem + 1.6vw, 40px); min-width: 0; }
.hg-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.hg-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 900px) { .hg-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .hg-3, .hg-2 { grid-template-columns: minmax(0, 1fr); } }
/* the card rise (zaha.js, 22 Oct) moves a cell's contents, not the cell, so the hairlines never open while it runs */
@media (prefers-reduced-motion: no-preference) {
  .hg-grid > .z-rise { animation: none; }
  .hg-grid > .z-rise > * { animation: z-rise 420ms var(--ease-out) backwards; animation-delay: calc(var(--rise-i, 0) * 60ms); }
}
.hg-num { display: block; margin: 0 0 var(--z-gap-2); font: 500 12px/1.4 var(--z-sans); letter-spacing: .14em; color: var(--z-terra-ink); font-variant-numeric: tabular-nums; }

/* one section head */
.hg-h2 { font: 300 clamp(28px, 1.2rem + 1.4vw, 36px)/1.1 var(--z-serif); letter-spacing: -0.015em; color: var(--z-ink); margin: var(--z-gap-5) 0 var(--z-gap-3); }

/* the outline pill in the hero, with its icon */
.hg-pill-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 20px; border: 1px solid var(--z-ink); border-radius: 999px; background: transparent; color: var(--z-ink); font: var(--z-t-strong); font-size: 15px; cursor: pointer; transition: background-color var(--z-dur-2) var(--z-ease), color var(--z-dur-2) var(--z-ease); -webkit-tap-highlight-color: transparent; }
.hg-pill-btn svg { flex: none; width: 16px; height: 16px; color: var(--z-terra-ink); }
.hg-pill-btn span { white-space: nowrap; }
@media (hover: hover) and (pointer: fine) { .hg-pill-btn:hover { background: var(--z-ink); color: var(--z-bg); } .hg-pill-btn:hover svg { color: inherit; } }
.hg-pill-btn:focus-visible { outline: 2px solid var(--z-terra); outline-offset: 3px; }

/* the sign-off: an aside between a top and a bottom hairline, a heading, one line and the pills */
.hg-signoff { margin: var(--z-gap-5) 0 0; padding: var(--z-gap-5) 0; border-block: 1px solid var(--z-hair); text-align: center; }
.hg-signoff-icon { display: block; width: 22px; height: 22px; margin: 0 auto var(--z-gap-2); color: var(--z-terra-ink); }
.hg-signoff-h { font: 300 clamp(28px, 1.2rem + 1.4vw, 38px)/1.1 var(--z-serif); letter-spacing: -0.015em; color: var(--z-ink); margin: 0 auto; max-width: 18em; text-wrap: balance; }
.hg-signoff p { font: var(--z-t-body); color: var(--z-ink-2); max-width: 32em; margin: 12px auto var(--z-gap-3); text-wrap: balance; }
.hg-pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.hg-pills .z-action { gap: 8px; padding: 0 22px; }
@media (max-width: 560px) { .hg-pills .z-action { flex: 1 1 100%; } }
