.cs-lead { margin-top: 16px; font-size: 16px; font-weight: 600; }
.cs-narrow { max-width: 610px; margin-inline: auto; line-height: 1.38; }
.cs-big-title {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: clamp(30px, 3.4vw, 46px);
  line-height: 1.3;
}
.pill-label {
  display: inline-block;
  padding: 7px 12px;
  border-radius: 999px;
  background: #19191b;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

.mono-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 13px 12px;
  max-width: 880px;
  margin-inline: auto;
}
.mono-chips li {
  display: flex;
  align-items: center;
  height: 53px;
  padding: 0 17px;
  border-radius: 10px;
  border: 1px solid #2a2a2e;
  background: linear-gradient(180deg, #141416, #0b0b0c);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  transition: border-color .3s, background-color .3s, box-shadow .3s, transform .3s var(--ease);
}
.mono-chips li:hover,
.mono-chips li.is-lit {
  border-color: rgba(91,155,255,.6);
  box-shadow: 0 0 22px -6px rgba(43,123,255,.6);
  transform: translateY(-2px);
}
.mono-chips--flow { max-width: none; }

.cs-hero { padding-bottom: 110px; }
.cs-hero__layout {
  display: grid;
  grid-template-columns: minmax(0, 700px) 280px;
  justify-content: space-between;
  align-items: start;
  gap: 40px;
  padding-right: 25px;
}
.cs-hero__title { line-height: 1.3; }
.cs-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 500px;
  margin-top: 24px;
}
.cs-tags li {
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid #3a3a3e;
  background: rgba(0,0,0,.5);
  font-size: 12.5px;
  font-weight: 500;
}
.cs-about {
  position: relative;
  margin-top: -7px;
  border-radius: 12px;
  background: #09090a;
}
.cs-about .code-window__bar { height: 32px; border-bottom: 1px solid #222225; padding-right: 110px; }
.cs-about__logo {
  position: absolute;
  top: -1px;
  right: -1px;
  display: grid;
  place-items: center;
  width: 103px;
  height: 69px;
  border: 1px solid #2a2a2e;
  border-radius: 0 12px 0 12px;
  background: #09090a;
}
.cs-about__logo .logo-chip { height: 40px; max-width: 110px; }

/* client logo as a white silhouette, the same treatment as the home page logo marquee */
.logo-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 34px;
  max-width: 132px;
  flex-shrink: 0;
}
.logo-chip img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: .9;
}
/* the Prospect JM file carries extra artwork on the right; show only the logo, as the marquee does */
.logo-chip--prospect img { height: 100%; aspect-ratio: 570 / 238; object-fit: cover; object-position: left center; }
.cs-about__list { padding: 44px 15px 16px; font-family: var(--font-mono); font-size: 11px; }
.cs-about__list div + div { margin-top: 10px; }
.cs-about__list dt { color: #a1a1a7; }
.cs-about__list dd { margin-top: 4px; color: #fff; }

.cs-overview { padding-top: 110px; }
.cs-overview__layout {
  display: grid;
  grid-template-columns: minmax(0, 590px) 459px;
  justify-content: space-between;
  gap: 48px;
}
.cs-overview__text .section__title { font-size: 32px; }
.cs-overview__text p { margin-top: 22px; font-size: 16px; line-height: 1.38; color: #a1a1a7; }
.cs-overview__text .section__title + p { margin-top: 20px; }
.cs-overview__aside { padding-top: 0; align-self: start; }
.cs-overview__visual {
  display: grid;
  place-items: center;
  height: 326px;
  border-radius: 20px;
  background:
    radial-gradient(80% 60% at 100% 100%, #3a6dff 0%, transparent 60%),
    linear-gradient(160deg, #0a2bc0 0%, #0d3be0 45%, #2357ff 100%);
  overflow: hidden;
}
.cs-overview__visual .device { transform: scale(1.18); }
.cs-overview__visual:hover .device { transform: scale(1.23); }
/* finished mockup image: the box takes the image's proportions, so nothing is cropped at any width */
.cs-overview__visual--shot {
  display: block;
  height: auto;
  aspect-ratio: 1376 / 978;
  border: 1px solid #222227;
  background: #0b0b0d;
}
.cs-overview__visual--shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s var(--ease);
}
.cs-overview__visual--shot:hover img { transform: scale(1.035); }
.page-portfolio .cs-overview__visual.cs-overview__visual--shot { height: auto; } /* beats the fixed device heights in the breakpoints */
.cs-quote {
  margin-top: 11px;
  padding: 18px 24px 20px;
  border-radius: 16px;
  border: 1px solid #262629;
  background: linear-gradient(180deg, #0f0f12, #0b0b0c);
  font-size: 16px;
  line-height: 1.38;
}

.cs-challenge { padding-top: 219px; }
.cs-challenge .section__head { margin-bottom: 26px; }
.cs-challenge .section__subtitle { margin-top: 20px; }
.cs-challenge__notes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 120px;
  margin-top: 60px;
  padding-inline: 16px;
}
.cs-challenge__notes p { max-width: 460px; font-size: 16px; line-height: 1.38; color: #a1a1a7; }
.cs-challenge__notes p:last-child { justify-self: end; text-align: right; }

.cs-approach { padding-top: 170px; }
.cs-approach .section__head { margin-bottom: 33px; }
.cs-approach__title { margin-top: 20px; font-size: clamp(24px, 2.6vw, 34px); }
.cs-underline {
  text-decoration: underline;
  text-decoration-color: var(--c-primary);
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}
.cs-approach .section__subtitle { line-height: 1.38; }
.cs-stats {
  position: relative;
  display: flex;
  justify-content: center;
  gap: 24px;
}
.cs-stat {
  position: relative;
  width: 226px;
  height: 210px;
  padding: 44px 36px 0;
  border-radius: 16px 16px 0 0;
  background: linear-gradient(180deg, #151517 0%, rgba(13,13,15,.6) 60%, transparent 100%);
}
.cs-stat::before {
  content: "";
  position: absolute;
  top: -2px;
  left: 50%;
  width: 70px;
  height: 3px;
  margin-left: -45px;
  border-radius: 3px;
  background: linear-gradient(90deg, transparent, #1f6bff 60%, #5b9bff);
  box-shadow: 0 0 10px rgba(43,123,255,.7);
}
.cs-stat:nth-child(2)::before { margin-left: -10px; }
.cs-stat__value {
  display: block;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 62px;
  line-height: 1;
  letter-spacing: -0.02em;
  background: linear-gradient(180deg, #c4c4c6, #8a8a8e);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}
.cs-stat__label { display: block; margin-top: 22px; font-size: 13px; font-weight: 600; }
.cs-note {
  position: relative;
  max-width: 800px;
  margin: -26px auto 0;
  padding: 22px 23px 24px;
  border-radius: 16px;
  border: 1px solid #2a2a2e;
  background:
    radial-gradient(circle, rgba(255,255,255,.12) 1px, transparent 1.4px) 0 0 / 20px 20px,
    linear-gradient(180deg, rgba(15,15,17,.92), rgba(10,10,11,.96));
}
.cs-note p { font-size: 16px; line-height: 1.38; color: #a1a1a7; }

.cs-solution { padding-top: 136px; }
.cs-solution__title {
  margin-top: 22px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: clamp(24px, 2.6vw, 34px);
  line-height: 1.2;
}
.cs-solution__lead { margin-top: 20px; font-size: 16px; line-height: 1.38; color: #a1a1a7; }

.cs-modules {
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 49px;
  margin-top: 18px;
  margin-left: -2px;
}
.cs-modules__tabs { position: relative; align-self: start; padding: 0; }
.cs-modules__tabs::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: #2a2a2e;
}
.cs-modules__tab {
  position: relative;
  display: block;
  width: 100%;
  min-height: 63px;
  padding: 18px 20px 18px 32px;
  border-radius: 16px;
  border: 1px solid transparent;
  text-align: left;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.28;
  color: #6a6a70;
  transition: color .25s, background-color .25s, border-color .25s;
}
.cs-modules__tab:hover { color: #b5b5ba; }
.cs-modules__tab[aria-selected="true"] {
  margin-block: 6px;
  padding-block: 22px;
  border-color: #2a2a2e;
  color: #fff;
  background:
    radial-gradient(circle, rgba(255,255,255,.12) 1px, transparent 1.4px) 0 0 / 20px 20px,
    #0b0b0c;
}
.cs-modules__tab[aria-selected="true"]::before {
  content: "";
  position: absolute;
  left: -1px; top: 12px; bottom: 12px;
  width: 2px;
  border-radius: 2px;
  background: var(--c-primary-light);
  box-shadow: 0 0 10px rgba(43,123,255,.8);
}

.cs-modules__panel {
  padding: 12px 12px 24px;
  border-radius: 28px;
  border: 1px solid #262629;
  background: #0a0a0b;
}
.cs-modules__screen {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-flow: dense;
  align-content: start;
  gap: 32px 33px;
  height: 418px;
  padding: 62px 60px 0;
  border-radius: 20px;
  border: 1px solid #1d1d20;
  background:
    radial-gradient(circle, rgba(255,255,255,.1) 1px, transparent 1.4px) 0 0 / 20px 20px,
    #0f0f10;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(180deg, #000 82%, transparent 100%);
          mask-image: linear-gradient(180deg, #000 82%, transparent 100%);
  transition: opacity .3s var(--ease);
}
.cs-modules__panel.is-switching .cs-modules__screen,
.cs-modules__panel.is-switching .cs-modules__caption { opacity: 0; }
.cs-shot { min-width: 0; }
.cs-shot--tall { grid-row: span 2; }
.cs-shot--wide { grid-column: 1 / -1; }
.cs-shot__label {
  display: block;
  margin-bottom: 8px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  color: #b5b5ba;
}
.cs-shot.is-highlight .cs-shot__label { color: #2b8bff; }
.cs-shot img {
  width: 100%;
  border-radius: 4px;
  background: #fff;
  transition: transform .4s var(--ease);
}
.cs-shot.is-highlight img { outline: 2px solid #1f7bff; outline-offset: 1px; }
.cs-shot img:hover { transform: scale(1.02); }
.cs-shot--phone img { width: 46%; margin-inline: auto; border-radius: 12px; }
.cs-visual-note {
  max-width: 760px;
  margin: 32px auto 0;
  padding-left: 12px;
  border-left: 2px solid #262629;
  font-size: 12px;
  font-style: italic;
  line-height: 1.5;
  color: #6e6e74;
}
/* /portfolio listing */
.pf-hero__lead { max-width: 620px; margin-top: 18px; font-size: 16px; line-height: 1.5; color: #a1a1a7; }
.pf-list { padding-top: 0; }
.pf-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.pf-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #222225;
  border-radius: 20px;
  background: #111113;
  color: inherit;
  transition: border-color .3s, box-shadow .3s, transform .3s var(--ease);
}
.pf-card:hover,
.pf-card:focus-visible {
  border-color: rgba(91,155,255,.6);
  box-shadow: 0 0 32px -10px rgba(43,123,255,.6);
  transform: translateY(-4px);
}
.pf-card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: #0b0b0c; }
.pf-card__media img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform .8s var(--ease); }
.pf-card:hover .pf-card__media img { transform: scale(1.04); }
.pf-card__media--shot { aspect-ratio: 1376 / 978; background: #0b0b0d; }
.pf-card__media--shot img { object-position: center; }
.pf-card__body { display: flex; flex: 1; flex-direction: column; padding: 22px; }
.pf-card__meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pf-card__name { margin-top: 16px; font-family: var(--font-mono); font-size: 22px; font-weight: 600; }
.pf-card__tagline { margin-top: 8px; font-size: 14px; line-height: 1.4; color: #a1a1a7; }
.pf-card__cta { margin-top: auto; padding-top: 20px; font-size: 13px; font-weight: 600; color: var(--c-primary-light); }
.pf-empty { color: #a1a1a7; }
@media (max-width: 1024px) { .pf-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .pf-grid { grid-template-columns: 1fr; gap: 16px; } }

.cs-tour__window { margin-top: 40px; overflow: hidden; }
.cs-tour__window .code-window__bar { height: 36px; border-bottom: 1px solid #222225; }
.cs-tour__open {
  margin-left: auto;
  font-size: 12px;
  color: #a1a1a7;
  transition: color .2s;
}
.cs-tour__open:hover { color: #fff; }
.cs-tour__stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0b0b0c;
}
.cs-tour__stage img,
.cs-tour__stage iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.cs-tour__stage img { object-fit: cover; filter: brightness(.6); transition: filter .4s, transform .8s var(--ease); }
.cs-tour__stage:hover img { filter: brightness(.75); transform: scale(1.02); }
.cs-tour__play {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 999px;
  background: rgba(20,20,22,.6);
  backdrop-filter: blur(8px);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  transition: border-color .3s, box-shadow .3s;
}
.cs-tour__play:hover,
.cs-tour__play:focus-visible { border-color: rgba(91,155,255,.8); box-shadow: 0 0 28px -6px rgba(43,123,255,.8); }
@media (max-width: 640px) {
  .cs-tour__stage { aspect-ratio: 3 / 4; }
  .cs-tour__open { display: none; }
}
.cs-modules__caption { padding: 24px 12px 0; transition: opacity .3s var(--ease); }
.cs-modules__caption h3 { font-size: 16px; font-weight: 600; }
.cs-modules__caption p { margin-top: 12px; font-size: 14px; line-height: 1.43; color: #a1a1a7; }

@media (min-width: 1025px) {
  .cs-modules-track.is-pinned { height: calc(100vh + var(--mod-count, 8) * 40vh); }
  /* Heading + tabs + panel form one viewport-high block. The layout is identical pinned or released
     (releasePinOutside), so nothing shifts; only the sticky positioning toggles. */
  .cs-modules-track.is-scrolly .cs-modules-pin {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: safe center;
    padding: 64px 0 24px;
  }
  .cs-modules-track.is-pinned .cs-modules-pin { position: sticky; top: 0; }
  .cs-modules-track.is-scrolly .cs-modules { width: 100%; margin-top: 40px; }
  /* the panel shrinks with the viewport: 330px = header, heading gap, panel chrome and caption */
  .cs-modules-track.is-scrolly .cs-modules__screen {
    height: clamp(200px, calc(100vh - var(--sol-head, 170px) - 330px), 418px);
  }
  .cs-modules-track.is-scrolly .cs-modules__tab {
    min-height: 0;
    padding-block: clamp(9px, 1.5vh, 18px);
    font-size: clamp(15px, 2vh, 18px);
  }
  .cs-modules-track.is-scrolly .cs-modules__tab[aria-selected="true"] {
    margin-block: clamp(2px, .6vh, 6px);
    padding-block: calc(clamp(9px, 1.5vh, 18px) + 4px);
  }

  .cs-modules { position: relative; }
  .cs-modules__line {
    position: absolute;
    z-index: 1;
    overflow: visible;
    pointer-events: none;
  }
  .cs-modules__line path { fill: none; stroke: #2a2a2e; stroke-width: 1; }
  .cs-modules.has-line .cs-modules__tabs::before { display: none; }
  .cs-modules.has-line .cs-modules__tab[aria-selected="true"] {
    border-color: transparent;
    border-radius: 0 16px 16px 0;
  }
  .cs-modules.has-line .cs-modules__tab[aria-selected="true"]::before { display: none; }
}
@media (max-width: 1024px) {
  .cs-modules__line { display: none; }
}

.cs-continuous { padding-top: 96px; }
.cs-continuous .section__head { margin-bottom: 26px; }
.cs-continuous .section__subtitle { margin-top: 20px; }

.cs-ecosystem { padding-top: 160px; overflow-x: clip; }
.cs-ecosystem__layout {
  display: grid;
  grid-template-columns: minmax(0, 495px) 520px;
  justify-content: space-between;
  gap: 40px;
}
.cs-ecosystem__text { padding-top: 74px; }
.cs-ecosystem__text p { margin-top: 22px; font-size: 16px; line-height: 1.38; color: #a1a1a7; }
.cs-ecosystem__text .cs-big-title + p { margin-top: 18px; }

.eco { position: relative; aspect-ratio: 520 / 440; }
.eco__stage {
  position: absolute;
  top: 0; left: 0;
  width: 520px;
  height: 440px;
  transform-origin: top left;
  transform: scale(var(--stage-scale, 1));
}
.eco__dots {
  position: absolute;
  inset: -10px -40px 0 -40px;
  background-image: radial-gradient(circle, rgba(255,255,255,.18) 1px, transparent 1.4px);
  background-size: 20px 20px;
  -webkit-mask-image: radial-gradient(closest-side, #000 50%, transparent 100%);
          mask-image: radial-gradient(closest-side, #000 50%, transparent 100%);
}
.eco__lines { position: absolute; inset: 0; width: 520px; height: 440px; overflow: visible; }
.eco__lines path {
  fill: none;
  stroke: var(--c-node);
  stroke-dasharray: 4 4;
  animation: dash 1.2s linear infinite;
}
.eco__lines path.is-red { stroke: #8c5aa8; }
.eco__port {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: 7px; height: 7px;
  margin: -3.5px 0 0 -3.5px;
  border-radius: 50%;
  background: #8b8bd1;
}
.eco__port--red { background: #ff2d55; box-shadow: 0 0 8px rgba(255,45,85,.7); }
.eco__node {
  position: absolute;
  top: var(--y);
  left: var(--x);
  display: flex;
  align-items: center;
  gap: 10px;
  height: 47px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid #222226;
  background: #141416;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color .3s, box-shadow .3s, transform .3s var(--ease);
}
.eco__node--left { left: auto; right: var(--r); }
.eco__node svg {
  width: 16px; height: 16px;
  flex: none;
  fill: none;
  stroke: #e4e4e2;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.eco__node svg.is-teal { stroke: #3cc8e6; }
.eco__node svg.is-orange { stroke: var(--c-accent-orange); }
.eco__node.is-highlight,
.eco__node.is-lit {
  border-color: #1f4fae;
  background: #0b1430;
  box-shadow: 0 0 20px -6px rgba(43,123,255,.6);
}
.eco__node:hover { transform: translateY(-2px); }

.cs-role { padding-top: 160px; }
.cs-role__layout {
  display: grid;
  grid-template-columns: minmax(0, 400px) minmax(0, 660px);
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}
.cs-role__text .cs-big-title { font-size: clamp(30px, 3vw, 42px); }
.cs-role__text p { margin-top: 20px; font-size: 16px; line-height: 1.38; color: #a1a1a7; }
.cs-role__text .cs-big-title + p { margin-top: 26px; }
.cs-role__text p:last-child { margin-top: 22px; }
.role-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 13px 13px;
}
.role-chips li {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  height: 72px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid #2a2a2e;
  background: #0b0b0c;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  transition: border-color .3s, transform .3s var(--ease);
}
.role-chips li:hover { border-color: #444; transform: translateY(-2px); }
.role-chips span {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 10px;
  font-weight: 500;
}
.role-chips span::before {
  content: "";
  width: 9px; height: 9px;
  border-radius: 50%;
  background: #ff0b0b;
  box-shadow: 0 0 8px rgba(255,11,11,.6);
}

.cs-cta { padding-top: 84px; }
.cs-cta .cta__card { padding-top: 76px; }
.cs-cta .cta__text { margin-top: 26px; max-width: 690px; }
.cs-cta__tagline { margin-top: 20px; font-size: 14px; font-weight: 600; }
.cs-cta .cta__actions { margin-top: 40px; }

@media (max-width: 1100px) {
  .cs-overview__layout { grid-template-columns: 1fr 400px; }
  .cs-modules { grid-template-columns: 260px 1fr; gap: 32px; }
  .cs-modules__tab { font-size: 16px; }
  .eco { margin-right: 0; }
}

@media (max-width: 1024px) {
  .cs-hero__layout { grid-template-columns: 1fr; padding-right: 0; }
  .cs-about { max-width: 320px; margin-top: 0; }
  .cs-overview__layout { grid-template-columns: 1fr; }
  .cs-overview__aside { max-width: 560px; }
  .cs-modules { grid-template-columns: 1fr; }
  .cs-modules__tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: none;
  }
  .cs-modules__tabs::-webkit-scrollbar { display: none; }
  .cs-modules__tabs::before { display: none; }
  .cs-modules__tab,
  .cs-modules__tab[aria-selected="true"] {
    width: auto;
    min-height: 0;
    margin: 0;
    padding: 12px 16px;
    font-size: 14px;
    white-space: nowrap;
    border-color: #222226;
  }
  .cs-modules__tab[aria-selected="true"]::before { display: none; }
  .cs-ecosystem__layout { grid-template-columns: 1fr; }
  .cs-ecosystem__text { padding-top: 0; }
  .eco { max-width: 520px; width: 100%; }
  .cs-role__layout { grid-template-columns: 1fr; }
  .role-chips { justify-content: flex-start; }
}

@media (max-width: 1024px) {
  .cs-overview { padding-top: 40px; }
  .cs-overview__text p { font-size: 15px; }
  .cs-overview__visual { height: 260px; }
  .cs-overview__visual .device { transform: scale(.95); }
  .cs-challenge { padding-top: 90px; }
  .mono-chips li { height: 44px; font-size: 12.5px; padding: 0 13px; }
  .cs-challenge__notes { grid-template-columns: 1fr; gap: 20px; padding: 0; }
  .cs-challenge__notes p:last-child { text-align: left; justify-self: start; }
  .cs-approach { padding-top: 100px; }
  .cs-stats { gap: 12px; }
  .cs-stat { width: 50%; height: 170px; padding: 32px 18px 0; }
  .cs-stat__value { font-size: 40px; }
  .cs-note p, .cs-solution__lead { font-size: 15px; }
  .cs-solution { padding-top: 100px; }
  .cs-modules__panel { border-radius: 20px; }
  .cs-modules__screen { height: 320px; padding: 28px 20px 0; gap: 16px; grid-template-columns: 1fr; }
  .cs-shot--tall { grid-row: auto; }
  .cs-continuous { padding-top: 60px; }
  .cs-ecosystem { padding-top: 100px; }
  .cs-role { padding-top: 100px; }
  .role-chips li { height: 60px; padding: 0 16px; font-size: 12.5px; }
  .cs-cta { padding-top: 100px; }
}

@media (max-width: 1024px) {
  .page-portfolio main > section { padding-bottom: 0; }

  .page-portfolio .cs-hero { min-height: 100vh; min-height: 100svh; padding: 120px 0 90px; text-align: center; }
  .page-portfolio .cs-hero__layout { display: block; }
  .page-portfolio .cs-about { display: none; }
  .page-portfolio .cs-hero__title { max-width: 290px; margin: 18px auto 0; font-size: 28px; line-height: 1.29; }
  .page-portfolio .cs-tags { justify-content: center; gap: 8px; max-width: none; margin-top: 20px; }
  .page-portfolio .cs-tags li { padding: 9px 15px; font-size: 12.5px; }

  .page-portfolio .cs-overview { padding-top: 0; text-align: center; }
  .page-portfolio .cs-overview__layout { gap: 17px; }
  .page-portfolio .cs-overview__text .section__title { font-size: 24px; }
  .page-portfolio .cs-overview__text p { margin-top: 18px; font-size: 14px; line-height: 1.29; }
  .page-portfolio .cs-overview__text .section__title + p { margin-top: 14px; }
  .page-portfolio .cs-overview__aside { max-width: none; }
  .page-portfolio .cs-overview__visual { height: 278px; border-radius: 16px; }
  .page-portfolio .cs-overview__visual .device { transform: scale(1.05); }
  .page-portfolio .cs-quote { margin-top: 10px; padding: 18px 24px 20px; font-size: 16px; text-align: left; }

  .page-portfolio .cs-challenge { padding-top: 57px; }
  .page-portfolio .cs-challenge .section__head { margin-bottom: 15px; }
  .page-portfolio .cs-lead { margin-top: 14px; font-size: 14px; line-height: 1.43; }
  .page-portfolio .cs-challenge .section__subtitle { margin-top: 10px; }
  .page-portfolio .mono-chips { gap: 13px 12px; }
  .page-portfolio .mono-chips li { height: 42px; padding: 0 11px; font-size: 12px; border-radius: 10px; }
  .page-portfolio .cs-challenge__notes { gap: 20px; margin-top: 40px; text-align: center; }
  .page-portfolio .cs-challenge__notes p,
  .page-portfolio .cs-challenge__notes p:last-child { max-width: none; justify-self: center; text-align: center; font-size: 14px; line-height: 1.29; }

  .page-portfolio .cs-approach { padding-top: 80px; }
  .page-portfolio .cs-approach .section__head { margin-bottom: 48px; }
  .page-portfolio .cs-approach__title { margin-top: 16px; font-size: 20px; line-height: 1.38; }
  .page-portfolio .cs-underline { text-underline-offset: 5px; text-decoration-thickness: 2px; }
  .page-portfolio .cs-approach .section__subtitle { margin-top: 14px; font-size: 14px; line-height: 1.43; }
  .page-portfolio .cs-stats { gap: 16px; }
  .page-portfolio .cs-stat { width: 150px; height: 140px; padding: 26px 0 0; text-align: center; border-radius: 12px 12px 0 0; }
  .page-portfolio .cs-stat::before { left: auto; right: 70px; width: 56px; margin: 0; }
  .page-portfolio .cs-stat__value { font-size: 40px; }
  .page-portfolio .cs-stat__label { margin-top: 18px; font-size: 11px; }
  .page-portfolio .cs-note { margin-top: -38px; padding: 22px 22px 24px; text-align: center; }
  .page-portfolio .cs-note p { font-size: 14px; line-height: 1.43; }
  .page-portfolio .cs-note p br { display: none; }

  .page-portfolio .cs-solution { padding-top: 72px; text-align: center; }
  .page-portfolio .cs-solution__title { margin-top: 14px; font-size: 24px; line-height: 1.3; }
  .page-portfolio .cs-solution__lead { margin-top: 12px; font-size: 14px; line-height: 1.29; }
  .page-portfolio .cs-modules { display: block; margin: 40px 0 0; text-align: left; }
  .page-portfolio .cs-modules__tabs { display: block; overflow: visible; padding: 0; }
  .page-portfolio .cs-modules__tabs::before { display: block; left: -2px; }
  .page-portfolio .cs-modules__tabs li { position: relative; z-index: 1; }
  .page-portfolio .cs-modules__tabs li:has([aria-selected="true"]) {
    margin-block: 4px;
    padding-bottom: 16px;
    border: 1px solid #2a2a2e;
    border-radius: 16px;
    background:
      radial-gradient(circle, rgba(255,255,255,.12) 1px, transparent 1.4px) 0 0 / 20px 20px,
      #0b0b0c;
  }
  .page-portfolio .cs-modules__tab,
  .page-portfolio .cs-modules__tab[aria-selected="true"] {
    width: 100%;
    min-height: 0;
    margin: 0;
    padding: 18px 8px 18px 30px;
    border: 0;
    background: none;
    font-size: 16px;
    line-height: 1.38;
    white-space: normal;
  }
  .page-portfolio .cs-modules__tab[aria-selected="true"] { padding-bottom: 14px; }
  .page-portfolio .cs-modules__tab[aria-selected="true"]::before { display: none; }
  .page-portfolio .cs-modules__panel { margin: 0 16px 0 24px; padding: 12px 12px 18px; border-radius: 16px; }
  .page-portfolio .cs-modules__screen {
    grid-template-columns: 1fr 1fr;
    height: 186px;
    padding: 24px 12px 0;
    gap: 10px 12px;
    border-radius: 12px;
  }
  .page-portfolio .cs-shot--tall { grid-row: span 2; }
  .page-portfolio .cs-shot__label { margin-bottom: 4px; font-size: 6px; }
  .page-portfolio .cs-shot.is-highlight img { outline-width: 1px; }
  .page-portfolio .cs-modules__caption { padding: 20px 12px 0; }
  .page-portfolio .cs-modules__caption h3 { font-size: 14px; line-height: 1.43; }
  .page-portfolio .cs-modules__caption p { margin-top: 10px; font-size: 13px; line-height: 1.38; }

  .page-portfolio .cs-continuous { padding-top: 89px; }
  .page-portfolio .cs-continuous .section__head { margin-bottom: 20px; }

  .page-portfolio .cs-ecosystem { padding-top: 97px; }
  .page-portfolio .cs-ecosystem__layout { gap: 40px; }
  .page-portfolio .cs-ecosystem__text { text-align: center; }
  .page-portfolio .cs-big-title { font-size: 24px; }
  .page-portfolio .cs-ecosystem__text p { margin-top: 14px; font-size: 14px; line-height: 1.29; }
  .page-portfolio .cs-ecosystem__text .cs-big-title + p { margin-top: 10px; }
  .page-portfolio .eco { margin-inline: auto; }

  .page-portfolio .cs-role { padding-top: 107px; }
  .page-portfolio .cs-role__layout { gap: 40px; }
  .page-portfolio .cs-role__text { text-align: center; }
  .page-portfolio .cs-role__text p { margin-top: 12px; font-size: 14px; line-height: 1.29; }
  .page-portfolio .cs-role__text .cs-big-title + p { margin-top: 12px; }
  .page-portfolio .cs-role__text p:last-child { margin-top: 20px; }
  .page-portfolio .role-chips { justify-content: center; gap: 10px 8px; }
  .page-portfolio .role-chips li { height: 52px; padding: 0 6px; gap: 4px; border-radius: 10px; font-size: 12px; }
  .page-portfolio .role-chips span { gap: 11px; padding-left: 4px; font-size: 9px; }
  .page-portfolio .role-chips span::before { width: 8px; height: 8px; }

  .page-portfolio .cs-cta { padding: 97px 0 49px; }
  .page-portfolio .cs-cta .cta__card { padding: 36px 16px 28px; text-align: left; }
  .page-portfolio .cs-cta .cta__title { font-size: 20px; line-height: 1.4; }
  .page-portfolio .cs-cta .cta__title br { display: none; }
  .page-portfolio .cs-cta .cta__text { margin-top: 16px; font-size: 12.5px; line-height: 1.45; text-align: justify; }
  .page-portfolio .cs-cta .cta__text br { display: none; }
  .page-portfolio .cs-cta__tagline { margin-top: 18px; font-size: 12.5px; color: #c9c9d6; }
  .page-portfolio .cs-cta .cta__actions { margin-top: 36px; }
  .page-portfolio .cs-cta .cta__actions .btn { flex: 0 0 auto; padding: 0 21px; }
}

/* =========================================================
   End-to-end pipeline (case studies with "stage" items)
   ========================================================= */
:is(.pipe-legend li, .pipe-station, .pipe__log li).is-plan { --ph: #a78bfa; }
:is(.pipe-legend li, .pipe-station, .pipe__log li).is-sell { --ph: #60a5fa; }
:is(.pipe-legend li, .pipe-station, .pipe__log li).is-pay { --ph: #fbbf24; }
:is(.pipe-legend li, .pipe-station, .pipe__log li).is-make { --ph: #34d399; }
:is(.pipe-legend li, .pipe-station, .pipe__log li).is-deliver { --ph: #22d3ee; }
:is(.pipe-legend li, .pipe-station, .pipe__log li).is-account { --ph: #f472b6; }

.cs-pipeline { padding-top: 130px; }
.cs-pipeline .section__head { margin-bottom: 26px; }
.pipe-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 22px;
  margin: 0 0 44px;
  padding: 0;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #a1a1a7;
}
.pipe-legend li { display: flex; align-items: center; gap: 8px; }
.pipe-legend li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ph);
  box-shadow: 0 0 10px var(--ph);
}

.pipe__board { position: relative; }
.pipe__track {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}
.pipe__rail { fill: none; stroke: #2a2a31; stroke-width: 2; }
.pipe__flow {
  fill: none;
  stroke: #2f7dff;
  stroke-width: 2;
  stroke-dasharray: 3 13;
  stroke-linecap: round;
  opacity: .55;
  animation: pipe-dash 1.1s linear infinite;
}
@keyframes pipe-dash { to { stroke-dashoffset: -16; } }
.pipe__packets circle { fill: #fff; }
.pipe__packets .pipe__halo { fill: var(--ph, #2f7dff); opacity: .3; }

.pipe__stations {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 70px 52px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.pipe-station {
  grid-column: var(--c4);
  grid-row: var(--r4);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 196px;
  padding: 18px 18px 16px;
  border-radius: 18px;
  border: 1px solid #222227;
  background: #0b0b0c;
  overflow: hidden;
  transition: border-color .45s, box-shadow .45s, transform .45s var(--ease);
}
.pipe-station::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(90% 70% at 0% 0%, color-mix(in srgb, var(--ph) 16%, transparent), transparent 70%);
  opacity: .5;
  transition: opacity .45s;
  pointer-events: none;
}
.pipe-station > * { position: relative; }
.pipe-station__top { display: flex; align-items: center; justify-content: space-between; }
.pipe-station__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--ph) 14%, transparent);
  color: var(--ph);
  transition: background-color .45s, color .45s, box-shadow .45s;
}
.pipe-station__icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.pipe-station__num { font-family: var(--font-mono); font-size: 12px; color: #4f4f57; }
.pipe-station__title { margin-top: 16px; font-size: 16px; line-height: 1.25; font-weight: 700; }
.pipe-station__desc { flex: 1; margin-top: 8px; font-size: 13px; line-height: 1.45; color: #8e8e96; }
.pipe-station__phase {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ph);
}
.pipe-station.is-active {
  border-color: color-mix(in srgb, var(--ph) 65%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--ph) 30%, transparent), 0 18px 50px -12px color-mix(in srgb, var(--ph) 55%, transparent);
  transform: translateY(-4px);
}
.pipe-station.is-active::before { opacity: 1; }
.pipe-station.is-active .pipe-station__icon { background: var(--ph); color: #0a0a0b; box-shadow: 0 0 22px color-mix(in srgb, var(--ph) 70%, transparent); }

.pipe__console { margin-top: 56px; border-radius: 16px; }
.pipe__console .code-window__bar { height: 40px; padding: 0 16px; }
.pipe__live {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: #8e8e96;
}
.pipe__live i { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 8px #22c55e; animation: pipe-blink 1.6s ease-in-out infinite; }
.pipe__live b { color: #fff; font-weight: 600; }
@keyframes pipe-blink { 50% { opacity: .25; } }
.pipe__log {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 212px;
  margin: 0;
  padding: 14px 20px;
  overflow: hidden;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 30px;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 45%);
          mask-image: linear-gradient(180deg, transparent 0, #000 45%);
}
.pipe__log li { display: flex; flex: none; gap: 16px; min-width: 0; white-space: nowrap; color: #d4d4d8; animation: pipe-line .45s var(--ease); }
.pipe__log li > span:last-child { overflow: hidden; text-overflow: ellipsis; }
.pipe__log time { flex: none; color: #55555c; }
.pipe__log .pipe__ph { flex: none; width: 70px; color: var(--ph); }
@keyframes pipe-line { from { opacity: 0; transform: translateY(12px); } }

@media (max-width: 1024px) {
  .pipe__stations { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 56px 40px; }
  .pipe-station { grid-column: var(--c2); grid-row: var(--r2); }
  .cs-stats { flex-wrap: wrap; }
}
@media (max-width: 640px) {
  .cs-pipeline { padding-top: 72px; }
  .pipe-legend { gap: 6px 14px; margin-bottom: 28px; font-size: 10.5px; }
  .pipe__stations { grid-template-columns: 1fr; gap: 30px; }
  .pipe-station { grid-column: auto; grid-row: auto; min-height: 0; padding: 16px; }
  .pipe-station__title { margin-top: 12px; font-size: 15px; }
  .pipe__console { margin-top: 36px; }
  .pipe__live { font-size: 10px; }
  .pipe__log { height: 184px; padding: 10px 14px; font-size: 11px; line-height: 26px; }
  .pipe__log li { gap: 10px; }
  .pipe__log time { display: none; }
  .pipe__log .pipe__ph { width: 58px; }
}

/* =========================================================
   Integrations (case studies with "integration" items)
   ========================================================= */
.cs-integrations { padding-top: 130px; }
.cs-integrations .section__head { margin-bottom: 44px; }
.cs-integrations__layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}
.cs-integrations__layout.is-cards-only { grid-template-columns: 1fr; }
.integ-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.is-cards-only .integ-grid { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.integ-card {
  position: relative;
  padding: 22px 22px 24px;
  border-radius: 20px;
  border: 1px solid #232328;
  background:
    radial-gradient(circle, rgba(255, 255, 255, .05) 1px, transparent 1.4px) 0 0 / 18px 18px,
    #0b0b0c;
  overflow: hidden;
  transition: border-color .3s, transform .3s var(--ease);
}
.integ-card:hover { border-color: #3a3a44; transform: translateY(-3px); }
.integ-card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.integ-card__icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(47, 125, 255, .12);
  color: #5b9dff;
}
.integ-card__icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.integ-card__cat { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: #8e8e96; text-align: right; }
.integ-card h3 { margin-top: 18px; font-size: 17px; line-height: 1.25; font-weight: 700; }
.integ-card p { margin-top: 8px; font-size: 13.5px; line-height: 1.45; color: #9a9aa2; }
/* a signal sweeping along the top edge, staggered per card */
.integ-card__pulse {
  position: absolute;
  top: 0;
  left: -40%;
  width: 40%;
  height: 1px;
  background: linear-gradient(90deg, transparent, #4d8fff, transparent);
  animation: integ-sweep 4s linear infinite;
}
.integ-card:nth-child(2) .integ-card__pulse { animation-delay: 1s; }
.integ-card:nth-child(3) .integ-card__pulse { animation-delay: 2s; }
.integ-card:nth-child(4) .integ-card__pulse { animation-delay: 3s; }
@keyframes integ-sweep { to { left: 100%; } }

.integ-code { display: flex; flex-direction: column; border-radius: 20px; }
.integ-code .code-window__bar { height: 40px; padding: 0 16px; }
.integ-code__body {
  flex: 1;
  margin: 0;
  padding: 20px 22px 24px;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
  color: #d4d4d8;
  white-space: pre;
}
.tok-method { color: #22c55e; font-weight: 700; }
.tok-path { color: #fff; }
.tok-header { color: #8e8e96; }
.tok-key { color: #7dd3fc; }
.tok-str { color: #a5d6a7; }
.tok-num { color: #fbbf24; }
.tok-status { color: #22c55e; }
.tok-var { color: #c084fc; }

@media (max-width: 1024px) {
  .cs-integrations__layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cs-integrations { padding-top: 72px; }
  .cs-integrations .section__head { margin-bottom: 28px; }
  .integ-grid { grid-template-columns: 1fr; gap: 12px; }
  .integ-card { padding: 18px; border-radius: 16px; }
  .integ-code__body { padding: 16px; font-size: 11px; }
}

/* =========================================================
   Module screenshots open in a gallery
   ========================================================= */
.cs-shot img { cursor: zoom-in; }
.cs-shots-more {
  margin-top: 12px;
  padding: 0;
  border: 0;
  background: none;
  font-family: var(--font-mono);
  font-size: 12px;
  color: #5b9dff;
  cursor: pointer;
}
.cs-shots-more:hover { color: #8db8ff; }
.shots-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) 72px;
  align-items: center;
  background: rgba(4, 4, 5, .94);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .25s;
}
.shots-lightbox[hidden] { display: none; }
.shots-lightbox.is-open { opacity: 1; }
.shots-lightbox__figure {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  margin: 0;
  padding: 64px 0 28px;
}
.shots-lightbox__figure img {
  max-width: 100%;
  max-height: calc(100vh - 150px);
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
}
.shots-lightbox__figure figcaption { display: flex; gap: 16px; font-size: 13px; color: #a1a1a7; }
.shots-lightbox__count { font-family: var(--font-mono); color: #fff; }
.shots-lightbox button {
  justify-self: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid #2a2a30;
  background: #111114;
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: border-color .2s, background-color .2s;
}
.shots-lightbox button:hover { border-color: #4d8fff; background: #16161b; }
.shots-lightbox__prev { grid-column: 1; grid-row: 1; }
.shots-lightbox__next { grid-column: 3; grid-row: 1; }
.shots-lightbox__close { position: absolute; top: 16px; right: 16px; }
@media (max-width: 640px) {
  .shots-lightbox { grid-template-columns: 1fr; }
  .shots-lightbox__figure { grid-column: 1; padding: 64px 12px 88px; }
  .shots-lightbox__prev,
  .shots-lightbox__next { position: absolute; bottom: 24px; }
  .shots-lightbox__prev { left: calc(50% - 58px); }
  .shots-lightbox__next { left: calc(50% + 12px); }
}
