/* Product Cards — inline chat rendering */

.product-cards-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 6px 0 4px 0;
  width: 100%;
}

/* ── Base card — compact horizontal layout ──────────────────────── */
.pc-card {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0;           /* square card corners (client request) */
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  width: 100%;
  max-width: 100%;
  gap: 0;
  transition: box-shadow 0.15s ease;
}

.pc-card:hover {
  box-shadow: 0 3px 10px rgba(0,0,0,0.11);
}

/* ── Image — fixed small square on the left ─────────────────────── */
.pc-card__img-wrap {
  position: relative;
  width: 80px;
  min-width: 80px;
  height: 80px;
  overflow: hidden;
  background: #f3f4f6;
  flex-shrink: 0;
}

.pc-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* ── Trending badge ──────────────────────────────────────────────── */
.pc-trending-badge {
  position: absolute;
  top: 5px;
  left: 5px;
  background: var(--pc-accent, #7c3aed);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 20px;
  pointer-events: none;
  z-index: 2;
}

/* ── SALE ribbon ─────────────────────────────────────────────────── */
.pc-sale-ribbon {
  position: absolute;
  top: 5px;
  right: 5px;
  background: #dc2626;
  color: #fff;
  font-size: 8px;
  font-weight: 700;
  padding: 2px 5px;
  border-radius: 20px;
  text-transform: uppercase;
  pointer-events: none;
  z-index: 2;
}

/* ── Body ────────────────────────────────────────────────────────── */
.pc-card__body {
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3px;
  flex: 1;
  min-width: 0;
}

.pc-card__title {
  font-size: 13px;
  font-weight: 700;
  color: #111827;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin: 0;
}

/* ── Tags / subtitle ─────────────────────────────────────────────── */
.pc-card__tags {
  font-size: 10px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Star rating ─────────────────────────────────────────────────── */
.pc-star-row {
  display: flex;
  align-items: center;
  gap: 1px;
}

.pc-star {
  color: #f59e0b;
  font-size: 10px;
  line-height: 1;
}

.pc-star--empty {
  color: #d1d5db;
}

/* ── Meta row ────────────────────────────────────────────────────── */
.pc-card__meta-row {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.pc-size-pill {
  display: inline-flex;
  align-items: center;
  font-size: 9px;
  font-weight: 600;
  color: #374151;
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 20px;
  padding: 1px 6px;
  white-space: nowrap;
}

.pc-badge {
  display: inline-flex;
  align-items: center;
  font-size: 9px;
  font-weight: 600;
  padding: 1px 5px;
  border-radius: 20px;
  background: #f3f4f6;
  color: #374151;
  white-space: nowrap;
}

.pc-badge--sale {
  background: #fee2e2;
  color: #dc2626;
}

/* Gender badge (clothing/shoes) */
.pc-badge--gender {
  background: #ede9fe;
  color: #6d28d9;
}

/* ── Color swatch ────────────────────────────────────────────────── */
.pc-swatch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 9px;
  font-weight: 600;
  color: #374151;
  white-space: nowrap;
}

.pc-swatch__dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4);
  flex-shrink: 0;
}

.pc-swatch__label {
  text-transform: capitalize;
}

/* ── Condition badge (electronics) — colour-coded ────────────────── */
.pc-cond--new          { background: #dcfce7; color: #16a34a; }
.pc-cond--like-new     { background: #ccfbf1; color: #0d9488; }
.pc-cond--good         { background: #fef3c7; color: #d97706; }
.pc-cond--fair         { background: #ffedd5; color: #ea580c; }
.pc-cond--refurbished  { background: #dbeafe; color: #2563eb; }

/* ── Location line (travel) ──────────────────────────────────────── */
.pc-card__location {
  font-size: 10px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Brand line (electronics) ────────────────────────────────────── */
.pc-card__brand {
  font-size: 10px;
  font-weight: 600;
  color: #374151;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── "from" prefix on travel price ───────────────────────────────── */
.pc-price-from {
  font-size: 9px;
  font-weight: 600;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-right: 2px;
}

/* ── Dates ──────────────────────────────────────────────────────── */
.pc-dates {
  font-size: 10px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Footer (price + button) ─────────────────────────────────────── */
.pc-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 2px;
  gap: 6px;
}

.pc-price-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
  flex-wrap: wrap;
}

.pc-price {
  font-size: 13px;
  font-weight: 800;
  color: #111827;
}

.pc-price--sale {
  color: #dc2626;
}

.pc-price--original {
  font-size: 10px;
  font-weight: 400;
  color: #9ca3af;
  text-decoration: line-through;
}

.pc-discount-pill {
  font-size: 9px;
  font-weight: 700;
  color: #dc2626;
  background: #fee2e2;
  border-radius: 20px;
  padding: 1px 5px;
  white-space: nowrap;
}

/* ── CTA button ──────────────────────────────────────────────────── */
.pc-btn {
  /* Both buttons share these metrics so "Get Started" and "WhatsApp" render
     the exact same size regardless of label length. */
  flex: 0 0 auto;
  box-sizing: border-box;
  min-width: 96px;
  height: 28px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: var(--user-message-color, #7c3aed);
  color: var(--user-font-color, #fff);
  border: none;
  border-radius: 0;           /* square buttons to match the square card */
  font-size: 10px;
  font-weight: 700;
  font-family: inherit;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.15s ease;
}

.pc-btn:hover {
  opacity: 0.85;
}

/* Gift-card action row: Get Started + WhatsApp side by side */
.pc-card__actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* Green WhatsApp click-to-chat button — inherits .pc-btn sizing above */
.pc-btn--whatsapp {
  background: #25d366;
  color: #fff;
  text-decoration: none;
}

.pc-btn--whatsapp:hover {
  background: #1ebe57;
  opacity: 1;
}

.pc-btn__wa-icon {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* ── Travel card — slightly taller image ─────────────────────────── */
.pc-card--travel .pc-card__img-wrap {
  width: 90px;
  min-width: 90px;
  height: 90px;
}

/* ── Trending product on start screen ───────────────────────────── */
.trending-product-wrap {
  width: 100%;
  padding: 16px 0 0;
  box-sizing: border-box;
}

.trending-product-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--user-message-color, #7c3aed);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.trending-product-label::before {
  content: "🔥";
  font-size: 13px;
}

/* Short viewports: shrink the trending card so the start screen fits */
@media (max-height: 640px) {
  .trending-product-wrap {
    padding-top: 6px;
  }

  .pc-card--travel .pc-card__img-wrap {
    width: 76px;
    min-width: 76px;
    height: 76px;
  }

  .pc-card__body {
    padding: 6px 8px;
    gap: 2px;
  }
}

/* The section label already says "Trending Today" — keep the card image clean */
.trending-product-card .pc-trending-badge {
  display: none;
}

.trending-product-card .product-cards-row {
  margin: 0;
}

.trending-product-card .pc-card {
  max-width: 100%;
  width: 100%;
}
