/* CJL Forward. Brand palette and Archivo only. Text on orange is always ink. */

@font-face {
  font-family: "Archivo";
  src: url("fonts/archivo-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-stretch: 100% 112%;
  font-display: swap;
}

:root {
  --bottle: #0E3B36;
  --signal: #FF6A2B;
  --mist: #E4ECEA;
  --white: #FFFFFF;
  --ink: #10201E;

  --gutter: clamp(20px, 4vw, 72px);
  --section: clamp(72px, 10vw, 152px);
  --header: 72px;
  --drive: cubic-bezier(.16, 1, .3, 1);
}

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

html {
  scroll-padding-top: var(--header);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--signal);
  color: var(--ink);
  font: 400 clamp(18px, 1.35vw, 22px)/1.5 "Archivo", Arial, sans-serif;
  overflow-x: clip;
}

h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; }
a { color: inherit; }

h1, h2, h3 {
  font-weight: 600;
  font-stretch: 112%;
  letter-spacing: -.035em;
  line-height: .95;
}

h2 {
  font-size: clamp(44px, 7vw, 124px);
  text-wrap: balance;
}
h2 span { display: block; }

:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 5px;
}

.skip {
  position: fixed;
  z-index: 20;
  top: 12px;
  left: 12px;
  padding: 12px 20px;
  background: var(--ink);
  color: var(--white);
  transform: translateY(-200%);
}
.skip:focus { transform: none; }

/* Arrow button. The shape sits behind the label so the focus ring isn't cut off. */

.button {
  --point: 24px;
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  min-height: 64px;
  padding: 0 52px 0 30px;
  color: var(--white);
  font-size: 20px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
}
.button:focus-visible { outline-color: var(--ink); }
.button::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: var(--ink);
  clip-path: polygon(0 0, calc(100% - var(--point)) 0, 100% 50%, calc(100% - var(--point)) 100%, 0 100%);
  transition: right .3s var(--drive);
}
.button span { transition: transform .3s var(--drive); }
.button:active::before { background: var(--bottle); }
.button-small {
  --point: 16px;
  min-height: 44px;
  padding: 0 32px 0 18px;
  font-size: 17px;
}
@media (hover: hover) {
  .button:hover::before { right: -14px; }
  .button:hover span { transform: translateX(7px); }
}

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 600;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}
.text-link:hover { text-decoration-thickness: 4px; }

/* Header */

.header {
  position: sticky;
  z-index: 10;
  top: 0;
  display: flex;
  align-items: center;
  gap: 32px;
  height: var(--header);
  padding: 0 var(--gutter);
  background: var(--signal);
}
.header-logo {
  display: flex;
  align-items: center;
  min-height: 44px;
  margin-right: auto;
}
.header-logo img { width: auto; height: clamp(22px, 2.2vw, 30px); }
.header-nav { display: none; gap: 32px; font-size: 17px; font-weight: 500; }
.header-nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}
.header-nav a:hover {
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}
@media (min-width: 800px) { .header-nav { display: flex; } }
@media (max-width: 379px) {
  .header { gap: 12px; }
  .header-logo img { height: 18px; }
}

/* Opening screen */

.hero {
  display: flex;
  flex-direction: column;
  min-height: calc(100svh - var(--header));
  padding: clamp(20px, 3.5vh, 56px) var(--gutter) 0;
  background: var(--signal);
  overflow: clip;
}
.hero h1 {
  position: relative;
  z-index: 1;
  margin-left: -.05em;
  font-size: 23.5vw;
  letter-spacing: -.045em;
  line-height: .88;
}
.hero h1 span { display: block; }
.hero-lower {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.hero-text {
  position: relative;
  z-index: 1;
  padding-top: 28px;
}
.hero-text p {
  max-width: 27em;
  font-size: clamp(20px, 1.75vw, 30px);
  font-weight: 500;
  line-height: 1.35;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 40px;
  margin-top: 28px;
}
.hero-arrows {
  position: relative;
  flex: 1;
  min-height: 190px;
  margin-top: 32px;
}
.hero-arrows svg {
  position: absolute;
  top: 0;
  right: calc(var(--gutter) * -1 - 12vw);
  width: auto;
  height: max(300px, 120%);
  overflow: visible;
}
.arrow-small { fill: var(--white); }
.arrow-large { fill: var(--ink); }

@media (min-width: 640px) {
  .hero { min-height: min(100svh - var(--header), 75vw); }
  .hero h1 { font-size: min(14vw, 30svh); }
  .hero-text {
    width: 46%;
    padding: clamp(28px, 5vh, 64px) 0 48px;
  }
  .hero-arrows {
    position: absolute;
    inset: clamp(28px, 5vh, 64px) 0 0 50%;
    min-height: 0;
    margin: 0;
  }
  .hero-arrows svg {
    right: calc(var(--gutter) * -1 - 3vw);
    height: min(135%, 44vw);
  }
}

.not-found h1 { font-size: min(15vw, 34svh); }
.not-found .hero-text { width: auto; }

/* What we do: two arrow blocks that lock together */

.services {
  padding: var(--section) 0;
  background: var(--white);
  color: var(--bottle);
  overflow: clip;
}
.services h2 { padding: 0 var(--gutter); }
.service-blocks {
  --point: 36px;
  display: grid;
  gap: 16px;
  margin-top: clamp(40px, 5vw, 80px);
}
.service {
  display: flex;
  flex-direction: column;
  padding: 56px calc(var(--point) + 28px) 56px var(--gutter);
}
.service h3 {
  font-size: clamp(38px, 4.6vw, 84px);
  text-wrap: balance;
}
.service p { max-width: 27em; margin-top: 24px; }
.service ul {
  margin-top: 32px;
  font-size: clamp(21px, 1.8vw, 30px);
  font-weight: 600;
  line-height: 1.35;
}
.service-brand {
  margin-right: 20px;
  background: var(--bottle);
  color: var(--white);
  clip-path: polygon(0 0, calc(100% - var(--point)) 0, 100% 50%, calc(100% - var(--point)) 100%, 0 100%);
}
.service-web {
  background: var(--signal);
  color: var(--ink);
  margin-right: 20px;
  clip-path: polygon(0 0, calc(100% - var(--point)) 0, 100% 50%, calc(100% - var(--point)) 100%, 0 100%);
}
@media (min-width: 1000px) {
  .service-blocks {
    --point: clamp(90px, 10vw, 190px);
    grid-template-columns: 1fr 1fr;
    gap: 0;
  }
  .service { min-height: clamp(460px, 42vw, 760px); padding-block: clamp(48px, 5vw, 88px); }
  .service ul { margin-top: auto; padding-top: 40px; }
  .service-brand {
    margin-right: calc(var(--point) / -2);
    padding-right: calc(var(--point) + 16px);
  }
  .service-web {
    margin: 0 0 0 calc(var(--point) / -2 + 20px);
    padding-left: calc(var(--point) + 40px);
    padding-right: var(--gutter);
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, var(--point) 50%);
  }
}

/* How it works: arrows that gain size with each step */

.steps {
  padding: var(--section) var(--gutter);
  background: var(--mist);
  overflow: clip;
}
.steps h2 { color: var(--bottle); }
.steps ol {
  display: grid;
  gap: 56px;
  margin-top: clamp(48px, 5vw, 80px);
}
.steps svg { width: auto; height: var(--size); fill: var(--bottle); }
.steps li:nth-child(1) { --size: 64px; }
.steps li:nth-child(2) { --size: 104px; }
.steps li:nth-child(3) { --size: 152px; }
.steps li:nth-child(1) svg { fill: var(--signal); }
.steps h3 {
  margin-top: 28px;
  color: var(--bottle);
  font-size: clamp(36px, 3.8vw, 68px);
}
.steps p { max-width: 20em; margin-top: 14px; }
@media (min-width: 800px) {
  .steps ol { grid-template-columns: repeat(3, 1fr); gap: 40px; }
  .steps li { display: grid; grid-template-rows: subgrid; grid-row: span 3; row-gap: 0; }
  .steps svg { align-self: end; }
  .steps li:nth-child(1) { --size: 7vw; }
  .steps li:nth-child(2) { --size: 12vw; }
  .steps li:nth-child(3) { --size: 19vw; }
}

/* About: the tagline, always orange on green */

.about {
  padding: var(--section) var(--gutter);
  background: var(--bottle);
  color: var(--white);
  overflow: clip;
}
.about h2 {
  margin-left: -.04em;
  color: var(--signal);
  font-size: 19vw;
  line-height: .9;
  letter-spacing: -.045em;
}
.about p {
  max-width: 30em;
  margin-top: 40px;
  font-size: clamp(21px, 2vw, 34px);
  line-height: 1.4;
}
@media (min-width: 800px) {
  .about h2 { font-size: 9.6vw; white-space: nowrap; }
  .about p { margin: clamp(48px, 6vw, 104px) 0 0 auto; width: 58%; }
}

/* Contact */

.contact {
  padding: var(--section) var(--gutter);
  background: var(--signal);
}
.contact h2 { max-width: 9em; font-size: clamp(56px, 10.5vw, 196px); line-height: .9; }
.contact-lower {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 48px 64px;
  margin-top: clamp(36px, 4.5vw, 72px);
}
.contact-lower p:first-child {
  max-width: 22em;
  margin-bottom: 28px;
  font-size: clamp(20px, 1.75vw, 30px);
  font-weight: 500;
  line-height: 1.35;
}
.address { position: relative; }
.address a {
  display: block;
  font-size: clamp(25px, 2.8vw, 48px);
  font-weight: 600;
  letter-spacing: -.02em;
  text-decoration-thickness: 3px;
  text-underline-offset: 8px;
}
.copy {
  min-height: 48px;
  margin-top: 20px;
  padding: 0 22px;
  border: 2px solid var(--ink);
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
}
.copy:hover { background: var(--ink); color: var(--white); }
.copy:focus-visible { outline-color: var(--ink); }
.copy-status { min-height: 1.5em; margin-top: 8px; font-size: 17px; font-weight: 500; }

/* Footer */

.footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 48px;
  padding: 40px var(--gutter);
  background: var(--ink);
  color: var(--white);
  font-size: 17px;
}
.footer img { width: auto; height: 26px; margin-right: auto; }
.footer a { display: inline-flex; align-items: center; min-height: 44px; text-underline-offset: 5px; }

/* Movement: everything drives forward, left to right. Off when the device asks for less. */

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  .hero h1 span, .hero-arrows path { animation: drive-in .8s var(--drive) backwards; }
  .hero h1 span { --from: calc(var(--gutter) * -.4); }
  .hero h1 span:nth-child(2) { --from: calc(var(--gutter) * -.8); }
  .hero-arrows .arrow-large { --from: -110vw; animation-duration: .9s; }
  .hero-arrows .arrow-small { --from: -110vw; animation-delay: .12s; animation-duration: .9s; }

  @supports (animation-timeline: scroll()) {
    .hero-arrows svg {
      animation: drive-out linear both;
      animation-timeline: scroll(root);
      animation-range: 0 100vh;
    }
  }

  /* .js is added by script.js, so nothing is displaced if scripts don't run */
  .js [data-drive] :is(.service, h2, li svg) { transition: transform .9s var(--drive); }
  .js .services[data-drive]:not(.driven) .service-brand { transform: translateX(-70%); }
  .js .services[data-drive]:not(.driven) .service-web { transform: translateX(-35%); }
  .js .steps[data-drive]:not(.driven) li svg { transform: translateX(-60vw); }
  .js .steps li:nth-child(2) svg { transition-delay: .1s; }
  .js .steps li:nth-child(3) svg { transition-delay: .2s; }
  .js .about[data-drive]:not(.driven) h2 { transform: translateX(-45vw); }
}

@media (prefers-reduced-motion: reduce) {
  .button::before, .button span { transition: none; }
}

@keyframes drive-in { from { transform: translateX(var(--from)); } }
@keyframes drive-out { to { transform: translateX(45vw); } }

@media print { .header { position: static; } }
