/* TriPeak CPG Consulting - site stylesheet.
   One file for all pages. Mobile layout below 768px (same breakpoint as the old site).
   Sizes were measured from the old site at nine window sizes (390 to 2560px wide)
   and fitted so the layout follows it at every width: content is capped at 1400px wide,
   blocks stop growing at about 1667px, and widths between the measured ones are interpolated. */

/* ---------- Fonts ---------- */
@font-face {
  font-family: "Anton";
  src: url("/assets/fonts/anton-latin-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Epilogue";
  src: url("/assets/fonts/epilogue-latin-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Epilogue";
  src: url("/assets/fonts/epilogue-latin-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --bg: #f4f4f3;
  --text: #383838;
  --black: #000;
  --white: #fff;
  --yellow: #ffc700;

  --font-head: "Anton", Impact, "Arial Narrow", sans-serif;
  --font-body: "Epilogue", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  /* Content column: 92% of the window, never wider than 1400px, centered. */
  --cw: min(92vw, 1400px);
  --gutter: calc((100vw - var(--cw)) / 2);
  --header-h: calc(4vw + 61px);

  /* Ramps used to follow the live site's fluid layout between window sizes.
     r1: 1280 to 1440 wide. r2: 1440 to 1522 (column still growing).
     r3: 1440 to 1667 (rows still growing). r4: beyond 1728 (padding in vw keeps growing).
     v1: 820 to 1280 (type only). Every block size is flat once the ramps run out. */
  --r1: clamp(0px, 100vw - 1280px, 160px);
  --r2: clamp(0px, 100vw - 1440px, 82px);
  --r3: clamp(0px, 100vw - 1440px, 227px);
  --r4: max(0px, 100vw - 1728px);
  --r5: max(0px, 100vw - 1440px);               /* small text keeps shrinking */
  --r6: max(0px, 100vw - 1920px);
  --v1: clamp(0px, 100vw - 820px, 460px);

  /* Type scale on desktop and tablet: value at 820px wide, rising to 1280, then to 1440 where it stops. */
  --fs-h1: calc(45.52px + var(--v1) * 0.036 + var(--r1) * 0.027);
  --fs-h2: calc(33.71px + var(--v1) * 0.0216 + var(--r1) * 0.0162);
  --fs-h3: calc(27.81px + var(--v1) * 0.0144 + var(--r1) * 0.0108);
  --fs-h4: calc(21.9px + var(--v1) * 0.0072 + var(--r1) * 0.0054);
  --fs-lead: calc(19.94px + var(--v1) * 0.0048 + var(--r1) * 0.0036);
  --fs-small: calc(14.4px - var(--r1) * 0.0008 - var(--r5) * 0.0012);

  interpolate-size: allow-keywords;
}

@media (max-width: 767px) {
  :root {
    --gutter: 6vw;        /* 23.4px at 390 */
    --cw: calc(100vw - 2 * var(--gutter));
    --header-h: 84px;
    /* Type scale on phones: value at 390px wide rising linearly with the window. */
    --fs-h1: clamp(46.38px, calc(46.38px + (100vw - 390px) * 0.019063), 66.4px);
    --fs-h2: clamp(34.23px, calc(34.23px + (100vw - 390px) * 0.011438), 46.24px);
    --fs-h3: clamp(28.15px, calc(28.15px + (100vw - 390px) * 0.007629), 36.16px);
    --fs-h4: clamp(22.08px, calc(22.08px + (100vw - 390px) * 0.00381), 26.08px);
    --fs-lead: clamp(20.05px, calc(20.05px + (100vw - 390px) * 0.002543), 22.72px);
    --fs-small: clamp(14.27px, calc(14.99px - (100vw - 390px) * 0.000686), 14.99px);
  }
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  /* The page is at least as tall as the window; the footer rides at the bottom. */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1 0 auto; }

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

h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 400;
  text-transform: uppercase;
}

.heading-xl { font-size: var(--fs-h1); line-height: 1.056; }
.heading-l  { font-size: var(--fs-h2); line-height: 1.1136; }
.heading-m  { font-size: var(--fs-h3); line-height: 1.1424; }
.heading-s  { font-size: var(--fs-h4); line-height: 1.1712; }

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--black);
  outline-offset: 3px;
  box-shadow: 0 0 0 2px var(--white);
}

main:focus { outline: none; box-shadow: none; }

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

/* ---------- Skip link ---------- */
.skip-link {
  position: fixed;
  top: 24px;
  left: -16000px;
  z-index: 300;
  padding: 19.2px 32px;
  border-radius: 300px;
  background: var(--black);
  color: var(--white);
  text-transform: uppercase;
  text-decoration: none;
}
.skip-link:focus { left: 24px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 19.2px 32px;
  border: 0;
  border-radius: 300px;
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: normal;
  text-transform: uppercase;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: opacity 0.1s linear;
}
.btn:hover { opacity: 0.8; }
.btn--grey { background: var(--text); }
.btn--yellow { background: var(--yellow); color: var(--black); }
.btn[disabled] { opacity: 0.6; cursor: default; }

/* ---------- Header ---------- */
.site-header {
  position: absolute;      /* without JavaScript the header scrolls away with the page */
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  transition: background 0.3s ease-in-out;
}
.js .site-header { position: fixed; }

.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 2vw var(--gutter);
  transition: padding 0.14s ease-in-out;
}

.site-header.is-scrolled { background: var(--bg); }
.site-header.is-scrolled .site-header__inner { padding-block: 1.8vw; }

.site-logo { position: relative; z-index: 2; display: block; line-height: 0; }
.site-logo img { width: 444px; height: auto; }

.site-nav { display: flex; gap: 2vw; }
.site-nav a {
  padding: 1.6px 0;
  border-bottom: 1px solid transparent;
  color: var(--text);
  text-decoration: none;
}
.site-nav a[aria-current="page"] { border-bottom-color: currentColor; }

.menu-button { display: none; }

@media (max-width: 767px) {
  .site-header__inner { align-items: flex-start; padding-block: 27px; }
  .site-header.is-scrolled .site-header__inner { padding-block: 24px; }
  .site-logo img { width: min(55.9vw, 218px); }

  /* No JavaScript: simple row of links under the logo. */
  .site-nav { width: 100%; justify-content: center; gap: 24px; padding-top: 8px; }

  /* With JavaScript: hamburger button and full-screen menu. */
  .js .site-nav {
    position: fixed;
    inset: 0;
    z-index: 1;
    width: auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: var(--header-h) 0 0;
    background: var(--bg);
    font-size: 33.15px;
    line-height: 33px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  }
  .js .site-nav.is-open { opacity: 1; visibility: visible; }
  .js .site-nav a { padding: 12px 0; border-bottom: 0; color: var(--black); }

  .js .menu-button {
    position: relative;
    z-index: 2;
    display: block;
    width: 47px;
    height: 37px;
    margin: -4px -6px 0 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
  }
  .menu-button__line {
    position: absolute;
    left: 0;
    width: 35px;
    height: 1px;
    background: var(--text);
    transition: transform 0.2s ease;
  }
  .menu-button__line:nth-of-type(2) { top: 12px; }   /* (1) is the hidden label */
  .menu-button__line:nth-of-type(3) { top: 23px; }
  .menu-button[aria-expanded="true"] .menu-button__line:nth-of-type(2) { top: 17px; transform: rotate(45deg); }
  .menu-button[aria-expanded="true"] .menu-button__line:nth-of-type(3) { top: 17px; transform: rotate(-45deg); }

  .menu-open body { overflow: hidden; }
}

/* ---------- Page frame ---------- */
main { padding-top: var(--header-h); }

@media (max-width: 767px) {
  html:not(.js) main { padding-top: calc(var(--header-h) + 44px); }
}

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  --foot-h: calc(136px + var(--r1) * 0.05 + var(--r2) * 0.085);   /* footer and badge size */
  display: grid;
  grid-template-columns: 34% 33.2% 16.8% 16%;
  grid-template-areas: "brand badge location contact";
  align-items: start;
  min-height: var(--foot-h);
  padding: 0 var(--gutter);
  color: var(--black);
}
.site-footer__badge { grid-area: badge; width: var(--foot-h); height: var(--foot-h); }
.site-footer__location { grid-area: location; margin-top: calc(26px + var(--r1) * 0.013 + var(--r2) * 0.024); }
.site-footer__contact { grid-area: contact; margin-top: calc(26px + var(--r1) * 0.013 + var(--r2) * 0.024); }
.site-footer__brand { grid-area: brand; margin-top: calc(56px + var(--r1) * 0.006 + var(--r2) * 0.037); }
.site-footer__heading { font-size: var(--fs-h4); line-height: 1.1712; }
.site-footer__location p { margin-top: calc(31.5px + var(--r1) * 0.006); }
.site-footer__brand p { margin-top: 0; }
.site-footer__contact a { display: inline-block; border-bottom: 1px solid currentColor; text-decoration: none; }

@media (max-width: 767px) {
  .site-footer {
    display: block;
    min-height: 0;
    padding: 24px var(--gutter);
  }
  .site-footer__badge { width: 144px; height: 144px; margin: 0 auto; }
  .site-footer__location { margin-top: 24px; }
  .site-footer__location p { margin-top: 32px; }
  .site-footer__contact { margin-top: 38px; }
  .site-footer__brand { margin-top: 33px; }
  .site-footer__brand p { margin-top: 11px; }
}

/* ---------- Home: hero ---------- */
/* The photo is 92% of the window wide (not capped) and its height follows the fluid rows.
   Title and text are centered boxes whose width and position are fitted to the live site. */
.hero {
  --hero-h: calc(686px + var(--r1) * 0.269 + var(--r3) * 0.361);
  position: relative;
  box-sizing: border-box;
  height: calc(var(--hero-h) + 4vw);
  margin: 0 4vw;
  padding-bottom: 4vw;
  overflow: hidden;
  background: var(--text);
  background-clip: content-box;
  color: var(--white);
}
.hero__image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--hero-h);
  object-fit: cover;
  filter: brightness(0.5);   /* the live hero photo is darkened by half */
}
.hero__title {
  position: absolute;
  top: calc(239px + var(--r1) * 0.125 + var(--r3) * 0.128);
  left: 0;
  right: 0;
  width: calc(985px + var(--r1) * 0.769 + var(--r3) * 0.767);
  margin: 0 auto;
  font-size: var(--fs-h2);
  line-height: 1.1136;
  text-align: center;
}
.hero__text {
  position: absolute;
  top: calc(546px + var(--r1) * 0.287 + var(--r3) * 0.291);
  left: 0;
  right: 0;
  width: calc(623px + var(--r1) * 0.487 + var(--r3) * 0.489);
  margin: 0 auto;
  text-align: center;
}

@media (max-width: 767px) {
  /* The photo is shorter than the box here, so a strip of box shows above and below it. Each strip
     takes the colour of the photo edge it touches (dark sky above, dark ground below, both measured
     from this photo as displayed, darkened), so the photo appears to run the full height with no
     bars. The colours switch at 199px, the middle of the photo, hidden behind it. If the photo is
     ever replaced, re-measure the two colours. (The old site used one lighter grey for both.) */
  .hero {
    height: auto;
    margin: 0 16px;
    padding: 105px 23px 10px;
    background: linear-gradient(to bottom, #1a1a1a 199px, #0c0c0c 199px);
    background-clip: border-box;
  }
  /* Each end of the photo also fades into its strip over 32px. On phones the colours already match;
     the fade is for windows 650 to 767px wide (phones held sideways, small tablets), where a snow
     peak touches the photo's top left corner and would otherwise be cut off in a hard line. */
  .hero__image {
    height: 328px;
    top: 35px;
    bottom: auto;
    -webkit-mask-image: linear-gradient(to bottom, transparent, #000 32px, #000 calc(100% - 32px), transparent);
    mask-image: linear-gradient(to bottom, transparent, #000 32px, #000 calc(100% - 32px), transparent);
  }
  .hero__title, .hero__text { position: relative; inset: auto; width: auto; margin: 0; }
  .hero__text { margin-top: 45px; }
}

/* ---------- Home: "We serve founders" ---------- */
.founders {
  display: grid;
  grid-template-columns: calc(var(--cw) * 0.538) calc(var(--cw) * 0.37);
  column-gap: calc(var(--cw) * 0.0505);
  align-items: start;
  padding: 0 var(--gutter) calc(79px + var(--r1) * 0.075 + var(--r2) * 0.085);
}
.founders__video {
  aspect-ratio: 16 / 9;
  margin-top: calc(73px + var(--r1) * 0.037 + var(--r2) * 0.037);
  overflow: hidden;
}
/* The video file has black bars built in. Showing the middle 72% of the width and
   zooming in slightly hides them, so only the picture shows, as on the live site. */
.founders__video video {
  width: 68.4%;
  height: 100%;
  margin: 0 auto;
  object-fit: cover;
  transform: scale(1.05);
  transform-origin: 50% 100%;
}
.founders__body { padding-top: calc(109px + var(--r1) * 0.062 + var(--r2) * 0.061); }
.founders__title { margin-bottom: calc(48px + var(--r1) * 0.019 + var(--r3) * 0.009); }
.founders__action { width: 88.6%; margin-top: calc(47px + var(--r1) * 0.037 + var(--r2) * 0.098); text-align: center; }

@media (max-width: 767px) {
  .founders {
    display: block;
    margin-top: 15px;
    padding: 0 var(--gutter) 2px;
  }
  /* Same crop as on desktop, so the black bars built into the video file never show: the box has
     the shape of the visible picture (1.277 wide to 1 tall) and the video fills it, zoomed 5%.
     (The old site showed the middle 81% of the frame here, which left a strip of black each side.) */
  .founders__video { width: 80.8%; margin: 0 auto; aspect-ratio: 1.2768; }
  .founders__video video { width: 100%; }
  .founders__body { padding-top: 52px; }
  .founders__title { margin-bottom: 11px; }
  .founders__action { width: auto; margin-top: 13px; }
}

/* ---------- Home: "What we do" accordion ---------- */
.what-we-do {
  display: grid;
  grid-template-columns: calc(var(--cw) * 0.2441) calc(var(--cw) * 0.4536);
  grid-template-rows: auto 1fr;
  grid-template-areas:
    "title list"
    "action list";
  column-gap: calc(var(--cw) * 0.2174);
  padding: 0 var(--gutter) calc(45px + var(--r1) * 0.019 + var(--r3) * 0.053 + var(--r4) * 0.034) calc(var(--gutter) + var(--cw) * 0.0842);
  background: var(--white);
}
.what-we-do__title {
  grid-area: title;
  margin-top: calc(79px + var(--r1) * 0.181 + var(--r3) * 0.048 + var(--r4) * 0.032);
  text-align: center;
}
.accordion { grid-area: list; margin-top: calc(42px + var(--r1) * 0.031 + var(--r3) * 0.044 + var(--r4) * 0.032); }
.what-we-do__action { grid-area: action; margin-top: calc(14px + var(--r1) * 0.1375 + var(--r2) * 0.049); text-align: center; }

.accordion__item { border-top: 1px solid var(--black); }
.accordion__item:last-child { border-bottom: 1px solid var(--black); }

/* The title fills the whole row (as on the live site) and the plus sign sits at the right edge. */
.accordion__summary {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: calc(68px + var(--r1) * 0.0125);
  color: var(--black);
  cursor: pointer;
  list-style: none;
}
.accordion__summary::-webkit-details-marker { display: none; }
.accordion__title {
  display: flex;
  flex: 1;
  align-items: center;
  align-self: stretch;
  font-size: var(--fs-h4);
  line-height: 1.1712;
}

.accordion__icon { position: absolute; top: calc(50% - 7px); right: 0; flex: none; width: 14px; height: 14px; }
.accordion__icon::before,
.accordion__icon::after {
  content: "";
  position: absolute;
  top: 6.5px;
  left: 0;
  width: 14px;
  height: 1px;
  background: var(--black);
  transition: transform 0.25s;
}
.accordion__icon::after { transform: rotate(90deg); }
.accordion__item[open] .accordion__icon::after { transform: rotate(0); }

.accordion__panel { width: 70%; padding-bottom: 30px; }

/* Smooth open and close in browsers that support styling the details content. */
.accordion__item::details-content {
  height: 0;
  overflow: clip;
  transition: height 0.25s cubic-bezier(0.66, 0, 0.34, 1), content-visibility 0.25s allow-discrete;
}
.accordion__item[open]::details-content { height: auto; }

@media (max-width: 767px) {
  .what-we-do {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    grid-template-areas:
      "title"
      "list"
      "action";
    padding: 27.85px var(--gutter) 30px;
  }
  .what-we-do__title { margin-top: 0; margin-bottom: 56px; }
  .what-we-do__action { margin-top: 48px; }
  .accordion__summary { min-height: 63px; }
  .accordion { margin-top: 0; }
}

/* ---------- Home: client logo marquee ---------- */
.clients { overflow: hidden; padding: calc(49px + var(--r1) * 0.0437) 0; }
.marquee {
  --logo-w: 240px;
  --logo-h: 120px;
  --logo-gap: 57.6px;
  display: flex;
  width: max-content;
  animation: marquee 45s linear infinite;
}
.marquee__list {
  display: flex;
  gap: var(--logo-gap);
  padding: 0 var(--logo-gap) 0 0;
  margin: 0;
  list-style: none;
}
.marquee__list img {
  width: var(--logo-w);
  height: var(--logo-h);
  object-fit: contain;
}
@keyframes marquee {
  to { transform: translateX(-50%); }
}

@media (max-width: 767px) {
  .clients { padding: 28px 0; }
  .marquee { --logo-w: 150px; --logo-h: 70px; --logo-gap: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  .marquee { width: auto; animation: none; justify-content: center; }
  .marquee__list { flex-wrap: wrap; justify-content: center; padding: 0 var(--gutter); }
  .marquee__list[aria-hidden="true"] { display: none; }
}

/* ---------- Home: testimonials ---------- */
.testimonials {
  padding:
    calc(42px + var(--r1) * 0.031 + var(--r3) * 0.044 + var(--r4) * 0.032)
    0
    calc(42px + var(--r1) * 0.194 + var(--r3) * 0.0845 + var(--r4) * 0.034);
}
.testimonials__list { display: block; margin-top: calc(12px + var(--r1) * 0.094 + var(--r2) * 0.049); }
.testimonials__title { width: calc(var(--cw) * 0.2441); margin: 0 auto; text-align: center; }

/* Photos are a sixth of the content column; quotes sit beside them. Row offsets follow the live site. */
.testimonial {
  display: grid;
  grid-template-columns: calc(var(--cw) * 0.16) calc(var(--cw) * 0.7057);
  column-gap: calc(var(--cw) * 0.05);
  align-items: start;
  padding: 0 var(--gutter);
}
.testimonial__photo {
  width: calc(var(--cw) * 0.16);
  height: calc(var(--cw) * 0.16);
  border-radius: 50%;
  object-fit: cover;
}
.testimonial__quote { font-weight: 700; }
.testimonial__quote p { margin-bottom: 16px; }
.testimonial__name { margin-top: 16px; }

.testimonial--first .testimonial__photo { margin-top: calc(22px - var(--r1) * 0.094 - var(--r3) * 0.009); }

.testimonial--second {
  grid-template-columns: calc(var(--cw) * 0.6643) calc(var(--cw) * 0.16);
  column-gap: calc(var(--cw) * 0.0497);
  margin-top: calc(47px + var(--r1) * 0.069);
  padding: 0 var(--gutter) 0 calc(var(--gutter) + var(--cw) * 0.126);
}
.testimonial--second .testimonial__photo { grid-column: 2; grid-row: 1; margin-top: calc(17px - var(--r1) * 0.069); }
.testimonial--second .testimonial__text { grid-column: 1; grid-row: 1; }
.testimonial--second .testimonial__name { text-align: right; margin-top: 16px; }

.testimonial--third { margin-top: calc(28px - var(--r1) * 0.013 + var(--r2) * 0.159); }
.testimonial--third .testimonial__text { margin-top: calc(19px + var(--r1) * 0.087 + var(--r2) * 0.024); }

@media (max-width: 767px) {
  .testimonials { padding: 27.85px 0 27px; }
  .testimonials .testimonials__title { width: auto; margin: 0; text-align: center; padding: 0 var(--gutter); }
  /* On mobile the EZ Bombs testimonial comes first, as on the live site. */
  .testimonials__list { display: flex; flex-direction: column; margin-top: 0; }
  .testimonial--second { order: -1; }
  .testimonial,
  .testimonial--second {
    display: block;
    padding: 0 var(--gutter);
  }
  .testimonial--second { margin-top: 32px; }
  .testimonial--first, .testimonial--third { margin-top: 11px; }
  .testimonial__photo,
  .testimonial--first .testimonial__photo,
  .testimonial--second .testimonial__photo {
    width: 129px;
    height: 129px;
    margin: 0 auto 11px;
  }
  .testimonial--third .testimonial__text { margin-top: 0; }
  .testimonial--second .testimonial__name { margin-top: 16px; }
}

/* ---------- Home: "Why TriPeak?" ---------- */
.why {
  display: grid;
  grid-template-columns: calc(var(--cw) * 0.4536) calc(var(--cw) * 0.3279);
  column-gap: calc(var(--cw) * 0.1343);
  align-items: start;
  padding: 0 var(--gutter) calc(37px + var(--r1) * 0.025 + var(--r2) * 0.024);
}
.why__image { margin-top: calc(135px - var(--r1) * 0.075 + var(--r2) * 0.024); aspect-ratio: 16 / 9; width: 100%; object-fit: contain; }
.why__body { padding-top: calc(111px + var(--r1) * 0.056 + var(--r2) * 0.061); }
.why__text { margin-top: calc(23px + var(--r1) * 0.025 + var(--r2) * 0.037); }
/* "About us" is a standard button, the same size as the others (the old site had a slim one here,
   24 to 30px tall), so this section is about 27px taller than on the old site. */
.why__action { width: 87%; margin-top: calc(48px + var(--r1) * 0.075 + var(--r2) * 0.146); text-align: center; }

@media (max-width: 767px) {
  .why { display: block; padding: 4px var(--gutter) 36px; }
  .why__image { margin-top: 0; }
  .why__body { padding-top: 49px; }
  .why__text { margin-top: 32px; }
  .why__action { width: auto; margin-top: 13px; }   /* same gap as above "Learn more" */
}

/* ---------- About ---------- */
/* One centered column (about half the content width). Photos and gaps follow the live site's
   fluid rows, so they grow between 1280 and about 1520 wide and then stay put. */
.about { display: flow-root; padding: 0 var(--gutter) calc(13px + var(--r1) * 0.014 + var(--r2) * 0.313 + var(--r4) * 0.011); }
.about__title {
  margin-top: calc(85px + var(--r1) * 0.05 + var(--r3) * 0.031 + var(--r4) * 0.01);
  text-align: center;
}
.person { width: calc(var(--cw) * 0.4958); margin: 0 auto; }
.person__photo {
  display: block;
  width: calc(var(--cw) * 0.3279);
  max-width: 100%;
  height: calc(425px + var(--r1) * 0.237 + var(--r2) * 0.232);
  margin: 0 auto;
  object-fit: cover;
}
.person__name { margin-bottom: calc(17px + var(--r1) * 0.013 + var(--r2) * 0.012); }
.person__role { font-size: var(--fs-lead); line-height: 1.5; color: var(--black); margin-bottom: calc(17px - var(--r1) * 0.006); }
.person__bio p + p { margin-top: 16px; }
.person__list-title { margin: 32px 0; color: var(--black); }
.checklist { padding-left: 40px; }
.checklist li + li { margin-top: 8px; }

.person--rob .person__photo { margin-top: calc(60.4px + var(--r1) * 0.044 + var(--r2) * 0.049); }
.person--rob .person__name { margin-top: calc(90px + var(--r1) * 0.044 + var(--r2) * 0.073); }
.person--alexa { margin-top: calc(55px + var(--r1) * 0.025 + var(--r2) * 0.646); }
.person--alexa .person__name { margin-top: calc(54px + var(--r1) * 0.025 + var(--r2) * 0.049); }
.person--levi { margin-top: calc(47px + var(--r1) * 0.019 + var(--r2) * 0.305); }
.person--levi .person__name { margin-top: calc(48px + var(--r1) * 0.019); margin-bottom: 10px; }

@media (max-width: 767px) {
  .about { padding: 8.44px var(--gutter) 8px; }
  .about__title { margin-top: 70px; }
  .person { width: auto; }
  .person__role { margin-bottom: 16px; }
  .person__photo { width: 100%; height: 374px; }
  .person--rob .person__photo { margin-top: 32px; }
  .person--rob .person__name,
  .person--alexa .person__name,
  .person--levi .person__name { margin-top: 22px; margin-bottom: 21px; }
  .person__list-title { margin: 32px 0; }
  .person--alexa { margin-top: 19px; }
  .person--levi { margin-top: 11px; }
}

/* ---------- Services ---------- */
.services-intro {
  display: grid;
  grid-template-columns: calc(var(--cw) * 0.3779) calc(var(--cw) * 0.58);
  min-height: 33vh;
  padding:
    calc(72px + var(--r1) * 0.05 + var(--r3) * 0.048 + var(--r4) * 0.034)
    var(--gutter)
    calc(42px + var(--r1) * 0.033 + var(--r2) * 0.483 + var(--r4) * 0.032);
}
.services-intro h1 { align-self: start; }
.services-intro__text { font-size: var(--fs-lead); line-height: 1.5; color: var(--black); }

/* Three columns of two cards: 1-2, then 3-4, then 5-6. Card width and gaps are shares of the content column. */
.cards {
  display: grid;
  grid-template-columns: repeat(3, calc(var(--cw) * 0.2441));
  grid-template-rows: auto auto;
  column-gap: calc(var(--cw) * 0.092);
  row-gap: calc(11px + var(--r1) * 0.1 + var(--r2) * 0.134 + var(--r4) * 0.016 + var(--r6) * 0.0295);
  min-height: 66vh;
  padding:
    calc(121px + var(--r1) * 0.087 + var(--r3) * 0.088 + var(--r4) * 0.066)
    var(--gutter)
    calc(8vw + 157.6px + var(--r1) * 0.201 + var(--r3) * 0.15 + var(--r4) * 0.103);
}
.cards { padding-left: calc(var(--gutter) + var(--cw) * 0.0419); }
.card { text-align: center; }
.card:nth-child(1) { grid-area: 1 / 1; }
.card:nth-child(2) { grid-area: 2 / 1; }
.card:nth-child(3) { grid-area: 1 / 2; }
.card:nth-child(4) { grid-area: 2 / 2; }
.card:nth-child(5) { grid-area: 1 / 3; }
.card:nth-child(6) { grid-area: 2 / 3; }
.card__image {
  width: 100%;
  height: calc(352px + var(--r1) * 0.2 + var(--r2) * 0.195);
  border-radius: 28px;
  object-fit: cover;
}
/* The logo card: show the whole image at any box shape (never crop a logo); white fills the rest. */
.card__image--logos { object-fit: contain; background: var(--white); }
.card__title {
  position: relative;
  display: inline-block;
  margin-top: calc(27px + var(--r1) * 0.013 + var(--r2) * 0.037);
  margin-bottom: calc(26px + var(--r1) * 0.019 + var(--r2) * 0.024);
  color: var(--black);
}
/* Hand-drawn style underline under each card title. */
.card__title::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: -7px;
  height: 5px;
  border-radius: 5px 2px 2px 5px;
  background: var(--black);
  transform: rotate(-0.4deg);
}
.card__text { font-size: var(--fs-small); line-height: 1.5; }

/* Bottom banner: the photo box is the curved strip (8vw) plus the section below it, which is at
   least a third of the window tall. As on the live site, heading and button stay at the bottom of
   the box, so any spare height on a tall window opens up above the heading. */
.banner {
  --curve: 8vw;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  min-height: calc(var(--curve) + 33vh);
  margin: calc(var(--curve) * -1) 0 0;
  padding: calc(var(--curve) + 6.6vw + var(--r6) * 0.0078) calc(var(--cw) * 0.126) calc(4.45vw - 3px + var(--r1) * 0.019 - var(--r6) * 0.0078);
  color: var(--white);
  text-align: center;
  clip-path: polygon(
    0 var(--curve),
    10% calc(var(--curve) * 0.81),
    20% calc(var(--curve) * 0.64),
    30% calc(var(--curve) * 0.495),
    40% calc(var(--curve) * 0.35),
    50% calc(var(--curve) * 0.217),
    60% calc(var(--curve) * 0.13),
    70% calc(var(--curve) * 0.07),
    80% calc(var(--curve) * 0.03),
    90% calc(var(--curve) * 0.01),
    100% 0,
    100% 100%,
    0 100%
  );
}
.banner__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}
.banner::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0.15);
}
.banner__title, .banner__action { position: relative; z-index: 2; }
.banner__title { margin-bottom: calc(27px + var(--r1) * 0.037 + var(--r2) * 0.061); }

@media (max-width: 767px) {
  .services-intro { display: block; min-height: 0; padding: 56px var(--gutter) 0; }
  .services-intro__text { margin-top: 18px; }
  .cards {
    display: block;
    min-height: 0;
    margin-top: 83px;
    padding: 0 var(--gutter);
  }
  /* Cards stack in HTML order. Small gap inside a desktop column, larger gap after its last card (2, 4, 6). */
  .card { margin-bottom: 11px; }
  .card:nth-child(2), .card:nth-child(6) { margin-bottom: 45px; }
  .card:nth-child(3) { margin-bottom: 15px; }
  .card:nth-child(4) { margin-bottom: 46px; }
  .card__image { width: 100%; height: 374px; }
  .card__title { margin-top: 27px; margin-bottom: 28px; }
  .card__text { font-size: var(--fs-small); }
  /* The button always sits 212px below the top of the heading, however many lines the heading takes. */
  .banner {
    display: grid;
    grid-template-rows: minmax(212px, auto) auto;
    align-items: start;
    justify-content: stretch;
    min-height: 0;
    margin-top: 83px;
    padding: calc(var(--curve) + 14.35vw) var(--gutter) 52px;
  }
  .banner__title { margin-bottom: 0; }
}

/* ---------- Contact ---------- */
/* Text column and photo sit at the two edges of the content column. The photo sets the row height;
   the form is pushed to the bottom of the row. */
.contact {
  display: grid;
  grid-template-columns: calc(var(--cw) * 0.4121) calc(var(--cw) * 0.4536);
  justify-content: space-between;
  padding: calc(36px + var(--r1) * 0.019 + var(--r2) * 0.024) var(--gutter) 0;
}
.contact__main {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: calc(17px + var(--r1) * 0.014 + var(--r2) * 0.02);
}
.contact__text { margin-top: calc(26.4px + var(--r1) * 0.021 + var(--r2) * 0.041); color: var(--black); }
.contact__image {
  width: 100%;
  height: calc(773px + var(--r1) * 0.031 + var(--r2) * 0.402);
  object-fit: cover;
}

.contact-form { color: var(--black); }
.field-group { min-width: 0; margin: 0; padding: 0; border: 0; }
.field-group legend { padding: 0; margin-bottom: 3px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; column-gap: 10px; }
.field + .field-group,
.field-group + .field,
.field + .field { margin-top: 20px; }
.field label { display: block; font-size: 16px; line-height: 28px; }
.field-row .field + .field { margin-top: 0; }
.field-row .field label { font-size: 14.1px; line-height: 27px; }
.field-required { margin-left: 0.35em; color: rgba(0, 0, 0, 0.65); }
.field label .field-required { font-size: 0.9em; }
.field-row .field label .field-required { font-size: 1em; }
.field input,
.field textarea {
  display: block;
  width: 100%;
  padding: 8px 15px;
  border: 1px solid var(--black);
  border-radius: 23.84px;
  background: transparent;
  color: var(--black);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 24px;
}
.field input { height: 42px; }
.field textarea { height: 100px; resize: vertical; }
.field-error { margin-top: 4px; color: #a8071a; font-size: 14px; line-height: 20px; }
.field-error[hidden] { display: none; }

.hp-field { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

#turnstile-widget:not(:empty) { margin-top: 20px; }
.contact-form__submit { margin-top: 20px; }
.contact-form__status { margin-top: 16px; min-height: 24px; }
.contact-form__status:empty { margin-top: 0; min-height: 0; }
.contact-form__noscript { margin-bottom: 16px; }
.contact-thanks { margin-top: 0; }

@media (max-width: 767px) {
  .contact { display: block; padding: 70px var(--gutter) 35px; }
  .contact__main { padding-top: 0; }
  .contact__text { margin-top: 21px; }
  .contact-form { margin-top: 13px; }
  .contact__image { margin-top: 44px; height: 479px; }
}

@media (min-width: 1440px) {
  .banner { margin-bottom: -1px; }   /* tucks 1px under the footer so no sub-pixel seam shows */
}

/* ---------- Tablet (768 to 1279px wide) ----------
   The live site keeps its desktop layout here, with smaller rows. Each value runs from what it is at
   820px wide up to its value at 1280px (the ramp --v1), where the desktop rules above take over. */
@media (min-width: 768px) and (max-width: 1279px) {
  .site-footer {
    --foot-h: calc(146px + var(--v1) * -0.0217);
    grid-template-columns: calc(var(--cw) * 0.297) calc(var(--cw) * 0.379) calc(var(--cw) * 0.17) calc(var(--cw) * 0.154);
  }
  .site-footer__brand { max-width: calc(var(--cw) * 0.2386); margin-top: calc(47px + var(--v1) * 0.0196); }
  .site-footer__location, .site-footer__contact { margin-top: calc(16px + var(--v1) * 0.0217); }

  .hero { --hero-h: calc(560px + var(--v1) * 0.2739); }
  .hero__title { top: calc(181px + var(--v1) * 0.1261); width: calc(631px + var(--v1) * 0.7696); }
  .hero__text { top: calc(413px + var(--v1) * 0.2891); width: calc(397px + var(--v1) * 0.4913); }

  .founders {
    grid-template-columns: calc(var(--cw) * 0.5355) calc(var(--cw) * 0.366);
    column-gap: calc(var(--cw) * 0.0557);
    padding-bottom: calc(55px + var(--v1) * 0.0522);
  }
  .founders__video { margin-top: calc(54px + var(--v1) * 0.0413); }
  .founders__body { padding-top: calc(81px + var(--v1) * 0.0609); }
  .founders__title { margin-bottom: calc(39px + var(--v1) * 0.0196); }
  .founders__action { margin-top: calc(38px + var(--v1) * 0.0196); }

  .what-we-do { padding-bottom: calc(39px + var(--v1) * 0.013); }
  .what-we-do__title { margin-top: calc(74px + var(--v1) * 0.0109); }
  .accordion { margin-top: calc(38px + var(--v1) * 0.0065); }
  .accordion__summary { min-height: calc(63px + var(--v1) * 0.0109); }
  .what-we-do__action { margin-top: calc(11px + var(--v1) * 0.0065); }

  .clients { padding: calc(34.5px + var(--v1) * 0.0315) 0; }

  .testimonials { padding: calc(39px + var(--v1) * 0.0065) 0 calc(39px + var(--v1) * 0.0065); }
  .testimonials__list { margin-top: calc(11px + var(--v1) * 0.0022); }
  .testimonial--first .testimonial__photo { margin-top: calc(105px + var(--v1) * -0.1804); }
  .testimonial--second { margin-top: calc(38px + var(--v1) * 0.0196); }
  .testimonial--second .testimonial__photo { margin-top: calc(120px + var(--v1) * -0.2239); }
  .testimonial--third { margin-top: calc(38px + var(--v1) * -0.0217); }
  .testimonial--third .testimonial__text { margin-top: calc(var(--v1) * 0.0413); }
  .testimonial--third .testimonial__photo { margin-top: calc(51px - var(--v1) * 0.111); }

  .why { padding-bottom: calc(28px + var(--v1) * 0.0196); }
  .why__image { margin-top: calc(232px + var(--v1) * -0.2109); }
  .why__body { padding-top: calc(83px + var(--v1) * 0.0609); }
  .why__text { margin-top: calc(17px + var(--v1) * 0.013); }
  .why__action { margin-top: calc(38px + var(--v1) * 0.0217); }

  .about { padding-bottom: calc(11.5px + var(--v1) * 0.0033); }
  .about__title { margin-top: calc(66.5px + var(--v1) * 0.0402); }
  .person__photo { height: calc(316px + var(--v1) * 0.237); }
  .person--rob .person__photo { margin-top: calc(43.5px + var(--v1) * 0.0359); }
  .person--rob .person__name { margin-top: calc(68px + var(--v1) * 0.0478); }
  .person__name { margin-bottom: calc(14px + var(--v1) * 0.0065); }
  .person__role { margin-bottom: calc(16px + var(--v1) * 0.0022); }
  .person--alexa { margin-top: calc(46px + var(--v1) * 0.0196); }
  .person--alexa .person__name { margin-top: calc(41px + var(--v1) * 0.0283); }
  .person--levi { margin-top: calc(38px + var(--v1) * 0.0196); }
  .person--levi .person__name { margin-top: calc(38px + var(--v1) * 0.0217); margin-bottom: calc(11px + var(--v1) * -0.0022); }

  .services-intro { padding-top: calc(60px + var(--v1) * 0.0261); padding-bottom: calc(37.5px + var(--v1) * 0.0098); }
  .cards { padding-top: calc(105px + var(--v1) * 0.0348); padding-bottom: calc(8vw + calc(163.4px + var(--v1) * -0.0126)); row-gap: calc(10px + var(--v1) * 0.0022); }
  .cards { grid-template-columns: repeat(3, calc(var(--cw) * 0.2386)); column-gap: calc(var(--cw) * 0.0994); }
  .card__image { height: calc(261px + var(--v1) * 0.1978); }
  .card__title { margin-top: calc(24px + var(--v1) * 0.0065); margin-bottom: calc(19px + var(--v1) * 0.0152); }
  .banner { padding-bottom: calc(33px + var(--v1) * 0.0456); }
  .banner__title { margin-bottom: calc(12px + var(--v1) * 0.0326); }

  .contact { padding-top: calc(27px + var(--v1) * 0.0196); }
  .contact__main { padding-top: calc(11.2px + var(--v1) * 0.0126); }
  .contact__text { margin-top: calc(22.8px + var(--v1) * 0.007); }
  .contact__image { height: calc(833px + var(--v1) * -0.1304); }
}

/* ---------- 404 ---------- */
.not-found { padding: 79px var(--gutter) 112px; text-align: center; }
.not-found__text { margin: 24px 0 32px; }
