/* ==========================================================================
   SJBC design system: one stylesheet for every page of teamsanjose.org.
   Theme: the 2026 club kit. Deep blue with light topographic lines, royal blue
   for actions, wide bold lettering. Red is reserved for the logo mark and for
   urgent status (cancelled, action required). See site/DESIGN_SYSTEM.md.
   Club blue, red and cerulean match the official logo and kit (PMS 286, red J11,
   cerulean J60), taken from the club logo files (2026-11-07).
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  /* Brand blues (sampled from the kit and team store banner) */
  --blue-950: #0c1830;
  --blue-900: #12234a;
  --blue-800: #1a3463;   /* jersey navy */
  --blue-700: #25487e;   /* topo banner blue: main dark surface */
  --blue-600: #0033a1;   /* club blue, PMS 286 (logo and kit): buttons and links */
  --blue-500: #2f56c9;
  --topo:     #3c95b9;   /* contour lines on dark blue */
  --sky:      #8fd0ec;   /* accent text on dark blue (a tint of cerulean that stays readable) */
  --cerulean: #3cc2f4;   /* kit cerulean, J60: large accents on dark blue only (too light for small text) */
  --blue-100: #dfe8f6;
  --blue-50:  #f1f5fb;
  --red:      #e4262c;   /* kit red, J11: logo and urgent status only */

  /* Neutrals */
  --ink: #0f1a2e;
  --text: #2a3448;
  --muted: #5a6478;
  --line: #d8dfeb;
  --paper: #ffffff;

  /* Status (never color alone: chips always carry a word) */
  --ok: #1d7a46;      --ok-bg: #e2f4ea;
  --warn: #8a5a00;    --warn-bg: #fff3d6;
  --stop: #b3202a;    --stop-bg: #fde6e7;
  --info: var(--blue-600); --info-bg: var(--blue-100);

  /* Type: Archivo with its width axis; display text is set extra wide like the kit lettering */
  --font: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wide: 125%;
  --semi-wide: 112%;
  --step--1: clamp(.83rem, .8rem + .1vw, .9rem);
  --step-0: clamp(1rem, .97rem + .15vw, 1.08rem);
  --step-1: clamp(1.2rem, 1.12rem + .35vw, 1.4rem);
  --step-2: clamp(1.45rem, 1.3rem + .7vw, 1.9rem);
  --step-3: clamp(1.8rem, 1.5rem + 1.4vw, 2.7rem);
  --step-4: clamp(2rem, 1.55rem + 2vw, 3.3rem);
  --step-5: clamp(2.6rem, 1.8rem + 3.8vw, 5rem);

  /* Space, shape, depth */
  --space-1: .25rem; --space-2: .5rem; --space-3: .75rem; --space-4: 1rem; --space-5: 1.5rem;
  --space-6: 2rem;   --space-7: 3rem;  --space-8: 4.5rem; --space-9: 6.5rem;
  --radius-sm: 4px; --radius: 10px; --radius-lg: 18px;
  --shadow-1: 0 1px 2px rgba(12,24,48,.06), 0 2px 8px rgba(12,24,48,.06);
  --shadow-2: 0 12px 32px rgba(12,24,48,.16);
  --wrap: 1200px;
  --gutter: 16px;
}

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 78px; }   /* the sticky header's height; site.js sets it exactly */
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; font: 400 var(--step-0)/1.6 var(--font); color: var(--text); background: var(--paper); text-rendering: optimizeLegibility; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
[hidden] { display: none !important; }
svg { flex: none; }
a { color: var(--blue-600); text-underline-offset: .18em; }
a:hover { color: var(--blue-500); }
:focus-visible { outline: 3px solid #f2b705; outline-offset: 2px; border-radius: 2px; }
h1, h2, h3, h4 { margin: 0; color: var(--ink); line-height: 1.08; font-weight: 800; letter-spacing: -.005em; text-wrap: balance; }
h1, h2 { font-stretch: var(--wide); text-transform: uppercase; }
h3 { font-stretch: var(--semi-wide); }
h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }
p { margin: 0 0 var(--space-4); text-wrap: pretty; }
ul, ol { padding-left: 1.2em; }
.icon { width: 1.15em; height: 1.15em; }
.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.nowrap { white-space: nowrap; }
.skip-link { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--paper); color: var(--ink); padding: 10px 14px; border-radius: var(--radius-sm); }
.skip-link:focus { left: 8px; }

/* 3. Topographic texture ----------------------------------------------------
   Add .topo to any dark section. The lines are a CSS mask, so their color is
   a token: --topo-color. .topo--light gives pale lines for light sections. */
.topo { position: relative; isolation: isolate; }
.topo::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: var(--topo-color, var(--topo)); opacity: var(--topo-opacity, .85);
  -webkit-mask: url("../img/topo.svg") 0 0 / var(--topo-size, 1100px) repeat; mask: url("../img/topo.svg") 0 0 / var(--topo-size, 1100px) repeat; }
.topo--light { --topo-color: var(--blue-600); --topo-opacity: .09; }
.topo--faint { --topo-opacity: .35; }

/* 4. Type helpers ------------------------------------------------------------ */
.eyebrow { display: inline-flex; align-items: center; gap: .6em; margin: 0 0 var(--space-4); font-size: var(--step--1); font-weight: 700; font-stretch: var(--semi-wide); letter-spacing: .14em; text-transform: uppercase; color: var(--blue-600); }
.eyebrow::before { content: ""; width: 28px; height: 3px; border-radius: 2px; background: currentColor; }
.lead { font-size: var(--step-1); line-height: 1.5; color: var(--muted); max-width: 46ch; }
.on-dark { color: #dbe6f7; }
.on-dark h1, .on-dark h2, .on-dark h3, .on-dark h4 { color: #fff; }
.on-dark .eyebrow { color: var(--sky); }
.on-dark .lead { color: #c9d8ef; }
.on-dark a:not(.btn) { color: #fff; }
.text-link { display: inline-flex; align-items: center; gap: .4em; font-weight: 700; text-decoration: none; }
.text-link .icon { transition: transform .15s; }
.text-link:hover { text-decoration: underline; }
.text-link:hover .icon { transform: translateX(3px); }

/* 5. Buttons ----------------------------------------------------------------- */
.btn { --b: var(--blue-600); --f: #fff; display: inline-flex; align-items: center; justify-content: center; gap: .55em; min-height: 48px; padding: .7em 1.4em;
  border: 2px solid var(--b); border-radius: 999px; background: var(--b); color: var(--f); font: 700 var(--step-0)/1.1 var(--font); font-stretch: var(--semi-wide);
  text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s, color .15s, transform .15s; }
.btn:hover { --b: var(--blue-800); color: var(--f); }
.btn:active { transform: translateY(1px); }
.btn--light { --b: #fff; --f: var(--blue-800); }
.btn--light:hover { --b: var(--blue-100); --f: var(--blue-900); }
.btn--outline { background: transparent; --f: var(--blue-600); }
.btn--outline:hover { --b: var(--blue-600); background: var(--blue-600); --f: #fff; }
.btn--outline-light { --b: rgba(255,255,255,.75); --f: #fff; background: transparent; }
.btn--outline-light:hover { --b: #fff; background: #fff; --f: var(--blue-800); }
.btn--sm { min-height: 40px; padding: .5em 1.1em; font-size: var(--step--1); }
.btn--block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; }

/* 6. Chips (status) ------------------------------------------------------------ */
.chip { display: inline-flex; align-items: center; gap: .4em; padding: .3em .7em; border-radius: 999px; font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; line-height: 1.2;
  background: var(--blue-100); color: var(--blue-800); white-space: nowrap; }
.chip--next { background: var(--blue-600); color: #fff; }
.chip--open { background: var(--ok-bg); color: var(--ok); }
.chip--done { background: #eceff4; color: var(--muted); }
.chip--warn { background: var(--warn-bg); color: var(--warn); }
.chip--stop { background: var(--stop-bg); color: var(--stop); }
.chip--live::before { content: ""; width: .5em; height: .5em; border-radius: 50%; background: currentColor; }

/* 7. Notice bar, header, navigation ------------------------------------------- */
.notice-bar { background: var(--blue-900); color: #c9d8ef; font-size: var(--step--1); }
.notice-bar__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: 40px; padding-block: 6px; }
.notice-bar p { margin: 0; }
.notice-bar strong { color: var(--sky); }
.notice-bar a { color: #fff; font-weight: 600; }

.site-header { position: sticky; top: 0; z-index: 40; background: rgba(255,255,255,.96); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--line); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); min-height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--blue-800); text-decoration: none; }
.brand:hover { color: var(--blue-800); }
.brand__mark { width: auto; height: 46px; }
.brand__name { display: grid; line-height: 1; }
.brand__name b { font-size: 1.32rem; font-weight: 900; font-stretch: var(--wide); letter-spacing: .01em; text-transform: uppercase; }
.brand__name small { margin-top: 5px; font-size: .64rem; font-weight: 700; font-stretch: var(--wide); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.brand--light { color: #fff; }
.brand--light:hover { color: #fff; }
.brand--light small { color: #b9c9e6; }

.site-nav { display: flex; align-items: center; gap: var(--space-2); }
.site-nav__links { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.site-nav__links a { display: block; padding: .55em .8em; border-radius: 999px; color: var(--ink); font-weight: 600; text-decoration: none; }
.site-nav__links a:hover { background: var(--blue-50); color: var(--blue-600); }
.site-nav__links a[aria-current="page"] { background: var(--blue-100); color: var(--blue-800); }
.site-nav__actions { display: flex; align-items: center; gap: var(--space-2); margin-left: var(--space-3); }
.site-nav__login { padding: .55em .8em; color: var(--ink); font-weight: 600; text-decoration: none; }
.menu-toggle { display: none; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 2px solid var(--blue-800); border-radius: 999px; background: none; color: var(--blue-800); font: 700 var(--step--1)/1 var(--font); cursor: pointer; }

/* 8. Sections ----------------------------------------------------------------- */
.section { padding-block: var(--space-9); }
.section--tight { padding-block: var(--space-8); }
.section--tint { background: var(--blue-50); }
.section--dark { background: var(--blue-700); color: #dbe6f7; }
.section--deep { background: var(--blue-900); color: #dbe6f7; }
.section-head { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: var(--space-5) var(--space-8); align-items: end; margin-bottom: var(--space-7); }
.section-head > :last-child { justify-self: end; }
.section-head p:not(.eyebrow) { margin: 0; color: var(--muted); max-width: 46ch; }
.section-head--stack { grid-template-columns: 1fr; }
.section-head--stack > :last-child { justify-self: start; }
.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)); }

/* 9. Home hero ------------------------------------------------------------------ */
.hero { background: var(--blue-700); color: #dbe6f7; overflow: hidden; --topo-opacity: .42; }
.hero__inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: var(--space-8); align-items: center; padding-block: var(--space-8) var(--space-9); }
.hero h1 { color: #fff; font-size: var(--step-5); line-height: .98; margin-bottom: var(--space-5); }
.hero h1 span { display: block; }
.hero h1 .accent { color: var(--cerulean); }
.hero .lead { color: #c9d8ef; margin-bottom: var(--space-6); }
.hero__media { position: relative; }
.hero__photo { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; object-position: 50% 35%; border-radius: var(--radius-lg); border: 6px solid rgba(255,255,255,.12); box-shadow: var(--shadow-2); }
.next-ride { position: relative; z-index: 1; margin: -44px 0 0 auto; width: min(400px, 88%); padding: var(--space-5); border-radius: var(--radius); background: #fff; color: var(--text); box-shadow: var(--shadow-2); }
.on-dark .next-ride h2, .next-ride h2 { color: var(--ink); font-size: var(--step-1); font-stretch: var(--semi-wide); text-transform: none; margin: var(--space-2) 0 var(--space-3); }
.next-ride ul { list-style: none; margin: 0 0 var(--space-3); padding: 0; display: grid; gap: 6px; font-size: var(--step--1); }
.next-ride li { display: flex; gap: 8px; }
.next-ride li .icon { color: var(--blue-600); margin-top: 3px; }
.hero-facts { display: grid; grid-template-columns: repeat(3, minmax(0, max-content)); gap: var(--space-3) var(--space-6); margin: var(--space-7) 0 0; padding: var(--space-5) 0 0; border-top: 1px solid rgba(255,255,255,.18); list-style: none; }
.hero-facts li { display: grid; align-content: start; font-size: var(--step--1); color: #b9c9e6; }
.hero-facts b { font-size: var(--step-1); font-stretch: var(--wide); color: #fff; }

/* 10. Inner-page hero and breadcrumbs ------------------------------------------- */
.page-hero { background: var(--blue-700); color: #dbe6f7; padding-block: var(--space-7) var(--space-8); }
.page-hero h1 { color: #fff; font-size: var(--step-4); margin-bottom: var(--space-4); }
.page-hero .lead { color: #c9d8ef; max-width: 60ch; margin: 0; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0 0 var(--space-5); padding: 0; font-size: var(--step--1); color: #b9c9e6; }
.crumbs li + li::before { content: "/"; margin-right: 6px; opacity: .6; }
.crumbs a { color: #fff; }

/* 11. Cards ------------------------------------------------------------------------ */
.card { display: flex; flex-direction: column; gap: var(--space-3); padding: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow-1); }
.card > :last-child { margin-bottom: 0; }
.card h3 { font-size: var(--step-2); }
.card p { color: var(--muted); }
.card__foot { margin-top: auto; padding-top: var(--space-2); }
.card--link { position: relative; transition: border-color .15s, box-shadow .15s, transform .15s; }
.card--link:hover { border-color: var(--blue-500); box-shadow: var(--shadow-2); transform: translateY(-2px); }
.card--link .stretched::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.card--dark { background: var(--blue-800); border-color: transparent; color: #dbe6f7; }
.card--dark h3 { color: #fff; }
.card--dark p { color: #c9d8ef; }
.card__media { margin: calc(-1 * var(--space-6)) calc(-1 * var(--space-6)) var(--space-2); aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius) var(--radius) 0 0; }
.card__media img { width: 100%; height: 100%; object-fit: cover; }
.icon-badge { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: var(--blue-100); color: var(--blue-600); }
.icon-badge .icon { width: 26px; height: 26px; }
.on-dark .icon-badge, .card--dark .icon-badge { background: rgba(255,255,255,.1); color: var(--sky); }

/* 12. Ride rows ----------------------------------------------------------------------- */
.ride-list { display: grid; gap: var(--space-4); }
.ride-row { position: relative; display: grid; grid-template-columns: 112px minmax(0, 1fr) auto; gap: var(--space-6); align-items: center; padding: var(--space-5) var(--space-6); border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); transition: border-color .15s, box-shadow .15s; }
.ride-row:hover { border-color: var(--blue-500); box-shadow: var(--shadow-1); }
.ride-row__when { display: grid; justify-items: center; padding-right: var(--space-5); border-right: 1px solid var(--line); text-align: center; line-height: 1.1; }
.ride-row__when small { font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.ride-row__when b { font-size: 1.7rem; font-weight: 800; font-stretch: var(--wide); color: var(--blue-800); }
.ride-row h3 { font-size: var(--step-2); margin: var(--space-2) 0 var(--space-2); }
.ride-row h3 a { color: inherit; text-decoration: none; }
.ride-row h3 a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.ride-row p { margin: 0 0 var(--space-3); color: var(--muted); max-width: 70ch; }
.meta { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); list-style: none; margin: 0; padding: 0; font-size: var(--step--1); color: var(--text); }
.meta li { display: inline-flex; align-items: center; gap: 6px; }
.meta .icon { color: var(--blue-600); }
.ride-row__go { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line); color: var(--blue-600); transition: background .15s, color .15s; }
.ride-row:hover .ride-row__go { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }

/* 13. Steps (first ride guide and other how-tos) ------------------------------------- */
.steps { counter-reset: step; list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-5); }
.steps li { counter-increment: step; position: relative; display: grid; grid-template-columns: 52px 1fr; gap: var(--space-4); }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; border: 2px solid currentColor; font-weight: 800; font-stretch: var(--wide); font-size: 1.15rem; color: var(--blue-600); background: var(--paper); }
.steps li:not(:last-child)::after { content: ""; position: absolute; left: 25px; top: 56px; bottom: calc(-1 * var(--space-5) + 4px); width: 2px; background: var(--blue-100); }
.steps h3 { font-size: var(--step-1); margin: .55em 0 .3em; }
/* Donate page: one PayPal form per program (incld/site/donate-inc.php); side by side, stacked on phones. */
.donate-buttons { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-3); }
.donate-form { margin: 0; }
@media (max-width: 480px) { .donate-form, .donate-form .btn { width: 100%; } }
.steps p { margin: 0; color: var(--muted); }

/* 14. Feature panel (what's on now) and quick links ----------------------------------- */
.feature { border-radius: var(--radius-lg); overflow: hidden; background: var(--blue-800); color: #dbe6f7; box-shadow: var(--shadow-2); }
.feature__body { padding: var(--space-7); }
.feature h2 { font-size: var(--step-3); margin-bottom: var(--space-3); }
.schedule { list-style: none; margin: var(--space-5) 0; padding: 0; display: grid; gap: 4px; }
.schedule li { display: grid; grid-template-columns: 84px minmax(0, 1fr) auto; gap: var(--space-4); align-items: center; padding: 12px var(--space-4); border-radius: var(--radius-sm); background: rgba(255,255,255,.06); }
.schedule time { font-weight: 800; font-stretch: var(--wide); color: #fff; letter-spacing: .02em; text-transform: uppercase; font-size: .95rem; }
.schedule li.is-done { color: #93a6c8; }
.schedule li.is-done time { color: #93a6c8; }
.schedule li.is-next { background: #fff; color: var(--ink); }
.schedule li.is-next time { color: var(--blue-600); }
.schedule li.is-next a { color: var(--blue-600); font-weight: 700; }
.schedule .chip--done { background: transparent; color: #93a6c8; }
.quick-links { display: grid; gap: var(--space-3); align-content: start; list-style: none; margin: 0; padding: 0; }
.quick-link { display: flex; gap: var(--space-4); align-items: flex-start; padding: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); color: var(--text); text-decoration: none; transition: border-color .15s; }
a.quick-link:hover { border-color: var(--blue-500); color: var(--text); }
.quick-link b { display: block; color: var(--ink); font-stretch: var(--semi-wide); font-size: var(--step-1); line-height: 1.2; margin-bottom: 4px; }
.quick-link small { display: block; color: var(--muted); font-size: var(--step--1); }
.social-list { list-style: none; margin: var(--space-3) 0 0; padding: 0; display: grid; gap: var(--space-2); }
.social-list a { display: inline-flex; align-items: center; gap: 12px; padding: 2px 0; font-weight: 600; line-height: 1.2; text-decoration: none; }
.social-list a:hover { text-decoration: underline; }
.social-list__badge { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--blue-100); color: var(--blue-600); }
.social-list__badge .icon { width: 20px; height: 20px; }
.social-list small { font-weight: 500; }

/* 15. Paths band ------------------------------------------------------------------------ */

/* 16. Event cards ------------------------------------------------------------------------- */
.event-card { position: relative; display: flex; flex-direction: column; min-height: 300px; padding: var(--space-6); border-radius: var(--radius); overflow: hidden; background: var(--blue-800); color: #dbe6f7; text-decoration: none; --topo-opacity: .5; transition: transform .15s, box-shadow .15s; }
.event-card:nth-child(2) { background: var(--blue-700); }
.event-card:nth-child(3) { background: var(--blue-600); --topo-color: #6fb7e0; }
.event-card:nth-child(4) { background: var(--blue-900); }
.event-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); color: #dbe6f7; }
.event-card__season { font-size: var(--step--1); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--sky); }
.event-card h3 { margin-top: auto; color: #fff; font-size: var(--step-1); font-stretch: var(--wide); text-transform: uppercase; line-height: 1.15; }
.event-card p { margin: var(--space-3) 0 var(--space-4); color: #c9d8ef; font-size: var(--step--1); }
.event-card .chip { align-self: flex-start; }

/* 17. Instagram feed ------------------------------------------------------------------------ */
.feed-filters { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-bottom: var(--space-5); }
.feed-filters button { min-height: 40px; padding: 0 1.1em; border: 2px solid var(--blue-800); border-radius: 999px; background: transparent; color: var(--blue-800); font: 700 var(--step--1)/1 var(--font); cursor: pointer; }
.feed-filters button[aria-pressed="true"] { background: var(--blue-800); color: #fff; }
.feed-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-3); }
figure.post { margin: 0; }
.feed-empty { grid-column: 1 / -1; margin: 0; color: var(--muted); }
.post { position: relative; display: block; aspect-ratio: 1; overflow: hidden; border-radius: var(--radius); background: var(--blue-100); color: #fff; text-decoration: none; }
.post img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.post:hover img, .post:focus-visible img { transform: scale(1.04); }
.post__meta { position: absolute; inset: auto 0 0; padding: 36px 12px 10px; background: linear-gradient(180deg, rgba(12,24,48,0), rgba(12,24,48,.88)); font-size: .85rem; }
.post__account { font-weight: 700; }
.post__caption { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 2px; color: #dbe6f7; line-height: 1.35; }
.post .chip { position: absolute; top: 10px; left: 10px; background: rgba(255,255,255,.92); color: var(--blue-800); }

/* 18. Membership, benefits, history, CTA ------------------------------------------------------ */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: var(--space-8); align-items: center; }
.benefits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); list-style: none; margin: 0; padding: 0; }
.benefits li { padding: var(--space-5); border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); }
.benefits .icon-badge { margin-bottom: var(--space-3); }
.benefits b { display: block; color: var(--ink); font-stretch: var(--semi-wide); font-size: var(--step-1); line-height: 1.2; margin-bottom: 4px; }
.benefits span { color: var(--muted); font-size: var(--step--1); }
.photo-frame { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-2); }
.photo-frame img { width: 100%; height: 100%; object-fit: cover; }
.photo-caption { margin-top: var(--space-3); font-size: var(--step--1); color: var(--muted); }
.history { overflow: hidden; }
.history__year { position: absolute; right: -0.04em; bottom: -0.2em; z-index: -1; font-size: clamp(8rem, 22vw, 20rem); font-weight: 900; font-stretch: var(--wide); line-height: 1; color: rgba(255,255,255,.06); }
.cta-band { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--space-6); }
.cta-band h2 { font-size: var(--step-3); }

/* 19. Tiles, sponsors -------------------------------------------------------------------------- */
.tile { position: relative; isolation: isolate; display: flex; flex-direction: column; justify-content: flex-end; gap: var(--space-2); min-height: 280px; padding: var(--space-6); border-radius: var(--radius); overflow: hidden; color: #fff; text-decoration: none; background: var(--blue-800) center / cover; }
.tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(12,24,48,.05) 10%, rgba(12,24,48,.9) 78%); }
.tile.topo::after { display: none; }
.tile h3 { color: #fff; font-size: var(--step-2); }
.tile p { margin: 0 0 var(--space-3); color: #dbe6f7; }
.tile .text-link { color: #fff; }
.tile:hover { color: #fff; }
.tile:hover .text-link { text-decoration: underline; }
/* Home page sponsors: the featured sponsor in a wide band, then a grid of logo tiles. Logos are JPEGs on white,
   so each sits on a white plate. */
.sponsors { text-align: center; }
.sponsor-feature { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: center; gap: var(--space-6); margin-top: var(--space-2); padding: var(--space-5); border-radius: var(--radius-lg); background: var(--blue-50); text-align: left; }
.sponsor-feature__logo { display: flex; align-items: center; justify-content: center; min-height: 150px; padding: var(--space-5) var(--space-6); border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: box-shadow .15s; }
.sponsor-feature__logo:hover { box-shadow: var(--shadow-2); }
.sponsor-feature__logo img { width: 100%; max-width: 360px; height: auto; }
.sponsor-feature__text { display: grid; justify-items: start; gap: var(--space-3); }
.sponsor-feature__text p { margin: 0; font-size: var(--step-1); line-height: 1.45; color: var(--text); }
.sponsor-feature__text strong { color: var(--ink); }
/* Rows of four (two on phones), a short last row centered, so any number of sponsors lines up */
.sponsor-logos { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-4); list-style: none; margin: var(--space-5) 0 0; padding: 0; }
.sponsor-logos > li { flex: 0 0 calc((100% - 3 * var(--space-4)) / 4); }
.sponsor-logos__tile { display: flex; align-items: center; justify-content: center; height: 104px; padding: var(--space-4); border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: border-color .15s, box-shadow .15s; }
a.sponsor-logos__tile:hover { border-color: var(--blue-100); box-shadow: var(--shadow-1); }
.sponsor-logos__tile img { max-width: 100%; max-height: 64px; width: auto; height: auto; object-fit: contain; }
.sponsors__more { margin: var(--space-5) 0 0; font-size: var(--step--1); color: var(--muted); }
/* The same sponsors on a content page (Our club): inside .prose, so undo its list and image styles; in that
   narrower column the featured band stacks and the logos go three to a row (two on phones, as on the home page) */
.sponsors--in-page { margin: var(--space-5) 0 var(--space-6); }
.prose .sponsors--in-page li { margin: 0; }
.prose .sponsors--in-page img { border-radius: 0; }
.sponsors--in-page .sponsor-feature { grid-template-columns: minmax(0, 1fr); gap: var(--space-4); margin-top: 0; text-align: left; }
.sponsors--in-page .sponsor-feature__logo { min-height: 120px; }
.sponsors--in-page .sponsor-feature__logo img { max-width: 300px; }
@media (min-width: 721px) { .sponsors--in-page .sponsor-logos > li { flex-basis: calc((100% - 2 * var(--space-4)) / 3); } }
/* Sponsored links page: each paid listing is its logo on a white plate beside its name and text; stacked on phones */
/* (the prose column's 72ch limit is lifted so the logo and text sit side by side) */
.prose.sponsored-links { max-width: none; display: grid; gap: var(--space-6); }
.listing { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: var(--space-5); align-items: start; padding-bottom: var(--space-6); border-bottom: 1px solid var(--line); }
.listing:last-child { border-bottom: 0; padding-bottom: 0; }
.listing__logo { display: flex; align-items: center; justify-content: center; height: 120px; padding: var(--space-4); border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: box-shadow .15s; }
.listing__logo:hover { box-shadow: var(--shadow-1); }
.listing__logo img { max-width: 100%; max-height: 80px; width: auto; height: auto; object-fit: contain; border-radius: 0; }
.prose.sponsored-links h2 { font-size: var(--step-2); margin: 0 0 var(--space-3); }
.listing__text p { margin: 0; max-width: 72ch; }
@media (max-width: 600px) {
  .listing { grid-template-columns: minmax(0, 1fr); gap: var(--space-4); }
  .listing__logo { height: 100px; max-width: 260px; }
}
@media (max-width: 720px) {
  .sponsor-feature { grid-template-columns: minmax(0, 1fr); padding: var(--space-4); }
  .sponsor-feature__logo { min-height: 110px; }
  .sponsor-logos { gap: var(--space-3); }
  .sponsor-logos > li { flex: 0 0 calc(50% - var(--space-3) / 2); }
  .sponsor-logos__tile { height: 88px; padding: var(--space-3); }
  .sponsor-logos__tile img { max-height: 52px; }
}

/* 20. Content pages: layout, prose, facts, callouts, tables -------------------------------------- */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: var(--space-8); align-items: start; }
.layout__aside { position: sticky; top: 100px; display: grid; gap: var(--space-5); }
.prose { max-width: 72ch; }
.prose h2 { font-size: var(--step-3); margin: var(--space-7) 0 var(--space-4); }
.prose h3 { margin: var(--space-6) 0 var(--space-3); }
.prose > :first-child { margin-top: 0; }
.prose li { margin-bottom: var(--space-2); }
.prose img { border-radius: var(--radius); }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: var(--space-3) var(--space-5); margin: 0; }
.facts dt { font-size: var(--step--1); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-top: .15em; }
.facts dd { margin: 0; color: var(--ink); font-weight: 600; }
.card--dark .facts dt { color: #93a6c8; }
.card--dark .facts dd { color: #fff; }
.prose .table-wrap { margin: var(--space-5) 0; }
/* Name lists (race team roster, sponsors): columns that wrap to one on phones */
.roster { columns: 3 13em; column-gap: var(--space-6); list-style: none; margin: 0 0 var(--space-5); padding: 0; }
.prose .roster li { margin: 0 0 var(--space-2); break-inside: avoid; }
/* "On this page" list in a sidebar card */
.toc { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.toc a { font-weight: 600; }
.contact-more { margin-top: var(--space-8); }
.callout { display: grid; grid-template-columns: auto 1fr; gap: var(--space-3); padding: var(--space-4) var(--space-5); border-radius: var(--radius); background: var(--info-bg); color: var(--blue-900); border-left: 4px solid var(--info); }
.callout p { margin: 0; }
.callout--warn { background: var(--warn-bg); color: #4d3500; border-color: #d99a00; }
.callout--stop { background: var(--stop-bg); color: #5c0d12; border-color: var(--stop); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.table { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
.table th, .table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.table th { background: var(--blue-50); color: var(--ink); font-weight: 700; white-space: nowrap; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #fafcff; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }

/* 20b. Home page notices (incld/notices-inc.php) and the Notices page ---------------------------- */
.notices__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-3); margin-bottom: var(--space-5); }
.notices__head h2 { margin: 0; }
.notices__list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-4); grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
.notice { display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-2); min-width: 0; padding: var(--space-5) var(--space-6); border: 1px solid var(--line); border-left: 4px solid var(--blue-600); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow-1); }
.notice h3 { margin: 0; font-size: var(--step-1); }
.notice p { margin: 0; color: var(--ink); overflow-wrap: anywhere; }
.notice--urgent { border-color: var(--stop); border-left-color: var(--stop); background: var(--stop-bg); }
.notice--urgent .chip--stop { background: var(--stop); color: #fff; }
.notice__link { display: inline-flex; align-items: center; gap: .4em; font-weight: 700; }
.notice__date { font-size: var(--step--1); color: var(--muted) !important; }
.notices__none { padding-top: var(--space-5); }
.notices-admin h2 { margin-bottom: var(--space-5); }
.notices-admin__dates { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: var(--space-4); }
.notices-admin__list-title { margin-top: var(--space-8); }
.notices-admin__actions { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; }
.notices-admin__actions form { margin: 0; }
/* Login, password pages and the members area (members/index.php) */
.auth { display: flex; flex-direction: column; gap: var(--space-4); max-width: 30rem; }
.auth .form, .form.auth { display: flex; flex-direction: column; gap: var(--space-4); }
.member-area { display: flex; flex-direction: column; gap: var(--space-5); }
.member-nav ul { display: flex; flex-wrap: wrap; gap: var(--space-2); list-style: none; margin: 0; padding: 0; }
.member-nav a { display: inline-block; padding: .45em .9em; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); font-weight: 600; text-decoration: none; }
.member-nav a:hover { border-color: var(--blue-500); }
.member-nav a[aria-current="page"] { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }
.member-status { max-width: 40rem; }
.member-status p { color: var(--text); margin: 0; }
.member-status__ok { display: flex; gap: .4em; align-items: center; }
.member-links { grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr)); }
.deal-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); }
.deal__logo { max-width: 160px; max-height: 80px; object-fit: contain; align-self: flex-start; }
.deal__text { color: var(--text); overflow-wrap: anywhere; }
.minutes-years { display: grid; gap: var(--space-3); max-width: 40rem; }
.minutes-year { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.minutes-year summary { display: flex; align-items: baseline; gap: var(--space-3); padding: var(--space-3) var(--space-4); cursor: pointer; font-weight: 800; font-stretch: var(--semi-wide); font-size: var(--step-1); color: var(--ink); }
.minutes-year summary small { font-weight: 500; font-size: var(--step--1); color: var(--muted); }
.minutes-year[open] summary { border-bottom: 1px solid var(--line); }
.minutes-list { list-style: none; margin: 0; padding: var(--space-2) var(--space-4) var(--space-3); display: grid; gap: var(--space-1); }
.minutes-list a { display: block; padding: var(--space-1) 0; font-weight: 600; }
.legacy-content { overflow-x: auto; }
.legacy-content table { width: auto !important; }
/* Renewal reminders admin page (/reminders/) */
.account-lookup { display: flex; flex-direction: column; gap: var(--space-5); max-width: 46rem; }
.account-lookup .form { display: flex; flex-direction: column; gap: var(--space-4); }
.account-lookup__fields { display: flex; flex-wrap: wrap; gap: var(--space-4); }
.account-lookup__fields .field { flex: 1 1 14rem; min-width: 0; }
.account-lookup__result .facts dd { overflow-wrap: anywhere; }
.reminders-admin { display: flex; flex-direction: column; gap: var(--space-5); }
.reminders-admin h2 { margin-top: var(--space-6); }
.reminders-admin .form { display: flex; flex-direction: column; gap: var(--space-4); }
.reminder-email summary { cursor: pointer; }
.reminder-email[open] summary { margin-bottom: var(--space-3); }
.reminder-sample { max-width: 40rem; }
.reminder-sample p { color: var(--ink); }

/* 20c. Release of liability (incld/release/release-inc.php): /release/, /sign-release/, the organizer list ------ */
.callout--ok { background: var(--ok-bg); color: #0d3d23; border-color: var(--ok); }
.callout > div > :last-child { margin-bottom: 0; }
.release-done h2 { font-size: var(--step-3); margin-bottom: var(--space-3); }
.release-form-wrap { display: grid; gap: var(--space-5); max-width: 800px; }
.release-form { display: grid; gap: var(--space-5); }
.release-form__rest { display: grid; gap: var(--space-5); }
.release-step { display: grid; gap: var(--space-4); min-width: 0; margin: 0; padding: var(--space-5) var(--space-6) var(--space-6); border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow-1); }
.release-step legend { float: left; width: 100%; display: flex; align-items: center; gap: var(--space-3); margin: 0 0 var(--space-2); padding: 0; font-size: var(--step-1); font-weight: 800; font-stretch: var(--semi-wide); color: var(--ink); }
.release-step legend + * { clear: both; }
.release-step__num { display: inline-grid; place-items: center; flex: none; width: 2rem; height: 2rem; border-radius: 50%; background: var(--blue-600); color: #fff; font-size: 1rem; font-stretch: 100%; }
.choice-list { display: grid; gap: var(--space-3); }
.choice { display: flex; gap: var(--space-3); align-items: flex-start; padding: var(--space-4); border: 2px solid var(--line); border-radius: var(--radius); cursor: pointer; }
.choice:hover { border-color: #9fb3d9; }
.choice:has(input:checked) { border-color: var(--blue-600); background: var(--blue-50); }
.choice input { flex: none; width: 20px; height: 20px; margin-top: 2px; accent-color: var(--blue-600); }
.choice b { display: block; color: var(--ink); }
.release-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); }
.release-panel { display: grid; gap: var(--space-3); }
.release-panel p { margin: 0; }
.release-panel .check { padding: var(--space-3) var(--space-4); border-radius: var(--radius-sm); background: var(--blue-50); }
.check.is-locked { opacity: .55; cursor: not-allowed; }
.release-text { font-size: .95rem; line-height: 1.55; }
.release-text h3 { margin: var(--space-5) 0 var(--space-2); font-size: var(--step-0); font-stretch: 100%; }
.release-text--scroll { max-height: 380px; overflow: auto; padding: var(--space-4) var(--space-5); border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--blue-50); overscroll-behavior: auto; }
.release-text__title { margin-top: 0 !important; font-size: var(--step-1) !important; }
.release-text__end { margin: var(--space-4) 0 0; }
.release-sig { max-width: 28rem; }
.release-step__title { font-size: var(--step-2); }
.release-step > .lead, .release-step > p { margin: 0; }
/* Join and renew: the steps in the page hero */
.join-steps { display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-6); margin: var(--space-6) 0 0; padding: 0; list-style: none; font-size: var(--step--1); color: #b9c9e6; }
.join-steps li { display: flex; align-items: center; gap: var(--space-2); }
.join-steps b { display: inline-grid; place-items: center; width: 1.8rem; height: 1.8rem; border-radius: 50%; border: 2px solid rgba(255,255,255,.4); color: #fff; }
.join-steps .is-current { color: #fff; font-weight: 700; }
.join-steps .is-current b { background: #fff; border-color: #fff; color: var(--blue-800); }
.join-steps .is-done b { background: var(--ok); border-color: var(--ok); }
.release-list-tools { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: end; margin-bottom: var(--space-4); }
.release-list-tools .field { flex: 1 1 14rem; }
@media (max-width: 600px) {
  .release-grid { grid-template-columns: 1fr; }
  .release-step { padding: var(--space-4); }
}

/* 21. Forms --------------------------------------------------------------------------------------- */
.form { display: grid; gap: var(--space-5); max-width: 560px; }
.field { display: grid; gap: 6px; }
.field label, .field legend { font-weight: 700; color: var(--ink); }
.field__hint { font-size: var(--step--1); color: var(--muted); }
.field__error { display: flex; gap: 6px; font-size: var(--step--1); font-weight: 600; color: var(--stop); }
.input, .select, .textarea { width: 100%; min-height: 48px; padding: .65em .85em; border: 1.5px solid #b8c3d6; border-radius: var(--radius-sm); background: #fff; color: var(--ink); font: inherit; }
.textarea { min-height: 120px; resize: vertical; }
.input:hover, .select:hover, .textarea:hover { border-color: var(--blue-500); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--blue-600); box-shadow: 0 0 0 3px rgba(30,59,166,.2); }
[aria-invalid="true"] { border-color: var(--stop); }
.check { display: flex; gap: 10px; align-items: flex-start; }
.check input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--blue-600); }
fieldset.field { border: 0; margin: 0; padding: 0; }

/* 22. Footer --------------------------------------------------------------------------------------- */
.site-footer { background: var(--blue-950); color: #b9c9e6; font-size: var(--step--1); --topo-opacity: .14; }
.site-footer__grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: var(--space-7); padding-block: var(--space-8) var(--space-7); }
.site-footer h2 { font-size: .8rem; font-stretch: var(--wide); letter-spacing: .14em; color: #fff; margin: 0 0 var(--space-4); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.site-footer a { color: #dbe6f7; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer__tag { margin: var(--space-4) 0; max-width: 34ch; }
.social-icons { display: flex; gap: var(--space-2); list-style: none; margin: 0; padding: 0; }
.social-icons a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,.08); color: #fff; transition: background-color .15s; }
.social-icons a:hover, .social-icons a:focus-visible { background: var(--blue-600); text-decoration: none; }
/* Each platform's own colour on hover or focus only; at rest the footer stays navy and white (Fix 30). */
.social-icons a.is-instagram:hover, .social-icons a.is-instagram:focus-visible { background: #e1306c; }
.social-icons a.is-facebook:hover, .social-icons a.is-facebook:focus-visible { background: #0866ff; }
.social-icons a.is-strava:hover, .social-icons a.is-strava:focus-visible { background: #fc4c02; }
.site-footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-3); padding-block: var(--space-5); border-top: 1px solid rgba(255,255,255,.12); }

/* 23. Responsive ------------------------------------------------------------------------------------ */
@media (max-width: 1080px) {
  .menu-toggle { display: inline-flex; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; padding: var(--space-3) var(--gutter) var(--space-5); background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-2); }
  .site-nav.is-open { display: flex; }
  .site-nav__links { flex-direction: column; }
  .site-nav__links a { padding: 14px 8px; border-radius: 0; border-bottom: 1px solid var(--line); }
  .site-nav__actions { margin: var(--space-4) 0 0; justify-content: space-between; }
  .hero__inner, .split, .layout { grid-template-columns: 1fr; }
  .hero__media { max-width: 640px; }
  .layout__aside { position: static; }
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feed-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-footer__grid { grid-template-columns: repeat(3, 1fr); }
  .site-footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  :root { --space-9: 4rem; --space-8: 3rem; }
  .brand__mark { width: auto; height: 34px; }   /* the train logo is wide: keep the header on one line at phone width */
  .brand { gap: 10px; }
  .brand__name b { font-size: 1.12rem; }
  .section-head { grid-template-columns: 1fr; }
  .section-head > :last-child { justify-self: start; }
  .grid--2, .grid--3, .grid--4, .benefits { grid-template-columns: 1fr; }
  .ride-row { grid-template-columns: 76px minmax(0, 1fr); gap: var(--space-4); padding: var(--space-5) var(--space-4); }
  .ride-row__when { padding-right: var(--space-3); }
  .ride-row__when b { font-size: 1.3rem; }
  .ride-row__go { display: none; }
  .hero-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-3); }
  .hero-facts b { font-size: var(--step-0); font-stretch: normal; }
  .next-ride { width: auto; margin: -28px var(--space-3) 0; }
  .feature__body { padding: var(--space-5); }
  .schedule li { grid-template-columns: 70px minmax(0, 1fr); }
  .schedule .chip { grid-column: 2; justify-self: start; }
  .feed-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); }
  .post__caption { display: none; }
  .facts { grid-template-columns: 1fr; gap: 2px var(--space-4); }
  .facts dd { margin-bottom: var(--space-3); }
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 400px) {
  .site-header__inner { gap: var(--space-3); }
  .brand__name small { letter-spacing: .08em; }
  .menu-toggle { padding: 0 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
@media print {
  .notice-bar, .site-header, .site-footer, .feed, .btn { display: none !important; }
  .topo::before { display: none; }
  body { color: #000; }
}

/* 24. Layout modifiers (keep inline styles out of pages) --------------------------------------------- */
.split--feature { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: start; }
.feature__title { font-size: var(--step-3); font-stretch: var(--wide); text-transform: uppercase; margin-bottom: var(--space-3); }
.tile--topo { background-color: var(--blue-700); }
.tile--topo .icon-badge { background: rgba(255,255,255,.12); color: var(--sky); }
.stack-lg > * + * { margin-top: var(--space-6); }
.mt-3 { margin-top: var(--space-3); }
@media (max-width: 1080px) { .split--feature { grid-template-columns: 1fr; } }
.figure { margin: 0; }
.benefits { margin-block: var(--space-6); }
.history__lead { margin: var(--space-5) 0 var(--space-6); }
.on-dark .next-ride a:not(.btn) { color: var(--blue-600); }
.on-dark .section-head p:not(.eyebrow) { color: #c9d8ef; }
.site-footer .social-icons { display: flex; }
.card > .chip, .event-card > .chip { align-self: flex-start; }
.prose .steps h3, .steps h3 { margin: .55em 0 .3em; }
.schedule time { white-space: nowrap; }
.ride-row .chip { white-space: normal; }
.card--link h3 a { color: inherit; text-decoration: none; }
.card--link:hover h3 a { color: var(--blue-600); }
.prose .figure { margin: var(--space-6) 0; }
.prose .photo-frame img { aspect-ratio: 16 / 9; border-radius: 0; }
.tile__credit { position: absolute; top: var(--space-4); right: var(--space-4); font-size: .72rem; color: rgba(255,255,255,.85); text-shadow: 0 1px 3px rgba(0,0,0,.6); }
.site-footer__base a { text-decoration: underline; }

/* Store, cart and checkout (redesign, 2026-11-22; incld/site/store-inc.php). */
.buy { display: grid; gap: var(--space-5); }
.buy > * { max-width: 960px; }
.buy-steps { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); list-style: none; margin: 0; padding: 0; counter-reset: buy; font-weight: 700; color: var(--muted); }
.buy-steps li { counter-increment: buy; display: flex; align-items: center; gap: var(--space-2); }
.buy-steps li::before { content: counter(buy); display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--line); font-size: .85rem; }
.buy-steps .is-done::before { content: "\2713"; border-color: var(--ok); color: var(--ok); }
.buy-steps .is-current { color: var(--blue-700); }
.buy-steps .is-current::before { border-color: var(--blue-600); background: var(--blue-600); color: #fff; }
.buy__actions { margin: 0; }
.buy__grid { display: grid; gap: var(--space-5); grid-template-columns: minmax(0, 1fr) minmax(0, 360px); align-items: start; }
@media (max-width: 760px) { .buy__grid { grid-template-columns: minmax(0, 1fr); } }
.cart-table tfoot th, .cart-table tfoot td { border-bottom: 0; background: var(--blue-50); }
.cart-table__remove { text-align: right; width: 1%; white-space: nowrap; }
.cart-table__remove form { margin: 0; }
.btn-link { background: none; border: 0; padding: 0; font: inherit; color: var(--blue-600); text-decoration: underline; cursor: pointer; }
.btn-link:hover { color: var(--blue-800); }
.product-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-5); grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
/* An h2 for the outline, styled like the other card titles (h3). */
.product__name { font-size: var(--step-2); font-stretch: var(--semi-wide); text-transform: none; margin: 0; }
.product .product__price { font-weight: 800; color: var(--ink); font-size: var(--step-1); margin: 0; }
.product__buy { display: flex; flex-wrap: wrap; align-items: end; gap: var(--space-3); margin-top: auto; }
.product__qty { display: grid; gap: var(--space-1); font-size: var(--step--1); font-weight: 700; }
.product__qty select { min-height: 48px; padding: 0 var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-sm); font: inherit; }
.pay__title { font-size: var(--step-2); font-stretch: var(--semi-wide); text-transform: none; margin: 0; }
.pay__buttons { display: grid; gap: var(--space-3); min-height: 48px; }
.pay__buttons [hidden] { display: none !important; }
.pay__loading { color: var(--muted); margin: 0; }
.pay__status { margin: 0; font-weight: 600; }
.pay__status:empty { display: none; }
.pay__status.is-error { color: var(--stop); }

/* Photo event cards on the home page (2026-11-24): the photo fills the card, darkened at the top for the season
   label and at the bottom for the title, so the text reads on any photo. */
.event-card--photo { min-height: 380px; background: var(--blue-900); isolation: isolate; }
.event-card--photo:nth-child(n) { background: var(--blue-900); }
.event-card__img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.event-card--photo::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(12,24,48,.6) 0%, rgba(12,24,48,0) 26%, rgba(12,24,48,.2) 42%, rgba(12,24,48,.8) 62%, rgba(12,24,48,.95) 85%); }
.event-card--photo:hover .event-card__img, .event-card--photo:focus-visible .event-card__img { transform: scale(1.04); }
.event-card--photo .event-card__season { text-shadow: 0 1px 3px rgba(0,0,0,.5); }
.event-card--photo p { color: #dbe6f7; }
@media (prefers-reduced-motion: reduce) { .event-card__img { transition: none; } }

/* Text beside a portrait photo (Cat's Hill history, 2026-11-24); stacks on phones. */
.story { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 17rem); gap: var(--space-6); align-items: start; }
.story > div > p:first-child { margin-top: 0; }
.prose .story .figure { margin: 0; }
.prose .figure--portrait .photo-frame img { aspect-ratio: 3 / 4; }
@media (max-width: 720px) { .story { grid-template-columns: minmax(0, 1fr); } .story .figure--portrait { max-width: 22rem; } }
.prose .callout + .story { margin-top: var(--space-5); }
.btn-stack { display: grid; gap: var(--space-2); }

/* Donate page: the site's own donation form (Fix 25) */
.donate-online { display: grid; gap: var(--space-5); margin: var(--space-4) 0 var(--space-5); padding: var(--space-5); }
.donate-online fieldset { border: 0; margin: 0; padding: 0; }
.donate-online legend { font-weight: 700; margin-bottom: var(--space-2); }
.amount-choices { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.amount-choice { position: relative; }
.amount-choice input { position: absolute; opacity: 0; inset: 0; }
.amount-choice span { display: inline-flex; align-items: center; justify-content: center; min-width: 4.5rem; padding: var(--space-2) var(--space-4); border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font-weight: 700; cursor: pointer; }
.amount-choice input:checked + span { border-color: var(--blue-600); background: var(--blue-600); color: #fff; }
.amount-choice input:focus-visible + span { outline: 2px solid var(--blue-500); outline-offset: 2px; }
.amount-other { margin-top: var(--space-3); display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }
.amount-other .input { max-width: 10rem; }
.donate-summary { margin: 0; font-weight: 700; font-size: var(--step-1); color: var(--ink); }
.donate-summary:empty { display: none; }
/* Renewal pay step: membership, optional gift, total (Fix 32) */
.member-area--store { margin-bottom: var(--space-6); }   /* the members menu above the store (Fix 35) */
.gift-form { display: grid; gap: var(--space-4); max-width: 40rem; }
.gift-line { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-4); padding-bottom: var(--space-3); border-bottom: 1px solid var(--line); }
.gift-line b { display: block; color: var(--ink); }
.gift-line small { display: block; color: var(--muted); font-size: var(--step--1); }
.gift-line__amt { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--ink); }
.gift-line--total { border-bottom: 0; border-top: 2px solid var(--ink); padding: var(--space-3) 0 0; font-size: var(--step-1); }
.gift { margin: 0; }
.gift legend { padding: 0; font: 700 var(--step-1)/1.25 var(--font); color: var(--ink); }
.gift__sub { margin: 2px 0 var(--space-3); color: var(--muted); font-size: var(--step--1); }
.gift__program { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-5); margin-top: var(--space-4); }
.gift__for { flex-basis: 100%; margin: 0; font-weight: 700; color: var(--ink); }
.gift__radio { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.gift__radio input { width: 20px; height: 20px; margin: 0; accent-color: var(--blue-600); }
.gift .field__hint { margin-top: var(--space-3); }
