.spn-popup {
  position: fixed;
  bottom: 20px;
  left: 20px;
  background-color: var(--spn-background-color, #fff);
  color: var(--spn-text-color, #333);
  padding: 15px;
  border-radius: var(--spn-border-radius, 8px);
  box-shadow: 0 4px 20px var(--spn-shadow-color, rgba(0, 0, 0, 0.15));
  z-index: 9999;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue",
    sans-serif;
  max-width: 350px;
  width: calc(100% - 40px);
  box-sizing: border-box;
  transition: all 0.3s ease;
  touch-action: pan-y;
  animation: fadeInUp 0.3s ease-out;
  background: linear-gradient(to bottom, var(--spn-background-color, #ffffff), #f8f9fa);
}

/* Position variations */
.spn-popup.top-left {
  top: 20px;
  bottom: auto;
  left: 20px;
  right: auto;
  animation: fadeInDown 0.3s ease-out;
}

.spn-popup.top-right {
  top: 20px;
  bottom: auto;
  right: 20px;
  left: auto;
  animation: fadeInDown 0.3s ease-out;
}

.spn-popup.bottom-right {
  bottom: 20px;
  top: auto;
  right: 20px;
  left: auto;
  animation: fadeInUp 0.3s ease-out;
}

.spn-popup.bottom-left {
  bottom: 20px;
  top: auto;
  left: 20px;
  right: auto;
  animation: fadeInUp 0.3s ease-out;
}

.spn-popup-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.spn-popup-content {
  display: flex;
  align-items: center;
}

.spn-popup-img {
  width: 70px;
  height: 70px;
  min-width: 70px;
  margin-right: 15px;
  border-radius: calc(var(--spn-border-radius, 8px) - 2px);
  object-fit: cover;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  background-color: #f0f0f0;
}

.spn-popup-text {
  font-size: 14px;
  line-height: 1.5;
  flex-grow: 1;
  overflow: hidden;
}

.spn-popup-text p {
  margin: 0 0 4px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.spn-buyer {
  font-weight: 600;
  color: var(--spn-text-color, #2c3e50);
}

.spn-product {
  font-weight: 500;
  color: var(--spn-text-color, #34495e);
}

.spn-time {
  font-size: 12px;
  color: #7f8c8d;
}

.spn-verified {
  color: var(--spn-verified-color, #3498db);
  font-weight: 600;
  margin-left: 5px;
}

.spn-verified.real-order {
  color: var(--spn-real-verified-color, #27ae60);
}

/* Watermark for free version */
.spn-watermark {
  position: absolute;
  bottom: 5px;
  right: 10px;
  font-size: 10px;
  opacity: 0.7;
  text-align: right;
}

.spn-watermark a {
  color: #7f8c8d;
  text-decoration: none;
  font-weight: 500;
}

.spn-watermark a:hover {
  color: #3498db;
  text-decoration: underline;
}

@media screen and (max-width: 480px) {
  .spn-popup {
    left: 10px;
    right: 10px;
    width: calc(100% - 20px);
    max-width: none;
    padding: 12px;
  }

  .spn-popup.top-left,
  .spn-popup.bottom-left {
    left: 10px;
  }

  .spn-popup.top-right,
  .spn-popup.bottom-right {
    right: 10px;
  }

  .spn-popup-img {
    width: 60px;
    height: 60px;
    min-width: 60px;
    margin-right: 12px;
  }

  .spn-popup-text {
    font-size: 13px;
  }

  .spn-time {
    font-size: 11px;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translate3d(0, 20px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translate3d(0, -20px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

.spn-popup:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 40px var(--spn-shadow-color, rgba(0, 0, 0, 0.15));
}
