/* BoroughLets marketing site.
 *
 * One stylesheet, no framework, no build step. The content security policy on the
 * distribution forbids unsafe-inline, so every rule lives here: no <style> blocks
 * and no style="" attributes anywhere in the HTML.
 *
 * The palette is the product's own design tokens (frontend/src/styles/variables.css)
 * for light surfaces, and the demo film's gradient (compose.py) for dark ones. They
 * are one system: the film's ground is the app's primary blue pushed darker.
 *
 * Three contrast rules, measured rather than assumed:
 *   the brand green #5CB85C is 2.48:1 on white, so it is decoration on light
 *     surfaces and never text, and never a button fill with white text;
 *   the app's muted grey #7a7a8a is 4.22:1 on white, which fails AA for body text,
 *     so this site uses #5f5f70 (6.25:1);
 *   the app's focus ring colour is 1.12:1, so focus here is a solid 3px ring.
 */

/* ---------------------------------------------------------------- tokens --- */
:root {
  --c-bg: #ffffff;
  --c-bg-alt: #f8f8fa;
  --c-bg-tint: #E8F4F8;
  --c-border: #e2e2e8;
  --c-border-strong: #8a8a99;

  --c-ink-900: #0B2238;
  --c-ink-800: #081C2E;
  --c-ink-700: #134766;
  --c-ink-600: #1D5A86;

  --c-text: #1a1a2e;
  --c-text-2: #4a4a5a;
  --c-text-3: #5f5f70;
  --c-text-dk: #ffffff;
  --c-text-dk-2: #D3E6F5;

  --c-primary: #1B5E8A;
  --c-primary-dk: #134766;
  --c-accent: #5CB85C;
  --c-accent-film-pale: #a9dc7a; /* small text on the dark band: 4.6:1 at its lightest */
  --c-accent-film: #7CBE42;
  --c-accent-text: #0d7a3e;

  --grad-ground: linear-gradient(135deg, #0B2238 0%, #1D5A86 100%);

  --r-sm: 2px;
  --r-md: 4px;
  --r-lg: 6px;
  --r-media: 10px;

  /* One easing curve for everything that moves, so the whole page feels like one
   * object. A long tail (the 1 in the third slot) reads as settling rather than
   * stopping, which is what makes restrained motion feel expensive. */
  --ease: cubic-bezier(.22, .61, .36, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --dur-rise: 620ms;
  --dur-hover: 240ms;

  --sh-1: 0 1px 2px rgba(26, 26, 46, .04);
  --sh-2: 0 2px 8px rgba(26, 26, 46, .06);
  --sh-media: 0 1px 2px rgba(26, 26, 46, .04), 0 10px 28px rgba(26, 26, 46, .08), 0 28px 56px rgba(26, 26, 46, .05);
  --sh-media-dark: 0 24px 60px rgba(2, 9, 17, .5);
  --sh-lift: 0 2px 4px rgba(26, 26, 46, .04), 0 14px 32px rgba(26, 26, 46, .10);
  --sh-btn: 0 1px 2px rgba(11, 34, 56, .18), 0 6px 16px rgba(27, 94, 138, .22);

  --w-page: 1160px;
  --w-prose: 680px;
  --header-h: 68px;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

@font-face {
  font-family: 'Inter';
  src: url('/assets/fonts/inter-latin-variable.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+2018-201D, U+2026, U+2192;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

::selection { background: var(--c-primary); color: #fff; }
.band--dark ::selection { background: var(--c-accent-film); color: var(--c-ink-900); }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  margin: 0 0 .5em;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -.02em;
  text-wrap: balance;
}

h1 { font-size: clamp(34px, 5.2vw, 60px); line-height: 1.04; letter-spacing: -.028em; }
h2 { font-size: clamp(26px, 3.4vw, 38px); line-height: 1.14; letter-spacing: -.024em; }
h3 { font-size: 21px; line-height: 1.35; letter-spacing: -.012em; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--c-primary); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--c-primary-dk); text-decoration-thickness: 2px; }

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

ul { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: .4em; }

/* A visible ring on every background the site uses. Never removed. */
:focus-visible {
  outline: 3px solid var(--c-primary);
  outline-offset: 2px;
  border-radius: var(--r-sm);
}
.band--dark :focus-visible, .site-footer :focus-visible,
html.js body.has-dark-hero .site-header:not(.is-scrolled) :focus-visible, .lightbox :focus-visible { outline-color: #ffffff; }

/* The sticky header must never hide what the keyboard just moved to. */
[id] { scroll-margin-top: calc(var(--header-h) + 20px); }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--c-bg);
  color: var(--c-primary);
  padding: 12px 20px;
  z-index: 100;
}
.skip:focus { left: 0; }

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

/* --------------------------------------------------------------- motion --- */
/* Sections rise as they come into view. The [data-reveal] attribute is added by
 * site.js, never written in the HTML, so with JavaScript blocked nothing is ever
 * hidden: there is no state in which the page renders blank. site.js also marks
 * anything already on screen as visible in the same frame it adds the attribute,
 * so the first paint is never a flash of hidden content. */
[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition: opacity var(--dur-rise) var(--ease-out), transform var(--dur-rise) var(--ease-out);
}
[data-reveal].is-visible { opacity: 1; transform: none; }

/* A group's children follow one another in. Delays are by position rather than an
 * inline custom property, because the content security policy forbids style="". */
[data-reveal-group] > * { opacity: 0; }
[data-reveal-group].is-visible > * { animation: rise var(--dur-rise) var(--ease-out) both; }
[data-reveal-group].is-visible > *:nth-child(2) { animation-delay: 70ms; }
[data-reveal-group].is-visible > *:nth-child(3) { animation-delay: 140ms; }
[data-reveal-group].is-visible > *:nth-child(4) { animation-delay: 210ms; }
[data-reveal-group].is-visible > *:nth-child(5) { animation-delay: 280ms; }
[data-reveal-group].is-visible > *:nth-child(6) { animation-delay: 350ms; }

@keyframes rise {
  from { opacity: 0; transform: translate3d(0, 14px, 0); }
  to   { opacity: 1; transform: none; }
}

/* The hero is above the fold, so it plays on load rather than waiting to be
 * scrolled to. Nothing here is ever left hidden by an observer that never fires. */
.hero__intro > * { animation: rise 760ms var(--ease-out) both; }
.hero__intro > *:nth-child(2) { animation-delay: 90ms; }
.hero__intro > *:nth-child(3) { animation-delay: 170ms; }
.hero__intro > *:nth-child(4) { animation-delay: 250ms; }
.hero__intro > *:nth-child(5) { animation-delay: 330ms; }
.hero__media { animation: rise 900ms var(--ease-out) 380ms both; }

main { flex: 1 0 auto; display: flex; flex-direction: column; }
main > section:last-of-type { flex: 1 0 auto; }
main > .hero--page:last-of-type { display: grid; align-content: center; }

/* --------------------------------------------------------------- layout --- */
.wrap { width: 100%; max-width: var(--w-page); margin: 0 auto; padding: 0 24px; }
.wrap--prose { max-width: var(--w-prose); }
.wrap--prose h1, .wrap--prose-left h1 { font-size: clamp(32px, 3.6vw, 48px); }
/* Left aligned prose, for a narrow section sitting among full width ones: centring
 * the column there moves its text 240px right of everything above and below it.
 * The wrapper keeps the page's own width and centring, so the left edge matches its
 * neighbours exactly; only the content inside is held to a readable measure. */
.wrap--prose-left { max-width: var(--w-page); }
.wrap--prose-left > * { max-width: var(--w-prose); }

.band { padding: 96px 0; }
.band--alt { background: var(--c-bg-alt); }
.band--tight { padding: 64px 0; }

.band--dark {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--grad-ground);
  color: var(--c-text-dk-2);
  padding: 112px 0;
}
/* Two wide, very low opacity pools of light. A flat diagonal gradient reads as a
 * filled shape; this reads as a lit room, which is the difference between a dark
 * section looking cheap and looking deliberate. Purely decorative, so it is
 * pointer-transparent and sits behind everything. */
.band--dark::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(760px 420px at 8% -20%, rgba(124, 190, 66, .13), transparent 62%),
    radial-gradient(900px 560px at 96% 116%, rgba(74, 150, 205, .30), transparent 64%);
}
.band--dark h1, .band--dark h2, .band--dark h3 { color: var(--c-text-dk); }
.band--dark a { color: var(--c-text-dk); }

.eyebrow {
  display: block;
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--c-primary);
}
.band--dark .eyebrow { color: var(--c-accent-film); }

.hero .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 22px;
  padding: 7px 15px 7px 12px;
  border: 1px solid rgba(255, 255, 255, .20);
  border-radius: 999px;
  background: rgba(255, 255, 255, .07);
  color: var(--c-text-dk-2);
  letter-spacing: .05em;
}
.hero .eyebrow::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--c-accent-film);
  box-shadow: 0 0 0 0 rgba(124, 190, 66, .55);
  animation: ping 2.8s var(--ease) 3;
}
@keyframes ping {
  0%, 62% { box-shadow: 0 0 0 0 rgba(124, 190, 66, .5); }
  100%    { box-shadow: 0 0 0 9px rgba(124, 190, 66, 0); }
}

.lead { font-size: 20px; line-height: 1.55; color: var(--c-text-2); }
.band--dark .lead { color: var(--c-text-dk-2); }

.small { font-size: 14px; line-height: 1.55; color: var(--c-text-3); }
.band--dark .small { color: var(--c-text-dk-2); }

/* -------------------------------------------------------------- buttons --- */
.btn {
  display: inline-block;
  padding: 14px 24px;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--dur-hover) var(--ease), color var(--dur-hover) var(--ease),
              border-color var(--dur-hover) var(--ease), transform var(--dur-hover) var(--ease),
              box-shadow var(--dur-hover) var(--ease);
}
/* A single pixel of lift. Enough to feel like a response, not enough to bounce. */
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); transition-duration: 60ms; }
.btn--primary { background: var(--c-primary); color: #fff; box-shadow: var(--sh-btn); }
.btn--primary:hover { background: var(--c-primary-dk); color: #fff; text-decoration: none; }
.btn--secondary { background: transparent; border-color: var(--c-primary); color: var(--c-primary); }
.btn--secondary:hover { background: var(--c-bg-tint); text-decoration: none; }

.band--dark .btn--primary { background: #fff; color: var(--c-ink-900); }
.band--dark .btn--primary:hover { background: var(--c-text-dk-2); color: var(--c-ink-900); }
.band--dark .btn--secondary { border-color: rgba(255, 255, 255, .45); color: #fff; }
.band--dark .btn--secondary:hover { background: rgba(255, 255, 255, .1); border-color: #fff; }

.btn-row { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 32px; }

/* --------------------------------------------------------------- header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(1.2) blur(8px);
  border-bottom: 1px solid transparent;
  transition: background-color 320ms var(--ease), border-color 320ms var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--c-border); }

/* Over a dark hero the header rides on the artwork instead of cutting a white slab
 * across the top of it, then resolves to the normal bar as soon as the page moves.
 * The class is set in the HTML rather than by script, so there is no flash: the
 * content security policy rules out an inline script that could run earlier. */
html.js body.has-dark-hero .site-header {
  /* Fixed rather than sticky, so the hero starts at the very top of the viewport and
   * the header rides on the artwork. Sticky keeps its place in the flow, which put a
   * white band above the hero and hid the white half of the wordmark inside it.
   * The hero's own top padding is what leaves room underneath. */
  position: fixed;
  left: 0; right: 0;
}
/* Transparent only while the page is at the top of the hero. This has to be scoped to
 * the state and not merely written before the scrolled rule: with the appearance
 * properties on the selector above, "html.js body.has-dark-hero .site-header" (three
 * classes, two elements) outranked "body.has-dark-hero .site-header.is-scrolled"
 * (three classes, one element), so the bar stayed see through for the whole page and
 * every line of text scrolled visibly underneath the wordmark. Two rules that describe
 * opposite states must never be left to argue about specificity. */
html.js body.has-dark-hero .site-header:not(.is-scrolled) {
  background: transparent;
  backdrop-filter: none;
  border-bottom-color: transparent;
}
/* Two wordmarks ship in the header, one for each ground, and CSS picks: swapping the
 * image source on scroll left the bar blank while the second file loaded. */
.site-header .logo--on-dark { display: none; }
html.js body.has-dark-hero .site-header:not(.is-scrolled) .logo--on-dark { display: block; }
html.js body.has-dark-hero .site-header:not(.is-scrolled) .logo--on-light { display: none; }
html.js body.has-dark-hero .site-nav a { color: rgba(255, 255, 255, .84); }
html.js body.has-dark-hero .site-nav a:not(.btn):hover,
html.js body.has-dark-hero .site-nav a:not(.btn)[aria-current='page'] { color: #fff; }
html.js body.has-dark-hero .site-nav .btn--primary {
  background: rgba(255, 255, 255, .13);
  border-color: rgba(255, 255, 255, .34);
  color: #fff;
  box-shadow: none;
}
html.js body.has-dark-hero .site-nav .btn--primary:hover { background: rgba(255, 255, 255, .22); }
/* Without the script the header sits in the flow, so the page header needs less room. */
html:not(.js) .hero--page, html:not(.js) .band--dark.page-top { padding-top: 72px; }
body.has-dark-hero .site-header.is-scrolled {
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(1.2) blur(8px);
  border-bottom-color: var(--c-border);
}
body.has-dark-hero .site-header.is-scrolled .site-nav a { color: var(--c-text-2); }
body.has-dark-hero .site-header.is-scrolled .site-nav a:not(.btn):hover,
body.has-dark-hero .site-header.is-scrolled .site-nav a:not(.btn)[aria-current='page'] { color: var(--c-primary); }
body.has-dark-hero .site-header.is-scrolled .site-nav .btn--primary {
  background: var(--c-primary);
  border-color: transparent;
  color: #fff;
}

.site-header .wrap { display: flex; align-items: center; gap: 24px; }

.wordmark { display: inline-flex; align-items: center; gap: 10px; }
.wordmark__mark { width: 30px; height: 30px; flex: none; }
.site-footer .wordmark__mark { width: 34px; height: 34px; }

.wordmark {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.02em;
  text-decoration: none;
  color: var(--c-primary);
  white-space: nowrap;
}
.wordmark__text > span { color: var(--c-accent-text); }
.wordmark:hover { text-decoration: none; }

.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: 28px; margin: 0; padding: 0; list-style: none; align-items: center; }
.site-nav li { margin: 0; }
.site-nav a {
  display: inline-block;
  padding: 10px 0;
  font-size: 15px;
  font-weight: 500;
  color: var(--c-text-2);
  text-decoration: none;
}
.site-nav a:not(.btn) { position: relative; }
.site-nav a:not(.btn)::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 4px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 260ms var(--ease);
}
.site-nav a:not(.btn):hover::after,
.site-nav a:not(.btn)[aria-current='page']::after { transform: scaleX(1); }

/* The current page marker must not reach the button: on /demo/ it painted the label
 * primary blue on a primary blue fill, leaving an empty rectangle in the header. */
.site-nav a:not(.btn):hover,
.site-nav a:not(.btn)[aria-current='page'] { color: var(--c-primary); }
.site-nav a:not(.btn)[aria-current='page'] { font-weight: 600; }
.site-nav .btn { padding: 10px 18px; font-size: 15px; color: #fff; }

/* The links live inside a <details> so the mobile menu needs no script. The element
 * ships with `open` set, because a CLOSED details has its content hidden by the
 * browser and no author rule reliably overrides that: display:contents still leaves
 * the links unpainted and out of the tab order in both Chromium and WebKit, which is
 * how this site spent its first day with no desktop navigation at all. So it is open
 * by default and script closes it below 720px. */
.nav-toggle { display: contents; }
.nav-toggle > summary { display: none; }

/* ------------------------------------------------------------ page header --- */
/* Every page opens on the same dark ground as the home page, so moving between them
 * never feels like leaving the site. Same band, same lighting, no media, less height. */
.hero--page { padding: 128px 0 72px; }
.band--dark.page-top { padding-top: 128px; }
@media (max-width: 720px) { .band--dark.page-top { padding-top: calc(var(--header-h) + 34px); } }
.hero--page h1 { max-width: 20ch; }
.hero.hero--page .lead { max-width: 56ch; }


/* ----------------------------------------------------------------- hero --- */
.hero { padding: 120px 0 96px; }
/* From 1100px the product sits beside the promise instead of below it. On a 1440 by
 * 900 screen the map used to begin at 741px, with the right half of the viewport
 * empty; a reader saw four paragraphs before any product. */
@media (min-width: 1100px) {
  .hero > .wrap { display: grid; grid-template-columns: minmax(0, 46fr) minmax(0, 54fr); gap: 48px; align-items: center; }
  /* The page headers have no media, so they stay a single column. This must outrank
   * the grid rule above it: as a plain later rule it was losing, and every inner
   * page's headline was floating into an empty right hand column. */
  .hero.hero--page > .wrap { display: block; }
  .hero__media { margin-top: 0; }
  .hero h1 { font-size: clamp(32px, 3.15vw, 44px); }
  /* The two column hero only; a page header keeps the larger single column lead. */
  .hero:not(.hero--page) > .wrap .lead { font-size: 18px; }
}
.hero .lead { max-width: 44ch; font-size: clamp(18px, 1.6vw, 21px); }
.hero__support { margin-top: 18px; max-width: 48ch; color: var(--c-text-dk-2); opacity: .8; font-size: 16px; }
.hero__intro { max-width: 56ch; }
.hero h1 { margin-bottom: 20px; }

/* A dot grid, barely there. It gives the gradient something to sit on so the eye
 * reads depth rather than a flat fill, and it costs no request. */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .5;
  background-image: radial-gradient(rgba(255, 255, 255, .11) 1px, transparent 1px);
  background-size: 26px 26px;
  mask-image: linear-gradient(to bottom, #000 0%, transparent 62%);
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, transparent 62%);
}

.hero__media { margin-top: 60px; position: relative; }
/* The screenshot is the proof, so it gets the light. */
.hero__media::before {
  content: '';
  position: absolute;
  left: 6%; right: 6%; top: 12%; bottom: -6%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(124, 190, 66, .22), transparent 70%);
  filter: blur(46px);
}

.player {
  position: relative;
  margin: 0;
  border-radius: var(--r-media);
  overflow: hidden;
  box-shadow: var(--sh-media-dark), 0 0 0 1px rgba(255, 255, 255, .10);
  background: var(--c-ink-800);
  aspect-ratio: 16 / 9;
}
.player img, .player video { width: 100%; height: 100%; object-fit: cover; }

.player__play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border: 0;
  background: rgba(11, 34, 56, .28);
  cursor: pointer;
}
.player__play:hover { background: rgba(11, 34, 56, .16); }
.player__play span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 84px; height: 84px;
  border-radius: 50%;
  background: rgba(11, 34, 56, .82);
  border: 2px solid rgba(255, 255, 255, .9);
  transition: transform var(--dur-hover) var(--ease), border-color var(--dur-hover) var(--ease),
              background-color var(--dur-hover) var(--ease);
}
.player__play:hover span { border-color: var(--c-accent-film); transform: scale(1.07); }
.player__play:active span { transform: scale(1); }
.player__play svg { width: 30px; height: 34px; margin-left: 5px; fill: #fff; }

.player__note { margin-top: 16px; }

/* ---------------------------------------------------------------- proof --- */
.proof { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.proof > div { padding: 4px 28px; border-left: 1px solid var(--c-border); }
.proof > div:first-child { padding-left: 0; border-left: 0; }
.proof b {
  display: block;
  font-size: clamp(30px, 3.4vw, 40px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  color: var(--c-primary);
}
.proof span { display: block; margin-top: 10px; font-size: 15px; line-height: 1.45; color: var(--c-text-2); }

/* ----------------------------------------------------------------- acts --- */
/* Find, Engage, Place, Prove, Scale are numbered because they are genuinely a
 * sequence: the order a case actually happens. The number is set from the markup
 * with attr(), so it stays correct if a section is reordered or removed. */
.eyebrow[data-act] { display: flex; align-items: center; gap: 12px; }
.eyebrow[data-act]::before {
  content: attr(data-act);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid currentColor;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  opacity: .85;
}

/* -------------------------------------------------------------- feature --- */
.feature { display: grid; grid-template-columns: 46fr 54fr; gap: 64px; align-items: start; }
.feature + .feature { margin-top: 96px; }
/* Flipping the row swaps which side the screenshot sits on. The track sizes swap with
 * it, or the screenshot would be the narrower column on every other row. */
.feature--flip { grid-template-columns: 54fr 46fr; }
.feature--flip .feature__copy { order: 2; }

.shot { margin: 0; position: relative; }
/* A cool wash under the screenshot, so it sits on the page rather than being pasted
 * onto it. Sized to the image and blurred well past its edges. */
.shot::before {
  content: '';
  position: absolute;
  left: 8%; right: 8%; top: 20%; bottom: 4%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(27, 94, 138, .16), transparent 72%);
  filter: blur(40px);
}
.band--dark .shot::before { background: radial-gradient(closest-side, rgba(124, 190, 66, .18), transparent 72%); }
.shot img {
  width: 100%;
  border: 1px solid var(--c-border);
  border-radius: var(--r-media);
  box-shadow: var(--sh-media);
  background: #fff;
}
.band--dark .shot img { border: 0; box-shadow: var(--sh-media-dark); }
.shot figcaption { margin-top: 12px; font-size: 13px; line-height: 1.5; color: var(--c-text-3); }
.band--dark .shot figcaption { color: var(--c-text-dk-2); }

/* A green rule is the accent on light surfaces, because the green itself is not
 * readable as text there. */
.ruled { padding-left: 20px; border-left: 3px solid var(--c-accent); }
.ruled + .ruled { margin-top: 24px; }
/* A rule-marked list is followed by prose often enough that the gap has to be
 * declared: both of these were measured at 0px, so the text collided. */
.ruled + p, .ruled + .lead { margin-top: 32px; }

/* ---------------------------------------------------------------- stats --- */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 48px; }
.stat { position: relative; }
.stat b {
  display: block;
  font-size: clamp(34px, 4.4vw, 50px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
  color: #fff;
  padding-bottom: 16px;
  border-bottom: 3px solid var(--c-accent-film);
}
.stat span { display: block; margin-top: 14px; font-size: 16px; color: var(--c-text-dk-2); }
.stats + .small { margin-top: 32px; }
/* The same figures on a light band. */
.stats--light .stat b { color: var(--c-text); border-bottom-color: var(--c-accent); }
.stats--light .stat span { color: var(--c-text-2); }
.stats--light { margin-top: 40px; }
.wrap--figures { margin-bottom: 44px; }

/* ------------------------------------------------ what a week is worth --- */
/* Three numbers the reader already knows, one product. Sits under the dashboard on the
 * dark band, so the arithmetic and the report that counts the real thing are together. */
.calc {
  margin-top: 56px;
  padding: 32px;
  border-radius: var(--r-media);
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
}
.calc h3 { margin: 0 0 6px; font-size: 22px; color: #fff; }
.calc > p { margin: 0 0 24px; color: var(--c-text-dk-2); }
.calc__grid { display: grid; grid-template-columns: repeat(3, 1fr) 1.5fr; gap: 24px; align-items: end; }
.calc label { display: block; margin-bottom: 8px; font-size: 14px; line-height: 1.4; color: var(--c-text-dk-2); }
.calc input {
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  font-size: 19px;
  font-variant-numeric: tabular-nums;
  color: #fff;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: var(--r-md);
}
.calc input::-webkit-inner-spin-button, .calc input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.calc input { -moz-appearance: textfield; appearance: textfield; }
.calc input:hover { border-color: rgba(255, 255, 255, .6); }
.calc input:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.calc__out { padding-bottom: 4px; }
.calc__out b {
  display: block;
  font-size: clamp(30px, 3.4vw, 44px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
  color: var(--c-accent-film-pale);
}
.calc__out span { display: block; margin-top: 10px; font-size: 15px; color: var(--c-text-dk-2); }
.calc > .calc__note { margin: 22px 0 0; font-size: 14px; line-height: 1.5; color: var(--c-text-dk-2); }

/* ------------------------------------------------------- one morning --- */
/* Five moments from one case, left to right, each with the screen it happens on. */
.morning { display: grid; grid-template-columns: repeat(5, 1fr); gap: 22px; margin: 44px 0 0; padding: 0; list-style: none; }
.morning li { position: relative; margin: 0; padding-top: 16px; border-top: 3px solid var(--c-border); }
.morning li::before { content: ''; position: absolute; top: -3px; left: 0; width: 44px; height: 3px; background: var(--c-accent); }
.morning__when { display: block; font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--c-accent-text); }
.morning__shot { display: block; width: 100%; margin: 12px 0 14px; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 8px; }
.morning__shot:hover img { box-shadow: var(--sh-lift); transform: translateY(-2px); }
.morning img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  transition: box-shadow var(--dur-rise) var(--ease-out), transform var(--dur-rise) var(--ease-out);
  object-fit: contain;
  object-position: center;
  margin: 0;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 8px;
  box-shadow: var(--sh-2);
}
.morning b { display: block; margin-bottom: 4px; font-size: 17px; line-height: 1.3; letter-spacing: -.01em; }
.morning p { margin: 0; font-size: 15px; line-height: 1.5; color: var(--c-text-2); }
.morning + .small { margin-top: 20px; margin-bottom: 64px; }


.pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--c-bg-tint);
  color: var(--c-ink-700);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .02em;
}
.band--dark .pill { background: rgba(255, 255, 255, .14); color: var(--c-text-dk-2); }

/* --------------------------------------------------------------- panels --- */
.panel {
  position: relative;
  overflow: hidden;
  margin-top: 32px;
  padding: 28px 32px;
  background: var(--c-ink-800);
  color: var(--c-text-dk-2);
  border-left: 3px solid var(--c-accent-film);
  border-radius: var(--r-media);
}
.panel strong { display: block; margin-bottom: 8px; color: #fff; font-size: 19px; font-weight: 600; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin-top: 40px; }
.card {
  position: relative;
  overflow: hidden;
  padding: 26px;
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-1);
}
/* A standing rule along the top, not one that appears on hover: these cards are read,
 * not clicked, and a hover response on them invites a click that does nothing. The
 * green is decoration here, never text, because it fails contrast on white. */
.card::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 3px;
  background: var(--c-accent);
}
.band--dark .card::before { background: var(--c-accent-film); }
.band--dark .card { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .16); box-shadow: none; }
.card h3 { margin-bottom: 8px; font-size: 18px; }
.card p { font-size: 16px; color: var(--c-text-2); }
.band--dark .card p { color: var(--c-text-dk-2); }

/* ------------------------------------------------------------ questions --- */
.qa { border-top: 1px solid var(--c-border); }
.qa details { border-bottom: 1px solid var(--c-border); }
.qa details { transition: background-color var(--dur-hover) var(--ease); }
.qa summary:hover { color: var(--c-primary); }
.qa summary { transition: color var(--dur-hover) var(--ease); }
.qa summary {
  padding: 22px 40px 22px 0;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  position: relative;
  list-style: none;
}
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after {
  content: '';
  position: absolute;
  right: 8px; top: 30px;
  width: 10px; height: 10px;
  border-right: 2px solid var(--c-primary);
  border-bottom: 2px solid var(--c-primary);
  transform: rotate(45deg);
  transition: transform 150ms ease;
}
.qa details[open] summary::after { transform: rotate(-135deg); top: 34px; }
.qa .qa__body { padding: 0 40px 24px 0; color: var(--c-text-2); }
/* Opening animates, closing does not. A close animation needs the panel to outlive
 * the open attribute, which means taking the behaviour off <details> and rebuilding
 * it in script. Not worth losing the native semantics for. */
.qa details[open] .qa__body { animation: qaOpen 300ms var(--ease-out) both; }
@keyframes qaOpen {
  from { opacity: 0; transform: translate3d(0, -8px, 0); }
  to   { opacity: 1; transform: none; }
}

/* ----------------------------------------------------------------- form --- */
.form { margin-top: 32px; }
.form__row { margin-bottom: 20px; }
.form label { display: block; margin-bottom: 6px; font-size: 15px; font-weight: 600; }
.form input, .form textarea, .form select {
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  font-size: 16px;
  color: var(--c-text);
  background: #fff;
  border: 1px solid var(--c-border-strong);
  border-radius: var(--r-md);
  transition: border-color var(--dur-hover) var(--ease), box-shadow var(--dur-hover) var(--ease);
}
.form input:hover, .form textarea:hover, .form select:hover { border-color: var(--c-primary); }
.form input:focus, .form textarea:focus, .form select:focus {
  border-color: var(--c-primary);
  box-shadow: 0 0 0 3px rgba(27, 94, 138, .14);
}
.form textarea { min-height: 140px; resize: vertical; }
.form .hp { position: absolute; left: -9999px; }
.form__hint { margin-top: 6px; font-size: 14px; color: var(--c-text-3); }

.band--dark .form label { color: #fff; }
.band--dark .form__hint { color: var(--c-text-dk-2); }

.form__error {
  margin-top: 6px;
  font-size: 14px;
  font-weight: 600;
  color: #b31b1b;
}
.band--dark .form__error { color: #ffc9c9; }
.form [aria-invalid='true'] { border-color: #b31b1b; border-width: 2px; }

.form__status { margin-top: 20px; padding: 16px 20px; border-radius: var(--r-md); font-weight: 500; }
.form__status:empty { display: none; }
.form__status--ok { background: #e6f5ec; color: #0d5c31; border-left: 3px solid var(--c-accent-text); }
.form__status--bad { background: #fef2f2; color: #8f1616; border-left: 3px solid #b31b1b; }

/* ---------------------------------------------------------------- video --- */
/* Product clips: silent, looping, and only loaded once they are near the viewport
 * (site.js moves data-src into src). The still sits in the frame underneath and
 * carries the alt text and the layout height; the clip is painted over it once it
 * has a frame. So with the clips unpublished, script blocked, or reduced motion
 * asked for, the reader sees the still and never a hole. */
.clip { margin: 0; }
.clip__frame {
  position: relative;
  border: 1px solid var(--c-border);
  border-radius: var(--r-media);
  overflow: hidden;
  background: #fff;
  box-shadow: var(--sh-media);
}
.band--dark .clip__frame { border: 0; box-shadow: var(--sh-media-dark); }
.clip__frame img { display: block; width: 100%; height: auto; }
.clip__video {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 600ms var(--ease);
}
.clip__frame.is-playing .clip__video { opacity: 1; }
.clip figcaption { margin-top: 12px; font-size: 13px; line-height: 1.5; color: var(--c-text-3); }
.band--dark .clip figcaption { color: var(--c-text-dk-2); }
/* A still and a loop are hard to tell apart at rest, so the caption says which it is.
 * It used to be a badge inside the frame, which sat over the table header, a card, or
 * the dashboard's own title in every single clip. */
.clip figcaption::before {
  content: '';
  display: inline-block;
  width: 7px; height: 7px;
  margin: 0 8px 1px 0;
  border-radius: 50%;
  background: var(--c-border-strong);
  vertical-align: middle;
}
.clip.is-playing figcaption::before { background: var(--c-accent-text); }
.band--dark .clip.is-playing figcaption::before { background: var(--c-accent-film); }

/* The hero: the product moving, full bleed, under a play control for the film. */
.hero__loop {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 900ms var(--ease);
}
.player.is-playing .hero__loop { opacity: 1; }

/* -------------------------------------------------------------- gallery --- */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px 18px;
  margin-top: 40px;
}
.gallery figure { margin: 0; }
/* Every thumbnail is the same shape, cropped from the top, so a portrait dialog and
 * a wide chart sit in one calm grid. The lightbox shows each at its true shape. */
.gallery button {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  padding: 0;
  border: 1px solid var(--c-border);
  border-radius: var(--r-media);
  overflow: hidden;
  background: #fff;
  cursor: zoom-in;
  box-shadow: var(--sh-1);
  transition: box-shadow var(--dur-hover) var(--ease), transform var(--dur-hover) var(--ease);
}
.gallery button:hover { box-shadow: var(--sh-lift); transform: translateY(-2px); }
.gallery img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center; }
/* Every thumbnail shows the whole still. A cover crop was cutting the bottoms off the
 * taller cards, which is exactly what a reader took to be a broken screenshot. The
 * screens are white-backed, so letterboxing on a white cell costs nothing. */
/* A genuinely wide screen (a chart, a table, a dashboard strip) spans two cells, so
 * its text is readable rather than a grey smear in a half-empty box. Two tiers of
 * cell shape, matched to the shots, so the letterboxing stays thin; and dense packing,
 * so the single shots fill the gaps that a run of wide ones would otherwise leave. */
.gallery { grid-auto-flow: dense; }
.gallery figure.is-wide, .gallery figure.is-strip { grid-column: span 2; }
/* Two cells plus the gap, over one cell's height, so every row lines up. */
.gallery figure.is-wide button, .gallery figure.is-strip button { aspect-ratio: 3.29; }
/* A portrait still spans two rows and its button fills them, so its caption lands on the
 * same line as its neighbours' whatever the caption lengths. */
.gallery figure { display: flex; flex-direction: column; }
.gallery figure.is-tall { grid-row: span 2; }
.gallery figure.is-tall button { flex: 1 1 auto; min-height: 0; }
.gallery figure.is-panel { grid-column: span 2; grid-row: span 2; }
.gallery figure.is-panel button { flex: 1 1 auto; min-height: 0; }
.gallery figcaption { padding-top: 12px; min-height: calc(2 * 1.45em + 12px); font-size: 14px; line-height: 1.45; color: var(--c-text-2); }
.gallery + .btn-row { margin-top: 36px; }

/* The lightbox is a <dialog>, so focus, Escape and the backdrop come for free. */
.lightbox {
  width: min(96vw, 1400px);
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: var(--r-media);
  background: var(--c-ink-900);
  color: var(--c-text-dk-2);
  box-shadow: 0 40px 100px rgba(2, 9, 17, .6);
}
.lightbox::backdrop { background: rgba(5, 15, 27, .82); backdrop-filter: blur(4px); }
.lightbox img { display: block; width: auto; max-width: 100%; height: auto; max-height: 80vh; margin: 0 auto; background: #fff; }
@media (max-width: 720px) {
  .lightbox img { max-width: none; width: 720px; max-height: none; }
  .lightbox img.is-small { width: auto; max-width: 100%; }
}
.lightbox { text-align: center; }
.lightbox__bar { text-align: left; }
.lightbox__bar {
  position: sticky;
  bottom: 0;
  background: var(--c-ink-900);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
}
.lightbox__bar p { margin: 0; font-size: 15px; color: #fff; }
.lightbox__bar button {
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, .34);
  border-radius: var(--r-md);
  background: transparent;
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.lightbox__bar button:hover { background: rgba(255, 255, 255, .12); }
.lightbox__nav { display: flex; gap: 8px; align-items: center; }
.lightbox .small { color: var(--c-text-dk-2); }
/* On a phone the enlarged image can be panned at a readable size instead of shrinking
 * to the dialog's width. */
.lightbox__img { overflow: auto; -webkit-overflow-scrolling: touch; }

/* ----------------------------------------------------------- the lockup --- */
/* The real logo, cut from the source artwork, rather than the site's typeface
 * imitating it. Two versions: brand colours on light, white "Borough" on dark. */
.wordmark img { display: block; height: 34px; width: auto; }
.site-footer .wordmark img { height: 40px; }
/* One image per wordmark. Over a dark hero the header starts with the white version
 * and site.js swaps it as the bar resolves; the footer only ever needs the white one. */

/* A brand moment: the stacked logo, centred, for the about page and the 404. */
.brand-moment { display: flex; justify-content: center; margin: 0 0 40px; }
.brand-moment img { width: min(230px, 50vw); height: auto; }

/* ---------------------------------------------------------------- tables --- */
/* Comparisons are tables. The wrapper scrolls sideways on a phone rather than letting
 * the page do it; the caption carries the illustrative note where one is needed. */
.table-wrap { margin-top: 40px; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 1.5; }
.table caption { caption-side: bottom; padding-top: 12px; text-align: left; font-size: 13px; color: var(--c-text-3); }
.table th, .table td { padding: 16px 20px; vertical-align: top; text-align: left; border-bottom: 1px solid var(--c-border); }
.table thead th {
  padding-top: 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--c-text-3);
  border-bottom: 2px solid var(--c-border-strong);
}
.table tbody th { font-weight: 600; color: var(--c-text); white-space: nowrap; }
.table td { color: var(--c-text-2); }
/* The column that is us. A tinted ground, not a coloured heading, so it reads as the
 * answer without shouting. */
.table .is-us { background: var(--c-bg-tint); color: var(--c-text); }
.table thead .is-us { color: var(--c-primary); }
@media (min-width: 901px) { .table--min td, .table--min th { min-width: 14em; } }
.band--dark .table th, .band--dark .table td { border-color: rgba(255, 255, 255, .16); color: var(--c-text-dk-2); }
.band--dark .table tbody th, .band--dark .table .is-us { color: #fff; }
.band--dark .table .is-us { background: rgba(255, 255, 255, .07); }
.band--dark .table thead th { color: var(--c-text-dk-2); border-color: rgba(255, 255, 255, .3); }
.band--dark .table caption { color: var(--c-text-dk-2); }

/* The trust strip: four facts, no numbers pretending to be proof. */
.proof--facts b { font-size: 19px; line-height: 1.35; letter-spacing: -.01em; color: var(--c-text); }

/* ------------------------------------------------- calls to action --- */
.hero__trust {
  margin-top: 22px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--c-text-dk-2);
  opacity: .78;
  max-width: 44ch;
}

/* A quiet band that interrupts the read once, where the argument has just landed. */
.cta-strip { background: var(--c-bg-tint); }
.cta-strip__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.cta-strip h2 { margin-bottom: 8px; font-size: clamp(22px, 2.4vw, 28px); }
.cta-strip p { margin: 0; color: var(--c-text-2); max-width: 56ch; }
.cta-strip .btn { flex: none; }

/* The closing block asks for the demo on the page rather than sending the reader to
 * another one to ask again. */
.final-cta { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.final-cta__copy h1 { font-size: clamp(32px, 4vw, 46px); }
.final-cta__copy .lead { margin-bottom: 28px; }
.final-cta__copy .small { margin-top: 24px; }

.ticks { list-style: none; margin: 0; padding: 0; }
.ticks li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 14px;
  color: var(--c-text-dk-2);
}
.ticks li::before {
  content: '';
  position: absolute;
  left: 2px; top: 8px;
  width: 11px; height: 6px;
  border-left: 2px solid var(--c-accent-film);
  border-bottom: 2px solid var(--c-accent-film);
  transform: rotate(-45deg);
}

.final-cta__form {
  margin-top: 0;
  padding: 32px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: var(--r-media);
  backdrop-filter: blur(2px);
}
.final-cta__form .btn { width: 100%; margin-top: 4px; }
/* White on the dark ground: the primary blue does not have the contrast here. */
.band--dark .final-cta__form .btn--primary { background: #fff; color: var(--c-ink-900); box-shadow: none; }
.band--dark .final-cta__form .btn--primary:hover { background: var(--c-text-dk-2); }

/* --------------------------------------------------------------- footer --- */
.site-footer {
  position: relative;
  background: var(--c-ink-900);
  color: var(--c-text-dk-2);
  padding: 72px 0 40px;
}
/* A hairline of brand colour where the footer meets the page above it. */
.site-footer::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(124, 190, 66, .55), rgba(74, 150, 205, .45), transparent);
}
.site-footer a { color: var(--c-text-dk-2); }
.site-footer a:hover { color: #fff; }
.site-footer .small { color: var(--c-text-dk-2); }
.site-footer .wordmark { color: #fff; font-size: 20px; }
.site-footer .wordmark__text > span { color: var(--c-accent-film); }

.footer-cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.3fr; gap: 40px; }
.footer-cols .footer-heading { margin-top: 0; font-size: 14px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: #fff; margin-bottom: 14px; }
.footer-cols ul { list-style: none; margin: 0; padding: 0; }
.footer-cols li { margin-bottom: 10px; }
.footer-cols a { font-size: 15px; text-decoration: none; transition: color var(--dur-hover) var(--ease); }
.footer-cols a:hover { text-decoration: underline; color: #fff; }

.footer-base {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: 14px;
  opacity: .85;
}

/* ------------------------------------------------------------ 404, misc --- */
.center { text-align: center; }
.center > h1, .center > .lead, .center > p { margin-inline: auto; }
.center .btn-row { justify-content: center; }

.prose h2 { margin-top: 48px; }
.prose > h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 32px; font-size: 19px; }
.prose dl { margin: 24px 0; }
.prose dt { font-weight: 600; margin-top: 16px; }
.prose dd { margin: 4px 0 0; color: var(--c-text-2); }

/* ------------------------------------------------------------ responsive --- */
@media (max-width: 900px) {
  .feature { grid-template-columns: 1fr; gap: 32px; }
  /* Stacked, the copy leads on every row: its heading is what introduces the
   * screenshot, so a reader should never meet the picture first. */
  .feature__copy { order: 0; }
  .feature--flip .feature__copy { order: 0; }
  .proof { grid-template-columns: 1fr 1fr; gap: 28px 0; }
  .proof > div:nth-child(3) { padding-left: 0; border-left: 0; }
  /* The facts are sentences, not numbers, and two abreast they overflow a phone. */
  .proof--facts { grid-template-columns: 1fr; gap: 0; }
  .proof--facts > div { padding: 14px 0; border-left: 0; }
  .proof--facts > div + div { border-top: 1px solid var(--c-border); }
  .stats { grid-template-columns: 1fr; gap: 32px; }
  .footer-cols { grid-template-columns: 1fr 1fr; gap: 32px 40px; }
  .final-cta { grid-template-columns: 1fr; gap: 40px; }
  /* One column: each still takes its own shape rather than a strip in a white box. Two
   * columns left holes beside the figures that span. */
  .gallery { grid-template-columns: 1fr; }
  .gallery figure.is-wide, .gallery figure.is-strip, .gallery figure.is-panel { grid-column: auto; }
  .gallery figure.is-tall, .gallery figure.is-panel { grid-row: auto; }
  .gallery figure.is-tall button, .gallery figure.is-panel button { flex: none; }
  .gallery button, .gallery figure.is-wide button, .gallery figure.is-strip button, .gallery figure.is-tall button { aspect-ratio: auto; }
  .gallery img { height: auto; object-fit: initial; }
  .gallery figcaption { min-height: 0; }
  .calc__grid { grid-template-columns: 1fr 1fr; }
  .calc__out { grid-column: 1 / -1; padding-top: 8px; }
  .morning { grid-template-columns: 1fr; gap: 18px; }
  .morning li { display: grid; grid-template-columns: 168px 1fr; grid-template-areas: 'img when' 'img title' 'img body'; column-gap: 18px; align-content: start; padding-top: 0; border-top: 0; }
  .morning li::before { display: none; }
  .morning__shot { grid-area: img; margin: 0; }
  .morning__when { grid-area: when; }
  .morning b { grid-area: title; }
  .morning p { grid-area: body; }
  .cta-strip__inner { flex-direction: column; align-items: flex-start; gap: 24px; }
}

@media (max-width: 720px) {
  h1 { font-size: 34px; }
  h2 { font-size: 26px; }
  h3 { font-size: 19px; }
  body { font-size: 16px; }
  .lead { font-size: 18px; }
  .band { padding: 56px 0; }
  .band--dark { padding: 64px 0; }
  .hero { padding: calc(var(--header-h) + 34px) 0 56px; }
  .hero__media { margin-top: 36px; }
  .stat b { font-size: 34px; }
  .btn-row .btn { width: 100%; text-align: center; }

  /* The nav becomes a real disclosure again. */
  .site-nav { position: static; margin-left: auto; }
  .nav-toggle { display: block; position: relative; }
  .nav-toggle > summary {
    display: block;
    list-style: none;
    padding: 9px 14px;
    border: 1px solid var(--c-border-strong);
    border-radius: var(--r-md);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    color: var(--c-text);
  }
  .nav-toggle > summary::-webkit-details-marker { display: none; }
  /* Over the dark hero the button has to be legible on the artwork. */
  html.js body.has-dark-hero .site-header:not(.is-scrolled) .nav-toggle > summary {
    color: #fff;
    border-color: rgba(255, 255, 255, .42);
    background: rgba(255, 255, 255, .08);
  }
  /* A closed disclosure must hide its list. The base rule sets display on the list
   * for the desktop bar, and that was overriding the browser's own hiding, so the
   * links sat on the page with the menu shut. */
  .nav-toggle:not([open]) > ul { display: none; }
  .nav-toggle[open] > ul {
    display: flex;
    position: static;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 8px 24px 20px;
    background: var(--c-bg);
    border-bottom: 1px solid var(--c-border);
    box-shadow: var(--sh-2);
  }
  .nav-toggle a { padding: 14px 0; font-size: 17px; color: var(--c-text-2); }
  .nav-toggle a::after { display: none; }
  .nav-toggle .btn { display: block; margin-top: 10px; text-align: center; color: #fff; }
  body.has-dark-hero .nav-toggle a { color: var(--c-text-2); }
  /* The dark hero rule for the current page outranks the panel colour; restate it here
   * or the current page's own link is white on the white panel. */
  body.has-dark-hero .nav-toggle a:not(.btn):hover,
  body.has-dark-hero .nav-toggle a:not(.btn)[aria-current='page'] { color: var(--c-primary); }
  html.js .nav-toggle[open] > ul { position: fixed; left: 0; right: 0; top: var(--header-h); }
  /* Without the script the disclosure ships open and the list sits under the bar. */
  html:not(.js) .site-header { position: static; height: auto; }
  html:not(.js) .site-header .wrap { flex-wrap: wrap; }
  html:not(.js) .site-nav { flex: 1 1 100%; }
  html:not(.js) .nav-toggle[open] > ul { box-shadow: none; padding-top: 0; }
  body.has-dark-hero .nav-toggle .btn--primary { background: var(--c-primary); border-color: transparent; color: #fff; }
  /* The dark header's link and button rules are prefixed html.js, which lifts them above
   * the panel rules here; restated at that weight, and later, so the white panel keeps
   * dark links, a blue current page and a filled button whether or not the page has
   * scrolled. */
  html.js body.has-dark-hero .nav-toggle a { color: var(--c-text-2); }
  html.js body.has-dark-hero .nav-toggle a:not(.btn):hover,
  html.js body.has-dark-hero .nav-toggle a:not(.btn)[aria-current='page'] { color: var(--c-primary); }
  html.js body.has-dark-hero .nav-toggle .btn--primary,
  html.js body.has-dark-hero .nav-toggle .btn--primary:hover { background: var(--c-primary); border-color: transparent; color: #fff; }
  .footer-cols { grid-template-columns: 1fr; }
  /* A three column comparison stacks: each row becomes a small card, each cell
   * carrying its column heading. Wider tables keep the sideways scroll instead. */
  .table--stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .table--stack, .table--stack tbody, .table--stack tr, .table--stack th, .table--stack td { display: block; }
  .table--stack tr { padding: 4px 0 16px; border-bottom: 1px solid var(--c-border); }
  .table--stack tr + tr { margin-top: 12px; }
  .table--stack tbody th { padding: 12px 0 6px; border: 0; white-space: normal; font-size: 17px; }
  .table--stack td { padding: 8px 0 8px 14px; border: 0; border-left: 3px solid var(--c-border); margin-top: 8px; }
  .table--stack td.is-us { border-left-color: var(--c-accent); background: transparent; }
  .table--stack td::before { content: attr(data-label); display: block; margin-bottom: 4px; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--c-text-3); }
  .table--stack td.is-us::before { color: var(--c-accent-text); }
  .band--dark .table--stack td::before { color: var(--c-text-dk-2); }
  .band--dark .table--stack td.is-us::before { color: var(--c-accent-film-pale); }
  .band--dark .table--stack tr, .band--dark .table--stack td { border-color: rgba(255, 255, 255, .16); }
  .band--dark .table--stack td.is-us { border-left-color: var(--c-accent-film); }
  .table tbody th { white-space: normal; }
  .calc { padding: 24px 20px; }
  .calc__grid { grid-template-columns: 1fr; gap: 18px; }
  .morning li { grid-template-columns: 120px 1fr; column-gap: 14px; }
  .lightbox__bar { flex-direction: column; align-items: stretch; gap: 12px; }
  .lightbox__nav { justify-content: space-between; }
  .wordmark img { height: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  html { scroll-behavior: auto; }
  /* The important part: never leave anything hidden waiting on motion that will
   * not happen. Everything that animates in is simply present instead. */
  [data-reveal],
  [data-reveal-group].is-visible > *,
  .hero__intro > *,
  .hero__media {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
  .hero .eyebrow::before { animation: none !important; }
  .btn:hover, .card:hover, .shot:hover img { transform: none !important; }
}

/* ----------------------------------------------------------------- print --- */
/* The security page's job is to end up attached to a council's data protection
 * impact assessment. An information governance officer will print it or save it
 * as a PDF, so it has to survive leaving the browser: dark bands that cost a
 * fortune in toner and read badly in greyscale, navigation that means nothing on
 * paper, a link whose destination is invisible once it is not clickable, and an
 * accordion whose answers are shut. This lives here rather than in a second file
 * so the content security policy has one stylesheet to allow, as it always has. */
.print-only { display: none; }

@media print {
  .print-only { display: block; }

  /* Everything that waits for a scroll is simply present. Without this the page
   * prints as a heading and a contents list: the reveal sweep only runs for what
   * has been scrolled past, so a reader who opens the page and reaches straight
   * for print gets a blank document. Found by printing it, not by reading it. */
  [data-reveal],
  [data-reveal-group] > *,
  [data-reveal-group].is-visible > *,
  .hero__intro > *,
  .hero__media {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }

  /* The body is a flex column with a min-height of one viewport, which keeps a
   * short page's footer at the bottom of the screen. On paper that viewport
   * becomes a sheet, and the flex column paginates into blank pages between the
   * sections. Print is plain block flow. */
  body { display: block; min-height: 0; }
  main { display: block; flex: none; }
  main > section:last-of-type { flex: none; }
  main > .hero--page:last-of-type { display: block; }

  /* Ink. Every band prints as black on white, including the ones that carry the
   * gradient and the radial pools of light. */
  body, .band, .band--alt, .band--dark, .band--tight {
    background: #fff !important;
    color: #000 !important;
  }
  .band--dark::before { display: none !important; }
  .band--dark h1, .band--dark h2, .band--dark h3, .band--dark p,
  .band--dark li, .band--dark .lead, .band--dark .small, .band--dark .eyebrow,
  .band--dark .table, .band--dark .table th, .band--dark .table td {
    color: #000 !important;
  }

  /* Anything that is navigation, decoration or a call to action is not part of
   * the document someone is filing. */
  .site-header, .skip, .site-nav, .btn-row, .cta-strip, .final-cta,
  .lightbox, .clip__video, .player { display: none !important; }
  .site-footer { border-top: 1px solid #999; }
  .site-footer .footer-cols { display: none !important; }

  /* Paper is not a screen: less air, and no drop shadows. */
  .band { padding: 18px 0 !important; }
  .band--dark { padding: 18px 0 !important; }
  .hero, .hero--page { padding: 0 0 18px !important; }
  .wrap { max-width: none; padding: 0; }
  .shot, .clip__frame, .card, .panel { box-shadow: none !important; }

  /* A link is only useful on paper if you can see where it goes. Site relative
   * links get the domain so the reader can type them. */
  a[href^="/"]::after { content: " (boroughlets.com" attr(href) ")"; font-size: .85em; word-break: break-all; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .85em; word-break: break-all; }
  a[href^="mailto:"]::after, a[href^="#"]::after { content: ""; }

  /* A closed accordion prints as a list of questions with no answers. */
  details > *:not(summary) { display: block !important; }
  .qa__body { height: auto !important; }

  /* Keep a table row and a heading with what they belong to. */
  tr, .ruled, .panel, li { break-inside: avoid; }
  h1, h2, h3 { break-after: avoid; page-break-after: avoid; }
  table { break-inside: auto; }
  thead { display: table-header-group; }
}
