.calculator-promo {
  position: relative;
  isolation: isolate;
  container-type: inline-size;
  overflow: hidden;
  margin-top: 80px;
  color: #f6f6f6;
}

.calculator-promo-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: center;
  justify-items: start;
  gap: 2.06cqw;
  aspect-ratio: 1488 / 498;
}

.calculator-promo-copy {
  display: grid;
  justify-items: start;
  gap: 2.06cqw;
  width: 42%;
  max-width: 476px;
}

.case-results .calculator-promo-title {
  font-size: clamp(28px, 3.5cqw, 52px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -.055em;
}

.calculator-promo-description {
  font-size: clamp(15px, 1.35cqw, 20px);
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -.015em;
  color: #bcbcbc;
}

.calculator-promo .calculator-promo-cta {
  position: static;
  background: #f4f4f4;
  border-color: #f4f4f4;
  color: #151515;
  justify-content: space-between;
  width: min(255px, 100%);
  padding: 15px 18px 15px 22px;
  cursor: pointer;
}

.calculator-promo-cta::after {
  position: absolute;
  inset: 0;
  z-index: 2;
  content: "";
}

.calculator-promo .calculator-promo-cta:hover { background: #fff; }
.calculator-promo:has(.calculator-promo-cta:focus-visible) {
  outline: 2px solid #fff;
  outline-offset: 4px;
}

.calculator-promo-art {
  position: absolute;
  top: 4.2%;
  right: 1.61%;
  display: block;
  width: 53.09%;
  max-width: none;
  height: auto;
  pointer-events: none;
}

.case-results-inner {
  container: case-results / inline-size;
}

@container case-results (width > 760px) {
  .calculator-promo { margin-top: clamp(32px, 3.4cqw, 48px); }

  .calculator-promo-content,
  .calculator-promo-copy { gap: clamp(16px, 1.5cqw, 24px); }

  .calculator-promo-content {
    aspect-ratio: auto;
    min-height: 28cqw;
  }

  .calculator-promo-copy {
    width: 46%;
    max-width: 520px;
  }

  .calculator-promo-art {
    top: 50%;
    right: 0;
    width: 46%;
    translate: 0 -50%;
  }
}

@container (max-width: 760px) {
  .calculator-promo-content {
    gap: 16px;
    aspect-ratio: auto;
  }

  .calculator-promo-copy {
    width: auto;
    gap: 16px;
  }

  .case-results .calculator-promo-title { font-size: clamp(27px, 8.72cqw, 38px); }

  .calculator-promo-description { font-size: 16px; }

  .calculator-promo-art {
    position: relative;
    top: auto;
    right: auto;
    left: -9cqw;
    width: 105.33cqw;
    margin-block: -8px -5px;
  }
}

@media (max-width: 760px) {
  .calculator-promo { margin-top: 56px; }
}

.calculator-promo--service {
  display: grid;
  grid-column: 1 / -1;
  container-type: normal;
  align-items: start;
  row-gap: 16px;
  margin-top: 0;
}

.calculator-promo-action {
  display: grid;
  justify-items: start;
  gap: 16px;
}

.calculator-promo--service .calculator-promo-art {
  position: static;
  width: 100%;
  max-width: 460px;
}

.calculator-promo--service[data-promo-motion="closed"] .calculator-promo-art {
  visibility: hidden;
}

@media (min-width: 1200px) {
  .calculator-promo--service {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
    grid-template-columns: subgrid;
    overflow: visible;
  }

  .calculator-promo--service .calculator-promo-title { grid-area: 1 / 1; }
  .calculator-promo--service .calculator-promo-art {
    grid-area: 2 / 1;
    justify-self: end;
    width: 112%;
    max-width: 520px;
    margin-inline-end: 8px;
  }

  .calculator-promo--service .calculator-promo-cta::after { inset-inline-start: calc(-6% - 8px); }
  .calculator-promo-action { grid-area: 1 / 2 / span 2; }
}

@media (prefers-reduced-motion: reduce) {
  #services .service-item--promo :is(.service-panel, .service-detail--promo) { transition: none; }
}

/* The five-second timeline comes from Figma. SVG groups are centred at each motion pivot. */
@property --promo-scale-x { syntax: '<number>'; initial-value: 1; inherits: false; }
@property --promo-scale-y { syntax: '<number>'; initial-value: 1; inherits: false; }
@property --promo-rotate { syntax: '<number>'; initial-value: 0; inherits: false; }
@property --promo-translate-x { syntax: '<number>'; initial-value: 0; inherits: false; }
@property --promo-translate-y { syntax: '<number>'; initial-value: 0; inherits: false; }

.promo-glint, .promo-lid, .promo-audit, .promo-concept {
  transform-origin: 0 0;
  transform: translate(calc(var(--promo-translate-x, 0) * 1px), calc(var(--promo-translate-y, 0) * 1px))
    rotate(calc(var(--promo-rotate, 0) * 1rad)) scale(var(--promo-scale-x, 1), var(--promo-scale-y, 1));
}

@media (prefers-reduced-motion: no-preference) {
  .calculator-promo:is([data-promo-motion="ready"], [data-promo-motion="playing"]) .promo-layer {
    animation: var(--promo-timeline);
  }

  .calculator-promo[data-promo-motion="ready"] .promo-layer { animation-play-state: paused; }

  .promo-lid, .promo-audit, .promo-concept {
    translate: 0px;
    rotate: 0deg;
  }

  .calculator-promo[data-promo-motion="settled"] :is(.promo-lid, .promo-audit, .promo-concept) {
    translate:
      calc(var(--promo-pointer-x, 0) * var(--promo-depth))
      calc(var(--promo-pointer-y, 0) * var(--promo-depth) * .72);
    rotate: calc(var(--promo-pointer-x, 0) * var(--promo-tilt));
    transition: translate 240ms var(--ease), rotate 240ms var(--ease);
  }

  .promo-lid { --promo-depth: 9px; --promo-tilt: -.9deg; }
  .promo-audit { --promo-depth: 12px; --promo-tilt: 1.2deg; }
  .promo-concept { --promo-depth: 16px; --promo-tilt: 1.6deg; }
}

.promo-studio { --promo-timeline: promo-studio-opacity 5s linear both; }
.promo-orbit { --promo-timeline: promo-orbit-opacity 5s linear both; }
.promo-glint { --promo-timeline: promo-glint-scale-x 5s linear both, promo-glint-scale-y 5s linear both, promo-glint-opacity 5s linear both; }
.promo-box { --promo-timeline: promo-box-opacity 5s linear both; }
.promo-ribbons { --promo-timeline: promo-ribbons-opacity 5s linear both; }
.promo-rim-trace { --promo-timeline: promo-rim-trace-opacity 5s linear both, promo-rim-trace-path-trim 5s linear both; }
.promo-shell-trace { --promo-timeline: promo-shell-trace-opacity 5s linear both, promo-shell-trace-path-trim 5s linear both; }
.promo-seam-trace { --promo-timeline: promo-seam-trace-opacity 5s linear both, promo-seam-trace-path-trim 5s linear both; }
.promo-glow { --promo-timeline: promo-glow-opacity 5s linear both; }
.promo-lid { --promo-timeline: promo-lid-rotate 5s linear both, promo-lid-translate-x 5s linear both, promo-lid-translate-y 5s linear both; }
.promo-lid-faces { --promo-timeline: promo-lid-faces-opacity 5s linear both; }
.promo-bow { --promo-timeline: promo-bow-opacity 5s linear both; }
.promo-lid-trace { --promo-timeline: promo-lid-trace-opacity 5s linear both, promo-lid-trace-path-trim 5s linear both; }
.promo-audit { --promo-timeline: promo-audit-rotate 5s linear both, promo-audit-scale-x 5s linear both, promo-audit-scale-y 5s linear both, promo-audit-translate-x 5s linear both, promo-audit-translate-y 5s linear both, promo-audit-opacity 5s linear both; }
.promo-concept { --promo-timeline: promo-concept-rotate 5s linear both, promo-concept-scale-x 5s linear both, promo-concept-scale-y 5s linear both, promo-concept-translate-x 5s linear both, promo-concept-translate-y 5s linear both, promo-concept-opacity 5s linear both; }

@keyframes promo-studio-opacity {
  0% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0.1; }
  18% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0.28; }
  38% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0.86; }
  57.2% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-orbit-opacity {
  0% { opacity: 0; }
  48.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  71% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-glint-scale-x {
  0% { --promo-scale-x: 0.7; }
  70% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-x: 0.7; }
  85% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-x: 1.18; }
  97.2% { --promo-scale-x: 1; }
  100% { --promo-scale-x: 1; }
}

@keyframes promo-glint-scale-y {
  0% { --promo-scale-y: 0.7; }
  70% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-y: 0.7; }
  85% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-y: 1.18; }
  97.2% { --promo-scale-y: 1; }
  100% { --promo-scale-y: 1; }
}

@keyframes promo-glint-opacity {
  0% { opacity: 0; }
  66.4% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  79.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0.42; }
  87% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 1; }
  93.6% { opacity: 0.78; }
  100% { opacity: 0.78; }
}

@keyframes promo-box-opacity {
  0% { opacity: 0; }
  18.4% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  31.8% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-ribbons-opacity {
  0% { opacity: 0; }
  23.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  37.4% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-rim-trace-opacity {
  0% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  1% { opacity: 1; }
  24.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 1; }
  36.8% { opacity: 0.42; }
  100% { opacity: 0.42; }
}

@keyframes promo-rim-trace-path-trim {
  0% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); stroke-dasharray: 0 1; visibility: hidden; }
  14.8% { stroke-dasharray: 1 1; visibility: visible; }
  100% { stroke-dasharray: 1 1; visibility: visible; }
}

@keyframes promo-shell-trace-opacity {
  0% { opacity: 0; }
  1.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  2.8% { opacity: 1; }
  24.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 1; }
  36.8% { opacity: 0.42; }
  100% { opacity: 0.42; }
}

@keyframes promo-shell-trace-path-trim {
  0% { stroke-dasharray: 0 1; visibility: hidden; }
  1.8% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); stroke-dasharray: 0 1; visibility: hidden; }
  19.2% { stroke-dasharray: 1 1; visibility: visible; }
  100% { stroke-dasharray: 1 1; visibility: visible; }
}

@keyframes promo-seam-trace-opacity {
  0% { opacity: 0; }
  6.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  7.2% { opacity: 1; }
  24.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 1; }
  36.8% { opacity: 0.42; }
  100% { opacity: 0.42; }
}

@keyframes promo-seam-trace-path-trim {
  0% { stroke-dasharray: 0 1; visibility: hidden; }
  6.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); stroke-dasharray: 0 1; visibility: hidden; }
  17.2% { stroke-dasharray: 1 1; visibility: visible; }
  100% { stroke-dasharray: 1 1; visibility: visible; }
}

@keyframes promo-glow-opacity {
  0% { opacity: 0; }
  40.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  47.4% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); opacity: 0.23; }
  55.6% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 1; }
  66% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0.84; }
  94% { opacity: 0.93; }
  100% { opacity: 0.93; }
}

@keyframes promo-lid-rotate {
  0% { --promo-rotate: 0.139626; }
  39.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-rotate: 0.139626; }
  44% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-rotate: 0.150098; }
  58.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-rotate: -0.007854; }
  68.6% { --promo-rotate: 0; }
  100% { --promo-rotate: 0; }
}

@keyframes promo-lid-translate-x {
  0% { --promo-translate-x: 13; }
  42.4% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-translate-x: 13; }
  58.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-x: -1.4; }
  67.8% { --promo-translate-x: 0; }
  100% { --promo-translate-x: 0; }
}

@keyframes promo-lid-translate-y {
  0% { --promo-translate-y: 87; }
  39.6% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-y: 87; }
  42.4% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-translate-y: 89; }
  58.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-y: -2.7; }
  67.8% { --promo-translate-y: 0; }
  100% { --promo-translate-y: 0; }
}

@keyframes promo-lid-faces-opacity {
  0% { opacity: 0; }
  19.6% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  33% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-bow-opacity {
  0% { opacity: 0; }
  25.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  39.8% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-lid-trace-opacity {
  0% { opacity: 0; }
  4.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 0; }
  5.8% { opacity: 1; }
  24.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); opacity: 1; }
  36.8% { opacity: 0.42; }
  100% { opacity: 0.42; }
}

@keyframes promo-lid-trace-path-trim {
  0% { stroke-dasharray: 0 1; visibility: hidden; }
  4.8% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); stroke-dasharray: 0 1; visibility: hidden; }
  20.8% { stroke-dasharray: 1 1; visibility: visible; }
  100% { stroke-dasharray: 1 1; visibility: visible; }
}

@keyframes promo-audit-rotate {
  0% { --promo-rotate: 0.226893; }
  60.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-rotate: 0.226893; }
  74.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-rotate: 0.013963; }
  80.8% { --promo-rotate: 0; }
  100% { --promo-rotate: 0; }
}

@keyframes promo-audit-scale-x {
  0% { --promo-scale-x: 0.47; }
  60.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-scale-x: 0.47; }
  70.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-x: 0.97; }
  74.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-x: 1.012; }
  80% { --promo-scale-x: 1; }
  100% { --promo-scale-x: 1; }
}

@keyframes promo-audit-scale-y {
  0% { --promo-scale-y: 0.47; }
  60.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-scale-y: 0.47; }
  70.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-y: 0.97; }
  74.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-y: 1.012; }
  80% { --promo-scale-y: 1; }
  100% { --promo-scale-y: 1; }
}

@keyframes promo-audit-translate-x {
  0% { --promo-translate-x: -286; }
  60.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-translate-x: -286; }
  73.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-x: 3; }
  81% { --promo-translate-x: 0; }
  100% { --promo-translate-x: 0; }
}

@keyframes promo-audit-translate-y {
  0% { --promo-translate-y: 123; }
  60.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-translate-y: 123; }
  73.8% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-y: -2; }
  81% { --promo-translate-y: 0; }
  100% { --promo-translate-y: 0; }
}

@keyframes promo-audit-opacity {
  0% { opacity: 0; }
  60.2% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); opacity: 0; }
  68% { opacity: 1; }
  100% { opacity: 1; }
}

@keyframes promo-concept-rotate {
  0% { --promo-rotate: -0.174533; }
  64.6% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-rotate: -0.174533; }
  78.6% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-rotate: 0.013963; }
  85.2% { --promo-rotate: 0; }
  100% { --promo-rotate: 0; }
}

@keyframes promo-concept-scale-x {
  0% { --promo-scale-x: 0.47; }
  64.6% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-scale-x: 0.47; }
  74.6% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-x: 0.97; }
  79.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-x: 1.012; }
  84.4% { --promo-scale-x: 1; }
  100% { --promo-scale-x: 1; }
}

@keyframes promo-concept-scale-y {
  0% { --promo-scale-y: 0.47; }
  64.6% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-scale-y: 0.47; }
  74.6% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-y: 0.97; }
  79.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-scale-y: 1.012; }
  84.4% { --promo-scale-y: 1; }
  100% { --promo-scale-y: 1; }
}

@keyframes promo-concept-translate-x {
  0% { --promo-translate-x: -307; }
  64.6% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-translate-x: -307; }
  78.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-x: 4; }
  85.4% { --promo-translate-x: 0; }
  100% { --promo-translate-x: 0; }
}

@keyframes promo-concept-translate-y {
  0% { --promo-translate-y: 28; }
  64.6% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); --promo-translate-y: 28; }
  78.2% { animation-timing-function: cubic-bezier(0.45, 0, 0.2, 1); --promo-translate-y: 1; }
  85.4% { --promo-translate-y: 0; }
  100% { --promo-translate-y: 0; }
}

@keyframes promo-concept-opacity {
  0% { opacity: 0; }
  64.6% { animation-timing-function: cubic-bezier(0.22, 0.68, 0, 1); opacity: 0; }
  72.4% { opacity: 1; }
  100% { opacity: 1; }
}
