/* ================================================================
   SoloStocks — WhatsApp OTP v2.1
   Styles uniquement pour les blocs OTP/WhatsApp
   (styles interface compte supprimés — thème natif conservé)
   ================================================================ */

/* ================================================================
   FORMULAIRE OTP — INSCRIPTION & MODIFICATION
   ================================================================ */

.swoa-wrapper { margin-bottom: 8px; }

.swoa-phone-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
  width: 100%;
}
.swoa-phone-row .woocommerce-Input { flex: 1; min-width: 0; }

/* ── Bouton "Envoyer le code" ── */
.swoa-send-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 20px;
  min-height: 46px;
  min-width: 155px;
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: #fff !important;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.3px;
  border: none !important;
  border-radius: 8px !important;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  box-shadow: 0 3px 10px rgba(37, 211, 102, 0.32);
  transition: transform 0.2s cubic-bezier(.4,0,.2,1), box-shadow 0.2s cubic-bezier(.4,0,.2,1);
  -webkit-tap-highlight-color: transparent;
}

.swoa-send-btn .swoa-icon {
  width: 18px;
  height: 18px;
  fill: #fff;
  flex-shrink: 0;
  transition: transform 0.2s cubic-bezier(.4,0,.2,1);
}

.swoa-send-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.42);
}
.swoa-send-btn:hover:not(:disabled) .swoa-icon {
  transform: scale(1.15) rotate(-5deg);
}
.swoa-send-btn:active:not(:disabled) { transform: scale(0.97); }
.swoa-send-btn:disabled {
  background: #b0bec5 !important;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}
.swoa-send-btn:focus-visible {
  outline: 3px solid rgba(37, 211, 102, 0.45);
  outline-offset: 2px;
}

/* ── Messages de statut ── */
.swoa-status {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 7px;
  font-size: 13px;
  min-height: 18px;
  opacity: 0;
  transform: translateY(-3px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.swoa-status:not(:empty) { opacity: 1; transform: translateY(0); }
.swoa-status--success { color: #1b8a4e; font-weight: 500; }
.swoa-status--error   { color: #c0392b; font-weight: 500; }

/* ── Badge "Numéro vérifié" ── */
.swoa-verified-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #e8f8ef;
  color: #1b8a4e;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  margin-top: 6px;
  animation: swoa-pop 0.3s cubic-bezier(.34, 1.56, .64, 1) both;
}

/* ── Champ OTP ── */
.swoa-otp-row {
  animation: swoa-slide-in 0.3s cubic-bezier(.34, 1.56, .64, 1) both;
}
@keyframes swoa-slide-in {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes swoa-pop {
  from { opacity: 0; transform: scale(0.8); }
  to   { opacity: 1; transform: scale(1); }
}

.swoa-otp-input {
  letter-spacing: 10px !important;
  font-size: 22px !important;
  font-weight: 700 !important;
  text-align: center !important;
  max-width: 220px;
}

/* ── Lien "Renvoyer" ── */
.swoa-resend-wrap {
  display: block;
  margin-top: 6px;
  font-size: 12.5px;
  color: #666;
}
.swoa-resend-wrap a {
  color: #128C7E;
  font-weight: 600;
  border-bottom: 1px dashed #128C7E;
  text-decoration: none;
  transition: color 0.2s ease;
}
.swoa-resend-wrap a:hover { color: #25D366; }

/* ================================================================
   BLOC WHATSAPP — PAGE "DÉTAILS DU COMPTE"
   ================================================================ */

.swoa-account-fieldset {
  border: 1.5px solid #d0e4f0;
  border-radius: 10px;
  padding: 22px 26px;
  margin: 24px 0;
  background: #f7fbfd;
}

.swoa-account-fieldset legend {
  font-size: 15px;
  font-weight: 700;
  padding: 0 8px;
}

.swoa-current-phone {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px !important;
  font-size: 15px;
}

.swoa-current-phone strong {
  background: #e0f0f8;
  padding: 4px 12px;
  border-radius: 20px;
  letter-spacing: 0.5px;
}

.swoa-wa-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  background: #e8fdf0;
  border-radius: 50%;
  text-decoration: none !important;
  transition: background 0.2s ease, transform 0.2s ease;
}
.swoa-wa-link:hover { background: #25D366; transform: scale(1.1); }
.swoa-wa-link:hover svg { fill: #fff !important; }

.swoa-change-toggle { margin: 6px 0 0 !important; }
.swoa-change-toggle a { font-size: 13px; font-weight: 500; text-decoration: underline dashed !important; }

.swoa-no-phone { font-size: 13px; color: #888; font-style: italic; margin-bottom: 14px !important; }

/* ── Responsive ── */
@media (max-width: 480px) {
  .swoa-phone-row     { flex-direction: column; }
  .swoa-send-btn      { width: 100%; min-height: 48px; }
  .swoa-otp-input     { max-width: 100% !important; }
  .swoa-current-phone { flex-direction: column; align-items: flex-start; }
  .swoa-account-fieldset { padding: 16px 14px; }
}
