/**
 * BG-Parfum Recent Sales Popup - Boutique Front-end Styles
 * Tailored for BG-Parfum.com (#b89569 champagne gold, #9b1c2e bordeaux)
 */

:root {
  --bgp-popup-bg: #ffffff;
  --bgp-popup-text: #26221f;
  --bgp-popup-muted: #6e6760;
  --bgp-popup-gold: #b89569;
  --bgp-popup-bordeaux: #9b1c2e;
  --bgp-popup-border: #e8e0d5;
  --bgp-popup-shadow: 0 12px 32px rgba(38, 34, 31, 0.14), 0 2px 8px rgba(38, 34, 31, 0.06);
  --bgp-popup-radius: 14px;
}

.bgp-sales-popup {
  position: fixed;
  z-index: 99980;
  max-width: 380px;
  width: auto;
  min-width: 290px;
  background: var(--bgp-popup-bg);
  border: 1px solid var(--bgp-popup-border);
  border-left: 3.5px solid var(--bgp-popup-gold);
  border-radius: var(--bgp-popup-radius);
  box-shadow: var(--bgp-popup-shadow);
  padding: 12px 14px;
  box-sizing: border-box;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(30px);
  opacity: 0;
  pointer-events: none;
  font-family: inherit;
  line-height: 1.35;
}

.bgp-sales-popup.bgp-pos-bottom-left {
  bottom: 24px;
  left: 24px;
}

.bgp-sales-popup.bgp-pos-bottom-right {
  bottom: 24px;
  right: 24px;
}

.bgp-sales-popup.bgp-pos-top-left {
  top: 24px;
  left: 24px;
}

.bgp-sales-popup.bgp-pos-top-right {
  top: 24px;
  right: 24px;
}

.bgp-sales-popup.bgp-show {
  transform: translateY(0) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.bgp-popup-inner {
  position: relative;
  width: 100%;
}

.bgp-popup-close {
  position: absolute;
  top: -6px;
  right: -4px;
  background: transparent;
  border: none;
  font-size: 18px;
  line-height: 1;
  color: #9b938a;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 50%;
  transition: color 0.2s, background 0.2s;
  z-index: 2;
}

.bgp-popup-close:hover {
  color: var(--bgp-popup-text);
  background: #f6f1ea;
}

.bgp-popup-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none !important;
  color: inherit !important;
}

.bgp-popup-img-wrap {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border-radius: 10px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid #ede5da;
  padding: 4px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bgp-popup-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.bgp-popup-content {
  flex-grow: 1;
  min-width: 0;
  padding-right: 16px;
}

.bgp-popup-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}

.bgp-popup-city {
  font-size: 12px;
  font-weight: 600;
  color: var(--bgp-popup-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bgp-popup-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--bgp-popup-gold);
  flex-shrink: 0;
}

.bgp-popup-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--bgp-popup-text);
  margin: 2px 0 4px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 235px;
  transition: color 0.16s ease;
}

.bgp-popup-link:hover .bgp-popup-title {
  color: var(--bgp-popup-gold);
}

.bgp-popup-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}

.bgp-popup-price {
  font-weight: 700;
  color: var(--bgp-popup-bordeaux);
}

.bgp-popup-time {
  color: var(--bgp-popup-muted);
  font-size: 11px;
}

@media (max-width: 767px) {
  .bgp-sales-popup {
    max-width: calc(100% - 28px);
    min-width: 0;
    width: calc(100% - 28px);
    left: 14px !important;
    right: 14px !important;
    bottom: 14px !important;
    padding: 10px 12px;
  }

  .bgp-popup-img-wrap {
    width: 54px;
    height: 54px;
  }

  .bgp-popup-title {
    max-width: 100%;
    font-size: 12.5px;
  }

  .bgp-popup-meta {
    font-size: 11.5px;
  }
}
