/* Modal Upsell - Mobile First */

/* Backdrop */
.upsell-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.upsell-modal[aria-hidden="false"] {
  display: flex;
}

.upsell-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

/* Dialog */
.upsell-dialog {
  position: relative;
  background: #fff;
  border-radius: 12px;
  padding: 2rem 1.5rem;
  max-width: 500px;
  width: 100%;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
              0 10px 10px -5px rgba(0, 0, 0, 0.04);
  z-index: 1001;
  text-align: center;
  animation: slideUp 0.3s ease-out;
}

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

/* Close button */
.upsell-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: transparent;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: #6b7280;
  cursor: pointer;
  padding: 0.25rem;
  transition: color 0.2s ease;
}

.upsell-close:hover {
  color: #111827;
}

.upsell-close:focus {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Title */
.upsell-title {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  color: #111827;
  margin: 0 0 1.5rem 0;
  padding-right: 1.5rem;
}

/* Buy button */
.upsell-buy {
  background: #ff3200;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 1rem 2.5rem;
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.025em;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 6px -1px rgba(239, 68, 68, 0.3);
  width: 100%;
}

.upsell-buy:hover {
  background: #d92c00;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px -2px rgba(239, 68, 68, 0.4);
}

.upsell-buy:active {
  transform: translateY(0);
}

.upsell-buy:focus {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

/* Tablet */
@media (min-width: 640px) {
  .upsell-dialog {
    max-width: 420px;
    padding: 2rem 1.75rem;
  }

  .upsell-title {
    font-size: 1.375rem;
  }

  .upsell-buy {
    width: auto;
    min-width: 180px;
    padding: 0.875rem 2rem;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .upsell-dialog {
    max-width: 400px;
    padding: 2rem 1.75rem;
  }

  .upsell-title {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
  }

  .upsell-buy {
    font-size: 1rem;
    padding: 0.875rem 2rem;
  }

  .upsell-close {
    font-size: 1.5rem;
  }
}

/* Prevent body scroll when modal is open */
body.modal-open {
  overflow: hidden;
}