/* ==========================================================================
   SPB-KATALOG V5 — Chat-Style AI Order Pet («Котик SPb») Above Jivo Icon
   Bottom-right floating chat bubble above Jivo · Messenger popover UI
   Native Figma v5 tokens · Self-hosted Onest font · Desktop 1920 & Mobile 390
   ========================================================================== */

/* Lock page scroll on mobile only when chat sheet is open; desktop stays browsable */
@media (max-width: 640px) {
  html.v5-pet-open,
  html.v5-pet-open body {
    overflow: hidden !important;
  }
}

/* Hide JivoSite widget while AI Order Chat window is open so it never overlaps */
html.v5-pet-open jdiv,
html.v5-pet-open #jcont,
html.v5-pet-open #jivo_action,
html.v5-pet-open #jivo-iframe-container,
html.v5-pet-open [id*="jivo"],
html.v5-pet-open .b24-widget-button-wrapper {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* Hide pet chat button when site drawers/modals or AI chat window itself are open */
html.v5-cdrawer-open .v5-pet-dock,
html.v5-modal-open .v5-pet-dock,
html.v5-pet-open .v5-pet-dock,
body.v5-drawer-open .v5-pet-dock {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transform: translate3d(0, 12px, 0) scale(0.9) !important;
}

@media print {
  .v5-pet-dock,
  .v5-pet-modal {
    display: none !important;
  }
}

/* ==========================================================================
   1. BOTTOM-RIGHT CHAT-STYLE PET LAUNCHER (DIRECTLY ABOVE JIVO ICON)
   ========================================================================== */
.v5-pet-dock {
  position: fixed !important;
  right: 22px !important;
  bottom: 96px !important;
  left: auto !important;
  z-index: 1180 !important;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  font-family: 'Onest', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease, bottom 0.24s ease;
  will-change: transform, opacity;
  pointer-events: none;
}

/* Incoming speech-bubble callout to the left of the pet chat icon */
.v5-pet-callout {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px 9px 13px;
  border-radius: 16px 16px 4px 16px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(35, 85, 223, 0.16);
  box-shadow: 0 8px 24px rgba(17, 19, 23, 0.13), 0 2px 6px rgba(35, 85, 223, 0.08);
  color: #111317;
  pointer-events: auto;
  transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.v5-pet-callout::after {
  content: '';
  position: absolute;
  right: -6px;
  bottom: 11px;
  width: 11px;
  height: 11px;
  background: #ffffff;
  border-right: 1px solid rgba(35, 85, 223, 0.16);
  border-bottom: 1px solid rgba(35, 85, 223, 0.16);
  transform: rotate(-45deg);
  border-radius: 0 0 2px 0;
}

.v5-pet-callout:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(17, 19, 23, 0.16), 0 3px 10px rgba(35, 85, 223, 0.14);
}

.v5-pet-callout__btn {
  display: flex;
  flex-direction: column;
  gap: 1px;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
}

.v5-pet-callout__title {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  color: #111317;
  white-space: nowrap;
}

.v5-pet-callout__sub {
  font-size: 11px;
  font-weight: 500;
  line-height: 1.2;
  color: #555c6b;
  white-space: nowrap;
}

.v5-pet-callout__close {
  position: relative;
  z-index: 1;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 0;
  background: #f1f3f8;
  color: #555c6b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.v5-pet-callout__close:hover {
  background: #e2e6f0;
  color: #111317;
}

.v5-pet-dock.is-compact .v5-pet-callout {
  display: none !important;
}

/* Circular chat-bubble Pet FAB */
.v5-pet-launcher {
  position: relative;
  width: 58px;
  height: 58px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 50% 50% 8px 50%;
  background: linear-gradient(145deg, #2355df 0%, #3b78f2 72%, #5c92ff 100%);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: auto;
  box-shadow: 0 10px 26px rgba(35, 85, 223, 0.36), 0 3px 10px rgba(17, 19, 23, 0.16);
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.2s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.v5-pet-launcher::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50% 50% 10px 50%;
  border: 2px solid rgba(35, 85, 223, 0.24);
  animation: v5PetPulseRing 3.4s ease-out infinite;
  pointer-events: none;
}

.v5-pet-launcher:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 14px 32px rgba(35, 85, 223, 0.44), 0 4px 12px rgba(17, 19, 23, 0.18);
}

.v5-pet-launcher:active {
  transform: scale(0.96);
}

.v5-pet-launcher:focus-visible {
  box-shadow: 0 0 0 4px rgba(35, 85, 223, 0.32), 0 10px 26px rgba(35, 85, 223, 0.36);
}

@keyframes v5PetPulseRing {
  0% { opacity: 0.65; transform: scale(1); }
  70% { opacity: 0; transform: scale(1.18); }
  100% { opacity: 0; transform: scale(1.18); }
}

.v5-pet-avatar-wrap {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.v5-pet-avatar-wrap--head {
  width: 42px;
  height: 42px;
  background: rgba(255, 255, 255, 0.18);
  border: 1.5px solid rgba(255, 255, 255, 0.42);
}

.v5-pet-avatar-wrap--mini {
  width: 28px;
  height: 28px;
  border-radius: 50% 50% 50% 6px;
  background: linear-gradient(145deg, #2355df 0%, #3b78f2 100%);
  box-shadow: 0 2px 6px rgba(35, 85, 223, 0.22);
  margin-top: 2px;
}

.v5-pet-online-dot {
  position: absolute;
  right: 1px;
  top: 1px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #22c55e;
  border: 2px solid #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
}

.v5-pet-avatar-wrap--head .v5-pet-online-dot {
  right: -1px;
  bottom: 0;
  top: auto;
  border-color: #275ce3;
}

.v5-pet-launcher__badge {
  position: absolute;
  top: -5px;
  left: -5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 21px;
  height: 21px;
  padding: 0 6px;
  border-radius: 999px;
  background: #111317;
  color: #ffffff;
  border: 2px solid #ffffff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(17, 19, 23, 0.24);
}

.v5-pet-launcher__badge.is-empty {
  display: none;
}

/* ==========================================================================
   2. ANIMATED SVG PET («Котик SPb»)
   ========================================================================== */
.v5-pet-svg {
  width: 40px;
  height: 40px;
  display: block;
  overflow: visible;
}

.v5-pet-avatar-wrap--head .v5-pet-svg {
  width: 34px;
  height: 34px;
}

.v5-pet-avatar-wrap--mini .v5-pet-svg {
  width: 22px;
  height: 22px;
}

.v5-pet-svg__head {
  transform-origin: 24px 26px;
  animation: v5PetBreathe 3.6s ease-in-out infinite;
}

.v5-pet-svg__ear-l {
  transform-origin: 14px 15px;
  transition: transform 0.2s ease;
}

.v5-pet-svg__ear-r {
  transform-origin: 34px 15px;
  transition: transform 0.2s ease;
}

.v5-pet-launcher:hover .v5-pet-svg__ear-l {
  transform: rotate(-8deg);
}

.v5-pet-launcher:hover .v5-pet-svg__ear-r {
  transform: rotate(8deg);
}

.v5-pet-svg__eyes {
  transform-origin: 24px 24px;
  animation: v5PetBlink 4.8s ease-in-out infinite;
}

.v5-pet-svg__happy-eyes,
.v5-pet-svg__sparkles {
  opacity: 0;
  transition: opacity 0.2s ease;
}

.v5-pet-svg[data-mood="happy"] .v5-pet-svg__eyes,
.v5-pet-svg[data-mood="celebrate"] .v5-pet-svg__eyes {
  opacity: 0;
}

.v5-pet-svg[data-mood="happy"] .v5-pet-svg__happy-eyes,
.v5-pet-svg[data-mood="celebrate"] .v5-pet-svg__happy-eyes {
  opacity: 1;
}

.v5-pet-svg[data-mood="celebrate"] .v5-pet-svg__sparkles {
  opacity: 1;
  animation: v5PetSparkle 1.4s ease-in-out infinite;
}

.v5-pet-svg[data-mood="celebrate"] .v5-pet-svg__head {
  animation: v5PetCelebrateBounce 0.9s ease-in-out infinite;
}

.v5-pet-svg[data-mood="thinking"] .v5-pet-svg__head {
  animation: v5PetThinkTilt 1.3s ease-in-out infinite;
}

@keyframes v5PetBreathe {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-1.3px); }
}

@keyframes v5PetBlink {
  0%, 46%, 50%, 100% { transform: scaleY(1); }
  48% { transform: scaleY(0.12); }
}

@keyframes v5PetThinkTilt {
  0%, 100% { transform: rotate(0deg) translateY(0); }
  35% { transform: rotate(-4deg) translateY(-1px); }
  70% { transform: rotate(4deg) translateY(-1px); }
}

@keyframes v5PetCelebrateBounce {
  0%, 100% { transform: translateY(0) scale(1); }
  45% { transform: translateY(-2.6px) scale(1.04); }
}

@keyframes v5PetSparkle {
  0%, 100% { opacity: 0.45; transform: scale(0.92); }
  50% { opacity: 1; transform: scale(1.08); }
}

/* ==========================================================================
   3. MESSENGER CHAT POPOVER WINDOW (BOTTOM-RIGHT FLOATING CHAT STYLE)
   ========================================================================== */
.v5-pet-modal {
  position: fixed !important;
  inset: 0 !important;
  z-index: 2147483646 !important;
  display: flex !important;
  align-items: flex-end !important;
  justify-content: flex-end !important;
  padding: 20px 22px 22px !important;
  pointer-events: none !important;
  visibility: hidden;
  transition: visibility 0s linear 0.24s;
  font-family: 'Onest', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.v5-pet-modal.is-open {
  visibility: visible;
  transition-delay: 0s;
}

/* On desktop keep page browsable behind the floating chat; scrim appears on mobile only */
.v5-pet-modal__backdrop {
  display: none;
}

.v5-pet-sheet {
  position: relative;
  z-index: 1;
  width: 404px;
  max-width: 100%;
  height: min(650px, calc(100dvh - 44px));
  max-height: calc(100vh - 44px);
  background: #ffffff;
  border-radius: 22px;
  border: 1px solid rgba(17, 19, 23, 0.08);
  box-shadow: 0 22px 60px rgba(15, 16, 19, 0.22), 0 4px 18px rgba(35, 85, 223, 0.14);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  pointer-events: none;
  transform: translate3d(0, 22px, 0) scale(0.94);
  opacity: 0;
  transform-origin: bottom right;
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease;
}

.v5-pet-modal.is-open .v5-pet-sheet {
  pointer-events: auto;
  transform: translate3d(0, 0, 0) scale(1);
  opacity: 1;
}

/* Messenger Branded Header (Royal Blue Gradient) */
.v5-pet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 14px;
  background: linear-gradient(135deg, #2355df 0%, #3469eb 100%);
  color: #ffffff;
  flex-shrink: 0;
}

.v5-pet-head__id {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.v5-pet-head__meta {
  min-width: 0;
}

.v5-pet-head__title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.22;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 6px;
}

.v5-pet-head__tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.v5-pet-head__status {
  margin: 2px 0 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.86);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.v5-pet-head__actions {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.v5-pet-icon-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.15s ease;
  padding: 0;
}

.v5-pet-icon-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: scale(1.05);
}

/* Compact 5-Step Checkout Progress Bar */
.v5-pet-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  padding: 7px 12px;
  background: #ffffff;
  border-bottom: 1px solid #e6ebf4;
  flex-shrink: 0;
}

.v5-pet-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  background: transparent;
  border: 0;
  padding: 2px 0;
  cursor: pointer;
  color: #6b7280;
  font-family: inherit;
}

.v5-pet-step:disabled {
  cursor: default;
  opacity: 0.55;
}

.v5-pet-step__bar {
  width: 100%;
  height: 3.5px;
  border-radius: 999px;
  background: #e2e7f0;
  transition: background-color 0.2s ease;
}

.v5-pet-step.is-active .v5-pet-step__bar {
  background: #2355df;
}

.v5-pet-step.is-done .v5-pet-step__bar {
  background: #0d6b32;
}

.v5-pet-step__lbl {
  font-size: 10px;
  font-weight: 600;
  line-height: 1.1;
  white-space: nowrap;
}

.v5-pet-step.is-active .v5-pet-step__lbl {
  color: #2355df;
}

.v5-pet-step.is-done .v5-pet-step__lbl {
  color: #0d6b32;
}

/* Live Order Cart Strip */
.v5-pet-cartbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 12px;
  background: #eef3ff;
  border-bottom: 1px solid #dce5ff;
  font-size: 12px;
  color: #111317;
  flex-shrink: 0;
}

.v5-pet-cartbar[hidden] {
  display: none !important;
}

.v5-pet-cartbar__info {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.v5-pet-cartbar__sum {
  font-weight: 700;
  color: #2355df;
}

.v5-pet-cartbar__btn {
  border: 0;
  background: #ffffff;
  color: #2355df;
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 1px 4px rgba(35, 85, 223, 0.12);
}

.v5-pet-cartbar__btn:hover {
  background: #2355df;
  color: #ffffff;
}

/* ==========================================================================
   4. MESSENGER CHAT FEED & DIRECTIONAL SPEECH BUBBLES
   ========================================================================== */
.v5-pet-feed {
  flex: 1 1 auto;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 13px 12px 12px;
  background: #eef2f8;
  background-image: radial-gradient(rgba(35, 85, 223, 0.05) 1px, transparent 1px);
  background-size: 18px 18px;
  display: flex;
  flex-direction: column;
  gap: 11px;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.v5-pet-msg {
  display: flex;
  flex-direction: column;
  gap: 7px;
  max-width: 100%;
}

.v5-pet-msg--user {
  align-items: flex-end;
}

.v5-pet-msg--assistant {
  align-items: flex-start;
}

.v5-pet-msg__row {
  display: flex;
  align-items: flex-end;
  gap: 7px;
  max-width: 100%;
}

.v5-pet-msg--user .v5-pet-msg__row {
  justify-content: flex-end;
}

.v5-pet-bubble {
  max-width: 84%;
  padding: 9px 13px 7px;
  font-size: 13.5px;
  line-height: 1.44;
  white-space: pre-line;
  word-break: break-word;
  position: relative;
}

.v5-pet-msg--user .v5-pet-bubble {
  background: linear-gradient(135deg, #2355df 0%, #3469eb 100%);
  color: #ffffff;
  border-radius: 18px 18px 4px 18px;
  box-shadow: 0 3px 12px rgba(35, 85, 223, 0.22);
}

.v5-pet-msg--assistant .v5-pet-bubble {
  background: #ffffff;
  color: #111317;
  border-radius: 18px 18px 18px 4px;
  border: 1px solid rgba(17, 19, 23, 0.06);
  box-shadow: 0 2px 8px rgba(17, 19, 23, 0.05);
}

.v5-pet-bubble__meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 3px;
  font-size: 10px;
  line-height: 1;
  opacity: 0.65;
}

.v5-pet-msg--assistant .v5-pet-bubble__meta {
  color: #6b7280;
  opacity: 0.85;
}

.v5-pet-msg--user .v5-pet-bubble__meta {
  color: rgba(255, 255, 255, 0.82);
  opacity: 1;
}

/* Messenger typing bubble */
.v5-pet-typing {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 11px 14px;
  border-radius: 18px 18px 18px 4px;
  background: #ffffff;
  border: 1px solid rgba(17, 19, 23, 0.06);
  box-shadow: 0 2px 8px rgba(17, 19, 23, 0.05);
}

.v5-pet-typing span {
  width: 6.5px;
  height: 6.5px;
  border-radius: 50%;
  background: #3b78f2;
  animation: v5PetDot 1.1s ease-in-out infinite;
}

.v5-pet-typing span:nth-child(2) { animation-delay: 0.16s; }
.v5-pet-typing span:nth-child(3) { animation-delay: 0.32s; }

@keyframes v5PetDot {
  0%, 80%, 100% { opacity: 0.32; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-3px); }
}

/* ==========================================================================
   5. RICH IN-CHAT ORDER CARDS
   ========================================================================== */
.v5-pet-card {
  width: 100%;
  background: #ffffff;
  border: 1px solid rgba(17, 19, 23, 0.08);
  border-radius: 16px;
  padding: 11px;
  box-shadow: 0 2px 10px rgba(17, 19, 23, 0.05);
}

.v5-pet-card__title {
  margin: 0 0 8px;
  font-size: 12.5px;
  font-weight: 700;
  color: #111317;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.v5-pet-prods {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.v5-pet-prod {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 7px;
  border-radius: 12px;
  background: #f6f8fc;
  border: 1px solid #eaeef6;
}

.v5-pet-prod__img {
  width: 50px;
  height: 50px;
  border-radius: 9px;
  background: #ffffff;
  object-fit: contain;
  padding: 3px;
  border: 1px solid #eaeef6;
}

.v5-pet-prod__body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.v5-pet-prod__name {
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  color: #111317;
  text-decoration: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.v5-pet-prod__name:hover {
  color: #2355df;
}

.v5-pet-prod__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-wrap: wrap;
}

.v5-pet-prod__price {
  font-size: 13px;
  font-weight: 700;
  color: #111317;
}

.v5-pet-prod__stock {
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 999px;
}

.v5-pet-prod__stock--in {
  background: #eaf8ef;
  color: #0d6b32;
}

.v5-pet-prod__stock--out {
  background: #feecec;
  color: #b91c1c;
}

.v5-pet-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  padding: 8px 12px;
  cursor: pointer;
  transition: background-color 0.16s ease, color 0.16s ease, border-color 0.16s ease;
  white-space: nowrap;
}

.v5-pet-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.v5-pet-btn--primary {
  background: #2355df;
  color: #ffffff;
}

.v5-pet-btn--primary:hover:not(:disabled) {
  background: #1b45ba;
}

.v5-pet-btn--soft {
  background: #edf2ff;
  color: #2355df;
}

.v5-pet-btn--soft:hover:not(:disabled) {
  background: #2355df;
  color: #ffffff;
}

.v5-pet-btn--ghost {
  background: #f5f6f8;
  color: #2d3139;
  border-color: #e6e8ee;
}

.v5-pet-btn--ghost:hover:not(:disabled) {
  background: #eef0f4;
}

.v5-pet-btn--full {
  width: 100%;
  min-height: 42px;
  font-size: 13.5px;
  padding: 10px 14px;
}

.v5-pet-cart-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 0;
  border-bottom: 1px solid #eef0f4;
}

.v5-pet-cart-item:last-of-type {
  border-bottom: 0;
}

.v5-pet-cart-item__name {
  font-size: 12px;
  font-weight: 600;
  color: #111317;
  line-height: 1.3;
}

.v5-pet-cart-item__price {
  font-size: 11.5px;
  color: #555c6b;
  margin-top: 2px;
}

.v5-pet-stepper {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #f5f6f8;
  border: 1px solid #e6e8ee;
  border-radius: 999px;
  padding: 2px 4px;
  flex-shrink: 0;
}

.v5-pet-stepper button {
  width: 23px;
  height: 23px;
  border: 0;
  border-radius: 50%;
  background: #ffffff;
  color: #111317;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.v5-pet-stepper button:hover {
  background: #2355df;
  color: #ffffff;
}

.v5-pet-stepper span {
  min-width: 16px;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
}

.v5-pet-options {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.v5-pet-opt {
  width: 100%;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 11px;
  border-radius: 12px;
  border: 1.5px solid #e6e8ee;
  background: #ffffff;
  color: #111317;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease;
}

.v5-pet-opt:hover:not(:disabled) {
  border-color: #93b0ff;
  background: #f8faff;
}

.v5-pet-opt.is-selected {
  border-color: #2355df;
  background: #edf2ff;
}

.v5-pet-opt:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.v5-pet-opt__main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.v5-pet-opt__title {
  font-size: 12.5px;
  font-weight: 700;
  color: #111317;
  line-height: 1.25;
}

.v5-pet-opt__sub {
  font-size: 11px;
  color: #555c6b;
  line-height: 1.3;
}

.v5-pet-opt__price {
  font-size: 12.5px;
  font-weight: 700;
  color: #2355df;
  white-space: nowrap;
  flex-shrink: 0;
}

.v5-pet-subform {
  margin-top: 9px;
  padding-top: 9px;
  border-top: 1px solid #eef0f4;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.v5-pet-field {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.v5-pet-field label {
  font-size: 11px;
  font-weight: 600;
  color: #2d3139;
}

.v5-pet-input {
  width: 100%;
  min-height: 36px;
  padding: 7px 10px;
  border-radius: 10px;
  border: 1px solid #d7dce6;
  background: #ffffff;
  color: #111317;
  font-family: inherit;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.v5-pet-input:focus {
  border-color: #2355df;
  box-shadow: 0 0 0 3px rgba(35, 85, 223, 0.14);
}

.v5-pet-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.v5-pet-chip {
  border: 1px solid #dce2ef;
  background: #f8f9fc;
  color: #2d3139;
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  padding: 5px 9px;
  border-radius: 999px;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.v5-pet-chip:hover {
  border-color: #2355df;
  color: #2355df;
}

.v5-pet-chip.is-selected {
  background: #2355df;
  border-color: #2355df;
  color: #ffffff;
}

.v5-pet-hint {
  font-size: 11px;
  color: #0d6b32;
  background: #eaf8ef;
  padding: 6px 9px;
  border-radius: 10px;
  line-height: 1.35;
}

.v5-pet-receipt {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
}

.v5-pet-receipt__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  color: #2d3139;
}

.v5-pet-receipt__row strong {
  color: #111317;
  text-align: right;
}

.v5-pet-receipt__total {
  margin-top: 4px;
  padding-top: 7px;
  border-top: 1px dashed #d7dce6;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 14px;
  font-weight: 700;
  color: #111317;
}

.v5-pet-receipt__total strong {
  color: #2355df;
  font-size: 16px;
}

.v5-pet-check {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 11.5px;
  line-height: 1.4;
  color: #2d3139;
  cursor: pointer;
  padding: 5px 0;
}

.v5-pet-check input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 1px 0 0;
  accent-color: #2355df;
  flex-shrink: 0;
  cursor: pointer;
}

.v5-pet-check a {
  color: #2355df;
  text-decoration: underline;
}

.v5-pet-check.is-error {
  color: #b91c1c;
}

.v5-pet-error {
  padding: 7px 10px;
  border-radius: 10px;
  background: #feecec;
  color: #b91c1c;
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.35;
}

.v5-pet-success {
  border-color: #bfe8cd;
  background: linear-gradient(180deg, #f3fcf6 0%, #ffffff 42%);
}

.v5-pet-success__head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 9px;
}

.v5-pet-success__ico {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #0d6b32;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.v5-pet-success__num {
  margin: 0;
  font-size: 14.5px;
  font-weight: 700;
  color: #0d6b32;
}

.v5-pet-success__sub {
  margin: 2px 0 0;
  font-size: 11.5px;
  color: #2d3139;
}

/* ==========================================================================
   6. QUICK REPLIES & MESSENGER COMPOSER BAR
   ========================================================================== */
.v5-pet-quick {
  display: flex;
  gap: 6px;
  padding: 7px 12px 3px;
  overflow-x: auto;
  background: #ffffff;
  border-top: 1px solid #e6ebf4;
  flex-shrink: 0;
  scrollbar-width: none;
}

.v5-pet-quick::-webkit-scrollbar {
  display: none;
}

.v5-pet-quick:empty {
  display: none;
}

.v5-pet-quick__btn {
  flex: 0 0 auto;
  border: 1px solid #d5e1ff;
  background: #f4f7ff;
  color: #2355df;
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.v5-pet-quick__btn:hover {
  background: #2355df;
  color: #ffffff;
}

.v5-pet-composer {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 8px 10px calc(10px + env(safe-area-inset-bottom, 0px));
  background: #ffffff;
  flex-shrink: 0;
}

.v5-pet-composer__input {
  flex: 1 1 auto;
  min-height: 40px;
  max-height: 108px;
  padding: 9px 14px;
  border-radius: 20px;
  border: 1px solid #dce2ee;
  background: #f4f6fa;
  color: #111317;
  font-family: inherit;
  font-size: 13.5px;
  line-height: 1.35;
  resize: none;
  outline: none;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.v5-pet-composer__input:focus {
  border-color: #2355df;
  background: #ffffff;
}

.v5-pet-composer__send {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 0;
  background: #2355df;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background-color 0.15s ease, transform 0.12s ease;
}

.v5-pet-composer__send:hover:not(:disabled) {
  background: #1b45ba;
  transform: scale(1.05);
}

.v5-pet-composer__send:disabled {
  background: #b7c4eb;
  cursor: not-allowed;
}

/* ==========================================================================
   7. RESPONSIVE ALIGNMENT DIRECTLY ABOVE JIVO ICON (Tablet & Mobile 390px)
   ========================================================================== */
@media (max-width: 1249px) {
  .v5-pet-dock {
    right: 18px !important;
    bottom: calc(148px + env(safe-area-inset-bottom, 0px)) !important;
  }
}

@media (max-width: 1024px) {
  .v5-pet-dock {
    right: 16px !important;
    bottom: calc(150px + env(safe-area-inset-bottom, 0px)) !important;
  }
  .v5-pet-callout {
    display: none !important;
  }
  .v5-pet-launcher {
    width: 52px;
    height: 52px;
  }
  .v5-pet-svg {
    width: 36px;
    height: 36px;
  }
  html body:has(.v5-pdp-mbar.is-visible) .v5-pet-dock {
    bottom: calc(214px + env(safe-area-inset-bottom, 0px)) !important;
  }
  html.v5-cookie-open .v5-pet-dock,
  html body:has(#spb-cookie-banner[style*="flex"]) .v5-pet-dock {
    bottom: calc(258px + env(safe-area-inset-bottom, 0px)) !important;
  }
}

@media (max-width: 640px) {
  .v5-pet-modal {
    padding: 0 !important;
    justify-content: center !important;
  }
  .v5-pet-modal.is-open {
    pointer-events: auto !important;
  }
  .v5-pet-modal__backdrop {
    display: block;
    position: fixed !important;
    inset: 0 !important;
    background: rgba(15, 16, 19, 0.44);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.22s ease;
  }
  .v5-pet-modal.is-open .v5-pet-modal__backdrop {
    opacity: 1;
  }
  .v5-pet-sheet {
    width: 100%;
    height: 92dvh;
    max-height: 92vh;
    border-radius: 22px 22px 0 0;
    border: 0;
    transform-origin: bottom center;
  }
  .v5-pet-bubble {
    max-width: 88%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .v5-pet-launcher::before,
  .v5-pet-svg__head,
  .v5-pet-svg__eyes,
  .v5-pet-svg__sparkles,
  .v5-pet-typing span {
    animation: none !important;
  }
  .v5-pet-dock,
  .v5-pet-sheet,
  .v5-pet-modal__backdrop,
  .v5-pet-launcher,
  .v5-pet-callout {
    transition: none !important;
  }
}
