:host,
:host *,
:host *::before,
:host *::after {
  box-sizing: border-box;
}
:host {
  all: initial;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Ubuntu, sans-serif;
  color: #0a2540;
  -webkit-font-smoothing: antialiased;
}

/* Bouton déclencheur style Stripe */
.slickpay-trigger-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--sp-brand, #635bff);
  color: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  padding: 11px 20px;
  border-radius: 6px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(50, 50, 93, 0.1), 0 1px 1px rgba(0, 0, 0, 0.07);
  transition: background-color 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease, filter 0.15s ease;
}
.slickpay-trigger-btn:hover {
  filter: brightness(0.92);
  box-shadow: 0 4px 11px rgba(50, 50, 93, 0.18), 0 1px 3px rgba(0, 0, 0, 0.08);
}
.slickpay-trigger-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Overlay minimaliste */
.sp-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 37, 64, 0.42);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999999;
  padding: 16px;
}

/* Carte modale style Stripe Payment Element */
.sp-modal {
  background: #ffffff;
  color: #0a2540;
  width: 100%;
  max-width: 440px;
  border-radius: 12px;
  border: 1px solid #e6ebf1;
  box-shadow: 0 30px 60px -12px rgba(50, 50, 93, 0.25), 0 18px 36px -18px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* En-tête épuré blanc */
.sp-header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid #f0f3f7;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}
.sp-merchant-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sp-merchant-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #697386;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.sp-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--sp-brand, #635bff);
}
.sp-amount-hero {
  font-size: 24px;
  font-weight: 700;
  color: #0a2540;
  letter-spacing: -0.02em;
  margin: 2px 0 0;
}
.sp-product-sub {
  font-size: 13px;
  color: #697386;
  margin: 0;
}
.sp-close {
  background: transparent;
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 15px;
  color: #8792a2;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
}
.sp-close:hover {
  background: #f6f9fc;
  color: #0a2540;
}

/* Barre de progression multi-étapes (Stepper Stripe) */
.sp-steps-bar {
  display: flex;
  align-items: center;
  padding: 12px 24px;
  background: #f6f9fc;
  border-bottom: 1px solid #e6ebf1;
  gap: 8px;
}
.sp-step-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #8792a2;
}
.sp-step-item.active {
  color: #0a2540;
  font-weight: 600;
}
.sp-step-item.done {
  color: var(--sp-brand, #635bff);
}
.sp-step-num {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e3e8ee;
  color: #697386;
}
.sp-step-item.active .sp-step-num {
  background: #0a2540;
  color: #ffffff;
}
.sp-step-item.done .sp-step-num {
  background: var(--sp-brand, #635bff);
  color: #ffffff;
}
.sp-step-sep {
  flex: 1;
  height: 1px;
  background: #e3e8ee;
  min-width: 12px;
}

/* Corps de l'étape active (aéré, max 2-3 champs par étape) */
.sp-body {
  padding: 24px;
}
.sp-step-title {
  font-size: 14px;
  font-weight: 600;
  color: #0a2540;
  margin: 0 0 16px;
}

/* Sélecteur de quantité discret */
.sp-qty-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: #f6f9fc;
  border: 1px solid #e3e8ee;
  border-radius: 6px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #3c4257;
}
.sp-stepper {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sp-stepper button {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  border: 1px solid #d8dee4;
  background: #ffffff;
  color: #0a2540;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
}
.sp-stepper button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}
.sp-stepper output {
  font-weight: 600;
  font-size: 13px;
  min-width: 16px;
  text-align: center;
}

/* Champs de formulaire style Stripe Input */
.sp-field {
  margin-bottom: 14px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.sp-field label {
  font-size: 12px;
  font-weight: 500;
  color: #3c4257;
  margin-bottom: 6px;
}
.sp-field input,
.sp-field select {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid #e3e8ee;
  border-radius: 6px;
  font-size: 14px;
  color: #0a2540;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.sp-field input::placeholder {
  color: #a3acb9;
}
.sp-field input:focus,
.sp-field select:focus {
  border-color: var(--sp-brand, #635bff);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03), 0 0 0 3px rgba(99, 91, 255, 0.16);
}

.sp-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 440px) {
  .sp-grid-2 {
    grid-template-columns: 1fr;
  }
}

/* Récapitulatif épuré (Étape finale) */
.sp-summary-card {
  background: #f6f9fc;
  border: 1px solid #e3e8ee;
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 18px;
}
.sp-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: #697386;
  padding: 5px 0;
}
.sp-summary-row strong {
  color: #0a2540;
  font-weight: 600;
}
.sp-summary-row code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  background: #ffffff;
  border: 1px solid #e3e8ee;
  padding: 2px 6px;
  border-radius: 4px;
  color: #0a2540;
}
.sp-summary-row.sp-total {
  border-top: 1px solid #e3e8ee;
  margin-top: 8px;
  padding-top: 10px;
  font-size: 14px;
  color: #0a2540;
  font-weight: 600;
}

/* Badge de statut discret */
.sp-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
  font-weight: 600;
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}
.sp-reserve-note {
  font-size: 12px;
  color: #697386;
  margin: 0 0 14px;
}

/* Boutons d'action navigation multi-étapes */
.sp-actions-row {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}
.sp-btn-primary {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-sizing: border-box;
  text-align: center;
  text-decoration: none;
  background: var(--sp-brand, #635bff);
  color: #ffffff;
  border: none;
  padding: 11px 16px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(50, 50, 93, 0.1), 0 1px 1px rgba(0, 0, 0, 0.07);
  transition: filter 0.15s ease;
}
.sp-btn-primary:hover {
  filter: brightness(0.92);
}
.sp-btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.sp-btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  color: #3c4257;
  border: 1px solid #d8dee4;
  padding: 11px 14px;
  border-radius: 6px;
  font-weight: 500;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03);
  transition: background-color 0.15s ease;
}
.sp-btn-secondary:hover {
  background: #f6f9fc;
}

.sp-error {
  background: #fff5f5;
  color: #cd3d64;
  border: 1px solid #fbd5e0;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 12px;
  margin-bottom: 12px;
}

/* Pied de modale sobre style Stripe */
.sp-footer {
  padding: 12px 24px;
  background: #f6f9fc;
  border-top: 1px solid #e6ebf1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: #8792a2;
}
.sp-footer a {
  color: #697386;
  text-decoration: none;
  font-weight: 500;
}
.sp-footer a:hover {
  color: #0a2540;
  text-decoration: underline;
}
