/* ==========================================================================
   Ashlar Technologies — one-page site
   Palette: warm stone greys + gold. Display: Playfair Display. Text: Inter.
   Gold #CA8A04 is shared with masonic-tools.co.uk so click-through feels continuous.
   ========================================================================== */

:root {
  /* Stone */
  --stone-50:  #FCFBF9;
  --stone-100: #F6F4F0;
  --stone-150: #EFECE6;
  --stone-200: #E6E2DA;
  --stone-300: #D5CFC3;
  --stone-400: #B3AC9E;
  --stone-500: #8C8577;
  --stone-600: #6A6459;
  --stone-700: #4A4640;

  /* Ink */
  --ink:       #1C1B18;
  --ink-soft:  #3B3833;
  --ink-mute:  #6A6459;

  /* Gold */
  --gold:      #CA8A04;
  --gold-lift: #EAB308;
  --gold-deep: #9A6B08;
  --gold-wash: #FBF3DF;

  --ok:        #15803D;
  --warn:      #B45309;

  --measure: 68ch;
  --radius: 4px;
  --radius-lg: 8px;

  --shadow-sm: 0 1px 2px rgba(28,27,24,.06), 0 1px 3px rgba(28,27,24,.05);
  --shadow-lg: 0 18px 40px -18px rgba(28,27,24,.28), 0 2px 8px rgba(28,27,24,.06);

  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --pad: clamp(1.25rem, 4vw, 2.5rem);
  --section-y: clamp(4rem, 9vw, 7.5rem);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--stone-50);
  color: var(--ink-soft);
  font-family: var(--sans);
  font-size: 1.0625rem;      /* 17px base — audience skews older */
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
@media (min-width: 60em) { body { font-size: 1.125rem; } }

h1, h2, h3 { font-family: var(--serif); color: var(--ink); line-height: 1.15; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(2.25rem, 6vw, 4rem); letter-spacing: -.015em; }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.75rem); letter-spacing: -.01em; }
h3 { font-size: clamp(1.125rem, 1.8vw, 1.375rem); font-weight: 600; }
p { margin: 0 0 1.15rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--gold-deep); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 2px; }

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

.wrap { width: min(100% - (var(--pad) * 2), 76rem); margin-inline: auto; }
.wrap.narrow { width: min(100% - (var(--pad) * 2), 46rem); }
.center { text-align: center; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: .5rem; top: -4rem; z-index: 100;
  background: var(--ink); color: var(--stone-50); padding: .7rem 1.1rem;
  border-radius: var(--radius); text-decoration: none; font-weight: 600;
  transition: top .15s ease;
}
.skip:focus { top: .5rem; color: var(--stone-50); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .45rem;
  font: inherit; font-weight: 600; font-size: .9375rem;
  padding: .8rem 1.4rem; border-radius: var(--radius);
  text-decoration: none; border: 1px solid transparent; cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}
.btn-primary { background: var(--ink); color: var(--stone-50); border-color: var(--ink); }
.btn-primary:hover { background: var(--gold-deep); border-color: var(--gold-deep); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--stone-300); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); background: var(--stone-100); }
.btn-sm { padding: .55rem 1rem; font-size: .875rem; }

.eyebrow {
  font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold-deep); margin: 0 0 1rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(252,251,249,.88);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--stone-200);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; }

.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand-mark { width: 2.1rem; height: 2.1rem; flex: none; border-radius: 5px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; letter-spacing: -.01em; }
.brand-sub { font-size: .6875rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-mute); margin-top: .18rem; }

.nav ul { display: flex; align-items: center; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.nav a:not(.btn) {
  text-decoration: none; color: var(--ink-soft); font-size: .9375rem; font-weight: 500;
  padding: .35rem 0; border-bottom: 2px solid transparent;
}
.nav a:not(.btn):hover { color: var(--ink); border-bottom-color: var(--gold); }

.nav-toggle {
  display: none; background: transparent; border: 1px solid var(--stone-300);
  border-radius: var(--radius); padding: .55rem .6rem; cursor: pointer;
}
.nav-toggle-bars { display: block; width: 1.1rem; }
.nav-toggle-bars span { display: block; height: 2px; background: var(--ink); border-radius: 2px; }
.nav-toggle-bars span + span { margin-top: 4px; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(3.5rem, 7vw, 6rem) 0 0; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(180deg, var(--stone-100) 0%, var(--stone-50) 70%),
    repeating-linear-gradient(90deg, rgba(28,27,24,.028) 0 1px, transparent 1px 88px),
    repeating-linear-gradient(0deg, rgba(28,27,24,.028) 0 1px, transparent 1px 88px);
}

.hero-inner {
  display: grid;
  gap: clamp(2.5rem, 5vw, 4.5rem);
  grid-template-columns: 1fr;
  align-items: center;
}
@media (min-width: 62em) {
  .hero-inner { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); }
}
.hero-copy { max-width: 36rem; }
.hero h1 em { font-style: normal; color: var(--gold-deep); }
.lede { font-size: clamp(1.125rem, 1.9vw, 1.5rem); color: var(--ink-mute); margin-bottom: 2.25rem; max-width: 30rem; line-height: 1.5; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin: 0; }

/* Hero artwork: an isometric coursed ashlar wall. Carries the hero visually
   so the copy can stay short. Blocks settle into place on load. */
.hero-art {
  min-width: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}
.ashlar {
  width: 100%;
  max-width: 30rem;
  height: auto;
  overflow: visible;
}
/* Stacked under the copy on small screens, so keep it from eating the fold. */
@media (max-width: 62em) { .ashlar { max-width: 21rem; } }

.ashlar .f-top   { fill: url(#gTop); }
.ashlar .f-left  { fill: url(#gLeft); }
.ashlar .f-right { fill: url(#gRight); }
.ashlar .gold .f-top   { fill: url(#gGoldTop); }
.ashlar .gold .f-left  { fill: url(#gGoldLeft); }
.ashlar .gold .f-right { fill: url(#gGoldRight); }

.ashlar polygon {
  stroke: rgba(28, 27, 24, .10);
  stroke-width: .75;
  stroke-linejoin: round;
}
.ashlar .gold polygon { stroke: rgba(88, 62, 4, .28); }

.ashlar .glow { transform-origin: center; animation: glow-breathe 9s ease-in-out infinite; }

/* Each block drops the last few pixels into its course, staggered up the wall.
   Fill mode is `backwards`, not `forwards`, and the resting state is the plain
   element: if animations never run, the wall is simply visible rather than
   stuck at opacity 0. */
.js .ashlar .blk {
  animation: block-set .9s cubic-bezier(.16, .84, .44, 1) backwards;
  animation-delay: calc(var(--i, 0) * 70ms + 120ms);
}

@keyframes block-set {
  from { opacity: 0; transform: translateY(-16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes glow-breathe {
  0%, 100% { opacity: .75; transform: scale(1); }
  50%      { opacity: 1;   transform: scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
  .js .ashlar .blk { opacity: 1; transform: none; animation: none; }
  .ashlar .glow { animation: none; }
}

.hero-rule {
  /* Sits at the very foot of the hero as the divider into the next section,
     so the breathing room belongs above it, not below. */
  margin-top: clamp(2.5rem, 5vw, 4.5rem);
  height: 3px;
  background: linear-gradient(90deg, var(--gold) 0%, var(--gold-lift) 16%, var(--stone-300) 44%, var(--stone-200) 100%);
}

/* ---------- Sections ---------- */
.section { padding: var(--section-y) 0; }
.section-tight { padding-block: clamp(3rem, 6vw, 4.5rem); }
.band { background: var(--stone-100); border-block: 1px solid var(--stone-200); }

.section-head { max-width: var(--measure); margin-bottom: clamp(2rem, 4vw, 3rem); }
.section-lede { font-size: 1.0625rem; color: var(--ink-mute); }

/* ---------- Product overview cards ---------- */
.product-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
}
.product-card {
  position: relative; background: #fff; border: 1px solid var(--stone-200);
  border-radius: var(--radius-lg); padding: 1.6rem 1.4rem 1.4rem;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.product-card::before {
  content: ""; position: absolute; inset: 0 auto auto 0;
  width: 3rem; height: 3px; border-radius: var(--radius-lg) 0 0 0;
  background: var(--card-accent, var(--gold));
}
.product-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--stone-300); }
.card-kicker { font-size: .6875rem; letter-spacing: .11em; text-transform: uppercase; color: var(--ink-mute); margin: .4rem 0 .5rem; }
.product-card h3 { margin-bottom: .5rem; font-size: 1.3rem; }
.product-card h3 a { text-decoration: none; color: var(--ink); }
.product-card h3 a::after { content: ""; position: absolute; inset: 0; }
.product-card p { font-size: .9375rem; color: var(--ink-mute); }
.card-status { display: flex; align-items: center; gap: .45rem; margin-top: 1rem; font-size: .8125rem; font-weight: 600; color: var(--ink-soft); }
.dot { width: .5rem; height: .5rem; border-radius: 50%; flex: none; }
.dot-live { background: var(--ok); }
.dot-private { background: var(--stone-400); }

/* ---------- Product sections ---------- */
.product { border-top: 1px solid var(--stone-200); }
.product-alt { background: var(--stone-100); }
.product-inner {
  display: grid; gap: clamp(2.5rem, 5vw, 4.5rem);
  grid-template-columns: 1fr; align-items: center;
}
@media (min-width: 62em) {
  .product-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); }
  .product-alt .product-copy { order: 2; }
  .product-alt .product-visual { order: 1; }
}
.product-copy h2 { margin-bottom: .35em; }
.product-lede { font-size: 1.0625rem; max-width: var(--measure); }
.audience { font-size: .9375rem; color: var(--ink-mute); padding-bottom: 1.1rem; border-bottom: 1px solid var(--stone-200); }
.audience strong { color: var(--ink-soft); }

.pull {
  border-left: 3px solid var(--gold); padding: .2rem 0 .2rem 1.1rem;
  font-size: 1.0625rem; color: var(--ink); margin: 1.5rem 0;
}

.features { list-style: none; margin: 1.4rem 0 1.8rem; padding: 0; display: grid; gap: .85rem; }
.features li { font-size: .9375rem; color: var(--ink-mute); padding-left: 1.15rem; position: relative; }
.features li::before {
  content: ""; position: absolute; left: 0; top: .62em;
  width: .4rem; height: .4rem; background: var(--gold); border-radius: 1px;
}
.features strong { color: var(--ink); font-weight: 600; }
@media (min-width: 40em) {
  .features-cols { grid-template-columns: 1fr 1fr; column-gap: 1.75rem; }
}

.badge {
  display: inline-block; font-size: .6875rem; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; padding: .15rem .5rem; border-radius: 999px; margin-right: .3rem;
  vertical-align: .08em;
}
.badge-live { background: #DCFCE7; color: #14532D; }
.badge-soon { background: var(--stone-200); color: var(--stone-700); }

.callout {
  background: var(--gold-wash); border: 1px solid #EFE0B8;
  border-radius: var(--radius-lg); padding: 1.1rem 1.25rem;
  font-size: .9375rem; color: var(--ink-soft); margin-bottom: 1.6rem;
}
.callout strong { color: var(--ink); }

.product-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: .5rem; }

/* ---------- Value grid ---------- */
.value-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: clamp(1.5rem, 3vw, 2.5rem);
  grid-template-columns: 1fr;
}
/* Explicit steps: auto-fit left an unbalanced 3 + 1 at desktop widths. */
@media (min-width: 40em) { .value-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 68em) { .value-grid { grid-template-columns: repeat(4, 1fr); } }
.value-grid li { padding-top: 1.25rem; border-top: 2px solid var(--gold); }
.value-grid h3 { margin-bottom: .5rem; }
.value-grid p { font-size: .9375rem; color: var(--ink-mute); }

/* ==========================================================================
   Product mockups
   Recreated interfaces with fabricated data — no real member records.
   ========================================================================== */
.mock-fig { margin: 0; }
.mock-note {
  margin-top: .75rem;
  font-size: .8125rem;
  line-height: 1.5;
  color: var(--ink-mute);
  font-style: italic;
}

.mock {
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-lg); border: 1px solid var(--stone-300);
  font-size: 11px; line-height: 1.45; background: #fff;
  /* Not selectable/searchable content — decorative illustration */
  user-select: none;
}
/* No step up to 12px: .wrap caps at 76rem, so the mock column stops growing
   at about 1300px and the widest table (Provincial Duties) never gets the room
   12px needs. 11px fits at every width. */

.mock-bar {
  display: flex; align-items: center; gap: .35rem;
  background: var(--stone-150); border-bottom: 1px solid var(--stone-300);
  padding: .5rem .7rem;
}
.mock-bar .d { width: .55rem; height: .55rem; border-radius: 50%; background: var(--stone-300); }
.mock-url {
  margin-left: .6rem; flex: 1; background: #fff; border: 1px solid var(--stone-200);
  border-radius: 999px; padding: .18rem .7rem; color: var(--stone-600);
  font-size: .9em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.mock-body { padding: 1rem; }
.mock-app { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); min-height: 20rem; }
@media (max-width: 30em) { .mock-app { grid-template-columns: 1fr; } .mock-side { display: none; } }

.mock-side { padding: .8rem .6rem; }
.mock-side-brand { display: flex; align-items: center; gap: .4rem; font-weight: 600; margin: 0 0 .9rem; font-size: .95em; }
.mock-logo { display: inline-grid; place-items: center; width: 1.4rem; height: 1.4rem; border-radius: 4px; font-size: .62em; font-weight: 700; letter-spacing: .02em; }
.mock-side-label { font-size: .78em; letter-spacing: .1em; text-transform: uppercase; opacity: .55; margin: .9rem 0 .35rem; }
.mock-side ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .1rem; }
.mock-side li { padding: .3rem .5rem; border-radius: 4px; opacity: .8; }

.mock-main { padding: .9rem 1rem; min-width: 0; }
.mock-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; margin-bottom: .8rem; }
.mock-title { font-weight: 700; font-size: 1.25em; margin: 0; }
.mock-kicker { margin: .15rem 0 0; opacity: .6; font-size: .95em; }

.mock-pill { font-size: .8em; font-weight: 700; padding: .12rem .5rem; border-radius: 999px; white-space: nowrap; }
.mock-pill-gold { background: var(--gold-wash); color: var(--gold-deep); }
.mock-pill-vacant { background: #EADFA8; color: #4A3B08; }

.mock-btn { font-size: .88em; font-weight: 600; padding: .28rem .65rem; border-radius: 4px; white-space: nowrap; }
.mock-btn-sm { font-size: .82em; padding: .18rem .5rem; }

.mock-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .4rem; margin-bottom: .9rem; }
.mock-stats div { border: 1px solid var(--stone-200); border-radius: 5px; padding: .45rem .5rem; }
.mock-stats b { display: block; font-size: 1.2em; color: var(--ink); }
.mock-stats span { font-size: .82em; opacity: .6; }

.mock-filters { display: grid; grid-template-columns: 2fr 1fr; gap: .4rem; margin-bottom: .7rem; }
.mock-input, .mock-select { display: block; border: 1px solid var(--stone-300); border-radius: 4px; padding: .3rem .5rem; opacity: .55; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.mock-tabs { display: flex; flex-wrap: wrap; gap: .3rem; margin-bottom: .7rem; }
.mock-tabs span { padding: .22rem .55rem; border-radius: 4px; opacity: .6; font-size: .92em; white-space: nowrap; }

.mock-table { width: 100%; border-collapse: collapse; }
.mock-table th, .mock-table td { text-align: left; padding: .38rem .45rem; border-bottom: 1px solid var(--stone-200); white-space: nowrap; }
.mock-table th { font-size: .82em; letter-spacing: .05em; text-transform: uppercase; opacity: .55; font-weight: 600; }
.mock-table td { font-size: .95em; }
.mock-table .ok { color: var(--ok); font-weight: 600; }
.mock-table .pend { color: var(--warn); font-weight: 600; }
.mock-table .hist { font-size: .8em; opacity: .6; }
.tag { display: inline-block; background: var(--stone-150); border-radius: 3px; padding: .05rem .35rem; font-size: .85em; }
.chip { display: inline-block; background: #1E3A8A; color: #fff; border-radius: 999px; padding: .06rem .45rem; font-size: .8em; font-weight: 600; }
.chip-alt { background: var(--stone-400); }
.avail { display: inline-block; background: var(--stone-150); color: var(--stone-700); border-radius: 3px; padding: 0 .3rem; font-size: .82em; margin-left: .3rem; }

/* --- Masonic Tools: navy + gold on near-white --- */
.mock-mt .mock-title { color: #1E3A8A; font-family: var(--serif); }
.mock-mt .mock-kicker { color: var(--gold-deep); opacity: 1; font-size: .82em; letter-spacing: .1em; text-transform: uppercase; font-weight: 600; }
.mock-mt .mock-stats b { color: #1E3A8A; }

/* --- LBR: navy sidebar, blue accent --- */
.mock-lbr .mock-side { background: #16213E; color: #DCE3F2; }
.mock-lbr .mock-logo { background: #2563EB; color: #fff; }
.mock-lbr .mock-side li.on { background: rgba(37,99,235,.22); box-shadow: inset 2px 0 0 #2563EB; opacity: 1; }
.mock-lbr .mock-main { background: #fff; color: var(--ink-soft); }
.mock-lbr .mock-btn { background: #1E3A8A; color: #fff; }

/* --- Provincial Duties: dark slate + gold --- */
.mock-pd { border-color: #232842; }
.mock-pd .mock-side { background: #1F2438; color: #C9CEE2; }
.mock-pd .mock-logo { background: #D3C27A; color: #2A2410; }
.mock-pd .mock-side li.on { background: #D3C27A; color: #2A2410; opacity: 1; font-weight: 600; }
.mock-pd .mock-main { background: #2E3348; color: #DDE1EE; }
.mock-pd .mock-title { color: #fff; }
.mock-pd .mock-tabs span { background: rgba(255,255,255,.06); }
.mock-pd .mock-tabs span.on { background: #D3C27A; color: #2A2410; opacity: 1; font-weight: 600; }
.mock-pd .mock-warn { color: #E7C86A; font-size: .92em; margin: 0 0 .6rem; }
.mock-pd .mock-assign { display: flex; align-items: center; gap: .5rem; margin-bottom: .5rem; }
.mock-pd .mock-assign-title { font-weight: 700; }
.mock-pd .mock-table th, .mock-pd .mock-table td { border-bottom-color: rgba(255,255,255,.09); }
.mock-pd .mock-btn { background: #D3C27A; color: #2A2410; }
.mock-pd .avail { background: rgba(255,255,255,.1); color: #C9CEE2; }

/* --- Data Warehouse: dark, heat-mapped --- */
.mock-dw { border-color: #1A1F1C; }
.mock-dw .mock-body { background: #1E2422; color: #D6DED9; }
.mock-dw .mock-title { color: #fff; }
.mock-dw .mock-tabs span { background: rgba(255,255,255,.06); }
.mock-dw .mock-tabs span.on { background: #2B6E4A; color: #fff; opacity: 1; font-weight: 600; }
.mock-dw .mock-table th, .mock-dw .mock-table td { border-bottom-color: rgba(255,255,255,.08); }
.mock-dw .mock-heat td:not(:first-child) { text-align: center; font-weight: 600; color: #10201A; }
.mock-dw .mock-heat td:nth-child(2), .mock-dw .mock-heat td:nth-child(3) { background: none; color: #D6DED9; }
.mock-heat .h1 { background: #0F3D2A; color: #7FC9A4 !important; }
.mock-heat .h2 { background: #2E8B57; }
.mock-heat .h3 { background: #6FA83C; }
.mock-heat .h4 { background: #B5B32E; }
.mock-heat .h5 { background: #E0A32A; }
.mock-heat .h6 { background: #E2762A; }

/* ---------- Contact ---------- */
.contact-inner { display: grid; gap: clamp(2rem, 4vw, 3.5rem); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 56em) { .contact-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); } }
.contact-copy p { color: var(--ink-mute); max-width: 34rem; }
.contact-list { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: .6rem; }
.contact-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: .6rem; font-size: .9375rem; }
.contact-list span { font-size: .6875rem; letter-spacing: .11em; text-transform: uppercase; color: var(--ink-mute); min-width: 3.2rem; }
.contact-list a { word-break: break-word; }

.contact-form { background: #fff; border: 1px solid var(--stone-200); border-radius: var(--radius-lg); padding: clamp(1.25rem, 3vw, 2rem); box-shadow: var(--shadow-sm); }
.form-row { margin-bottom: 1.1rem; }
.form-row label, .form-check label { display: block; font-size: .875rem; font-weight: 600; color: var(--ink); margin-bottom: .35rem; }
.req { color: var(--gold-deep); }
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form select,
.contact-form textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--stone-50); border: 1px solid var(--stone-300);
  border-radius: var(--radius); padding: .65rem .75rem;
  transition: border-color .15s ease, background-color .15s ease;
}
.contact-form textarea { resize: vertical; min-height: 7rem; }
.contact-form :is(input, select, textarea):focus { background: #fff; border-color: var(--gold); }
.contact-form :is(input, select, textarea)[aria-invalid="true"] { border-color: #B91C1C; background: #FEF2F2; }

.field-error { display: block; margin-top: .3rem; font-size: .8125rem; font-weight: 600; color: #B91C1C; }

.form-check { display: grid; grid-template-columns: auto 1fr; gap: .6rem; align-items: start; margin-bottom: 1.25rem; }
.form-check input { margin-top: .3rem; width: 1.05rem; height: 1.05rem; accent-color: var(--gold-deep); }
.form-check label { font-weight: 400; font-size: .875rem; color: var(--ink-mute); margin: 0; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-actions { margin: 0; }
.form-status { margin: 1rem 0 0; font-size: .9375rem; font-weight: 600; }
.form-status[data-state="ok"] { color: var(--ok); }
.form-status[data-state="error"] { color: #B91C1C; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--stone-300); padding-top: clamp(3rem, 6vw, 4.5rem); font-size: .9375rem; }
.footer-inner { display: grid; gap: 2.25rem; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); padding-bottom: 2.5rem; }
.site-footer h2 { font-family: var(--sans); font-size: .6875rem; letter-spacing: .13em; text-transform: uppercase; color: var(--stone-400); margin: 0 0 .9rem; font-weight: 600; }
.site-footer a { color: var(--stone-200); text-decoration: none; }
.site-footer a:hover { color: var(--gold-lift); text-decoration: underline; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.footer-brand .brand-mark { width: 2.1rem; height: 2.1rem; margin-bottom: .8rem; }
.footer-name { font-family: var(--serif); font-size: 1.15rem; color: var(--stone-50); margin: 0 0 .3rem; font-weight: 700; }
.footer-tag { color: var(--stone-400); margin: 0; font-size: .875rem; }
.footer-legal address { font-style: normal; margin-bottom: .9rem; line-height: 1.6; }
.footer-legal p { font-size: .875rem; color: var(--stone-400); }
.footer-legal strong { color: var(--stone-200); }
.footer-base { border-top: 1px solid rgba(255,255,255,.1); padding: 1.25rem 0 1.75rem; }
.footer-base p { font-size: .8125rem; color: var(--stone-500); margin: 0; }

/* ---------- Reveal on scroll (progressive enhancement) ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .5s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; } }

/* ---------- Mobile nav ---------- */
@media (max-width: 56em) {
  .nav-toggle { display: block; }
  .nav {
    position: absolute; inset: 100% 0 auto; background: var(--stone-50);
    border-bottom: 1px solid var(--stone-200); box-shadow: var(--shadow-lg);
    display: none; padding: .75rem var(--pad) 1.25rem;
  }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; align-items: stretch; gap: .25rem; }
  .nav a:not(.btn) { padding: .7rem 0; border-bottom: 1px solid var(--stone-200); }
  .nav li:last-child { margin-top: .75rem; }
  .nav .btn { justify-content: center; }
}

@media print {
  .site-header, .nav, .hero-actions, .product-actions, .contact-form, .skip { display: none !important; }
  body { background: #fff; font-size: 11pt; }
  .mock { box-shadow: none; }
}

/* Provincial Duties carries the most columns of any mock — tighten to fit. */
.mock-pd .mock-table th,
.mock-pd .mock-table td { padding-inline: .28rem; }
.mock-pd .mock-btn-sm { padding: .18rem .4rem; }
.mock-pd .avail { margin-left: .22rem; padding: 0 .22rem; }

/* ---------- Mock overflow on small screens ----------
   The mock frames clip (overflow:hidden for the rounded corners), so a table
   wider than the frame was being cut mid-cell. Let the inner surface scroll
   instead, and drop the purely decorative action column on narrow screens. */
.mock-body,
.mock-main {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

@media (max-width: 40em) {
  /* Scale the illustration down so its table fits without a cut-off edge. */
  .mock { font-size: 10px; }
  .mock-table th, .mock-table td { padding-inline: .22rem; }

  /* The Select buttons are chrome, not information — reclaim the width. */
  .mock-pd .mock-table th:last-child,
  .mock-pd .mock-table td:last-child { display: none; }

  /* Oldest age bands carry the least signal in the illustration. */
  .mock-dw .mock-heat th:nth-child(8), .mock-dw .mock-heat td:nth-child(8),
  .mock-dw .mock-heat th:nth-child(9), .mock-dw .mock-heat td:nth-child(9) { display: none; }

  /* Years column is redundant next to Age at this size. */
  .mock-lbr .mock-table th:nth-child(4),
  .mock-lbr .mock-table td:nth-child(4) { display: none; }
}

/* Once settled, drop the animation entirely so the resting state is plain CSS. */
.ashlar.is-set .blk { animation: none; }

/* --- Membership Manager: the member's card page, dark with a blue accent --- */
.mock-mm { border-color: #101B31; }
.mock-mm .mock-body { background: #0B1220; color: #C9D4E8; padding: 1rem .9rem; }

.pass { max-width: 17rem; margin-inline: auto; text-align: center; }
.pass-venue { margin: 0; font-size: .85em; opacity: .6; }
.pass-title { margin: .1rem 0 .7rem; font-weight: 600; color: #fff; font-size: 1.05em; }

.pass-card {
  background: linear-gradient(160deg, #16233D 0%, #101A2E 100%);
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 8px; padding: .7rem .8rem; text-align: left;
}
.pass-badge {
  display: inline-block; font-size: .72em; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: #7FB0FF;
}
.pass-name { margin: .2rem 0 0; font-weight: 700; color: #fff; font-size: 1.1em; }
.pass-plan { margin: 0; font-size: .88em; opacity: .6; }
.pass-meta { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-top: .6rem; }
.pass-meta span { display: block; font-size: .78em; opacity: .55; }
.pass-meta b { color: #fff; font-size: .98em; }

.pass-qr { background: #fff; border-radius: 8px; padding: .6rem .6rem .35rem; margin-top: .5rem; }
.pass-qr .qr { display: block; width: 5.4rem; height: 5.4rem; margin-inline: auto; fill: #0B1220; }
.pass-qr p { margin: .3rem 0 0; font-size: .78em; color: #4A5566; }

.pass-wallets { display: grid; gap: .35rem; margin-top: .55rem; }
.wallet {
  display: block; border-radius: 6px; padding: .38rem .5rem;
  font-size: .82em; font-weight: 600; background: #000; color: #fff;
  border: 1px solid rgba(255,255,255,.16);
}
.wallet-g { background: #fff; color: #1F2430; border-color: transparent; }

/* --- Five product cards: explicit steps, so the row never breaks 4 + 1 --- */
.product-grid { grid-template-columns: 1fr; }
@media (min-width: 34em) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 52em) { .product-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 76em) {
  .product-grid { grid-template-columns: repeat(5, 1fr); gap: .9rem; }
  .product-card { padding: 1.4rem 1.1rem 1.2rem; }
  .product-card h3 { font-size: 1.15rem; }
}
