/* WSOne public site. William Stobart & Son brand, values from
   wsd-design-system/packages/tokens/src/tokens.ts. Plain CSS, no build step. */

/* Montserrat, the brand's sanctioned fallback typeface, self-hosted (SIL OFL):
   no third-party font request, as the privacy policy promises. Two weights. */
@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/montserrat-400.woff2") format("woff2");
}
@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/montserrat-700.woff2") format("woff2");
}

:root {
  --ws-50: #eff8fe;
  --ws-400: #32b4e9;
  --ws-500: #004b96;
  --ws-600: #003c7a;
  --ws-900: #102166;
  --brand-gray: #e5e5e1;
  --white: #ffffff;
  --black: #000000;
  --gray-500: #64748b;

  --font-sans: "Montserrat", system-ui, sans-serif;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;

  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.25rem;
  --sp-6: 1.5rem;
  --sp-8: 2rem;
  --sp-10: 2.5rem;
  --sp-12: 3rem;

  --top-bar: 3.5rem;
  --tap: 2.75rem;
  --cta: 3.5rem;
  --radius-md: 0.375rem;
  --radius-lg: 0.5rem;
  --radius-full: 9999px;
  --transition-fast: 150ms ease;

  --container: 48rem;
  --measure: 42rem;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--white);
  color: var(--black);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

main { flex: 1 0 auto; }

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

h1, h2, h3 { margin: 0; font-weight: 700; line-height: 1.2; }
p { margin: 0; }

a {
  color: var(--ws-500);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover { text-decoration-thickness: 2px; }

:focus-visible { outline: 3px solid var(--ws-900); outline-offset: 3px; }
.hero :focus-visible,
.site-footer :focus-visible { outline-color: var(--white); }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--sp-4);
}

.skip-link {
  position: absolute;
  left: var(--sp-2);
  top: -10rem;
  z-index: 10;
  padding: var(--sp-3) var(--sp-4);
  background: var(--white);
  color: var(--ws-900);
  font-weight: 700;
}
.skip-link:focus { top: var(--sp-2); }

/* Header: white bar, full-colour icon logo, two-colour brand stripe */
.site-header { position: relative; padding-bottom: 4px; background: var(--white); }
.site-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--ws-500) 0 78%, var(--white) 78% 79%, var(--ws-400) 79% 100%);
}
.header-inner {
  height: var(--top-bar);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; min-height: var(--tap); }
.brand img { width: 64px; }
.site-nav ul {
  list-style: none;
  margin: 0 calc(-1 * var(--sp-3)) 0 0;
  padding: 0;
  display: flex;
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  color: var(--ws-500);
  font-weight: 700;
  text-decoration: none;
}
.site-nav a:hover { text-decoration: underline; }
.site-nav a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--ws-500); }

/* Hero: cobalt band, as the app bar */
.hero { background: var(--ws-900); color: var(--white); padding-block: var(--sp-8) var(--sp-10); }
.eyebrow {
  margin-bottom: var(--sp-2);
  color: var(--ws-400);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.hero h1 { margin-bottom: var(--sp-3); font-size: var(--text-3xl); line-height: 1.15; }
.lede { max-width: 34ch; font-size: var(--text-lg); line-height: 1.5; }

/* Install cards */
.install { display: grid; gap: var(--sp-4); margin-top: var(--sp-6); }
.store-card {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  padding: var(--sp-5);
  background: var(--white);
  border: 2px solid var(--ws-500);
  border-radius: var(--radius-lg);
}
.store-card h2 { color: var(--ws-500); font-size: var(--text-xl); }
.store-card--soon { background: var(--brand-gray); border-color: var(--brand-gray); }
.soon { color: var(--ws-900); font-size: var(--text-lg); font-weight: 700; }

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: var(--cta);
  padding: var(--sp-2) var(--sp-5);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: var(--text-base);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color var(--transition-fast);
}
.btn-primary { background: var(--ws-500); color: var(--white); }
.btn-primary:hover,
.btn-primary:active { background: var(--ws-600); }
.btn-secondary { min-height: 3rem; background: var(--white); color: var(--ws-500); border-color: var(--ws-500); }
.btn-secondary:hover,
.btn-secondary:active { background: var(--ws-50); }

.qr {
  display: none;
  margin: var(--sp-2) 0 0;
  padding-top: var(--sp-4);
  border-top: 1px solid var(--brand-gray);
  text-align: center;
}
.qr img { width: 160px; height: 160px; margin: 0 auto var(--sp-3); }
.qr figcaption { font-size: var(--text-sm); line-height: 1.5; }

/* PIN callout: cobalt on light blue (6.2:1). White on light blue fails. */
.callout {
  margin-top: var(--sp-8);
  padding: var(--sp-5);
  background: var(--ws-400);
  color: var(--ws-900);
  border-radius: var(--radius-lg);
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1.3;
}

.section { margin-top: var(--sp-10); }
.section h2 { margin-bottom: var(--sp-4); color: var(--ws-900); font-size: var(--text-2xl); }

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--sp-5);
  counter-reset: step;
}
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 2.5rem 1fr;
  gap: var(--sp-4);
  align-items: start;
  font-size: var(--text-lg);
  line-height: 1.45;
}
.steps li::before {
  content: counter(step);
  /* biome-ignore lint/suspicious/noDuplicateProperties: fallback for browsers without content alt text */
  content: counter(step) / "";
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-full);
  background: var(--ws-500);
  color: var(--white);
  font-weight: 700;
  line-height: 1;
}
.steps li > span { padding-top: 0.45rem; }

.note { margin-top: var(--sp-6); padding-top: var(--sp-4); border-top: 1px solid var(--brand-gray); }

.help { margin-bottom: var(--sp-12); }
.help p { margin-bottom: var(--sp-4); font-size: var(--text-lg); }

/* Footer */
.site-footer { background: var(--ws-900); color: var(--white); padding-block: var(--sp-4) var(--sp-8); font-size: var(--text-sm); }
.site-footer a { color: var(--white); }
.footer-links { list-style: none; margin: 0 0 var(--sp-2); padding: 0; display: flex; flex-wrap: wrap; gap: 0 var(--sp-6); }
.footer-links a { display: inline-flex; align-items: center; min-height: var(--tap); font-weight: 700; }

/* Privacy and support */
.page { padding-block: var(--sp-8) var(--sp-12); }
.prose { max-width: var(--measure); }
.prose h1 { margin-bottom: var(--sp-3); color: var(--ws-900); font-size: var(--text-3xl); line-height: 1.15; }
.prose h2 { margin: var(--sp-8) 0 var(--sp-2); color: var(--ws-900); font-size: var(--text-xl); }
.prose h3 { margin: var(--sp-6) 0 var(--sp-1); font-size: var(--text-lg); line-height: 1.35; }
.prose p, .prose li { margin: var(--sp-2) 0; }
.prose ul { margin: var(--sp-2) 0; padding-left: var(--sp-5); }
.prose a { overflow-wrap: anywhere; }
.meta { color: var(--gray-500); font-size: var(--text-sm); }
.panel { margin-top: var(--sp-6); padding: var(--sp-5); background: var(--brand-gray); border-radius: var(--radius-lg); }
.panel h2 { margin-top: 0; }

@media (min-width: 48rem) {
  .container { padding-inline: var(--sp-6); }
  .install { grid-template-columns: 1fr 1fr; margin-top: var(--sp-8); }
  .steps { grid-template-columns: repeat(3, 1fr); gap: var(--sp-6); }
  .steps li { grid-template-columns: 1fr; gap: var(--sp-3); }
  .steps li > span { padding-top: 0; }
  .help .btn { display: inline-flex; width: auto; }
}

/* QR only where a phone camera can scan it: a computer with a mouse */
@media (min-width: 48rem) and (hover: hover) and (pointer: fine) {
  .qr { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
