/* =============================================================================
   BASE  —  reset, typography, layout primitives
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

/*
 * The browser hides [hidden] elements with `display: none`, but that comes
 * from the UA stylesheet — so ANY author rule setting `display` silently wins
 * and the element stays laid out. For the lightbox that meant an invisible
 * full-screen overlay swallowing every click on the gallery page.
 * This rule makes the hidden attribute authoritative everywhere.
 */
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h-scroll) + 16px);
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.is-locked { overflow: hidden; }

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--space-3);
  font-family: var(--font-head);
  font-weight: 800;
  line-height: var(--lh-tight);
  color: var(--ink-strong);
  text-wrap: balance;
}

h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); font-weight: 700; }
h4 { font-size: var(--fs-h4); font-weight: 700; }

p { margin: 0 0 var(--space-4); }
p:last-child { margin-bottom: 0; }

a {
  color: var(--green-600);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease);
}
a:hover { color: var(--gold-600); }

img, svg, video {
  display: block;
  max-width: 100%;
  height: auto;
}

ul, ol { margin: 0 0 var(--space-4); padding-left: 1.15rem; }
li { margin-bottom: var(--space-2); }
li:last-child { margin-bottom: 0; }

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: var(--space-6) 0;
}

strong, b { font-weight: 700; color: var(--ink-strong); }

blockquote { margin: 0; }

::selection { background: var(--gold-500); color: var(--ink-strong); }

/* ---- Focus -------------------------------------------------------------- */
:focus-visible {
  outline: 3px solid var(--gold-500);
  outline-offset: 3px;
  border-radius: 3px;
}
.on-dark :focus-visible { outline-color: var(--gold-400); }

/* ---- Skip link ---------------------------------------------------------- */
.skip-link {
  position: absolute;
  left: 50%;
  top: -100px;
  transform: translateX(-50%);
  z-index: 999;
  padding: 0.75rem 1.5rem;
  background: var(--green-700);
  color: #fff;
  font-weight: 700;
  border-radius: 0 0 var(--radius) var(--radius);
  transition: top var(--dur) var(--ease);
}
.skip-link:focus { top: 0; color: #fff; }

/* =============================================================================
   LAYOUT
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--wide { max-width: var(--container-wide); }
.container--header { max-width: var(--container-header); }
.container--text { max-width: var(--container-text); }

.site-main { display: block; }

.section {
  position: relative;
  padding-block: var(--section-y);
}
.section--sm    { padding-block: var(--section-y-sm); }
.section--tint  { background: var(--green-tint); }
.section--cream { background: var(--gold-tint); }
.section--flush-top { padding-top: 0; }

/* Grids ------------------------------------------------------------------- */
.grid { display: grid; gap: var(--space-5); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--gap-lg { gap: var(--space-6); }

/* Utilities --------------------------------------------------------------- */
.text-center { text-align: center; }
.text-gold   { color: var(--gold-500); }
.text-green  { color: var(--green-600); }
.text-muted  { color: var(--ink-muted); }
.lead {
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.12rem);
  color: var(--ink-muted);
}
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-4 { margin-top: var(--space-4); }
.mt-5 { margin-top: var(--space-5); }
.mt-6 { margin-top: var(--space-6); }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.icon {
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon--filled { fill: currentColor; stroke: none; }

/* Sprite host never renders */
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* Scroll reveal ----------------------------------------------------------- */
/* Scoped to .js so content is never left invisible if a script fails to run. */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}
.js .reveal.is-visible { opacity: 1; transform: none; }
