.paw-checkout {
  position: absolute;
  z-index: 2;
  inset: 0;
  pointer-events: none;
}

.paw-checkout-paw {
  position: absolute;
  top: 64.6%;
  left: 39%;
  width: 67%;
  height: auto;
  transform: translate(-24%, -31%);
  transform-origin: 24% 31%;
  animation: checkout-paw-reach 850ms cubic-bezier(.22,.67,.3,1) both;
}

@keyframes checkout-paw-reach {
  0% { transform: translate(102%, 72%) rotate(-18deg); }
  31% { transform: translate(65%, 26%) rotate(-24deg); }
  61% { transform: translate(34%, -31%) rotate(5deg); }
  82% { transform: translate(2%, -27%) rotate(10deg); }
  100% { transform: translate(-24%, -31%); }
}

.paw-checkout[data-phase="reveal"] .paw-checkout-paw {
  animation: checkout-paw-leave 390ms ease-in both;
}

.paw-checkout:is([data-phase="scan"], [data-phase="unlocked"]) .paw-checkout-paw { visibility: hidden; }

@keyframes checkout-paw-leave {
  from { transform: translate(-24%, -31%) scale(.94); }
  to { transform: translate(95%, 60%) rotate(-16deg); }
}

.paw-checkout-press,
.paw-checkout-paid {
  position: absolute;
  top: 62.15%;
  left: 9.1%;
  width: 60.6%;
  height: 4.93%;
  border-radius: 30px;
  opacity: 0;
}

.paw-checkout-press {
  background: #d1ffeeab;
  box-shadow: 0 0 0 2px #d7fff4, 0 0 12px #96fadf;
}

.paw-checkout[data-phase="tap"] .paw-checkout-press {
  animation: checkout-press 160ms ease-out both;
}

@keyframes checkout-press {
  from { opacity: .88; transform: scale(.96); }
  to { opacity: .26; transform: scale(1); }
}

.paw-checkout-paid {
  display: grid;
  place-items: center;
  border: 1px solid #96c4a9;
  background: linear-gradient(#317557, #184e3c);
  color: #f6fff9;
  font: 700 3.65cqw/1 "Helvetica Neue", Arial, sans-serif;
}

.paw-checkout[data-phase="unlocked"] .paw-checkout-paid { opacity: 1; }

.paw-face-id {
  position: absolute;
  top: 7%;
  left: 50%;
  width: 45%;
  display: grid;
  justify-items: center;
  gap: 2cqw;
  padding: 3cqw 2cqw;
  border: 1px solid #fbffff;
  border-radius: 6cqw;
  background: linear-gradient(#fff, #d7e8f4 55%, #e9f4fc);
  box-shadow: 0 3px 9px #11335357;
  color: #245f9b;
  font: 700 4.6cqw/1.1 "Helvetica Neue", Arial, sans-serif;
  opacity: 0;
  transform: translate(-50%, -12%);
  transition: transform 150ms ease-out, opacity 150ms ease-out, color 120ms ease;
}

.paw-face-id svg { width: 13cqw; height: 13cqw; }
.face-id-unlocked, .face-id-done { display: none; }

.paw-checkout:is([data-phase="scan"], [data-phase="unlocked"]) .paw-face-id {
  opacity: 1;
  transform: translate(-50%, 0);
}

.paw-checkout[data-phase="scan"] .paw-face-id svg { animation: face-id-pulse 720ms ease-in-out both; }
.paw-checkout[data-phase="unlocked"] .paw-face-id { color: #236a50; }
.paw-checkout[data-phase="unlocked"] :is(.face-id-label, .face-id-scanning) { display: none; }
.paw-checkout[data-phase="unlocked"] :is(.face-id-unlocked, .face-id-done) { display: block; }

@keyframes face-id-pulse {
  0%, 100% { opacity: 1; }
  55% { opacity: .5; transform: scale(.92); }
}

.cat-takeover {
  position: fixed;
  z-index: 50;
  inset: 0;
  isolation: isolate;
  width: auto;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
  background: #071b1cd6;
  animation: takeover-dim 2250ms both;
  overflow: hidden;
  pointer-events: none;
}

.cat-takeover-mascot,
.cat-takeover-camera {
  position: absolute;
  display: block;
  max-height: 76svh;
  object-fit: contain;
}

.cat-takeover-mascot {
  left: -4vw;
  top: 5svh;
  width: min(37vw, 570px);
  object-position: left center;
  transform-origin: left center;
  animation: cat-entrance 2250ms both;
}

.cat-takeover-camera {
  right: -4vw;
  top: 24svh;
  width: min(47vw, 680px);
  object-position: right center;
  transform-origin: right center;
  animation: digicam-entrance 2250ms both;
}

@keyframes takeover-dim {
  0% { background: #071b1c00; }
  12%, 86% { background: #071b1cd6; }
  100% { background: #071b1c00; }
}

@keyframes cat-entrance {
  0%, 42% { transform: translate(-115%, 0) rotate(-12deg); }
  56% { transform: translate(5%, 0) rotate(6deg); }
  69% { transform: translate(0, 0) rotate(2deg); }
  85%, 100% { transform: translate(-115%, -8%) rotate(-12deg); }
}

@keyframes digicam-entrance {
  0%, 4% { transform: translate(105%, 15%) rotate(16deg) scale(.92); }
  29% { transform: translate(-3%, 0) rotate(-5deg); }
  37% { transform: translate(-8%, -3%) rotate(-4deg) scale(1.095); }
  47% { transform: translate(9%, 4%) rotate(3deg); }
  63%, 100% { transform: translate(110%, 13%) rotate(11deg) scale(.9); }
}

.cat-takeover-shutter {
  position: absolute;
  inset: 0;
  background: #f4fff9;
  animation: cat-shutter 2250ms linear both;
}

@keyframes cat-shutter {
  0%, 37% { opacity: 0; }
  40% { opacity: .9; }
  46%, 100% { opacity: 0; }
}

.cat-takeover-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 54% 46%;
  background: #1a302c;
  transform-origin: top left;
  animation: cat-photo 2250ms both;
}

@keyframes cat-photo {
  0%, 47% { opacity: 0; transform: translateX(-4%) scale(1.06); }
  54% { opacity: 1; transform: scale(1.025); }
  81% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: translate(-7%, -3%) scale(.97); }
}

.paw-checkout-manual .paw-face-id {
  top: 16%;
  width: 38%;
  font-size: clamp(13px, 4cqw, 18px);
}

.paw-checkout-manual .paw-face-id svg { width: 11cqw; height: 11cqw; }
.paw-checkout-manual .paw-checkout-paid { display: none; }

@media (max-width: 600px) {
  .cat-takeover-mascot { left: -8vw; top: 11svh; width: 65vw; }
  .cat-takeover-camera { right: -8vw; top: 36svh; width: 63vw; }
  .cat-takeover-photo { object-position: 58% 51%; }
}
