/* ==========================================================================
   Project SHOUT | main.css
   The only stylesheet for the site. Plain CSS, mobile first, no framework.

   Contents
   1.  Fonts
   2.  Design tokens
   3.  Base
   4.  Layout
   5.  Accessibility helpers
   6.  Emergency strip
   7.  Header, logo and navigation
   8.  Buttons
   9.  Sections, hero and page headers
   10. Content components
   11. Video
   12. Footer
   13. Verify marks
   14. High contrast, reduced motion and print
   ========================================================================== */


/* 1. Fonts
   Self-hosted, SIL Open Font Licence. See /assets/fonts/ for licence files.
   -------------------------------------------------------------------------- */

@font-face {
  font-family: "Source Sans 3";
  src: url("/assets/fonts/source-sans-3-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Playfair Display";
  src: url("/assets/fonts/playfair-display-latin-wght-normal.woff2") format("woff2");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Playfair Display";
  src: url("/assets/fonts/playfair-display-latin-wght-italic.woff2") format("woff2");
  font-weight: 400 900;
  font-style: italic;
  font-display: swap;
}


/* 2. Design tokens
   Colours come from the information booklet. Contrast notes are in
   /docs/design-plan.md. Orange is never used for text.
   -------------------------------------------------------------------------- */

:root {
  --purple: #4f2d86;
  --purple-900: #2e1a4f;
  --purple-100: #f3eef9;
  --orange: #ef8a23;
  --orange-300: #f6b26b;
  --orange-100: #fdf0e1;
  --blue: #0f6cb5;
  --sky: #5dbdea;
  --sky-100: #e9f6fc;
  --ink: #2b2b33;
  --ink-soft: #4a4a55;
  --paper: #fbf8f4;
  --white: #ffffff;
  --line: #ddd3ea;
  --verify-bg: #fff200;

  --font-sans: "Source Sans 3", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Playfair Display", Georgia, "Times New Roman", serif;

  /* Fluid type scale, 320px to 1280px */
  --step--1: 0.9375rem;
  --step-0: 1.125rem;
  --step-1: clamp(1.25rem, 1.1875rem + 0.3125vw, 1.4375rem);
  --step-2: clamp(1.4375rem, 1.3125rem + 0.625vw, 1.8125rem);
  --step-3: clamp(1.75rem, 1.5rem + 1.25vw, 2.5rem);
  --step-4: clamp(2.125rem, 1.75rem + 1.875vw, 3.5rem);
  --step-5: clamp(2.5rem, 1.875rem + 3.125vw, 4.5rem);

  --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-section: clamp(3rem, 2rem + 5vw, 6rem);
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2rem);

  --container: 72rem;
  --measure: 42rem;
  --radius: 0.75rem;
  --radius-s: 0.375rem;
  --shadow: 0 1px 2px rgb(46 26 79 / 0.08), 0 8px 24px rgb(46 26 79 / 0.08);
  --shadow-lift: 0 2px 4px rgb(46 26 79 / 0.1), 0 16px 36px rgb(46 26 79 / 0.18);

  /* Focus ring colour. Dark panels switch this to white. */
  --ring: var(--purple-900);
}


/* 3. Base
   -------------------------------------------------------------------------- */

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

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

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.6;
  overflow-wrap: break-word;
}

img,
svg,
iframe {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 var(--space-s);
  color: var(--purple);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 {
  font-size: var(--step-4);
}

h2 {
  font-size: var(--step-3);
}

h3 {
  font-size: var(--step-2);
  font-weight: 700;
  line-height: 1.25;
}

h4 {
  font-size: var(--step-1);
  font-weight: 700;
  line-height: 1.3;
}

p,
ul,
ol,
dl,
blockquote,
figure {
  margin: 0 0 var(--space-s);
}

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

li + li {
  margin-top: 0.35em;
}

:where(p, ul, ol, dl, figure, blockquote):last-child {
  margin-bottom: 0;
}

strong,
b {
  font-weight: 700;
}

a {
  color: var(--blue);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--purple);
  text-decoration-thickness: 0.14em;
}

:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 3px;
}

[tabindex="-1"]:focus {
  outline: none;
}

[hidden] {
  display: none !important;
}

[id] {
  scroll-margin-top: 1.5rem;
}

a[href^="tel:"] {
  white-space: nowrap;
}

.icon {
  display: inline-block;
  flex: none;
  width: 1.25em;
  height: 1.25em;
  vertical-align: -0.25em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}


/* 4. Layout
   -------------------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.measure {
  max-width: var(--measure);
}

.split {
  display: grid;
  gap: var(--space-xl);
  align-items: center;
}

@media (min-width: 56em) {
  .split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: var(--space-2xl);
  }

  .split--top {
    align-items: start;
  }

  /* Photo shows on the left, but text stays first in the reading order. */
  .split--media-left > .split__media {
    order: -1;
  }
}

/* A section introduction with a photo beside it */
.split--intro {
  margin-bottom: var(--space-xl);
}

.list-reset {
  margin: 0;
  padding: 0;
  list-style: none;
}

.list-reset > li {
  margin: 0;
}


/* 5. Accessibility helpers
   -------------------------------------------------------------------------- */

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

.skip-link {
  position: absolute;
  top: -10rem;
  left: var(--space-s);
  z-index: 100;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-s);
  background: var(--purple-900);
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: var(--space-s);
}

.skip-link:hover {
  color: var(--white);
}


/* 6. Emergency strip
   On every page, above the header.
   -------------------------------------------------------------------------- */

.emergency {
  --ring: var(--purple-900);
  background: var(--orange);
  color: var(--purple-900);
  font-size: 1rem;
  line-height: 1.5;
}

.emergency__inner {
  display: flex;
  align-items: flex-start;
  gap: var(--space-xs);
  padding-block: var(--space-xs);
}

.emergency__icon {
  width: 1.75rem;
  height: 1.75rem;
}

.emergency__text {
  margin: 0;
}

.emergency a {
  color: inherit;
  font-weight: 800;
}

.emergency a:hover {
  color: inherit;
  text-decoration-thickness: 0.16em;
}

.emergency__phone {
  white-space: nowrap;
}

.emergency__link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
}

@media (min-width: 48em) {
  .emergency {
    font-size: 1.0625rem;
  }

  .emergency__inner {
    align-items: center;
  }
}


/* 7. Header, logo and navigation
   -------------------------------------------------------------------------- */

.site-header {
  position: relative;
  background: var(--white);
}

.site-header::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 4px;
  background: linear-gradient(90deg, var(--purple), var(--blue) 60%, var(--sky));
}

.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xs) var(--space-s);
  padding-block: var(--space-xs) calc(var(--space-xs) + 4px);
}

/* Project SHOUT watercolour logo, made from the .ai file in /source. */
.logo {
  display: block;
  flex: none;
  border-radius: var(--radius-s);
}

.logo img {
  width: auto;
  height: 4rem;
}

@media (min-width: 48em) {
  .logo img {
    height: 4.5rem;
  }
}

/* Keep the logo and Menu button on one line on the narrowest phones. */
@media (max-width: 22.5em) {
  .site-header__inner {
    column-gap: var(--space-2xs);
  }

  .site-header .menu-toggle,
  .site-header .menu-link {
    padding-inline: 0.9rem;
  }
}

.menu-toggle,
.menu-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0.5rem 1.1rem;
  border: 2px solid var(--purple);
  border-radius: 999px;
  background: var(--white);
  color: var(--purple);
  font: inherit;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.menu-toggle:hover,
.menu-link:hover,
.menu-toggle[aria-expanded="true"] {
  background: var(--purple);
  color: var(--white);
}

.menu-toggle .icon--close,
.menu-toggle[aria-expanded="true"] .icon--menu {
  display: none;
}

.menu-toggle[aria-expanded="true"] .icon--close {
  display: inline-block;
}

.primary-nav {
  display: none;
  flex-basis: 100%;
}

.primary-nav.is-open {
  display: block;
}

.primary-nav__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.primary-nav__list > li {
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.primary-nav__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  width: 100%;
  min-height: 3rem;
  padding: 0.65rem 0.25rem;
  border: 0;
  background: none;
  color: var(--purple-900);
  font: inherit;
  font-weight: 700;
  line-height: 1.3;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.primary-nav__link:hover {
  color: var(--blue);
  text-decoration: underline;
}

.primary-nav__link[aria-current="page"] {
  padding-left: 0.85rem;
  box-shadow: inset 4px 0 0 var(--purple);
  color: var(--purple);
}

.submenu-toggle .icon {
  transition: transform 0.2s ease;
}

.submenu-toggle[aria-expanded="true"] .icon {
  transform: rotate(180deg);
}

.submenu {
  display: none;
  margin: 0;
  padding: 0 0 0.5rem 0.85rem;
  list-style: none;
}

.submenu > li {
  margin: 0;
}

.submenu-toggle[aria-expanded="true"] + .submenu {
  display: block;
}

/* Without JavaScript the dropdown still opens on hover and keyboard focus. */
html:not(.js) .has-submenu:hover > .submenu,
html:not(.js) .has-submenu:focus-within > .submenu {
  display: block;
}

.submenu__link {
  display: block;
  padding: 0.6rem 0.25rem;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

.submenu__link:hover {
  color: var(--blue);
  text-decoration: underline;
}

.submenu__link[aria-current="page"] {
  padding-left: 0.85rem;
  box-shadow: inset 4px 0 0 var(--purple);
  color: var(--purple);
  font-weight: 800;
}

@media (min-width: 64em) {
  .menu-toggle,
  .menu-link {
    display: none !important;
  }

  .primary-nav {
    display: block;
    flex-basis: auto;
  }

  .primary-nav__list {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    border: 0;
  }

  .primary-nav__list > li {
    position: relative;
    border: 0;
  }

  .primary-nav__link {
    width: auto;
    min-height: 2.75rem;
    padding: 0.5rem 0.8rem;
    border-radius: var(--radius-s);
  }

  .primary-nav__link:hover {
    background: var(--purple-100);
    color: var(--purple-900);
    text-decoration: none;
  }

  .primary-nav__link[aria-current="page"],
  .has-submenu:has([aria-current="page"]) > .submenu-toggle {
    padding-left: 0.8rem;
    border-radius: var(--radius-s) var(--radius-s) 0 0;
    box-shadow: inset 0 -3px 0 var(--purple);
    color: var(--purple);
  }

  .submenu-toggle[aria-expanded="true"] {
    background: var(--purple-100);
  }

  .submenu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 30;
    min-width: 17rem;
    padding: 0.5rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--white);
    box-shadow: var(--shadow-lift);
  }

  .submenu__link {
    padding: 0.65rem 0.85rem;
    border-radius: var(--radius-s);
  }

  .submenu__link:hover {
    background: var(--purple-100);
    color: var(--purple-900);
    text-decoration: none;
  }

  .submenu__link[aria-current="page"] {
    border-radius: 0 var(--radius-s) var(--radius-s) 0;
  }
}


/* 8. Buttons
   -------------------------------------------------------------------------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0.7rem 1.5rem;
  border: 2px solid transparent;
  border-radius: 999px;
  background: var(--purple);
  color: var(--white);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.button:hover {
  background: var(--purple-900);
  color: var(--white);
}

.button--accent {
  background: var(--orange);
  color: var(--purple-900);
}

.button--accent:hover {
  background: var(--orange-300);
  color: var(--purple-900);
}

.button--light {
  background: var(--white);
  color: var(--purple);
}

.button--light:hover {
  background: var(--purple-100);
  color: var(--purple-900);
}

.button--outline {
  border-color: var(--purple);
  background: transparent;
  color: var(--purple);
}

.button--outline:hover {
  border-color: var(--purple);
  background: var(--purple);
  color: var(--white);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s);
  margin-top: var(--space-l);
}


/* 9. Sections, hero and page headers
   -------------------------------------------------------------------------- */

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

.section--tight {
  padding-block: var(--space-xl);
}

.section--paper {
  background: var(--paper);
}

.section--lilac {
  background: var(--purple-100);
}

.section--purple {
  --ring: var(--white);
  background: var(--purple);
  color: var(--white);
}

.section--purple :is(h2, h3) {
  color: var(--white);
}

.section--purple a:not(.button) {
  color: var(--white);
}

.section--purple a:not(.button):hover {
  color: var(--sky-100);
}

.section__header {
  max-width: var(--measure);
  margin-bottom: var(--space-xl);
}

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

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

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: var(--space-xs);
  color: var(--blue);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.eyebrow::before {
  content: "";
  flex: none;
  width: 2rem;
  height: 4px;
  border-radius: 2px;
  background: var(--orange);
}

.lead {
  font-size: var(--step-1);
  line-height: 1.5;
}

.standfirst {
  color: var(--purple-900);
  font-size: var(--step-1);
  font-weight: 600;
  line-height: 1.4;
}

/* Home page hero */
.hero {
  --ring: var(--white);
  position: relative;
  overflow: hidden;
  background: var(--purple);
  color: var(--white);
}

.hero__inner {
  display: grid;
  gap: var(--space-xl);
  align-items: center;
  padding-block: clamp(2.5rem, 1.5rem + 5vw, 5.5rem) clamp(3rem, 2rem + 5vw, 6rem);
}

@media (min-width: 56em) {
  .hero__inner {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: var(--space-2xl);
  }
}

.hero .eyebrow,
.page-hero .eyebrow,
.section--purple .eyebrow {
  color: var(--sky);
}

.hero__title {
  margin-bottom: var(--space-m);
  color: var(--white);
  font-size: var(--step-5);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.hero__text {
  max-width: 32ch;
  font-size: var(--step-2);
  line-height: 1.4;
}

.hero__media {
  position: relative;
  padding: var(--space-m) var(--space-s);
}

/* Watercolour wash sits behind the photo only, never behind text. */
.hero__media::before {
  content: "";
  position: absolute;
  inset: -14% -30%;
  background: url("/assets/img/watercolour/wash-large.svg") center / contain no-repeat;
  pointer-events: none;
}

.hero__media > * {
  position: relative;
}

/* Inner page header */
.page-hero {
  --ring: var(--white);
  position: relative;
  overflow: hidden;
  background: var(--purple);
  color: var(--white);
}

.page-hero::after {
  content: "";
  display: none;
  position: absolute;
  top: 50%;
  right: -8rem;
  width: min(34rem, 45vw);
  height: 26rem;
  transform: translateY(-50%);
  background: url("/assets/img/watercolour/wash-large.svg") center / contain no-repeat;
  pointer-events: none;
}

@media (min-width: 64em) {
  .page-hero::after {
    display: block;
  }
}

.page-hero__inner {
  position: relative;
  z-index: 1;
  padding-block: clamp(2.5rem, 1.75rem + 4vw, 5rem);
}

.page-hero__inner > * {
  max-width: 40rem;
}

.page-hero h1 {
  margin-bottom: var(--space-m);
  color: var(--white);
}

.page-hero a:not(.button) {
  color: var(--white);
}

.page-hero a:not(.button):hover {
  color: var(--sky-100);
}

.page-hero .lead + p {
  margin-top: var(--space-s);
}


/* 10. Content components
   -------------------------------------------------------------------------- */

/* Image placeholder: describes the photo that needs to be supplied */
.placeholder {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  aspect-ratio: 4 / 5;
  padding: 1.25rem;
  border: 2px dashed var(--purple);
  background: repeating-linear-gradient(-45deg, var(--purple-100) 0 10px, var(--white) 10px 20px);
  color: var(--purple-900);
  font-size: var(--step--1);
  line-height: 1.45;
  text-align: center;
}

.placeholder p {
  margin: 0;
}

.placeholder--landscape {
  aspect-ratio: 3 / 2;
}

.placeholder--wide {
  aspect-ratio: 16 / 9;
}

.placeholder__label {
  color: var(--purple);
  font-size: 1rem;
  font-weight: 800;
}

/* Polaroid frame for photos, as used in the campaign's own artwork */
.polaroid {
  width: 100%;
  max-width: 24rem;
  margin: 0 auto;
  padding: 0.75rem 0.75rem 0;
  background: var(--white);
  box-shadow: var(--shadow-lift);
  transform: rotate(-1deg);
}

.polaroid img {
  width: 100%;
  background: var(--purple-100);
}

.polaroid--right {
  transform: rotate(1deg);
}

@media (min-width: 40em) {
  .polaroid {
    transform: rotate(-2.5deg);
  }

  .polaroid--right {
    transform: rotate(2deg);
  }
}

.polaroid__caption {
  padding: 0.85rem 0.25rem 1.1rem;
  color: var(--purple-900);
  font-family: var(--font-serif);
  font-size: var(--step-1);
  font-style: italic;
  line-height: 1.3;
  text-align: center;
}

.polaroid-stack {
  display: grid;
  gap: var(--space-l);
}

@media (min-width: 56em) {
  .polaroid-stack > :nth-child(2) {
    width: 85%;
    margin: -2.5rem 0 0 auto;
  }
}

/* Quote panels */
.quote {
  --ring: var(--purple-900);
  margin: 0;
  padding: clamp(1.75rem, 1.25rem + 2.5vw, 3rem);
  background: var(--orange);
  color: var(--purple-900);
}

.quote--purple {
  --ring: var(--white);
  background: var(--purple);
  color: var(--white);
}

.quote blockquote {
  margin: 0;
}

.quote blockquote p {
  font-family: var(--font-serif);
  font-size: var(--step-3);
  font-weight: 500;
  line-height: 1.3;
}

.quote--small blockquote p {
  font-size: var(--step-2);
}

.quote--wide blockquote p {
  max-width: 34ch;
}

.quote__mark {
  color: var(--white);
}

.quote--purple .quote__mark {
  color: var(--orange);
}

.quote figcaption {
  margin-top: var(--space-m);
  font-weight: 700;
}

.quote figcaption a,
.quote figcaption a:hover {
  color: inherit;
}

.quote-grid {
  display: grid;
  gap: var(--space-m);
  margin-block: var(--space-xl) 0;
}

@media (min-width: 48em) {
  .quote-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 64em) {
  .quote-grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .quote-grid--3 .quote blockquote p {
    font-size: var(--step-1);
  }
}

/* Key figures */
.stats {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 48em) {
  .stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.stat {
  margin: 0;
  padding: var(--space-xl) var(--space-l);
  background: var(--purple);
  color: var(--white);
}

.stat:nth-child(2) {
  background: var(--orange);
  color: var(--purple-900);
}

.stat:nth-child(3) {
  background: var(--blue);
  color: var(--white);
}

.stat__number {
  margin-bottom: var(--space-s);
  font-family: var(--font-serif);
  font-size: clamp(3rem, 2.25rem + 3.75vw, 4.5rem);
  font-style: italic;
  font-weight: 800;
  line-height: 1;
}

/* While a figure is still a [VERIFY] mark, keep the line height normal. */
.stat__number:has(> .verify) {
  font-size: 1rem;
  line-height: 1.6;
}

.stat__label {
  font-size: var(--step-1);
  font-weight: 600;
  line-height: 1.35;
}

.stat__source {
  margin-top: var(--space-s);
  font-size: var(--step--1);
}

/* Numbered steps on watercolour blobs (blue, purple, orange) */
.steps {
  display: grid;
  gap: var(--space-m);
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.steps > li {
  display: grid;
  grid-template-columns: 4.75rem minmax(0, 1fr);
  gap: var(--space-s);
  align-items: center;
  margin: 0;
  counter-increment: step;
}

.steps > li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 4.75rem;
  height: 3.75rem;
  background: url("/assets/img/watercolour/blob-blue.svg") center / 100% 100% no-repeat;
  color: var(--white);
  font-family: var(--font-serif);
  font-size: 2rem;
  font-style: italic;
  font-weight: 800;
  line-height: 1;
}

.steps > li:nth-child(3n + 2)::before {
  background-image: url("/assets/img/watercolour/blob-purple.svg");
}

.steps > li:nth-child(3n)::before {
  background-image: url("/assets/img/watercolour/blob-orange.svg");
  color: var(--purple-900);
}

.steps p {
  margin: 0;
  font-size: var(--step-1);
  line-height: 1.4;
}

.steps a[href^="tel:"] {
  font-weight: 800;
}

@media (min-width: 48em) {
  .steps--grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-l) var(--space-xl);
  }
}

@media (min-width: 64em) {
  .steps--grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .steps--grid > li {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
    align-items: start;
  }
}

/* Link cards: the whole card is clickable */
.cards {
  display: grid;
  gap: var(--space-m);
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 40em) {
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 64em) {
  .cards--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
  margin: 0;
  padding: var(--space-l);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  transition: box-shadow 0.15s ease;
}

.card:hover {
  box-shadow: var(--shadow-lift);
}

.card__icon {
  width: 2.75rem;
  height: 2.75rem;
  margin-bottom: var(--space-2xs);
  color: var(--purple);
  stroke-width: 1.5;
}

.card__title {
  margin: 0;
  font-size: var(--step-1);
}

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

.card__title a::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
}

.card:hover .card__title a {
  text-decoration: underline;
}

.card p {
  margin: 0;
  color: var(--ink-soft);
}

.card__arrow {
  width: 1.75rem;
  height: 1.75rem;
  margin-top: auto;
  color: var(--blue);
}

@supports selector(:has(*)) {
  .card__title a:focus-visible {
    outline: none;
  }

  .card:has(a:focus-visible) {
    outline: 3px solid var(--ring);
    outline-offset: 3px;
  }
}

/* Feature cards (not links) */
.features {
  display: grid;
  gap: var(--space-m);
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 40em) {
  .features--2,
  .features--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 64em) {
  .features--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.feature {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: var(--space-l);
  border-top: 5px solid var(--purple);
  border-radius: var(--radius-s);
  background: var(--white);
  box-shadow: var(--shadow);
}

.feature:nth-child(3n + 2) {
  border-top-color: var(--orange);
}

.feature:nth-child(3n) {
  border-top-color: var(--blue);
}

.feature__icon {
  width: 3rem;
  height: 3rem;
  margin-bottom: var(--space-s);
  color: var(--purple);
  stroke-width: 1.5;
}

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

.feature p {
  margin-bottom: var(--space-xs);
}

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

.feature__status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: var(--space-xs);
  color: var(--ink-soft);
  font-weight: 700;
}

/* Bullet list with orange dots */
.dot-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.dot-list > li {
  position: relative;
  margin: 0 0 0.5rem;
  padding-left: 1.5rem;
}

.dot-list > li::before {
  content: "";
  position: absolute;
  top: 0.6em;
  left: 0.15rem;
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: var(--orange);
}

@media (min-width: 40em) {
  .dot-list--columns {
    columns: 2;
    column-gap: var(--space-xl);
  }

  .dot-list--columns > li {
    break-inside: avoid;
  }
}

/* Checklist with tick icons */
.check-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.check-list > li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin: 0 0 0.75rem;
}

.check-list .icon {
  width: 1.6rem;
  height: 1.6rem;
  margin-top: 0.05rem;
  color: var(--orange);
  stroke-width: 2.5;
}

.page-hero .check-list {
  margin-top: var(--space-m);
  font-size: var(--step-1);
  font-weight: 600;
}

/* Callout box for key advice */
.callout {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-xs);
  margin-block: var(--space-xl) 0;
  padding: var(--space-m);
  border-left: 6px solid var(--orange);
  background: var(--orange-100);
  color: var(--ink);
}

@media (min-width: 40em) {
  .callout {
    flex-direction: row;
    gap: var(--space-s);
    padding: var(--space-m) var(--space-l);
  }
}

.callout > .icon {
  width: 2.25rem;
  height: 2.25rem;
  color: var(--purple);
}

.callout p {
  margin: 0;
  font-size: var(--step-1);
  line-height: 1.45;
}

.callout--purple {
  --ring: var(--white);
  margin-block: 0 var(--space-xl);
  background: var(--purple);
  color: var(--white);
}

.callout--purple > .icon {
  color: var(--orange);
}

/* "On this page" contents */
.toc {
  padding: var(--space-l);
  border-radius: var(--radius);
  background: var(--purple-100);
}

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

.toc__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.toc__list > li {
  margin: 0 0 0.35rem;
  break-inside: avoid;
}

.toc__list a {
  display: inline-block;
  padding-block: 0.15rem;
  font-weight: 600;
}

@media (min-width: 48em) {
  .toc__list {
    columns: 2;
    column-gap: var(--space-xl);
  }
}

/* Pill links (story jump links) */
.pill-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2xs);
  margin: var(--space-l) 0 0;
  padding: 0;
  list-style: none;
}

.pill-nav > li {
  margin: 0;
}

.page-hero .pill-nav a,
.pill-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 1.15rem;
  border: 2px solid var(--white);
  border-radius: 999px;
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
}

.page-hero .pill-nav a:hover,
.pill-nav a:hover {
  background: var(--white);
  color: var(--purple);
}

/* Severity of symptoms */
.severity {
  display: grid;
  gap: var(--space-m);
  margin: 0 0 var(--space-xl);
  padding: 0;
  list-style: none;
}

@media (min-width: 48em) {
  .severity {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.severity__level {
  margin: 0;
  padding: var(--space-l);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.severity__meter {
  display: flex;
  gap: 0.35rem;
  margin-bottom: var(--space-s);
}

.severity__meter span {
  flex: 1;
  height: 0.6rem;
  border-radius: 999px;
  background: var(--purple-100);
}

.severity__level--1 .severity__meter span:nth-child(-n + 1) {
  background: var(--sky);
}

.severity__level--2 .severity__meter span:nth-child(-n + 2) {
  background: var(--blue);
}

.severity__level--3 .severity__meter span:nth-child(-n + 3) {
  background: var(--purple);
}

.severity__level h3 {
  font-size: var(--step-1);
}

.severity__level ul {
  margin: 0;
  padding-left: 1.2em;
}

/* Story and profile layouts */
.story {
  display: grid;
  gap: var(--space-xl);
}

@media (min-width: 56em) {
  .story {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: var(--space-2xl);
    align-items: start;
  }

  .story--reverse {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  }

  .story--reverse .story__media {
    order: 2;
  }
}

.story__body .quote {
  margin-block: var(--space-l);
}

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

.story__body .video {
  margin-top: var(--space-l);
}

/* Rooms to fit a CO alarm */
.rooms {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-xs);
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 48em) {
  .rooms {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.rooms > li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
  padding: var(--space-s);
  background: var(--orange);
  color: var(--purple-900);
  font-weight: 700;
  line-height: 1.25;
}

.rooms .icon {
  width: 1.6rem;
  height: 1.6rem;
  stroke-width: 2.5;
}

/* Vision list */
.vision-list {
  display: grid;
  gap: var(--space-m);
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 56em) {
  .vision-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.vision-list > li {
  display: flex;
  flex-direction: column;
  gap: var(--space-s);
  margin: 0;
  padding: var(--space-l);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  color: var(--purple-900);
  font-size: var(--step-1);
  font-weight: 600;
  line-height: 1.4;
}

.vision-list .icon {
  width: 3rem;
  height: 3rem;
  color: var(--purple);
  stroke-width: 1.5;
}

/* Retailers */
.logo-tiles {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-s);
  margin: 0 0 var(--space-m);
  padding: 0;
  list-style: none;
}

.logo-circle {
  display: grid;
  place-items: center;
  width: 7rem;
  height: 7rem;
  margin: 0;
  padding: 0.5rem;
  border: 2px dashed var(--purple);
  border-radius: 50%;
  background: var(--white);
  color: var(--purple-900);
  font-size: 1.0625rem;
  font-weight: 800;
  line-height: 1.1;
  text-align: center;
}

.logo-tiles__note {
  text-align: center;
}

.retailers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 12.5rem), 1fr));
  gap: var(--space-m);
  margin: 0;
  padding: 0;
  list-style: none;
}

.retailer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-s);
  margin: 0;
  padding: var(--space-l) var(--space-s);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  text-align: center;
}

.retailer h3 {
  margin: 0;
  font-size: var(--step-1);
}

.retailer .button {
  width: 100%;
  margin-top: auto;
  padding-inline: 0.75rem;
  font-size: 1rem;
}

/* Contacts */
.contacts {
  display: grid;
  gap: var(--space-m);
}

@media (min-width: 56em) {
  .contacts {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    grid-template-rows: auto 1fr;
    align-items: start;
  }

  .contact-group--main {
    grid-row: span 2;
  }
}

.contact-group {
  padding: var(--space-l);
  border-top: 5px solid var(--purple);
  border-radius: var(--radius-s);
  background: var(--white);
  box-shadow: var(--shadow);
}

.contact-group:nth-child(2) {
  border-top-color: var(--orange);
}

.contact-group:nth-child(3) {
  border-top-color: var(--blue);
}

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

.contact-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.contact-list > li {
  margin: 0;
  padding-block: var(--space-xs);
  border-bottom: 1px solid var(--line);
}

.contact-list > li:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.contact__name {
  display: block;
  color: var(--purple-900);
  font-weight: 700;
}

.contact__details {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}

.contact__details a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2rem;
}

.contact-list > .contact--emergency {
  margin-bottom: var(--space-2xs);
  padding: var(--space-s);
  border: 0;
  border-radius: var(--radius-s);
  background: var(--orange-100);
}

.contact--emergency a {
  font-size: var(--step-1);
  font-weight: 800;
}

/* Legal and simple text pages */
.prose {
  max-width: var(--measure);
}

.prose h2 {
  margin-top: var(--space-xl);
  font-size: var(--step-2);
}

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


/* 11. Video
   Click to load. Nothing is requested from YouTube until someone presses play.
   -------------------------------------------------------------------------- */

.video {
  margin: 0;
}

.video__player {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: var(--purple-900) url("/assets/img/watercolour/wash-large.svg") center / 120% auto no-repeat;
  box-shadow: var(--shadow-lift);
}

.video__play {
  --ring: var(--white);
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  width: 100%;
  padding: var(--space-s);
  border: 0;
  background: transparent;
  color: var(--white);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.video__play:focus-visible {
  outline-offset: -6px;
}

.video__play-icon {
  display: grid;
  place-items: center;
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 50%;
  background: var(--orange);
  color: var(--purple-900);
  box-shadow: 0 6px 20px rgb(0 0 0 / 0.3);
  transition: transform 0.15s ease;
}

.video__play-icon .icon {
  width: 2rem;
  height: 2rem;
  margin-left: 0.25rem;
}

.video__play:hover .video__play-icon {
  transform: scale(1.06);
}

.video__play-text {
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  background: rgb(46 26 79 / 0.88);
  line-height: 1.3;
  text-align: center;
}

.video__player.is-missing .video__play {
  cursor: default;
}

.video__player.is-missing .video__play-icon {
  background: var(--white);
  opacity: 0.7;
}

.video__player iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video__caption {
  margin-top: var(--space-xs);
  color: var(--ink-soft);
  font-size: var(--step--1);
}

.video-grid {
  display: grid;
  gap: var(--space-xl);
}

@media (min-width: 56em) {
  .video-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.video-grid h2 {
  font-size: var(--step-2);
}


/* 12. Footer
   -------------------------------------------------------------------------- */

.site-footer {
  --ring: var(--white);
  padding-block: var(--space-2xl) var(--space-l);
  background: var(--purple-900);
  color: var(--white);
}

.site-footer a {
  color: var(--white);
}

.site-footer a:hover {
  color: var(--sky);
}

.site-footer__line {
  max-width: 22ch;
  margin-bottom: var(--space-xl);
  font-size: var(--step-3);
  font-weight: 300;
  line-height: 1.2;
}

.site-footer__grid {
  display: grid;
  gap: var(--space-xl);
}

@media (min-width: 48em) {
  .site-footer__grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
  }
}

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

.site-footer__brand img {
  width: 12.5rem;
}

/* The Trust's purple logo needs a white tile to show on the dark footer. */
.trust-logo {
  display: inline-block;
  margin-top: var(--space-xs);
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-s);
  background: var(--white);
}

.trust-logo img {
  width: 10rem;
}

.site-footer__heading {
  margin-bottom: var(--space-s);
  color: var(--white);
  font-size: var(--step-1);
}

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

.footer-links > li {
  margin: 0 0 0.25rem;
}

.footer-links a {
  display: inline-block;
  padding-block: 0.3rem;
}

.site-footer__social .verify {
  display: inline-block;
  margin-top: var(--space-xs);
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-s) var(--space-l);
  margin-top: var(--space-2xl);
  padding-top: var(--space-l);
  border-top: 1px solid rgb(255 255 255 / 0.25);
  font-size: var(--step--1);
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem var(--space-m);
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-legal > li {
  margin: 0;
}

.footer-legal a {
  display: inline-block;
  padding-block: 0.3rem;
}

.site-footer__bottom p {
  margin: 0;
}


/* 13. Verify marks
   Preview only. Every one must be checked and removed before launch.
   -------------------------------------------------------------------------- */

.verify {
  padding: 0.1em 0.4em;
  border-radius: 0.2em;
  background: var(--verify-bg);
  box-shadow: 0 0 0 2px #000000;
  color: #000000;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-style: normal;
  font-weight: 700;
  letter-spacing: normal;
  line-height: 1.5;
  text-transform: none;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}


/* 14. High contrast, reduced motion and print
   -------------------------------------------------------------------------- */

@media (forced-colors: active) {
  .button,
  .menu-toggle,
  .menu-link,
  .video__play-icon,
  .pill-nav a {
    border: 2px solid ButtonText;
  }

  .placeholder {
    border-color: CanvasText;
  }

  .card:has(a:focus-visible) {
    outline-color: Highlight;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  .skip-link,
  .site-header,
  .video,
  .pill-nav,
  .site-footer__grid,
  .button-row {
    display: none !important;
  }

  body {
    color: #000000;
    font-size: 12pt;
  }

  .emergency,
  .hero,
  .page-hero,
  .section--purple,
  .quote,
  .stat,
  .callout,
  .rooms > li {
    background: none !important;
    color: #000000 !important;
  }

  .emergency {
    border: 2px solid #000000;
  }

  .page-hero::after,
  .hero__media::before {
    display: none !important;
  }

  h1,
  h2,
  h3,
  .page-hero h1,
  .hero__title {
    color: #000000 !important;
    break-after: avoid;
  }

  .section {
    padding-block: 1rem;
  }

  .site-footer {
    background: none;
    color: #000000;
  }
}
