/* =========================================================
   STRUCT REHAB — Main Stylesheet
   Design System: Steel and Sky
   ========================================================= */

/* ---- Fonts (self-hosted) ----
   Served from /assets/fonts so the browser never has to resolve, connect to,
   and chain a stylesheet off fonts.googleapis.com before it can paint.
   IBM Plex Sans and Inter are variable files: one download covers every weight. */
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-400-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-400-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-500-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-500-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-600-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-600-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-sans-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/ibm-plex-sans-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('/assets/fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---- Design Tokens ---- */
:root {
  /* Colours */
  --color-primary:      #0A2A4A;
  --color-secondary:    #1565C0;
  --color-accent:       #4FC3F7;
  --color-surface:      #F5F8FC;
  --color-white:        #FFFFFF;
  --color-ink:          #1C2B3A;
  --color-mid:          #607080;
  --color-rule:         #D0DCE8;
  --color-dark-surface: #0D1F33;

  /* Typography */
  --font-heading: 'IBM Plex Sans', system-ui, sans-serif;
  --font-body:    'Inter', system-ui, sans-serif;
  --font-mono:    'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  /* Type scale sizes */
  --text-hero:    clamp(44px, 5vw, 66px);
  --text-h1:      44px;
  --text-h2:      36px;
  --text-h3:      18px;
  --text-label:   11px;
  --text-body:    16px;
  --text-small:   13px;
  --text-caption: 11px;

  /* Spacing */
  --section-pad:    80px;
  --container-max:  1200px;
  --container-pad:  24px;
  --grid-gap:       24px;

  /* Components */
  --shadow-card: 0 2px 12px rgba(10, 42, 74, 0.08);
  --shadow-nav:  0 2px 20px rgba(10, 42, 74, 0.18);
  --radius-card: 0px;
}

@media (max-width: 768px) {
  :root {
    --section-pad: 48px;
    --text-hero:   36px;
    --text-h1:     30px;
    --text-h2:     24px;
  }
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: 1.7;
  color: var(--color-ink);
  background: var(--color-surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

address {
  font-style: normal;
}

/* ---- Layout ---- */
.container {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

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

.section--white   { background: var(--color-white); }
.section--tinted  { background: var(--color-surface); }
.section--dark    { background: var(--color-primary); }
.section--darker  { background: var(--color-dark-surface); }

/* ---- Split: a main column beside a supporting one ----
   Page layouts used to set grid-template-columns inline, which no media
   query can reach, so they stayed two-up at 360px and pushed the page
   sideways. Every two-column body layout routes through this class. */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.split--wide-first   { grid-template-columns: 1.2fr 1fr; }
.split--narrow-first { grid-template-columns: 1fr 2fr; }
.split--form         { grid-template-columns: 1fr 1.6fr; }

@media (max-width: 900px) {
  .split,
  .split--wide-first,
  .split--narrow-first,
  .split--form {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* ---- Typography ---- */
h1 {
  font-family: var(--font-heading);
  font-size: var(--text-h1);
  font-weight: 700;
  line-height: 1.15;
  color: var(--color-primary);
}

h2 {
  font-family: var(--font-heading);
  font-size: var(--text-h2);
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-primary);
}

h3 {
  font-family: var(--font-heading);
  font-size: var(--text-h3);
  font-weight: 600;
  line-height: 1.3;
  color: var(--color-primary);
}

p {
  font-size: var(--text-body);
  line-height: 1.7;
}

/* ---- Section Labels ---- */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: var(--text-label);
  font-weight: 600;
  color: var(--color-secondary);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  line-height: 1;
  margin-bottom: 14px;
}

.section-label::before {
  content: '';
  display: block;
  width: 40px;
  height: 2px;
  background: var(--color-accent);
  flex-shrink: 0;
}

/* On dark surfaces the accent has enough contrast; on white it does not */
.hero .section-label,
.page-banner .section-label,
.section--dark .section-label,
.section--darker .section-label,
.stats-bar .section-label,
.cta-band .section-label {
  color: var(--color-accent);
}

/* ---- Section Header ---- */
.section-header {
  margin-bottom: 48px;
}

.section-header h2 {
  margin-bottom: 14px;
}

.section-header .intro {
  font-size: 15px;
  color: var(--color-mid);
  max-width: 560px;
}

.section-header--center {
  text-align: center;
}

.section-header--center .section-label {
  justify-content: center;
}

.section-header--center .section-label::before {
  display: none;
}

.section-header--center .intro {
  margin-inline: auto;
}

.section-header--light h2 {
  color: var(--color-white);
}

.section-header--light .intro {
  color: rgba(255, 255, 255, 0.65);
}

.section-footer {
  text-align: center;
  margin-top: 48px;
}

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 14px 28px;
  border: 2px solid transparent;
  border-radius: 0;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease,
    transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 2px rgba(79, 195, 247, 0.45), 0 6px 16px rgba(10, 42, 74, 0.22);
}

@media (prefers-reduced-motion: reduce) {
  .btn:hover {
    transform: none;
    box-shadow: 0 0 0 2px rgba(79, 195, 247, 0.45);
  }
}

.btn--primary {
  background: var(--color-secondary);
  color: var(--color-white);
  border-color: var(--color-secondary);
}

/* border-color is accent, not primary navy, so the button stays visible
   even when hovered on a section whose background is --color-primary
   (e.g. .cta-band) */
.btn--primary:hover {
  background: var(--color-primary);
  border-color: var(--color-accent);
}

.btn--outline-white {
  background: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.7);
}

.btn--outline-white:hover {
  background: var(--color-white);
  color: var(--color-primary);
  border-color: var(--color-white);
}

.btn--outline-blue {
  background: transparent;
  color: var(--color-secondary);
  border-color: var(--color-secondary);
}

.btn--outline-blue:hover {
  background: var(--color-secondary);
  color: var(--color-white);
}

/* ---- Cards ---- */
.card {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  box-shadow: var(--shadow-card);
  border-radius: var(--radius-card);
}

/* =========================================================
   NAVIGATION
   ========================================================= */
.site-nav-wrap {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-primary);
  transition: box-shadow 0.3s ease;
}

.site-nav-wrap.is-scrolled {
  box-shadow: var(--shadow-nav);
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

/* Logo */
.nav-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.nav-logo img {
  height: 38px;
  width: auto;
}

/* The drawer frees up the space the desktop links used, so the mark can carry
   more of the header on small screens. */
@media (max-width: 900px) {
  .site-nav { height: 76px; }

  /* The mark is 5.7:1, so height is capped by how much width is left beside
     the hamburger. The vw term keeps small phones clear of it. */
  .nav-logo img { height: clamp(38px, 12vw, 46px); }
}

/* Desktop links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-links a {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: rgba(255, 255, 255, 0.75);
  padding: 8px 14px;
  border-radius: 0;
  transition: color 0.2s ease;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 14px;
  right: 14px;
  height: 2px;
  background: var(--color-accent);
  transform: scaleX(0);
  transition: transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--color-white);
}

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

.nav-links a.nav-cta {
  background: var(--color-secondary);
  color: var(--color-white);
  padding: 9px 18px;
  margin-left: 10px;
}

.nav-links a.nav-cta::after {
  display: none;
}

.nav-links a.nav-cta:hover {
  background: var(--color-accent);
  color: var(--color-primary);
}

/* Hamburger */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  width: 40px;
  height: 40px;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-white);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Mobile drawer */
.nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: min(300px, 85vw);
  height: 100dvh;
  background: var(--color-dark-surface);
  z-index: 200;
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  /* Slides on transform rather than `right` so the panel is composited
     instead of relaying out each frame; visibility keeps the closed
     drawer out of the tab order and off screen readers. */
  transform: translateX(100%);
  visibility: hidden;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    visibility 0s linear 0.3s;
}

.nav-drawer.is-open {
  transform: none;
  visibility: visible;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), visibility 0s;
}

@media (prefers-reduced-motion: reduce) {
  .nav-drawer { transition: visibility 0s linear 0.3s; }
  .nav-drawer.is-open { transition: none; }
}

/* The close button is the only child now, so it is pinned right rather than
   spaced against a logo. */
.nav-drawer-header {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  margin-bottom: 40px;
}

.nav-drawer-close {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  font-size: 22px;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  transition: color 0.2s;
}

.nav-drawer-close:hover {
  color: var(--color-white);
}

.nav-drawer-links {
  display: flex;
  flex-direction: column;
}

.nav-drawer-links li {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-drawer-links a {
  display: block;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: rgba(255, 255, 255, 0.75);
  padding: 16px 0;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.nav-drawer-links a:hover {
  color: var(--color-accent);
  padding-left: 6px;
}

/* Overlay */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 150;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.nav-overlay.is-active {
  opacity: 1;
  pointer-events: all;
}

/* =========================================================
   PAGE BANNER (inner pages)
   ========================================================= */
.page-banner {
  position: relative;
  /* The photo is a real <img> below, not a background, so the browser can
     pick the 820px file on phones and start fetching it from the markup
     instead of waiting for this stylesheet to parse. */
  background-color: var(--color-primary);
  background-size: cover;
  background-position: center;
  padding: 96px 0;
  min-height: 340px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.page-banner-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.page-banner-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 42, 74, 0.65);
}

.page-banner-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(79, 195, 247, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79, 195, 247, 0.07) 1px, transparent 1px);
  background-size: 48px 48px;
}

.page-banner-content {
  position: relative;
  z-index: 1;
}

.page-banner-content .section-label {
  margin-bottom: 10px;
}

.page-banner-content h1 {
  color: var(--color-white);
  font-size: var(--text-h1);
}

.page-banner-content p {
  color: rgba(255, 255, 255, 0.75);
  margin-top: 12px;
  max-width: 540px;
  font-size: 15px;
}

/* =========================================================
   HERO (home page)
   ========================================================= */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  /* The photo comes from .hero-image (responsive srcset); this is just the
     ground colour it paints over. */
  background-color: var(--color-dark-surface);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  /* The Ken Burns scale on .hero-image paints wider than the viewport;
     without this the page gains ~20-45px of sideways scroll on phones. */
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  /* Left-to-right scrim seats the headline; vertical navy grade
     ties the photo to the Steel-and-Sky palette and darkens the
     base so the overlapping stats band reads cleanly. */
  background:
    linear-gradient(
      90deg,
      rgba(6, 16, 28, 0.82) 0%,
      rgba(6, 16, 28, 0.42) 42%,
      rgba(10, 42, 74, 0.12) 100%
    ),
    linear-gradient(
      180deg,
      rgba(6, 16, 28, 0.55) 0%,
      rgba(10, 42, 74, 0.30) 34%,
      rgba(10, 42, 74, 0.62) 100%
    );
}

/* Blueprint grid texture over overlay */
.hero-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(79, 195, 247, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79, 195, 247, 0.08) 1px, transparent 1px);
  background-size: 48px 48px;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding-block: 100px 140px;
  max-width: 1000px;
}

.hero-content .section-label {
  margin-bottom: 20px;
}

.hero-heading {
  font-family: var(--font-heading);
  font-size: var(--text-hero);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.015em;
  color: var(--color-white);
  margin-bottom: 24px;
}

.hero-sub {
  font-size: 16px;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 40px;
  max-width: 560px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---- Heritage seal: stamps the founding year into the open sky ---- */
.hero-est {
  position: absolute;
  top: clamp(112px, 15vh, 156px);
  right: clamp(24px, 4vw, 64px);
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 22px 30px;
  border: 1px solid rgba(79, 195, 247, 0.45);
  background: rgba(6, 16, 28, 0.30);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  text-align: center;
}

/* Engineering-drawing corner ticks (self-contained, matches .corner-ticks) */
.hero-est::before,
.hero-est::after {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  border: 2px solid var(--color-accent);
  pointer-events: none;
}

.hero-est::before {
  top: -1px;
  left: -1px;
  border-right: none;
  border-bottom: none;
}

.hero-est::after {
  bottom: -1px;
  right: -1px;
  border-left: none;
  border-top: none;
}

.hero-est-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.hero-est-year {
  font-family: var(--font-heading);
  font-size: 46px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--color-white);
}

.hero-est-place {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}

/* Ties the "25+ Years" tile to the founding year */
.stat-since {
  display: block;
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
}

/* Hero scroll hint */

/* =========================================================
   STATS BAR
   ========================================================= */
.stats-bar {
  background: var(--color-dark-surface);
  padding-block: 52px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.stat-item {
  padding: 16px 24px;
  text-align: center;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item:last-child {
  border-right: none;
}

.stat-number {
  display: block;
  font-family: var(--font-mono);
  font-size: 54px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--color-accent);
  line-height: 1;
  margin-bottom: 10px;
  letter-spacing: -0.02em;
}

.stat-number--text {
  font-size: 28px;
  line-height: 54px;
  letter-spacing: 0.02em;
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---- Founding-figure tiles (About story block) ---- */
.figure-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
}

.figure-tile {
  background: var(--color-primary);
  padding: 32px 24px;
  text-align: center;
}

.figure-tile:nth-child(n + 3) {
  background: var(--color-dark-surface);
}

.figure-tile-num {
  display: block;
  font-family: var(--font-mono);
  font-size: 38px;
  font-weight: 600;
  color: var(--color-accent);
  line-height: 1;
  margin-bottom: 8px;
}

/* Word figures ("All India") need to sit smaller than the numerals but hold
   the same 38px line box, so all four tiles keep their labels on one line. */
.figure-tile-num--text {
  font-size: 24px;
  line-height: 38px;
  letter-spacing: 0.02em;
}

.figure-tile-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.55);
}

/* Two 32px-padded tiles do not fit side by side on the narrowest phones */
@media (max-width: 400px) {
  .figure-tile      { padding: 24px 10px; }
  .figure-tile-num  { font-size: 28px; }
  .figure-tile-num--text { font-size: 18px; line-height: 28px; }
  .figure-tile-label { font-size: 10px; letter-spacing: 0.06em; }
}

/* =========================================================
   SERVICES OVERVIEW
   ========================================================= */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--grid-gap);
}

.service-card {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  box-shadow: var(--shadow-card);
  padding: 36px 28px;
  border-left: 4px solid transparent;
  transition: border-left-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.service-card:hover {
  border-left-color: var(--color-accent);
  box-shadow: 0 6px 24px rgba(10, 42, 74, 0.12);
  transform: translateY(-3px);
}

.service-icon {
  width: 52px;
  height: 52px;
  background: var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
  color: var(--color-secondary);
}

.service-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--color-secondary);
  fill: none;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-card h3 {
  font-size: var(--text-h3);
  color: var(--color-primary);
  margin-bottom: 12px;
}

.service-card p {
  font-size: 14px;
  color: var(--color-mid);
  line-height: 1.65;
  margin-bottom: 22px;
}

.card-link {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-secondary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s ease, gap 0.2s ease;
}

.card-link:hover {
  color: var(--color-primary);
  gap: 10px;
}

/* =========================================================
   CLIENTS STRIP
   ========================================================= */
.clients-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  align-items: center;
  margin-top: 8px;
}

.client-logo-box {
  height: 88px;
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  transition: border-color 0.2s;
}

.client-logo-box:hover {
  border-color: var(--color-secondary);
}

.client-logo-box img {
  max-height: 56px;
  width: auto;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: opacity 0.2s, filter 0.2s;
}

.client-logo-box:hover img {
  filter: grayscale(0%);
  opacity: 0.85;
}

.client-placeholder-text {
  font-family: var(--font-body);
  font-size: 10px;
  color: var(--color-mid);
  text-align: center;
  line-height: 1.4;
  padding: 4px;
}

/* =========================================================
   PROJECT CARDS
   ========================================================= */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--grid-gap);
}

.project-card {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.project-card:hover {
  box-shadow: 0 8px 28px rgba(10, 42, 74, 0.13);
  transform: translateY(-3px);
}

.project-card-img-wrap {
  position: relative;
  height: 220px;
  overflow: hidden;
}

.project-card-img {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  transition: transform 0.5s ease;
}

.project-card:hover .project-card-img {
  transform: scale(1.05);
}

.project-tag {
  position: absolute;
  top: 16px;
  left: 0;
  background: var(--color-secondary);
  color: var(--color-white);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  padding: 5px 12px;
  z-index: 1;
}

.project-card-body {
  padding: 24px 22px;
}

.project-card-body h3 {
  font-size: 16px;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.project-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.02em;
  color: var(--color-mid);
  margin-bottom: 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.project-meta-sep {
  color: var(--color-rule);
}

.project-card-body p {
  font-size: 13px;
  color: var(--color-mid);
  line-height: 1.65;
}

/* =========================================================
   PROJECT LISTING (full page)
   ========================================================= */
.project-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.filter-btn {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 8px 16px;
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  color: var(--color-mid);
  cursor: pointer;
  transition: all 0.2s ease;
  border-radius: 0;
}

.filter-btn:hover,
.filter-btn.is-active {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
  color: var(--color-white);
}

/* Project table listing */
.project-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.project-table th {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-mid);
  padding: 12px 16px;
  border-bottom: 2px solid var(--color-rule);
  text-align: left;
}

.project-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--color-rule);
  color: var(--color-ink);
}

.project-table tr:hover td {
  background: var(--color-surface);
}

/* =========================================================
   CASE STUDIES
   ========================================================= */
.case-study {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 48px;
  padding: 48px 0;
  border-bottom: 1px solid var(--color-rule);
  align-items: start;
}

.case-study:last-child {
  border-bottom: none;
}

.case-study-meta h3 {
  font-size: 20px;
  color: var(--color-primary);
  margin-bottom: 10px;
}

.case-study-meta .tag {
  display: inline-block;
  background: var(--color-surface);
  border: 1px solid var(--color-rule);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--color-secondary);
  padding: 4px 10px;
  margin-bottom: 16px;
}

.case-study-content .cs-block {
  margin-bottom: 20px;
}

.case-study-content .cs-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-secondary);
  margin-bottom: 6px;
}

.case-study-content p {
  font-size: 14px;
  color: var(--color-mid);
}

/* =========================================================
   ENQUIRY CTA BAND
   ========================================================= */
.cta-band {
  background: var(--color-primary);
  padding-block: var(--section-pad);
  position: relative;
  overflow: hidden;
}

.cta-band::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  right: 0;
  width: min(38vw, 480px);
  background: repeating-linear-gradient(
    45deg,
    rgba(79, 195, 247, 0.06) 0px,
    rgba(79, 195, 247, 0.06) 2px,
    transparent 2px,
    transparent 16px
  );
  pointer-events: none;
}

.cta-content {
  text-align: center;
  max-width: 640px;
  margin-inline: auto;
  position: relative;
  z-index: 1;
  padding: 36px 28px;
}

.cta-content h2 {
  color: var(--color-white);
  margin-bottom: 14px;
}

.cta-content p {
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 32px;
  font-size: 15px;
}

/* =========================================================
   TEAM CARDS
   ========================================================= */
.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--grid-gap);
}

/* Two-person leadership grid (centered). Doubled up on .team-grid so these
   beat the responsive .team-grid column rules further down the file, which
   otherwise drop this two-card pair into a 3 or 4 column track. */
.team-grid.team-grid--duo {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 720px;
  margin-inline: auto;
  align-items: stretch;
}

/* Two portrait cards side by side get too narrow to read below tablet, so the
   pair stacks at the same 768px breakpoint the rest of the site collapses on. */
@media (max-width: 768px) {
  .team-grid.team-grid--duo {
    grid-template-columns: 1fr;
    max-width: 380px;
  }
}

/* The two headshots are supplied at different aspect ratios (one square,
   one portrait). A portrait frame keeps both heads and shoulders fully in
   view: the square crops only its empty side margins, the tall one only a
   little shirt at the bottom. */
.team-grid--duo .team-card-photo {
  height: auto;
  aspect-ratio: 3 / 4;
}

.team-grid--duo .team-card-photo img {
  object-position: center 20%;
}

.team-card {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.team-card-photo {
  height: 260px;
  background: var(--color-surface);
  overflow: hidden;
  position: relative;
}

.team-card-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.team-photo-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #D8E4F0;
  color: var(--color-mid);
  font-size: 11px;
  text-align: center;
  padding: 16px;
  font-family: var(--font-body);
}

.team-card-body {
  padding: 20px;
}

.team-card-body h3 {
  font-size: 16px;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.team-card-body .role {
  font-size: 12px;
  font-family: var(--font-heading);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-secondary);
  margin-bottom: 10px;
}

.team-card-body p {
  font-size: 13px;
  color: var(--color-mid);
  line-height: 1.6;
}

/* =========================================================
   FORMS
   ========================================================= */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-grid--full {
  grid-template-columns: 1fr;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group.span-full {
  grid-column: 1 / -1;
}

.form-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-mid);
}

.form-input,
.form-textarea,
.form-select {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--color-ink);
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  padding: 12px 14px;
  border-radius: 0;
  width: 100%;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  border-color: var(--color-secondary);
  box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.1);
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.6;
}

.form-note {
  font-size: 12px;
  color: var(--color-mid);
  margin-top: 12px;
}

.form-success {
  display: none;
  padding: 20px;
  background: #E8F5E9;
  border: 1px solid #A5D6A7;
  color: #2E7D32;
  font-size: 14px;
  margin-top: 16px;
}

/* Validation states */
.form-input.is-invalid,
.form-textarea.is-invalid,
.form-select.is-invalid {
  border-color: #C62828;
}

.form-input.is-invalid:focus,
.form-textarea.is-invalid:focus,
.form-select.is-invalid:focus {
  border-color: #C62828;
  box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.1);
}

.form-file-label.is-invalid {
  border-color: #C62828;
  border-style: solid;
  color: #C62828;
}

.form-error {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #C62828;
}

/* reCaptcha v3 badge is hidden in favour of the .form-note attribution line
   below each submit button. Google permits this only while that text is
   visible. `visibility` rather than `display` is what Google documents. */
.grecaptcha-badge {
  visibility: hidden;
}

.form-alert {
  display: none;
  padding: 16px 20px;
  background: #FDECEA;
  border: 1px solid #F5B7B1;
  color: #C62828;
  font-size: 14px;
  margin-top: 16px;
}

/* File input */
.form-file-wrap {
  position: relative;
}

.form-file-label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--color-surface);
  border: 1px dashed var(--color-rule);
  cursor: pointer;
  font-size: 13px;
  color: var(--color-mid);
  transition: border-color 0.2s;
}

.form-file-label:hover {
  border-color: var(--color-secondary);
  color: var(--color-secondary);
}

.form-file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

/* =========================================================
   GALLERY
   ========================================================= */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.gallery-item {
  aspect-ratio: 4/3;
  overflow: hidden;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(45%) contrast(1.04);
  transition: transform 0.4s ease, filter 0.4s ease;
}

.gallery-item:hover img,
.gallery-item:focus-visible img {
  transform: scale(1.06);
  filter: none;
}

.gallery-placeholder {
  width: 100%;
  height: 100%;
  background: #D8E4F0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--color-mid);
  text-align: center;
  padding: 8px;
}

/* --- Project-grouped gallery + lightbox (Phase 1) --- */
.gallery-project { margin-bottom: 44px; }
.gallery-project:last-child { margin-bottom: 0; }
.gallery-project-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #D8E4F0;
}
.gallery-project-title {
  margin: 0;
  font-size: 18px;
  color: var(--color-primary);
}
.gallery-project-count {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-mid);
}
.gallery-note {
  margin: -6px 0 14px;
  font-size: 12px;
  font-style: italic;
  color: var(--color-mid);
}
.gallery-item {
  position: relative;
  border: 0;
  padding: 0;
  margin: 0;
  background: #D8E4F0;
  display: block;
  width: 100%;
}
.gallery-item:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}
.gallery-more {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 42, 74, 0.62);
  color: #fff;
  font-size: 22px;
  font-weight: 600;
  pointer-events: none;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(6, 16, 28, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox[hidden] { display: none; }
.lightbox-figure {
  margin: 0;
  max-width: min(92vw, 1200px);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.lightbox-img {
  max-width: 100%;
  max-height: 78vh;
  object-fit: contain;
  background: #0D1F33;
}
.lightbox-caption {
  color: #E4EEF7;
  font-size: 13px;
  text-align: center;
  padding: 0 12px;
}
.lightbox-counter { color: var(--color-accent); margin-left: 8px; }
.lightbox-close,
.lightbox-nav {
  position: absolute;
  background: rgba(255, 255, 255, 0.10);
  color: #fff;
  border: 0;
  cursor: pointer;
  width: 48px;
  height: 48px;
  font-size: 26px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox-close:hover,
.lightbox-nav:hover { background: rgba(255, 255, 255, 0.22); }
.lightbox-close { top: 16px; right: 16px; }
.lightbox-nav { top: 50%; transform: translateY(-50%); }
.lightbox-prev { left: 16px; }
.lightbox-next { right: 16px; }
.lightbox-close:focus-visible,
.lightbox-nav:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}
@media (max-width: 640px) {
  .lightbox-nav { width: 40px; height: 40px; font-size: 22px; }
  .lightbox-prev { left: 6px; }
  .lightbox-next { right: 6px; }
}

/* =========================================================
   MILESTONES / TIMELINE
   ========================================================= */
.timeline {
  position: relative;
  padding-left: 32px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--color-rule);
}

.timeline-item {
  position: relative;
  margin-bottom: 32px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -28px;
  top: 5px;
  width: 10px;
  height: 10px;
  border-radius: 0;
  background: var(--color-accent);
  border: 2px solid var(--color-primary);
}

.timeline-year {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--color-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.timeline-item h3 {
  font-size: 16px;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.timeline-item p {
  font-size: 14px;
  color: var(--color-mid);
}

/* =========================================================
   OPEN ROLES (Careers)
   ========================================================= */
.roles-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.role-card {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  padding: 28px 24px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
  transition: border-left-color 0.2s ease;
  border-left: 4px solid transparent;
}

.role-card:hover {
  border-left-color: var(--color-secondary);
}

.role-title {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.role-meta {
  display: flex;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.02em;
  color: var(--color-mid);
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.role-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.role-desc {
  font-size: 14px;
  color: var(--color-mid);
  line-height: 1.6;
}

/* =========================================================
   CONTACT
   ========================================================= */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 64px;
  align-items: start;
}

.contact-info h3 {
  font-size: 16px;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.contact-info-block {
  margin-bottom: 28px;
}

.contact-info-block p,
.contact-info-block a {
  font-size: 14px;
  color: var(--color-mid);
  line-height: 1.7;
}

.contact-info-block a:hover {
  color: var(--color-secondary);
}

.map-embed {
  width: 100%;
  height: 220px;
  border: 1px solid var(--color-rule);
  background: #D8E4F0;
  margin-top: 24px;
  overflow: hidden;
}

.map-embed iframe {
  width: 100%;
  height: 100%;
  border: none;
  filter: grayscale(1) contrast(1.04);
  transition: filter 0.35s ease;
}

.map-embed:hover iframe {
  filter: none;
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  background: var(--color-dark-surface);
  padding-top: 64px;
  color: rgba(255, 255, 255, 0.6);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand-logo {
  height: 38px;
  width: auto;
  margin-bottom: 16px;
}

.footer-tagline {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.65;
  max-width: 220px;
}

.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--color-accent);
  margin-bottom: 18px;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-col ul a {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
  transition: color 0.2s ease;
}

.footer-col ul a:hover {
  color: var(--color-white);
}

.footer-col address {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.85;
}

.footer-col address a {
  color: rgba(255, 255, 255, 0.55);
  transition: color 0.2s ease;
}

.footer-col address a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-bottom p {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.28);
  line-height: 1;
}

.footer-bottom-links {
  display: flex;
  gap: 20px;
}

.footer-bottom-links a {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.28);
  transition: color 0.2s;
}

.footer-bottom-links a:hover {
  color: rgba(255, 255, 255, 0.6);
}

/* =========================================================
   SCROLL REVEAL
   ========================================================= */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* =========================================================
   UTILITY
   ========================================================= */
.text-center { text-align: center; }
.text-mid    { color: var(--color-mid); }
.text-accent { color: var(--color-accent); }
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-0  { margin-bottom: 0; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1100px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

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

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

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

@media (max-width: 900px) {
  /* Seal would crowd the wrapping headline; eyebrow carries Est. 2001 here */
  .hero-est {
    display: none;
  }

  .services-grid {
    grid-template-columns: 1fr 1fr;
  }

  .projects-grid {
    grid-template-columns: 1fr 1fr;
  }

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

  .stat-item:nth-child(2) { border-right: none; }
  .stat-item:nth-child(3) { border-right: 1px solid rgba(255,255,255,0.1); }

  .case-study {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .contact-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

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

@media (max-width: 768px) {
  /* Nav */
  .nav-links  { display: none; }
  .nav-hamburger { display: flex; }

  /* Hero */
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .hero-actions .btn { width: 100%; text-align: center; }

  /* Stats */
  .stat-number { font-size: 32px; }
  .stat-number--text { font-size: 20px; line-height: 32px; }

  /* Grids */
  .services-grid  { grid-template-columns: 1fr; }
  .projects-grid  { grid-template-columns: 1fr; }
  .clients-grid   { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid   { grid-template-columns: repeat(2, 1fr); }

  /* Forms */
  .form-grid { grid-template-columns: 1fr; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }

  /* Section header */
  .section-header { margin-bottom: 32px; }

  /* Case studies */
  .case-study { padding: 32px 0; }

  /* Roles */
  .role-card {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   BREADCRUMB
   ========================================================= */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-rule);
  margin-bottom: 48px;
}

.breadcrumb a {
  color: var(--color-mid);
  transition: color 0.2s;
}

.breadcrumb a:hover {
  color: var(--color-secondary);
}

.breadcrumb-sep {
  color: var(--color-rule);
}

.breadcrumb-current {
  color: var(--color-secondary);
}

/* =========================================================
   SERVICE ITEM CARDS (sub-pages)
   ========================================================= */
.service-items-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--grid-gap);
}

.service-item-card {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  box-shadow: var(--shadow-card);
  padding: 32px 28px;
  border-top: 3px solid var(--color-secondary);
  position: relative;
  overflow: hidden;
}

.service-item-card::before {
  content: attr(data-num);
  position: absolute;
  top: 12px;
  right: 20px;
  font-family: var(--font-heading);
  font-size: 52px;
  font-weight: 700;
  color: var(--color-surface);
  line-height: 1;
  pointer-events: none;
}

.service-item-icon {
  width: 44px;
  height: 44px;
  background: var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: var(--color-secondary);
}

.service-item-icon svg {
  width: 22px;
  height: 22px;
  stroke: var(--color-secondary);
  fill: none;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-item-card h3 {
  font-size: 17px;
  color: var(--color-primary);
  margin-bottom: 10px;
}

.service-item-card p {
  font-size: 14px;
  color: var(--color-mid);
  line-height: 1.65;
  margin-bottom: 14px;
}

.service-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.service-bullets li {
  font-size: 13px;
  color: var(--color-mid);
  padding-left: 14px;
  position: relative;
}

.service-bullets li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 7px;
  width: 5px;
  height: 5px;
  background: var(--color-accent);
  flex-shrink: 0;
}

/* =========================================================
   RELATED SERVICES (bottom of service sub-pages)
   ========================================================= */
.related-services-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--grid-gap);
}

.related-service-card {
  display: block;
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  padding: 28px 24px;
  border-left: 4px solid transparent;
  transition: border-left-color 0.25s ease, box-shadow 0.25s ease;
}

.related-service-card:hover {
  border-left-color: var(--color-accent);
  box-shadow: var(--shadow-card);
}

.related-service-card h3 {
  font-size: 16px;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.related-service-card p {
  font-size: 13px;
  color: var(--color-mid);
  line-height: 1.6;
  margin-bottom: 16px;
}

/* =========================================================
   WHY US DIFFERENTIATORS GRID
   ========================================================= */
.differentiators-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--grid-gap);
}

.differentiator-item {
  padding: 28px 20px;
  border-top: 2px solid var(--color-accent);
  background: rgba(255,255,255,0.05);
}

.differentiator-item h3 {
  font-size: 15px;
  color: var(--color-white);
  margin-bottom: 8px;
}

.differentiator-item p {
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  line-height: 1.6;
}

/* =========================================================
   SERVICES INDEX — large service overview cards
   ========================================================= */
.service-overview-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
}

.service-overview-item {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 32px;
  align-items: center;
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  padding: 36px 32px;
  border-left: 4px solid transparent;
  transition: border-left-color 0.25s ease, box-shadow 0.25s ease;
}

.service-overview-item:hover {
  border-left-color: var(--color-secondary);
  box-shadow: var(--shadow-card);
  z-index: 1;
}

.service-overview-icon {
  width: 64px;
  height: 64px;
  background: var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.service-overview-icon svg {
  width: 28px;
  height: 28px;
  stroke: var(--color-secondary);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-overview-body h3 {
  font-size: 20px;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.service-overview-body p {
  font-size: 14px;
  color: var(--color-mid);
  margin-bottom: 12px;
  max-width: 580px;
}

.service-overview-body .tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tag-chip {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-secondary);
  background: var(--color-surface);
  border: 1px solid var(--color-rule);
  padding: 4px 10px;
}

@media (max-width: 768px) {
  .service-items-grid    { grid-template-columns: 1fr; }
  .related-services-grid { grid-template-columns: 1fr; }
  .differentiators-grid  { grid-template-columns: 1fr 1fr; }
  .service-overview-item { grid-template-columns: 1fr; gap: 16px; }
  .service-overview-icon { width: 48px; height: 48px; }
}

@media (max-width: 480px) {
  .differentiators-grid  { grid-template-columns: 1fr; }
}

/* =========================================================
   RESPONSIVE (continued)
   ========================================================= */
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-item  { padding: 16px 12px; }
  .team-grid  { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .project-card-img-wrap { height: 180px; }
}

/* =========================================================
   ACCESSIBILITY — FOCUS RINGS  (Item 11)
   ========================================================= */
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

/* Suppress focus ring for mouse users on form controls that have their own style */
.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none; /* handled by border + box-shadow */
}

/* =========================================================
   CURSOR POINTER — interactive non-button elements  (Item 10)
   ========================================================= */
.role-card,
.gallery-item,
.related-service-card,
.service-card,
.project-card,
.form-file-label,
.form-file-input {
  cursor: pointer;
}

/* =========================================================
   CERTIFICATIONS / ACCREDITATIONS  (Item 6)
   ========================================================= */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--grid-gap);
}

/* Two-badge variant: a three column track leaves an empty cell trailing the
   pair, so two centred columns keep the badges near the width they were
   designed for. Doubled up on .certs-grid to beat the responsive rule below. */
.certs-grid.certs-grid--duo {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 760px;
  margin-inline: auto;
}

.cert-badge {
  background: var(--color-white);
  border: 1px solid var(--color-rule);
  border-top: 3px solid var(--color-secondary);
  padding: 28px 20px;
  text-align: center;
}

.cert-badge-icon {
  width: 40px;
  height: 40px;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cert-badge-icon svg {
  width: 36px;
  height: 36px;
  stroke: var(--color-secondary);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cert-badge h4 {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.cert-badge p {
  font-size: 12px;
  color: var(--color-mid);
  line-height: 1.55;
}

.cert-pending {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-mid);
  background: var(--color-surface);
  border: 1px solid var(--color-rule);
  padding: 2px 8px;
  margin-top: 8px;
}

@media (max-width: 768px) {
  .certs-grid,
  .certs-grid.certs-grid--duo { grid-template-columns: 1fr; }
}

/* =========================================================
   PROJECT REGIONAL FILTER  (Item 7)
   ========================================================= */
.filter-group {
  margin-bottom: 8px;
}

.filter-group-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--color-mid);
  margin-bottom: 6px;
}

/* =========================================================
   CASE STUDY CTA LINK  (Item 8)
   ========================================================= */
.case-study-cta {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--color-rule);
}

.case-study-cta a {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-secondary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s ease, gap 0.2s ease;
}

.case-study-cta a:hover {
  color: var(--color-primary);
  gap: 10px;
}

/* =========================================================
   REGIONAL FILTER RESPONSIVE
   ========================================================= */
/* Stacking one chip per row pushed the table two screens down, so the chips
   stay on a wrapping row and give back the horizontal padding instead. */
@media (max-width: 600px) {
  .project-filters {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 6px;
    margin-bottom: 24px;
  }

  .project-filters .filter-btn {
    flex: 0 1 auto;
    padding-inline: 11px;
    letter-spacing: 0.05em;
  }
}

/* =========================================================
   FIELD RECORD COMPONENT KIT  (Plan v2)
   ========================================================= */

/* ---- Blueprint grid on dark sections ---- */
.tech-grid {
  position: relative;
}

.tech-grid::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(79, 195, 247, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79, 195, 247, 0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

.tech-grid > .container {
  position: relative;
}

/* ---- Registration-mark corner ticks ---- */
.corner-ticks {
  position: relative;
}

.corner-ticks::before,
.corner-ticks::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid var(--color-accent);
  pointer-events: none;
  z-index: 2;
}

.corner-ticks::before {
  top: -2px;
  left: -2px;
  border-right: none;
  border-bottom: none;
}

.corner-ticks::after {
  bottom: -2px;
  right: -2px;
  border-left: none;
  border-top: none;
}

/* ---- Dimension-line divider ---- */
.dim-rule {
  position: relative;
  height: 1px;
  background: var(--color-rule);
}

.dim-rule::before,
.dim-rule::after {
  content: '';
  position: absolute;
  top: -4px;
  width: 1px;
  height: 9px;
  background: var(--color-rule);
}

.dim-rule::before { left: 0; }
.dim-rule::after  { right: 0; }

/* ---- Duotone photo treatment (real site photography) ---- */
.photo-frame {
  position: relative;
  overflow: hidden;
  background: var(--color-dark-surface);
}

.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(55%) contrast(1.05);
  transition: filter 0.45s ease;
}

.photo-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(10, 42, 74, 0.28);
  transition: opacity 0.45s ease;
  pointer-events: none;
}

.photo-frame:hover img,
.photo-frame:focus-within img {
  filter: none;
}

.photo-frame:hover::after,
.photo-frame:focus-within::after {
  opacity: 0;
}

/* ---- Technical figure caption ---- */
.fig-caption {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 1;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(13, 31, 51, 0.82);
  padding: 7px 12px;
  line-height: 1.4;
}

/* ---- Transparent nav over home hero ---- */
.site-nav-wrap.nav--transparent {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.site-nav-wrap.nav--transparent.is-scrolled {
  background: var(--color-primary);
}

/* ---- Stats band overlapping the hero ---- */
.stats-bar--overlap {
  background: transparent;
  padding-block: 0;
  position: relative;
  z-index: 5;
  margin-top: -84px;
}

.stats-inner {
  background: var(--color-dark-surface);
  padding: 36px 24px;
  box-shadow: 0 18px 44px rgba(6, 16, 28, 0.35);
}

/* ---- Client logo ribbon (marquee) ---- */
.logo-ribbon {
  background: var(--color-white);
  border-bottom: 1px solid var(--color-rule);
  padding-top: 88px;
  padding-bottom: 44px;
  overflow: hidden;
}

.logo-ribbon-label {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-mid);
  margin-bottom: 32px;
}

.logo-marquee {
  display: flex;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}

.logo-track {
  display: flex;
  align-items: center;
  gap: 88px;
  padding-right: 88px;
  flex-shrink: 0;
  min-width: 100%;
  justify-content: space-around;
  animation: logo-scroll 38s linear infinite;
}

@keyframes logo-scroll {
  to { transform: translateX(-100%); }
}

.logo-marquee:hover .logo-track {
  animation-play-state: paused;
}

.logo-track img {
  height: 56px;
  width: auto;
  flex-shrink: 0;
  filter: grayscale(100%);
  opacity: 0.65;
  transition: filter 0.25s ease, opacity 0.25s ease;
}

.logo-track img:hover {
  filter: none;
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .logo-track {
    animation: none;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    padding-right: 0;
  }

  .logo-track[aria-hidden="true"] {
    display: none;
  }

  .logo-marquee {
    -webkit-mask-image: none;
    mask-image: none;
  }
}

/* =========================================================
   TOUCH DEVICES: no hover, so resolve the desaturate effects
   - Logos and the map render in full colour immediately.
   - Gallery + portrait photos gain colour via a scroll-driven
     "spotlight" as they enter the active band (see script.js,
     which adds .in-view only where hover is unavailable).
   ========================================================= */
@media (hover: none) {
  .client-logo-box img,
  .logo-track img {
    filter: none;
    opacity: 1;
  }

  .map-embed iframe {
    filter: none;
  }

  .gallery-item.in-view img,
  .photo-frame.in-view img {
    filter: none;
  }

  .photo-frame.in-view::after {
    opacity: 0;
  }
}

/* ---- Services as alternating photo rows ---- */
.service-rows {
  display: flex;
  flex-direction: column;
  gap: 72px;
}

.service-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.service-row-media {
  aspect-ratio: 4 / 3;
}

.service-row--flip .service-row-media {
  order: 2;
}

.service-row-body h3 {
  font-size: 26px;
  margin-bottom: 14px;
}

.service-row-body > p {
  font-size: 15px;
  color: var(--color-mid);
  line-height: 1.7;
  margin-bottom: 20px;
  max-width: 480px;
}

.service-row-body .tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

/* ---- Featured case study spotlight ---- */
.spotlight-layout {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 64px;
  align-items: center;
}

.spotlight-layout h2 {
  color: var(--color-white);
  font-size: 30px;
  margin-bottom: 16px;
}

.spotlight-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.spotlight-meta span:not(:last-child)::after {
  content: '/';
  margin-left: 10px;
  color: rgba(255, 255, 255, 0.25);
}

.spotlight-desc {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.75;
  margin-bottom: 32px;
}

.spotlight-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.spotlight-media {
  aspect-ratio: 4 / 3;
}

/* ---- Process strip ---- */
.process-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-left: 1px solid var(--color-rule);
}

.process-step {
  padding: 28px 24px 10px;
  border-right: 1px solid var(--color-rule);
  border-top: 2px solid var(--color-rule);
  position: relative;
}

.process-step::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--color-accent);
}

.process-num {
  display: block;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: 16px;
}

.process-step h3 {
  font-size: 16px;
  margin-bottom: 8px;
}

.process-step p {
  font-size: 13px;
  color: var(--color-mid);
  line-height: 1.6;
}

/* ---- Team photo corner ticks (About leadership) ---- */
.team-grid--duo .team-card-photo::before,
.team-grid--duo .team-card-photo::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid var(--color-accent);
  z-index: 1;
  pointer-events: none;
}

.team-grid--duo .team-card-photo::before {
  top: 10px;
  left: 10px;
  border-right: none;
  border-bottom: none;
}

.team-grid--duo .team-card-photo::after {
  bottom: 10px;
  right: 10px;
  border-left: none;
  border-top: none;
}

/* ---- Responsive: Field Record components ---- */
@media (max-width: 900px) {
  .service-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .service-row--flip .service-row-media {
    order: 0;
  }

  .spotlight-layout {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

/* Five steps across an iPad leaves ~195px a column, which crushes the
   body copy, so the strip becomes a vertical list from tablet down. */
@media (max-width: 1024px) {
  .process-grid {
    grid-template-columns: 1fr;
    border-left: none;
    border-top: 1px solid var(--color-rule);
  }

  .process-step {
    border-right: none;
    border-top: none;
    border-left: 2px solid var(--color-rule);
    padding: 20px 20px 20px 24px;
  }

  .process-step::before {
    top: 0;
    left: -2px;
    width: 2px;
    height: 40px;
  }
}

@media (max-width: 768px) {
  .stats-bar--overlap {
    margin-top: -64px;
  }

  .stats-inner {
    padding: 24px 12px;
  }

  .logo-ribbon {
    padding-top: 72px;
  }

  .logo-track {
    gap: 48px;
    padding-right: 48px;
  }

  .logo-track img {
    height: 40px;
  }

  .service-rows {
    gap: 48px;
  }

  .service-row-body h3 {
    font-size: 22px;
  }

  .spotlight-layout h2 {
    font-size: 24px;
  }

  .cta-content {
    padding: 24px 12px;
  }
}

/* =========================================================
   MOTION LAYER  (Plan v2 round 3)
   ========================================================= */

/* ---- Hero background photo ---- */
.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
  /* Cool and firm up the golden-hour grade toward Steel-and-Sky */
  filter: saturate(0.9) contrast(1.06) brightness(0.97);
  /* Slow Ken Burns push-in; settles just past cover so no edge shows */
  transform: scale(1.02);
  animation: hero-kenburns 24s ease-out both;
  will-change: transform;
}

@keyframes hero-kenburns {
  from { transform: scale(1.12); }
  to   { transform: scale(1.02); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-image {
    animation: none;
    transform: none;
  }
}

/* ---- Hero entrance sequence ---- */
@keyframes hero-rise {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.hero-content > * {
  animation: hero-rise 0.85s cubic-bezier(0.2, 0.7, 0.3, 1) both;
}

.hero-content > *:nth-child(2) { animation-delay: 0.12s; }
.hero-content > *:nth-child(3) { animation-delay: 0.24s; }
.hero-content > *:nth-child(4) { animation-delay: 0.36s; }

@media (prefers-reduced-motion: reduce) {
  .hero-content > * {
    animation: none;
  }
}

/* ---- Wipe reveal for photo frames ----
   The clip lives on the inner .photo-frame, not on the observed .reveal
   wrapper: a fully clipped element never intersects, so the observer
   would never fire. */
.reveal--wipe {
  opacity: 1;
  transform: none;
}

.reveal--wipe .photo-frame {
  height: 100%;
  clip-path: inset(0 100% 0 0);
  transition: clip-path 1s cubic-bezier(0.65, 0.05, 0.36, 1);
}

.service-row--flip .reveal--wipe .photo-frame {
  clip-path: inset(0 0 0 100%);
}

.reveal--wipe.is-visible .photo-frame {
  clip-path: inset(0 0 0 0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal--wipe .photo-frame {
    clip-path: none;
    transition: none;
  }
}

/* ---- Scroll progress bar (injected by script.js) ---- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--color-accent);
  transform: scaleX(0);
  transform-origin: 0 50%;
  z-index: 300;
  pointer-events: none;
}

/* ---- Anchor target for enquiry form ---- */
#enquiry {
  scroll-margin-top: 96px;
}

/* =========================================================
   INDIA COVERAGE MAP  (Phase 4)
   ========================================================= */
.coverage-layout {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 64px;
  align-items: center;
}

.coverage-layout h2 {
  color: var(--color-white);
  font-size: 30px;
  margin-bottom: 16px;
}

.coverage-desc {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.75;
  margin-bottom: 14px;
  max-width: 460px;
}

.coverage-note {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 30px;
}

.coverage-map {
  position: relative;
  width: 100%;
  max-width: 520px;
  margin-inline: auto;
}

.india-svg {
  display: block;
  width: 100%;
  height: auto;
}

/* ---- State pins ---- */
.map-pin {
  position: absolute;
  width: 34px; /* generous touch target; marker itself stays 8px */
  height: 34px;
  transform: translate(-50%, -50%);
  display: block;
}

/* marker square */
.map-pin::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  transform: translate(-50%, -50%);
  background: var(--color-accent);
  box-shadow: 0 0 0 2px rgba(10, 42, 74, 0.9);
  transition: box-shadow 0.2s ease;
}

/* radar pulse ring */
.map-pin::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 16px;
  border: 1px solid var(--color-accent);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.5);
  animation: pin-pulse 2.8s ease-out infinite;
  animation-delay: calc(var(--pin-i, 0) * 0.35s);
  pointer-events: none;
}

@keyframes pin-pulse {
  0%   { transform: translate(-50%, -50%) scale(0.5); opacity: 0.8; }
  70%  { transform: translate(-50%, -50%) scale(2);   opacity: 0; }
  100% { transform: translate(-50%, -50%) scale(2);   opacity: 0; }
}

.map-pin:hover::before,
.map-pin:focus::before {
  box-shadow: 0 0 0 2px var(--color-accent), 0 0 16px rgba(79, 195, 247, 0.8);
}

/* mono tooltip */
.map-pin-tip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.92);
  background: var(--color-dark-surface);
  border: 1px solid rgba(79, 195, 247, 0.4);
  padding: 6px 10px;
  z-index: 3;
}

.map-pin:hover .map-pin-tip,
.map-pin:focus .map-pin-tip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---- Pin entrance cascade (after the map block reveals) ---- */
.coverage-map .map-pin {
  opacity: 0;
}

.coverage-map.is-visible .map-pin {
  animation: pin-in 0.4s ease both;
  animation-delay: calc(0.35s + var(--pin-i, 0) * 90ms);
}

@keyframes pin-in {
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .coverage-map .map-pin {
    opacity: 1;
    animation: none;
  }

  .map-pin::after {
    animation: none;
    display: none;
  }
}

/* Deep-link target: keep filters clear of the sticky nav */
.project-filters {
  scroll-margin-top: 92px;
}

@media (max-width: 900px) {
  .coverage-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .coverage-map {
    max-width: 420px;
  }
}

/* =========================================================
   MOBILE + TABLET OPTIMISATION
   ========================================================= */

/* ---- Text inflation + tap flash ----
   iOS inflates body text when a phone is rotated to landscape unless
   text-size-adjust is pinned; the grey flash on tap is replaced by the
   components' own :active and :focus-visible states. */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  -webkit-tap-highlight-color: rgba(21, 101, 192, 0.12);
}

/* ---- Scrollable data table (projects listing) ---- */
.table-scroll {
  overflow-x: auto;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
}

.table-scroll:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.table-hint {
  display: none;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-mid);
  margin-bottom: 10px;
}

@media (max-width: 900px) {
  /* Below this the five columns would compress into unreadable slivers,
     so the table keeps a floor width and scrolls inside its container. */
  .project-table { min-width: 620px; }
  .table-hint { display: block; }
}

/* ---- Tablet grid density ----
   Lower bound matters: the single-column rule for this grid lives earlier
   in the file, so an unbounded max-width would win at phone widths too. */
@media (min-width: 481px) and (max-width: 1100px) {
  /* Four differentiators across an iPad leaves ~175px a column */
  .differentiators-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---- Narrow phones ---- */
@media (max-width: 480px) {
  /* Long labels such as "Download Full Project List (PDF)" are wider than
     a 320px screen while .btn is nowrap */
  .btn {
    white-space: normal;
    max-width: 100%;
  }

  .page-banner {
    padding: 64px 0;
    min-height: 260px;
  }

  .breadcrumb { margin-bottom: 32px; }

  .hero-content { padding-block: 84px 104px; }

  .service-card      { padding: 28px 22px; }
  .service-item-card { padding: 26px 22px; }
  .project-card-body { padding: 20px 18px; }
  .stats-inner       { padding: 20px 8px; }

  /* The oversized watermark numeral collides with the heading once the
     card is full width */
  .service-item-card::before { font-size: 40px; top: 8px; right: 12px; }

  .cta-content { padding: 20px 0; }
}

/* ---- Landscape phones ----
   A 100svh hero plus 100/140px of vertical padding does not fit in a
   ~375px-tall landscape viewport. */
@media (max-height: 500px) and (orientation: landscape) {
  .hero {
    min-height: auto;
    padding-block: 72px 40px;
  }

  .hero-content { padding-block: 24px; }
  .hero-est     { display: none; }

  .page-banner {
    min-height: auto;
    padding: 56px 0;
  }

  .nav-drawer { padding-block: 16px; }
  .nav-drawer-header { margin-bottom: 20px; }
  .nav-drawer-links a { padding: 11px 0; }
}

/* ---- Form controls on touch ----
   Safari zooms the whole page when a control smaller than 16px receives
   focus, which leaves the user scrolled sideways mid-form. */
@media (max-width: 1024px), (pointer: coarse) {
  .form-input,
  .form-textarea,
  .form-select,
  .form-file-input {
    font-size: 16px;
  }

  .form-input,
  .form-select {
    min-height: 48px;
    padding: 12px 14px;
  }

  .form-file-label {
    font-size: 15px;
    min-height: 48px;
  }

  .form-textarea { min-height: 150px; }
}

/* ---- Touch targets ----
   Pointer-driven layouts can rely on precise cursors; fingers cannot.
   These bring the small controls up to a ~44px comfortable minimum. */
@media (pointer: coarse) {
  .nav-hamburger {
    width: 48px;
    height: 48px;
    margin-right: -8px;
  }

  .nav-drawer-close {
    width: 44px;
    height: 44px;
    margin-right: -10px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .nav-drawer-links a { padding: 18px 0; }

  .filter-btn {
    min-height: 44px;
    padding: 12px 18px;
  }

  .footer-col ul a,
  .footer-col address a,
  .breadcrumb a,
  .contact-info-block a {
    display: inline-block;
    padding-block: 11px;
  }

  .nav-logo { min-height: 44px; }

  /* 11px type sits on a shorter line box, so it needs the deeper pad */
  .footer-bottom-links a {
    display: inline-block;
    padding-block: 13px;
  }

  /* Padding now carries the separation these gaps used to provide */
  .footer-col ul { gap: 0; }
  .footer-bottom-links { gap: 24px; }

  .card-link,
  .case-study-cta a,
  .related-service-card .card-link {
    padding-block: 13px;
  }

  /* Marker stays 8px; only the hit area grows */
  .map-pin {
    width: 44px;
    height: 44px;
  }

  .lightbox-close,
  .lightbox-nav {
    width: 48px;
    height: 48px;
  }

  /* Hover-only affordances never resolve on touch, so pin labels stay on */
  .map-pin-tip {
    opacity: 1;
    transform: translateX(-50%);
    font-size: 9px;
    padding: 4px 7px;
  }
}

/* Tooltips sit outside the map on the narrowest screens; the pins deep-link
   to the same filtered list, so the labels are redundant there. */
@media (pointer: coarse) and (max-width: 560px) {
  .map-pin-tip { display: none; }
}
