/* Johnny mascot integration */

/* Generated Johnny paw keeps the existing smooth follower. */
.cursor {
  width: 56px;
  height: 56px;
  border: 0;
  border-radius: 0;
  background: transparent;
  transition: none;
  transform-origin: 8px 8px;
}
.cursor.is-active {
  width: 56px;
  height: 56px;
  border: 0;
  background: transparent;
}
.cursor__paw {
  width: 100%;
  height: 100%;
  display: block;
  transform: scale(1);
  transform-origin: 8px 8px;
  filter: drop-shadow(0 0 5px rgba(255, 45, 45, .55));
  transition: transform .16s var(--ease), filter .16s var(--ease);
}
.cursor.is-active .cursor__paw {
  transform: scale(.82);
  filter: drop-shadow(0 0 9px rgba(255, 45, 45, .9));
}
.cursor.is-onred .cursor__paw {
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, .75));
}

/* Johnny guides the four workflow stages. */
.process--johnny {
  --johnny-progress: 0;
  position: relative;
  isolation: isolate;
  gap: clamp(.7rem, 1.35vw, 1.15rem);
}
.process__cable {
  position: absolute;
  top: 1rem;
  left: calc(var(--pad) + 11%);
  right: calc(var(--pad) + 11%);
  height: 2px;
  z-index: 0;
  background: rgba(246, 244, 239, .2);
}
.process__cable::before {
  content: "";
  position: absolute;
  inset: -4px 0;
  background: repeating-linear-gradient(90deg, transparent 0 10px, rgba(246,244,239,.08) 10px 11px);
}
.process__cable span {
  position: absolute;
  inset: 0 auto 0 0;
  width: calc(var(--johnny-progress) * 100%);
  background: var(--red);
  box-shadow: 0 0 12px rgba(255, 45, 45, .75);
  transition: width .12s linear;
}
.step--johnny {
  position: relative;
  z-index: 1;
  min-width: 0;
  border: 0;
  padding: 0;
  gap: 1.15rem;
  align-content: start;
}
.step__visual {
  position: relative;
  aspect-ratio: 1 / 1;
  margin-top: 1rem;
  overflow: hidden;
  border: 2px solid var(--white);
  background:
    radial-gradient(circle at 72% 24%, rgba(255, 45, 45, .32), transparent 34%),
    linear-gradient(145deg, #f6f4ef 0%, #d8d5cf 100%);
  box-shadow: 7px 7px 0 rgba(255, 45, 45, .16);
}
.step__visual::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background-image:
    linear-gradient(rgba(13,13,14,.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13,13,14,.055) 1px, transparent 1px);
  background-size: 20px 20px;
  mask-image: linear-gradient(to bottom, #000, transparent 72%);
}
.step__visual::after {
  content: "";
  position: absolute;
  z-index: 1;
  width: 54%;
  aspect-ratio: 1;
  right: -18%;
  bottom: -24%;
  background: var(--red);
  transform: rotate(18deg);
  opacity: .9;
}
.step__visual img {
  position: absolute;
  inset: 2%;
  z-index: 2;
  width: 96%;
  height: 96%;
  object-fit: contain;
  object-position: center bottom;
  transition: transform .55s var(--ease), filter .55s var(--ease);
  filter: drop-shadow(0 14px 14px rgba(13, 13, 14, .24));
}
.step--johnny:hover .step__visual img,
.step--johnny.is-current .step__visual img {
  transform: translateY(-2.5%) scale(1.045);
}
.step__copy {
  display: grid;
  gap: .58rem;
  padding-right: .35rem;
}
.step--johnny .step__num {
  font-size: clamp(2rem, 3vw, 3rem);
}
.step__comment {
  position: absolute;
  z-index: 4;
  max-width: 78%;
  padding: .38rem .55rem;
  border-left: 3px solid var(--red);
  background: rgba(13, 13, 14, .92);
  color: var(--white);
  font-family: "Space Mono", "JetBrains Mono", monospace;
  font-size: clamp(.54rem, .7vw, .68rem);
  line-height: 1.2;
  box-shadow: 3px 3px 0 rgba(255, 45, 45, .25);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.step__comment b {
  color: var(--red);
  margin-right: .28rem;
}
.step__comment--one { top: 7%; left: 3%; }
.step__comment--two { right: 3%; bottom: 9%; transition-delay: .11s; }
.step--comments:hover .step__comment,
.step--comments.is-current .step__comment {
  opacity: 1;
  transform: none;
}
.step--delivery.is-current .step__visual {
  box-shadow: 7px 7px 0 rgba(255, 45, 45, .32), 0 0 24px rgba(255, 45, 45, .14);
}

/* A dedicated CTA stage makes Johnny part of the footer hierarchy. */
.footer__johnny {
  position: relative;
  max-width: var(--maxw);
  min-height: clamp(330px, 34vw, 450px);
  margin: 0 auto clamp(3rem, 7vw, 5.5rem);
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, .88fr);
  overflow: hidden;
  border: 2px solid var(--white);
  background:
    linear-gradient(90deg, rgba(255,45,45,.08) 1px, transparent 1px),
    linear-gradient(rgba(255,45,45,.08) 1px, transparent 1px),
    var(--white);
  background-size: 28px 28px;
  color: var(--black);
}
.footer__johnny-copy {
  position: relative;
  z-index: 3;
  align-self: center;
  display: grid;
  justify-items: start;
  gap: 1.2rem;
  padding: clamp(2rem, 5vw, 4.5rem);
}
.footer__johnny-kicker {
  color: var(--red);
  font-family: "Space Mono", "JetBrains Mono", monospace;
  font-size: clamp(.66rem, 1vw, .82rem);
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.footer__johnny h2 {
  max-width: 13ch;
  font-size: clamp(2rem, 4.4vw, 4.4rem);
  font-weight: 900;
  letter-spacing: -.045em;
  line-height: .92;
  text-transform: uppercase;
}
.footer__johnny-btn {
  box-shadow: 5px 5px 0 var(--black);
}
.footer__johnny-figure {
  position: relative;
  min-height: 100%;
}
.footer__johnny-figure::before {
  content: "";
  position: absolute;
  z-index: 0;
  width: min(33vw, 430px);
  aspect-ratio: 1;
  right: -6%;
  top: 50%;
  border-radius: 50%;
  background: var(--red);
  transform: translateY(-50%);
  box-shadow: 0 0 0 18px rgba(255, 45, 45, .13);
}
.footer__johnny-figure img {
  position: absolute;
  z-index: 2;
  right: -1%;
  bottom: -16%;
  width: min(38vw, 500px);
  height: 126%;
  object-fit: contain;
  object-position: right bottom;
  filter: drop-shadow(-16px 18px 18px rgba(13, 13, 14, .3));
  transition: transform .65s var(--ease);
}
.footer__johnny:hover .footer__johnny-figure img {
  transform: translateX(-2.5%);
}

@media (max-width: 980px) {
  .process--johnny {
    grid-template-columns: 1fr;
    gap: 2.4rem;
    padding-left: calc(var(--pad) + 2.6rem);
  }
  .process__cable {
    top: 7%;
    bottom: 7%;
    left: calc(var(--pad) + 1.25rem);
    right: auto;
    width: 2px;
    height: auto;
  }
  .process__cable::before {
    inset: 0 -4px;
    background: repeating-linear-gradient(180deg, transparent 0 10px, rgba(246,244,239,.08) 10px 11px);
  }
  .process__cable span {
    inset: 0 0 auto;
    width: 100%;
    height: calc(var(--johnny-progress) * 100%);
    transition: height .12s linear;
  }
  .step--johnny {
    grid-template-columns: minmax(250px, .8fr) minmax(0, 1.2fr);
    align-items: center;
    gap: clamp(1.5rem, 5vw, 3rem);
  }
  .step__visual { width: 100%; margin-top: 0; }
}

@media (max-width: 700px) {
  .cursor { display: none !important; }
  body, a, button { cursor: auto; }
  .process--johnny {
    padding-left: calc(var(--pad) + 2.25rem);
  }
  .step--johnny {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .step__comment { font-size: .58rem; }
  .footer__johnny {
    min-height: 400px;
    grid-template-columns: minmax(0, 1fr) 42%;
  }
  .footer__johnny-copy {
    padding: 2rem 0 2rem 1.5rem;
  }
  .footer__johnny h2 { font-size: clamp(1.65rem, 8vw, 2.65rem); }
  .footer__johnny-figure::before {
    width: 230px;
    right: -45%;
  }
  .footer__johnny-figure img {
    right: -42%;
    width: 310px;
    height: 104%;
    bottom: -7%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cursor { display: none !important; }
  body, a, button { cursor: auto !important; }
  .process__cable span { transition: none; }
  .step__visual img,
  .step__comment,
  .footer__johnny-figure img { transition: none; }
}
