:root {
  /* Dark palette (hero, footer, exhibits) */
  --ink: #0a0d0b;
  --ink-2: #121612;
  --ink-3: #1a1f1c;
  --bone: #e8e2d4;
  --bone-dim: #b7b1a3;
  --gold: #c4a56a;

  /* Light palette (page) */
  --paper: #f2efe6;
  --paper-2: #eae6d8;
  --paper-3: #e0dbcb;
  --ink-text: #181c18;
  --ink-dim: #5a6055;
  --gold-deep: #8a6f33;

  --sage: #7c9a78;
  --sage-deep: #48654a;

  /* Semantic (light context by default) */
  --bg: var(--paper);
  --bg-2: var(--paper-2);
  --bg-3: var(--paper-3);
  --fg: var(--ink-text);
  --fg-dim: var(--ink-dim);
  --line: rgba(24, 28, 24, 0.14);
  --line-strong: rgba(24, 28, 24, 0.3);
  --accent: var(--sage-deep);
  --gold-c: var(--gold-deep);

  --font-display: "Barlow", "IBM Plex Sans", Arial, sans-serif;
  --font-body: "IBM Plex Sans", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --header-h: 5.25rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --pad: clamp(1.25rem, 4vw, 4.5rem);
}

/* Dark-context scopes: hero, footer, and data exhibits */
.hero,
.site-footer,
.service-media,
.page-hero,
.engine-panel {
  --bg: var(--ink);
  --bg-2: var(--ink-2);
  --bg-3: var(--ink-3);
  --fg: var(--bone);
  --fg-dim: var(--bone-dim);
  --line: rgba(232, 226, 212, 0.12);
  --line-strong: rgba(232, 226, 212, 0.22);
  --accent: var(--sage);
  --gold-c: var(--gold);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

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

h1,
h2,
h3,
.stat-num,
.panel-stat,
.service-index {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.08;
}

h1 {
  font-size: clamp(2.9rem, 6.4vw, 5.6rem);
  margin: 0 0 1.4rem;
}

h2 {
  font-size: clamp(2rem, 3.8vw, 3.2rem);
  margin: 0 0 1rem;
  text-wrap: balance;
}

h3 {
  font-size: clamp(1.5rem, 2.2vw, 2rem);
  margin: 0 0 0.7rem;
}

p {
  margin: 0 0 1rem;
}

.brand-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 80;
  background: var(--ink-text);
  color: var(--paper);
  padding: 0.5rem 0.8rem;
}

.skip-link:focus {
  top: 0.5rem;
}

/* Loader */
.loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  background: var(--paper);
  color: var(--ink-text);
  transition: opacity 0.7s var(--ease), visibility 0.7s var(--ease);
  /* Lifts the curtain even if script.js never runs */
  animation: loader-failsafe 0.7s var(--ease) 3.2s forwards;
}

.loader.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

@keyframes loader-failsafe {
  to {
    opacity: 0;
    visibility: hidden;
  }
}

.loader-logo {
  width: min(20rem, 62vw);
  clip-path: inset(0 100% 0 0);
  animation: wipe 0.9s var(--ease) 0.1s forwards;
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0;
  z-index: 70;
  background: var(--sage-deep);
}

/* Header: transparent over the dark hero, paper glass over light content */
.site-header {
  --fg: var(--bone);
  --fg-dim: var(--bone-dim);
  --line: rgba(232, 226, 212, 0.12);
  --line-strong: rgba(232, 226, 212, 0.22);
  --accent: var(--sage);
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  /* Pull following content up so the transparent header sits on the hero, not on paper */
  margin-bottom: calc(-1 * var(--header-h));
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0 var(--pad);
  color: var(--fg);
  border-bottom: 1px solid transparent;
  background: transparent;
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease),
    color 0.4s var(--ease), backdrop-filter 0.4s var(--ease);
}

.site-header.is-scrolled {
  --fg: var(--ink-text);
  --fg-dim: var(--ink-dim);
  --line: rgba(24, 28, 24, 0.14);
  --line-strong: rgba(24, 28, 24, 0.3);
  --accent: var(--sage-deep);
  background: rgba(242, 239, 230, 0.86);
  border-bottom-color: var(--line);
  backdrop-filter: blur(16px);
}

.logo {
  display: inline-flex;
  align-items: center;
  flex: none;
  color: var(--fg);
}

/* Colors follow the header: currentColor for sail and lettering, --accent for the lines */
.logo-lockup {
  display: block;
  height: 3.75rem;
  width: auto;
  aspect-ratio: 960 / 366;
}

.nav {
  display: flex;
  gap: 1.35rem;
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.nav a {
  position: relative;
  color: var(--fg-dim);
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.3rem;
  width: 100%;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.nav a:hover {
  color: var(--fg);
}

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

.header-cta {
  margin-left: 0.5rem;
}

.nav-toggle {
  display: none;
  width: 2.4rem;
  height: 2.4rem;
  margin-left: auto;
  border: 0;
  background: transparent;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 1px;
  margin: 0.4rem 0.4rem;
  background: var(--fg);
  transition: transform 0.3s var(--ease);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  padding: 0 1.15rem;
  border: 1px solid var(--line-strong);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: transform 0.35s var(--ease), background 0.35s var(--ease),
    border-color 0.35s var(--ease), color 0.35s var(--ease);
  position: relative;
  overflow: hidden;
}

.btn span {
  position: relative;
  z-index: 1;
  transition: transform 0.35s var(--ease);
}

.btn-small {
  min-height: 2.35rem;
  padding: 0 0.9rem;
}

.btn-primary {
  background: var(--sage);
  border-color: var(--sage);
  color: #08100a;
}

.btn-primary:hover {
  background: #8eae89;
}

.btn-dark {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bone);
}

.btn-dark:hover {
  background: var(--ink-3);
  border-color: var(--ink-3);
}

.btn-ghost {
  background: transparent;
  color: var(--fg);
}

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

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

/* Hero: full-bleed aisle photo, copy lower left, the logo's sail drawn over the right */
.hero {
  position: relative;
  min-height: max(100vh, 44rem);
  display: grid;
  grid-template-rows: 1fr auto;
  padding: calc(var(--header-h) + clamp(1.5rem, 5vh, 4rem)) var(--pad) 1.75rem;
  overflow: hidden;
  background: var(--ink);
  color: var(--fg);
}

.hero-art,
.hero-photo,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-photo {
  overflow: hidden;
}

.hero-img {
  width: 100%;
  height: 112%;
  object-fit: cover;
  filter: saturate(0.85) brightness(0.85);
  transform: scale(1);
  animation: kenburns 28s var(--ease) forwards;
}

/* Dark behind the copy, header, and practice strip; the photo stays open on the right */
.hero-shade {
  background:
    linear-gradient(90deg, rgba(10, 13, 11, 0.92) 0%, rgba(10, 13, 11, 0.74) 36%, rgba(10, 13, 11, 0.22) 68%, rgba(10, 13, 11, 0.42) 100%),
    linear-gradient(180deg, rgba(10, 13, 11, 0.62) 0%, rgba(10, 13, 11, 0) 26%, rgba(10, 13, 11, 0) 62%, rgba(10, 13, 11, 0.86) 100%);
}

/* Sized from the viewBox ratio so it clears the header and practice strip at any height */
.hero-sail {
  position: absolute;
  right: clamp(1rem, 3vw, 3rem);
  bottom: 8.5rem;
  width: min(50vw, calc((100vh - 16rem) * 1.36));
  aspect-ratio: 498 / 366;
  overflow: visible;
}

.sail-frame {
  fill: var(--bone);
}

.sail-line,
.sail-minor {
  fill: none;
  stroke: var(--sage);
}

.sail-line {
  stroke-width: 1.15;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: draw 1.3s var(--ease) forwards;
  animation-delay: calc(0.9s + var(--i) * 90ms);
}

.sail-minor {
  stroke-width: 0.35;
  opacity: 0;
  animation: fadein 1.4s var(--ease) 1.9s forwards;
}

.hero-inner {
  position: relative;
  z-index: 1;
  align-self: end;
  max-width: min(56rem, 100%);
}

.hero h1 {
  font-size: clamp(2.9rem, 5.2vw, 6rem);
}

.hero h1 .line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.22em;
  margin-bottom: -0.12em;
}

/* Beside the sail each line stays whole; below 900px the copy runs full width and wraps */
@media (min-width: 901px) {
  .hero h1 {
    width: max-content;
  }

  .hero h1 .line {
    white-space: nowrap;
  }
}

.hero h1 .line > span {
  display: inline-block;
  padding-bottom: 0.08em;
  transform: translateY(110%);
  animation: lineup 0.9s var(--ease) forwards;
}

.hero h1 .line:nth-child(1) > span {
  animation-delay: 0.9s;
}

.hero h1 .line:nth-child(2) > span {
  animation-delay: 1.05s;
}

.hero h1 .line:nth-child(3) > span {
  animation-delay: 1.2s;
}

.hero h1 .italic {
  font-style: italic;
  color: #d7d0be;
  padding-bottom: 0.32em;
  margin-bottom: -0.16em;
}

.eyebrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 1rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.eyebrow-line {
  width: 2.4rem;
  height: 1px;
  background: var(--accent);
  transform-origin: left;
  animation: growx 0.9s var(--ease) 0.2s both;
}

.lede {
  max-width: 34rem;
  color: var(--fg-dim);
  font-size: 1.08rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.6rem;
}

.hero-meta {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem 2rem;
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}

.hero-area-k {
  display: block;
  margin-bottom: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-area-v {
  display: block;
  max-width: 28rem;
  text-wrap: balance;
  font-size: 1rem;
  line-height: 1.4;
  color: var(--fg);
}

.hero-area:hover .hero-area-v {
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-underline-offset: 0.2em;
}

/* Sections */
.section {
  padding: clamp(4.5rem, 10vw, 8rem) 0;
}

/* Anchor jumps must clear the sticky header */
section[id],
main[id] {
  scroll-margin-top: calc(var(--header-h) + 1rem);
}

.section-inner {
  width: min(1320px, calc(100% - (var(--pad) * 2)));
  margin: 0 auto;
}

/* rem, not ch — ch here would resolve against this wrapper's body font, not the headline */
.section-head {
  max-width: min(36rem, 100%);
  margin-bottom: 3rem;
}

.intro {
  background: var(--bg-2);
}

.intro-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  grid-template-rows: auto 1fr;
  gap: 1rem 4rem;
}

.intro .eyebrow {
  grid-column: 1 / -1;
}

.intro h2 {
  grid-column: 1;
  max-width: 22ch;
  overflow: visible;
  padding-bottom: 0.12em;
}

.intro-copy {
  grid-column: 2;
  align-self: end;
  max-width: 38rem;
  color: var(--fg-dim);
  font-size: 1.2rem;
}

/* Services */
.service {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem 3.5rem;
  align-items: center;
  padding: 3rem 0;
  border-top: 1px solid var(--line);
}

.service:nth-of-type(even) {
  grid-template-columns: 0.85fr 1.15fr;
}

.service:nth-of-type(even) .service-media {
  order: 2;
}

.service:last-child {
  border-bottom: 1px solid var(--line);
}

/* Media panels read as dark exhibits set into the light page */
.service-media {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: var(--ink);
  border: 1px solid rgba(24, 28, 24, 0.22);
  box-shadow: 0 22px 44px -30px rgba(24, 28, 24, 0.45);
}

.service-media img {
  width: 100%;
  height: min(58vh, 560px);
  object-fit: cover;
  object-position: center;
  transform: scale(1);
  transition: transform 1.1s var(--ease);
}

.service:hover .service-media:not([data-video]) img {
  transform: scale(1.03);
}

/* Network clip: lock framing so cover-crop + hover scale cannot shimmer the map */
.service-media[data-video] {
  aspect-ratio: 2 / 1;
}

.service-media[data-video] img,
.service-media[data-video] .service-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: none;
}

.service-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 0.9s var(--ease);
  pointer-events: none;
}

.service-media.is-playing .service-video {
  opacity: 1;
}

.service-media.is-playing img {
  opacity: 0;
}

.service-index {
  position: absolute;
  left: 1rem;
  bottom: 0.8rem;
  font-size: 3.4rem;
  color: var(--bone);
  text-shadow: 0 0 24px rgba(10, 13, 11, 0.8);
  z-index: 1;
}

.service-body p,
.service-body li {
  color: var(--fg-dim);
}

.service-body ul {
  margin: 1.1rem 0 0;
  padding: 0;
  list-style: none;
}

.service-body li {
  position: relative;
  padding: 0.45rem 0 0.45rem 1.1rem;
  border-top: 1px solid var(--line);
  font-size: 0.95rem;
}

.service-body li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1rem;
  width: 0.45rem;
  height: 1px;
  background: var(--accent);
}

/* Evidence: real engine output, framed as report plates */
.evidence {
  background: var(--bg-2);
}

.plate {
  margin: 0 0 2.5rem;
  padding: clamp(1.25rem, 2.4vw, 2.1rem);
  background: #fdfcf8;
  border: 1px solid rgba(24, 28, 24, 0.18);
  box-shadow: 0 26px 52px -34px rgba(24, 28, 24, 0.45);
}

.plate-head {
  max-width: 46rem;
  margin-bottom: 1.5rem;
}

.plate-no {
  display: block;
  margin-bottom: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-c);
}

.plate-head h3 {
  margin-bottom: 0.5rem;
}

.plate-head p {
  margin: 0;
  color: var(--fg-dim);
}

.plate-zoom {
  display: block;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 0.6rem 0;
}

.plate img {
  width: 100%;
  height: auto;
}

.plate figcaption {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: baseline;
  margin-top: 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

.plate-zoom-hint {
  color: var(--gold-c);
}

.plate-zoom:hover + figcaption .plate-zoom-hint {
  border-bottom: 1px solid var(--gold-c);
}

.panel-note a {
  color: var(--gold-c);
  border-bottom: 1px solid rgba(196, 165, 106, 0.5);
}

.panel-note a:hover {
  border-bottom-color: var(--gold-c);
}

.evidence-note {
  max-width: 44rem;
  margin: 0;
  color: var(--fg-dim);
  font-size: 0.95rem;
}

/* Method */
.method {
  background:
    radial-gradient(900px 500px at 90% 10%, rgba(124, 154, 120, 0.12), transparent 50%),
    var(--bg);
}

.method-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3.5rem;
  align-items: start;
}

.method-copy p:not(.eyebrow) {
  color: var(--fg-dim);
  max-width: 38rem;
}

.steps {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
}

.steps li {
  display: grid;
  grid-template-columns: 3rem 1fr;
  gap: 1rem;
  padding: 1.1rem 0;
  border-top: 1px solid var(--line);
}

.steps li span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.steps p {
  margin: 0.25rem 0 0;
}

.method-media {
  margin: 4.6rem 0 0;
  position: sticky;
  top: calc(var(--header-h) + 1.5rem);
}

.method-media img {
  width: 100%;
  height: 460px;
  object-fit: cover;
  border: 1px solid rgba(24, 28, 24, 0.18);
}

.method-media figcaption {
  margin-top: 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

/* Engine */
.engine {
  background: var(--bg-2);
}

.engine-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem;
  align-items: center;
}

.engine-lede {
  color: var(--fg-dim);
  max-width: 36rem;
  font-size: 1.12rem;
}

.engine-points {
  display: grid;
  gap: 1rem;
  margin: 1.8rem 0 2rem;
}

.engine-points strong {
  display: block;
  margin-bottom: 0.2rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.engine-points p {
  margin: 0;
  color: var(--fg-dim);
}

/* Engine panel as a dark exhibit */
.engine-panel {
  padding: 1.6rem;
  border: 1px solid rgba(24, 28, 24, 0.22);
  background: var(--ink);
  color: var(--fg);
  box-shadow: 0 26px 52px -32px rgba(24, 28, 24, 0.5);
}

.panel-kicker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-c);
}

.panel-stat {
  margin: 0;
  font-size: clamp(4rem, 8vw, 6.5rem);
  color: var(--fg);
}

.panel-note {
  color: var(--fg-dim);
  max-width: 28rem;
}

.engine-panel img {
  margin-top: 1.2rem;
  width: 100%;
  height: 180px;
  object-fit: cover;
  filter: saturate(0.85);
}

/* Stats */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
}

.stats li {
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
}

.stat-num {
  display: block;
  font-size: clamp(3.4rem, 7vw, 5.6rem);
}

.stat-label {
  display: block;
  margin-top: 0.5rem;
  color: var(--fg-dim);
  max-width: 16rem;
}

/* Closing call to action */
.cta-band {
  position: relative;
  overflow: hidden;
  padding: clamp(3.5rem, 7vw, 5.5rem) 0;
  background: var(--sage);
  color: #08100a;
}

.cta-band-inner {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 2rem 4rem;
  align-items: end;
}

.cta-band h2 {
  max-width: 18ch;
  margin: 0;
  font-size: clamp(2.2rem, 4.6vw, 3.8rem);
}

.cta-band p {
  margin-bottom: 1.2rem;
  font-size: 1.1rem;
}

/* Team */
.team {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.person {
  padding: 1.8rem 0 0;
  border-top: 1px solid var(--line);
}

.person-media {
  margin-bottom: 1.4rem;
  overflow: hidden;
  background: var(--bg-3);
}

.person-media img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform 0.7s var(--ease), filter 0.7s var(--ease);
  will-change: transform;
}

.person:hover .person-media img {
  transform: scale(1.06);
  filter: brightness(1.06);
}

.role {
  margin-top: -0.35rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.person p:last-of-type {
  color: var(--fg-dim);
}

.person a {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-c);
  border-bottom: 1px solid transparent;
}

.person a:hover {
  border-bottom-color: var(--gold-c);
}

/* Contact */
.contact {
  background: var(--bg-2);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 3rem;
}

.contact-mail {
  margin-top: 1.6rem;
  font-size: 1.15rem;
}

.contact-mail a {
  border-bottom: 1px solid var(--accent);
}

.brief-form {
  display: grid;
  gap: 1rem;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.brief-form label {
  display: grid;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

.brief-form input,
.brief-form select,
.brief-form textarea {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line-strong);
  background: transparent;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.65rem 0;
  outline: none;
  transition: border-color 0.3s var(--ease);
}

.brief-form input:focus,
.brief-form select:focus,
.brief-form textarea:focus {
  border-bottom-color: var(--accent);
}

.brief-form select {
  border-radius: 0;
}

.brief-form .btn {
  justify-self: start;
  margin-top: 0.4rem;
}

.form-note {
  color: var(--gold-c);
}

.form-note.is-error {
  color: #9a3b2a;
}

.form-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Footer */
.site-footer {
  padding: clamp(3rem, 6vw, 4.5rem) 0 1.75rem;
  background: var(--ink);
  color: var(--fg-dim);
  font-size: 0.95rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.7fr 1fr 1fr 1.2fr;
  gap: 2.5rem;
  align-items: start;
}

.footer-logo {
  display: inline-block;
  margin-bottom: 1.2rem;
  color: var(--bone);
}

.footer-logo .logo-lockup {
  height: 5.5rem;
}

.footer-brand p {
  max-width: 19rem;
  margin: 0;
}

.footer-col {
  display: grid;
  gap: 0.45rem;
  justify-items: start;
}

.footer-head {
  margin-bottom: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.footer-col a {
  transition: color 0.25s var(--ease);
}

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

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* 404 */
.notfound {
  min-height: 100vh;
  display: grid;
  align-content: center;
  padding: 0 var(--pad);
}

.notfound-logo {
  position: absolute;
  top: 1.25rem;
  left: var(--pad);
}

.notfound h1 {
  max-width: 14ch;
}

/* Reveal — gated on .js so content is never hidden when script.js is absent */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  animation: rise 0.95s var(--ease) forwards;
  animation-delay: var(--d, 0ms);
  animation-play-state: paused;
}

.js [data-reveal].is-in,
.js .hero-meta[data-reveal] {
  animation-play-state: running;
}

/* Split text */
.split .line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.22em;
  margin-bottom: -0.12em;
}

.split .line > span {
  display: inline-block;
  padding-bottom: 0.08em;
  transform: translateY(110%);
}

.split.is-in .line > span {
  animation: lineup 0.9s var(--ease) forwards;
}

.split.is-in .line:nth-child(1) > span {
  animation-delay: 0.9s;
}

.split.is-in .line:nth-child(2) > span {
  animation-delay: 1.05s;
}

.split.is-in .line:nth-child(3) > span {
  animation-delay: 1.2s;
}

/* Keyframes */
@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes lineup {
  to {
    transform: translateY(0);
  }
}

@keyframes kenburns {
  to {
    transform: scale(1.04);
  }
}

@keyframes wipe {
  to {
    clip-path: inset(0 0 0 0);
  }
}

@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes growx {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

@keyframes fadein {
  to {
    opacity: 1;
  }
}

/* Responsive */
@media (max-width: 900px) {
  .nav,
  .header-cta {
    display: none;
  }

  .nav.is-open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 1rem;
    padding: 1.2rem var(--pad) 1.4rem;
    background: var(--paper);
    border-bottom: 1px solid rgba(24, 28, 24, 0.14);
  }

  .nav.is-open a {
    color: var(--ink-dim);
  }

  .nav.is-open a:hover {
    color: var(--ink-text);
  }

  .nav-toggle {
    display: block;
  }

  .hero {
    grid-template-rows: 1fr auto;
    min-height: max(100vh, 44rem);
  }

  .hero-inner {
    max-width: none;
  }

  /* The copy spans the full width here, so the photo alone carries the hero */
  .hero-sail {
    display: none;
  }

  .hero-shade {
    background: linear-gradient(180deg, rgba(10, 13, 11, 0.62) 0%, rgba(10, 13, 11, 0.5) 30%, rgba(10, 13, 11, 0.86) 62%, rgba(10, 13, 11, 0.95) 100%);
  }

  .hero-meta,
  .intro-grid,
  .service,
  .service:nth-of-type(even),
  .cta-band-inner,
  .method-grid,
  .engine-grid,
  .stats,
  .team,
  .contact-grid,
  .field-row {
    grid-template-columns: 1fr;
  }

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

  .footer-brand {
    grid-column: 1 / -1;
  }

  .service:nth-of-type(even) .service-media {
    order: 0;
  }

  .intro .eyebrow,
  .intro h2,
  .intro-copy {
    grid-column: auto;
  }

  .hero-meta {
    margin-top: 3rem;
  }

  .method-media {
    margin-top: 0;
    position: static;
  }

  .method-media img {
    height: 240px;
  }

  .service-media img {
    height: min(42vh, 320px);
  }

  .plate {
    padding: 1rem;
  }
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .js [data-reveal],
  .split .line > span,
  .hero h1 .line > span {
    opacity: 1;
    transform: none;
  }

  .hero-img {
    transform: none;
  }

  .sail-line {
    stroke-dashoffset: 0;
  }

  .sail-minor {
    opacity: 1;
  }

  .loader {
    display: none;
  }

  .service-video {
    display: none;
  }
}

/* Client portal entry points */
.nav .nav-login {
  color: var(--fg);
  padding-left: 1.35rem;
  border-left: 1px solid var(--line-strong);
}

@media (max-width: 900px) {
  .nav.is-open .nav-login {
    padding-left: 0;
    border-left: 0;
  }
}

/* Services dropdown */
.nav {
  align-items: center;
}

.nav-item {
  position: relative;
}

.nav-parent {
  padding-right: 0.95rem;
}

.nav-parent::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0.2rem;
  width: 0.35rem;
  height: 0.35rem;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(45deg);
}

.nav-menu {
  --fg: var(--ink-text);
  --fg-dim: var(--ink-dim);
  --accent: var(--sage-deep);
  position: absolute;
  top: 100%;
  left: -1rem;
  min-width: 13rem;
  display: grid;
  gap: 0.9rem;
  margin-top: 0.9rem;
  padding: 1rem;
  background: var(--paper);
  border: 1px solid rgba(24, 28, 24, 0.14);
  box-shadow: 0 18px 36px -24px rgba(24, 28, 24, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), visibility 0.25s;
}

/* Bridge the gap so the pointer can travel from the label into the menu */
.nav-menu::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 0.9rem;
}

.nav-item:hover .nav-menu,
.nav-item:focus-within .nav-menu {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.nav a[aria-current="page"] {
  color: var(--fg);
}

/* Inner-page banner: dark like the hero so the transparent header reads on load */
.page-hero {
  position: relative;
  overflow: hidden;
  padding: calc(var(--header-h) + clamp(3rem, 7vw, 5.5rem)) 0 clamp(3rem, 6vw, 5rem);
  background: var(--ink);
  color: var(--fg);
}

.page-hero::after {
  content: "";
  position: absolute;
  right: clamp(-6rem, -4vw, -1rem);
  bottom: -7%;
  width: min(56vw, 52rem);
  aspect-ratio: 498 / 366;
  background: url("images/brand/sail-art.svg") center / contain no-repeat;
  opacity: 0.55;
  pointer-events: none;
}

.page-hero .section-inner {
  position: relative;
  z-index: 1;
}

.page-hero h1 {
  max-width: 18ch;
  font-size: clamp(2.6rem, 5.4vw, 4.6rem);
}

/* Services overview */
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-card {
  display: flex;
  flex-direction: column;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
  transition: border-color 0.35s var(--ease);
}

.service-card:hover {
  border-top-color: var(--accent);
}

.service-card p {
  color: var(--fg-dim);
}

.service-card-no {
  margin-bottom: 1rem;
  font-family: var(--font-display);
  font-size: 2.6rem;
  color: var(--gold-c);
}

.service-link {
  margin-top: auto;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

@media (max-width: 900px) {
  .nav.is-open {
    align-items: stretch;
  }

  .nav.is-open .nav-menu {
    position: static;
    min-width: 0;
    margin: 0.8rem 0 0;
    padding: 0 0 0 1rem;
    gap: 0.8rem;
    background: none;
    border: 0;
    border-left: 1px solid rgba(24, 28, 24, 0.14);
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav.is-open .nav-menu::before,
  .nav.is-open .nav-parent::before {
    display: none;
  }

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

/* Storage Strategy sub-pages */
.subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.8rem;
  margin-top: 2.6rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.subnav a {
  padding-bottom: 0.3rem;
  border-bottom: 1px solid transparent;
  color: var(--fg-dim);
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.subnav a:hover {
  color: var(--fg);
}

.subnav a[aria-current="page"] {
  color: var(--fg);
  border-bottom-color: var(--accent);
}

.walk {
  background: var(--bg-2);
}

.walk-grid {
  display: grid;
  grid-template-columns: 12rem minmax(0, 1fr);
  gap: 4rem;
  align-items: start;
}

.rail {
  position: sticky;
  top: calc(var(--header-h) + 2rem);
}

.rail-title {
  margin-bottom: 1rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.rail ol {
  margin: 0;
  padding: 0;
  list-style: none;
  border-left: 1px solid var(--line);
}

.rail a {
  display: flex;
  gap: 0.8rem;
  margin-left: -1px;
  padding: 0.55rem 0 0.55rem 1.1rem;
  border-left: 1px solid transparent;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-dim);
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.rail a span {
  color: var(--gold-c);
}

.rail a:hover,
.rail a.is-active {
  color: var(--fg);
  border-left-color: var(--accent);
}

.stage,
.chapter {
  padding-bottom: clamp(3.5rem, 7vw, 5.5rem);
}

.stage + .stage,
.chapter + .chapter {
  padding-top: clamp(3.5rem, 7vw, 5.5rem);
  border-top: 1px solid var(--line);
}

.stage-no {
  display: block;
  margin-bottom: 0.6rem;
  font-family: var(--font-display);
  font-size: 2.6rem;
  line-height: 1;
  color: var(--gold-c);
}

.stage-lead {
  max-width: 40rem;
  color: var(--fg-dim);
  font-size: 1.12rem;
}

.stage-note {
  max-width: 40rem;
  margin: 1.6rem 0 0;
  color: var(--fg-dim);
  font-size: 0.95rem;
}

.stage .plate {
  margin: 2.5rem 0 0;
}

.spec {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.spec li {
  display: grid;
  grid-template-columns: 13rem 7rem minmax(0, 1fr);
  gap: 1.5rem;
  align-items: baseline;
  padding: 1.1rem 0;
  border-bottom: 1px solid var(--line);
}

.spec strong {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 500;
}

.spec p {
  margin: 0;
  color: var(--fg-dim);
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.tag-opt {
  color: var(--fg-dim);
}

.spec-sample {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-c);
}

.checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  margin-top: 2rem;
}

.checks h3,
.note h4 {
  margin: 0 0 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.ticks {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ticks li {
  position: relative;
  padding: 0.5rem 0 0.5rem 1.1rem;
  border-top: 1px solid var(--line);
  color: var(--fg-dim);
  font-size: 0.95rem;
}

.ticks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.05rem;
  width: 0.45rem;
  height: 1px;
  background: var(--accent);
}

.bins {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 2rem 0 0;
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line);
}

.bins div {
  padding: 1rem 0.5rem 0.9rem 0;
}

.bins div + div {
  padding-left: 1rem;
  border-left: 1px solid var(--line);
}

.bins strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  font-weight: 500;
}

.bins span,
.bins-caption {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

.bins-caption {
  margin: 0.7rem 0 0;
}

.table-wrap {
  margin-top: 2rem;
  overflow-x: auto;
}

.params {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
}

.params thead th {
  padding: 0 1rem 0.7rem 0;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-align: left;
  text-transform: uppercase;
  color: var(--fg-dim);
}

.params tbody th,
.params td {
  padding: 0.9rem 1rem 0.9rem 0;
  border-top: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.params tbody th {
  width: 14rem;
  font-weight: 500;
}

.params td {
  color: var(--fg-dim);
}

.params td:last-child {
  width: 10rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--fg);
}

.callout {
  max-width: 40rem;
  margin: 2rem 0 0;
  padding-left: 1.2rem;
  border-left: 2px solid var(--accent);
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: 1.4;
}

.fit-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.fit-stats li {
  padding-top: 1rem;
  border-top: 1px solid var(--line-strong);
}

.fit-num {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.3rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.fit-label {
  display: block;
  margin-top: 0.3rem;
  color: var(--fg);
}

.fit-from {
  display: block;
  margin-top: 0.3rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--fg-dim);
}

.plate-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.plate-pair .plate-head h3 {
  font-size: 1.35rem;
}

.plate-dark {
  --fg: var(--bone);
  --fg-dim: var(--bone-dim);
  --line: rgba(232, 226, 212, 0.12);
  --gold-c: var(--gold);
  background: var(--ink);
  color: var(--fg);
}

.deliverables {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 2rem;
  margin: 2.5rem 0 0;
  padding: 0;
  list-style: none;
}

.deliverables li {
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}

.deliverables strong {
  display: block;
  margin-bottom: 0.25rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 500;
}

.deliverables p {
  margin: 0;
  color: var(--fg-dim);
}

.stage .cta-row {
  margin-top: 2.2rem;
}

/* Sample report: figure with margin notes */
.chapter-head {
  margin-bottom: 2rem;
}

.sheet {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 15rem;
  gap: 2rem;
  align-items: start;
  margin-bottom: 2.5rem;
}

.sheet .plate {
  margin: 0;
}

.note {
  padding-top: 1.2rem;
  border-top: 1px solid var(--line-strong);
}

.note p {
  color: var(--fg-dim);
  font-size: 0.95rem;
}

.note p + h4 {
  margin-top: 1.4rem;
}

.report-close {
  max-width: 44rem;
  margin-bottom: 2rem;
  padding-top: clamp(2.5rem, 5vw, 3.5rem);
  border-top: 1px solid var(--line);
}

.report-close p {
  color: var(--fg-dim);
}

@media (max-width: 1100px) {
  .sheet {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }

  .note {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-flow: column;
    grid-template-rows: auto auto;
    gap: 0 2rem;
  }

  .note p + h4 {
    margin-top: 0;
  }
}

@media (max-width: 900px) {
  .walk-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .rail {
    display: none;
  }

  .spec li {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }

  .checks,
  .plate-pair,
  .deliverables {
    grid-template-columns: 1fr;
  }

  .note {
    display: block;
  }

  .note p + h4 {
    margin-top: 1.2rem;
  }

  .fit-stats {
    grid-template-columns: 1fr 1fr;
  }

  .bins div + div {
    padding-left: 0.6rem;
  }
}

/* Consulting: operations assessment detail */
.service-tagline {
  color: var(--fg);
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: 1.35;
}

.assessment {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 3.5rem;
  padding: 0.4rem 0 2.8rem;
}

.assessment h4 {
  margin: 0 0 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.assessment .steps {
  margin: 0;
}

.assessment .steps li {
  grid-template-columns: 4.5rem 1fr;
}

.assessment .steps p {
  color: var(--fg-dim);
}

@media (max-width: 900px) {
  .assessment {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* Storage Strategy: Bay Creator page */
.bc-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  gap: 3rem;
  align-items: end;
  margin-bottom: 3rem;
}

.bc-intro h2 {
  max-width: 16ch;
}

.plate-shot .plate-zoom {
  padding: 0;
  border: 1px solid rgba(24, 28, 24, 0.18);
}

.bc-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin: 0 0 3rem;
  padding: 0;
  list-style: none;
}

.bc-steps li {
  padding-top: 1rem;
  border-top: 1px solid var(--line-strong);
}

.bc-steps .stage-no {
  font-size: 2rem;
}

.bc-steps h3 {
  font-size: 1.3rem;
}

.bc-steps p {
  margin: 0;
  color: var(--fg-dim);
  font-size: 0.95rem;
}

.bc-note {
  margin-top: 2rem;
}

.inline-link {
  color: var(--accent);
  border-bottom: 1px solid currentColor;
}

@media (max-width: 1100px) {
  .bc-steps {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 900px) {
  .bc-intro {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

@media (max-width: 560px) {
  .bc-steps {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .page-hero::after {
    width: 92vw;
    opacity: 0.2;
  }
}
