/* FUN Technologies — funtechnol.com */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  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: "Archivo";
  src: url("../fonts/archivo-latin-ext.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/jetbrains-mono-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
}

:root {
  --paper: #f3f1ea;
  --paper-2: #e9e6dc;
  --ink: #121418;
  --ink-2: #4b5058;
  --ink-3: #8a8e95;
  --line: rgba(18, 20, 24, 0.14);
  --line-strong: rgba(18, 20, 24, 0.85);
  --signal: #ff5a1f;
  --signal-text: #b83808;

  --sans: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --wrap: 1240px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 72px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  /* 1% of the viewport height that excludes mobile browser chrome */
  --vh: 1vh;
  --h2: clamp(2.25rem, 5.2vw, 4.25rem);
}
@supports (height: 1svh) {
  :root { --vh: 1svh; }
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
p { text-wrap: pretty; }
a { color: inherit; }
img, svg { display: block; max-width: 100%; }
::selection { background: var(--signal); color: var(--ink); }

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

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

.skip {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 0.875rem;
  text-decoration: none;
}
.skip:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- shared pieces ---------- */

.mono {
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
}

.kicker {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}
@media (max-width: 479px) {
  /* one line down to 360px */
  .kicker { gap: 8px; font-size: 0.75rem; letter-spacing: 0.04em; }
}

.pulse {
  position: relative;
  width: 8px;
  height: 8px;
  /* centred on the first line, also when the kicker wraps */
  margin-top: calc(0.8em - 4px);
  border-radius: 50%;
  background: var(--signal);
  flex: none;
}
@media (prefers-reduced-motion: no-preference) {
  .pulse::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--signal);
    animation: ping 2.4s var(--ease) infinite;
  }
}
@keyframes ping {
  0% { transform: scale(1); opacity: 0.6; }
  70%, 100% { transform: scale(3.2); opacity: 0; }
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 22px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  font-stretch: 108%;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s, transform 0.2s var(--ease);
}
.btn svg { width: 18px; height: 18px; transition: transform 0.25s var(--ease); }
.btn:hover { background: var(--signal); border-color: var(--signal); color: var(--ink); }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: translateY(1px); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
}
.btn--ghost:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.btn--ghost:hover svg { transform: translateY(3px); }

.btn--small { min-height: 42px; padding: 0 18px; font-size: 0.9375rem; }

.section { padding-block: clamp(80px, 11vw, 144px); }

.section__head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  margin-bottom: clamp(40px, 6vw, 72px);
}
@media (min-width: 900px) {
  .section__head {
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
  }
}

.index {
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding-top: 0.6em;
}
.index b { color: var(--signal-text); font-weight: 600; }
@media (min-width: 900px) {
  /* cap height of the index on the cap height of the h2 next to it
     (Archivo cap top sits 0.148em into a line-height:1 box, JetBrains Mono 0.43em into 1.6) */
  .section__head .index { padding-top: calc(var(--h2) * 0.148 - 0.43em); }
}

.h2 {
  font-size: var(--h2);
  font-weight: 750;
  font-stretch: 112%;
  line-height: 1;
  letter-spacing: -0.035em;
  max-width: 16ch;
  text-wrap: balance;
  /* optical edge: big capitals carry ~0.08em of side bearing */
  margin-left: -0.05em;
}
.h2 em { font-style: normal; color: var(--signal-text); }

.section__intro {
  margin-top: 22px;
  max-width: 56ch;
  color: var(--ink-2);
  font-size: 1.1875rem;
  line-height: 1.55;
}

/* ---------- header ---------- */

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(243, 241, 234, 0.86);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s;
}
.header.is-scrolled { border-bottom-color: var(--line); }

.header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: var(--header-h);
}

.brand { display: inline-flex; flex: none; }
.brand img { height: 34px; width: auto; }

.nav {
  display: none;
  gap: 4px;
  margin-left: auto;
}
.nav a {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--ink-2);
  transition: color 0.2s, background-color 0.2s;
}
.nav a:hover { color: var(--ink); background: var(--paper-2); }

@media (min-width: 860px) {
  .nav { display: flex; }
}
.header .btn--small { white-space: nowrap; }
@media (max-width: 420px) {
  .header__bar { gap: 12px; }
  .brand img { height: 26px; }
  .header .btn--small { padding: 0 14px; font-size: 0.875rem; }
  .header .btn--small svg { display: none; }
}
@media (max-width: 359px) {
  /* the hero CTAs sit right below */
  .header .btn--small { display: none; }
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  display: flex;
  align-items: center;
  padding-top: clamp(24px, calc(5 * var(--vh)), 72px);
  padding-bottom: clamp(24px, 4vw, 48px);
  isolation: isolate;
}
@media (min-width: 960px) {
  /* side by side: the hero is the first screen, content centred in it */
  .hero {
    min-height: min(calc(100 * var(--vh) - var(--header-h)), 1000px);
    padding-block: clamp(32px, calc(6 * var(--vh)), 88px);
  }
}
.hero::before {
  /* engineering paper */
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 40px 40px;
  background-position: center top;
  opacity: 0.55;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 70% 35%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 80% 70% at 70% 35%, #000 20%, transparent 75%);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(48px, 7vw, 72px);
  align-items: center;
}
@media (min-width: 960px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr) minmax(0, clamp(360px, 38vw, 470px)); }
}

/* Vertical rhythm of the hero copy shrinks with the viewport height,
   so the CTAs stay above the fold on 650–800px tall laptop screens. */
.acro {
  margin-top: clamp(16px, calc(3 * var(--vh)), 28px);
  font-weight: 400;
  line-height: 1;
}
.acro__visual {
  display: inline-flex;
  flex-direction: column;
  font-size: clamp(3rem, min(15vw, calc(11.5 * var(--vh))), 6.5rem);
  line-height: 0.94;
  letter-spacing: -0.035em;
}
@media (min-width: 960px) {
  .acro__visual { font-size: clamp(3rem, min(7.4vw, calc(11.5 * var(--vh))), 6.5rem); }
}
.acro__line {
  display: block;
  white-space: nowrap;
  /* F, U and N carry 0.078em of side bearing at this weight */
  margin-left: -0.075em;
}
.acro__line b {
  display: inline-block;
  font-weight: 850;
  font-stretch: 118%;
  letter-spacing: -0.02em;
}
.acro__rest {
  display: inline-block;
  font-weight: 250;
  font-stretch: 100%;
}

.acro__sum {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 0.4em;
  margin-top: 0.34em;
  padding-top: 0.32em;
  font-size: max(1.25rem, 0.35em);
  font-weight: 650;
  font-stretch: 112%;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.acro__sum::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  background: var(--ink);
  transform-origin: left center;
}
.acro__eq { color: var(--signal); font-weight: 800; }

@media (prefers-reduced-motion: no-preference) {
  .acro__line b { animation: rise 0.7s var(--ease) backwards; }
  .acro__line:nth-child(2) b { animation-delay: 0.08s; }
  .acro__line:nth-child(3) b { animation-delay: 0.16s; }
  .acro__rest { animation: unclip 1s cubic-bezier(0.7, 0, 0.2, 1) backwards; }
  .acro__line:nth-child(1) .acro__rest { animation-delay: 0.45s; }
  .acro__line:nth-child(2) .acro__rest { animation-delay: 0.57s; }
  .acro__line:nth-child(3) .acro__rest { animation-delay: 0.69s; }
  .acro__sum::before { animation: draw 0.8s var(--ease) 1.05s backwards; }
  .acro__sum > span { animation: fade 0.7s var(--ease) 1.35s backwards; }
  .hero__lead, .hero__cta { animation: fade 0.8s var(--ease) 0.3s backwards; }
  .fig { animation: fade 1s var(--ease) 0.5s backwards; }
}
@keyframes rise { from { transform: translateY(0.35em); opacity: 0; } }
@keyframes unclip { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes draw { from { transform: scaleX(0); } }
@keyframes fade { from { opacity: 0; transform: translateY(12px); } }

.hero__lead {
  margin-top: clamp(20px, calc(4 * var(--vh)), 36px);
  max-width: 40ch;
  font-size: clamp(1.125rem, min(1.6vw, calc(2.4 * var(--vh))), 1.3125rem);
  line-height: 1.55;
  color: var(--ink-2);
}
.hero__lead strong { color: var(--ink); font-weight: 600; }

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: clamp(20px, calc(3.5 * var(--vh)), 32px);
}
@media (max-width: 479px) {
  /* one row that spans the column; full-width stack when it no longer fits */
  .hero__cta { gap: 10px; }
  .hero__cta .btn {
    flex: 1 1 auto;
    justify-content: center;
    gap: 8px;
    padding-inline: 16px;
    font-size: 0.9375rem;
  }
}

/* figure */

.fig { position: relative; width: 100%; max-width: 560px; container-type: inline-size; }
@media (min-width: 960px) {
  /* shrinks on short screens so it never outgrows the copy beside it */
  .hero .fig {
    justify-self: end;
    max-width: min(100%, calc((100 * var(--vh) - var(--header-h) - 200px) * 1.35));
  }
}
.fig__frame {
  position: relative;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background:
    radial-gradient(circle, rgba(18, 20, 24, 0.16) 1px, transparent 1.4px) 0 0 / 20px 20px,
    var(--paper);
  overflow: hidden;
}
.fig__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.fig__bar > span:first-child { white-space: nowrap; }
.fig__legend { display: flex; gap: 14px; }
/* the bar needs ~420px for the title and the legend */
@container (max-width: 429px) {
  .fig__legend { display: none; }
}
.fig__legend span { display: inline-flex; align-items: center; gap: 6px; }
.fig__legend i {
  display: inline-block;
  width: 16px;
  border-top: 1.5px solid var(--ink);
}
.fig__legend i.dash { border-top-style: dashed; }
.fig svg { width: 100%; height: auto; }
.fig figcaption {
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--ink-2);
}
.fig figcaption b { color: var(--ink); font-weight: 600; }

.dia-chip rect { fill: var(--paper); stroke: var(--ink); stroke-width: 1.25; }
.dia-chip text { font-family: var(--mono); font-size: 11.5px; fill: var(--ink); letter-spacing: 0.01em; }
.dia-chip .lamp { fill: var(--ink); }
.dia-chip--hot rect { stroke-width: 1.75; }
.dia-chip--hot .lamp { fill: var(--signal); }
.dia-edge { fill: none; stroke: var(--ink); stroke-width: 1.25; }
.dia-edge--dash { stroke-dasharray: 3 4; }
.dia-zone { fill: rgba(243, 241, 234, 0.55); stroke: var(--ink); stroke-width: 1; stroke-dasharray: 6 5; }
.dia-label { font-family: var(--mono); font-size: 10px; fill: var(--ink-2); letter-spacing: 0.06em; text-transform: uppercase; }
.dia-zone-label { font-family: var(--mono); font-size: 10px; fill: var(--ink); letter-spacing: 0.12em; font-weight: 600; }
.dia-pkt { fill: var(--signal); }
.dia-pkt--ink { fill: var(--ink); }
.dia-beat { fill: none; stroke: var(--signal); stroke-width: 1.75; stroke-linejoin: round; stroke-linecap: round; }

@media (prefers-reduced-motion: no-preference) {
  .dia-beat { stroke-dasharray: 100; animation: beat 2.2s linear infinite; }
}
@media (prefers-reduced-motion: reduce) {
  .dia-pkt { display: none; }
}
@keyframes beat {
  from { stroke-dashoffset: 100; }
  to { stroke-dashoffset: -100; }
}

/* ---------- services ---------- */

.services__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  border-top: 1px solid var(--line-strong);
}
@media (min-width: 640px) {
  .services__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 980px) {
  .services__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.svc {
  position: relative;
  /* subgrid: titles, texts and tags line up across a row even when a title wraps */
  display: grid;
  grid-row: span 4;
  grid-template-rows: subgrid;
  row-gap: 14px;
  align-content: start;
  padding: 28px 28px 32px;
  border-bottom: 1px solid var(--line);
  transition: background-color 0.25s;
}
@media (min-width: 640px) {
  .svc:nth-child(odd) { border-right: 1px solid var(--line); }
}
@media (min-width: 980px) {
  .svc:nth-child(odd) { border-right: 0; }
  .svc:not(:nth-child(3n)) { border-right: 1px solid var(--line); }
}
@media (max-width: 639px) {
  .svc { padding-inline: 0; }
}
.svc:hover { background: var(--paper-2); }

.svc__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.svc__num { font-family: var(--mono); font-size: 0.8125rem; color: var(--ink-2); }
.svc__icon { width: 40px; height: 40px; color: var(--ink); }
.svc__icon .sig { fill: var(--ink); transition: fill 0.25s; }
.svc__icon .bgfill { fill: var(--paper); transition: fill 0.25s; }
.svc:hover .svc__icon .bgfill { fill: var(--paper-2); }
.svc:hover .svc__icon .sig { fill: var(--signal); }

.svc h3 {
  /* a one-line title sits on its text when a neighbour's title wraps */
  align-self: end;
  font-size: 1.5rem;
  font-weight: 700;
  font-stretch: 108%;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
.svc p { color: var(--ink-2); font-size: 1rem; line-height: 1.6; }

.tags {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 6px;
  padding-top: 8px;
}
.tags li {
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--ink-2);
}

.stack {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 24px;
  margin-top: 36px;
}
@media (min-width: 640px) {
  /* on the text edge of the cards above */
  .stack { padding-inline: 28px; }
}
.stack__label {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}
/* Every item gets a "/" in front; the list is pulled left by one separator
   and clipped, so the separator that starts a wrapped line is never shown. */
.stack ul {
  --sep: 44px;
  display: flex;
  flex-wrap: wrap;
  row-gap: 4px;
  margin-left: calc(var(--sep) * -1);
  clip-path: inset(0 0 0 var(--sep));
  font-family: var(--mono);
  font-size: 0.875rem;
}
.stack li { white-space: nowrap; }
.stack li::before {
  content: "/";
  display: inline-block;
  width: var(--sep);
  text-align: center;
  color: var(--ink-3);
}

/* ---------- approach (dark) ---------- */

.approach {
  background: var(--ink);
  color: var(--paper);
  --line: rgba(243, 241, 234, 0.16);
}
.approach .index { color: rgba(243, 241, 234, 0.6); }
.approach .index b { color: var(--signal); }
.approach .section__intro { color: rgba(243, 241, 234, 0.72); }
.approach .section__intro strong { color: var(--paper); font-weight: 600; }

.letters {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
}
@media (min-width: 900px) {
  .letters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.letter {
  padding: 32px 0 40px;
  border-bottom: 1px solid var(--line);
}
@media (min-width: 900px) {
  .letter { padding: 36px 32px 8px; border-bottom: 0; }
  .letter:first-child { padding-left: 0; }
  .letter + .letter { border-left: 1px solid var(--line); }
}

.letter__glyph {
  display: block;
  /* optical edge: the glyph's side bearing would push it right of the text */
  margin-left: -0.075em;
  font-size: clamp(6rem, 13vw, 11rem);
  font-weight: 850;
  font-stretch: 125%;
  line-height: 0.8;
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--paper);
  transition: color 0.35s, -webkit-text-stroke-color 0.35s;
}
.letter:hover .letter__glyph,
.letter.is-on .letter__glyph {
  color: var(--signal);
  -webkit-text-stroke-color: var(--signal);
}
@media (prefers-reduced-motion: reduce) {
  .letter__glyph { color: var(--signal); -webkit-text-stroke-color: var(--signal); }
}

.letter h3 {
  margin-top: 28px;
  font-size: 1.75rem;
  font-weight: 700;
  font-stretch: 112%;
  letter-spacing: -0.02em;
}
.letter h3 span { color: var(--signal); }
.letter p {
  margin-top: 12px;
  color: rgba(243, 241, 234, 0.72);
  max-width: 40ch;
}
.letter ul {
  margin-top: 24px;
  display: grid;
  gap: 10px;
  font-family: var(--mono);
  font-size: 0.8125rem;
  line-height: 1.5;
  color: rgba(243, 241, 234, 0.88);
}
.letter li {
  position: relative;
  padding-left: 22px;
}
.letter li::before {
  content: "";
  position: absolute;
  left: 0;
  top: calc(0.75em - 3.5px);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 1.5px solid var(--signal);
}

/* ---------- process ---------- */

.steps {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  counter-reset: step;
}
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
}

.step {
  position: relative;
  padding: 0 0 36px 40px;
}
.step::before {
  /* node */
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: var(--ink);
  box-shadow: 0 0 0 6px var(--paper);
}
.step:last-child::before { background: var(--signal); }
.step::after {
  /* edge */
  content: "";
  position: absolute;
  left: 7px;
  top: 10px;
  bottom: -10px;
  width: 1.5px;
  background: var(--ink);
  z-index: -1;
}
.step:last-child::after { display: none; }

@media (min-width: 900px) {
  .step { padding: 44px 0 0; }
  .step::after {
    left: 8px;
    right: -36px;
    top: 9px;
    bottom: auto;
    width: auto;
    height: 1.5px;
  }
}

.step__num {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--ink-2);
}
.step h3 {
  margin-top: 6px;
  font-size: 1.5rem;
  font-weight: 700;
  font-stretch: 108%;
  letter-spacing: -0.02em;
}
.step p { margin-top: 10px; color: var(--ink-2); font-size: 1rem; }

.loop {
  display: flex;
  align-items: center;
  /* icon centred under the step nodes, text on the step text edge (40px) */
  gap: 21.5px;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--ink-2);
}
.loop svg { width: 22px; height: 22px; flex: none; margin-left: -3.5px; color: var(--signal); }

@media (min-width: 900px) {
  .loop svg { margin-left: 0; }
  .loop {
    position: relative;
    gap: 12px;
    margin-top: 36px;
    /* spans "Build" → "Run" */
    margin-left: calc((100% - 3 * 28px) / 4 + 28px + 7px);
    /* … and ends at the "Run" node */
    margin-right: calc((100% - 3 * 28px) / 4 - 8px);
    padding-top: 26px;
    justify-content: center;
  }
  .loop::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: -10px;
    height: 28px;
    border: 1.5px dashed var(--ink);
    border-top: 0;
    border-radius: 0 0 14px 14px;
  }
  .loop::after {
    /* arrow head pointing up at "Build" */
    content: "";
    position: absolute;
    left: -5.5px;
    top: -16px;
    border: 6px solid transparent;
    border-bottom: 8px solid var(--ink);
    border-top: 0;
  }
}

/* ---------- contact ---------- */

.contact {
  background: var(--signal);
  color: var(--ink);
  --line: rgba(18, 20, 24, 0.22);
}
.contact .index,
.contact .index b { color: var(--ink); }

.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 48px;
  align-items: end;
}
@media (min-width: 980px) {
  .contact__grid { grid-template-columns: minmax(0, 1fr) 380px; gap: 64px; }
}

.contact .h2 {
  margin-top: 24px;
  font-size: clamp(2.75rem, 7.4vw, 6rem);
  max-width: 12ch;
}
.contact__text {
  margin-top: 24px;
  max-width: 46ch;
  font-size: 1.1875rem;
  line-height: 1.55;
}
.contact .btn {
  margin-top: 36px;
  min-height: 60px;
  padding: 0 28px;
  font-size: 1.0625rem;
}
.contact .btn:hover { background: var(--paper); border-color: var(--paper); color: var(--ink); }

.card {
  border: 1.5px solid var(--ink);
  border-radius: 14px;
  background: var(--paper);
  overflow: hidden;
}
.card__row {
  padding: 20px 22px;
}
.card__row + .card__row { border-top: 1px solid rgba(18, 20, 24, 0.14); }
.card__label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.card address {
  font-style: normal;
  font-size: 1.125rem;
  line-height: 1.45;
}
.card address strong { font-weight: 700; font-stretch: 108%; }
.card__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 0.8125rem;
}
.card__links a,
.card__links button {
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font: inherit;
  text-decoration: underline;
  text-decoration-color: rgba(18, 20, 24, 0.35);
  text-underline-offset: 3px;
  cursor: pointer;
}
.card__links a:hover,
.card__links button:hover { text-decoration-color: var(--signal); }
.card__mail {
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
  word-break: break-all;
}
.card__mail:hover { color: var(--signal-text); }

/* ---------- footer ---------- */

.footer {
  background: var(--ink);
  color: rgba(243, 241, 234, 0.7);
  padding-block: 56px 40px;
  font-size: 0.9375rem;
}
.footer__top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 32px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(243, 241, 234, 0.14);
}
.footer__brand img { height: 40px; width: auto; }
.footer__brand p {
  margin-top: 16px;
  max-width: 34ch;
  font-family: var(--mono);
  font-size: 0.8125rem;
  line-height: 1.6;
}
.footer__nav {
  display: grid;
  grid-template-rows: repeat(2, auto);
  grid-auto-flow: column;
  gap: 10px 40px;
}
.footer__nav a { text-decoration: none; color: var(--paper); }
.footer__nav a:hover { color: var(--signal); }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
  padding-top: 24px;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}
.footer__bottom a { color: var(--paper); text-decoration: none; }
.footer__bottom a:hover { color: var(--signal); }

/* ---------- scroll reveal (only when JS is on) ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
    transition-delay: calc(var(--d, 0) * 90ms);
  }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
}
