/* ==========================================================================
   Pascoe Business Systems - site stylesheet

   The palette comes from the approved brand pack
   (06_COLOUR_THEME/PBS_THEME_TOKENS.json): navy #071E3D and accent #F5A516.

   Two surface systems, matching the two approved logo systems:
     .surface-light  light ground, navy type, amber used sparingly
     .surface-dark   navy ground, light type, the metallic logo

   Amber is never used for small text on white: #F5A516 on #FFFFFF is about
   2.1:1, well under the WCAG AA threshold. It carries buttons (with navy
   text), rules, marks and large display accents instead.
   ========================================================================== */

/* --------------------------------------------------------------- tokens */
:root {
  --navy: #071e3d;
  --navy-800: #0a2750;
  --navy-700: #0d3060;
  --navy-600: #14417d;
  --navy-050: #eef2f8;

  --amber: #f5a516;
  --amber-700: #9c6100; /* 5.09:1 on white, 4.83:1 on the tint - AA for text */
  --amber-050: #fff6e4;

  --ink: #0f1e33;
  --ink-muted: #4a5a70;
  --ink-faint: #5c6a7c; /* 5.52:1 on white, 5.23:1 on the tint */

  --paper: #ffffff;
  --paper-tint: #f7f9fc;
  --line: #dfe5ee;
  --line-strong: #c6d0de;

  --focus: #14417d;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;

  --shadow-sm: 0 1px 2px rgba(7, 30, 61, 0.06), 0 1px 3px rgba(7, 30, 61, 0.08);
  --shadow: 0 10px 30px rgba(7, 30, 61, 0.08);
  --shadow-lg: 0 24px 60px rgba(7, 30, 61, 0.16);

  --measure: 68ch;
  --gutter: clamp(20px, 5vw, 48px);
  --section-y: clamp(56px, 9vw, 112px);

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

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

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

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

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

/* ----------------------------------------------------------- typography */
h1,
h2,
h3,
h4 {
  color: var(--navy);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.1rem, 1.3rem + 3.4vw, 3.6rem);
  font-weight: 800;
}

h2 {
  font-size: clamp(1.6rem, 1.15rem + 1.9vw, 2.4rem);
  font-weight: 800;
}

h3 {
  font-size: clamp(1.15rem, 1rem + 0.7vw, 1.4rem);
  font-weight: 700;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1.1em;
  max-width: var(--measure);
}

a {
  color: var(--navy-600);
  text-underline-offset: 0.18em;
  text-decoration-thickness: from-font;
}

a:hover {
  color: var(--amber-700);
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.surface-dark :focus-visible {
  outline-color: var(--amber);
}

::selection {
  background: var(--amber);
  color: var(--navy);
}

.eyebrow {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-700);
  margin: 0 0 0.9em;
}

.surface-dark .eyebrow {
  color: var(--amber);
}

.lead {
  font-size: clamp(1.05rem, 1rem + 0.4vw, 1.25rem);
  color: var(--ink-muted);
}

.surface-dark .lead {
  color: #c4d0e0;
}

.small {
  font-size: 0.92rem;
  color: var(--ink-faint);
}

/* ------------------------------------------------------------- surfaces */
.surface-light {
  background: var(--paper);
  color: var(--ink);
}

.surface-tint {
  background: var(--paper-tint);
  color: var(--ink);
}

.surface-dark {
  background: var(--navy);
  color: #e8eef7;
}

.surface-dark h1,
.surface-dark h2,
.surface-dark h3,
.surface-dark h4 {
  color: #ffffff;
}

.surface-dark a {
  color: var(--amber);
}

.surface-dark a:hover {
  color: #ffc85a;
}

/* --------------------------------------------------------------- layout */
.wrap {
  width: 100%;
  max-width: 1160px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

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

.section--tight {
  padding-block: clamp(40px, 6vw, 72px);
}

.stack > * + * {
  margin-top: 1rem;
}

.grid {
  display: grid;
  gap: clamp(18px, 2.6vw, 30px);
}

.grid--2 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

.grid--3 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}

.split {
  display: grid;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
  grid-template-columns: 1fr;
}

@media (min-width: 880px) {
  .split {
    grid-template-columns: 1.05fr 0.95fr;
  }

  .split--reverse > :first-child {
    order: 2;
  }
}

.section-head {
  max-width: 62ch;
  margin-bottom: clamp(28px, 4vw, 48px);
}

/* --------------------------------------------------------------- header */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--navy);
  color: #fff;
  padding: 12px 18px;
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 700;
}

.skip-link:focus {
  left: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 76px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
  padding: 6px 0;
}

.brand-link img {
  width: auto;
  height: 52px;
}

/* Below 560px the small mark is served instead of the full lockup, and it is
   square rather than 3.1:1, so it needs its own size. */
@media (max-width: 560px) {
  .brand-link img {
    height: 44px;
  }
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  color: var(--navy);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 10px 14px;
  cursor: pointer;
}

.nav-toggle__bars {
  display: grid;
  gap: 4px;
  width: 18px;
}

.nav-toggle__bars span {
  display: block;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
}

.site-nav ul {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 30px);
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a:not(.btn) {
  display: inline-block;
  color: var(--navy);
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
}

.site-nav a:not(.btn):hover {
  border-bottom-color: var(--amber);
  color: var(--navy);
}

.site-nav a:not(.btn)[aria-current="page"] {
  border-bottom-color: var(--amber);
}

/* The navigation button keeps its own shape and a comfortable target height. */
.site-nav .btn {
  min-height: 44px;
  padding-block: 10px;
}

/* Sign in sits between the marketing navigation and the enquiry button. It is
   an existing-customer action, so it reads as quieter than the call to action
   but heavier than a page link. */
.site-nav__signin {
  font-weight: 700;
}

.site-nav__signin::after {
  content: "";
  display: inline-block;
  width: 0.42em;
  height: 0.42em;
  margin-left: 0.5em;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: translateY(-0.1em) rotate(45deg);
}

@media (max-width: 880px) {
  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: 8px var(--gutter) 20px;
  }

  .site-nav[data-open="true"] {
    display: block;
  }

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

  .site-nav li + li {
    border-top: 1px solid var(--line);
  }

  .site-nav a:not(.btn) {
    padding: 15px 2px;
    border-bottom: none;
    border-left: 3px solid transparent;
    padding-left: 12px;
  }

  .site-nav a:not(.btn)[aria-current="page"] {
    border-left-color: var(--amber);
    border-bottom-color: transparent;
  }

  .site-nav .btn {
    margin-top: 14px;
    justify-content: center;
    border-left: none;
  }
}

/* -------------------------------------------------------------- buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.12s ease, background-color 0.16s ease,
    border-color 0.16s ease, color 0.16s ease;
}

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

.btn--primary,
a.btn--primary,
.surface-dark a.btn--primary {
  background: var(--navy);
  border-color: var(--navy);
  color: #ffffff;
}

.btn--primary:hover,
a.btn--primary:hover,
.surface-dark a.btn--primary:hover {
  background: var(--navy-700);
  border-color: var(--navy-700);
  color: #ffffff;
}

/* On a navy section a navy button would disappear, so it borrows the light
   outline treatment instead. */
.surface-dark a.btn--primary,
.surface-dark .btn--primary {
  border-color: rgba(255, 255, 255, 0.5);
}

.btn--accent,
a.btn--accent,
.surface-dark a.btn--accent {
  background: var(--amber);
  border-color: var(--amber);
  color: var(--navy);
}

.btn--accent:hover,
a.btn--accent:hover,
.surface-dark a.btn--accent:hover {
  background: #ffb733;
  border-color: #ffb733;
  color: var(--navy);
}

.btn--ghost {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--navy);
}

.btn--ghost:hover {
  border-color: var(--navy);
  color: var(--navy);
}

.surface-dark .btn--ghost,
.surface-dark a.btn--ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.55);
  color: #ffffff;
}

.surface-dark .btn--ghost:hover,
.surface-dark a.btn--ghost:hover {
  border-color: var(--amber);
  color: var(--amber);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 26px;
}

/* ----------------------------------------------------------------- hero */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(56px, 8vw, 104px);
}

.hero::after {
  /* A single amber rule, echoing the rules in the logo lockup. */
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--amber) 0%,
    var(--amber) 22%,
    rgba(245, 165, 22, 0) 70%
  );
}

.hero__logo {
  width: min(420px, 78%);
  margin-bottom: clamp(24px, 3vw, 36px);
}

.hero .lead {
  max-width: 56ch;
}

.hero-panel {
  background-color: var(--navy);
  background-image: linear-gradient(180deg, var(--navy-800) 0%, var(--navy) 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3vw, 34px);
  box-shadow: var(--shadow-lg);
}

.hero-panel__title {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
  margin: 0 0 18px;
}

.flow-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
  counter-reset: flow;
}

.flow-list li {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: baseline;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: #d8e2f0;
  font-size: 0.98rem;
}

.flow-list li:last-child {
  border-bottom: none;
}

.flow-list li::before {
  counter-increment: flow;
  content: counter(flow, decimal-leading-zero);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  color: var(--amber);
}

.flow-list strong {
  color: #ffffff;
  font-weight: 700;
}

/* ---------------------------------------------------------------- cards */
.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(20px, 2.4vw, 28px);
  box-shadow: var(--shadow-sm);
  height: 100%;
}

.card h3 {
  margin-top: 0;
}

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

.card--accent {
  border-top: 3px solid var(--amber);
}

.surface-dark .card {
  background: var(--navy-800);
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: none;
  color: #d8e2f0;
}

.card__mark {
  width: 40px;
  height: 40px;
  margin-bottom: 16px;
}

/* ------------------------------------------------------------- features */
.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.feature-list li {
  position: relative;
  padding-left: 30px;
  max-width: var(--measure);
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 14px;
  height: 3px;
  border-radius: 2px;
  background: var(--amber);
}

/* ----------------------------------------------------------- modules */
.module-grid {
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

.module {
  background: var(--paper);
  padding: 22px;
}

.module h3 {
  font-size: 1.02rem;
  margin-bottom: 0.4em;
}

.module p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--ink-muted);
}

/* ----------------------------------------------------------------- CTA */
.cta {
  position: relative;
  overflow: hidden;
}

.cta__inner {
  display: grid;
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
  grid-template-columns: 1fr;
}

@media (min-width: 820px) {
  .cta__inner {
    grid-template-columns: 1.2fr 0.8fr;
  }
}

.cta__logo {
  width: min(360px, 100%);
  justify-self: start;
}

@media (min-width: 820px) {
  .cta__logo {
    justify-self: end;
  }
}

/* ---------------------------------------------------------------- forms */
.form-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

.field {
  display: block;
}

.field--full {
  grid-column: 1 / -1;
}

.field label {
  display: block;
  font-weight: 700;
  font-size: 0.94rem;
  color: var(--navy);
  margin-bottom: 7px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

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

.field .hint {
  display: block;
  margin-top: 7px;
  font-size: 0.88rem;
  color: var(--ink-faint);
}

.field .error {
  display: block;
  margin-top: 7px;
  font-size: 0.9rem;
  font-weight: 600;
  color: #b3261e;
}

.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"],
.field select[aria-invalid="true"] {
  border-color: #b3261e;
  background: #fff8f7;
}

.form-status {
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  background: var(--paper-tint);
  font-weight: 600;
}

.form-status[data-tone="error"] {
  border-color: #e6b4b0;
  background: #fff8f7;
  color: #8c1d18;
}

.form-status[data-tone="success"] {
  border-color: #9fcbb0;
  background: #f2fbf5;
  color: #14532d;
}

/* -------------------------------------------------------------- contact */
.contact-card {
  border: 1px solid var(--line);
  border-left: 3px solid var(--amber);
  border-radius: var(--radius);
  padding: clamp(20px, 2.4vw, 28px);
  background: var(--paper);
}

.contact-card dt {
  font-weight: 700;
  color: var(--navy);
  font-size: 0.86rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 18px;
}

.contact-card dt:first-of-type {
  margin-top: 0;
}

.contact-card dd {
  margin: 4px 0 0;
}

/* --------------------------------------------------------------- footer */
.site-footer {
  background: var(--navy);
  color: #c4d0e0;
  padding-block: clamp(44px, 6vw, 72px) 28px;
}

.site-footer h2 {
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 1.1em;
}

.site-footer__grid {
  display: grid;
  gap: clamp(28px, 4vw, 52px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
}

.site-footer__brand img {
  width: 240px;
  margin-bottom: 18px;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.site-footer a {
  color: #d8e2f0;
  text-decoration: none;
}

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

.site-footer__base {
  margin-top: clamp(32px, 4vw, 52px);
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  justify-content: space-between;
  font-size: 0.88rem;
  color: #9fb0c6;
}

/* ---------------------------------------------------------------- prose */
.prose h2 {
  margin-top: 1.8em;
}

.prose h3 {
  margin-top: 1.5em;
}

.prose ul,
.prose ol {
  max-width: var(--measure);
  padding-left: 1.3em;
}

.prose li {
  margin-bottom: 0.5em;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.4em 0;
  font-size: 0.96rem;
}

.prose th,
.prose td {
  text-align: left;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.prose th {
  color: var(--navy);
  background: var(--paper-tint);
}

.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

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

.centre {
  text-align: center;
}

.centre p,
.centre .lead {
  margin-inline: auto;
}

.rule {
  border: none;
  border-top: 1px solid var(--line);
  margin: clamp(32px, 5vw, 56px) 0;
}

.surface-dark .rule {
  border-top-color: rgba(255, 255, 255, 0.16);
}

/* ------------------------------------------------------------ 404 page */
.status-page {
  min-height: 60vh;
  display: grid;
  place-items: center;
  text-align: center;
}

.status-page__code {
  font-size: clamp(3.4rem, 2rem + 6vw, 6rem);
  font-weight: 800;
  color: var(--navy);
  line-height: 1;
  margin: 0 0 0.35em;
  letter-spacing: -0.03em;
}

.status-page__code::after {
  content: "";
  display: block;
  width: 84px;
  height: 4px;
  margin: 0.18em auto 0;
  border-radius: 2px;
  background: var(--amber);
}

/* ---------------------------------------------------- no JavaScript ----- */
/*
 * Below 880px the navigation is hidden and revealed by the Menu button. With
 * JavaScript disabled that button does nothing, so the site had no navigation
 * at all on a phone - every page reachable only by typing an address.
 *
 * The <noscript> block in each page's head enables this class, which shows the
 * navigation as a plain list and hides the button that cannot work.
 */
.no-js .nav-toggle {
  display: none !important;
}

@media (max-width: 880px) {
  .no-js .site-nav {
    display: block;
    position: static;
    box-shadow: none;
    border-bottom: none;
    padding: 0 0 12px;
  }

  .no-js .site-header__inner {
    flex-wrap: wrap;
  }
}

/* --------------------------------------------------------------- print --- */
/*
 * Prospects do print these pages, usually the product and platform ones to put
 * in front of a colleague. Navigation, buttons and the footer are noise on
 * paper, and dark sections waste an entire cartridge.
 */
@media print {
  .site-header,
  .site-footer,
  .btn,
  .btn-row,
  .skip-link,
  .nav-toggle {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 11pt;
  }

  .surface-dark,
  .surface-tint,
  .hero-panel,
  .card {
    background: #fff !important;
    color: #000 !important;
    box-shadow: none !important;
    border-color: #999 !important;
  }

  .surface-dark h1,
  .surface-dark h2,
  .surface-dark h3,
  .surface-dark .lead,
  .flow-list li,
  .flow-list strong {
    color: #000 !important;
  }

  .section {
    padding-block: 12pt;
    break-inside: avoid;
  }

  h1,
  h2,
  h3 {
    break-after: avoid;
  }

  /* A printed page cannot be clicked, so say where the link went. */
  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 9pt;
    color: #444;
  }
}
