/* ==========================================================================
   Z-Axiss Design System
   Brand direction retained (deep teal + sky accent); everything else rebuilt.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Tokens
   -------------------------------------------------------------------------- */
:root {
  /* Brand ramp — anchored on the original #1e4356 heading and #68a4c4 accent */
  --brand-950: #061a24;
  --brand-900: #0b2733;
  --brand-800: #123243;
  --brand-700: #1e4356;
  --brand-600: #2a6480;
  --brand-500: #2e86ae;
  --brand-400: #4e9cbe;
  --brand-300: #68a4c4;
  --brand-200: #a7cadd;
  --brand-100: #d7e8f0;
  --brand-50: #eff6fa;

  /* Neutrals — cool grey, tuned to sit beside the brand teal */
  --n-950: #0a1419;
  --n-900: #101f27;
  --n-800: #1b2f39;
  --n-700: #2c4652;
  --n-600: #45636f;
  --n-500: #5f7d89;
  --n-400: #85a0aa;
  --n-300: #b0c4cc;
  --n-200: #d5e0e5;
  --n-100: #e9f0f3;
  --n-50: #f5f8fa;

  /* Semantic — light surface (default) */
  --fg: #0e2029;
  --fg-muted: #4b6672;
  --fg-subtle: #6f8a95;
  --fg-onbrand: #ffffff;

  --surface: #ffffff;
  --surface-2: #f5f8fa;
  --surface-3: #eaf1f5;
  --surface-inset: #f8fbfc;

  --border: #e2eaef;
  --border-strong: #cddbe2;

  --accent: var(--brand-500);
  --accent-hover: var(--brand-600);
  --accent-soft: var(--brand-50);

  --ok: #1f9d6b;
  --warn: #c9820f;

  /* Type */
  --font-display: "Plus Jakarta Sans", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;

  --step--2: 0.75rem;
  --step--1: 0.8125rem;
  --step-0: 0.9375rem;
  --step-1: 1.0625rem;
  --step-2: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --step-3: clamp(1.375rem, 1.24rem + 0.6vw, 1.75rem);
  --step-4: clamp(1.75rem, 1.5rem + 1.15vw, 2.5rem);
  --step-5: clamp(2.25rem, 1.75rem + 2.2vw, 3.5rem);
  --step-6: clamp(2.625rem, 1.9rem + 3.1vw, 4.25rem);

  /* Space */
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 24px;
  --sp-6: 32px;
  --sp-7: 48px;
  --sp-8: 64px;
  --sp-9: 96px;
  --sp-10: 128px;

  --section-y: clamp(64px, 7vw, 116px);
  --container: 1200px;
  --container-narrow: 840px;
  --gutter: clamp(20px, 4vw, 40px);

  /* Radius + elevation — restrained on purpose */
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --r-xl: 20px;
  --r-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(14, 32, 41, 0.04), 0 1px 3px rgba(14, 32, 41, 0.06);
  --shadow-md: 0 4px 12px rgba(14, 32, 41, 0.06), 0 2px 4px rgba(14, 32, 41, 0.04);
  --shadow-lg: 0 18px 48px rgba(14, 32, 41, 0.1), 0 4px 12px rgba(14, 32, 41, 0.05);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur: 220ms;

  --header-h: 72px;
}

/* Dark surface context — applied to sections, not the whole page */
.on-dark {
  --fg: #ffffff;
  --fg-muted: #a9c3ce;
  --fg-subtle: #85a3b0;
  --surface: var(--brand-900);
  --surface-2: var(--brand-800);
  --surface-3: #16394b;
  --surface-inset: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.22);
  --accent: var(--brand-300);
  --accent-hover: #8fbdd6;
  --accent-soft: rgba(104, 164, 196, 0.14);
  color: var(--fg);
  background: var(--surface);
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* Must live on html, not body: overflow-x on body makes body the scroll
     container, which zeroes window.scrollY and breaks scroll-linked JS. */
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--step-1);
  line-height: 1.65;
  color: var(--fg);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

h1, h2, h3, h4, h5 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.022em;
  color: var(--fg);
  text-wrap: balance;
}

h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-3); }
h4 { font-size: var(--step-2); letter-spacing: -0.015em; }
h5 { font-size: var(--step-1); letter-spacing: -0.01em; }

p {
  margin: 0 0 var(--sp-4);
  color: var(--fg-muted);
  text-wrap: pretty;
}

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

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}

a:hover { color: var(--accent-hover); }

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

ul, ol { margin: 0; padding: 0; }
li { list-style: none; }

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: var(--sp-7) 0;
}

strong { font-weight: 650; color: var(--fg); }

::selection {
  background: var(--brand-200);
  color: var(--brand-950);
}

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  padding: 12px 20px;
  background: var(--brand-700);
  color: #fff;
  border-radius: 0 0 var(--r-md) 0;
}

.skip-link:focus { left: 0; color: #fff; }

/* --------------------------------------------------------------------------
   3. Layout
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow { max-width: var(--container-narrow); }
.container--wide { max-width: 1360px; }

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

.section--tight { padding-block: clamp(48px, 5vw, 80px); }
.section--flush-top { padding-top: 0; }
.section--flush-bottom { padding-bottom: 0; }
.section--muted { background: var(--surface-2); }
.section--inset { background: var(--surface-inset); }

.section-head {
  max-width: 720px;
  margin-bottom: clamp(40px, 5vw, 68px);
}

.section-head--center {
  margin-inline: auto;
  text-align: center;
}

.section-head p {
  font-size: var(--step-2);
  line-height: 1.55;
  margin-top: var(--sp-4);
  margin-bottom: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: var(--sp-4);
  font-family: var(--font-body);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: currentColor;
  opacity: 0.55;
}

.eyebrow--plain::before { display: none; }

.lede {
  font-size: var(--step-2);
  line-height: 1.6;
  color: var(--fg-muted);
}

.grid { display: grid; gap: var(--sp-6); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

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

.split--wide-left { grid-template-columns: 1.15fr 0.85fr; }
.split--wide-right { grid-template-columns: 0.85fr 1.15fr; }
.split--top { align-items: start; }

.stack > * + * { margin-top: var(--sp-4); }
.stack-lg > * + * { margin-top: var(--sp-6); }

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
  margin-top: var(--sp-6);
}

.rule {
  height: 1px;
  background: var(--border);
  border: 0;
  margin: 0;
}

/* --------------------------------------------------------------------------
   4. Buttons
   -------------------------------------------------------------------------- */
.btn {
  --btn-bg: var(--accent);
  --btn-fg: #fff;
  --btn-bd: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 24px;
  border: 1px solid var(--btn-bd);
  border-radius: var(--r-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-body);
  font-size: var(--step-0);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.005em;
  cursor: pointer;
  white-space: nowrap;
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease),
    border-color var(--dur) var(--ease), color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.btn:hover {
  color: var(--btn-fg);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn:active { transform: translateY(0); }

.btn i, .btn svg {
  font-size: 1.05em;
  transition: transform var(--dur) var(--ease);
}

.btn:hover i.bi-arrow-right { transform: translateX(3px); }

.btn--primary { --btn-bg: var(--accent); --btn-bd: var(--accent); }
.btn--primary:hover { --btn-bg: var(--accent-hover); --btn-bd: var(--accent-hover); }

.btn--dark {
  --btn-bg: var(--brand-700);
  --btn-bd: var(--brand-700);
  --btn-fg: #fff;
}
.btn--dark:hover { --btn-bg: var(--brand-800); --btn-bd: var(--brand-800); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--fg);
  --btn-bd: var(--border-strong);
}
.btn--ghost:hover {
  --btn-bd: var(--accent);
  --btn-fg: var(--accent);
  box-shadow: none;
}

.btn--light {
  --btn-bg: #fff;
  --btn-fg: var(--brand-800);
  --btn-bd: #fff;
}
.btn--light:hover { --btn-bg: rgba(255, 255, 255, 0.88); --btn-bd: rgba(255, 255, 255, 0.88); }

.btn--sm { padding: 9px 18px; font-size: var(--step--1); }
.btn--lg { padding: 16px 30px; font-size: var(--step-1); }
.btn--block { width: 100%; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: var(--step-0);
  color: var(--accent);
}

.link-arrow i { transition: transform var(--dur) var(--ease); }
.link-arrow:hover i { transform: translateX(4px); }

/* --------------------------------------------------------------------------
   5. Header / navigation
   -------------------------------------------------------------------------- */
/* Transparent over the hero, then it takes on colour once you scroll.
   Every page opens with a dark hero, so the white wordmark and light nav
   stay legible at the top of all of them. */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  /* Fully transparent at rest — no background, no border. Every page opens
     with a dark hero, which is what keeps the white wordmark and nav legible. */
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 320ms var(--ease), border-color 320ms var(--ease),
    height 320ms var(--ease), box-shadow 320ms var(--ease);
}

.site-header.is-stuck {
  height: calc(var(--header-h) - 8px);
  background: rgba(6, 26, 36, 0.92);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 30px rgba(4, 18, 26, 0.28);
}

/* The open mobile panel needs the bar solid regardless of scroll position. */
body.nav-open .site-header {
  background: var(--brand-950);
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

.site-header__inner {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-5);
}

.brand { display: inline-flex; align-items: center; }
.brand img { height: 30px; width: auto; }

.nav { display: flex; align-items: center; gap: var(--sp-2); }

.nav a {
  position: relative;
  padding: 8px 14px;
  border-radius: var(--r-sm);
  font-size: var(--step-0);
  font-weight: 500;
  color: #b7cdd7;
}

.nav a:hover { color: #fff; }

.nav a.is-active { color: #fff; font-weight: 600; }

.header-actions { display: flex; align-items: center; gap: var(--sp-3); }

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--r-sm);
  background: transparent;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}

.nav-panel {
  position: fixed;
  inset: var(--header-h) 0 0;
  z-index: 99;
  padding: var(--sp-6) var(--gutter) var(--sp-8);
  background: var(--brand-950);
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), visibility var(--dur);
}

.nav-panel.is-open { opacity: 1; visibility: visible; transform: none; }

.nav-panel a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-4) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 600;
  color: #fff;
}

.nav-panel a i { color: var(--brand-300); font-size: 0.7em; }
.nav-panel .btn { margin-top: var(--sp-6); }

body.nav-open { overflow: hidden; }

/* --------------------------------------------------------------------------
   6. Hero
   -------------------------------------------------------------------------- */
/* The header is fixed and transparent at rest, so every hero starts beneath it
   and provides the dark ground the nav sits on. */
.hero {
  position: relative;
  padding-block: calc(var(--header-h) + clamp(40px, 5vw, 76px)) clamp(56px, 7vw, 96px);
  overflow: hidden;
}

.hero--dark {
  background:
    radial-gradient(900px 520px at 78% 6%, rgba(104, 164, 196, 0.22), transparent 62%),
    linear-gradient(180deg, var(--brand-900) 0%, var(--brand-950) 100%);
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}

.hero h1 {
  font-size: var(--step-6);
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.hero__lede {
  margin-top: var(--sp-5);
  font-size: var(--step-2);
  line-height: 1.6;
  max-width: 34em;
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3) var(--sp-6);
  margin-top: var(--sp-7);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--border);
  font-size: var(--step-0);
  color: var(--fg-subtle);
}

.hero__meta span { display: inline-flex; align-items: center; gap: 8px; }
.hero__meta i { color: var(--accent); }

.page-hero {
  padding-block: calc(var(--header-h) + clamp(32px, 4vw, 60px)) clamp(40px, 5vw, 64px);
  border-bottom: 1px solid var(--border);
}

.page-hero--dark {
  border-bottom: 0;
  background:
    radial-gradient(760px 420px at 85% 0%, rgba(104, 164, 196, 0.2), transparent 60%),
    linear-gradient(180deg, var(--brand-900) 0%, var(--brand-950) 100%);
}

.page-hero h1 { max-width: 16ch; }
.page-hero .lede { margin-top: var(--sp-5); max-width: 62ch; }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: var(--sp-5);
  font-size: var(--step--1);
  color: var(--fg-subtle);
}

.breadcrumb a { color: var(--fg-subtle); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb li + li::before { content: "/"; margin-right: 8px; opacity: 0.5; }
.breadcrumb li { display: inline-flex; align-items: center; }
.breadcrumb [aria-current] { color: var(--fg); }

/* --------------------------------------------------------------------------
   7. Product UI frame
   -------------------------------------------------------------------------- */
.frame {
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
}

.on-dark .frame,
.hero--dark .frame {
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.4);
}

.frame__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}

.frame__bar span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--border-strong);
}

.frame__bar em {
  margin-left: 10px;
  font-style: normal;
  font-size: var(--step--2);
  letter-spacing: 0.04em;
  color: var(--fg-subtle);
}

.frame img { width: 100%; display: block; }

/* Case-study hero art: stock photography varies wildly in ratio, so crop it */
.frame--hero img {
  max-height: clamp(260px, 40vw, 480px);
  object-fit: cover;
  /* Screenshots carry their content at the top; a centre crop lands on empty
     canvas. Photographs read fine top-anchored too. */
  object-position: center top;
}

.frame--tilt {
  transform: perspective(1600px) rotateY(-4deg) rotateX(1.5deg);
  transition: transform 600ms var(--ease-out);
}

.frame--tilt:hover { transform: perspective(1600px) rotateY(0) rotateX(0); }

.shot {
  display: block;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.shot img { transition: transform 600ms var(--ease-out); }
.shot:hover img { transform: scale(1.015); }

.shot-caption {
  margin-top: var(--sp-3);
  font-size: var(--step--1);
  line-height: 1.6;
  color: var(--fg-subtle);
}

/* --------------------------------------------------------------------------
   8. Stats, logos, chips
   -------------------------------------------------------------------------- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.stat {
  padding: clamp(20px, 3vw, 32px);
  background: var(--surface);
}

.stat__value {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 1.3rem + 1.8vw, 2.5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--fg);
}

.stat__label {
  margin-top: 10px;
  font-size: var(--step-0);
  color: var(--fg-subtle);
  line-height: 1.5;
}

.logo-wall {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: clamp(28px, 5vw, 64px);
}

.logo-wall img {
  height: 30px;
  width: auto;
  opacity: 0.5;
  filter: grayscale(1);
  transition: opacity var(--dur) var(--ease), filter var(--dur) var(--ease);
}

.logo-wall img:hover { opacity: 0.9; filter: grayscale(0); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 13px;
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  background: var(--surface);
  font-size: var(--step--1);
  font-weight: 500;
  color: var(--fg-muted);
}

.chip--accent {
  border-color: color-mix(in srgb, var(--accent), transparent 70%);
  background: var(--accent-soft);
  color: var(--accent);
}

.chip-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: var(--r-sm);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: var(--step--2);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   9. Editorial rows (services, capabilities)
   -------------------------------------------------------------------------- */
.rows { border-top: 1px solid var(--border); }

.row-item {
  display: grid;
  grid-template-columns: 88px 1fr 1.1fr;
  gap: clamp(20px, 4vw, 56px);
  padding-block: clamp(28px, 3.5vw, 44px);
  border-bottom: 1px solid var(--border);
  align-items: start;
}

.row-item__num {
  font-family: var(--font-mono);
  font-size: var(--step--1);
  letter-spacing: 0.08em;
  color: var(--fg-subtle);
  padding-top: 6px;
}

.row-item h3 { margin-bottom: var(--sp-3); }
.row-item__body p { margin-bottom: var(--sp-4); }

.row-item:hover .row-item__num { color: var(--accent); }

.mini-list { display: grid; gap: 10px; }

.mini-list li {
  position: relative;
  padding-left: 26px;
  font-size: var(--step-0);
  color: var(--fg-muted);
  line-height: 1.55;
}

.mini-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 12px;
  height: 2px;
  background: var(--accent);
  opacity: 0.75;
}

.check-list { display: grid; gap: 12px; }

.check-list li {
  display: flex;
  gap: 12px;
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--fg-muted);
}

.check-list i {
  flex: none;
  margin-top: 3px;
  color: var(--accent);
  font-size: 1.05em;
}

.check-list strong { color: var(--fg); }

/* --------------------------------------------------------------------------
   10. Cards
   -------------------------------------------------------------------------- */
.card {
  display: flex;
  flex-direction: column;
  padding: clamp(22px, 2.6vw, 32px);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--surface);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
}

.card:hover {
  border-color: var(--border-strong);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: var(--sp-5);
  border-radius: var(--r-md);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 20px;
}

.card h3, .card h4 { margin-bottom: var(--sp-3); }
.card p { font-size: var(--step-0); }
.card__foot { margin-top: auto; padding-top: var(--sp-5); }

/* Industry card — image-led, used on the portfolio index */
.industry {
  position: relative;
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--surface);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
}

.industry:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}

.industry__media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--surface-3);
}

.industry__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 700ms var(--ease-out);
}

.industry:hover .industry__media img { transform: scale(1.04); }

.industry__body { padding: clamp(20px, 2.4vw, 28px); }

/* Owned products / capabilities sitting among client case studies — visibly
   marked so they are never mistaken for work delivered for a client. */
.industry--owned {
  border-color: color-mix(in srgb, var(--accent), transparent 62%);
  background: linear-gradient(180deg, var(--accent-soft), var(--surface) 55%);
}

.industry--owned:hover { border-color: var(--accent); }

.industry__icon {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 10;
  background:
    radial-gradient(420px 200px at 70% 10%, rgba(104, 164, 196, 0.28), transparent 65%),
    linear-gradient(150deg, var(--brand-800), var(--brand-950));
}

.industry__icon i {
  font-size: 44px;
  color: var(--brand-200);
  transition: transform 600ms var(--ease-out);
}

.industry:hover .industry__icon i { transform: translateY(-3px) scale(1.06); }

.owned-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--step--2);
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.industry__domain {
  font-size: var(--step--2);
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.industry h3 {
  margin: 10px 0 8px;
  font-size: var(--step-2);
}

.industry p {
  font-size: var(--step-0);
  margin-bottom: 0;
}

.industry__foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: var(--sp-5);
  font-size: var(--step-0);
  font-weight: 600;
  color: var(--accent);
}

.industry:hover .industry__foot i { transform: translateX(4px); }
.industry__foot i { transition: transform var(--dur) var(--ease); }

/* --------------------------------------------------------------------------
   11. Case study rows
   -------------------------------------------------------------------------- */
.case {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
  padding-block: clamp(40px, 5vw, 72px);
  border-bottom: 1px solid var(--border);
}

.case:last-child { border-bottom: 0; }
.case:nth-child(even) .case__media { order: -1; }

/* The picture fills its half of the row instead of floating in white space */
.case { align-items: stretch; }
.case__media { display: flex; }
.case__media .shot { flex: 1; display: flex; min-height: 100%; }
.case__media .shot img { width: 100%; height: 100%; object-fit: cover; }

.case__domain {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.case h3 {
  margin: var(--sp-4) 0 var(--sp-4);
  font-size: var(--step-4);
}

.case__facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--sp-4);
  margin-top: var(--sp-6);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--border);
}

.case__fact dt {
  font-size: var(--step--2);
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  margin-bottom: 6px;
}

.case__fact dd {
  margin: 0;
  font-size: var(--step-0);
  color: var(--fg);
  line-height: 1.5;
}

/* Case study page: challenge → solution → tech → outcome */
.cs-block {
  display: grid;
  /* Label rail + a capped reading measure, left-aligned with the rest of the
     page rather than centred in a narrower container. */
  grid-template-columns: 240px minmax(0, 640px);
  gap: clamp(20px, 4vw, 56px);
  padding-block: clamp(24px, 2.6vw, 38px);
  border-top: 1px solid var(--border);
}

.cs-block__label {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--fg);
}

.cs-block__label span {
  display: block;
  margin-bottom: 6px;
  font-family: var(--font-mono);
  font-size: var(--step--2);
  font-weight: 400;
  letter-spacing: 0.12em;
  color: var(--accent);
}

.cs-block__body > p { font-size: var(--step-1); }

.pull {
  margin: 0;
  padding: clamp(24px, 3vw, 36px);
  border-left: 3px solid var(--accent);
  background: var(--surface-2);
  border-radius: 0 var(--r-md) var(--r-md) 0;
}

.pull p {
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.015em;
  color: var(--fg);
  margin: 0;
}

/* --------------------------------------------------------------------------
   12. Product panel (owned products — deliberately distinct from client work)
   -------------------------------------------------------------------------- */
.product-panel {
  position: relative;
  border-radius: var(--r-xl);
  overflow: hidden;
  background:
    radial-gradient(800px 400px at 88% 0%, rgba(104, 164, 196, 0.22), transparent 60%),
    linear-gradient(160deg, var(--brand-800) 0%, var(--brand-950) 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.product-panel__inner {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: clamp(32px, 4vw, 64px);
  align-items: center;
  padding: clamp(28px, 4vw, 60px);
}

.product-panel .badge {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.owned-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 13px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(255, 255, 255, 0.24);
  font-size: var(--step--2);
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #fff;
}

/* --------------------------------------------------------------------------
   13. CTA band
   -------------------------------------------------------------------------- */
.cta-band {
  padding-block: clamp(56px, 6vw, 96px);
  background:
    radial-gradient(700px 340px at 15% 100%, rgba(104, 164, 196, 0.2), transparent 60%),
    linear-gradient(140deg, var(--brand-800), var(--brand-950));
}

.cta-band h2 { font-size: var(--step-5); max-width: 18ch; }
.cta-band p { max-width: 46ch; margin-top: var(--sp-4); }

/* --------------------------------------------------------------------------
   14. Forms
   -------------------------------------------------------------------------- */
.form-card {
  padding: clamp(24px, 3.5vw, 44px);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.field { margin-bottom: var(--sp-5); }

.field > label {
  display: block;
  margin-bottom: 8px;
  font-size: var(--step--1);
  font-weight: 600;
  color: var(--fg);
}

.input,
.select,
.textarea {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--border-strong);
  border-radius: var(--r-md);
  background: var(--surface);
  font-family: var(--font-body);
  font-size: var(--step-0);
  color: var(--fg);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.input::placeholder, .textarea::placeholder { color: var(--fg-subtle); }

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent), transparent 82%);
}

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

.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%236f8a95'%3E%3Cpath d='M4.5 6.5 8 10l3.5-3.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  padding-right: 40px;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-4);
}

.opt {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  font-size: var(--step-0);
  color: var(--fg-muted);
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}

.opt:hover { border-color: var(--border-strong); background: var(--surface-2); }

.opt input {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--accent);
  cursor: pointer;
}

.opt:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--fg);
}

.opt-grid { display: grid; gap: 10px; }

.error-message {
  display: block;
  margin-top: 6px;
  font-size: var(--step--1);
  color: #c0392b;
}

.status-message {
  margin-top: var(--sp-4);
  font-size: var(--step-0);
  font-weight: 500;
}

.status-message.success { color: var(--ok); }
.status-message.error { color: #c0392b; }

.contact-line {
  display: flex;
  gap: var(--sp-4);
  padding-block: var(--sp-5);
  border-bottom: 1px solid var(--border);
}

.contact-line:last-child { border-bottom: 0; }

.contact-line i {
  flex: none;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: var(--r-md);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 18px;
}

.contact-line dt {
  font-size: var(--step--1);
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  margin-bottom: 4px;
}

.contact-line dd { margin: 0; color: var(--fg); }

/* --------------------------------------------------------------------------
   15. Team / blog
   -------------------------------------------------------------------------- */
.person__photo {
  aspect-ratio: 1 / 1;
  border-radius: var(--r-lg);
  overflow: hidden;
  /* Soft tint sits behind cut-out PNGs so they read as intentional portraits */
  background: linear-gradient(160deg, var(--surface-3), var(--surface-2));
  margin-bottom: var(--sp-4);
}

.person__photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease-out); }
.person:hover .person__photo img { transform: scale(1.03); }
.person h3 { font-size: var(--step-2); margin-bottom: 2px; }

.person__role {
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.person p { margin-top: var(--sp-3); font-size: var(--step-0); }

.post { display: flex; flex-direction: column; height: 100%; }

.post__media {
  aspect-ratio: 16 / 10;
  border-radius: var(--r-md);
  overflow: hidden;
  /* Soft tint sits behind cut-out PNGs so they read as intentional portraits */
  background: linear-gradient(160deg, var(--surface-3), var(--surface-2));
  margin-bottom: var(--sp-4);
}

.post__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease-out); }
.post:hover .post__media img { transform: scale(1.04); }

.post__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: var(--step--1);
  color: var(--fg-subtle);
  margin-bottom: 10px;
}

.post h3 { font-size: var(--step-2); }
.post h3 a { color: var(--fg); }
.post h3 a:hover { color: var(--accent); }

.pager { display: flex; gap: 8px; justify-content: center; }

.pager a, .pager span {
  min-width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  padding-inline: 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  font-size: var(--step-0);
  color: var(--fg-muted);
}

.pager .is-current { background: var(--brand-700); border-color: var(--brand-700); color: #fff; }

/* --------------------------------------------------------------------------
   16. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  padding-block: clamp(56px, 6vw, 88px) var(--sp-6);
  background: var(--brand-950);
  color: #fff;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr repeat(4, 1fr);
  gap: clamp(28px, 4vw, 56px);
  padding-bottom: var(--sp-8);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.site-footer img.footer-logo { height: 32px; margin-bottom: var(--sp-4); }

.site-footer p { color: #a9c3ce; font-size: var(--step-0); }

.footer-col h4 {
  margin-bottom: var(--sp-4);
  font-size: var(--step--1);
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
}

.footer-col li + li { margin-top: 11px; }

.footer-col a {
  font-size: var(--step-0);
  color: #a9c3ce;
}

.footer-col a:hover { color: #fff; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding-top: var(--sp-6);
  font-size: var(--step--1);
  color: #85a3b0;
}

.social { display: flex; gap: 10px; }

.social a {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  color: #a9c3ce;
  font-size: 16px;
  transition: all var(--dur) var(--ease);
}

.social a:hover {
  background: var(--brand-300);
  border-color: var(--brand-300);
  color: var(--brand-950);
}

/* --------------------------------------------------------------------------
   16b. Pillars — the "why us" block
   -------------------------------------------------------------------------- */
.pillars {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.pillar {
  position: relative;
  padding: clamp(24px, 3vw, 34px);
  background: var(--surface);
  transition: background var(--dur) var(--ease);
}

/* Accent rail that wipes in from the left on hover */
.pillar::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 460ms var(--ease-out);
}

.pillar:hover { background: var(--surface-2); }
.pillar:hover::before { transform: scaleX(1); }

.pillar__index {
  display: block;
  margin-bottom: var(--sp-5);
  font-family: var(--font-mono);
  font-size: var(--step--1);
  letter-spacing: 0.14em;
  color: var(--fg-subtle);
  transition: color var(--dur) var(--ease);
}

.pillar:hover .pillar__index { color: var(--accent); }

.pillar h4 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: var(--sp-3);
}

.pillar h4 i {
  color: var(--accent);
  font-size: 1.05em;
  transition: transform 460ms var(--ease-out);
}

.pillar:hover h4 i { transform: translateY(-2px) scale(1.08); }

.pillar p { font-size: var(--step-0); margin: 0; }

/* --------------------------------------------------------------------------
   17. Motion
   -------------------------------------------------------------------------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out),
    filter 700ms var(--ease-out);
  transition-delay: calc(var(--i, 0) * 80ms);
  will-change: opacity, transform;
}

[data-reveal="left"] { transform: translateX(-26px); }
[data-reveal="right"] { transform: translateX(26px); }
[data-reveal="scale"] { transform: scale(0.965); }
[data-reveal="soft"] { transform: translateY(12px); filter: blur(6px); }

[data-reveal].is-in {
  opacity: 1;
  transform: none;
  filter: none;
}

/* Split sections converge: the two halves slide in from opposite sides */
.split > [data-reveal]:first-child { transform: translate3d(-24px, 8px, 0); }
.split > [data-reveal]:last-child { transform: translate3d(24px, 8px, 0); }
.split > [data-reveal].is-in { transform: none; }

/* Image wipe: the frame clips its picture open as it enters */
[data-wipe] { clip-path: inset(0 0 100% 0); transition: clip-path 900ms var(--ease-out); }
[data-wipe].is-in { clip-path: inset(0 0 0 0); }

/* Hero entrance — runs on load rather than on scroll */
.hero [data-enter] {
  opacity: 0;
  transform: translateY(20px);
  animation: enter 900ms var(--ease-out) forwards;
  animation-delay: calc(120ms + var(--d, 0) * 110ms);
}

.hero [data-enter="frame"] {
  transform: translateY(28px) scale(0.97);
  animation-name: enter-frame;
  animation-duration: 1100ms;
}

@keyframes enter {
  to { opacity: 1; transform: none; }
}

@keyframes enter-frame {
  to { opacity: 1; transform: none; }
}

/* Button sheen */
.btn { position: relative; overflow: hidden; }

.btn::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 -60%;
  width: 45%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.28), transparent);
  transform: skewX(-18deg);
  transition: left 620ms var(--ease-out);
  pointer-events: none;
}

.btn:hover::after { left: 130%; }
.btn--ghost::after { display: none; }

/* Nav underline grows rather than appears */
.nav a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: var(--brand-300);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 320ms var(--ease-out);
}

.nav a:hover::after { transform: scaleX(1); }
.nav a.is-active::after { transform: scaleX(1); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: clamp(16px, 4vw, 56px);
  background: rgba(6, 26, 36, 0.92);
  backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 260ms var(--ease), visibility 260ms;
}

.lightbox.is-open { opacity: 1; visibility: visible; }

.lightbox img {
  max-width: 100%;
  max-height: 88vh;
  border-radius: var(--r-md);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}

.lightbox__close {
  position: absolute;
  top: clamp(12px, 3vw, 28px);
  right: clamp(12px, 3vw, 28px);
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  background: transparent;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}

.lightbox__close:hover { background: rgba(255, 255, 255, 0.12); }

/* --------------------------------------------------------------------------
   18. Utilities
   -------------------------------------------------------------------------- */
.text-center { text-align: center; }
.mx-auto { margin-inline: auto; }
.mt-0 { margin-top: 0; }
.mt-4 { margin-top: var(--sp-4); }
.mt-5 { margin-top: var(--sp-5); }
.mt-6 { margin-top: var(--sp-6); }
.mt-7 { margin-top: var(--sp-7); }
.mb-0 { margin-bottom: 0; }
.mb-5 { margin-bottom: var(--sp-5); }
.mb-6 { margin-bottom: var(--sp-6); }
.max-60 { max-width: 60ch; }
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* --------------------------------------------------------------------------
   19. Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1080px) {
  .footer-top { grid-template-columns: 1.4fr repeat(3, 1fr); }
  .footer-col--last { grid-column: 2 / -1; }
}

@media (max-width: 980px) {
  :root { --header-h: 64px; }

  .nav, .header-actions .btn { display: none; }
  .nav-toggle { display: inline-flex; }

  .hero__grid,
  .split,
  .split--wide-left,
  .split--wide-right,
  .product-panel__inner { grid-template-columns: 1fr; }

  .case,
  .case:nth-child(even) .case__media { grid-template-columns: 1fr; order: 0; }
  .case__media { margin-bottom: var(--sp-5); }

  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }

  .row-item { grid-template-columns: 56px 1fr; }
  .row-item__body { grid-column: 2; }

  .cs-block { grid-template-columns: 1fr; gap: var(--sp-4); }

  .frame--tilt { transform: none; }

  .footer-top { grid-template-columns: repeat(2, 1fr); }
  .footer-col--brand { grid-column: 1 / -1; }
  .footer-col--last { grid-column: auto; }
}

@media (max-width: 640px) {
  :root { --section-y: 56px; }

  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .case__facts { grid-template-columns: 1fr; }
  .hero__meta { gap: 10px var(--sp-5); }
  .actions .btn { width: 100%; }
  .logo-wall { gap: 28px; }
  .logo-wall img { height: 24px; }
  .footer-bottom { justify-content: flex-start; }
}

.person__focus {
  margin-top: 6px;
  font-size: var(--step-0);
  line-height: 1.55;
  color: var(--fg-muted);
}

/* --------------------------------------------------------------------------
   20. Long-form article
   -------------------------------------------------------------------------- */
.article > p { font-size: var(--step-1); line-height: 1.75; }

.article > h2 {
  margin-top: clamp(36px, 4vw, 56px);
  margin-bottom: var(--sp-4);
  font-size: var(--step-3);
}

.article > .pull { margin-block: clamp(32px, 4vw, 48px); }
.article .lede { margin-bottom: var(--sp-6); }
.article em { color: var(--fg); font-style: italic; }

.post h3 + p { margin-top: 10px; font-size: var(--step-0); }

/* Case-study lead-in: the hero art sits close under the title rather than
   marooned by two full section paddings. */
.page-hero--case { padding-bottom: clamp(26px, 3vw, 40px); }
.section--hug { padding-top: clamp(18px, 2.4vw, 30px); }
.section--hug-bottom { padding-bottom: clamp(24px, 3vw, 40px); }
