/* Application layout — the styling that used to live in template `style="…"`
   attributes, pulled out so the markup is class-only and the CSP needs no
   inline-style allowance for our own pages. styles.css stays the untouched
   copy of the Industry design system; everything app-specific is here.

   Values are taken verbatim from the templates. Names are page-scoped
   (`.home-*`, `.cal-*`, `.event-*`, `.console-*`, …) with a few shared
   patterns at the top. Load order: styles.css first, then this file. */

/* ─────────────────────────  base / document  ───────────────────────── */
body { margin: 0; background: var(--color-bg); font-family: var(--font-body); font-size: 15px; color: var(--color-text); }
a { color: var(--color-accent-700); }
a:hover { color: var(--color-accent-800); }
input[type=checkbox] { accent-color: var(--color-accent); width: 15px; height: 15px; }

.shell { min-height: 100vh; display: flex; flex-direction: column; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; width: 100%; box-sizing: border-box; }
.navlink { font-family: var(--font-heading); font-weight: 600; font-size: 13.5px; letter-spacing: .02em; text-transform: uppercase; background: none; border: 0; padding: 6px 10px; cursor: pointer; color: inherit; text-decoration: none; border-bottom: 2px solid transparent; }
.navlink:hover { color: var(--color-accent-700); }
.navlink[aria-current=page] { border-bottom-color: var(--color-accent); }
.flash { border: 1px solid var(--color-divider); padding: 11px 14px; font-size: 13.5px; margin: 18px 0; }

/* ─────────────────────────  shared patterns  ───────────────────────── */
/* section kicker — small caps label above a heading */
.kicker { font-size: 13px; letter-spacing: .13em; text-transform: uppercase; color: var(--color-neutral-600); margin: 0 0 12px; }
.kicker-16 { font-size: 13px; letter-spacing: .13em; text-transform: uppercase; color: var(--color-neutral-600); margin: 0 0 16px; }
.kicker-sm { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); margin-bottom: 10px; }
.kicker-sm-7 { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); margin-bottom: 7px; }

.prose { font-size: 15px; line-height: 1.65; margin: 0 0 32px; }
.section-pad { padding-top: 40px; padding-bottom: 70px; }
.stack-links { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.inline-link { font-size: 13.5px; }
.inline-icon { display: flex; align-items: center; gap: 7px; }
.row-icon { display: flex; align-items: center; gap: 6px; }
.text-right { text-align: right; }
.gap-7 { gap: 7px; }

.field-hint { font-size: 11px; color: var(--color-neutral-600); line-height: 1.5; margin: 12px 0 0; }
.field-error { font-size: 11.5px; color: var(--color-accent-800); margin-top: 4px; }
.meta-line { font-size: 11.5px; color: var(--color-neutral-700); margin-top: 3px; }
.heading-19 { font-family: var(--font-heading); font-weight: 600; font-size: 19px; line-height: 1.2; }
.heading-15 { font-family: var(--font-heading); font-weight: 600; font-size: 15px; }

/* ─────────────────────────  site header / footer  ──────────────────── */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--color-bg); border-bottom: 1px solid var(--color-divider); }
.site-header-bar { padding-top: 11px; padding-bottom: 11px; display: flex; align-items: center; gap: 22px; }
.site-brand { display: flex; align-items: center; gap: 12px; margin-right: auto; text-decoration: none; color: inherit; }
.site-brand-mark { width: 46px; height: 46px; flex: none; overflow: hidden; display: block; }
.site-brand-img { display: block; width: 100%; height: 100%; }
.site-brand-name { font-family: var(--font-heading); font-weight: 600; font-size: 19px; line-height: 1; letter-spacing: .01em; text-transform: uppercase; display: block; }
.site-brand-tag { font-size: 10.5px; letter-spacing: .13em; text-transform: uppercase; color: var(--color-neutral-600); margin-top: 3px; display: block; }
.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav-wa { margin-left: 10px; gap: 7px; }
.site-nav-admin { gap: 6px; padding-inline: 8px; }
.site-main { flex: 1; }
.site-footer { border-top: 1px solid var(--color-divider); margin-top: auto; }
.site-footer-inner { padding-top: 34px; padding-bottom: 40px; }
.site-footer-cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; align-items: start; margin-bottom: 26px; }
.site-footer-h { font-family: var(--font-heading); font-weight: 600; font-size: 17px; text-transform: uppercase; letter-spacing: .02em; margin-bottom: 8px; }
.site-footer-p { font-size: 13px; color: var(--color-neutral-700); margin: 0; max-width: 44ch; line-height: 1.55; }
.site-gdpr { font-size: 10.5px; line-height: 1.6; color: var(--color-neutral-600); margin: 0; border-top: 1px solid var(--color-divider); padding-top: 16px; }
.wa-float { position: fixed; right: 22px; bottom: 22px; z-index: 60; padding: 12px 18px; font-size: 15px; gap: 9px; box-shadow: var(--shadow-md); }

/* ─────────────────────────  home.html  ─────────────────────────────── */
.home-hero-sec { padding-top: 56px; padding-bottom: 20px; }
.home-hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: start; }
.home-eyebrow { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
/* "Free to join" leads to /my/join: a button in the accent outline the tag had. */
.home-join { border-color: var(--color-accent); color: var(--color-accent); }
.home-join:hover { background: var(--color-accent-100); }
.home-eyebrow-note { font-size: 11px; letter-spacing: .13em; text-transform: uppercase; color: var(--color-neutral-600); }
.home-hero { font-size: 58px; line-height: .98; letter-spacing: -.02em; text-transform: uppercase; margin: 0 0 22px; max-width: 15ch; }
.home-lead { font-size: 18px; line-height: 1.6; max-width: 52ch; margin: 0 0 14px; text-wrap: pretty; }
.home-lead-last { margin-bottom: 30px; }
.home-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.home-cta-primary { padding: 11px 22px; font-size: 15px; }
.home-cta-ask { padding: 11px 20px; font-size: 15px; gap: 8px; }
.home-hero-fig { aspect-ratio: 4/5; margin: 0; }
.home-hero-img { width: 100%; height: 100%; object-fit: cover; display: block; }

.section-pad-34 { padding-top: 34px; padding-bottom: 70px; }
.kicker-20 { margin: 0 0 20px; }
.home-next-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.home-next-card { padding: 18px; gap: 0; color: inherit; display: block; }
/* Two sibling links in one card (#39): the ride's name is stretched over the whole
   card, and the what3words link sits above that, so it is the only part of the
   card that goes anywhere else. The focus ring is drawn round the card. */
.home-next-link { color: inherit; text-decoration: none; }
.home-next-link::after { content: ""; position: absolute; inset: 0; }
.home-next-link:focus-visible { outline: none; }
.home-next-card:has(.home-next-link:focus-visible) { outline: 2px solid var(--color-accent); outline-offset: 4px; }
.home-next-w3w { position: relative; z-index: 1; display: block; width: fit-content; max-width: 100%; min-height: 24px; padding-block: 3px; color: var(--color-accent-700); }
.home-next-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.home-next-date { font-family: var(--font-heading); font-weight: 600; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--color-accent-700); }
.home-next-going { font-size: 11px; color: var(--color-neutral-600); font-variant-numeric: tabular-nums; }
.home-next-name { font-family: var(--font-heading); font-weight: 600; font-size: 23px; line-height: 1.1; letter-spacing: -.015em; margin: 9px 0 12px; }
.home-next-meta { font-size: 12.5px; color: var(--color-neutral-700); line-height: 1.5; }
.home-next-tag { margin-top: 14px; }

/* ─────────────────────────  _macros.html  ─────────────────────────── */
/* Data-driven widths, snapped to a 5% step so a width is a class, not an inline style. */
.w-0 { width: 0%; } .w-5 { width: 5%; } .w-10 { width: 10%; } .w-15 { width: 15%; } .w-20 { width: 20%; } .w-25 { width: 25%; } .w-30 { width: 30%; } .w-35 { width: 35%; } .w-40 { width: 40%; } .w-45 { width: 45%; } .w-50 { width: 50%; } .w-55 { width: 55%; } .w-60 { width: 60%; } .w-65 { width: 65%; } .w-70 { width: 70%; } .w-75 { width: 75%; } .w-80 { width: 80%; } .w-85 { width: 85%; } .w-90 { width: 90%; } .w-95 { width: 95%; } .w-100 { width: 100%; }

.stat-cell { background: var(--color-bg); padding: 20px 18px; }
.stat-cell-value { font-family: var(--font-heading); font-weight: 600; font-size: 38px; line-height: 1; letter-spacing: -.02em; color: var(--color-accent-700); font-variant-numeric: tabular-nums; }
.stat-cell-label { font-size: 11px; letter-spacing: .11em; text-transform: uppercase; color: var(--color-neutral-600); margin-top: 8px; }

/* ─────────────────────────  404 / 500  ───────────────────────────── */
.error-page { padding: 80px 24px 100px; max-width: 520px; text-align: center; }
.error-code { font-family: var(--font-heading); font-weight: 600; font-size: 72px; line-height: 1; color: var(--color-accent-700); letter-spacing: -.03em; }
.error-h { font-size: 28px; text-transform: uppercase; margin: 0 0 10px; }
.error-h--after-code { margin: 14px 0 10px; }
.error-p { font-size: 15px; color: var(--color-neutral-700); margin: 0 0 24px; }
.error-cta { padding: 11px 22px; }

/* ─────────────────────────  shared: forms  ───────────────────────── */
.field-mb-14 { margin-bottom: 14px; }
.field-mb-8 { margin-bottom: 8px; }
.btn-sm { font-size: 13px; }

/* ─────────────────────────  rider/login.html  ────────────────────── */
.auth-card-wrap { max-width: 420px; margin: 30px auto; }
.auth-card { padding: 28px 24px; display: block; }
.auth-title { margin: 0 0 6px; font-size: 28px; text-transform: uppercase; }
.auth-intro { font-size: 13px; color: var(--color-neutral-700); margin: 0 0 20px; line-height: 1.5; }
.auth-error { font-size: 12px; color: var(--color-accent-800); margin-bottom: 8px; }
.auth-submit { padding: 11px; margin-top: 12px; }

/* ─────────────────────────  rider/bookings.html  ─────────────────── */
.rider-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 24px; }

.rider-sub { margin: 0; font-size: 13px; color: var(--color-neutral-700); }
.rider-row { background: var(--color-bg); display: grid; grid-template-columns: 1fr auto auto; gap: 22px; align-items: center; padding: 18px 20px; }
.rider-row-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 5px; }
.rider-row-name { font-family: var(--font-heading); font-weight: 600; font-size: 21px; line-height: 1.1; }
.rider-row-when { font-size: 12.5px; color: var(--color-neutral-700); }
.rider-row-bike { font-size: 12px; color: var(--color-neutral-600); margin-top: 4px; }
.rider-empty { font-size: 14px; color: var(--color-neutral-700); padding-top: 22px; }
.rider-note { font-size: 11px; color: var(--color-neutral-600); margin: 18px 0 0; line-height: 1.5; }

/* ─────────────────────────  shared: panels / lists  ──────────────── */
.blueprint-pad { padding: 28px 24px; }
.hairline-list { display: flex; flex-direction: column; gap: 1px; background: var(--color-divider); border: 1px solid var(--color-divider); }
.kv-row { background: var(--color-bg); display: grid; grid-template-columns: 112px 1fr; gap: 12px; padding: 9px 12px; font-size: 13px; }
.kv-key { color: var(--color-neutral-600); }
.table-frame { padding: 6px 14px 10px; }
/* Wide tables scroll sideways inside their frame on a narrow screen instead of
   widening the page. */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.btn-pad-sm { padding: 10px 15px; }
.prose--14 { margin-bottom: 14px; }
.prose--0 { margin-bottom: 0; }

/* ─────────────────────────  privacy.html  ───────────────────────── */
.privacy-sec { padding-top: 40px; padding-bottom: 80px; max-width: 760px; }
.privacy-h1 { font-size: 40px; text-transform: uppercase; letter-spacing: -.015em; margin: 0 0 8px; }
.privacy-controller { font-size: 13px; color: var(--color-neutral-700); margin: 0 0 34px; }
.privacy-table { margin-bottom: 32px; }

/* ─────────────────────────  booked.html  ────────────────────────── */
.booked-sec { padding-top: 48px; padding-bottom: 80px; max-width: 640px; }
.booked-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; color: var(--color-accent-700); }
.booked-h1 { margin: 0; font-size: 28px; text-transform: uppercase; }
.booked-lead { font-size: 15px; line-height: 1.55; margin: 0 0 20px; }
.booked-kv { margin-bottom: 20px; }
.booked-note { font-size: 11px; color: var(--color-neutral-600); line-height: 1.5; margin: 0 0 20px; }
.booked-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ─────────────────────────  shared: page headers  ───────────────── */
.page-h1 { font-size: 40px; text-transform: uppercase; letter-spacing: -.015em; margin: 0 0 6px; }
.page-sub { margin: 0; font-size: 13px; color: var(--color-neutral-700); }

/* ─────────────────────────  events.html  ────────────────────────── */
.cal-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 26px; }
.cal-controls { display: flex; gap: 12px; align-items: center; }
a.seg-opt { text-decoration: none; }
.seg-opt.is-active { background: var(--color-accent); color: var(--color-bg); }
.seg-count { opacity: .6; margin-left: 4px; }

/* what3words in any language: a long word must wrap, never push the row wider. */
.w3w-link { overflow-wrap: anywhere; }
/* What a ride costs (#40), from price_tag in _macros.html. A fee never breaks across a line. */
.price-tag { white-space: nowrap; }
/* On the ride page the price follows the meet time (#40). Where the two can't share a line
   (its narrow "Meet at" cell on a phone), the tag drops beneath the time, never squeezes. */
.meet-price { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; }

/* The list (#49): one list grouped by month, the only place on the page to book. */
.cal-filter { display: flex; align-items: center; justify-content: space-between; gap: 8px 18px; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 22px; border: 1px solid var(--color-divider); background: color-mix(in srgb, var(--color-accent) 8%, var(--color-bg)); font-size: 13.5px; }
.cal-filter b { font-weight: 600; }
.cal-filter-all { font-size: 13px; }
.cal-month + .cal-month { margin-top: 30px; }
.cal-month-h { font-size: 22px; letter-spacing: .02em; text-transform: uppercase; margin: 0 0 12px; }
.cal-month-count { font-family: var(--font-body); font-weight: 400; font-size: 13px; letter-spacing: 0; text-transform: none; color: var(--color-neutral-700); }
.cal-ride { background: var(--color-bg); display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; gap: 22px; align-items: center; padding: 18px 20px; }
.cal-ride-date { display: flex; flex-direction: column; align-self: start; border-right: 1px solid var(--color-divider); padding-right: 16px; }
.cal-ride-mon, .cal-ride-wd { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); }
.cal-ride-day { font-family: var(--font-heading); font-weight: 600; font-size: 34px; line-height: 1; letter-spacing: -.02em; font-variant-numeric: tabular-nums; margin: 2px 0 3px; }
.cal-ride-name { font-size: 23px; line-height: 1.1; letter-spacing: -.015em; margin: 0 0 7px; }
.cal-ride-tags { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 9px; }
.cal-ride-meta { display: flex; align-items: center; gap: 4px 18px; flex-wrap: wrap; font-size: 12.5px; color: var(--color-neutral-700); }
.cal-ride-point { color: inherit; text-decoration: underline; text-decoration-color: var(--color-neutral-500); text-underline-offset: 3px; }
.cal-ride-point:hover { color: var(--color-text); text-decoration-color: currentColor; }
.cal-ride-places { display: grid; gap: 5px; margin-top: 11px; font-size: 12px; color: var(--color-neutral-700); font-variant-numeric: tabular-nums; }
.cal-ride-bar { display: block; width: 100%; max-width: 320px; height: 4px; background: var(--color-neutral-200); }
.cal-ride-bar-booked { fill: var(--color-accent); }
.cal-ride-bar-held { fill: var(--color-accent-300); }
.cal-ride--done .cal-ride-name { color: var(--color-neutral-700); }
.cal-ride--done .cal-ride-bar-booked { fill: var(--color-neutral-500); }
.cal-ride-cta { padding: 9px 16px; white-space: nowrap; }
/* The rows a pin on the map points at (#50, the message from map.js). */
.cal-ride.is-hot { background: color-mix(in srgb, var(--color-accent) 10%, var(--color-bg)); }

/* ─────────────────────────  shared: forms (cont.)  ──────────────── */
.field-mb-16 { margin-bottom: 16px; }
.field-mb-18 { margin-bottom: 18px; }
.kicker--14 { margin-bottom: 14px; }
.kicker-sm-12 { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); margin-bottom: 12px; }
.form-section { border-top: 1px solid var(--color-divider); padding-top: 16px; margin-bottom: 16px; }
.form-section--last { margin-bottom: 0; }
.check-row { display: grid; grid-template-columns: auto 1fr; gap: 10px; font-size: 12.5px; line-height: 1.5; cursor: pointer; }
.check-row--mb { margin-bottom: 12px; }
/* The booking form's "Add more details": shut until ticked (static/js/app.js). */
.book-more[hidden] { display: none; }
.book-more-h { font-weight: 600; color: var(--color-text); }
.req-mark { color: var(--color-accent-800); }
.visually-hidden { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ─────────────────────────  event.html  ─────────────────────────── */
.event-sec { padding-top: 28px; padding-bottom: 70px; }
.event-back { gap: 7px; margin-bottom: 20px; }
.event-tags { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.event-h1 { font-size: 46px; line-height: 1.02; letter-spacing: -.02em; text-transform: uppercase; margin: 0 0 26px; max-width: 26ch; }
.event-spec { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--color-divider); border: 1px solid var(--color-divider); margin-bottom: 34px; }
.spec-cell { background: var(--color-bg); padding: 16px 18px; }
.event-body { display: grid; grid-template-columns: 1.05fr .95fr; gap: 44px; align-items: start; }
.event-briefing { font-size: 16px; line-height: 1.6; margin: 0 0 30px; text-wrap: pretty;
  white-space: pre-line; }
.event-models { display: flex; flex-wrap: wrap; gap: 6px; }

/* The ride in numbers (#43): full width under the booking form, a six-column
   grid of blueprint cards that stacks to one column below 900px. */
.event-stats { margin-top: 56px; padding-top: 30px; border-top: 1px solid var(--color-divider); }
.event-stats-h { font-size: 30px; line-height: 1.05; text-transform: uppercase; margin: 0 0 8px; }
.event-stats-lede { font-size: 16px; margin: 0 0 30px; font-variant-numeric: tabular-nums; }
.event-stats-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 30px; align-items: start; }
.event-stats-card { grid-column: span 3; min-width: 0; padding: 20px; }
.event-stats-card--places { grid-column: span 2; }
.event-stats-card--pace { grid-column: span 4; }
.event-stats-card--who { grid-column: span 4; }
.event-stats-card--back { grid-column: span 2; }   /* beside Who's coming (#47) */
.event-stats-card-h { margin: 0 0 14px; font-family: var(--font-body); font-weight: 400; line-height: 1.3; }
.event-stats-sub { font-size: 12.5px; color: var(--color-neutral-700); margin: 0 0 20px; line-height: 1.45; }
.event-stats-sub--foot { margin: 12px 0 0; }

/* The booking pace (#45, _macros.pace_chart): a step line in a viewBox that
   scales with its card. Lines keep their thickness whatever the scale, and the
   words are sized in viewBox units, doubled on a phone where the chart is
   drawn at about half size. */
.pace { display: block; height: auto; overflow: visible; }
.pace line, .pace path { vector-effect: non-scaling-stroke; }
.pace-axis { stroke: var(--color-neutral-500); stroke-width: 1; }
.pace-cap { stroke: var(--color-neutral-600); stroke-width: 1; stroke-dasharray: 4 3; }
.pace-today { stroke: var(--color-text); stroke-width: 1; stroke-dasharray: 2 3; }
.pace-line { fill: none; stroke: var(--color-accent); stroke-width: 2; stroke-linejoin: round; }
.pace-line--wait { stroke: var(--color-neutral-500); }
.pace-dot { fill: var(--color-accent-700); }
.pace-hit { fill: transparent; }
.pace-mark:hover .pace-dot { fill: var(--color-text); }
.pace-label { font: 600 11px var(--font-body); letter-spacing: .06em; fill: var(--color-neutral-600); }
.pace-label--today { fill: var(--color-text); }
.event-stats-note { font-size: 11px; color: var(--color-neutral-600); margin: 22px 0 0; line-height: 1.45; }

/* Places grid (#44, _macros.places_grid): one square per place. Booked is the
   accent, held is the accent hatched (taken, not settled), free is an outline
   and the waitlist neutral. The outline and fills keep 3:1 against the page. */
.places-head { display: flex; align-items: baseline; gap: 10px; margin: 0 0 16px; }
.places-num { font-family: var(--font-heading); font-weight: 600; font-size: 44px; line-height: 1; letter-spacing: -.02em; color: var(--color-accent-700); font-variant-numeric: tabular-nums; }
.places-of { font-size: 13px; color: var(--color-neutral-700); }
.places { display: grid; gap: 10px; margin-bottom: 16px; }
.places-row { display: flex; flex-wrap: wrap; gap: 5px; }
.places-sq { display: block; width: 20px; height: 20px; border: 1px solid transparent; }
.places--dense .places-row { gap: 3px; }
.places--dense .places-sq { width: 12px; height: 12px; }
.places-sq--booked { background: var(--color-accent); }
.places-sq--held { border-color: var(--color-accent);
  background-image: repeating-linear-gradient(135deg, var(--color-accent) 0 2px, transparent 2px 5px); }
.places-sq--free { border-color: var(--color-neutral-600); }
.places-sq--wait { background: var(--color-neutral-500); }
.places-wait { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); }
.places-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--color-neutral-700); }
.places-legend li { display: inline-flex; align-items: center; gap: 6px; }
.places-legend b { font-weight: 600; color: var(--color-text); font-variant-numeric: tabular-nums; }
.places-sw { display: inline-block; flex: none; width: 10px; height: 10px; border: 1px solid transparent; }
@media (max-width: 900px) {
  .event-stats-card, .event-stats-card--places, .event-stats-card--pace, .event-stats-card--who,
  .event-stats-card--back { grid-column: 1 / -1; }
}

/* Split bars (#46, _macros.split_bar): one bar per group, a block per ordered
   category in the steel ramp. 600 is skipped (ride_stats.TONES): the share
   printed inside a block is dark on 300-500 and light on 700-800, 4.5:1 or
   better either way. A hairline of the page colour parts the blocks. */
.split { margin-bottom: 22px; }
.split-h { font-family: var(--font-body); font-weight: 400; font-size: 10.5px; line-height: 1.3; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); margin: 0 0 9px; }
.split-row { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); align-items: center; gap: 12px; margin-bottom: 6px; }
.split-name { font-size: 12.5px; color: var(--color-neutral-700); }
.split-row--solo { grid-template-columns: minmax(0, 1fr); }
.split-bar { display: block; width: 100%; height: 24px; overflow: visible; }
.split-bar rect { stroke: var(--color-bg); stroke-width: 1; }
.split-pct { font-family: var(--font-body); font-size: 11px; font-variant-numeric: tabular-nums; pointer-events: none; }
.split-empty { height: 24px; display: flex; align-items: center; padding-inline: 10px; font-size: 12px; color: var(--color-neutral-700); border: 1px dashed var(--color-neutral-500); }
.split-legend { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--color-neutral-700); }
.split-legend li { display: inline-flex; align-items: center; gap: 6px; }
.split-legend b { font-weight: 600; color: var(--color-text); font-variant-numeric: tabular-nums; }
.split-sw { display: inline-block; flex: none; width: 10px; height: 10px; background: var(--split-fill); }
.split-t300 { --split-fill: var(--color-accent-300); --split-ink: var(--color-text); }
.split-t400 { --split-fill: var(--color-accent-400); --split-ink: var(--color-text); }
.split-t500 { --split-fill: var(--color-accent-500); --split-ink: var(--color-text); }
.split-t700 { --split-fill: var(--color-accent-700); --split-ink: var(--color-bg); }
.split-t800 { --split-fill: var(--color-accent-800); --split-ink: var(--color-bg); }
.split-bar g rect { fill: var(--split-fill); }
.split-bar g text { fill: var(--split-ink); }
@media (max-width: 640px) {
  .split-row { grid-template-columns: minmax(0, 1fr); gap: 3px; margin-bottom: 10px; }
  .split-pct--small { display: none; }
}
.event-done { padding: 26px 22px; }
.event-done-h { margin: 0 0 8px; font-size: 22px; text-transform: uppercase; }
.event-done-p { font-size: 14px; color: var(--color-neutral-700); margin: 0 0 18px; }
.event-done-cta { padding: 11px; }
/* A book-direct ride's notice (#57), in the booking form's place. Names and
   links are the organiser's: a long one wraps rather than pushing the page
   sideways on a phone. */
.event-direct-h, .event-direct-must { overflow-wrap: anywhere; }
.event-direct-must { font-size: 15px; line-height: 1.45; margin: 0 0 10px; }
.event-direct-cta { overflow-wrap: anywhere; text-align: center; }
.event-direct-host { font-size: 12px; color: var(--color-neutral-600); text-align: center; margin: 8px 0 0; overflow-wrap: anywhere; }
.event-direct-say { font-size: 13px; color: var(--color-neutral-700); margin: 18px 0 0; }
.book-form { padding: 24px 22px; display: block; }
.book-h { margin: 0 0 4px; font-size: 26px; text-transform: uppercase; }
.book-intro { font-size: 12.5px; color: var(--color-neutral-700); margin: 0 0 20px; }
.book-radios { display: flex; flex-direction: column; gap: 8px; margin-top: 3px; }
.book-charcount { font-size: 11px; color: var(--color-neutral-600); margin-top: 4px; }
.book-dpnote { font-size: 11px; color: var(--color-neutral-600); line-height: 1.5; margin: 14px 0 0; }
.book-submit { padding: 12px; font-size: 15px; margin-top: 20px; }

/* ─────────────────────────  shared: tables  ─────────────────────── */
.plain-link { text-decoration: none; color: inherit; }
.td-nowrap { font-size: 13px; white-space: nowrap; }
.td-13 { font-size: 13px; }
.td-num { text-align: right; font-variant-numeric: tabular-nums; }

/* ──────────────  events.html: calendar + map + season stats  ───────────── */
.cal-layout { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 28px; align-items: start; margin-bottom: 44px; }
/* Sticky under the (sticky) site header, so the map stays in view beside a long list. */
.cal-side { position: sticky; top: 92px; }
/* Pins only since #50, no list beside the map: as tall as the window allows beside a
   long list, between 460 and 640px. */
.cal-map-frame { display: block; width: 100%; height: max(460px, min(640px, calc(100vh - 124px))); border: 0; }
.cal-none { font-size: 13px; color: var(--color-neutral-600); padding: 16px 18px; margin: 0; border: 1px solid var(--color-divider); }
.cal-season-h { margin-bottom: 14px; }
/* The season (#51): headline figures over a strip of one bar per ride
   (_macros.season_strip). The strip is drawn at a fixed scale and scrolls
   sideways inside its own box, so the page never does. */
.season { margin-bottom: 38px; }
.season-figures { font-size: 15px; margin: 0 0 14px; color: var(--color-neutral-700); font-variant-numeric: tabular-nums; }
.season-figures b { font-family: var(--font-heading); font-weight: 600; font-size: 24px; color: var(--color-text); }
.strip { max-width: 100%; overflow-x: auto; border: 1px solid var(--color-divider); padding-top: 4px; }
.strip:focus-visible { outline: 2px solid var(--color-accent-700); outline-offset: 2px; }
.strip-svg { display: block; }
.strip-month { stroke: var(--color-divider); stroke-width: 1; }
.strip-axis { stroke: var(--color-neutral-500); stroke-width: 1; }
.strip-month-label, .strip-today-label { font: 600 10px var(--font-body); letter-spacing: .1em; fill: var(--color-neutral-600); }
.strip-today { stroke: var(--color-text); stroke-width: 1; stroke-dasharray: 3 3; }
.strip-today-label { fill: var(--color-text); }
.strip-free { fill: var(--color-bg); stroke: var(--color-accent); stroke-width: 1; }
.strip-taken { fill: var(--color-accent); }
.strip-wait { fill: var(--color-neutral-500); }
.strip-bar { cursor: pointer; }
.strip-bar:focus { outline: none; }
.strip-bar.is-dim { opacity: .3; }
.strip-bar.is-hot .strip-free, .strip-bar:focus-visible .strip-free { stroke: var(--color-text); stroke-width: 2; }
.strip-bar.is-hot .strip-taken { fill: var(--color-text); }
/* The readout names a ride, and a book-direct one its organiser (#58): a long
   single word wraps rather than pushing the page sideways on a phone. */
.strip-readout { min-height: 1.4em; margin: 8px 0 6px; font-size: 12.5px; color: var(--color-neutral-700); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.strip-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--color-neutral-700); }
.strip-legend li { display: inline-flex; align-items: center; gap: 6px; }
.strip-sw { display: inline-block; width: 10px; height: 10px; box-sizing: border-box; }
.strip-sw--taken { background: var(--color-accent); }
.strip-sw--free { border: 1px solid var(--color-accent); background: var(--color-bg); }
.strip-sw--wait { background: var(--color-neutral-500); }
/* A book-direct ride's bar (#58): no places here, so a short dashed outline. */
.strip-direct { stroke-dasharray: 3 2; }
.strip-sw--direct { border: 1px dashed var(--color-accent); background: var(--color-bg); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--color-divider); border: 1px solid var(--color-divider); margin-bottom: 38px; }
/* Who's riding (#52): the ride page's split bars (#46), one per group, in one card. */
.riding { margin-bottom: 14px; }
.riding-sub { font-size: 13px; color: var(--color-neutral-700); margin: -6px 0 14px; }
.riding-card .split:last-child { margin-bottom: 0; }
.blueprint-pad-20 { padding: 20px; }

/* ─────────────────────────  shared: admin console  ──────────────── */
.h1-38 { font-size: 38px; text-transform: uppercase; letter-spacing: -.015em; margin: 0 0 5px; }
.console-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 22px; }
.console-sub { margin: 0; font-size: 12.5px; color: var(--color-neutral-700); }
.console-tabs { display: flex; border-bottom: 1px solid var(--color-divider); margin-bottom: 26px; }
.console-tab { font-family: var(--font-heading); font-weight: 600; font-size: 14px; letter-spacing: .03em; text-transform: uppercase; text-decoration: none; padding: 9px 16px; margin-bottom: -1px; border-bottom: 2px solid transparent; color: var(--color-neutral-700); }
.console-tab.is-active { border-bottom-color: var(--color-accent); color: var(--color-accent-800); }

/* ─────────────────────────  shared: admin tables / forms  ───────── */
.form-inline { display: inline; }
.kicker--0 { margin: 0; }
.console-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.console-form { padding: 26px 24px; display: block; }
.console-form-h { margin: 0 0 6px; font-size: 26px; text-transform: uppercase; }
.console-form-copy { color: var(--color-neutral-700); text-transform: none; font-size: 0.7em; }
.console-form-sub { font-size: 12.5px; color: var(--color-neutral-700); margin: 0 0 22px; }
.mw-760 { max-width: 760px; }
.event-cancel { margin-top: 24px; }
.two-step-steps { margin: 0 0 18px; padding-left: 20px; font-size: 13.5px; line-height: 1.6; }
.two-step-steps li { margin-bottom: 10px; }
.two-step-qr { margin: 12px 0; padding: var(--space-3); background: var(--color-bg); display: inline-block; border: 1px solid var(--color-neutral-300); }
.two-step-qr img { display: block; width: 200px; height: 200px; }
.two-step-secret { font-variant-numeric: tabular-nums; font-size: 14px; letter-spacing: 0.04em; word-break: break-all; }
.two-step-code { max-width: 180px; font-variant-numeric: tabular-nums; font-size: 18px; letter-spacing: 0.15em; }
.two-step-codes { list-style: none; padding: 0; margin: 0 0 6px; display: grid; grid-template-columns: repeat(2, minmax(0, 12ch)); gap: 8px 24px; font-variant-numeric: tabular-nums; font-size: 16px; }
.user-reset { display: flex; align-items: center; justify-content: flex-end; gap: 6px; margin-bottom: 6px; }
.user-reset-email { max-width: 200px; padding: 4px 8px; font-size: 12px; }
@media (max-width: 640px) { .user-reset { flex-wrap: wrap; justify-content: flex-start; } }
.mw-640 { max-width: 640px; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.col-span { grid-column: 1 / -1; }
.check-row-14 { display: grid; grid-template-columns: auto 1fr; gap: 10px; font-size: 12.5px; line-height: 1.4; cursor: pointer; }
.form-err-top { font-size: 12px; color: var(--color-accent-800); margin-top: 14px; }
.form-actions { display: flex; gap: 12px; }
.form-actions--24 { margin-top: 24px; }
.form-actions--18 { margin-top: 18px; }
.btn-pad-lg { padding: 11px 22px; }
.btn-pad-10 { padding: 10px; }
.btn-xs { font-size: 12.5px; }
.btn-danger { color: var(--color-accent-900); }
.ta-90 { min-height: 90px; }
.ta-170 { min-height: 170px; }
.field-mb-12 { margin-bottom: 12px; }
.field-hint-4 { font-size: 11px; color: var(--color-neutral-600); line-height: 1.5; margin-top: 4px; }
.field-hint--18 { margin-top: 18px; }
.field-hint--14 { margin-top: 14px; }

/* table cell helpers */
.td-125 { font-size: 12.5px; }
.td-tnum { font-variant-numeric: tabular-nums; }
.td-actions { text-align: right; white-space: nowrap; }
.td-idx { color: var(--color-neutral-600); font-variant-numeric: tabular-nums; }
.td-nowrap-only { white-space: nowrap; }
/* .table is width:100%, so without a floor the browser squeezes columns to
   nothing rather than letting .table-scroll scroll. The attendee list gained a
   Payment column, which is the point at which that starts to hurt. */
.td-comment { font-size: 12.5px; color: var(--color-neutral-700); min-width: 180px; max-width: 280px; }
.td-125-nowrap { font-size: 12.5px; white-space: nowrap; }
.td-125-muted { font-size: 12.5px; color: var(--color-neutral-700); }
.td-13-muted { font-size: 13px; color: var(--color-neutral-700); }
.td-mono { font-size: 12.5px; font-family: ui-monospace, Menlo, monospace; }
.td-mono--muted { color: var(--color-neutral-600); }
.td-when { font-size: 12.5px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.table-empty { font-size: 13px; color: var(--color-neutral-600); padding: 14px 6px; }
.table-empty--flush { padding: 12px 6px; margin: 0; }
.table-frame--minh { min-height: 90px; }

/* ─────────────────────────  admin/login.html  ──────────────────── */
.adm-login-wrap { max-width: 400px; margin: 40px auto; }
.adm-login-head { display: flex; align-items: center; gap: 9px; color: var(--color-accent-700); margin-bottom: 16px; }
.adm-login-h { margin: 0; font-size: 26px; text-transform: uppercase; }

/* ─────────────────────────  admin/attendees.html  ──────────────── */
.attend-bar { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.attend-select { min-width: 340px; }
.attend-actions { display: flex; gap: 10px; }

/* ─────────────────────────  admin/users.html  ─────────────────── */
.users-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 30px; align-items: start; }
.console-aside-form { padding: 22px 20px; display: block; }
.aside-h { margin: 0 0 14px; font-size: 22px; text-transform: uppercase; }
.role-select { min-height: 30px; font-size: 13px; width: 150px; }

/* ─────────────────────────  admin/gdpr.html  ──────────────────── */
.gdpr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; align-items: start; }
.gdpr-h { margin: 0 0 6px; font-size: 24px; text-transform: uppercase; }
.gdpr-intro { font-size: 13px; color: var(--color-neutral-700); margin: 0 0 18px; line-height: 1.5; }
.gdpr-buttons { display: flex; gap: 10px; flex-wrap: wrap; }
.gdpr-msg { margin-top: 16px; padding: 12px 14px; border: 1px solid var(--color-divider); font-size: 13px; line-height: 1.5; }

/* ─────────────────────────  responsive  ───────────────────────── */
/* Tablet / narrow laptop: the map drops below the calendar at full width. */
/* ─────────────────────────  payments  ──────────────────────────── */
/* Event form: the payment section, hidden and disabled until the organiser
   ticks "riders pay a fee" (static/js/app.js toggles both). */
.pay-fields { border: 1px solid var(--color-divider); padding: 16px 14px 14px; margin: 0; min-width: 0; }
.pay-fields[hidden] { display: none; }
/* The event form's Bookings section (#56): book-direct's two fields, or the
   places, approval and payment of a ride booked here. */
.event-bookings, .event-booking-settings { display: grid; gap: 14px; }
.event-book-direct[hidden], .event-booking-settings[hidden] { display: none; }
.pay-fields-legend { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); padding: 0 6px; }
/* One rider's emergency contact, opened from the attendee list. */
.emergency-card { display: grid; grid-template-columns: max-content 1fr; gap: var(--space-2) var(--space-6); margin: 0 0 var(--space-4); }
.emergency-card dt { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--color-neutral-600); align-self: center; }
.emergency-card dd { margin: 0; font-size: 18px; }
/* One rider's medical information: the rider's words, line breaks kept. */
.medical-note { font-size: 18px; white-space: pre-line; margin: 0 0 var(--space-4); }
/* Event form: who leads the ride, as ticks in columns. */
.leader-picks { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(160px, 100%), 1fr)); gap: var(--space-2) var(--space-4); }

/* Booking form: what the day costs, shown only on a ride that charges. */
.book-fee { border: 1px solid var(--color-divider); padding: 14px; margin-bottom: 18px; }
.book-fee-amount { display: flex; align-items: baseline; gap: 8px; }
.book-fee-value { font-family: var(--font-heading); font-weight: 600; font-size: 30px; line-height: 1; letter-spacing: -.02em; color: var(--color-accent-700); font-variant-numeric: tabular-nums; }
.book-fee-per { font-size: 12.5px; color: var(--color-neutral-700); }
.book-fee-note { font-size: 11.5px; color: var(--color-neutral-700); line-height: 1.5; margin: 10px 0 0; }

/* The payment page itself. */
.pay-amount { display: flex; align-items: baseline; gap: 10px; margin: 22px 0 0; }
.pay-amount-value { font-family: var(--font-heading); font-weight: 600; font-size: 44px; line-height: 1; letter-spacing: -.02em; color: var(--color-accent-700); font-variant-numeric: tabular-nums; }
.pay-amount-label { font-size: 13px; color: var(--color-neutral-700); }
.pay-note { font-size: 11.5px; color: var(--color-neutral-600); line-height: 1.5; margin: 10px 0 0; }
.pay-actions { margin-top: 20px; }
.pay-submit { width: 100%; padding: 13px; font-size: 15px; }

/* Attendees: what has been collected, and the per-rider payment cell. */
.pay-summary { padding: 16px 18px; margin-bottom: 16px; }
.pay-summary-line { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.pay-summary-value { font-family: var(--font-heading); font-weight: 600; font-size: 30px; line-height: 1; letter-spacing: -.02em; color: var(--color-accent-700); font-variant-numeric: tabular-nums; }
.pay-summary-label { font-size: 12.5px; color: var(--color-neutral-700); }
.pay-col { min-width: 148px; }
.pay-col-h { white-space: nowrap; }
.pay-cell-meta { font-size: 11px; color: var(--color-neutral-600); line-height: 1.45; margin-top: 4px; }
/* The ref box and the button share the column's width rather than forcing it
   wider — the attendee table is already 11 columns on a paid ride. */
.pay-mark { display: flex; align-items: center; gap: 6px; margin-top: 6px; }
.pay-ref { width: 100%; min-width: 0; font-size: 12px; padding: 5px 7px; }

/* My bookings: the fee line under a booking on a paid ride. */
.rider-row-fee { font-size: 12px; color: var(--color-neutral-700); margin-top: 4px; }

@media (max-width: 1000px) {
  .cal-layout { grid-template-columns: 1fr; }
  .cal-side { position: static; }
  .cal-map-frame { height: 520px; }
}

/* Phone. */
@media (max-width: 640px) {
  .wrap { padding-inline: 16px; }  /* sides only: sections set their own top/bottom padding */
  .section-pad { padding-top: 24px; padding-bottom: 48px; }
  .page-h1 { font-size: 30px; }

  /* Header: brand on one line, nav scrolls sideways beneath it; not sticky,
     so it doesn't eat a third of the screen. */
  .site-header { position: static; }
  .site-header-bar { flex-wrap: wrap; gap: 8px; }
  .site-brand-tag { display: none; }
  .site-nav { width: 100%; overflow-x: auto; justify-content: space-between; }
  .navlink { white-space: nowrap; padding-inline: 6px; }
  .site-nav-wa { display: none; }  /* the floating "WhatsApp us" button covers it */
  .site-footer-cols { grid-template-columns: 1fr; gap: 24px; }

  .cal-head { gap: 14px; margin-bottom: 18px; }
  .cal-controls { flex-wrap: wrap; }

  /* A finger-sized target (44px) for every what3words link on a phone (#39). */
  .w3w-link { display: inline-block; min-height: 44px; padding-block: 12px; line-height: 20px; }
  .home-next-w3w { display: block; font-size: 12.5px; }

  /* The list (#49): the date column narrows, and the button takes its own
     full-width row under the ride. The meeting point is a 44px target too. */
  .cal-ride { grid-template-columns: 58px minmax(0, 1fr); gap: 14px; padding: 16px 14px; }
  .cal-ride-date { padding-right: 10px; }
  .cal-ride-day { font-size: 28px; }
  .cal-ride-name { font-size: 20px; }
  .cal-ride-meta { gap: 0 14px; }
  .cal-ride-point { display: inline-flex; min-height: 44px; }
  .cal-ride-cta { grid-column: 1 / -1; text-align: center; }

  /* Event page: one column, so the booking form follows the briefing instead of
     squeezing in beside it. */
  .event-body { grid-template-columns: 1fr; gap: 30px; }
  .event-spec { grid-template-columns: 1fr 1fr; }
  .event-stats { margin-top: 40px; padding-top: 24px; }
  .event-stats-h { font-size: 24px; }
  .event-stats-grid { gap: 22px; }
  .pace-label { font-size: 19px; }   /* the chart is drawn at about half size */

  .event-h1 { font-size: 32px; margin-bottom: 20px; }

  /* Home: hero stacks over its photo, next-ride cards one per row. */
  .home-hero-sec { padding-top: 28px; }
  .home-hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .home-hero { font-size: 38px; }
  .home-lead { font-size: 16px; }
  .home-hero-fig { aspect-ratio: 4/3; }
  .home-next-grid { grid-template-columns: 1fr; gap: 16px; }

  /* My bookings: details on their own row, the two actions share the next. */
  .h1-38 { font-size: 30px; }
  .rider-sub { overflow-wrap: anywhere; }
  .rider-row { grid-template-columns: auto 1fr; gap: 12px 10px; padding: 16px 14px; }
  .rider-row-info { grid-column: 1 / -1; }
  .rider-row-name { font-size: 19px; }

  /* Organiser console: tabs scroll sideways, two-column forms and grids stack. */
  .console-tabs { overflow-x: auto; }
  .console-tab { white-space: nowrap; padding-inline: 12px; }
  .console-bar { flex-wrap: wrap; gap: 10px; }
  .console-form { padding: 20px 16px; }
  .form-grid-2, .users-grid, .gdpr-grid { grid-template-columns: 1fr; }
  .attend-select { min-width: 0; width: 100%; }
  .pay-amount-value, .pay-summary-value { font-size: 34px; }
  .pay-fields { padding: 14px 12px 12px; }
  .pay-mark { flex-wrap: wrap; }
  .pay-ref { width: 100%; }
  .attend-bar > * { max-width: 100%; }
  .attend-actions { flex-wrap: wrap; }

  /* The map sits under the list on a phone: pins only (#50), so a 460px frame. */
  .cal-map-frame { height: 460px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
}

/* ─────────────────────────  admin/store/*  ───────────────────────── */
/* The shop's side of the organiser console. Page-scoped class names, every
   value from a design-system token, no inline styles — the CSP keeps
   style-src at 'self' with no 'unsafe-inline'. */
.field-hint--0 { margin-top: 0; margin-bottom: 14px; }
.mw-880 { max-width: 880px; }
.input-sm { padding: 5px 7px; font-size: 12.5px; }
.input-num { text-align: right; font-variant-numeric: tabular-nums; }

.store-bar-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.store-closed-note { border: 1px solid var(--color-accent-400); background: var(--color-accent-100);
  padding: 11px 14px; font-size: 13px; margin-bottom: 18px; }

.store-filter { display: flex; gap: 8px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.store-filter-search { max-width: 280px; }

/* Shop reports: the store tick boxes, the line saying what a run covered, and
   the per-rate breakdown tables under the figures. */
.report-stores { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); border: 0; padding: 0; margin: 0; }
.report-stores legend { padding: 0; }
.report-scope { margin: 0 0 var(--space-4); }
.report-breakdown { margin-bottom: var(--space-6); }

.store-thumb-cell { width: 60px; }
.store-thumb { width: 48px; height: 48px; display: block; object-fit: cover;
  border: 1px solid var(--color-divider); }
.store-thumb--none { display: grid; place-items: center; font-size: 15px;
  color: var(--color-neutral-500); background: var(--color-neutral-200); }

.store-slug-row { display: flex; align-items: center; gap: 0; }
.store-slug-prefix { font-size: 12.5px; color: var(--color-neutral-600); padding: 8px 6px 8px 0;
  white-space: nowrap; }
.store-slug-row .input { flex: 1; min-width: 0; }

.store-section-h { font-family: var(--font-heading); font-weight: 600; font-size: 17px;
  text-transform: uppercase; letter-spacing: .03em; margin: 28px 0 6px;
  padding-top: 18px; border-top: 1px solid var(--color-divider); }
.store-section-h--first { margin-top: 18px; }

/* The size/price grid. A floor per column stops the browser squeezing the
   inputs to nothing instead of letting .table-scroll scroll. */
.store-variants th, .store-variants td { padding-inline: 5px; }
.store-variants { min-width: 780px; }

.stock-adjust { display: flex; gap: 7px; align-items: center; flex-wrap: nowrap; }
.stock-adjust .input-num { width: 74px; }
.stock-adjust select.input-sm { width: 155px; }
.stock-adjust input[name="note"] { min-width: 120px; }

.store-photos { margin-top: 22px; }
.store-photos-h { font-size: 20px; }
.store-photo-grid { display: grid; gap: 16px; margin-bottom: 22px;
  grid-template-columns: repeat(auto-fill, minmax(min(190px, 100%), 1fr)); }
.store-photo { padding: 10px; position: relative; }
.store-photo-img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; display: block; }
.store-photo-tag { position: absolute; top: 16px; left: 16px; }
.store-photo-alt { margin-top: 9px; display: grid; gap: 5px; }
.store-photo-actions { display: flex; gap: 5px; align-items: center; margin-top: 8px; }
.store-upload { border-top: 1px solid var(--color-divider); padding-top: 18px;
  display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; }
.store-upload .field { flex: 1; min-width: 260px; }

.store-bands { display: grid; gap: 14px;
  /* min() so the track can never be wider than the space it has: a bare
     minmax(320px, 1fr) overflows a 320px phone once the wrap padding is
     taken off, and the whole page scrolls sideways. */
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); }
.store-band { padding: 16px 16px 14px; display: block; }
.store-band-head { display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-bottom: 12px; }
.store-band-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.store-band-foot { display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-top: 14px; }

@media (max-width: 640px) {
  .store-filter-search { max-width: none; width: 100%; }
  .store-bar-actions { width: 100%; }
  .store-band-grid { grid-template-columns: 1fr; }
  .store-upload { flex-direction: column; align-items: stretch; }
  .store-photo-grid { grid-template-columns: repeat(auto-fill, minmax(min(150px, 100%), 1fr)); }
}

/* ─────────────────────────  store/*  (the public shop)  ──────────────── */
.store-preview-note { border: 1px solid var(--color-accent-400); background: var(--color-accent-100);
  padding: 11px 14px; font-size: 13px; margin-bottom: 20px; }

.shop-head { display: flex; justify-content: space-between; align-items: flex-end;
  gap: 24px; flex-wrap: wrap; margin-bottom: 22px; }
.shop-cats { margin-bottom: 14px; flex-wrap: wrap; }
.shop-filter { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap;
  padding-bottom: 18px; margin-bottom: 26px; border-bottom: 1px solid var(--color-divider); }
.shop-filter-field { display: flex; flex-direction: column; gap: 4px; }
.shop-filter-field .input { min-width: 170px; }
.shop-filter-check { align-items: center; padding-bottom: 8px; }

.shop-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.shop-card { padding: 0; display: block; text-decoration: none; color: inherit; }
.shop-card:hover { background: color-mix(in srgb, var(--color-accent) 5%, transparent); }
.shop-card-shot { display: block; }
.shop-card-img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; display: block;
  border-bottom: 1px solid var(--color-divider); }
.shop-card-img--none { background: var(--color-neutral-200); aspect-ratio: 1; display: block; }
.shop-card-body { display: block; padding: 15px 16px 18px; }
.shop-card-kicker { font-family: var(--font-heading); font-weight: 600; font-size: 11px;
  letter-spacing: .12em; text-transform: uppercase; color: var(--color-accent-700); display: block; }
.shop-card-name { font-family: var(--font-heading); font-weight: 600; font-size: 22px;
  line-height: 1.1; letter-spacing: -.015em; margin: 6px 0 0; display: block; }
.shop-card-sum { font-size: 12.5px; color: var(--color-neutral-700); line-height: 1.45;
  margin-top: 6px; display: block; }
.shop-card-price { font-family: var(--font-heading); font-weight: 600; font-size: 19px;
  margin-top: 11px; display: block; font-variant-numeric: tabular-nums; }
.shop-card-vat { font-size: 11px; color: var(--color-neutral-600); display: block; margin-top: 2px; }
.shop-card-tag { display: block; margin-top: 12px; }

.shop-pager { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 34px; }
.shop-pager-at { font-size: 12.5px; color: var(--color-neutral-700); }
.shop-empty { font-size: 15px; color: var(--color-neutral-700); padding: 30px 0 10px; }
.shop-foot { font-size: 11.5px; color: var(--color-neutral-600); line-height: 1.6;
  margin: 40px 0 0; border-top: 1px solid var(--color-divider); padding-top: 16px; }

/* ── one product ── */
.shop-crumbs { display: flex; gap: 8px; align-items: center; font-size: 12.5px;
  color: var(--color-neutral-600); margin-bottom: 18px; }
.shop-detail { display: grid; grid-template-columns: 1.05fr .95fr; gap: 44px; align-items: start; }
/* A grid child defaults to min-width:auto, so it refuses to shrink below its
   own content — one long word or a wide image and the column pushes the grid
   wider than the screen. These three are the columns that hold exactly that. */
.shop-gallery, .shop-buy { min-width: 0; }

.shop-shots { padding: 0; position: relative; overflow: hidden; }
/* The strip is the gallery: a scroll-snap row that works as a swipe on a phone
   and a drag or keyboard anywhere else, with no script at all. */
.shop-strip { display: grid; grid-auto-flow: column; grid-auto-columns: 100%;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  -webkit-overflow-scrolling: touch; }
.shop-strip::-webkit-scrollbar { display: none; }
.shop-slide { scroll-snap-align: center; margin: 0; }
.shop-slide-img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; display: block; }
.shop-slide--none { aspect-ratio: 1; display: grid; place-items: center;
  background: var(--color-neutral-200); color: var(--color-neutral-600); font-size: 13px; }
.shop-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  padding: 6px 12px; font-size: 20px; line-height: 1; }
.shop-arrow--prev { left: 10px; }
.shop-arrow--next { right: 10px; }
.shop-dots { display: flex; gap: 6px; justify-content: center; margin-top: 12px; }
.shop-dot { width: 7px; height: 7px; background: var(--color-neutral-400); display: block; }
.shop-dot.is-on { background: var(--color-accent); }
.shop-thumbs { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.shop-thumb { display: block; line-height: 0; border: 1px solid var(--color-divider); }
.shop-thumb img { width: 72px; height: 72px; object-fit: cover; display: block; }
.shop-thumb:hover { border-color: var(--color-accent); }

.shop-title { font-size: 40px; text-transform: uppercase; letter-spacing: -.015em; margin: 6px 0 10px; }
.shop-price { font-family: var(--font-heading); font-weight: 600; font-size: 34px; line-height: 1;
  color: var(--color-accent-700); font-variant-numeric: tabular-nums; }
.shop-vat { font-size: 11.5px; color: var(--color-neutral-600); margin: 6px 0 0; }
.shop-summary { font-size: 14.5px; line-height: 1.6; margin: 16px 0 0; }

.shop-options { margin-top: 22px; }
.shop-sizes { border: 0; padding: 0; margin: 0 0 18px; }
.shop-size { display: grid; grid-template-columns: auto auto 1fr; gap: 9px; align-items: center;
  padding: 7px 0; font-size: 14px; }
.shop-size.is-gone { color: var(--color-neutral-500); }
.shop-size-label { font-family: var(--font-heading); font-weight: 600; }
.shop-size-state { font-size: 11.5px; color: var(--color-neutral-600); }
.shop-add { padding: 12px 24px; font-size: 15px; }
.shop-note { font-size: 11.5px; color: var(--color-neutral-600); margin: 9px 0 0; }
.shop-facts { margin: 24px 0 0; }

.shop-share { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--color-divider); }
.shop-share-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.shop-share-url { font-size: 11px; color: var(--color-neutral-600); margin: 10px 0 0;
  word-break: break-all; }

.shop-prose { max-width: 640px; margin-top: 46px; font-size: 14.5px; line-height: 1.65; }
.shop-h2 { font-size: 20px; text-transform: uppercase; letter-spacing: .02em; margin: 26px 0 8px; }
.shop-back { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 40px; }

@media (max-width: 980px) {
  .shop-grid { grid-template-columns: repeat(2, 1fr); }
  .shop-detail { grid-template-columns: 1fr; gap: 30px; }
}
@media (max-width: 640px) {
  .shop-grid { grid-template-columns: 1fr; gap: 20px; }
  .shop-filter { gap: 12px; }
  .shop-filter-field { flex: 1; min-width: 140px; }
  .shop-filter-field .input { min-width: 0; width: 100%; }
  .shop-title { font-size: 30px; }
  .shop-price { font-size: 28px; }
}

/* ─────────────────────  store: basket, checkout, order  ──────────────── */
.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; }
.field-optional { font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--color-neutral-500); }
.input-short { max-width: 130px; }

.basket-sec { max-width: 820px; }
.basket-lines { margin: 22px 0 24px; }
.basket-line { background: var(--color-bg); display: grid;
  grid-template-columns: 64px 1fr auto 90px auto; gap: 14px; align-items: center; padding: 12px 14px; }
.basket-line.is-gone { opacity: .6; }
.basket-shot img, .basket-shot--none { width: 64px; height: 64px; object-fit: cover; display: block;
  border: 1px solid var(--color-divider); }
.basket-shot--none { background: var(--color-neutral-200); }
.basket-what { min-width: 0; }
.basket-name { text-decoration: none; color: inherit; display: block; }
.basket-name:hover { color: var(--color-accent-700); }
.basket-clamp { font-size: 11.5px; color: var(--color-accent-800); margin-top: 4px; }
.basket-qty .input-sm { width: 66px; }
.basket-money { text-align: right; font-variant-numeric: tabular-nums; font-size: 14px; }
.basket-sum { padding: 6px 4px; }
.basket-total .kv-key, .basket-total span { font-family: var(--font-heading); font-weight: 600;
  font-size: 16px; }
.basket-note { font-size: 11.5px; color: var(--color-neutral-600); line-height: 1.6; margin: 14px 0 0; }
.basket-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }
.basket-go { padding: 11px 26px; }

.checkout-sec { max-width: 1040px; }
.checkout-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: 26px;
  align-items: start; margin-top: 22px; }
.checkout-form { padding: 24px 22px; }
.checkout-sum { padding: 22px 20px; display: block; position: sticky; top: 90px; }
.checkout-total .kv-key, .checkout-total span { font-family: var(--font-heading);
  font-weight: 600; font-size: 16px; }
.checkout-pay { padding: 13px; font-size: 15px; margin-top: 16px; }
.checkout-note { font-size: 11px; color: var(--color-neutral-600); line-height: 1.55; margin: 12px 0 0; }
.checkout-back { display: inline-block; margin-top: 14px; }
.checkout-challenge { margin-top: 18px; }
/* The honeypot is not display:none — some bots skip hidden fields. It is simply
   somewhere a person will never look. */
.hp-field { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

.order-sec { max-width: 680px; }
.order-rail { display: grid; grid-auto-flow: column; gap: 2px; list-style: none;
  padding: 0; margin: 0 0 22px; }
.order-step { font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--color-neutral-600); border-top: 3px solid var(--color-neutral-300);
  padding-top: 8px; }
.order-step.is-done { color: var(--color-accent-800); border-top-color: var(--color-accent); }
.order-lines, .order-address, .order-tracking { margin-bottom: 18px; }
.order-total .kv-key, .order-total span { font-family: var(--font-heading); font-weight: 600;
  font-size: 16px; }
.order-actions { margin-bottom: 14px; }

@media (max-width: 900px) {
  .checkout-grid { grid-template-columns: 1fr; }
  .checkout-sum { position: static; }
}
@media (max-width: 640px) {
  .basket-line { grid-template-columns: 48px 1fr auto; gap: 10px; }
  .basket-shot img, .basket-shot--none { width: 48px; height: 48px; }
  .basket-money { grid-column: 2 / -1; text-align: left; }
  .basket-drop { grid-column: 1 / -1; }
  .order-rail { grid-auto-flow: row; gap: 0; }
  .order-step { border-top: 0; border-left: 3px solid var(--color-neutral-300);
    padding: 6px 0 6px 10px; }
  .order-step.is-done { border-left-color: var(--color-accent); }
}
.nav-count { display: inline-block; min-width: 17px; padding: 0 4px; background: var(--color-accent);
  color: var(--color-bg); font-size: 11px; line-height: 17px; text-align: center; }
.shop-qty { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.shop-qty label { font-size: 11px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--color-neutral-600); }

/* ── admin/store/orders  ── */
.store-order-tabs { margin-bottom: 14px; flex-wrap: wrap; }
.store-date { display: flex; flex-direction: column; gap: 4px; }
.order-rail--admin { max-width: 520px; margin-bottom: 20px; }
.order-admin-grid { display: grid; grid-template-columns: 1.45fr .55fr; gap: 26px; align-items: start; }
.order-admin-side { min-width: 0; }
.order-addr { padding: 16px 16px 12px; }
.order-addr-body { font-style: normal; font-size: 14px; line-height: 1.55; }
.order-admin-actions { display: flex; flex-direction: column; gap: 12px; }
.order-admin-inline { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.order-admin-inline .input-sm { min-width: 0; flex: 1; }
.order-ship { margin-bottom: 12px; }
.order-notes { font-size: 12.5px; line-height: 1.6; white-space: pre-line;
  border-left: 2px solid var(--color-accent-300); padding-left: 10px; margin: 0 0 12px; }

@media (max-width: 900px) {
  .order-admin-grid { grid-template-columns: 1fr; }
}
.gdpr-intro--warn { border-left: 2px solid var(--color-accent); padding-left: 11px; }

/* ── store: delivery, returns, terms ── */
.legal-sec { padding-top: 40px; padding-bottom: 80px; max-width: 720px; font-size: 14.5px;
  line-height: 1.68; }
.legal-h2 { font-size: 20px; text-transform: uppercase; letter-spacing: .02em; margin: 30px 0 8px; }
.legal-list { margin: 0 0 16px; padding-left: 20px; }
.legal-list li { margin-bottom: 7px; }
.legal-table { margin: 14px 0 6px; }
.legal-note { font-size: 12.5px; color: var(--color-neutral-700); }
.legal-address { font-style: normal; white-space: pre-line; margin: 0 0 10px; }

/* ── branded stores: who a buyer is buying from ── */
.legal-h3 { font-size: 15px; text-transform: uppercase; letter-spacing: .03em; margin: 20px 0 6px; color: var(--color-neutral-700); }
.legal-store { border-top: 1px solid var(--color-divider); padding-top: 12px; margin-top: 12px; }
.legal-store-name { font-family: var(--font-heading); font-weight: 600; font-size: 16px; margin: 0 0 4px; }
.legal-trader p { margin: 0 0 6px; }
.shop-seller-card { padding: 18px 20px; margin: 30px 0 0; font-size: 13.5px; }
.shop-sold-by { font-size: 12.5px; color: var(--color-neutral-700); margin: 8px 0 0; }
.shop-collect { font-size: 12.5px; color: var(--color-neutral-700); margin: 6px 0 0; }
.basket-stores-note { font-size: 13px; color: var(--color-neutral-700); margin: 0 0 18px; }
.basket-store { margin: 0 0 34px; }
.basket-store-h { font-size: 15px; text-transform: uppercase; letter-spacing: .03em; margin: 0 0 10px; }
.checkout-seller { font-size: 12.5px; color: var(--color-neutral-700); margin: -4px 0 12px; }
.legal-code { font-family: ui-monospace, monospace; font-size: 13px; }
.legal-foot { font-size: 12.5px; color: var(--color-neutral-600); margin-top: 36px;
  border-top: 1px solid var(--color-divider); padding-top: 16px; }
.checkout-collect { border: 1px solid var(--color-accent-400); background: var(--color-accent-100);
  padding: 12px 14px; margin-bottom: 18px; }
.checkout-collect-note { font-size: 13px; line-height: 1.6; margin: 0; white-space: pre-line; }
.checkout-contact { margin-bottom: 18px; }

/* A checkout across several stores: each store's goods in their own block, a
   total across them, and a page that walks through paying each in turn. */
.checkout-multi-note { margin: -4px 0 14px; }
.checkout-store + .checkout-store { margin-top: 18px; padding-top: 16px;
  border-top: 1px solid var(--color-divider); }
.checkout-grand { margin-top: 18px; }
.checkout-steps { list-style: none; margin: 0 0 20px; padding: 0;
  border-top: 1px solid var(--color-divider); }
.checkout-step { padding: 14px 0; border-bottom: 1px solid var(--color-divider); }
.checkout-step-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.checkout-step-money { font-family: var(--font-heading); font-weight: 600; font-size: 16px; }
.checkout-step-state { font-size: 13.5px; line-height: 1.55; margin: 6px 0 10px; }
.checkout-step-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.legal-collect { border-left: 2px solid var(--color-accent); padding-left: 12px;
  white-space: pre-line; }

/* ── store: buying advice (#60) ── */
/* The public page: one column of questions, then the safety wording and the
   two or three recommendations, each a card with its makes and models. */
.shop-advice-intro, .shop-advice-form, .shop-advice-result { max-width: 760px; }
.shop-advice-intro { margin-top: 8px; font-size: 14.5px; line-height: 1.6; }
.shop-advice-form { display: grid; gap: 20px; margin-top: 26px; }
.shop-advice-missing { border: 1px solid var(--color-accent-400); background: var(--color-accent-100);
  padding: 11px 14px; font-size: 13px; }
.shop-advice-q { border: 0; border-top: 1px solid var(--color-divider); margin: 0; padding: 16px 0 0;
  min-width: 0; }
.shop-advice-legend { font-family: var(--font-heading); font-weight: 600; font-size: 19px;
  line-height: 1.2; padding: 0; }
.shop-advice-q.is-missing .shop-advice-legend { color: var(--color-accent-700); }
.shop-advice-hint { font-size: 12.5px; color: var(--color-neutral-700); margin: 4px 0 0; }
.shop-advice-options { display: grid; gap: 2px; margin-top: 10px; }
.shop-advice-opt { padding: 8px 0; font-size: 14.5px; }
.shop-advice-go { justify-self: start; padding: 12px 22px; }
.shop-advice-result { margin-top: 34px; scroll-margin-top: 20px; }
.shop-advice-notice { border: 1px solid var(--color-divider); background: var(--color-neutral-100);
  padding: 14px 16px; font-size: 13px; line-height: 1.55; }
.shop-advice-notice p { margin: 0 0 6px; }
.shop-advice-notice p:last-child { margin-bottom: 0; }
.shop-advice-pick { display: block; padding: 20px 20px 16px; margin-top: 18px; }
.shop-advice-pick.is-preferred { border-color: var(--color-accent); }
.shop-advice-rank { display: flex; gap: 8px; }
.shop-advice-name { font-size: 24px; text-transform: uppercase; letter-spacing: -.01em;
  margin: 10px 0 6px; }
.shop-advice-why { font-size: 14.5px; line-height: 1.6; margin: 0 0 8px; }
.shop-advice-because { font-size: 12.5px; color: var(--color-neutral-700); margin: 8px 0 0; }
/* One make and model, every place to buy it (#63): buy here first, then
   retailers. One grid for the whole list, shared down to each seller through
   subgrid, so every seller's button starts in one column and every "Sold by" /
   "Another retailer" line in the next, whichever make and model it is under. */
.shop-advice-models { list-style: none; margin: 14px 0 0; padding: 0;
  border-top: 1px solid var(--color-divider); display: grid;
  grid-template-columns: minmax(8em, 1fr) max-content minmax(0, max-content); column-gap: 16px; }
.shop-advice-model { display: grid; grid-column: 1 / -1; grid-template-columns: subgrid;
  align-items: baseline; row-gap: 8px; padding: 10px 0;
  border-bottom: 1px solid var(--color-divider); }
.shop-advice-model:last-child { border-bottom: 0; }
.shop-advice-model-name { font-family: var(--font-heading); font-weight: 600; font-size: 16px;
  min-width: 0; }
.shop-advice-offers, .shop-advice-model > .shop-advice-model-by { grid-column: 2 / -1; }
.shop-advice-offers { list-style: none; margin: 0; padding: 0; display: grid;
  grid-template-columns: subgrid; row-gap: 6px; }
.shop-advice-model-buy { display: grid; grid-column: 1 / -1; grid-template-columns: subgrid;
  align-items: center; }
.shop-advice-model-buy .btn { justify-self: start; }
/* A retailer's ghost button takes a bordered button's padding here, so its
   name starts where "Buy here" does. */
.shop-advice-model-buy .btn-ghost { padding-inline: calc(var(--space-3) * 1.2); }
/* "Not sold here just now" lines up with the sellers' names: a button's
   padding plus its border. */
.shop-advice-model > .shop-advice-model-by { padding-inline-start: calc(var(--space-3) * 1.2 + 1px); }
.shop-advice-model-by { font-size: 12px; color: var(--color-neutral-600); }
.shop-advice-title, .shop-advice-name, .shop-advice-legend, .shop-advice-model-name,
.shop-advice-model-by, .shop-advice-link-title { overflow-wrap: anywhere; }

/* The way in: a card on the shop's listing, a line on a product's page. */
.shop-advice-link { display: block; max-width: 560px; padding: 14px 16px; margin-bottom: 18px;
  text-decoration: none; color: inherit; }
.shop-advice-link:hover { background: color-mix(in srgb, var(--color-accent) 5%, transparent); }
.shop-advice-link-title { display: block; font-family: var(--font-heading); font-weight: 600;
  font-size: 19px; line-height: 1.2; }
.shop-advice-link-go { display: block; font-size: 12.5px; color: var(--color-neutral-700); margin-top: 4px; }
.shop-advice-nudge { font-size: 13px; color: var(--color-neutral-700); margin: 12px 0 0; }

/* The console: a card per type and per question, each with a grid that
   scrolls rather than squeezes (one points column per type). */
.store-advice-card { margin-top: 16px; }
.store-advice-head { grid-template-columns: 1fr 140px; }
.store-advice-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 14px; }
.store-advice-grid { min-width: 520px; margin-top: 4px; }
.store-advice-grid th, .store-advice-grid td { padding-inline: 5px; }
.store-advice-models { min-width: 760px; }
.store-advice-pt { width: 66px; }
.store-advice-pt-h { font-size: 11px; line-height: 1.25; max-width: 96px; white-space: normal; }

@media (max-width: 640px) {
  .shop-advice { padding-bottom: 92px; }        /* clear of the floating WhatsApp button */
  .store-advice-head { grid-template-columns: 1fr; }
  .shop-advice-go { justify-self: stretch; }
  .shop-advice-pick { padding: 18px 14px 12px; }
  /* The name on its own line, then the sellers in two columns of their own. */
  .shop-advice-models { grid-template-columns: max-content minmax(0, 1fr); }
  .shop-advice-model-name, .shop-advice-offers,
  .shop-advice-model > .shop-advice-model-by { grid-column: 1 / -1; }
}

/* ─────────────────  store: phones, laptops and everything between  ───────── */
/* The booking system's rule: a phone gets a layout, not a squeezed desktop.
   These are the store's equivalents, and the things that only show up on a
   narrow screen — a row that will not wrap, a word that will not break, a
   table squeezed to slivers rather than allowed to scroll. */

/* Rows that must give way rather than push the page wider. */
.shop-crumbs, .shop-pager, .shop-qty, .shop-dots,
.store-band-head, .store-band-foot, .store-photo-actions { flex-wrap: wrap; }

/* A product called "NBBA-TRAILWEIGHT-LONGSLEEVE" has no spaces to break at. */
.shop-card-name, .shop-card-sum, .shop-title, .basket-name, .shop-size-label,
.order-addr-body, .order-notes { overflow-wrap: anywhere; }

/* The store's admin tables run to eight columns. Without a floor the browser
   squeezes them to slivers instead of letting .table-scroll scroll — the same
   problem the attendee list hit when it gained a Payment column. */
.store-table--wide { min-width: 720px; }

@media (max-width: 900px) {
  /* Tablet and small laptop: the gallery and its buying column stack, so the
     thumbnails have the full width and can show more of themselves. */
  .shop-thumbs { gap: 10px; }
  .shop-thumb img { width: 64px; height: 64px; }
}

@media (max-width: 640px) {
  /* iOS zooms the whole page when a field smaller than 16px takes focus, which
     on a nine-field checkout throws the layout about on every tap. Scoped to
     the shop's own forms, so the booking form keeps the size it has always had. */
  .checkout-form .input, .shop-options .input, .shop-filter .input,
  .basket-qty .input, .shop-share .input { font-size: 16px; }

  /* The floating WhatsApp button is fixed to the bottom right. Give the pages
     that end in a primary action enough room underneath that it never sits on
     top of Checkout or Pay. */
  .basket-sec, .checkout-sec, .order-sec { padding-bottom: 92px; }

  /* Gallery controls become touch targets rather than mouse targets. */
  .shop-arrow { padding: 10px 14px; font-size: 24px; }
  .shop-arrow--prev { left: 6px; }
  .shop-arrow--next { right: 6px; }
  .shop-thumbs { gap: 6px; }
  .shop-thumb img { width: 56px; height: 56px; }

  /* The product page: the price and the buying controls come first on a phone,
     because a photograph you can already see does not need scrolling past. */
  .shop-detail { gap: 24px; }
  .shop-price { font-size: 26px; }
  .shop-size { padding: 10px 0; }              /* a 44px row, not a 30px one */
  .shop-add { width: 100%; padding: 14px; }
  .shop-qty { justify-content: space-between; }
  .shop-qty .input-short { max-width: 160px; }

  /* The basket: quantity and price on their own line under the name, so the
     product still gets the width it needs to be read. */
  .basket-line { padding: 12px 10px; }
  .basket-qty .input-sm { width: 84px; }
  .basket-go { width: 100%; text-align: center; }
  .basket-actions .btn { flex: 1; text-align: center; }

  /* Checkout: the summary is already below the form in source order, which is
     the right order on a phone — fill it in, see the total, pay. */
  .checkout-sum { padding: 18px 16px; }
  .checkout-pay { padding: 15px; font-size: 16px; }
  .checkout-step-actions form, .checkout-step-actions .btn { width: 100%; }

  /* Admin: the console is used on a phone at a rideout more than anyone plans
     for, so the action stacks get the full width instead of sitting in a
     column narrowed for a sidebar. */
  .order-admin-inline { width: 100%; }
  .order-admin-inline .input-sm { flex: 1 1 100%; }
  .store-bar-actions .btn { flex: 1 1 auto; text-align: center; }
  .stock-adjust { flex-wrap: wrap; }
  .stock-adjust .input-num { width: 70px; }
  .stock-adjust select.input-sm { width: auto; flex: 1; min-width: 120px; }
}

/* Somebody who has asked for less movement should not be thrown along a photo
   strip; app.js checks the same query before it scrolls. */
@media (prefers-reduced-motion: reduce) {
  .shop-strip { scroll-behavior: auto; }
}
