/* Blau & co. ------------------------------------------------------------
   Ink and paper, one ultramarine. Newsreader for authority,
   IBM Plex Sans for legibility, IBM Plex Mono for rigor.
   ---------------------------------------------------------------------- */

:root {
  /* Color */
  --ink:        #0E0E10;
  --ink-soft:   #35353C;
  --muted:      #6B6B75;
  --paper:      #FFFFFF;
  --wash:       #F1F3FA;
  --wash-deep:  #E4E8F6;
  --rule:       #DEDFE6;
  --blau:       #002FA7;
  --blau-lift:  #2A55D8;

  /* The one accent, as a five step ramp */
  --blau-5: #002FA7;
  --blau-4: #4062BE;
  --blau-3: #8098D4;
  --blau-2: #BFCBE9;
  --blau-1: #E4E9F6;

  /* Type */
  --display: "Montserrat", "Avenir Next", "Century Gothic", Helvetica, Arial, sans-serif;
  --sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --label: "Montserrat", "Avenir Next", "Century Gothic", Helvetica, Arial, sans-serif;
  /* --mono kept as an alias so existing rules resolve to the label face. */
  --mono: var(--label);

  /* Space */
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --measure: 62ch;
  --rail: 172px;
  --shell: 1240px;
  --section-y: clamp(4.5rem, 9vw, 8.5rem);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.62;
  font-synthesis-weight: none;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

::selection { background: var(--blau); color: #fff; }

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

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: #fff;
  padding: .75rem 1rem; z-index: 100;
  font-family: var(--mono); font-size: .75rem;
}
.skip:focus { left: 0; }

/* Type primitives ------------------------------------------------------ */
h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

/* Optical sizing: a geometric sans needs less weight as it gets larger.
   600 holds a section heading; at display size it starts to shout. */
h1 { font-weight: 500; letter-spacing: -0.035em; }

h1 { font-size: clamp(2.6rem, 6.4vw, 4.9rem); }
h2 { font-size: clamp(2rem, 4.2vw, 3.15rem); }
h3 { font-size: clamp(1.35rem, 2.2vw, 1.75rem); line-height: 1.2; }

h1 em, h2 em, h3 em { font-style: normal; font-weight: 700; color: var(--blau); }

p { text-wrap: pretty; }

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

.eyebrow {
  font-family: var(--mono);
  font-size: .6875rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--blau);
  display: block;
}

.lede {
  font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: var(--measure);
}

.prose p { color: var(--ink-soft); max-width: var(--measure); }
.prose p + p { margin-top: 1.1em; }

.muted { color: var(--muted); }

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

.section { padding-block: var(--section-y); }
.section--wash { background: var(--wash); }
.section--ink { background: var(--ink); color: var(--paper); }
.section--ink .lede,
.section--ink .prose p { color: #C9C9D2; }
.section--ink .eyebrow { color: var(--blau-3); }
.section--ink a { color: #fff; }

/* The memo rail: mono metadata in a narrow left margin, content at right */
.railed { display: grid; gap: 2rem clamp(1.5rem, 4vw, 3.5rem); }
@media (min-width: 900px) {
  .railed { grid-template-columns: var(--rail) minmax(0, 1fr); }
}
.railed__rail {
  font-family: var(--mono);
  font-size: .6875rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: .55rem;
  border-top: 2px solid var(--blau);
  align-self: start;
}
.section--ink .railed__rail { color: #8A8A96; }

/* Header --------------------------------------------------------------- */
.masthead {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--rule);
}
.masthead__inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 74px;
}

.wordmark {
  display: inline-block;
  line-height: 0;
  text-decoration: none;
  border-bottom: 2px solid var(--blau);
  padding-bottom: 7px;
}
.wordmark img {
  display: block;
  height: 1.375rem;
  width: auto;
}

.nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2rem); }
/* :not(.btn) matters — these rules out-specify .btn--line, and without it
   the Contact button loses its bottom border to the transparent underline. */
.nav a:not(.btn) {
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  text-decoration: none;
  padding-block: .35rem;
  border-bottom: 1px solid transparent;
}
.nav a:not(.btn):hover { color: var(--blau); border-bottom-color: var(--blau); }
.nav a:not(.btn)[aria-current="page"] { color: var(--blau); border-bottom-color: var(--blau); }
.nav__set { display: contents; }

/* Below 1080 the link set moves behind the toggle, so the bar stays on a
   single row instead of wrapping to two. See "Mobile navigation" below. */
@media (max-width: 1080px) {
  .masthead__inner { min-height: 66px; padding-block: .7rem; }
  .nav .btn { padding: .6rem 1rem; }
}

/* Buttons -------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--mono);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-decoration: none;
  padding: .85rem 1.35rem;
  border: 1px solid var(--blau);
  border-radius: 2px;
  transition: background .18s ease, color .18s ease, transform .18s ease;
}
.btn--solid { background: var(--blau); color: #fff; }
.btn--solid:hover { background: var(--ink); border-color: var(--ink); color: #fff; transform: translateY(-1px); }
.btn--line { background: transparent; color: var(--blau); }
.btn--line:hover { background: var(--blau); color: #fff; transform: translateY(-1px); }
.section--ink .btn--line { border-color: #fff; color: #fff; }
.section--ink .btn--line:hover { background: #fff; color: var(--ink); }
.btn__arrow { transition: transform .18s ease; }
.btn:hover .btn__arrow { transform: translateX(3px); }

.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Hero ----------------------------------------------------------------- */
.hero { padding-block: clamp(3.5rem, 8vw, 7rem) clamp(3rem, 6vw, 5rem); }
.hero h1 { margin-top: 1.5rem; max-width: 16ch; }
.hero .lede { margin-top: 1.75rem; }
.hero .btn-row { margin-top: 2.25rem; }

/* Signature: the diligence scope ---------------------------------------- */
.scope { margin-top: clamp(3.5rem, 7vw, 6rem); border-top: 1px solid var(--rule); }

.scope__row {
  display: grid;
  gap: .5rem 1.75rem;
  padding-block: 1.5rem;
  border-bottom: 1px solid var(--rule);
  align-items: baseline;
}
@media (min-width: 800px) {
  .scope__row { grid-template-columns: minmax(0, 17rem) minmax(0, 1fr); }
}
.scope__name {
  font-family: var(--display);
  font-size: clamp(1.45rem, 2.6vw, 2.05rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
}
.scope__what { color: var(--ink-soft); font-size: .9375rem; line-height: 1.5; }


.scope__legend {
  display: flex; flex-wrap: wrap; gap: .75rem 1.5rem;
  margin-top: 1.25rem;
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}


/* Sequence -------------------------------------------------------------- */
.seq { display: grid; gap: 0; }
.seq__step {
  display: grid;
  gap: .5rem 1.75rem;
  padding-block: 1.75rem;
  border-top: 1px solid var(--rule);
  align-items: start;
}
@media (min-width: 800px) {
  .seq__step { grid-template-columns: 4.5rem minmax(0, 20rem) minmax(0, 1fr); }
}
.seq__step:last-child { border-bottom: 1px solid var(--rule); }
.seq__n {
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .08em;
  color: var(--blau);
  padding-top: .35rem;
}
.seq__t { font-family: var(--display); font-size: clamp(1.3rem, 2vw, 1.6rem); line-height: 1.15; }
.seq__d { color: var(--ink-soft); font-size: .9375rem; line-height: 1.6; max-width: 54ch; }

/* Case study ------------------------------------------------------------ */
.case { display: grid; gap: clamp(2rem, 4vw, 3.5rem); }
@media (min-width: 940px) { .case { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); } }

.case__facts { border-top: 2px solid var(--blau); }
.case__fact {
  display: grid; grid-template-columns: 8.5rem minmax(0,1fr);
  gap: 1rem; padding-block: .8rem;
  border-bottom: 1px solid var(--rule);
  font-size: .9375rem;
}
.case__fact dt {
  font-family: var(--mono); font-size: .6875rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); padding-top: .18rem;
}
.case__fact dd { color: var(--ink); }
.case__logo { margin-top: 2rem; width: 210px; }

.quote { margin-top: 2.5rem; border-left: 2px solid var(--blau); padding-left: clamp(1.25rem, 3vw, 2rem); }
.quote p {
  font-family: var(--display);
  font-size: clamp(1.25rem, 2.1vw, 1.6rem);
  line-height: 1.34;
  letter-spacing: -0.012em;
}
.quote footer {
  margin-top: 1.15rem;
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.7;
}

/* Cards ----------------------------------------------------------------- */
.cards { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); }
@media (min-width: 780px) { .cards--2 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .cards--3 { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: var(--paper);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  display: flex; flex-direction: column; gap: .85rem;
  text-decoration: none; color: inherit;
  transition: background .2s ease;
}
a.card:hover { background: var(--wash); }
.card__k { font-family: var(--mono); font-size: .6875rem; letter-spacing: .1em; text-transform: uppercase; color: var(--blau); }
.card h3 { letter-spacing: -0.015em; }
.card p { color: var(--ink-soft); font-size: .9375rem; line-height: 1.6; }
.card__go {
  margin-top: auto; padding-top: .5rem;
  font-family: var(--mono); font-size: .6875rem;
  letter-spacing: .1em; text-transform: uppercase; color: var(--blau);
}
.section--wash .cards { background: var(--rule); }
.section--wash .card { background: var(--paper); }

/* Checklist ------------------------------------------------------------- */
.checks { display: grid; gap: .7rem; padding: 0; list-style: none; }
.checks li {
  display: grid; grid-template-columns: 1.5rem minmax(0,1fr); gap: .5rem;
  font-size: .9375rem; line-height: 1.55; color: var(--ink-soft);
}
.checks li::before {
  content: ""; width: 9px; height: 9px; margin-top: .48rem;
  background: var(--blau); border-radius: 1px;
}

/* Person ---------------------------------------------------------------- */
.person { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (min-width: 860px) { .person { grid-template-columns: minmax(0, 320px) minmax(0, 1fr); } }
.person__figure {
  background: var(--wash);
  border-bottom: 3px solid var(--blau);
}
.person__photo {
  width: 100%;
  filter: grayscale(1) contrast(1.04);
  mix-blend-mode: multiply;
}

/* Contact --------------------------------------------------------------- */
.reach { display: grid; gap: 1px; padding: 1px; background: rgba(255,255,255,.16); margin-top: 2.75rem; }
@media (min-width: 720px) { .reach { grid-template-columns: repeat(3, 1fr); } }
.reach a {
  background: var(--ink);
  padding: 1.4rem 1.5rem;
  text-decoration: none;
  display: flex; flex-direction: column; gap: .4rem;
  transition: background .2s ease;
}
.reach a:hover { background: #191921; }
.reach__k { font-family: var(--mono); font-size: .6875rem; letter-spacing: .1em; text-transform: uppercase; color: var(--blau-3); }
.reach__v { color: #fff; font-size: 1.0625rem; }

/* Footer ---------------------------------------------------------------- */
.footer { border-top: 1px solid var(--rule); padding-block: 3rem 2.5rem; }
.footer__grid { display: grid; gap: 2rem; }
@media (min-width: 780px) { .footer__grid { grid-template-columns: minmax(0,1fr) auto; align-items: start; } }
.footer__nav { display: flex; flex-wrap: wrap; gap: .6rem 1.5rem; }
.footer__nav a {
  font-family: var(--mono); font-size: .6875rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-soft); text-decoration: none;
}
.footer__nav a:hover { color: var(--blau); }
.footer__fine {
  margin-top: 2.25rem; padding-top: 1.5rem; border-top: 1px solid var(--rule);
  font-family: var(--mono); font-size: .6875rem; letter-spacing: .06em; color: var(--muted);
  display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between;
}

/* Page head ------------------------------------------------------------- */
.pagehead { padding-block: clamp(3rem, 6.5vw, 5.5rem) clamp(2rem, 4vw, 3rem); border-bottom: 1px solid var(--rule); }
.pagehead h1 { margin-top: 1.25rem; max-width: 18ch; }
.pagehead .lede { margin-top: 1.5rem; }

/* Utilities ------------------------------------------------------------- */
.stack-sm > * + * { margin-top: 1rem; }
.stack > * + * { margin-top: 1.75rem; }
.stack-lg > * + * { margin-top: clamp(2.5rem, 5vw, 4rem); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }


/* ---------------------------------------------------------------
   Banner: full bleed image band under an accent wash.
   Swap the photograph per page with the inline background-image.
   --------------------------------------------------------------- */
.banner {
  /* Wash strength, overridable per banner so dark and light photographs
     both keep their detail under the accent. */
  --wash-a: .80;
  --wash-b: .44;
  position: relative;
  display: flex;
  align-items: center;
  min-height: clamp(190px, 26vw, 340px);
  background-color: var(--blau-5);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  padding-block: clamp(2rem, 5vw, 3.5rem);
}

.banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 47, 167, var(--wash-a)) 0%, rgba(0, 47, 167, var(--wash-b)) 100%);
}

.banner > .shell { position: relative; width: 100%; }

.banner__k {
  display: block;
  margin-bottom: .9rem;
  font-family: var(--mono);
  font-size: .6875rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--blau-2);
}

.banner__t {
  margin: 0;
  max-width: 22ch;
  font-family: var(--display);
  font-size: clamp(1.45rem, 3.2vw, 2.5rem);
  line-height: 1.12;
  color: #fff;
}

@media (prefers-reduced-motion: no-preference) {
  .banner { background-attachment: fixed; }
}

@media (max-width: 700px) {
  .banner { background-attachment: scroll; }
}

/* Mobile navigation ------------------------------------------------------
   Below 880px the link set collapses behind a toggle. The Contact button
   stays visible: it is the one action worth keeping one tap away. */
.nav__toggle { display: none; }

@media (max-width: 1080px) {
  /* Keep the bar on one row: the link set is absolutely positioned when
     open, so only the logo, Contact and the toggle sit in flow. */
  .masthead__inner { flex-wrap: nowrap; gap: .75rem; }
  .nav { width: auto; flex: 0 0 auto; flex-wrap: nowrap; gap: .6rem; }

  .nav__toggle {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px;
    height: 38px;
    padding: 0 9px;
    background: none;
    border: 1px solid var(--rule);
    cursor: pointer;
  }
  .nav__bar {
    display: block;
    height: 1.5px;
    background: var(--ink);
    transition: transform .2s ease, opacity .2s ease;
  }
  .nav__toggle[aria-expanded="true"] .nav__bar:nth-of-type(1) { transform: translateY(6.5px) rotate(45deg); }
  .nav__toggle[aria-expanded="true"] .nav__bar:nth-of-type(2) { opacity: 0; }
  .nav__toggle[aria-expanded="true"] .nav__bar:nth-of-type(3) { transform: translateY(-6.5px) rotate(-45deg); }

  .nav__set {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
    padding: .25rem var(--gutter) 1rem;
  }
  .nav__set.is-open { display: flex; }
  .nav__set a {
    padding-block: .95rem;
    border-bottom: 1px solid var(--rule);
    font-size: .75rem;
  }
  .nav__set a:last-child { border-bottom: 0; }
  .nav__contact { padding-inline: .9rem; }
}

/* Contact stays reachable at every width: it is not in the dropdown. */
@media (max-width: 360px) {
  .nav__contact { padding-inline: .7rem; font-size: .6875rem; }
  .wordmark img { height: 1.2rem; }
}

/* Credentials: one item per line, ruled like the rest of the page. */
.creds {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  border-top: 1px solid var(--rule);
}
.creds li {
  padding-block: .7rem;
  border-bottom: 1px solid var(--rule);
  color: var(--muted);
  font-size: .9375rem;
  line-height: 1.45;
}
