/* CSS Variables - Simplified (12 variables) */
:root {
  /* Brand color - set dynamically by JS from Shopify metafields */
  --chat-primary: #1f2937;            /* Buttons, CTAs, highlights */
  --chat-primary-rgb: 31, 41, 55;     /* RGB for rgba() - set by JS */

  /* Fixed backgrounds */
  --chat-bg: #ffffff;                 /* Main background: white */
  --chat-bg-muted: #f8fafc;           /* Input, secondary backgrounds */
  --chat-bg-dark: #f3f4f6;            /* Bot bubbles, cards */

  /* Fixed text colors */
  --chat-text: #000000;               /* Main text: black */
  --chat-text-muted: #4b5563;         /* Secondary/muted text */
  --chat-text-light: #94a3b8;         /* Placeholders, timestamps */
  --chat-text-inverse: #ffffff;       /* Text on primary buttons */

  /* Fixed UI */
  --chat-bubble-user: #1f2937;        /* User bubble: dark gray */
  --chat-border: rgba(0, 0, 0, 0.1);
  --chat-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.12);
  --chat-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --chat-max-width: 37.5rem;
  --chat-primary-hover: #374151;
}

/* Reset and base styles */
* {
  box-sizing: border-box;
}

/* Purands widget isolation - prevent customer CSS from overriding */
[class*="purands-"] *,
[class*="purands-"] {
  box-sizing: border-box !important;
}

[class*="purands-"] svg {
  display: inline-block !important;
  vertical-align: middle !important;
  overflow: visible !important;
  flex-shrink: 0 !important;
  max-width: none !important;
  max-height: none !important;
}

[class*="purands-"] svg path,
[class*="purands-"] svg circle,
[class*="purands-"] svg rect,
[class*="purands-"] svg line,
[class*="purands-"] svg polyline,
[class*="purands-"] svg polygon,
[class*="purands-"] svg ellipse {
  vector-effect: non-scaling-stroke !important;
}

/* Reset SVG fill and stroke - don't force inherit as it breaks icons */

[class*="purands-"] button {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif !important;
  cursor: pointer !important;
  line-height: normal !important;
  text-align: center !important;
}

[class*="purands-"] a {
  text-decoration: none !important;
}

[class*="purands-"] img {
  display: block !important;
  border: none !important;
}

html,
body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}

/* Prevent body scroll when chat is open on mobile */
body.purands-chat-open {
  overflow: hidden !important;
  position: fixed !important;
  width: 100% !important;
  height: 100% !important;
  touch-action: none !important;
  overscroll-behavior: none !important;
}

.purands-chat-button,
.purands-chat-container,
.purands-chat-container *,
.purands-chat-overlay {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

/* Floating button with improved animation */
.purands-chat-button {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  width: 4rem;
  height: 4rem;
  border: none;
  border-radius: 50%;
  background: var(--chat-primary);
  color: var(--chat-text-inverse);
  cursor: pointer;
  z-index: 9999999999;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0.625rem 1.5625rem -0.3125rem rgba(0, 0, 0, 0.25);
  transition: var(--chat-transition);
  padding: 0;
  margin: 0;
  overflow: hidden;
  /* will-change: transform; */
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}

.purands-chat-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent 30%, rgba(255, 255, 255, 0.1) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.purands-chat-button:hover::before {
  opacity: 1;
}

.purands-chat-button:hover,
.purands-chat-button:focus {
  transform: scale(1.1) translateZ(0) !important;
  box-shadow: 0 1.25rem 2.5rem -0.625rem rgba(0, 0, 0, 0.3) !important;
  background: var(--chat-primary) !important;
  color: var(--chat-text-inverse) !important;
  outline: none !important;
}

.purands-chat-button:active {
  transform: scale(0.95) translateZ(0) !important;
}

.purands-chat-button svg {
  width: 2.5rem !important;
  height: 2.5rem !important;
  fill: none !important;
  stroke: currentColor !important;
  transition: transform 0.3s ease !important;
  flex-shrink: 0 !important;
}

.purands-chat-button.animating svg {
  animation: rotateOut 0.3s ease-out;
}

@keyframes rotateOut {
  from {
    transform: rotate(0deg) scale(1);
  }

  to {
    transform: rotate(90deg) scale(0);
  }
}

/* Chat container with improved styling */
.purands-chat-container {
  position: fixed;
  bottom: 0;
  right: 0;
  max-width: var(--chat-max-width);
  width: calc(100% - 2rem);
  height: 100dvh;
  height: 100lvh;
  height: 100svh;
  padding-bottom: var(--safe-bottom);
  display: none;
  flex-direction: column;
  background: linear-gradient(135deg, var(--chat-bg), var(--chat-bg-muted));
  border: 1px solid var(--chat-border);
  border-radius: 1.5rem;
  box-shadow: var(--chat-shadow);
  overflow: hidden;
  z-index: 9999999999;
  opacity: 0;
  transform: translateY(20px) scale(0.95) translateZ(0);
  transition: opacity 0.3s ease, transform 0.3s ease;
  contain: layout style paint;
  /* will-change: transform, opacity; */
}

.purands-chat-container.show {
  opacity: 1;
  transform: translateY(0) scale(1) translateZ(0);
}

/* Enhanced header */
.purands-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  background: var(--chat-bg);
  border-bottom: 1px solid #e5e7eb;
  flex-shrink: 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.purands-chat-logo {
  max-height: 2.5rem;
  object-fit: contain;
  display: block;
}

.purands-chat-close-btn {
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--chat-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  transition: var(--chat-transition);
  padding: 0;
}

.purands-chat-close-btn:focus,
.purands-chat-close-btn:hover {
  background: rgba(0, 0, 0, 0.05) !important;
  color: var(--chat-text) !important;
  outline: none !important;
}

.purands-chat-close-btn svg {
  fill: none !important;
  stroke: currentColor !important;
  display: block !important;
  width: 20px !important;
  height: 20px !important;
}

/* Header actions container (cart + close) */
.purands-chat-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Cart button */
.purands-chat-cart-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--chat-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  padding: 0;
}

.purands-chat-cart-btn:hover,
.purands-chat-cart-btn:focus {
  background: rgba(0, 0, 0, 0.05) !important;
  transform: scale(1.05) !important;
  color: var(--chat-text) !important;
  outline: none !important;
}

.purands-chat-cart-btn svg {
  width: 20px;
  height: 20px;
  fill: none !important;
  stroke: currentColor !important;
  display: block !important;
}

/* Cart count badge */
.purands-cart-count {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  background: var(--chat-primary);
  color: var(--chat-text-inverse);
  border-radius: 9px;
  font-size: 0.7rem;
  font-weight: 700;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Wishlist header button */
.purands-chat-wishlist-header-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--chat-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  padding: 0;
}

.purands-chat-wishlist-header-btn:hover,
.purands-chat-wishlist-header-btn:focus {
  background: rgba(0, 0, 0, 0.05) !important;
  transform: scale(1.05) !important;
  color: var(--chat-text) !important;
  outline: none !important;
}

.purands-chat-wishlist-header-btn svg {
  width: 20px;
  height: 20px;
  fill: none !important;
  stroke: currentColor !important;
  display: block !important;
}

/* Wishlist count badge */
.purands-wishlist-count {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  background: var(--chat-primary);
  color: var(--chat-text-inverse);
  border-radius: 9px;
  font-size: 0.7rem;
  font-weight: 700;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.purands-wishlist-count.show {
  display: flex !important;
}

/* Wishlist Modal */
/* Cart Modal */
.purands-cart-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000000001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.purands-cart-modal.visible {
  opacity: 1;
}

.purands-cart-modal-content {
  background: var(--chat-bg);
  border-radius: 1rem;
  max-width: 600px;
  width: 100%;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.purands-cart-modal.visible .purands-cart-modal-content {
  transform: scale(1);
}

.purands-cart-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.purands-cart-modal-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0;
}

.purands-cart-modal-close {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #f1f1f1;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  padding: 0;
  color: var(--chat-text) !important;
}

.purands-cart-modal-close:hover,
.purands-cart-modal-close:focus {
  background: #e0e0e0 !important;
  color: var(--chat-text) !important;
  outline: none !important;
}

.purands-cart-modal-close svg {
  fill: none !important;
  stroke: currentColor !important;
}

.purands-cart-modal-items {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.purands-cart-empty {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--chat-text-muted);
}

.purands-cart-empty svg {
  margin-bottom: 1rem;
  opacity: 0.5;
}

.purands-cart-empty h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--chat-text);
  margin: 0 0 0.5rem 0;
}

.purands-cart-empty p {
  margin: 0;
  font-size: 0.95rem;
}

/* Modal Loading States */
.purands-loading-state,
.purands-cart-loading,
.purands-wishlist-loading,
.purands-quick-view-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  gap: 1rem;
  min-height: 200px;
}

.purands-loading-state .purands-spinner,
.purands-cart-loading .purands-spinner,
.purands-wishlist-loading .purands-spinner,
.purands-quick-view-loading .purands-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #e5e7eb;
  border-top-color: var(--chat-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.purands-loading-state p,
.purands-cart-loading p,
.purands-wishlist-loading p,
.purands-quick-view-loading p {
  margin: 0;
  color: var(--chat-text-muted);
  font-size: 0.875rem;
}

/* Error States */
.purands-error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--chat-text-muted);
}

.purands-error-state svg {
  margin-bottom: 1rem;
  opacity: 0.5;
  color: #ef4444;
}

.purands-error-state h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--chat-text);
  margin: 0 0 0.5rem 0;
}

.purands-error-state p {
  margin: 0;
  font-size: 0.875rem;
}

.purands-cart-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  transition: box-shadow 0.2s ease;
}

.purands-cart-item:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.purands-cart-item-image {
  width: 80px;
  height: 80px;
  border-radius: 0.5rem;
  overflow: hidden;
  background: #f9fafb;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.purands-cart-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.purands-cart-item-image svg {
  opacity: 0.3;
}

.purands-cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.purands-cart-item-title {
  font-weight: 600;
  color: var(--chat-text);
  font-size: 0.95rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.purands-cart-item-variant {
  font-size: 0.85rem;
  color: var(--chat-text-muted);
}

.purands-cart-item-price {
  font-size: 0.95rem;
  color: var(--chat-primary);
  font-weight: 600;
  margin-top: 0.25rem;
}

.purands-cart-quantity-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.purands-cart-item-remove {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #fee;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.purands-cart-item-remove:hover,
.purands-cart-item-remove:focus {
  background: #fcc;
  transform: scale(1.1);
  outline: none !important;
}

.purands-cart-item-remove svg {
  width: 18px;
  height: 18px;
  stroke: #e74c3c;
}

.purands-cart-modal-footer {
  border-top: 1px solid #e5e7eb;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.purands-cart-subtotal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.125rem;
}

.purands-cart-subtotal-label {
  font-weight: 600;
  color: var(--chat-text);
}

.purands-cart-subtotal-value {
  font-weight: 700;
  color: var(--chat-primary);
  font-size: 1.25rem;
}

.purands-cart-view-btn {
  width: 100%;
  padding: 1rem;
  background: var(--chat-primary);
  color: white !important;
  border: none;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.purands-cart-view-btn:hover,
.purands-cart-view-btn:focus {
  background: var(--chat-primary-hover) !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(0, 168, 132, 0.3) !important;
  outline: none !important;
}

/* Wishlist Modal */
.purands-wishlist-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000000001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.purands-wishlist-modal.visible {
  opacity: 1;
}

.purands-wishlist-modal-content {
  background: var(--chat-bg);
  border-radius: 1rem;
  max-width: 600px;
  width: 100%;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.purands-wishlist-modal.visible .purands-wishlist-modal-content {
  transform: scale(1);
}

.purands-wishlist-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.purands-wishlist-modal-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0;
}

.purands-wishlist-modal-close {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #f1f1f1;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  padding: 0;
  color: var(--chat-text) !important;
}

.purands-wishlist-modal-close:hover,
.purands-wishlist-modal-close:focus {
  background: #e0e0e0 !important;
  color: var(--chat-text) !important;
  outline: none !important;
}

.purands-wishlist-modal-close svg {
  fill: none !important;
  stroke: currentColor !important;
  display: block !important;
  width: 20px !important;
  height: 20px !important;
}

.purands-wishlist-modal-items {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
}

.purands-wishlist-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  margin-bottom: 0.75rem;
  transition: all 0.2s ease;
  background: var(--chat-bg);
}

.purands-wishlist-item:hover {
  border-color: var(--chat-primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.purands-wishlist-item-image {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  border-radius: 0.5rem;
  overflow: hidden;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
}

.purands-wishlist-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.purands-wishlist-item-image svg {
  opacity: 0.3;
}

.purands-wishlist-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.purands-wishlist-item-title {
  font-size: 1rem;
  font-weight: 500;
  color: var(--chat-text);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.4;
}

.purands-wishlist-item-price {
  font-size: 0.875rem;
  color: var(--chat-primary);
  font-weight: 600;
}

.purands-wishlist-item-actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
  align-items: center;
  flex-wrap: wrap;
}

.purands-wishlist-quantity-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.purands-wishlist-item-add-to-cart {
  padding: 0.5rem 1rem;
  background: var(--chat-primary);
  color: white;
  border: none;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.purands-wishlist-item-add-to-cart:hover,
.purands-wishlist-item-add-to-cart:focus {
  background: var(--chat-primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  outline: none !important;
}

.purands-wishlist-item-remove {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #fee;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.purands-wishlist-item-remove:hover,
.purands-wishlist-item-remove:focus {
  background: #fcc;
  transform: scale(1.1);
  outline: none !important;
}

.purands-wishlist-item-remove svg {
  width: 18px;
  height: 18px;
  stroke: #e74c3c;
}

/* Mobile responsive */
@media (max-width: 600px) {
  .purands-wishlist-item {
    flex-wrap: wrap;
  }

  .purands-wishlist-item-image {
    width: 60px;
    height: 60px;
  }

  .purands-wishlist-item-actions {
    width: 100%;
    margin-top: 0.5rem;
  }

  .purands-wishlist-item-add-to-cart {
    flex: 1;
  }
}

.purands-wishlist-empty {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--chat-text-muted);
}

.purands-wishlist-empty svg {
  margin-bottom: 1rem;
  opacity: 0.3;
}

.purands-wishlist-empty h3 {
  font-size: 1.25rem;
  color: var(--chat-text);
  margin: 1rem 0 0.5rem;
}

.purands-wishlist-empty p {
  margin: 0;
}

/* Variant Selector */
.purands-variant-selector {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1rem;
  margin: 0.5rem 0;
  animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.purands-variant-selector-header {
  font-weight: 600;
  color: var(--chat-text);
  margin-bottom: 0.75rem;
  font-size: 0.875rem;
}

.purands-variant-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.purands-variant-option {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  background: var(--chat-bg);
  border: 2px solid #e5e7eb;
  border-radius: 0.375rem;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--chat-text);
}

.purands-variant-option:hover {
  border-color: var(--chat-primary);
  background: rgba(var(--chat-primary-rgb), 0.05);
}

.purands-variant-option:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.purands-variant-price {
  color: var(--chat-primary);
  font-weight: 600;
  margin-left: auto;
  padding-left: 1rem;
}

.purands-variant-cancel {
  width: 100%;
  padding: 0.5rem;
  background: transparent;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  color: var(--chat-text-muted);
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.purands-variant-cancel:hover {
  background: #f3f4f6;
  border-color: var(--chat-text-muted);
}

/* Login / Profile Buttons in Header */
.purands-chat-profile-btn,
.purands-chat-login-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  border: none;
  background: transparent;
  color: var(--chat-text);
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.875rem;
  font-weight: 500;
}

.purands-chat-profile-btn:hover,
.purands-chat-profile-btn:focus,
.purands-chat-login-btn:hover,
.purands-chat-login-btn:focus {
  background: rgba(0, 0, 0, 0.05) !important;
  color: var(--chat-text) !important;
  outline: none !important;
}

.purands-chat-profile-btn svg,
.purands-chat-login-btn svg {
  fill: none !important;
  stroke: currentColor !important;
}

.purands-profile-name {
  max-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Login Modal - Removed (login now redirects to /account/login) */

/* Profile Dropdown */
.purands-profile-dropdown {
  position: absolute;
  background: var(--chat-bg);
  border-radius: 0.75rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  min-width: 250px;
  z-index: 10000000003;
  overflow: hidden;
  animation: dropdownFadeIn 0.2s ease;
}

@keyframes dropdownFadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.purands-profile-dropdown-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid #e5e7eb;
  background: #f9fafb;
}

.purands-profile-dropdown-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--chat-text);
  margin-bottom: 0.25rem;
}

.purands-profile-dropdown-email {
  font-size: 0.875rem;
  color: var(--chat-text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.purands-profile-dropdown-menu {
  padding: 0.5rem;
}

.purands-profile-dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border-radius: 0.5rem;
  color: var(--chat-text);
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
}

.purands-profile-dropdown-item:hover {
  background: #f3f4f6;
}

.purands-profile-dropdown-item svg {
  width: 18px;
  height: 18px;
  stroke: var(--chat-text-muted);
}

.purands-profile-dropdown-item span {
  font-size: 0.9375rem;
  font-weight: 500;
}

.purands-profile-dropdown-divider {
  height: 1px;
  background: #e5e7eb;
  margin: 0.5rem 0;
}

/* Orders Modal Styles */
.purands-orders-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000000002;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.purands-orders-modal.visible {
  opacity: 1;
}

.purands-orders-modal-content {
  background: var(--chat-bg);
  border-radius: 1rem;
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: modalSlideUp 0.3s ease;
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.purands-orders-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.purands-orders-modal-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--chat-text);
  margin: 0;
}

.purands-orders-modal-close {
  background: transparent;
  border: none;
  width: 2rem;
  height: 2rem;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--chat-text-muted);
  transition: all 0.2s ease;
}

.purands-orders-modal-close:hover {
  background: #f3f4f6;
  color: var(--chat-text);
}

.purands-orders-modal-content-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
}

/* Loading State */
.purands-orders-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  gap: 1rem;
}

.purands-loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #e5e7eb;
  border-top-color: var(--chat-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.purands-orders-loading p {
  margin: 0;
  color: var(--chat-text-muted);
  font-size: 0.875rem;
}

/* Empty State */
.purands-orders-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  text-align: center;
  gap: 1rem;
}

.purands-orders-empty svg {
  width: 64px;
  height: 64px;
  color: var(--chat-text-muted);
  margin-bottom: 0.5rem;
}

.purands-orders-empty h3 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--chat-text);
}

.purands-orders-empty p {
  margin: 0;
  color: var(--chat-text-muted);
  font-size: 0.875rem;
}

/* Order Cards */
.purands-order-card {
  background: var(--chat-bg);
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1.25rem;
  margin-bottom: 1rem;
  transition: all 0.2s ease;
}

.purands-order-card:hover {
  border-color: var(--chat-text-muted);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.purands-order-card:last-child {
  margin-bottom: 0;
}

.purands-order-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #f3f4f6;
}

.purands-order-header-left {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.purands-order-number {
  font-size: 1rem;
  font-weight: 600;
  color: var(--chat-text);
  margin: 0;
}

.purands-order-date {
  font-size: 0.875rem;
  color: var(--chat-text-muted);
  margin: 0;
}

.purands-order-status {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

/* Status Badge Colors */
.purands-order-status.status-delivered {
  background: #d1fae5;
  color: #065f46;
}

.purands-order-status.status-out-for-delivery {
  background: #dbeafe;
  color: #1e40af;
}

.purands-order-status.status-in-transit,
.purands-order-status.status-shipped {
  background: #e0e7ff;
  color: #4338ca;
}

.purands-order-status.status-processing,
.purands-order-status.status-confirmed {
  background: #fef3c7;
  color: #92400e;
}

.purands-order-status.status-cancelled,
.purands-order-status.status-failed {
  background: #fee2e2;
  color: #991b1b;
}

.purands-order-status.status-pending {
  background: #f3f4f6;
  color: #374151;
}

.purands-order-status svg {
  width: 12px;
  height: 12px;
}

/* Order Items */
.purands-order-items {
  margin: 1rem 0;
}

.purands-order-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0;
}

.purands-order-item:not(:last-child) {
  border-bottom: 1px solid #f3f4f6;
}

.purands-order-item-image {
  width: 48px;
  height: 48px;
  border-radius: 0.5rem;
  object-fit: cover;
  background: #f9fafb;
  flex-shrink: 0;
}

.purands-order-item-details {
  flex: 1;
  min-width: 0;
}

.purands-order-item-title {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--chat-text);
  margin: 0 0 0.25rem 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.purands-order-item-variant {
  font-size: 0.75rem;
  color: var(--chat-text-muted);
  margin: 0;
}

.purands-order-item-qty {
  font-size: 0.875rem;
  color: var(--chat-text-muted);
  flex-shrink: 0;
}

/* Order Footer */
.purands-order-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #f3f4f6;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.purands-order-price {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--chat-text);
  margin: 0;
}

.purands-order-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.purands-order-track-btn,
.purands-order-view-btn {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border: none;
}

.purands-order-track-btn {
  background: var(--chat-primary);
  color: white;
}

.purands-order-track-btn:hover {
  background: var(--chat-primary);
  opacity: 0.9;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.purands-order-view-btn {
  background: var(--chat-bg);
  color: var(--chat-text);
  border: 1px solid #e5e7eb;
}

.purands-order-view-btn:hover {
  background: #f9fafb;
  border-color: var(--chat-text-muted);
}

.purands-order-track-btn svg,
.purands-order-view-btn svg {
  width: 14px;
  height: 14px;
}

/* Delivery Journey Timeline */
.purands-delivery-journeys {
  margin: 1rem 0;
}

.purands-delivery-journey {
  background: #f9fafb;
  border-radius: 0.5rem;
  padding: 1rem;
  margin-bottom: 1rem;
}

.purands-delivery-journey:last-child {
  margin-bottom: 0;
}

.purands-journey-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--chat-text);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.purands-journey-title svg {
  flex-shrink: 0;
  color: var(--chat-primary);
}

.purands-carrier-name {
  margin-left: auto;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--chat-primary);
  background: var(--chat-bg);
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
}

.purands-journey-timeline {
  position: relative;
  padding: 0.5rem 0;
}

.purands-journey-step {
  display: flex;
  gap: 0.75rem;
  position: relative;
  padding-bottom: 1.5rem;
}

.purands-journey-step:last-child {
  padding-bottom: 0;
}

.purands-journey-indicator {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  z-index: 2;
  position: relative;
}

.purands-journey-step.completed .purands-journey-indicator {
  background: #10b981;
  color: white;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
}

.purands-journey-step.failed .purands-journey-indicator {
  background: #ef4444;
  color: white;
}

.purands-journey-connector {
  position: absolute;
  left: 1rem;
  top: 2rem;
  width: 2px;
  height: calc(100% - 0.5rem);
  background: #e5e7eb;
  z-index: 1;
}

.purands-journey-connector.completed {
  background: #10b981;
}

.purands-journey-step-content {
  flex: 1;
  padding-top: 0.25rem;
}

.purands-journey-step-label {
  font-weight: 500;
  color: var(--chat-text);
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.purands-journey-step.completed .purands-journey-step-label {
  color: #10b981;
  font-weight: 600;
}

.purands-journey-step.failed .purands-journey-step-label {
  color: #ef4444;
}

.purands-journey-step-date {
  font-size: 0.875rem;
  color: var(--chat-text-muted);
}

.purands-journey-step-date.pending {
  color: var(--chat-text-muted);
  font-style: italic;
}

.purands-tracking-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1rem;
  padding: 0.75rem;
  background: var(--chat-bg);
  border-radius: 0.5rem;
  font-size: 0.875rem;
}

.purands-tracking-label {
  font-weight: 500;
  color: var(--chat-text-muted);
}

.purands-tracking-number {
  font-family: 'Courier New', monospace;
  color: var(--chat-text);
  font-weight: 600;
  user-select: all;
}

.purands-package-items {
  margin-top: 1rem;
  padding: 0.75rem;
  background: var(--chat-bg);
  border-radius: 0.5rem;
}

.purands-package-items-title {
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--chat-text);
  margin-bottom: 0.5rem;
}

.purands-package-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  font-size: 0.875rem;
  border-bottom: 1px solid #f3f4f6;
}

.purands-package-item:last-child {
  border-bottom: none;
}

.purands-package-item-name {
  color: var(--chat-text);
  flex: 1;
}

.purands-package-item-qty {
  color: var(--chat-text-muted);
  font-weight: 500;
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .purands-orders-modal-content {
    max-width: 100%;
    max-height: 100vh;
    border-radius: 0;
  }

  .purands-orders-modal-header {
    padding: 1rem;
  }

  .purands-orders-modal-title {
    font-size: 1.125rem;
  }

  .purands-orders-modal-content-body {
    padding: 1rem;
  }

  .purands-order-card {
    padding: 1rem;
  }

  .purands-order-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .purands-order-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .purands-order-actions {
    width: 100%;
  }

  .purands-order-track-btn,
  .purands-order-view-btn {
    flex: 1;
    justify-content: center;
  }

  .purands-order-item-title {
    font-size: 0.8125rem;
  }
}

/* Messages area with improved scrollbar and performance optimizations */
.purands-chat-messages {
  flex: 1;
  padding: 1.5rem;
  padding-bottom: 1.5rem;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-height: 0;
  /* Performance optimizations */
  contain: strict;
  overflow-anchor: none;
  transform: translateZ(0);
  will-change: scroll-position;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: auto;
  /* Disable smooth scroll for better performance */
}

.purands-chat-messages::-webkit-scrollbar {
  width: 6px;
}

.purands-chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.purands-chat-messages::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
  transition: background 0.2s;
}

.purands-chat-messages::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Enhanced message bubbles */
.purands-chat-message {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  max-width: 100%;
  animation: messageSlideIn 0.3s ease-out;
}

@keyframes messageSlideIn {
  from {
    opacity: 0;
    transform: translateY(10px) translateZ(0);
  }

  to {
    opacity: 1;
    transform: translateY(0) translateZ(0);
  }
}

.purands-chat-message-user {
  justify-content: flex-end;
}

.purands-chat-message-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: 85%;
  min-width: 0;
}

.purands-chat-bubble {
  display: block;
  position: relative;
  border-radius: 1.25rem;
  padding: 0.75rem 1.25rem;
  font-size: 0.95rem;
  line-height: 1.5;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  word-wrap: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
  transition: transform 0.2s ease;
}

.purands-chat-bubble p {
  margin: 0;
  padding: 0;
}

.purands-chat-bubble:hover {
  transform: translateY(-1px) translateZ(0);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.purands-chat-bubble-user {
  background: var(--chat-bubble-user);
  color: var(--chat-text-inverse);
  border-bottom-right-radius: 0.25rem;
}

.purands-chat-bubble-bot {
  background: var(--chat-bg-dark);
  color: var(--chat-text);
  border-bottom-left-radius: 0.25rem;
}

/* Links in chat messages */
.purands-chat-bubble a {
  color: inherit !important;
  text-decoration: underline;
  cursor: pointer;
}

.purands-chat-bubble-user a {
  color: inherit !important;
  text-decoration: underline;
  cursor: pointer;
}

.purands-chat-bubble-bot a {
  color: inherit !important;
  text-decoration: underline;
  cursor: pointer;
}

.purands-chat-bubble a:hover {
  opacity: 0.7;
  text-decoration: underline;
}

.purands-chat-timestamp {
  font-size: 0.75rem;
  color: var(--chat-text-muted);
  padding: 0 0.75rem;
  opacity: 0.8;
}

.purands-typing-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-style: italic;
  color: var(--chat-text-muted);
}

/* Enhanced typing indicator */
.purands-typing-indicator {
  display: inline-flex;
  gap: 0.3rem;
  align-items: center;
  contain: layout style paint;
  /* will-change: contents; */
}

.purands-typing-dot {
  width: 0.25rem;
  height: 0.25rem;
  background: var(--chat-text-muted);
  border-radius: 50%;
  animation: typing-bounce 1.4s ease-in-out infinite;
  align-self: center;
  margin: auto 0;
  vertical-align: middle;
}

.purands-typing-dot:nth-child(1) {
  animation-delay: -0.32s;
}

.purands-typing-dot:nth-child(2) {
  animation-delay: -0.16s;
}

@keyframes typing-bounce {

  0%,
  60%,
  100% {
    transform: translateY(0);
    opacity: 0.4;
  }

  30% {
    transform: translateY(-0.75rem);
    opacity: 1;
  }
}

/* Enhanced input area */
.purands-chat-input-wrapper {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-top: 1px solid #e5e7eb;
  padding: 1rem 1.25rem;
  flex-shrink: 0;
  position: relative;
  width: 100%;
  padding-bottom: 0px;
  background-clip: padding-box;
  z-index: 10;
}

.purands-chat-inline .purands-chat-input-wrapper {
  bottom: 1rem;
}

.purands-widget-input-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--chat-bg-muted);
  border: 2px solid transparent;
  border-radius: 2rem;
  padding: 0.5rem 0.75rem;
  transition: var(--chat-transition);
}

.purands-widget-input-container:focus-within {
  border-color: var(--chat-primary);
  /* background: var(--chat-bg); */
  box-shadow: 0 0 0 3px rgba(0, 168, 132, 0.1);
}

.purands-chat-input-field {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--chat-text);
  font-size: 1rem;
  padding: 0.5rem;
  min-width: 0;
}

.purands-chat-input-field::placeholder {
  color: var(--chat-text-muted);
}

.purands-chat-input-field:hover {
  background: transparent;
  box-shadow: none;
}

.purands-chat-input-field:focus {
  box-shadow: none;
}

.purands-chat-send-button {
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 50%;
  background: var(--chat-primary);
  color: var(--chat-text-inverse);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--chat-transition);
  flex-shrink: 0;
  padding: 0;
  position: relative;
  overflow: hidden;
}

.purands-chat-send-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255, 255, 255, 0.3), transparent);
  opacity: 0;
  transform: scale(0);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.purands-chat-send-button:hover:not(:disabled)::before {
  opacity: 1;
  transform: scale(1);
}

.purands-chat-send-button:hover:not(:disabled) {
  background: var(--chat-primary-hover);
  transform: scale(1.1);
}

.purands-chat-send-button:active:not(:disabled) {
  transform: scale(0.95);
}

.purands-chat-send-button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.purands-chat-send-button svg {
  width: 1.25rem;
  height: 1.25rem;
  transition: transform 0.2s ease;
  fill: none;
}

.purands-chat-send-button:focus {
  outline: none;
  box-shadow: none;
}

.purands-chat-send-button:focus-visible {
  outline: 2px solid var(--chat-primary);
  outline-offset: 2px;
}

.purands-chat-send-button:hover:not(:disabled) svg {
  transform: translateX(2px);
}

/* Microphone button for speech-to-text */
.purands-chat-mic-button {
  width: 2.25rem;
  height: 2.25rem;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--chat-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
  padding: 0;
  margin-right: 0.25rem;
}

.purands-chat-mic-button:hover {
  background: rgba(var(--chat-primary-rgb), 0.1);
  transform: scale(1.05);
}

.purands-chat-mic-button:active {
  transform: scale(0.95);
}

.purands-chat-mic-button:focus {
  outline: none;
  box-shadow: none;
}

.purands-chat-mic-button:focus-visible {
  outline: 2px solid var(--chat-primary);
  outline-offset: 2px;
}

.purands-chat-mic-button.recording {
  background: var(--chat-primary);
  color: var(--chat-text-inverse);
  animation: pulse-recording 1.5s infinite;
}

@keyframes pulse-recording {

  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 0 0 rgba(var(--chat-primary-rgb), 0.7);
  }

  50% {
    opacity: 0.9;
    box-shadow: 0 0 0 8px rgba(var(--chat-primary-rgb), 0);
  }
}

.purands-chat-mic-button svg {
  width: 1rem;
  height: 1rem;
  fill: none;
  stroke: black;
}

.purands-chat-mic-button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Voice mode - hide input field and show listening animation */
.purands-widget-input-container.voice-active .purands-chat-input-field {
  display: none;
}

.purands-widget-input-container.voice-active .purands-chat-send-button {
  display: none;
}

.purands-voice-listening-text {
  display: none;
  flex: 1;
  color: var(--chat-text);
  font-size: 0.95rem;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0 0.5rem;
}

.purands-widget-input-container.voice-active .purands-voice-listening-text {
  display: flex;
}

.purands-voice-listening-text .purands-voice-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.purands-voice-listening-text.has-transcript .purands-voice-status {
  display: none;
}

.purands-voice-listening-text .purands-transcript {
  color: var(--chat-text);
}

.purands-voice-listening-text .purands-listening-dots {
  display: flex;
  gap: 0.25rem;
  align-items: center;
}

.purands-voice-listening-text .purands-listening-dot {
  width: 0.375rem;
  height: 0.375rem;
  background: var(--chat-primary);
  border-radius: 50%;
  animation: listening-bounce 1.4s ease-in-out infinite;
}

.purands-voice-listening-text .purands-listening-dot:nth-child(1) {
  animation-delay: -0.32s;
}

.purands-voice-listening-text .purands-listening-dot:nth-child(2) {
  animation-delay: -0.16s;
}

@keyframes listening-bounce {

  0%,
  60%,
  100% {
    transform: scale(1);
    opacity: 0.4;
  }

  30% {
    transform: scale(1.5);
    opacity: 1;
  }
}

/* Enhanced carousel */
.purands-chat-carousel {
  display: flex;
  align-items: stretch;
  gap: 1rem;
  overflow-x: auto;
  padding: 0;
  margin: 0;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.purands-chat-carousel::-webkit-scrollbar {
  display: none;
}

/* Enhanced product cards */
.purands-chat-card {
  background: var(--chat-bg) !important;
  border: 1px solid #e5e5e5 !important;
  border-radius: 1rem !important;
  min-width: 17.5rem !important;
  max-width: 17.5rem !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
  flex: 0 0 auto !important;
  transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  cursor: pointer !important;
}

.purands-chat-card-buttons button {
  margin-bottom: 5px;
}

.purands-chat-card-image-container {
  position: relative !important;
  width: 100% !important;
  height: 12rem !important;
  background: #f5f5f5 !important;
  overflow: hidden !important;
  flex-shrink: 0 !important;
}

.purands-chat-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.purands-chat-card-image-link {
  width: 100%;
  height: 100%;
  cursor: pointer;
  display: block;
}

.purands-chat-card:hover .purands-chat-card-image {
  transform: scale(1.05);
}

.purands-chat-card-no-image {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #f8f9fa;
  color: #8e8e93;
}

/* Wishlist/Save button */
.purands-wishlist-btn {
  position: absolute !important;
  top: 0.75rem !important;
  right: 0.75rem !important;
  left: auto !important;
  width: 36px !important;
  height: 36px !important;
  min-width: 36px !important;
  max-width: 36px !important;
  min-height: 36px !important;
  max-height: 36px !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.95) !important;
  border: none !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
  z-index: 10 !important;
  padding: 0 !important;
  margin: 0 !important;
  color: #333 !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  font-family: inherit !important;
  font-size: 1rem !important;
  line-height: 1 !important;
  font-weight: 400 !important;
  text-align: center !important;
  vertical-align: middle !important;
}

.purands-wishlist-btn:hover,
.purands-wishlist-btn:focus {
  transform: scale(1.1) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
  background: rgba(255, 255, 255, 0.95) !important;
  outline: none !important;
}

.purands-wishlist-btn .purands-heart-icon,
.purands-wishlist-btn svg.purands-heart-icon,
button.purands-wishlist-btn .purands-heart-icon {
  transition: all 0.3s ease !important;
  fill: none !important;
  stroke: currentColor !important;
}

.purands-wishlist-btn.active .purands-heart-icon,
.purands-wishlist-btn.active svg.purands-heart-icon,
button.purands-wishlist-btn.active .purands-heart-icon {
  fill: var(--chat-primary) !important;
  stroke: var(--chat-primary) !important;
}

/* Additional specificity for heart icon path */
.purands-wishlist-btn .purands-heart-icon path,
.purands-wishlist-btn svg.purands-heart-icon path {
  fill: none !important;
  stroke: currentColor !important;
}

.purands-wishlist-btn.active .purands-heart-icon path,
.purands-wishlist-btn.active svg.purands-heart-icon path {
  fill: var(--chat-primary) !important;
  stroke: var(--chat-primary) !important;
}

.purands-wishlist-btn.animated {
  animation: heartbeat 0.6s ease;
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.3); }
  50% { transform: scale(1.1); }
  75% { transform: scale(1.2); }
}

.purands-chat-card-content {
  padding: 1.25rem !important;
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  position: relative !important;
}

.purands-chat-card-title {
  color: var(--chat-text) !important;
  margin-bottom: 0.75rem !important;
  line-height: 1.4 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  height: 2.8rem !important;
  flex-shrink: 0 !important;
  font-weight: 700 !important;
  font-size: 1rem !important;
}

.purands-chat-card-title p {
  margin: 0;
  padding: 0;
}

.purands-chat-card-price {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--chat-primary);
  margin-bottom: 0.5rem;
  margin-top: -0.25rem;
  flex-shrink: 0;
}

.purands-price-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--chat-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
  margin-bottom: 0.25rem;
}

.purands-chat-card-description {
  font-size: 0.95rem;
  color: var(--chat-text-muted);
  line-height: 1.5;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 6rem;
  flex-shrink: 0;
  position: relative;
}

/* Fade effect for truncated descriptions */
.purands-chat-card-description.has-more::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2rem;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0), rgba(255, 255, 255, 1));
  pointer-events: none;
}

/* Clickable description indicator */
.purands-chat-card-description.has-more {
  transition: color 0.2s ease;
}

.purands-chat-card-description.has-more:hover {
  color: var(--chat-primary);
}

/* Description tooltip for showing full text */
.purands-description-tooltip {
  position: fixed;
  background: rgba(0, 0, 0, 0.9);
  color: var(--chat-text-inverse);
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  line-height: 1.5;
  z-index: 100000;
  max-width: 300px;
  word-wrap: break-word;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(-5px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.purands-description-tooltip.visible {
  opacity: 1;
  transform: translateY(0);
}

.purands-chat-card-details-actions {
  margin-top: auto;
  flex-shrink: 0;
}

.purands-chat-card-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
}

.purands-chat-card-button {
  width: 100%;
  padding: 0.75rem;
  background: transparent;
  border: 2px solid var(--chat-primary);
  border-radius: 2rem;
  color: var(--chat-primary);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--chat-transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  margin-top: auto;
}

.purands-chat-card-button:hover,
.purands-chat-card-button:focus {
  background: var(--chat-primary) !important;
  color: var(--chat-text-inverse) !important;
  border-color: var(--chat-primary) !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(0, 168, 132, 0.3) !important;
  outline: none !important;
}

.purands-chat-card-button svg {
  fill: none !important;
  stroke: currentColor !important;
}

/* Variant and cart wrapper - displays selector, quantity, and button in same row */
/* Cart controls wrapper - contains quantity and add to cart button */
.purands-cart-controls-wrapper {
  display: flex;
  gap: 0.5rem;
  width: 100%;
}

/* Variant selector dropdown - now full width */
.purands-variant-select {
  width: 100%;
  margin-bottom: 0.5rem;
  padding: 0.75rem 2.5rem 0.75rem 1rem;
  background: var(--chat-bg);
  border: 2px solid #e5e7eb;
  border-radius: 0.75rem;
  color: var(--chat-text);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--chat-transition);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath fill='%234b5563' d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.purands-variant-select:hover {
  border-color: var(--chat-primary);
  background-color: #f9fafb;
}

.purands-variant-select:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background-color: #f3f4f6;
  border-color: var(--chat-text-muted);
}

.purands-variant-select:disabled:hover {
  border-color: var(--chat-text-muted);
  background-color: #f3f4f6;
}

.purands-variant-select:focus {
  outline: none;
  border-color: var(--chat-primary);
  box-shadow: 0 0 0 3px rgba(0, 168, 132, 0.1);
}

.purands-variant-select:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background-color: #f3f4f6;
  border-color: var(--chat-text-muted);
}

/* Quantity controls */
.purands-quantity-wrapper {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  border: 2px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 0.25rem;
  background: var(--chat-bg);
  transition: var(--chat-transition);
  flex: 1 1 auto;
  justify-content: center;
}

.purands-quantity-wrapper:hover {
  border-color: var(--chat-primary);
}

.purands-quantity-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 0.5rem;
  color: var(--chat-primary);
  font-size: 1.25rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--chat-transition);
  line-height: 1;
  padding: 0;
}

.purands-quantity-btn:hover,
.purands-quantity-btn:focus {
  background: rgba(var(--chat-primary-rgb), 0.1) !important;
  color: var(--chat-primary) !important;
  outline: none !important;
}

.purands-quantity-btn:active {
  transform: scale(0.95) !important;
}

.purands-quantity-input {
  width: 45px;
  height: 32px;
  border: none;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--chat-text);
  background: transparent;
  appearance: textfield;
  -moz-appearance: textfield;
}

.purands-quantity-input::-webkit-outer-spin-button,
.purands-quantity-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.purands-quantity-input:focus {
  outline: none;
}

/* Cart controls: Add to Cart button sizing */
.purands-cart-controls-wrapper .purands-chat-add-to-cart-button {
  flex: 1 1 auto;
  min-width: 120px;
  padding: 0.75rem 1.25rem;
}

/* When quantity wrapper is visible, button shares space */
.purands-cart-controls-wrapper .purands-quantity-wrapper:not([style*="display: none"]) {
  flex: 1 1 auto;
}

.purands-cart-controls-wrapper .purands-quantity-wrapper:not([style*="display: none"])~.purands-chat-add-to-cart-button {
  flex: 1 1 auto;
  min-width: 100px;
}

/* Follow-up questions container */
.purands-followup-questions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding: 0;
}

/* Follow-up question pill */
.purands-followup-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
  background: rgba(var(--chat-primary-rgb), 0.1);
  border: 1.5px solid rgba(var(--chat-primary-rgb), 0.3);
  border-radius: 1.5rem;
  color: var(--chat-primary);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.purands-followup-pill:hover {
  background: var(--chat-primary);
  color: var(--chat-text-inverse);
  border-color: var(--chat-primary);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(var(--chat-primary-rgb), 0.3);
}

.purands-followup-pill:active {
  transform: translateY(0);
}

/* Mobile optimization for follow-up pills */
@media (max-width: 768px) {
  .purands-followup-pill {
    font-size: 0.8rem;
    padding: 0.4rem 0.875rem;
    max-width: calc(100vw - 4rem);
    white-space: normal;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }
}

@media (max-width: 480px) {
  .purands-followup-pill {
    font-size: 0.75rem;
    padding: 0.375rem 0.75rem;
    max-width: calc(100vw - 3rem);
    white-space: normal;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }
}

/* Discount code container */
.purands-discount-code-container {
  margin: 0.75rem 0;
  padding: 1rem;
  background: linear-gradient(135deg, rgba(var(--chat-primary-rgb), 0.1), rgba(var(--chat-primary-rgb), 0.05));
  border: 2px dashed var(--chat-primary);
  border-radius: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.purands-discount-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.purands-discount-percentage {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--chat-primary);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.purands-discount-type {
  font-size: 0.875rem;
  color: var(--chat-text-muted);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.purands-discount-code-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: var(--chat-bg);
  border-radius: 0.5rem;
  border: 1px solid #e5e7eb;
}

.purands-discount-code {
  flex: 1;
  font-size: 1.125rem;
  font-weight: 600;
  font-family: 'Courier New', monospace;
  color: var(--chat-text);
  letter-spacing: 0.05em;
}

.purands-discount-copy-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  background: var(--chat-primary);
  color: white;
  border: none;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  white-space: nowrap;
}

.purands-discount-copy-btn:hover {
  background: color-mix(in srgb, var(--chat-primary) 90%, black);
  transform: translateY(-1px);
}

.purands-discount-copy-btn:active {
  transform: translateY(0);
}

.purands-discount-copy-btn.copied {
  background: #10b981;
}

.purands-discount-copy-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  fill: none;
}

.purands-discount-copy-btn:focus {
  outline: none;
  box-shadow: none;
}

.purands-discount-copy-btn:focus-visible {
  outline: 2px solid var(--chat-primary);
  outline-offset: 2px;
}

/* Discount expiration date */
.purands-discount-expiry {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(var(--chat-primary-rgb), 0.2);
  font-size: 0.875rem;
  color: var(--chat-text-muted);
}

.purands-discount-expiry-icon svg {
  width: 14px;
  height: 14px;
  opacity: 0.7;
  fill: none;
}

.purands-discount-expiry-text.urgent {
  color: #e74c3c;
  font-weight: 600;
}

.purands-discount-expiry-text.soon {
  color: #f39c12;
  font-weight: 500;
}

.purands-discount-expiry-text.expired {
  color: #95a5a6;
  text-decoration: line-through;
}

/* Quick View Modal */
.purands-quick-view-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000000000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.purands-quick-view-modal.visible {
  opacity: 1;
}

.purands-quick-view-content {
  background: var(--chat-bg);
  border-radius: 1rem;
  max-width: 1200px;
  width: 95%;
  max-height: 95vh;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 2rem;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.purands-quick-view-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid rgba(var(--chat-primary-rgb), 0.15);
}

.purands-quick-view-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  flex: 1;
  overflow: hidden;
}

.purands-quick-view-right {
  overflow-y: auto;
  padding-right: 0.5rem;
}

.purands-quick-view-right::-webkit-scrollbar {
  width: 6px;
}

.purands-quick-view-right::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.purands-quick-view-right::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

.purands-quick-view-right::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.purands-quick-view-modal.visible .purands-quick-view-content {
  transform: scale(1);
}

.purands-quick-view-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.1);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10;
  padding: 0;
  color: var(--chat-text-muted) !important;
}

.purands-quick-view-close:hover,
.purands-quick-view-close:focus {
  background: rgba(255, 255, 255, 1) !important;
  color: #374151 !important;
  outline: none !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  transform: scale(1.05);
}

.purands-quick-view-left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.purands-quick-view-image {
  position: relative !important;
  background: transparent !important;
  width: 100% !important;
  height: 54vh !important;
  overflow: hidden !important;
  border-radius: 0.75rem !important;
  margin: 0 !important;
  padding: 0 !important;
  flex-shrink: 0;
}

.purands-quick-view-image img {
  width: 100% !important;
  height: 100% !important;
  display: block !important;
  object-fit: contain !important;
  margin: 0 !important;
  padding: 0 !important;
}

.purands-quick-view-wishlist-icon {
  position: absolute !important;
  top: 1rem !important;
  right: 1rem !important;
  left: auto !important;
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  max-width: 40px !important;
  min-height: 40px !important;
  max-height: 40px !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(0, 0, 0, 0.1) !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  z-index: 4 !important;
  transition: all 0.2s ease !important;
  padding: 0 !important;
  margin: 0 !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  font-family: inherit !important;
  font-size: 1rem !important;
  line-height: 1 !important;
  font-weight: 400 !important;
  text-align: center !important;
  vertical-align: middle !important;
  color: #333 !important;
}

.purands-quick-view-wishlist-icon:hover,
.purands-quick-view-wishlist-icon:focus {
  background: rgba(255, 255, 255, 1);
  transform: scale(1.05);
  outline: none !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.purands-quick-view-wishlist-icon.active {
  background: rgba(255, 255, 255, 0.95);
}

.purands-quick-view-wishlist-icon svg,
.purands-quick-view-wishlist-icon .purands-heart-icon {
  width: 24px !important;
  height: 24px !important;
  display: block !important;
}

/* Force heart icon fill/stroke for Quick View */
.purands-quick-view-wishlist-icon .purands-heart-icon,
.purands-quick-view-wishlist-icon svg.purands-heart-icon {
  fill: none !important;
  stroke: #6b7280 !important;
  stroke-width: 2;
}

.purands-quick-view-wishlist-icon.active .purands-heart-icon,
.purands-quick-view-wishlist-icon.active svg.purands-heart-icon {
  fill: var(--chat-primary) !important;
  stroke: var(--chat-primary) !important;
}

.purands-quick-view-wishlist-icon .purands-heart-icon path,
.purands-quick-view-wishlist-icon svg.purands-heart-icon path {
  fill: none !important;
  stroke: #6b7280 !important;
}

.purands-quick-view-wishlist-icon.active .purands-heart-icon path,
.purands-quick-view-wishlist-icon.active svg.purands-heart-icon path {
  fill: var(--chat-primary) !important;
  stroke: var(--chat-primary) !important;
}

.purands-quick-view-details {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow-y: auto;
  max-height: 100%;
  padding-right: 0.5rem;
}

.purands-quick-view-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0;
  flex: 1;
}

/* Collapsible Sections */
.purands-collapsible-section {
  margin: 1rem 0;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
  transition: all 0.3s ease;
}

.purands-collapsible-section:hover {
  border-color: var(--chat-text-muted);
}

.purands-collapsible-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  background: #f9fafb;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.2s;
}

.purands-collapsible-header:hover {
  background: #f3f4f6;
}

.purands-collapsible-section.expanded .purands-collapsible-header {
  background: linear-gradient(135deg, #fef3f2 0%, #fff5f5 100%);
  border-bottom: 1px solid #fecaca;
}

.purands-collapsible-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0;
}

.purands-collapsible-icon {
  font-size: 0.75rem;
  color: var(--chat-text-muted);
  transition: transform 0.3s ease;
}

.purands-collapsible-content {
  padding: 1rem;
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.purands-quick-view-description {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--chat-text-muted);
  max-height: 60vh;
  overflow-y: auto;
}

.purands-quick-view-description::-webkit-scrollbar {
  width: 6px;
}

.purands-quick-view-description::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.purands-quick-view-description::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

.purands-quick-view-description::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Format HTML content in Quick View description */
.purands-quick-view-description p {
  margin: 0 0 1rem 0;
}

.purands-quick-view-description p:last-child {
  margin-bottom: 0;
}

.purands-quick-view-description ul,
.purands-quick-view-description ol {
  margin: 0 0 1rem 1.5rem;
  padding: 0;
}

.purands-quick-view-description li {
  margin-bottom: 0.5rem;
}

.purands-quick-view-description strong,
.purands-quick-view-description b {
  font-weight: 600;
  color: var(--chat-text);
}

.purands-quick-view-description em,
.purands-quick-view-description i {
  font-style: italic;
}

.purands-quick-view-description h1,
.purands-quick-view-description h2,
.purands-quick-view-description h3,
.purands-quick-view-description h4,
.purands-quick-view-description h5,
.purands-quick-view-description h6 {
  margin: 1rem 0 0.5rem 0;
  font-weight: 600;
  color: var(--chat-text);
}

.purands-quick-view-description h1 { font-size: 1.5rem; }
.purands-quick-view-description h2 { font-size: 1.3rem; }
.purands-quick-view-description h3 { font-size: 1.1rem; }
.purands-quick-view-description h4 { font-size: 1rem; }
.purands-quick-view-description h5 { font-size: 0.95rem; }
.purands-quick-view-description h6 { font-size: 0.9rem; }

/* Quick View Price */
.purands-quick-view-price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--chat-primary);
  margin: 0.5rem 0;
}

/* Quick View Variants */
.purands-quick-view-variants {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.purands-quick-view-variant-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--chat-text);
  margin-bottom: 0.25rem;
}

.purands-quick-view-variant-select {
  padding: 0.75rem;
  border: 2px solid #e5e7eb;
  border-radius: 0.5rem;
  font-size: 1rem;
  background: var(--chat-bg);
  cursor: pointer;
  transition: all 0.2s ease;
}

.purands-quick-view-variant-select:hover {
  border-color: var(--chat-primary);
}

.purands-quick-view-variant-select:focus {
  outline: none;
  border-color: var(--chat-primary);
  box-shadow: 0 0 0 3px rgba(var(--chat-primary-rgb, 255, 0, 0), 0.1);
}

.purands-quick-view-variant-select:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background-color: #f3f4f6;
  border-color: var(--chat-text-muted);
}

.purands-quick-view-variant-select:disabled:hover {
  border-color: var(--chat-text-muted);
  background-color: #f3f4f6;
}

/* Quick View Actions */
.purands-quick-view-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.purands-quick-view-add-to-cart-btn,
.purands-quick-view-full-btn {
  width: 100%;
  padding: 0.875rem;
  border: 2px solid var(--chat-primary);
  border-radius: 2rem;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
}

.purands-quick-view-add-to-cart-btn {
  background: transparent !important;
  color: var(--chat-primary) !important;
  border-color: var(--chat-primary) !important;
}

.purands-quick-view-add-to-cart-btn:hover:not(:disabled),
.purands-quick-view-add-to-cart-btn:focus:not(:disabled) {
  background: var(--chat-primary) !important;
  border-color: var(--chat-primary) !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(0, 168, 132, 0.3) !important;
  outline: none !important;
}

.purands-quick-view-add-to-cart-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.purands-quick-view-add-to-cart-btn svg {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  fill: none !important;
  stroke: currentColor !important;
}

.purands-quick-view-full-btn {
  background: transparent !important;
  color: var(--chat-primary) !important;
  border-color: var(--chat-primary) !important;
}

.purands-quick-view-full-btn:hover,
.purands-quick-view-full-btn:focus {
  background: var(--chat-primary) !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(0, 168, 132, 0.3) !important;
  outline: none !important;
}

.purands-quick-view-full-btn svg {
  width: 18px;
  height: 18px;
  fill: none !important;
  stroke: currentColor !important;
}

/* Quick View quantity controls */
.purands-quick-view-quantity-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  justify-content: center;
}

.purands-quick-view-cart-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  width: 100%;
}

/* Floating footer for Quick View */
.purands-quick-view-footer {
  position: sticky;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--chat-bg);
  border-top: 1px solid #e5e7eb;
  padding: 1rem;
  z-index: 5;
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.purands-quick-view-footer-actions {
  display: flex;
  gap: 0.75rem;
  width: 100%;
}

.purands-quick-view-footer .purands-quick-view-add-to-cart-btn {
  flex: 1;
}

.purands-quick-view-footer .purands-quick-view-full-btn {
  flex: 1;
  margin-top: 0;
  border-radius: 0.5rem;
  padding: 0.875rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.975rem;
}

.purands-quick-view-footer .purands-quick-view-full-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* Image indicator for carousel cards */
.purands-image-indicator {
  position: absolute;
  bottom: 0.5rem;
  right: 0.5rem;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  z-index: 2;
}

/* Carousel image navigation */
.purands-carousel-image-nav {
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  background: rgba(255, 255, 255, 0.9) !important;
  border: none !important;
  width: 32px !important;
  height: 32px !important;
  min-width: 32px !important;
  max-width: 32px !important;
  min-height: 32px !important;
  max-height: 32px !important;
  border-radius: 50% !important;
  cursor: pointer !important;
  font-size: 18px !important;
  line-height: 32px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.2s ease !important;
  z-index: 3 !important;
  opacity: 0 !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15) !important;
  padding: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  padding-block: 0 !important;
  padding-inline: 0 !important;
  margin: 0 !important;
  color: #333 !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  font-weight: 400 !important;
  text-align: center !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
}

.purands-chat-card-image-container:hover .purands-carousel-image-nav {
  opacity: 1 !important;
}

.purands-carousel-image-nav:hover,
.purands-carousel-image-nav:focus {
  background: white !important;
  color: #333 !important;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25) !important;
  transform: translateY(-50%) scale(1.1) !important;
  outline: none !important;
}

.purands-carousel-image-nav svg {
  fill: none !important;
  stroke: currentColor !important;
  display: block !important;
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  max-width: 16px !important;
  min-height: 16px !important;
  max-height: 16px !important;
  margin: 0 !important;
  padding: 0 !important;
  flex-shrink: 0 !important;
}

.purands-carousel-image-nav.purands-prev {
  left: 0.5rem !important;
}

.purands-carousel-image-nav.purands-next {
  right: 0.5rem !important;
}

/* Quick View Image Navigation */
.purands-quick-view-image-indicator {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 1.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  z-index: 3;
}

.purands-quick-view-image-nav {
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  background: rgba(255, 255, 255, 0.95) !important;
  border: none !important;
  width: 2.5rem !important;
  height: 2.5rem !important;
  border-radius: 50% !important;
  cursor: pointer !important;
  font-size: 1rem !important;
  line-height: 1 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.2s ease !important;
  z-index: 3 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
  padding: 0 !important;
  color: #333 !important;
  margin: 0 !important;
  min-width: 2.5rem !important;
  max-width: 2.5rem !important;
  min-height: 2.5rem !important;
  max-height: 2.5rem !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  font-family: inherit !important;
  font-weight: 400 !important;
  text-align: center !important;
  vertical-align: middle !important;
}

.purands-quick-view-image-nav:hover,
.purands-quick-view-image-nav:focus {
  background: white !important;
  color: #333 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
  transform: translateY(-50%) scale(1.1) !important;
  outline: none !important;
}

.purands-quick-view-image-nav svg {
  fill: none !important;
  stroke: currentColor !important;
  display: block !important;
  width: 20px !important;
  height: 20px !important;
}

.purands-quick-view-image-nav.purands-prev {
  left: 1rem !important;
  right: auto !important;
}

.purands-quick-view-image-nav.purands-next {
  right: 1rem !important;
  left: auto !important;
}

/* Quick View Rating */
.purands-quick-view-rating {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.5rem 0;
}

.purands-stars {
  display: flex;
  gap: 0.125rem;
}

.purands-star {
  font-size: 1.25rem;
  line-height: 1;
}

.purands-star-full {
  color: #fbbf24;
}

.purands-star-half {
  color: #fbbf24;
  position: relative;
}

.purands-star-half::after {
  content: '★';
  position: absolute;
  left: 0;
  color: var(--chat-text-muted);
  clip-path: polygon(50% 0, 100% 0, 100% 100%, 50% 100%);
}

.purands-star-empty {
  color: var(--chat-text-muted);
}

.purands-rating-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--chat-text-muted);
}

/* Quick View Reason to Use */
.purands-quick-view-reason {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  border-left: 4px solid var(--chat-primary);
  padding: 1rem;
  border-radius: 0.5rem;
  margin: 1rem 0;
}

.purands-quick-view-reason-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--chat-primary);
  margin: 0 0 0.5rem 0;
}

.purands-quick-view-reason-text {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--chat-text);
  margin: 0;
}

/* Quick View Product Fit Section */
.purands-product-fit-loading {
  text-align: center;
  padding: 1rem;
  color: var(--chat-text-muted);
  font-size: 0.9rem;
  position: relative;
  overflow: hidden;
}

.purands-product-fit-loading::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--chat-primary), transparent);
  animation: loading-slide 1.5s ease-in-out infinite;
}

.purands-product-fit-error {
  text-align: center;
  padding: 0.5rem;
  color: #dc2626;
  font-size: 0.85rem;
}


.purands-product-fit-content {
  animation: fadeIn 0.3s ease-in;
  margin-bottom: 1.5rem;
}

.purands-quick-view-product-fit-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid rgba(var(--chat-primary-rgb), 0.2);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.purands-product-fit-heading {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0 0 0.5rem 0;
  line-height: 1.3;
}

.purands-product-fit-heading em {
  font-style: italic;
  font-weight: 400;
}

.purands-product-fit-subheading {
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--chat-text-muted);
  margin-bottom: 1rem;
}

.purands-product-fit-cards {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.purands-product-fit-card {
  background: rgba(var(--chat-primary-rgb), 0.05);
  border-radius: 0.75rem;
  padding: 1rem;
  border: 1px solid rgba(var(--chat-primary-rgb), 0.3);
  transition: transform 0.2s, box-shadow 0.2s;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  gap: 0.5rem 1rem;
  align-items: start;
}

.purands-product-fit-card:hover {
  transform: translateX(4px);
  box-shadow: 0 2px 8px rgba(var(--chat-primary-rgb), 0.2);
}

.purands-product-fit-card-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--chat-text);
  line-height: 1.3;
  grid-column: 1 / -1;
}

.purands-product-fit-card-rating {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--chat-primary) 0%, var(--chat-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  grid-row: 2;
  grid-column: 1;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.purands-product-fit-card-rating::after {
  content: '/10';
  font-size: 0.875rem;
  color: var(--chat-text-muted);
  font-weight: 400;
  background: none;
  -webkit-text-fill-color: var(--chat-text-muted);
}

.purands-product-fit-card-right {
  grid-row: 2;
  grid-column: 2;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.purands-product-fit-card-progress {
  width: 100%;
  height: 6px;
  background: rgba(var(--chat-primary-rgb), 0.2);
  border-radius: 3px;
  overflow: hidden;
}

.purands-product-fit-card-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--chat-primary) 0%, var(--chat-primary) 100%);
  border-radius: 3px;
  transition: width 0.6s ease;
}

.purands-product-fit-card-description {
  font-size: 0.8125rem;
  color: var(--chat-text-muted);
  line-height: 1.5;
}

.purands-product-fit-why {
  background: rgba(var(--chat-primary-rgb), 0.05);
  border-radius: 0.75rem;
  padding: 1rem;
  border: 1px solid rgba(var(--chat-primary-rgb), 0.2);
}

.purands-product-fit-why-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0 0 0.5rem 0;
}

.purands-product-fit-why-text {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--chat-text);
  margin: 0;
}

.purands-product-fit-why-text ul,
.purands-product-fit-why-text ol {
  margin: 0.5rem 0;
  padding-left: 1.5rem;
  list-style: disc;
}

.purands-product-fit-why-text li {
  margin-bottom: 0.25rem;
}

/* Quick View Reviews Summary */
.purands-quick-view-reviews {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  padding: 1rem;
  border-radius: 0.5rem;
  margin: 1rem 0;
}

.purands-quick-view-reviews-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--chat-text);
  margin: 0 0 0.5rem 0;
}

.purands-quick-view-reviews-text {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--chat-text-muted);
  margin: 0;
}

/* Mobile quick view */
@media (max-width: 768px) {
  .purands-quick-view-modal {
    padding: 0;
    align-items: flex-start;
  }

  .purands-quick-view-content {
    width: 100%;
    max-width: 100%;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
    padding: 1.5rem 1rem 1rem 1rem;
  }

  .purands-quick-view-header {
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    padding-right: 3rem;
    gap: 0.5rem;
    flex-direction: column;
    align-items: stretch;
  }

  .purands-quick-view-title {
    font-size: 1.125rem;
    line-height: 1.3;
    padding-right: 0;
  }

  .purands-quick-view-price {
    font-size: 1.25rem;
  }

  .purands-quick-view-body {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
  }

  .purands-quick-view-left,
  .purands-quick-view-right {
    width: 100%;
    overflow-y: visible;
    padding-right: 0;
  }

  .purands-quick-view-image {
    height: 40vh !important;
    margin-bottom: 1rem;
  }

  .purands-quick-view-close {
    position: fixed !important;
    width: 36px;
    height: 36px;
    top: 1rem;
    right: 1rem;
    font-size: 1.25rem;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  }

  .purands-quick-view-wishlist-icon {
    width: 36px;
    height: 36px;
    top: 0.5rem;
    right: 0.5rem;
  }

  .purands-product-fit-card {
    padding: 0.875rem;
    gap: 0.5rem 0.75rem;
  }

  .purands-product-fit-card-title {
    font-size: 0.875rem;
  }

  .purands-product-fit-card-rating {
    font-size: 1.25rem;
  }

  .purands-product-fit-card-description {
    font-size: 0.8rem;
  }

  /* Hide image navigation arrows on mobile - use swipe instead */
  .purands-quick-view-image-nav {
    display: none !important;
  }

  /* Cart modal full-screen on mobile */
  .purands-cart-modal {
    padding: 0;
    align-items: flex-start;
  }

  .purands-cart-modal-content {
    width: 100%;
    max-width: 100%;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
  }

  .purands-cart-modal-header {
    padding: 1rem 1rem 1rem 1.5rem;
  }

  .purands-cart-modal-title {
    font-size: 1.25rem;
  }

  .purands-cart-modal-close {
    width: 36px;
    height: 36px;
    font-size: 1.25rem;
  }

  .purands-cart-modal-items {
    padding: 1rem;
  }

  .purands-cart-modal-footer {
    padding: 1rem 1rem 1.5rem 1rem;
  }

  /* Wishlist modal full-screen on mobile */
  .purands-wishlist-modal {
    padding: 0;
    align-items: flex-start;
  }

  .purands-wishlist-modal-content {
    width: 100%;
    max-width: 100%;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
  }

  .purands-wishlist-modal-header {
    padding: 1rem 1rem 1rem 1.5rem;
  }

  .purands-wishlist-modal-title {
    font-size: 1.25rem;
  }

  .purands-wishlist-modal-close {
    width: 36px;
    height: 36px;
    font-size: 1.25rem;
  }

  .purands-wishlist-modal-items {
    padding: 1rem;
  }
}

/* Container for suggestion cards */
.purands-suggestion-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 0;
  margin: 1rem 0;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

/* Individual suggestion card */
.purands-suggestion-card {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  cursor: pointer;
  border-radius: 0.5rem;
  overflow: hidden;
  background-color: rgba(var(--chat-primary-rgb), 0.1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  max-height: 250px;
  margin-right: 1rem;
  /* will-change: transform, box-shadow; */
  backface-visibility: hidden;
  -webkit-font-smoothing: antialiased;
  width: 100%;
}

.purands-suggestion-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 4px;
  height: 100%;
  background: var(--chat-primary);
  border-radius: 0 0.25rem 0.25rem 0;
}

/* Alternating layout for suggestion cards */
.purands-suggestion-card:nth-child(even) {
  flex-direction: row-reverse;
}

/* .purands-suggestion-card:nth-child(even) .purands-suggestion-image {
   order: 2; 
} */
.purands-suggestion-card:nth-child(even) .purands-suggestion-text {
  order: 1;
}

.purands-suggestion-card:hover {
  transform: translateY(-2px) translateZ(0);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Card image (landscape) */
.purands-suggestion-image {
  flex: 0 0 40%;
  max-width: 40%;
  height: auto;
  display: block;
  /* width: 50%; */
  /* aspect-ratio: 16/9; */
  object-fit: cover;
  background: #f5f5f5;
  background-image: linear-gradient(90deg, #f5f5f5 25%, #e5e5e5 50%, #f5f5f5 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.purands-suggestion-image[src] {
  animation: none;
  background: none;
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

.purands-suggestion-text {
  flex: 1 1 60%;
  max-width: 60%;
  padding: 1rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--chat-text);
  border-radius: 0.5rem;
  position: relative;
  height: 100%;
  align-content: center;
}

/* No image placeholder for suggestions */
.purands-suggestion-no-image {
  flex: 0 0 40%;
  max-width: 40%;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  color: #999;
  font-size: 0.875rem;
}

/* Loading state for suggestions */
.purands-suggestions-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 2rem;
  color: var(--chat-text-muted);
  font-size: 0.875rem;
}

.purands-loading-spinner {
  width: 1.5rem;
  height: 1.5rem;
  border: 2px solid rgba(0, 0, 0, 0.1);
  border-top-color: var(--chat-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Welcome message styling */
.purands-chat-window-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
  color: var(--chat-text);
}

/* Footer styling */
.purands-chat-footer {
  text-align: center;
  font-size: 0.75rem;
  color: var(--chat-text-muted);
  /* background-color: rgba(255, 255, 255, 0.95); */
  padding: 0.75rem;
  flex-shrink: 0;
  line-height: 1.5;
}

.purands-chat-footer a {
  color: var(--chat-text);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.purands-chat-footer a:hover {
  color: var(--chat-primary);
  text-decoration: underline;
}

/* Loading state for input */
.purands-widget-input-container.loading {
  position: relative;
  overflow: hidden;
}

.purands-widget-input-container.loading::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--chat-primary), transparent);
  animation: loading-slide 1.5s ease-in-out infinite;
}

@keyframes loading-slide {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

/* Accessibility improvements */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus visible for keyboard navigation */
.purands-chat-button:focus-visible,
.purands-chat-close-btn:focus-visible,
.purands-chat-send-button:focus-visible,
.purands-chat-card-button:focus-visible {
  outline: 3px solid var(--chat-primary);
  outline-offset: 2px;
}

/* Mobile optimizations */
@media (max-width: 768px) {

  /* Use hardware acceleration for mobile transforms */
  .purands-chat-container,
  .purands-chat-button,
  .purands-suggestion-card {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
  }

  /* Optimize touch targets */
  .purands-suggestion-card {
    min-height: 44px;
    touch-action: manipulation;
  }


  .purands-chat-container {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    padding: 0 !important;
    padding-bottom: 0 !important;
    border-radius: 0 !important;
    margin: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    overflow: hidden !important;
  }

  .purands-chat-card-title {
    -webkit-line-clamp: 2;
    height: auto;
    max-height: none;
  }

  .purands-chat-card-description {
    -webkit-line-clamp: 4;
    height: 6rem;
    line-height: 1.5;
  }

  .purands-chat-modal-container {
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
  }
}

@media (max-width: 480px) {
  .purands-chat-container {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    padding: 0 !important;
    padding-bottom: 0 !important;
    border-radius: 0 !important;
    margin: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    overflow: hidden !important;
  }

  .purands-chat-header {
    padding: 1rem !important;
    border-radius: 0;
  }

  .purands-chat-messages {
    padding: 1rem !important;
    padding-bottom: 6rem !important;
    /* Adjusted for mobile input wrapper */
  }

  .purands-chat-input-wrapper {
    padding: 0.75rem 1rem !important;
    position: fixed !important;
    bottom: 0 !important;
    padding-bottom: calc(0.75rem + var(--safe-bottom)) !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
  }

  .purands-chat-card {
    min-width: 15rem;
    max-width: 15rem;
  }

  .purands-chat-footer {
    display: none;
  }

  .purands-chat-modal-container {
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    border-radius: 0 !important;
  }

  .purands-center-suggestions.show {
    width: clamp(14rem, 90vw, 23rem);
  }
}

/* Disable hover effects on mobile */
@media (hover: none) {
  .purands-suggestion-card:hover {
    transform: none;
  }

  .purands-chat-bubble:hover {
    transform: none;
  }
}

/* Overlay */
.purands-chat-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 9999999998;
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.purands-chat-overlay.show {
  opacity: 1;
}

/* Prevent body scroll when chat is open on mobile */
body.purands-chat-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

/* ===========================================
   CENTERED INPUT INTERFACE STYLES
   =========================================== */

/* Centered input container */
.purands-center-input-container {
  position: relative;
  z-index: 99;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  pointer-events: none;
  width: 100%;
  margin: 2rem auto;
  padding: 2rem 0;
}

/* Position variants using margin for spacing */
.purands-center-input-container[data-position="center"] {
  margin: 4rem auto;
}

.purands-center-input-container[data-position="top"] {
  margin: 2rem auto 4rem auto;
}

.purands-center-input-container[data-position="bottom"] {
  margin: 4rem auto 2rem auto;
}

/* Heading section */
.purands-center-heading-section {
  text-align: center;
  margin-bottom: 2rem;
  padding: 0 1rem;
  max-width: 70rem;
  pointer-events: none;
}

.purands-center-heading {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--chat-text);
  margin: 0 0 1rem 0;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.purands-center-subheading {
  font-size: clamp(1rem, 2vw, 1.125rem);
  font-weight: 400;
  color: var(--chat-text-muted);
  margin: 0;
  line-height: 1.6;
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
}

.purands-center-subheading a {
  color: var(--chat-primary-color, #0066cc);
  text-decoration: underline;
  cursor: pointer;
  pointer-events: auto;
}

.purands-center-subheading a:hover {
  color: var(--chat-primary-hover, #0052a3);
  text-decoration: underline;
}

/* Input wrapper */
.purands-center-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 2rem;
  padding: 0.75rem;
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.2);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: all;
  max-width: 90vw;
  width: clamp(20rem, 80vw, 70rem);
  touch-action: manipulation;
}

.purands-center-input-wrapper:hover {
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.25);
  transform: translateY(-2px);
}

.purands-center-input-wrapper:focus-within {
  border-color: var(--chat-primary);
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.25),
    0 0 0 3px rgba(var(--chat-primary-rgb), 0.2);
}

/* Visual indicator when there's chat history */
.purands-center-input-wrapper.has-history {
  border-color: rgba(var(--chat-primary-rgb), 0.3);
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.2),
    0 0 0 1px rgba(var(--chat-primary-rgb), 0.2);
}

.purands-center-input-wrapper.has-history:hover {
  border-color: var(--chat-primary);
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.25),
    0 0 0 2px rgba(var(--chat-primary-rgb), 0.3);
  cursor: pointer;
}

.purands-center-input-wrapper.has-history::before {
  position: absolute;
  right: 3.5rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
  opacity: 0.6;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.purands-center-input-wrapper.has-history:hover::before {
  opacity: 1;
}

/* Center input field */
.purands-center-input-field {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0.75rem 1rem;
  font-size: 16px;
  line-height: 1.5;
  color: var(--chat-text);
  outline: none;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  touch-action: manipulation;
  -webkit-text-size-adjust: 100%;
}

.purands-center-input-field::placeholder {
  color: var(--chat-text-muted);
  opacity: 0.8;
}

.purands-center-input-field:hover {
  background: transparent;
  box-shadow: none;
}

.purands-center-input-field:focus {
  background: transparent;
  box-shadow: none;
}

/* Center send button */
.purands-center-send-button {
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 50%;
  background: var(--chat-primary);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  margin-left: 0.5rem;
  flex-shrink: 0;
}

.purands-center-send-button:hover:not(:disabled) {
  background: color-mix(in srgb, var(--chat-primary) 90%, black);
  transform: scale(1.05);
}

.purands-center-send-button:active {
  transform: scale(0.95);
}

.purands-center-send-button:disabled {
  background: var(--chat-text-muted);
  cursor: not-allowed;
  opacity: 0.6;
}

.purands-center-send-button svg {
  width: 1rem;
  height: 1rem;
}

/* Center suggestions */
.purands-center-suggestions {
  margin-top: 1.5rem;
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: all;
  width: 100%;
  display: flex;
  justify-content: center;
}

.purands-center-suggestions.show {
  opacity: 1;
  transform: translateY(0);
}

.purands-center-suggestion-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
  max-width: clamp(20rem, 80vw, 70rem);
  width: 100%;
}

.purands-center-suggestion-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 1.5rem;
  padding: 1.5rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.1);
  min-height: 120px;
  opacity: 1;
}

.purands-center-suggestion-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, 0.15);
  border-color: var(--chat-primary);
}

.purands-center-suggestion-card:active {
  transform: translateY(-2px);
}

.purands-center-suggestion-image {
  max-width: 180px;
  height: 120px;
  object-fit: cover;
  border-radius: 1rem;
  flex-shrink: 0;
}

.purands-center-suggestion-no-image {
  width: 80px;
  height: 80px;
  background: #f3f4f6;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.purands-center-suggestion-no-image span {
  font-size: 0.75rem;
  color: var(--chat-text-muted);
  text-align: center;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.purands-center-suggestion-text {
  flex: 1;
  font-size: 1rem;
  color: var(--chat-text);
  font-weight: 500;
  line-height: 1.4;
  text-align: left;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

/* ===========================================
   MODAL CHAT INTERFACE STYLES
   =========================================== */

/* Modal chat container (80% VW/VH) */
.purands-chat-modal {
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) scale(0.9) !important;
  width: 80vw !important;
  height: 80vh !important;
  max-width: 80vw !important;
  max-height: 80vh !important;
  border-radius: 1.5rem !important;
  bottom: auto !important;
  right: auto !important;
  z-index: 9999999999;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.purands-chat-modal.show {
  opacity: 1 !important;
  transform: translate(-50%, -50%) scale(1) !important;
}

/* Body class for modal open state */
body.purands-chat-modal-open {
  overflow: hidden;
}

/* ===========================================
   INLINE CHAT INTERFACE STYLES
   =========================================== */

/* Inline chat container (integrated into page) */
.purands-chat-inline {
  position: relative !important;
  width: 100% !important;
  max-width: 960px !important;
  height: auto;
  min-height: 500px !important;
  /* max-height: 800px !important; */
  margin: 2rem auto !important;
  border-radius: 1.5rem !important;
  z-index: 1 !important;
  opacity: 0;
  transform: translateY(20px) !important;
  transition: opacity 0.3s ease, transform 0.3s ease !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: hidden !important;
}

.purands-chat-inline.show {
  opacity: 1 !important;
  transform: none !important;
}


/* Hide header in page mode */
.purands-chat-inline .purands-chat-header {
  display: none !important;
}

/* Remove background from input wrapper in page mode */
.purands-chat-inline .purands-chat-input-wrapper {
  background: transparent !important;
  backdrop-filter: none !important;
  border-top: none !important;
}

/* Messages area for inline chat - full height with hidden scrollbar */
.purands-chat-inline .purands-chat-messages {
  height: 100% !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  scrollbar-width: none !important;
  /* Firefox */
  -ms-overflow-style: none !important;
  /* IE/Edge */
}

.purands-chat-inline .purands-chat-messages::-webkit-scrollbar {
  display: none !important;
  /* Chrome/Safari */
}

/* Modal responsive adjustments */
@media (max-width: 768px) {
  .purands-center-input-wrapper {
    width: clamp(16rem, 80vw, 25rem);
    padding: 0.5rem;
  }

  /* Prevent transform on mobile to avoid zoom triggers */
  .purands-center-input-wrapper:hover {
    transform: none;
  }

  .purands-center-input-field {
    font-size: 16px;
    padding: 0.5rem 0.75rem;
  }

  .purands-center-send-button {
    width: 2rem;
    height: 2rem;
    margin-left: 0.25rem;
  }

  .purands-center-send-button svg {
    width: 0.875rem;
    height: 0.875rem;
  }

  .purands-center-suggestion-cards {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    max-width: clamp(16rem, 85vw, 50rem);
    gap: 0.75rem;
  }

  .purands-center-suggestion-card {
    padding: 1rem;
    min-height: 100px;
    gap: 0.75rem;
  }

  .purands-center-suggestion-image {
    width: 60px;
    height: 60px;
  }

  .purands-center-suggestion-no-image {
    width: 60px;
    height: 60px;
  }

  .purands-center-suggestion-text {
    font-size: 0.9rem;
  }

  .purands-chat-modal {
    width: 95vw !important;
    height: 90vh !important;
    max-width: 95vw !important;
    max-height: 90vh !important;
    border-radius: 1rem !important;
  }

  .purands-chat-input-wrapper {
    bottom: 0 !important;
  }
}

@media (max-width: 480px) {
  .purands-chat-modal-container {
    border-radius: 0 !important;
  }


  .purands-chat-inline {
    margin: 0 !important;
  }

  .purands-chat-inline .purands-chat-input-wrapper {
    background: rgba(255, 255, 255, 0.95) !important;
  }

  .purands-center-input-wrapper {
    width: clamp(14rem, 90vw, 23rem);
    background: rgba(255, 255, 255, 0.95) !important;
  }

  .purands-center-suggestion-cards {
    grid-template-columns: 1fr;
    max-width: clamp(14rem, 95vw, 25rem);
    gap: 0.5rem;
  }

  .purands-center-suggestion-card {
    padding: 1rem;
    min-height: 80px;
    gap: 0.75rem;
    flex-direction: row;
  }

  .purands-center-suggestion-image {
    width: 50px;
    height: 50px;
  }

  .purands-center-suggestion-no-image {
    width: 50px;
    height: 50px;
  }

  .purands-center-suggestion-text {
    font-size: 0.85rem;
    line-height: 1.3;
  }

  .purands-chat-modal {
    width: 100vw !important;
    height: 100vh !important;
    max-width: 100vw !important;
    max-height: 100vh !important;
    border-radius: 0 !important;
    top: 0 !important;
    left: 0 !important;
    transform: none !important;
  }

  .purands-chat-modal.show {
    transform: none !important;
  }

  .purands-chat-input-wrapper {
    bottom: 0 !important;
  }
}

/* Chat Modal Styles */
.purands-chat-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 99999999999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  overflow: hidden;
  touch-action: none;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: none;
}

.purands-chat-modal-overlay.show {
  overflow: hidden;
}

.purands-chat-modal-overlay.show {
  opacity: 1;
}

.purands-chat-modal-container {
  background: var(--chat-bg);
  border-radius: 12px;
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-height: 100vh;
  max-height: 100dvh;
  position: relative;
  transform: scale(0.9);
  transition: transform 0.3s ease;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  touch-action: pan-y;
  overscroll-behavior: contain;
}

.purands-chat-modal-container.show {
  transform: scale(1);
}

.purands-chat-container p {
  margin: 0;
  padding: 0;
}

.purands-chat-modal-header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f9fafb;
  flex-shrink: 0;
}

.purands-chat-modal-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--chat-text);
  display: flex;
  align-items: center;
}

.purands-chat-modal-logo {
  max-height: 32px;
  max-width: 150px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.purands-chat-modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--chat-text-muted);
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.purands-chat-modal-close:hover {
  background-color: #e5e7eb;
}

.purands-chat-modal-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.purands-chat-modal-body .purands-chat-container {
  width: 100% !important;
  height: 100% !important;
  position: relative !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  display: flex !important;
  flex-direction: column !important;
  background: white !important;
  bottom: auto !important;
  right: auto !important;
  transform: none !important;
  opacity: 1 !important;
}

/* Additional performance optimizations */
.purands-chat-message {
  contain: layout style;
  transform: translateZ(0);
}

.purands-chat-carousel {
  /* contain: layout; */
  transform: translateZ(0);
}

/* Optimize modal scroll performance */
.purands-chat-modal-body .purands-chat-messages {
  contain: strict;
  transform: translateZ(0);
  will-change: scroll-position;
  backface-visibility: hidden;
}

/* =========================================
   MARKDOWN STYLES FOR CHAT CONTENT
   ========================================= */

/* Override theme styles for chat message content */
.purands-chat-message h1,
.purands-chat-message h2,
.purands-chat-message h3,
.purands-chat-message h4,
.purands-chat-message h5,
.purands-chat-message h6 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  font-weight: 600 !important;
  line-height: 1.4 !important;
  margin: 0.75rem 0 0.5rem 0 !important;
  color: var(--chat-text) !important;
  border: none !important;
  background: none !important;
  padding: 0 !important;
}

/* Specific heading sizes */
.purands-chat-message h1 {
  font-size: 1.5rem !important;
}

.purands-chat-message h2 {
  font-size: 1.375rem !important;
}

.purands-chat-message h3 {
  font-size: 1.25rem !important;
}

.purands-chat-message h4 {
  font-size: 1.125rem !important;
}

.purands-chat-message h5 {
  font-size: 1rem !important;
}

.purands-chat-message h6 {
  font-size: 0.875rem !important;
}

/* First heading in message should have no top margin */
.purands-chat-message h1:first-child,
.purands-chat-message h2:first-child,
.purands-chat-message h3:first-child,
.purands-chat-message h4:first-child,
.purands-chat-message h5:first-child,
.purands-chat-message h6:first-child {
  margin-top: 0 !important;
}

/* Reset list styles and let marked.js handle structure */
.purands-chat-bubble ul,
.purands-chat-bubble ol {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--chat-text);
  background: none;
  border: none;
}

.purands-chat-bubble ul li,
.purands-chat-bubble ol li {
  line-height: 1.5;
  color: var(--chat-text);
  background: none;
  border: none;
}

/* Custom bullet styling */
.purands-chat-bubble ul {
  list-style: none;
}

.purands-chat-bubble ul li::before {
  content: '•';
  color: var(--chat-primary);
  font-weight: 600;
  margin-right: 0.5rem;
}

.purands-chat-bubble ol {
  list-style: decimal;
  list-style-position: outside;
}

/* Nested list styling */
.purands-chat-bubble ul ul li::before {
  content: '◦';
  font-size: 0.875rem;
}

.purands-chat-bubble ul ul ul li::before {
  content: '▪';
  font-size: 0.75rem;
}

/* Clean up paragraphs in lists */
.purands-chat-bubble ul li p,
.purands-chat-bubble ol li p {
  margin: 0;
  padding: 0;
  display: inline;
}

/* Disable interactions during processing */
.purands-chat-messages.processing {
  /* Allow scrolling and reading, but disable interactive elements */
  pointer-events: auto;
}

/* Disable follow-up pills and Product Details buttons during processing (they create new AI questions) */
.purands-chat-messages.processing .purands-followup-pill,
.purands-chat-messages.processing .purands-chat-card-button:not(.purands-chat-add-to-cart-button) {
  pointer-events: none !important;
  opacity: 0.5;
  cursor: not-allowed !important;
}

/* Ensure Add to Cart buttons remain enabled during processing */
.purands-chat-messages.processing .purands-chat-add-to-cart-button {
  pointer-events: auto !important;
  opacity: 1 !important;
  cursor: pointer !important;
}