:root {
  --porcelain: #f4f5f7;
  --paper: #ffffff;
  --ink: #10152b;
  --slate: #565d74;
  --line: #1c2452;
  --mist: #dcdfe7;
  --coral: #e4572e;
  --iris: #4c5fd5;
  --deep: #0e1330;
  --deep-2: #1d2450;
  --deep-text: #f4f5f7;
  --deep-muted: #a9afc9;
  --font: "Schibsted Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --container: 1320px;
  --pad: clamp(20px, 5vw, 64px);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--porcelain);
  color: var(--ink);
  font: 400 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a {
  color: inherit;
}
:focus-visible {
  outline: 2px solid var(--coral);
  outline-offset: 3px;
  border-radius: 6px;
}
.skip-link {
  position: fixed;
  top: -80px;
  left: 16px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
}
.skip-link:focus {
  top: 12px;
}
.wrap {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* ───── Navigation ───── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  max-width: var(--container);
  margin: 0 auto;
  padding: 18px var(--pad);
  border: 1px solid transparent;
  transition: top 0.4s var(--ease), max-width 0.4s var(--ease), padding 0.4s var(--ease), background-color 0.4s, border-color 0.4s, border-radius 0.4s, box-shadow 0.4s;
}
.nav.cond {
  top: 12px;
  max-width: 1100px;
  padding: 9px 10px 9px 24px;
  border-color: var(--mist);
  border-radius: 999px;
  background: var(--porcelain);
  box-shadow: 0 1px 2px rgb(16 21 43 / 0.04), 0 12px 40px -12px rgb(28 36 82 / 0.2);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font: 600 19px/1 var(--font);
  letter-spacing: -0.03em;
  text-decoration: none;
}
.nav.cond.dark {
  border-color: #2a3266;
  background: var(--deep);
  box-shadow: 0 12px 40px -12px rgb(0 0 0 / 0.5);
}
.nav.cond.dark .brand,
.nav.cond.dark nav > a:not(.btn) {
  color: var(--deep-text);
}
.nav.cond.dark .btn {
  background: var(--paper);
  color: var(--ink);
}
.nav.cond.dark .btn:hover {
  background: #e9ebfb;
}
.nav.cond.dark .btn i {
  background: rgb(16 21 43 / 0.07);
}
.brand svg {
  width: 28px;
  height: 28px;
}
.nav nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.2vw, 32px);
  font-size: 15px;
  font-weight: 500;
}
.nav nav > a:not(.btn) {
  color: var(--slate);
  text-decoration: none;
  transition: color 0.2s;
}
.nav nav > a:not(.btn):hover {
  color: var(--ink);
}

/* ───── Buttons ───── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 15px 16px 15px 24px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font: 500 15.5px/1 var(--font);
  text-decoration: none;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease);
}
.btn i {
  position: relative;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.14);
  transition: transform 0.4s var(--ease), background-color 0.3s;
}
.btn i::before {
  content: "";
  position: absolute;
  inset: 0;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 26'%3E%3Cpath d='M8 13h10m-4-4 4 4-4 4' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 26'%3E%3Cpath d='M8 13h10m-4-4 4 4-4 4' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat;
}
.btn:hover {
  background: #1c2452;
}
.btn:hover i {
  transform: translateX(3px);
  background: var(--coral);
}
.btn-sm {
  padding: 10px 10px 10px 18px;
  font-size: 14.5px;
}
.btn-sm i {
  width: 22px;
  height: 22px;
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--mist);
}
.btn-ghost i {
  background: rgb(76 95 213 / 0.1);
}
.btn-ghost:hover {
  background: var(--paper);
}
.btn-light {
  background: var(--paper);
  color: var(--ink);
}
.btn-light:hover {
  background: #e9ebfb;
}
.btn-light i {
  background: rgb(16 21 43 / 0.07);
}

/* ───── Type ───── */
.eyebrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  color: var(--slate);
  font: 500 12px/1.4 var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.eyebrow i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--coral);
}
.badge {
  padding: 5px 10px;
  border: 1px solid rgb(76 95 213 / 0.22);
  border-radius: 999px;
  background: rgb(76 95 213 / 0.06);
  color: #3d4cb0;
  font-size: 10.5px;
  letter-spacing: 0.06em;
}
h1,
h2,
h3 {
  margin: 0;
  font-weight: 600;
}
h1 {
  max-width: 12.5ch;
  font-size: clamp(46px, 5.6vw, 88px);
  line-height: 0.98;
  letter-spacing: -0.045em;
}
h2 {
  max-width: 15ch;
  font-size: clamp(34px, 3.7vw, 56px);
  line-height: 1.03;
  letter-spacing: -0.038em;
}
.lead {
  max-width: 46ch;
  margin: 20px 0 0;
  color: var(--slate);
  font-size: clamp(16.5px, 1.25vw, 19px);
  line-height: 1.55;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.items {
  display: grid;
  gap: 16px;
  max-width: 46ch;
  margin: 28px 0 0;
}
.items div {
  padding-left: 18px;
  border-left: 2px solid rgb(76 95 213 / 0.22);
}
.items dt {
  font-weight: 600;
  letter-spacing: -0.01em;
}
.items dd {
  margin: 3px 0 0;
  color: var(--slate);
  font-size: 15.5px;
  line-height: 1.5;
}
.built {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 50ch;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}
.built li {
  padding: 7px 12px;
  border: 1px solid rgb(76 95 213 / 0.18);
  border-radius: 999px;
  background: rgb(76 95 213 / 0.045);
  font-size: 14px;
  font-weight: 500;
}
.stack {
  max-width: 52ch;
  margin: 20px 0 0;
  color: var(--slate);
  font: 400 12.5px/1.7 var(--mono);
}
.note {
  max-width: 52ch;
  margin: 18px 0 0;
  color: var(--slate);
  font: 400 12.5px/1.6 var(--mono);
}

/* ───── The drawing: one fixed layer behind the text ───── */
.field {
  position: fixed;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}
.field .s1 {
  stop-color: var(--line);
  transition: stop-color 0.9s;
}
.field .s2 {
  stop-color: var(--iris);
  transition: stop-color 0.9s;
}
.field.dark .s1 {
  stop-color: #eef0fb;
}
.field.dark .s2 {
  stop-color: #9aa6f2;
}
.field .st path {
  fill: none;
  stroke: url(#sg);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.field .st path.c {
  stroke: var(--coral);
  stroke-width: 1.9;
}
.field .dot {
  fill: var(--coral);
}
.field .tags {
  opacity: 0;
  transition: opacity 0.6s var(--ease);
}
.field .tags.on {
  opacity: 1;
}
.field .tags text {
  fill: var(--slate);
  font: 500 10px var(--mono);
  letter-spacing: 0.1em;
}
.field.dark .tags text {
  fill: var(--deep-muted);
}
.shade {
  display: none;
}
/* Caption under the drawing when it sits beside the text. */
.cap {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 8px;
  width: 340px;
  margin: 0 0 0 -170px;
  text-align: center;
  pointer-events: none;
  transition: transform 1.6s var(--ease);
}
.cap.out,
.cap.off {
  visibility: hidden;
}
.cap-k {
  color: var(--coral);
  font: 500 11px/1 var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.cap-t {
  color: var(--slate);
  font: 500 11.5px/1.5 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
/* Progress through the story. */
.rail {
  position: fixed;
  right: 18px;
  top: 50%;
  z-index: 40;
  display: grid;
  gap: 9px;
  transform: translateY(-50%);
}
.rail a {
  position: relative;
  display: block;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: #c9cde0;
  transition: height 0.45s var(--ease), background-color 0.45s;
}
.rail a::after {
  content: "";
  position: absolute;
  inset: -5px -8px;
}
.rail a.on {
  height: 22px;
  background: var(--coral);
}

/* ───── Story sections ───── */
.panel {
  position: relative;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--pad);
}
.copy {
  position: relative;
  z-index: 2;
  transition: transform 0.8s var(--ease);
}
/* Text is never dimmed or faded; the drawing moves out of its way instead. */
.panel:not(.on) .copy {
  transform: translateY(12px);
}
/* Text on one side, the drawing on the other. */
.side {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-block: 14vh;
}
.side .copy {
  width: min(46%, 580px);
}
.side.flip .copy {
  margin-left: auto;
}
.hero {
  padding-top: calc(90px + 6vh);
}
/* Scenes hold their text still for a moment while the drawing fills the space around it. */
.scene {
  height: 130vh;
}
.scene.process {
  height: 170vh;
}
.pin {
  position: sticky;
  top: 0;
  z-index: 2;
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding-block: 13vh 8vh;
}
.top .pin {
  justify-content: flex-end;
}
.around .pin {
  justify-content: center;
  align-items: center;
  padding-block: 18vh 4vh;
  text-align: center;
}
.around .copy {
  max-width: 480px;
}
.around h2,
.around .lead,
.around .stack {
  margin-inline: auto;
}
.around .eyebrow,
.around .built {
  justify-content: center;
}
.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 18px clamp(32px, 6vw, 104px);
  align-items: start;
}
.split h2 {
  max-width: 13ch;
}
.split > div + div {
  padding-top: 34px;
}
.split > div + div > :first-child {
  margin-top: 0;
}
.scroll-hint {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 56px 0 0;
  color: var(--slate);
  font: 500 11px/1 var(--mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.scroll-hint span {
  position: relative;
  width: 1px;
  height: 36px;
  overflow: hidden;
  background: var(--mist);
}
.scroll-hint span::after {
  content: "";
  position: absolute;
  left: 0;
  top: -40%;
  width: 1px;
  height: 40%;
  background: var(--coral);
  animation: drip 2s var(--ease) infinite;
}
@keyframes drip {
  to {
    transform: translateY(350%);
  }
}

/* Systems list */
.syslist {
  max-width: 560px;
  margin: 30px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--mist);
}
.syslist li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 16px;
  padding: 11px 10px;
  border-bottom: 1px solid var(--mist);
  cursor: pointer;
  transition: background-color 0.3s;
}
.syslist li.hl {
  background: rgb(255 255 255 / 0.85);
}
.syslist .sn {
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: color 0.3s;
}
.syslist li.hl .sn {
  color: var(--coral);
}
.syslist .sm {
  color: var(--slate);
  font: 400 12px/1.9 var(--mono);
  text-align: right;
}
.syslist .sa {
  grid-column: 1 / -1;
  color: #3d4cb0;
  font: 400 11.5px/1.4 var(--mono);
  letter-spacing: 0.04em;
}

/* How we work: the arc is part of the drawing; the steps sit under its four points. */
.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: auto 0 0;
  padding: 0;
  list-style: none;
  text-align: center;
}
.steps li {
  padding-inline: 14px;
}
/* Steps the arc hasn't reached yet change colour, not opacity, so they stay sharp. */
.steps span {
  color: var(--slate);
  font: 500 13px/1 var(--mono);
  transition: color 0.6s var(--ease);
}
.steps li.on span {
  color: var(--coral);
}
.steps h3 {
  margin: 12px 0 8px;
  color: var(--slate);
  font-size: 21px;
  letter-spacing: -0.025em;
  transition: color 0.6s var(--ease);
}
.steps li.on h3 {
  color: var(--ink);
}
.steps p {
  max-width: 30ch;
  margin: 0 auto;
  color: var(--slate);
  font-size: 15px;
  line-height: 1.5;
}

/* ───── Contact ───── */
.contact {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: 20vh;
  border-radius: 40px 40px 0 0;
  background: var(--deep);
  color: var(--deep-text);
}
.contact .eyebrow,
.contact .lead {
  color: var(--deep-muted);
}
.contact h2 {
  max-width: 13ch;
}
.contact-grid {
  width: 100%;
}
.contact .copy {
  max-width: 560px;
  transform: none;
}
.foot {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin-top: 12vh;
  padding-block: 26px 34px;
  border-top: 1px solid var(--deep-2);
  color: var(--deep-muted);
  font: 400 12.5px/1.5 var(--mono);
}

/* ───── Narrow screens: the drawing pins to the top; the text scrolls beneath it ───── */
@media (max-width: 960px) {
  :root {
    --hm: min(38svh, calc(100vw - 40px));
  }
  .field {
    z-index: 4;
  }
  .shade {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 3;
    display: block;
    height: calc(76px + var(--hm) + 40px);
    background: var(--porcelain);
    box-shadow: 0 1px 0 var(--mist);
    pointer-events: none;
  }
  .rail,
  .cap {
    display: none;
  }
  .side,
  .scene,
  .scene.process {
    display: block;
    height: auto;
    min-height: 0;
    padding-block: 9vh;
  }
  .pin {
    position: static;
    display: block;
    height: auto;
    padding: 0;
  }
  .side .copy {
    width: auto;
  }
  .hero {
    padding-top: calc(76px + var(--hm) + 48px);
  }
  .split {
    grid-template-columns: minmax(0, 1fr);
  }
  .split > div + div {
    padding-top: 0;
  }
  .around .pin,
  .around .copy {
    max-width: none;
    text-align: left;
  }
  .around h2,
  .around .lead,
  .around .stack {
    margin-inline: 0;
  }
  .around .eyebrow,
  .around .built {
    justify-content: flex-start;
  }
  .steps {
    grid-template-columns: 1fr 1fr;
    gap: 28px 0;
    margin-top: 36px;
    text-align: left;
  }
  .steps li {
    padding-inline: 0 18px;
  }
  .steps p {
    margin: 0;
  }
  .scroll-hint {
    display: none;
  }
  .nav nav > a:not(.btn) {
    display: none;
  }
  .contact {
    padding-top: calc(52px + var(--hm) + 44px);
  }
}
@media (max-width: 600px) {
  .steps {
    grid-template-columns: 1fr;
  }
}

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

