/* ==========================================================================
   NEXG2EN CFO design system  -  single stylesheet, custom properties
   Brand derived from imgs/logo.webp: navy wordmark + green leaf/checkmark
   accent, deepened for AA. Editorial/authority register: Playfair Display
   headings + Source Serif 4 body. All colour pairings verified WCAG 2.1 AA
   (see docs/redesign-decisions.md section 9 for the computed ratios).
   ========================================================================== */

/* ---------- Fonts (self-hosted woff2, latin subset, no external CDN) ------ */
@font-face {
  font-family: 'Playfair Display'; font-style: normal; font-weight: 500;
  font-display: swap; src: url('../fonts/playfair-display-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Playfair Display'; font-style: normal; font-weight: 600;
  font-display: swap; src: url('../fonts/playfair-display-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Playfair Display'; font-style: italic; font-weight: 600;
  font-display: swap; src: url('../fonts/playfair-display-600-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Playfair Display'; font-style: normal; font-weight: 700;
  font-display: swap; src: url('../fonts/playfair-display-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Playfair Display'; font-style: normal; font-weight: 900;
  font-display: swap; src: url('../fonts/playfair-display-900.woff2') format('woff2');
}
@font-face {
  font-family: 'Source Serif 4'; font-style: normal; font-weight: 400;
  font-display: swap; src: url('../fonts/source-serif-4-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Source Serif 4'; font-style: italic; font-weight: 400;
  font-display: swap; src: url('../fonts/source-serif-4-400-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Source Serif 4'; font-style: normal; font-weight: 600;
  font-display: swap; src: url('../fonts/source-serif-4-600.woff2') format('woff2');
}

/* ---------- Design tokens ------------------------------------------------- */
:root {
  /* surfaces */
  --paper: #f8f7f3;
  --paper-2: #f1efe7;
  --surface: #ffffff;
  --line: #e2ddd0;
  --line-2: #d5cebb;

  /* text on light */
  --ink: #2d3091;        /* 10.1:1 on paper -- brand navy, from logo */
  --ink-2: #43425a;       /* 9.05:1 on paper */
  --ink-3: #5a5a72;       /* ~6.3:1 on paper */

  /* dark sections */
  --navy: #2d3091;
  --navy-dark: #1f2266;   /* deeper navy for hero/footer/CTA-band */
  --navy-line: rgba(255, 255, 255, 0.14);
  --paper-muted: #cfd0e6; /* ~9:1 on navy-dark */

  /* brand accent (lime, deepened for AA; original bright lime kept as on-dark token) */
  --accent: #506a18;          /* text/links/icons/button-fill on LIGHT surfaces (5.7:1 on paper) */
  --accent-strong: #435a14;   /* hover state, borders */
  --accent-on-dark: #a6ce3a;  /* text/links/eyebrows on DARK surfaces only (5.9:1 on navy) */
  --accent-soft: #e9edd9;     /* pale accent wash for light chips/icon tiles */

  /* type */
  --font-head: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --font-ui: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  /* fluid type scale */
  --fs-display: clamp(2.3rem, 1.4rem + 3.9vw, 3.9rem);
  --fs-h1: clamp(2rem, 1.4rem + 2.6vw, 3rem);
  --fs-h2: clamp(1.7rem, 1.35rem + 1.5vw, 2.4rem);
  --fs-h3: clamp(1.22rem, 1.08rem + 0.6vw, 1.45rem);
  --fs-lead: clamp(1.1rem, 1.02rem + 0.4vw, 1.28rem);
  --fs-body: 1.0625rem;
  --fs-small: 0.9rem;
  --fs-eyebrow: 0.78rem;

  /* spacing + shape */
  --container: 1120px;
  --container-wide: 1240px;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 18px;
  --space-section: clamp(3.5rem, 2.2rem + 5vw, 6.5rem);
  --header-h: 80px;

  --shadow-sm: 0 1px 2px rgba(31, 34, 102, 0.07), 0 2px 6px rgba(31, 34, 102, 0.05);
  --shadow: 0 6px 18px rgba(31, 34, 102, 0.09), 0 2px 6px rgba(31, 34, 102, 0.05);
  --shadow-lg: 0 18px 48px rgba(31, 34, 102, 0.16);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }

ul, ol { padding-left: 1.1em; }
strong { font-weight: 600; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.005em;
  color: var(--ink);
  text-wrap: balance;
}
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); line-height: 1.24; }
p { text-wrap: pretty; }

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

/* ---------- Skip link ---------------------------------------------------- */
.skip-link {
  position: absolute;
  left: 12px; top: -200px;
  z-index: 200;
  background: var(--navy-dark);
  color: #fff;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  font-family: var(--font-ui);
  font-weight: 600;
  transition: top 0.18s var(--ease);
}
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- Layout helpers ----------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.1rem, 0.5rem + 2.5vw, 2.2rem);
}
.container.wide { max-width: var(--container-wide); }

.section { padding-block: var(--space-section); }
.section--tight { padding-block: clamp(2.5rem, 1.8rem + 3vw, 4rem); }

.section--paper2 { background: var(--paper-2); }
.section--white { background: var(--surface); }
.section--navy {
  background: var(--navy-dark);
  color: #fff;
  background-image:
    radial-gradient(65% 85% at 88% 8%, rgba(166, 206, 58, 0.10), transparent 60%);
}
.section--navy h1, .section--navy h2, .section--navy h3 { color: #fff; }

.measure { max-width: 62ch; }
.center { text-align: center; }
.center.section-head { margin-inline: auto; }

/* ---------- Eyebrow + section heading ------------------------------------ */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-family: var(--font-ui);
  font-size: var(--fs-eyebrow);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.9rem;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 2px;
  background: var(--accent);
  display: inline-block;
}
.section--navy .eyebrow, .hero .eyebrow, .page-hero .eyebrow { color: var(--accent-on-dark); }
.section--navy .eyebrow::before, .hero .eyebrow::before, .page-hero .eyebrow::before { background: var(--accent-on-dark); }

.section-head { max-width: 58ch; margin-bottom: clamp(2rem, 1.4rem + 1.6vw, 3rem); }
/* :not(.eyebrow) so a container colour rule never overrides a component
   colour class (colour belongs to the component, not the container). */
.section-head p:not(.eyebrow) { color: var(--ink-3); font-size: var(--fs-lead); margin-top: 0.85rem; }
.section--navy .section-head p:not(.eyebrow) { color: var(--paper-muted); }

/* ledger-rule divider: signature editorial motif under a section heading,
   evoking a financial statement's double underrule. */
.ledger-rule { margin-top: 0.7rem; width: 84px; height: 5px; }
.ledger-rule::before, .ledger-rule::after { content: ""; display: block; height: 1px; }
.ledger-rule::before { background: var(--accent); margin-bottom: 2px; }
.ledger-rule::after { background: var(--line-2); }
.section--navy .ledger-rule::before { background: var(--accent-on-dark); }
.section--navy .ledger-rule::after { background: var(--navy-line); }

/* ---------- Buttons ------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  font-family: var(--font-ui);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  padding: 0.95em 1.5em;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.18s var(--ease), background-color 0.18s var(--ease),
              border-color 0.18s var(--ease), color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.btn svg { width: 1.1em; height: 1.1em; flex: none; }

.btn-primary {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: var(--navy-dark); border-color: var(--navy-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow); }

.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-2);
}
.btn-secondary:hover { background: var(--accent-soft); color: var(--ink); border-color: var(--accent); transform: translateY(-2px); }

/* on dark sections: navy-filled primary would vanish, so it flips to accent-on-dark fill with navy text */
.section--navy .btn-primary, .hero .btn-primary, .page-hero .btn-primary { background: var(--accent-on-dark); color: var(--navy-dark); border-color: var(--accent-on-dark); }
.section--navy .btn-primary:hover, .hero .btn-primary:hover, .page-hero .btn-primary:hover { background: #b8de5c; border-color: #b8de5c; color: var(--navy-dark); }
.section--navy .btn-secondary, .hero .btn-secondary, .page-hero .btn-secondary { color: #fff; border-color: rgba(255,255,255,0.4); }
.section--navy .btn-secondary:hover, .hero .btn-secondary:hover, .page-hero .btn-secondary:hover { background: rgba(255,255,255,0.1); color: #fff; border-color: #fff; }

.btn-text {
  display: inline-flex; align-items: center; gap: 0.4em;
  font-family: var(--font-ui);
  font-weight: 600; color: var(--accent); text-decoration: none;
}
.btn-text svg { width: 1em; height: 1em; transition: transform 0.18s var(--ease); }
.btn-text:hover { color: var(--accent-strong); }
.btn-text:hover svg { transform: translateX(3px); }
.section--navy .btn-text { color: var(--accent-on-dark); }
.section--navy .btn-text:hover { color: #fff; }

/* ---------- Header / nav ------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 247, 243, 0.9);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}
.brand {
  display: inline-flex; align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.35em 0.6em;
}
.brand img { height: 42px; width: auto; }

.nav-toggle {
  display: none;
  align-items: center; gap: 0.5em;
  font-family: var(--font-ui);
  background: transparent; border: 1.5px solid var(--line-2);
  border-radius: 999px; padding: 0.5em 0.9em;
  font-weight: 600; color: var(--ink); cursor: pointer;
}
.nav-toggle .bars { position: relative; width: 18px; height: 12px; }
.nav-toggle .bars span {
  position: absolute; left: 0; width: 100%; height: 2px; background: var(--ink);
  border-radius: 2px; transition: transform 0.2s var(--ease), opacity 0.2s var(--ease);
}
.nav-toggle .bars span:nth-child(1) { top: 0; }
.nav-toggle .bars span:nth-child(2) { top: 5px; }
.nav-toggle .bars span:nth-child(3) { top: 10px; }
.nav-toggle[aria-expanded="true"] .bars span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .bars span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

.nav-menu { display: flex; align-items: center; gap: 0.3rem; }
.nav-links { display: flex; align-items: center; gap: 0.1rem; list-style: none; padding: 0; margin: 0; flex-wrap: wrap; }
.nav-links a {
  display: inline-block;
  font-family: var(--font-ui);
  padding: 0.55em 0.7em;
  border-radius: var(--radius-sm);
  color: var(--ink-2);
  font-weight: 500;
  font-size: 0.96rem;
  text-decoration: none;
  transition: color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.nav-links a:hover { color: var(--ink); background: var(--accent-soft); }
.nav-links a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.nav-links a[aria-current="page"]::after {
  content: ""; display: block; height: 2px; border-radius: 2px;
  background: var(--accent); margin-top: 3px;
}
.nav-cta { margin-left: 0.5rem; padding: 0.7em 1.2em; }

/* ---------- Hero --------------------------------------------------------- */
.hero {
  position: relative;
  padding-top: clamp(2.5rem, 1.5rem + 4vw, 5rem);
  padding-bottom: clamp(2.5rem, 1.5rem + 4vw, 5rem);
  background: var(--navy-dark);
  color: #fff;
  background-image:
    radial-gradient(70% 60% at 80% 10%, rgba(166, 206, 58, 0.14), transparent 60%),
    radial-gradient(55% 55% at 8% 95%, rgba(166, 206, 58, 0.08), transparent 60%);
  overflow: hidden;
}
.hero h1 { color: #fff; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: clamp(1.5rem, 0.5rem + 3vw, 3.5rem);
}
.hero h1 { font-size: var(--fs-display); }
.hero .lead { font-size: var(--fs-lead); color: var(--paper-muted); margin-top: 1.1rem; max-width: 42ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 1.8rem; }
.hero-trust {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1.4rem;
  margin-top: 1.8rem; color: var(--paper-muted); font-size: var(--fs-small); font-family: var(--font-ui);
}
.hero-trust span { display: inline-flex; align-items: center; gap: 0.45em; }
.hero-trust svg { width: 1.05em; height: 1.05em; color: var(--accent-on-dark); }
.hero-media { position: relative; }
.hero-media img {
  width: 100%; height: auto; border-radius: var(--radius-lg);
  box-shadow: 0 24px 48px rgba(0,0,0,0.28);
}

/* page hero (inner pages: shorter, no media column) */
.page-hero {
  background: var(--navy-dark); color: #fff;
  padding-block: clamp(2.6rem, 1.9rem + 3vw, 4rem);
  background-image: radial-gradient(60% 80% at 85% 10%, rgba(166, 206, 58, 0.12), transparent 60%);
}
.page-hero h1 { color: #fff; font-size: var(--fs-h1); max-width: 26ch; }
.page-hero p.lead { color: var(--paper-muted); font-size: var(--fs-lead); margin-top: 0.9rem; max-width: 58ch; }

/* ---------- Pillars / feature grid --------------------------------------- */
.grid { display: grid; gap: clamp(1rem, 0.6rem + 1.4vw, 1.6rem); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-6 { grid-template-columns: repeat(6, 1fr); }

.pillar {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.4rem, 1.1rem + 1vw, 2rem);
  box-shadow: var(--shadow-sm);
}
.pillar .ico {
  display: inline-flex; align-items: center; justify-content: center;
  width: 52px; height: 52px; border-radius: 13px;
  background: var(--accent-soft); color: var(--accent);
  margin-bottom: 1rem;
}
.pillar .ico svg { width: 26px; height: 26px; }
.pillar h3 { margin-bottom: 0.45rem; }
.pillar p { color: var(--ink-3); }

/* ---------- Service / offering cards -------------------------------------- */
.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.4rem, 1.1rem + 1vw, 1.9rem);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), border-color 0.2s var(--ease);
  height: 100%;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--line-2); }
.card .ico {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 12px;
  background: var(--accent-soft); color: var(--accent); margin-bottom: 0.9rem;
}
.card .ico svg { width: 24px; height: 24px; }
.card h3 { font-size: 1.18rem; margin-bottom: 0.4rem; }
.card p { color: var(--ink-3); font-size: 1rem; }
.card .card-meta { margin-top: auto; padding-top: 1rem; }

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

/* ---------- Service detail groups (services page) ------------------------ */
.svc-group { margin-bottom: clamp(2.5rem, 1.8rem + 3vw, 4.5rem); }
.svc-group:last-child { margin-bottom: 0; }
.svc-group-head { display: flex; gap: 1.1rem; align-items: flex-start; margin-bottom: 1.6rem; }
.svc-group-head .ico {
  flex: none; width: 56px; height: 56px; border-radius: 15px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--navy); color: var(--accent-on-dark);
}
.svc-group-head .ico svg { width: 28px; height: 28px; }

.svc {
  scroll-margin-top: calc(var(--header-h) + 24px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 1.2rem + 1.2vw, 2.2rem);
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.1rem;
}
.svc h3 { margin-bottom: 0.5rem; }
.svc .promise { color: var(--accent-strong); font-weight: 600; margin-bottom: 0.6rem; font-family: var(--font-ui); font-size: 0.98rem; }
.svc p { color: var(--ink-3); }
.svc .whatyouget { margin-top: 1.1rem; }
.svc .whatyouget h4 {
  font-family: var(--font-ui); font-size: 0.78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-3); margin-bottom: 0.6rem;
}

/* check list */
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.55rem; }
.checklist li { position: relative; padding-left: 1.9rem; color: var(--ink-3); }
.checklist li::before {
  content: "";
  position: absolute; left: 0; top: 0.18em;
  width: 1.25rem; height: 1.25rem; border-radius: 50%;
  background: var(--accent-soft);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23506a18' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='5 12 10 17 19 7'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: center; background-size: 0.8rem;
}
.section--navy .checklist li { color: var(--paper-muted); }
.section--navy .checklist li::before {
  background-color: rgba(166, 206, 58, 0.18);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a6ce3a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='5 12 10 17 19 7'/%3E%3C/svg%3E");
}

/* ---------- Org chart (signature element: real delivery-tier diagram) ---- */
.org-chart { display: grid; gap: 0.9rem; }
.org-tier {
  display: grid;
  grid-template-columns: 13rem 1fr;
  align-items: stretch;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.org-tier-label {
  background: var(--navy-dark);
  color: #fff;
  display: flex; flex-direction: column; justify-content: center;
  padding: 1.2rem 1.4rem;
}
.org-tier-label .k {
  font-family: var(--font-ui); font-size: 0.74rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-on-dark);
}
.org-tier-label .t { font-family: var(--font-head); font-size: 1.15rem; margin-top: 0.3rem; color: #fff; }
.org-tier-nodes {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.7rem;
  padding: 1.2rem 1.4rem;
}
.org-node {
  font-family: var(--font-ui); font-size: 0.92rem; font-weight: 600;
  color: var(--ink); background: var(--accent-soft);
  border: 1px solid var(--line-2);
  padding: 0.5em 1em; border-radius: 999px;
}
.org-connector { display: flex; justify-content: flex-start; padding-left: 6.4rem; }
.org-connector svg { width: 1.4rem; height: 1.4rem; color: var(--line-2); }

/* ---------- Process steps ------------------------------------------------ */
.steps { counter-reset: step; display: grid; gap: clamp(1rem, 0.6rem + 1.4vw, 1.6rem); }
.step {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.4rem, 1.1rem + 1vw, 1.9rem);
  box-shadow: var(--shadow-sm);
}
.step .num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--navy); color: var(--accent-on-dark);
  font-family: var(--font-head); font-weight: 700; font-size: 1.15rem;
  margin-bottom: 0.9rem;
}
.step h3 { font-size: 1.18rem; margin-bottom: 0.35rem; }
.step p { color: var(--ink-3); font-size: 1rem; }

/* ---------- Trust / standards band --------------------------------------- */
.standards { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.4rem 2rem; }
.standards li { display: flex; gap: 0.85rem; align-items: flex-start; }
.standards .ico {
  flex: none; width: 42px; height: 42px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(166, 206, 58, 0.16); color: var(--accent-on-dark);
}
.standards .ico svg { width: 22px; height: 22px; }
.standards h3 { font-size: 1.08rem; margin-bottom: 0.2rem; color: #fff; }
.standards p { color: var(--paper-muted); font-size: 0.98rem; }

/* stat row */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.stat { text-align: center; }
.stat .n { font-family: var(--font-head); font-weight: 700; font-size: clamp(1.9rem, 1.4rem + 1.7vw, 2.7rem); color: var(--accent-on-dark); line-height: 1; }
.stat .l { color: var(--paper-muted); margin-top: 0.4rem; font-size: 0.95rem; font-family: var(--font-ui); }
.section--white .stat .n, .section--paper2 .stat .n { color: var(--accent-strong); }
.section--white .stat .l, .section--paper2 .stat .l { color: var(--ink-3); }

/* ---------- Testimonial pull-quotes (editorial signature) ---------------- */
.quotes { display: grid; gap: 1.4rem; }
.quote {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 1.1rem + 1vw, 2rem);
  box-shadow: var(--shadow-sm);
}
.quote p.text {
  font-family: var(--font-head); font-style: italic; font-weight: 500;
  font-size: 1.14rem; line-height: 1.5; color: var(--ink);
}
.quote .cite { margin-top: 1rem; font-family: var(--font-ui); font-size: 0.92rem; color: var(--ink-3); }
.quote .cite .name { font-weight: 700; color: var(--ink); display: block; }

/* client logo strip */
.client-strip { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.1rem; align-items: center; }
.client-strip li {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center; padding: 1rem 0.8rem; min-height: 84px;
}
.client-strip img { max-height: 46px; width: auto; max-width: 100%; filter: grayscale(20%); }
.client-strip .name { font-family: var(--font-ui); font-weight: 600; font-size: 0.92rem; color: var(--ink-2); text-align: center; }

/* industry cards with photo */
.industry-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-sm); height: 100%; display: flex; flex-direction: column;
}
.industry-card .photo { aspect-ratio: 4/3; overflow: hidden; background: var(--paper-2); }
.industry-card .photo img { width: 100%; height: 100%; object-fit: cover; }
.industry-card .body { padding: 1.3rem 1.4rem 1.5rem; flex: 1; display: flex; flex-direction: column; }
.industry-card h3 { margin-bottom: 0.4rem; }
.industry-card p { color: var(--ink-3); font-size: 0.98rem; }

/* ---------- FAQ accordion ------------------------------------------------ */
.faq { display: grid; gap: 0.8rem; max-width: 820px; }
.faq details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.faq details[open] { border-color: var(--line-2); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.15rem 1.3rem;
  font-family: var(--font-head);
  font-weight: 600; font-size: 1.1rem; color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .chev {
  flex: none; width: 1.4rem; height: 1.4rem; color: var(--accent);
  transition: transform 0.2s var(--ease);
}
.faq details[open] summary .chev { transform: rotate(180deg); }
.faq .answer { padding: 0 1.3rem 1.25rem; color: var(--ink-3); }
.faq .answer p + p { margin-top: 0.7rem; }

/* ---------- Contact -------------------------------------------------------*/
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.4rem, 0.8rem + 2vw, 2.2rem); align-items: stretch; }
.contact-card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: clamp(1.4rem, 1.1rem + 1vw, 1.9rem);
  box-shadow: var(--shadow-sm); display: flex; flex-direction: column;
}
.contact-card h3 { margin-bottom: 0.4rem; }
.contact-card p.desc { color: var(--ink-3); font-size: 0.98rem; margin-bottom: 1.1rem; }
.contact-card .btn { margin-top: auto; align-self: flex-start; }

.contact-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.2rem; }
.contact-list li { display: flex; gap: 0.9rem; align-items: flex-start; }
.contact-list .ico {
  flex: none; width: 46px; height: 46px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--accent-soft); color: var(--accent);
}
.contact-list .ico svg { width: 23px; height: 23px; }
.contact-list .k { font-family: var(--font-ui); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-3); font-weight: 700; }
.contact-list .v { font-size: 1.05rem; font-weight: 600; font-family: var(--font-ui); }
.contact-list .v a { font-weight: 600; }
.privacy-note { font-size: 0.9rem; color: var(--ink-3); margin-top: 1.3rem; font-family: var(--font-ui); }

/* ---------- Breadcrumb ---------------------------------------------------- */
.breadcrumb { padding-block: 1.1rem; border-bottom: 1px solid var(--line); background: var(--paper-2); }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem; padding: 0; margin: 0; font-size: 0.9rem; font-family: var(--font-ui); }
.breadcrumb li { display: flex; align-items: center; gap: 0.5rem; color: var(--ink-3); }
.breadcrumb li + li::before { content: "/"; color: var(--line-2); }
.breadcrumb a { color: var(--ink-2); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); text-decoration: underline; }
.breadcrumb [aria-current="page"] { color: var(--ink); font-weight: 700; }

/* ---------- CTA strip ------------------------------------------------------*/
.cta-band { text-align: center; }
.cta-band h2 { max-width: 24ch; margin-inline: auto; }
.cta-band p:not(.eyebrow) { max-width: 54ch; margin: 1rem auto 0; color: var(--paper-muted); font-size: var(--fs-lead); }
.cta-band .hero-actions { justify-content: center; }
.section--white .cta-band p:not(.eyebrow), .section--paper2 .cta-band p:not(.eyebrow) { color: var(--ink-3); }

/* ---------- Footer --------------------------------------------------------*/
.site-footer { background: var(--navy-dark); color: var(--paper-muted); padding-block: clamp(3rem, 2rem + 3vw, 4.5rem) 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 2rem; }
.footer-brand .brand { margin-bottom: 1rem; background: var(--surface); border-color: var(--surface); }
.footer-brand .brand img { height: 70px; }
.footer-brand p { color: var(--paper-muted); max-width: 34ch; font-size: 0.97rem; }
.footer-contact { list-style: none; padding: 0; margin: 1.1rem 0 0; display: grid; gap: 0.5rem; font-size: 0.95rem; font-family: var(--font-ui); }
.footer-contact a { color: var(--accent-on-dark); text-decoration: none; }
.footer-contact a:hover { color: #fff; text-decoration: underline; }
.site-footer h4 { font-family: var(--font-ui); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; color: #fff; margin-bottom: 1rem; }
.footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; font-family: var(--font-ui); }
.footer-links a { color: var(--paper-muted); text-decoration: none; }
.footer-links a:hover { color: #fff; text-decoration: underline; }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.8rem;
  margin-top: clamp(2rem, 1.4rem + 2vw, 3rem); padding-top: 1.6rem;
  border-top: 1px solid var(--navy-line); font-size: 0.88rem; color: var(--paper-muted); font-family: var(--font-ui);
}
.footer-bottom a { color: var(--paper-muted); }
.footer-bottom a:hover { color: #fff; }

/* ---------- Floating contact button --------------------------------------*/
.fab-group { position: fixed; right: clamp(1rem, 0.5rem + 1vw, 1.6rem); bottom: clamp(1rem, 0.5rem + 1vw, 1.6rem); z-index: 90; display: flex; flex-direction: column; gap: 0.6rem; align-items: flex-end; }
.fab {
  display: inline-flex; align-items: center; gap: 0.5em;
  font-family: var(--font-ui);
  background: var(--navy); color: #fff;
  border: 1.5px solid var(--navy);
  padding: 0.85em 1.2em; border-radius: 999px;
  font-weight: 600; text-decoration: none;
  box-shadow: var(--shadow-lg);
  transition: transform 0.18s var(--ease), background-color 0.18s var(--ease);
}
.fab:hover { transform: translateY(-2px); background: var(--navy-dark); color: #fff; }
.fab svg { width: 1.2em; height: 1.2em; }
.fab.fab-whatsapp { background: var(--accent); border-color: var(--accent); }
.fab.fab-whatsapp:hover { background: var(--accent-strong); }

/* ---------- 404 -----------------------------------------------------------*/
.errorpage { min-height: 70vh; display: grid; place-items: center; text-align: center; padding-block: 4rem; background: var(--navy-dark); color: #fff; }
.errorpage .code { font-family: var(--font-head); font-weight: 700; font-size: clamp(4rem, 2rem + 12vw, 8rem); color: var(--accent-on-dark); line-height: 1; }
.errorpage h1 { color: #fff; margin-top: 0.5rem; }
.errorpage p { color: var(--paper-muted); margin-top: 0.8rem; max-width: 46ch; margin-inline: auto; }
.errorpage .btn { margin-top: 1.6rem; }

/* ---------- Utilities -------------------------------------------------------*/
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.lead { font-size: var(--fs-lead); color: var(--ink-3); }
.prose p + p { margin-top: 1rem; }
.prose h2 { margin-top: 2.4rem; margin-bottom: 0.7rem; }
.prose h3 { margin-top: 1.8rem; margin-bottom: 0.5rem; }
.prose ul { margin-top: 0.6rem; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
  opacity: 0;
}
.tag {
  display: inline-block; font-family: var(--font-ui); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--accent-strong);
  background: var(--accent-soft); padding: 0.35em 0.7em; border-radius: 999px;
}
.placeholder-note {
  display: inline-flex; align-items: center; gap: 0.5em;
  font-family: var(--font-ui); font-size: 0.85rem; color: var(--ink-3);
  border: 1px dashed var(--line-2); border-radius: var(--radius-sm);
  padding: 0.6em 0.9em; margin-top: 0.8rem;
}

/* ---------- Responsive -----------------------------------------------------*/
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .client-strip { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 860px) {
  :root { --header-h: 68px; }
  .nav-toggle { display: inline-flex; }
  .nav-menu {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0.4rem;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: 1rem clamp(1.1rem, 0.5rem + 2.5vw, 2.2rem) 1.4rem;
    display: none;
  }
  .nav-menu[data-open="true"] { display: flex; }
  .nav-links { flex-direction: column; align-items: stretch; gap: 0.15rem; }
  .nav-links a { padding: 0.8em 0.6em; font-size: 1.03rem; }
  .nav-links a[aria-current="page"]::after { display: none; }
  .nav-cta { margin: 0.5rem 0 0; width: 100%; }

  /* JS off: the toggle cannot work, so show the menu as a stacked list. */
  .no-js .nav-toggle { display: none; }
  .no-js .nav-menu {
    display: flex; position: static;
    box-shadow: none; border-bottom: none;
    padding: 0.6rem 0 1rem;
  }

  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { order: -1; max-width: 460px; margin-inline: auto; }
  .contact-grid { grid-template-columns: 1fr; }
  .grid-4, .grid-6 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .org-tier { grid-template-columns: 1fr; }
  .org-tier-label { padding: 1rem 1.2rem; }
  .org-connector { padding-left: 1.4rem; }
}

@media (max-width: 720px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; gap: 1.6rem; }
  .svc-group-head { flex-direction: column; gap: 0.8rem; }
  .client-strip { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 520px) {
  .grid-4, .grid-6 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .btn { width: 100%; }
  .hero-actions .btn, .cta-band .btn { width: 100%; }
  .fab span { display: none; }
  .fab { padding: 0.9em; }
}

/* ---------- Motion preferences ---------------------------------------------*/
@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;
    scroll-behavior: auto !important;
  }
}

/* reveal-on-scroll: fail-safe. Content is visible by default; JS adds
   .reveal--armed to hide-then-reveal, so a JS failure never hides content. */
.reveal--armed { opacity: 0; transform: translateY(14px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal--armed.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal--armed { opacity: 1 !important; transform: none !important; } }
