/* =============================================================================
   Highline Systems — design system
   Built entirely from the Highline Systems Brand Package v1.0 (October 2026).
   Every colour below references a brand token. No component uses a raw hex.
   See docs/02-design-tokens.md for the role mapping and contrast ratios.
   ========================================================================== */

/* -----------------------------------------------------------------------------
   1. Brand palette — the eight colours from the brand package, verbatim.
   -------------------------------------------------------------------------- */
:root {
  --hl-summit-navy: #253d50;
  --hl-night-ridge: #17212b;
  --hl-glacier: #b1d6f2;
  --hl-snowfield: #fcfaf7;
  --hl-ridge-blue: #3f6b8f;
  --hl-granite: #5b6672;
  --hl-mist: #e4ecf2;
  --hl-basalt: #223040;

  /* Supplied in the brand package CSS as the dark-mode muted text value. */
  --hl-haze: #a9b6c2;

  /* Status colours — NOT brand colours. Interface only (form validation and
     status messages). Flagged for approval in docs/02-design-tokens.md.
     Light-mode error is the red already used in the brand guidelines PDF. */
  --hl-status-error-light: #b3261e;
  --hl-status-error-dark: #ffb4ab;
  --hl-status-success-light: #0f6b45;
  --hl-status-success-dark: #7fd1a6;
  --hl-status-warning-light: #7a4e00;
  --hl-status-warning-dark: #e8be6b;
}

/* -----------------------------------------------------------------------------
   2. Semantic tokens — light mode (default)
   -------------------------------------------------------------------------- */
:root {
  --color-bg: var(--hl-snowfield);
  --color-bg-alt: var(--hl-mist);
  --color-surface: var(--hl-mist);
  --color-surface-raised: var(--hl-snowfield);

  --color-text: var(--hl-summit-navy);
  --color-text-muted: var(--hl-granite);

  --color-border: rgba(91, 102, 114, 0.18); /* Granite, fallback */
  --color-border: color-mix(in srgb, var(--hl-granite) 18%, transparent);
  --color-border-strong: var(--hl-granite);

  --color-accent: var(--hl-summit-navy);
  --color-accent-hover: var(--hl-basalt);
  --color-accent-contrast: var(--hl-snowfield);
  --color-highlight: var(--hl-glacier);

  --color-link: var(--hl-ridge-blue);
  --color-link-hover: var(--hl-summit-navy);

  --color-focus: var(--hl-summit-navy);

  --color-inverse-bg: var(--hl-summit-navy);
  --color-inverse-text: var(--hl-snowfield);
  --color-inverse-muted: var(--hl-glacier);

  --color-success: var(--hl-status-success-light);
  --color-warning: var(--hl-status-warning-light);
  --color-error: var(--hl-status-error-light);

  --logo-light-display: block;
  --logo-dark-display: none;

  color-scheme: light;
}

/* -----------------------------------------------------------------------------
   3. Semantic tokens — dark mode (a designed palette, not an inversion)
   Ridge Blue is excluded here: it measures 2.9:1 on Night Ridge. Glacier
   takes the link and accent roles instead.
   -------------------------------------------------------------------------- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --color-bg: var(--hl-night-ridge);
    --color-bg-alt: var(--hl-basalt);
    --color-surface: var(--hl-basalt);
    --color-surface-raised: var(--hl-basalt);

    --color-text: var(--hl-snowfield);
    --color-text-muted: var(--hl-haze);

    --color-border: rgba(169, 182, 194, 0.22); /* Haze, fallback */
    --color-border: color-mix(in srgb, var(--hl-haze) 22%, transparent);
    --color-border-strong: var(--hl-haze);

    --color-accent: var(--hl-glacier);
    --color-accent-hover: #c2dff4; /* Glacier lightened, fallback */
    --color-accent-hover: color-mix(in srgb, var(--hl-glacier) 82%, var(--hl-snowfield));
    --color-accent-contrast: var(--hl-night-ridge);
    --color-highlight: var(--hl-glacier);

    --color-link: var(--hl-glacier);
    --color-link-hover: var(--hl-snowfield);

    --color-focus: var(--hl-glacier);

    --color-inverse-bg: var(--hl-basalt);
    --color-inverse-text: var(--hl-snowfield);
    --color-inverse-muted: var(--hl-glacier);

    --color-success: var(--hl-status-success-dark);
    --color-warning: var(--hl-status-warning-dark);
    --color-error: var(--hl-status-error-dark);

    --logo-light-display: none;
    --logo-dark-display: block;

    color-scheme: dark;
  }
}

:root[data-theme='dark'] {
  --color-bg: var(--hl-night-ridge);
  --color-bg-alt: var(--hl-basalt);
  --color-surface: var(--hl-basalt);
  --color-surface-raised: var(--hl-basalt);

  --color-text: var(--hl-snowfield);
  --color-text-muted: var(--hl-haze);

  --color-border: rgba(169, 182, 194, 0.22); /* Haze, fallback */
  --color-border: color-mix(in srgb, var(--hl-haze) 22%, transparent);
  --color-border-strong: var(--hl-haze);

  --color-accent: var(--hl-glacier);
  --color-accent-hover: #c2dff4; /* Glacier lightened, fallback */
  --color-accent-hover: color-mix(in srgb, var(--hl-glacier) 82%, var(--hl-snowfield));
  --color-accent-contrast: var(--hl-night-ridge);
  --color-highlight: var(--hl-glacier);

  --color-link: var(--hl-glacier);
  --color-link-hover: var(--hl-snowfield);

  --color-focus: var(--hl-glacier);

  --color-inverse-bg: var(--hl-basalt);
  --color-inverse-text: var(--hl-snowfield);
  --color-inverse-muted: var(--hl-glacier);

  --color-success: var(--hl-status-success-dark);
  --color-warning: var(--hl-status-warning-dark);
  --color-error: var(--hl-status-error-dark);

  --logo-light-display: none;
  --logo-dark-display: block;

  color-scheme: dark;
}

/* -----------------------------------------------------------------------------
   4. Type, space, motion and layout tokens
   -------------------------------------------------------------------------- */
:root {
  --font-sans: 'Montserrat', 'Montserrat Fallback', system-ui, -apple-system,
    'Segoe UI', sans-serif;

  /* Fluid scale, 320px → 1280px viewport */
  --step--2: clamp(0.76rem, 0.74rem + 0.08vw, 0.8rem);
  --step--1: clamp(0.875rem, 0.85rem + 0.12vw, 0.938rem);
  --step-0: clamp(1rem, 0.96rem + 0.2vw, 1.125rem);
  --step-1: clamp(1.125rem, 1.07rem + 0.28vw, 1.313rem);
  --step-2: clamp(1.33rem, 1.23rem + 0.5vw, 1.625rem);
  --step-3: clamp(1.602rem, 1.42rem + 0.9vw, 2.125rem);
  --step-4: clamp(1.9rem, 1.6rem + 1.5vw, 2.75rem);
  --step-5: clamp(2.25rem, 1.8rem + 2.25vw, 3.5rem);

  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;

  --leading-tight: 1.15;
  --leading-snug: 1.3;
  --leading-normal: 1.65;

  --tracking-label: 0.12em;
  --tracking-tight: -0.015em;

  --space-3xs: 0.25rem;
  --space-2xs: 0.5rem;
  --space-xs: 0.75rem;
  --space-s: 1rem;
  --space-m: 1.5rem;
  --space-l: 2rem;
  --space-xl: 3rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;

  --section-y: clamp(3rem, 1.5rem + 7vw, 6rem);

  --radius-s: 2px;
  --radius-m: 4px;
  --radius-l: 6px;

  --measure: 68ch;
  --container: 75rem;
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2.5rem);

  --ease: cubic-bezier(0.2, 0, 0, 1);
  --dur-fast: 150ms;
  --dur-base: 200ms;
  --dur-slow: 250ms;

  --header-h: 4.25rem;
}

/* -----------------------------------------------------------------------------
   5. Font face — self-hosted, subset, variable (wght 400–700)
   -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Montserrat';
  src: url('/assets/fonts/montserrat-subset.woff2') format('woff2-variations');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* Metric-matched fallback so swapping the webfont in causes no layout shift. */
@font-face {
  font-family: 'Montserrat Fallback';
  src: local('Arial'), local('Helvetica'), local('Liberation Sans');
  size-adjust: 112.5%;
  ascent-override: 86%;
  descent-override: 22.3%;
  line-gap-override: 0%;
}

/* -----------------------------------------------------------------------------
   6. Reset and base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* The `hidden` attribute must win. Any author `display` rule — and this sheet
   sets several, on .btn, .field__error and more — otherwise overrides the
   user-agent default and leaves hidden elements on screen. */
[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* Keeps anchored and focused targets clear of the sticky header (WCAG 2.4.11) */
  scroll-padding-top: calc(var(--header-h) + var(--space-m));
}

body {
  margin: 0;
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  font-weight: var(--weight-regular);
  line-height: var(--leading-normal);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color var(--dur-fast) var(--ease),
    color var(--dur-fast) var(--ease);
}

h1,
h2,
h3,
h4 {
  margin: 0 0 var(--space-s);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  text-wrap: balance;
}

h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }

p,
ul,
ol,
dl,
table {
  margin: 0 0 var(--space-m);
}

p {
  max-width: var(--measure);
  text-wrap: pretty;
}

/* The measure belongs to running prose. Structural lists are layout
   containers and must be free to use their column. */
.prose li,
.checklist > li,
.steps > li {
  max-width: var(--measure);
  text-wrap: pretty;
}

ul,
ol {
  padding-left: 1.25em;
}

li + li {
  margin-top: var(--space-2xs);
}

a {
  color: var(--color-link);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
  transition: color var(--dur-fast) var(--ease),
    text-decoration-color var(--dur-fast) var(--ease);
}

a:hover {
  color: var(--color-link-hover);
}

strong,
b {
  font-weight: var(--weight-semibold);
}

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

hr {
  height: 1px;
  border: 0;
  margin: var(--space-xl) 0;
  background-color: var(--color-border);
}

:target {
  scroll-margin-top: calc(var(--header-h) + var(--space-m));
}

/* -----------------------------------------------------------------------------
   7. Focus — a visible 2px ring, never removed
   -------------------------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 2px;
  border-radius: var(--radius-s);
}

/* Keep a ring for browsers that only support :focus */
:focus:not(:focus-visible) {
  outline: none;
}

.skip-link {
  position: absolute;
  left: var(--space-s);
  top: var(--space-s);
  z-index: 100;
  padding: var(--space-2xs) var(--space-s);
  background-color: var(--color-accent);
  color: var(--color-accent-contrast);
  font-weight: var(--weight-medium);
  border-radius: var(--radius-m);
  transform: translateY(-200%);
}

.skip-link:focus {
  transform: translateY(0);
  color: var(--color-accent-contrast);
}

/* -----------------------------------------------------------------------------
   8. Layout — a 12-column grid with generous gutters
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--space-m) var(--gutter);
}

.section {
  padding-block: var(--section-y);
}

.section--alt {
  background-color: var(--color-bg-alt);
}

.section--bordered {
  border-top: 1px solid var(--color-border);
}

.stack > * + * {
  margin-top: var(--space-m);
}

.prose > * + * {
  margin-top: var(--space-m);
}

.prose h2 {
  margin-top: var(--space-xl);
}

.prose h3 {
  margin-top: var(--space-l);
}

.prose > :first-child {
  margin-top: 0;
}

.lede {
  font-size: var(--step-1);
  line-height: var(--leading-snug);
  color: var(--color-text-muted);
  max-width: 54ch;
}

/* The brand's tracked label style. Wayfinding and data only — never a
   decorative kicker above a heading. */
.label {
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
  color: var(--color-text-muted);
}

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

/* Decorative hairline grid motif — pure paint, no layout cost */
.rule-grid {
  position: relative;
}

/* Drawn on the same 12-column grid the content sits on, so the rules land
   behind the column boundaries rather than at arbitrary intervals. */
.rule-grid::before {
  content: '';
  position: absolute;
  inset-block: 0;
  inset-inline: var(--gutter);
  max-width: var(--container);
  margin-inline: auto;
  pointer-events: none;
  background-image: repeating-linear-gradient(
    to right,
    var(--color-border) 0 1px,
    transparent 1px calc(100% / 6)
  );
  opacity: 0.6;
}

@media (max-width: 47.999em) {
  .rule-grid::before {
    background-image: repeating-linear-gradient(
      to right,
      var(--color-border) 0 1px,
      transparent 1px calc(100% / 2)
    );
  }
}

/* -----------------------------------------------------------------------------
   9. Header
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--color-bg);
  border-bottom: 1px solid var(--color-border-strong);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: var(--space-m);
  min-height: var(--header-h);
}

.site-logo {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  padding-block: var(--space-2xs);
  border-radius: var(--radius-m);
}

.site-logo img {
  width: 190px;
  height: auto;
}

.logo--light { display: var(--logo-light-display); }
.logo--dark { display: var(--logo-dark-display); }

.site-nav {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-m);
}

.site-nav__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-xs);
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav__list li + li {
  margin-top: 0;
}

.site-nav__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: var(--space-3xs) var(--space-2xs);
  color: var(--color-text);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

.site-nav__link:hover {
  color: var(--color-link);
  border-bottom-color: var(--color-border-strong);
}

.site-nav__link[aria-current='page'] {
  color: var(--color-text);
  border-bottom-color: var(--color-accent);
}

/* You are on a page beneath this section, but not on the section page itself. */
.site-nav__link.is-section {
  border-bottom-color: var(--color-border-strong);
}

.site-header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-2xs);
  flex: 0 0 auto;
}

.nav-toggle {
  display: none;
}

/* -----------------------------------------------------------------------------
   10. Theme toggle — native radios, so state is announced without ARIA
   -------------------------------------------------------------------------- */
.theme-toggle {
  display: flex;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 2px;
  border: 1px solid var(--color-border-strong);
  border-radius: 999px;
}

.theme-toggle__option {
  position: relative;
  display: inline-flex;
}

.theme-toggle__option input {
  position: absolute;
  inset: 0;
  opacity: 0;
  margin: 0;
  cursor: pointer;
}

.theme-toggle__option label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease),
    color var(--dur-fast) var(--ease);
}

.theme-toggle__option label svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.theme-toggle__option input:hover + label {
  color: var(--color-text);
}

.theme-toggle__option input:checked + label {
  background-color: var(--color-accent);
  color: var(--color-accent-contrast);
}

.theme-toggle__option input:focus-visible + label {
  outline: 2px solid var(--color-focus);
  outline-offset: 2px;
}

/* -----------------------------------------------------------------------------
   11. Buttons
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2xs);
  min-height: 44px;
  padding: var(--space-2xs) var(--space-m);
  border: 1px solid transparent;
  border-radius: var(--radius-m);
  font-family: inherit;
  font-size: var(--step--1);
  font-weight: var(--weight-semibold);
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease),
    color var(--dur-fast) var(--ease),
    transform var(--dur-fast) var(--ease);
}

.btn:active {
  transform: translateY(1px);
}

.btn--primary {
  background-color: var(--color-accent);
  color: var(--color-accent-contrast);
  border-color: var(--color-accent);
}

.btn--primary:hover {
  background-color: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
  color: var(--color-accent-contrast);
}

.btn--secondary {
  background-color: transparent;
  color: var(--color-text);
  border-color: var(--color-border-strong);
}

.btn--secondary:hover {
  background-color: var(--color-surface);
  color: var(--color-text);
  border-color: var(--color-text);
}

.btn[disabled],
.btn[aria-disabled='true'] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* On an inverted band the accent flips so it stays legible */
.band--inverse .btn--primary {
  background-color: var(--color-inverse-text);
  border-color: var(--color-inverse-text);
  color: var(--color-inverse-bg);
}

.band--inverse .btn--primary:hover {
  background-color: var(--color-inverse-muted);
  border-color: var(--color-inverse-muted);
  color: var(--hl-summit-navy);
}

.band--inverse .btn--secondary {
  color: var(--color-inverse-text);
  border-color: var(--color-inverse-muted);
  border-color: color-mix(in srgb, var(--color-inverse-text) 55%, transparent);
}

.band--inverse .btn--secondary:hover {
  background-color: transparent;
  background-color: color-mix(in srgb, var(--color-inverse-text) 12%, transparent);
  color: var(--color-inverse-text);
  border-color: var(--color-inverse-text);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-top: var(--space-m);
}

/* Arrow link */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  min-height: 24px;
  font-weight: var(--weight-medium);
  text-decoration: none;
}

.link-arrow .icon {
  transition: transform var(--dur-fast) var(--ease);
}

.link-arrow:hover {
  text-decoration: underline;
}

.link-arrow:hover .icon {
  transform: translateX(3px);
}

/* -----------------------------------------------------------------------------
   12a. Icons — one authored set, 24px grid, 1.5 stroke, no glyph stand-ins
   -------------------------------------------------------------------------- */
.icon {
  flex: 0 0 auto;
  width: 1.15em;
  height: 1.15em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  overflow: visible;
}

.icon--lg {
  width: 1.5em;
  height: 1.5em;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* -----------------------------------------------------------------------------
   12. Cards
   -------------------------------------------------------------------------- */
.card-grid {
  display: grid;
  gap: var(--gutter);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}

.card-grid > li + li {
  margin-top: 0;
}

.card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: var(--space-m);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-l);
  transition: border-color var(--dur-base) var(--ease),
    transform var(--dur-base) var(--ease);
}

.card:hover {
  border-color: var(--color-border-strong);
  transform: translateY(-2px);
}

.card h3 {
  font-size: var(--step-1);
  margin-bottom: var(--space-2xs);
}

.card h3 a {
  color: var(--color-text);
  text-decoration: none;
}

.card h3 a:hover {
  color: var(--color-link);
  text-decoration: underline;
}

/* Makes the whole card clickable while keeping one real link for a11y */
.card h3 a::after {
  content: '';
  position: absolute;
  inset: 0;
}

.card {
  position: relative;
}

.card p {
  margin-bottom: 0;
  color: var(--color-text-muted);
  font-size: var(--step--1);
}

.card p + p {
  margin-top: var(--space-2xs);
}

.card__meta {
  margin-top: auto;
  padding-top: var(--space-s);
  color: var(--color-link);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
}

.card--plain:hover {
  transform: none;
}

/* -----------------------------------------------------------------------------
   12b. Register — the indexed, rule-separated service list.
   This is the page's structural signature; it replaces a card deck.
   -------------------------------------------------------------------------- */
.register {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--color-text);
}

.register > li {
  margin-top: 0;
  border-bottom: 1px solid var(--color-border);
}

.register__row {
  position: relative;
  display: grid;
  grid-template-columns: 3.5rem minmax(0, 1fr);
  gap: var(--space-2xs) var(--space-s);
  align-items: start;
  padding-block: var(--space-m);
  transition: background-color var(--dur-fast) var(--ease);
}

.register__main {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-2xs);
}

.register__index {
  padding-top: 0.35em;
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  font-variant-numeric: tabular-nums;
  color: var(--color-text-muted);
}

.register__title {
  margin: 0;
  font-size: var(--step-2);
  line-height: var(--leading-snug);
}

.register__title a {
  color: var(--color-text);
  text-decoration: none;
}

.register__title a::after {
  content: '';
  position: absolute;
  inset: 0;
}

.register__row:hover .register__title a {
  color: var(--color-link);
  text-decoration: underline;
}

.register__body {
  grid-column: 2;
  margin: 0;
  max-width: 64ch;
  color: var(--color-text-muted);
}

.register__more {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  color: var(--color-link);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
}

.register__row:hover .register__more .icon {
  transform: translateX(3px);
}

.register__more .icon {
  transition: transform var(--dur-fast) var(--ease);
}

@media (min-width: 62em) {
  .register__row {
    grid-template-columns: 3.5rem minmax(0, 24rem) minmax(0, 1fr);
    gap: var(--space-l);
  }

  .register__body {
    grid-column: 3;
    margin-top: 0.3em;
  }
}

/* -----------------------------------------------------------------------------
   12c. Sector grid — a vertical counterpart to the register, so two adjacent
   list sections do not share one component.
   -------------------------------------------------------------------------- */
.sector-grid {
  display: grid;
  gap: var(--gutter);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}

.sector-grid > li {
  position: relative;
  margin-top: 0;
  padding-top: var(--space-s);
  border-top: 2px solid var(--color-text);
}

.sector-grid__index {
  display: block;
  margin-bottom: var(--space-2xs);
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  font-variant-numeric: tabular-nums;
  color: var(--color-text-muted);
}

.sector-grid h3 {
  font-size: var(--step-1);
  margin-bottom: var(--space-2xs);
}

.sector-grid h3 a {
  display: inline-block;
  min-height: 24px;
  color: var(--color-text);
  text-decoration: none;
}

.sector-grid h3 a::after {
  content: '';
  position: absolute;
  inset: 0;
}

.sector-grid > li:hover h3 a {
  color: var(--color-link);
  text-decoration: underline;
}

.sector-grid p {
  margin-bottom: 0;
  color: var(--color-text-muted);
  font-size: var(--step--1);
}

/* -----------------------------------------------------------------------------
   13. Pillars / numbered steps / feature lists
   -------------------------------------------------------------------------- */
.pillars {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--color-text);
}

.pillars > li {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-3xs) var(--space-l);
  margin-top: 0;
  padding-block: var(--space-s);
  border-bottom: 1px solid var(--color-border);
}

@media (min-width: 48em) {
  .pillars > li {
    grid-template-columns: 12rem minmax(0, 1fr);
    align-items: baseline;
  }
}

.pillars h3 {
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  margin: 0;
  color: var(--color-text-muted);
}

.pillars p {
  margin-bottom: 0;
  max-width: 58ch;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: var(--space-m) 0;
  display: grid;
  gap: var(--space-m);
}

.steps > li {
  position: relative;
  margin-top: 0;
  padding-left: 3.25rem;
  max-width: var(--measure);
}

.steps > li::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0.1em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  padding: 0.15em 0.4em;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-s);
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
}

.steps h3 {
  font-size: var(--step-1);
  margin-bottom: var(--space-3xs);
}

.steps p:last-child {
  margin-bottom: 0;
}

.checklist {
  list-style: none;
  padding: 0;
}

.checklist > li {
  position: relative;
  padding-left: 1.75rem;
  max-width: var(--measure);
}

/* A drawn item mark at the same 1px weight as every other rule on the page. */
.checklist > li::before {
  content: '';
  position: absolute;
  left: 1px;
  top: 0.58em;
  width: 9px;
  height: 9px;
  border: 1px solid var(--color-accent);
  rotate: 45deg;
}

/* -----------------------------------------------------------------------------
   14. Hero and CTA bands
   -------------------------------------------------------------------------- */
.hero {
  padding-block: clamp(2.5rem, 1rem + 7vw, 5.5rem) var(--section-y);
  border-bottom: 1px solid var(--color-border);
  overflow-x: clip;
}

.hero h1 {
  font-size: var(--step-4);
  max-width: 16ch;
}

@media (min-width: 75em) {
  .hero h1 {
    font-size: var(--step-5);
  }
}

.hero .lede {
  font-size: var(--step-1);
  max-width: 56ch;
}

/* Closes the first viewport by stating the whole scope on one measured rule,
   echoing the tracked label specimen in the brand guidelines. */
.hero__scope {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2xs) 0;
  max-width: none;
  margin: var(--space-2xl) 0 0;
  padding-top: var(--space-s);
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

/* Full-bleed: the one edge-to-edge gesture in the opening. */
.hero__scope::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  translate: -50% 0;
  width: 100vw;
  border-top: 1px solid var(--color-border-strong);
}

.hero__scope span {
  padding-right: var(--space-m);
  margin-right: var(--space-m);
  border-right: 1px solid var(--color-border);
}

.hero__scope span:last-child {
  padding-right: 0;
  margin-right: 0;
  border-right: 0;
}

.hero__aside {
  padding: var(--space-m) 0 0;
  border-top: 2px solid var(--color-text);
}

.hero__aside dl {
  margin: 0;
}

.hero__aside dt {
  padding-top: var(--space-xs);
  border-top: 1px solid var(--color-border);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
}

.hero__aside dt:first-of-type {
  border-top: 0;
}

.hero__aside dd {
  margin: 0 0 var(--space-s);
  color: var(--color-text-muted);
  font-size: var(--step--1);
}

.hero__aside p:last-child {
  margin-bottom: 0;
}

.page-hero {
  padding-block: var(--space-l) var(--space-xl);
  border-bottom: 1px solid var(--color-border);
}

.band {
  padding-block: var(--section-y);
}

.band--inverse {
  background-color: var(--color-inverse-bg);
  color: var(--color-inverse-text);
}

.band--inverse h2,
.band--inverse h3 {
  color: var(--color-inverse-text);
}

.band--inverse p {
  color: var(--color-inverse-text);
  color: color-mix(in srgb, var(--color-inverse-text) 86%, transparent);
}

.band--inverse a:not(.btn) {
  color: var(--color-inverse-muted);
}

.band--inverse a:not(.btn):hover {
  color: var(--color-inverse-text);
}


.band--inverse :focus-visible {
  outline-color: var(--color-inverse-muted);
}

/* -----------------------------------------------------------------------------
   15. Breadcrumb
   -------------------------------------------------------------------------- */
.breadcrumb {
  padding-block: var(--space-xs);
  border-bottom: 1px solid var(--color-border);
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3xs) var(--space-2xs);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--step--2);
}

.breadcrumb li {
  margin-top: 0;
  display: flex;
  align-items: center;
  gap: var(--space-2xs);
  color: var(--color-text-muted);
}

.breadcrumb li + li::before {
  content: '/';
  color: var(--color-border-strong);
}

.breadcrumb a {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  color: var(--color-text-muted);
}

.breadcrumb a:hover {
  color: var(--color-link);
}

.breadcrumb [aria-current='page'] {
  color: var(--color-text);
}

/* -----------------------------------------------------------------------------
   16. FAQ accordion — native details/summary
   -------------------------------------------------------------------------- */
.faq {
  border-top: 1px solid var(--color-border);
  max-width: var(--measure);
}

.faq__item {
  border-bottom: 1px solid var(--color-border);
}

.faq__item summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-m);
  min-height: 44px;
  padding-block: var(--space-s);
  font-size: var(--step-0);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
  cursor: pointer;
  list-style: none;
}

.faq__item summary::-webkit-details-marker {
  display: none;
}

.faq__item summary .icon {
  margin-top: 0.25em;
  color: var(--color-text-muted);
  transition: transform var(--dur-base) var(--ease);
}

.faq__item[open] summary .icon {
  transform: rotate(180deg);
}

.faq__item summary:hover {
  color: var(--color-link);
}

.faq__answer {
  padding-bottom: var(--space-s);
}

.faq__answer > :last-child {
  margin-bottom: 0;
}

/* -----------------------------------------------------------------------------
   17. Forms
   -------------------------------------------------------------------------- */
.form {
  max-width: 34rem;
}

.field {
  margin-bottom: var(--space-m);
}

.field > label {
  display: block;
  margin-bottom: var(--space-3xs);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
}

.field__hint {
  display: block;
  margin-bottom: var(--space-2xs);
  font-size: var(--step--1);
  color: var(--color-text-muted);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 44px;
  padding: var(--space-2xs) var(--space-xs);
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: inherit;
  font-size: var(--step-0);
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-m);
  transition: border-color var(--dur-fast) var(--ease);
}

.field textarea {
  min-height: 7rem;
  resize: vertical;
  line-height: var(--leading-normal);
}

.select-wrap {
  position: relative;
  display: block;
}

.select-wrap .icon {
  position: absolute;
  right: var(--space-xs);
  top: 50%;
  translate: 0 -50%;
  pointer-events: none;
  color: var(--color-text-muted);
}

.field select {
  appearance: none;
  padding-right: 2.75rem;
}

.field input:hover,
.field select:hover,
.field textarea:hover {
  border-color: var(--color-text);
}

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 1px;
  border-color: var(--color-focus);
}

.field--error input,
.field--error select,
.field--error textarea {
  border-color: var(--color-error);
  border-width: 2px;
}

.field__error {
  display: flex;
  align-items: flex-start;
  gap: 0.4em;
  margin-top: var(--space-3xs);
  color: var(--color-error);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
}

/* The icon carries the meaning too, so the error never relies on colour alone */
.field__error .icon {
  margin-top: 0.22em;
}

.field--checkbox {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-xs);
  align-items: start;
}

.field--checkbox input {
  width: 24px;
  height: 24px;
  min-height: 24px;
  margin: 0;
  accent-color: var(--color-accent);
}

.field--checkbox label {
  margin: 0;
  font-size: var(--step--1);
  font-weight: var(--weight-regular);
  line-height: var(--leading-normal);
}

.form__status {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-2xs) var(--space-s);
  margin-bottom: var(--space-m);
  padding: var(--space-s) 0;
  border-top: 2px solid var(--color-border-strong);
  border-bottom: 1px solid var(--color-border);
}

.form__status:empty {
  display: none;
}

.form__status h2,
.form__status h3 {
  margin: 0;
  font-size: var(--step-0);
}

.form__status .icon {
  margin-top: 0.15em;
}

.form__status--error {
  border-top-color: var(--color-error);
}

.form__status--error .icon {
  color: var(--color-error);
}

.form__status--success {
  border-top-color: var(--color-success);
}

.form__status--success .icon {
  color: var(--color-success);
}

.form__status > :last-child {
  margin-bottom: 0;
}

/* -----------------------------------------------------------------------------
   18. Diagrams, tables, notes
   -------------------------------------------------------------------------- */
.diagram {
  margin: var(--space-l) 0;
  padding: var(--space-m) 0;
  border-top: 1px solid var(--color-border-strong);
  border-bottom: 1px solid var(--color-border);
  background-color: transparent;
}

.diagram svg {
  width: 100%;
  height: auto;
  color: var(--color-text);
}

.diagram figcaption {
  margin-top: var(--space-s);
  font-size: var(--step--1);
  color: var(--color-text-muted);
}

.table-wrap {
  overflow-x: auto;
  margin-bottom: var(--space-m);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--step--1);
}

caption {
  text-align: left;
  padding-bottom: var(--space-2xs);
  color: var(--color-text-muted);
  font-size: var(--step--1);
}

th,
td {
  padding: var(--space-2xs) var(--space-xs);
  text-align: left;
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
}

th {
  font-weight: var(--weight-semibold);
  border-bottom-color: var(--color-border-strong);
}

.note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-xs) var(--space-s);
  padding: var(--space-s) 0;
  border-top: 1px solid var(--color-border-strong);
  border-bottom: 1px solid var(--color-border);
  font-size: var(--step--1);
}

.note .icon {
  margin-top: 0.15em;
  color: var(--color-text-muted);
}

.note > :last-child {
  margin-bottom: 0;
}

.note--placeholder .icon {
  color: var(--color-warning);
}

.placeholder {
  padding: 0.1em 0.35em;
  border: 1px dashed var(--color-border-strong);
  border-radius: var(--radius-s);
  font-size: 0.95em;
  color: var(--color-text-muted);
}

/* -----------------------------------------------------------------------------
   19. Insights list
   -------------------------------------------------------------------------- */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-top: 1px solid var(--color-border);
}

.post-list > li {
  margin-top: 0;
  padding-block: var(--space-m);
  border-bottom: 1px solid var(--color-border);
}

.post-list h3 {
  font-size: var(--step-1);
  margin-bottom: var(--space-3xs);
}

.post-list h3 a {
  color: var(--color-text);
  text-decoration: none;
}

.post-list h3 a:hover {
  color: var(--color-link);
  text-decoration: underline;
}

.post-list__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2xs);
  margin-bottom: var(--space-2xs);
  font-size: var(--step--2);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.post-list p {
  margin-bottom: 0;
  color: var(--color-text-muted);
}

/* -----------------------------------------------------------------------------
   20. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  padding-block: var(--space-2xl) var(--space-xl);
  background-color: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  font-size: var(--step--1);
}

.site-footer h2,
.site-footer h3 {
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space-s);
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.site-footer li + li {
  margin-top: var(--space-3xs);
}

.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  color: var(--color-text);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--color-link);
  text-decoration: underline;
}

.site-footer__brand img {
  width: 180px;
  margin-bottom: var(--space-s);
}

.site-footer__grid {
  display: grid;
  gap: var(--space-xl) var(--gutter);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr));
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-m);
  align-items: center;
  justify-content: space-between;
  margin-top: var(--space-2xl);
  padding-top: var(--space-m);
  border-top: 1px solid var(--color-border);
  color: var(--color-text-muted);
  font-size: var(--step--2);
}

.site-footer__bottom ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-m);
}

.site-footer__bottom li + li {
  margin-top: 0;
}

address {
  font-style: normal;
  color: var(--color-text-muted);
}

/* Contact links sit on their own line rather than inside a sentence, so they
   do not get WCAG 2.5.8's inline exception and must reach 24px themselves. */
address a,
.note a[href^='mailto:'] {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  min-height: 24px;
}

/* -----------------------------------------------------------------------------
   21. Column spans (12-column grid)
   -------------------------------------------------------------------------- */
.col-full { grid-column: 1 / -1; }

@media (min-width: 48em) {
  .col-6 { grid-column: span 6; }
  .col-7 { grid-column: span 7; }
  .col-5 { grid-column: span 5; }
  .col-8 { grid-column: span 8; }
  .col-4 { grid-column: span 4; }
  .col-9 { grid-column: span 9; }
  .col-3 { grid-column: span 3; }
}

@media (max-width: 47.999em) {
  .col-6,
  .col-7,
  .col-5,
  .col-8,
  .col-4,
  .col-9,
  .col-3 {
    grid-column: 1 / -1;
  }
}

/* -----------------------------------------------------------------------------
   22. Mobile navigation
   -------------------------------------------------------------------------- */
@media (max-width: 36em) {
  .hero .btn-row .btn,
  .page-hero .btn-row .btn {
    flex: 1 1 100%;
  }
}

@media (max-width: 61.999em) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2xs);
    width: 44px;
    height: 44px;
    padding: 0;
    background: none;
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-m);
    color: var(--color-text);
    cursor: pointer;
  }

  .nav-toggle svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
  }

  .nav-toggle__close { display: none; }
  .nav-toggle[aria-expanded='true'] .nav-toggle__open { display: none; }
  .nav-toggle[aria-expanded='true'] .nav-toggle__close { display: block; }

  .site-header__inner {
    justify-content: space-between;
  }

  .site-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-m);
    padding: var(--space-s) var(--gutter) var(--space-l);
    background-color: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    max-height: calc(100dvh - var(--header-h));
    overflow-y: auto;
  }

  .site-nav[data-open='true'] {
    display: flex;
  }

  /* The controls move into the panel, so the header row never overflows
     at 320px while the logo stays above its 160px brand minimum. */
  .site-header__actions {
    flex-wrap: wrap;
    gap: var(--space-m);
    justify-content: space-between;
  }

  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .site-nav__link {
    width: 100%;
    min-height: 48px;
    padding-inline: 0;
    font-size: var(--step-0);
    border-bottom: 1px solid var(--color-border);
  }

  .site-nav__link[aria-current='page'] {
    border-bottom-color: var(--color-accent);
  }

}

@media (min-width: 62em) {
  .site-nav {
    display: flex !important;
  }
}

/* -----------------------------------------------------------------------------
   23. Motion preferences and view transitions
   -------------------------------------------------------------------------- */
@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: var(--dur-base);
  animation-timing-function: var(--ease);
}


@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  @view-transition {
    navigation: none;
  }
}

/* -----------------------------------------------------------------------------
   24. Print
   -------------------------------------------------------------------------- */
@media print {
  .site-header,
  .site-footer,
  .theme-toggle,
  .nav-toggle,
  .band--inverse .btn {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
  }

  a::after {
    content: ' (' attr(href) ')';
    font-size: 0.85em;
  }
}

/* -----------------------------------------------------------------------------
   25. Browser surfaces — the parts we did not draw still carry the design
   -------------------------------------------------------------------------- */
::selection {
  background-color: var(--color-highlight);
  color: var(--hl-summit-navy);
}

:root {
  scrollbar-color: var(--color-border-strong) transparent;
  accent-color: var(--color-accent);
}

input,
textarea,
select {
  caret-color: var(--color-accent);
}

::placeholder {
  color: var(--color-text-muted);
  opacity: 1;
}

/* Numbers in data positions line up */
table,
.steps > li::before,
.label,
time {
  font-variant-numeric: tabular-nums;
}

@supports selector(::-webkit-scrollbar) {
  ::-webkit-scrollbar {
    width: 12px;
    height: 12px;
  }

  ::-webkit-scrollbar-track {
    background-color: transparent;
  }

  ::-webkit-scrollbar-thumb {
    background-color: var(--color-border-strong);
    border: 3px solid var(--color-bg);
    border-radius: 999px;
  }

  ::-webkit-scrollbar-thumb:hover {
    background-color: var(--color-text-muted);
  }
}

/* -----------------------------------------------------------------------------
   26. Forced colours
   -------------------------------------------------------------------------- */
@media (forced-colors: active) {
  .btn {
    border: 1px solid ButtonBorder;
  }

  :focus-visible {
    outline: 2px solid Highlight;
  }

  .card,
  .note,
  .diagram {
    border: 1px solid CanvasText;
  }
}

/* -----------------------------------------------------------------------------
   27. The hero demonstration
   A live inventory simulation the visitor can switch. Two states are drawn into
   one SVG and crossfaded, so switching animates opacity only.
   -------------------------------------------------------------------------- */
.hero-demo {
  margin: 0;
  padding-top: var(--space-s);
  border-top: 2px solid var(--color-text);
}

.hero-demo__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xs) var(--space-m);
  margin-bottom: var(--space-m);
}

.hero-demo__bar .label {
  margin: 0;
  color: var(--color-text);
}

/* --- the switch --- */
.hc-switch {
  display: flex;
  margin: 0;
  padding: 2px;
  border: 1px solid var(--color-border-strong);
  border-radius: 999px;
}

.hc-switch__opt {
  position: relative;
  display: inline-flex;
}

.hc-switch input {
  position: absolute;
  inset: 0;
  width: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.hc-switch label {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding-inline: var(--space-s);
  border-radius: 999px;
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: background-color var(--dur-base) var(--ease),
    color var(--dur-base) var(--ease);
}

.hc-switch input:hover + label { color: var(--color-text); }

.hc-switch input:checked + label {
  background-color: var(--color-accent);
  color: var(--color-accent-contrast);
}

.hc-switch input:focus-visible + label {
  outline: 2px solid var(--color-focus);
  outline-offset: 2px;
}

/* --- the chart --- */
.hc-chart { position: relative; }

.hc-svg {
  width: 100%;
  height: auto;
  overflow: visible;
  font-family: var(--font-sans);
}

.hc-axis path {
  fill: none;
  stroke: var(--color-border-strong);
  stroke-width: 1;
}

.hc-axis .hc-grid {
  stroke: var(--color-border);
  stroke-dasharray: 2 5;
}

.hc-axis text,
.hc-labels text {
  fill: var(--color-text-muted);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.hc-state {
  transition: opacity var(--dur-slow) var(--ease);
}

.hc-state .hc-line {
  fill: none;
  stroke: var(--color-text);
  stroke-width: 1.6;
  stroke-linejoin: round;
}

.hc-state .hc-area {
  fill: var(--color-highlight);
  opacity: 0.28;
  stroke: none;
}

.hc-state .hc-rop {
  fill: none;
  stroke: var(--color-link);
  stroke-width: 1.25;
  stroke-dasharray: 6 4;
}

/* A tick under every week that ran out: shape, not colour alone. */
.hc-stockout path {
  fill: none;
  stroke: var(--color-error);
  stroke-width: 2;
  stroke-linecap: round;
}

/* One state at a time. :has() drives it with no JS; the data attribute is the
   same rule for engines without :has(). */
.hero-demo .hc-state--after { opacity: 0; }

.hero-demo:has(#hc-after:checked) .hc-state--before,
.hero-demo[data-policy='after'] .hc-state--before { opacity: 0; }

.hero-demo:has(#hc-after:checked) .hc-state--after,
.hero-demo[data-policy='after'] .hc-state--after { opacity: 1; }

/* --- the figures --- */
.hc-readout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 9rem), 1fr));
  gap: var(--space-s) var(--space-m);
  margin: var(--space-m) 0 var(--space-s);
  padding-top: var(--space-s);
  border-top: 1px solid var(--color-border);
}

.hc-fig dt {
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.hc-fig dd {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 0.15em;
}

.hc-num {
  font-size: var(--step-3);
  font-weight: var(--weight-semibold);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
  letter-spacing: var(--tracking-tight);
}

.hc-unit {
  font-size: var(--step--1);
  color: var(--color-text-muted);
}

.hero-demo figcaption {
  max-width: 68ch;
  font-size: var(--step--2);
  line-height: 1.6;
  color: var(--color-text-muted);
}

.hero-demo figcaption strong { color: var(--color-text); }

/* --- the one authored entrance: the line draws itself, once --- */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-demo[data-draw='pending'] .hc-state .hc-line {
    stroke-dasharray: var(--hc-len, 3000);
    stroke-dashoffset: var(--hc-len, 3000);
  }

  .js .hero-demo[data-draw='pending'] .hc-state .hc-area,
  .js .hero-demo[data-draw='pending'] .hc-state .hc-rop,
  .js .hero-demo[data-draw='pending'] .hc-stockout {
    opacity: 0;
  }

  .js .hero-demo[data-draw='run'] .hc-state .hc-line {
    stroke-dasharray: var(--hc-len, 3000);
    animation: hc-draw 1100ms var(--ease) forwards;
  }

  .js .hero-demo[data-draw='run'] .hc-state .hc-area {
    animation: hc-fade 500ms var(--ease) 700ms backwards;
  }

  .js .hero-demo[data-draw='run'] .hc-state .hc-rop {
    animation: hc-fade 400ms var(--ease) 500ms backwards;
  }

  .js .hero-demo[data-draw='run'] .hc-stockout {
    animation: hc-fade 400ms var(--ease) 1000ms backwards;
  }
}

@keyframes hc-draw {
  to { stroke-dashoffset: 0; }
}

@keyframes hc-fade {
  from { opacity: 0; }
}

@media (max-width: 47.999em) {
  .hero-demo__bar { gap: var(--space-2xs); }
  .hc-switch { width: 100%; }
  .hc-switch__opt { flex: 1 1 0; }
  .hc-switch label { width: 100%; justify-content: center; min-height: 40px; }
  .hc-num { font-size: var(--step-2); }
}

/* -----------------------------------------------------------------------------
   28. Entrances
   Three authored moments, not one effect on every section. Each is additive:
   without JavaScript, or under reduced motion, every element is simply there.
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  /* A flow diagram draws its flow. */
  .js .diagram[data-draw='pending'] svg g > path {
    stroke-dasharray: var(--d-len, 1200);
    stroke-dashoffset: var(--d-len, 1200);
  }

  .js .diagram[data-draw='pending'] svg rect,
  .js .diagram[data-draw='pending'] svg text {
    opacity: 0;
  }

  .js .diagram[data-draw='run'] svg g > path {
    stroke-dasharray: var(--d-len, 1200);
    animation: hc-draw 900ms var(--ease) forwards;
  }

  .js .diagram[data-draw='run'] svg rect {
    animation: hc-fade 400ms var(--ease) 350ms backwards;
  }

  .js .diagram[data-draw='run'] svg text {
    animation: hc-fade 400ms var(--ease) 550ms backwards;
  }

  /* The register arrives in order, one row after another. */
  .js .register[data-stagger='pending'] > li,
  .js .sector-grid[data-stagger='pending'] > li {
    opacity: 0;
    transform: translateY(10px);
  }

  .js .register[data-stagger='run'] > li,
  .js .sector-grid[data-stagger='run'] > li {
    animation: row-in 420ms var(--ease) backwards;
    animation-delay: calc(var(--row-i, 0) * 55ms);
  }
}

@keyframes row-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

/* -----------------------------------------------------------------------------
   29. The opening
   One idea, at the scale it deserves, with nothing competing for attention.
   The demonstration that follows is the proof, so the words stay few.
   -------------------------------------------------------------------------- */
.hero--open {
  /* Tight enough that the demonstration's top edge sits in the first
     viewport: the headline states the problem, the chart is visibly the
     answer, and the page invites the scroll rather than hiding it. */
  padding-block: clamp(2rem, 0.5rem + 4.5vw, 4rem) clamp(1.25rem, 0.5rem + 1.5vw, 2rem);
  border-bottom: 0;
  overflow-x: clip;
}

.hero--open h1 {
  max-width: 18ch;
  margin-bottom: var(--space-s);
  font-size: clamp(2.4rem, 1.1rem + 5.6vw, 5rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

/* The second line is the consequence, not the headline. */
.hero--open h1 br + * ,
.hero--open h1 {
  color: var(--color-text);
}

.hero--open .lede {
  max-width: 46ch;
  font-size: var(--step-1);
  line-height: 1.45;
}

.hero--open .btn-row {
  margin-top: var(--space-m);
}

/* The demonstration gets the width and the quiet around it. */
.section--demo {
  padding-block: 0 var(--section-y);
}

.section--demo .hero-demo {
  border-top: 0;
  padding-top: 0;
}

.section--demo .hc-chart {
  margin-top: var(--space-xs);
}

.section--demo .hc-svg {
  max-height: min(46vh, 420px);
}

@media (min-width: 62em) {
  .section--demo .hero-demo__bar {
    margin-bottom: var(--space-s);
  }

  .section--demo .hc-readout {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-width: 52rem;
  }
}

/* Sections breathe further apart now that there are fewer of them. */
.page-page .section {
  padding-block: clamp(3.5rem, 2rem + 8vw, 7rem);
}

/* -----------------------------------------------------------------------------
   30. Booking
   The link is the control; the embed is an option. Reserve the frame's height
   so revealing it cannot shift anything below.
   -------------------------------------------------------------------------- */
.booking {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-xs);
  margin-bottom: var(--space-l);
}

.booking .btn {
  width: 100%;
}

.booking__embed {
  width: 100%;
  margin-top: var(--space-2xs);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-m);
  overflow: hidden;
  background-color: var(--color-surface);
}

.booking__embed iframe {
  display: block;
  width: 100%;
  min-height: 680px;
  border: 0;
}

.booking__note {
  margin: 0;
  font-size: var(--step--2);
  line-height: 1.55;
  color: var(--color-text-muted);
}

/* No JavaScript: the toggle cannot work, so it is not offered. */
html:not(.js) [data-booking-embed] {
  display: none;
}

/* The spam honeypot. display:none keeps it out of the accessibility tree as
   well as off the screen, so no assistive technology ever announces it. */
.form__bot {
  display: none;
}

/* -----------------------------------------------------------------------------
   31. The enquiry questionnaire
   One question at a time, sliding like a deck. Without JavaScript every
   fieldset is simply visible and the form is an ordinary one.
   -------------------------------------------------------------------------- */
.enquiry .step {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.step__legend {
  display: block;
  width: 100%;
  padding: 0;
  margin-bottom: var(--space-s);
}

.step__count {
  display: block;
  margin-bottom: var(--space-3xs);
  font-size: var(--step--2);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
  color: var(--color-text-muted);
}

.step__title {
  display: block;
  font-size: var(--step-2);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-tight);
}

.step__title:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 4px;
}

.step__hint {
  margin-top: calc(var(--space-s) * -0.5);
  margin-bottom: var(--space-m);
  color: var(--color-text-muted);
  font-size: var(--step--1);
}

/* Without the script every step shows, separated by a rule. */
.enquiry:not(.is-stepped) .step + .step {
  margin-top: var(--space-xl);
  padding-top: var(--space-l);
  border-top: 1px solid var(--color-border);
}

.enquiry:not(.is-stepped) .step__count {
  display: none;
}

/* --- stepped --- */
.enquiry.is-stepped .enquiry__track {
  /* Reserve the tallest step's height so advancing never shifts the page. */
  min-height: 19rem;
}

.enquiry.is-stepped .step[hidden] {
  display: none;
}

.enquiry__nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-top: var(--space-l);
  padding-top: var(--space-m);
  border-top: 1px solid var(--color-border);
}

.enquiry__nav [data-next],
.enquiry__nav [data-submit] {
  margin-left: auto;
}

/* --- progress --- */
.progress {
  display: flex;
  gap: var(--space-3xs);
  margin: 0 0 var(--space-m);
  padding: 0;
  list-style: none;
}

.progress__dot {
  flex: 1 1 0;
  height: 3px;
  margin: 0;
  border-radius: 2px;
  background-color: var(--color-border);
  transition: background-color var(--dur-base) var(--ease);
}

.progress__dot.is-done {
  background-color: var(--color-border-strong);
}

.progress__dot.is-current {
  background-color: var(--color-accent);
}

/* --- the one piece of motion: the question arriving --- */
@media (prefers-reduced-motion: no-preference) {
  .enquiry.is-stepped .step.is-current {
    animation: step-in 260ms var(--ease);
  }
}

@keyframes step-in {
  from {
    opacity: 0;
    transform: translateX(14px);
  }
}

@media (max-width: 36em) {
  .enquiry__nav .btn {
    flex: 1 1 100%;
  }

  .enquiry__nav [data-next],
  .enquiry__nav [data-submit] {
    margin-left: 0;
    order: -1;
  }
}
