/* 
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme-child/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 2.0.0
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/* Add your custom styles here */
/* ====== Cadre de la box paiement ====== */
#payment .payment_box {
  background: #F7F7FB;
  border: 1px solid #E7E7F0;
  border-radius: 14px;
  box-shadow: 0 2px 8px rgba(20,20,40,.05);
  padding: 16px;
}

/* ====== Grille des champs carte ====== */
/* PayPal (PPCP), Stripe & Braintree: on vise large via plusieurs sélecteurs  */
.payment_method_ppcp-credit-card-gateway .wc-credit-card-form,
.payment_method_stripe .wc-credit-card-form,
.payment_method_braintree_cc .wc-credit-card-form,
.woocommerce-checkout .wc-credit-card-form {
  display: grid !important;
  grid-template-columns: 1.25fr 0.9fr 0.8fr; /* numéro | date | cvc */
  gap: 14px;
  align-items: start;
}
.woocommerce-checkout .wc-credit-card-form .form-row {
  margin: 0 !important;
}

/* ====== Label ====== */
.woocommerce-checkout .wc-credit-card-form label {
  display: block;
  font-weight: 600;
  font-size: 13px;
  color: #4B5563;
  margin: 0 0 6px;
}

/* ====== “Cartes hébergées” — style des conteneurs des iframes ====== */
.wc-credit-card-form .wc-stripe-elements-field,
.wc-credit-card-form .StripeElement,
.wc-credit-card-form .braintree-hosted-field,
.wc-credit-card-form .ppcp-hosted-field,
.wc-credit-card-form .input-text { /* fallback */
  padding: 12px 14px !important;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  line-height: 1.25;
  min-height: 44px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
  transition: border-color .2s, box-shadow .2s, background .2s;
}

/* Focus (les plugins ajoutent souvent une classe “focused” sur le wrapper) */
.wc-credit-card-form .is-focused,
.wc-credit-card-form .braintree-hosted-fields-focused,
.wc-credit-card-form .ppcp-hosted-field.is-focused,
.wc-credit-card-form .StripeElement--focus {
  border-color: #4F46E5 !important;
  box-shadow: 0 0 0 4px rgba(79,70,229,.15) !important;
}

/* Erreur / invalide */
.wc-credit-card-form .is-invalid,
.wc-credit-card-form .braintree-hosted-fields-invalid,
.wc-credit-card-form .ppcp-hosted-field.is-invalid,
.wc-credit-card-form .StripeElement--invalid {
  border-color: #DC2626 !important;
  box-shadow: 0 0 0 3px rgba(220,38,38,.12) !important;
}

/* Placeholder (si le plugin remonte la couleur du placeholder) */
.wc-credit-card-form ::placeholder { color: #9CA3AF; }

/* Checkbox “Enregistrer la carte” */
.woocommerce-checkout .wc-payment-form .save_payment_method,
.woocommerce-checkout .wc-payment-form .wc-payment-token {
  margin-top: 10px;
  color: #6B7280;
  font-size: 14px;
}

/* Bandeau fin sous les champs (certains plugins) */
.wc-payment-form .wc-stripe-error, 
.woocommerce-error, 
.wc-stripe-card-icons {
  color: #DC2626;
  margin-top: 6px;
  font-size: 13px;
}

/* ====== Bouton Commander ====== */
.woocommerce-checkout #place_order {
  border-radius: 12px !important;
  padding: 12px 20px !important;
  font-weight: 700;
  letter-spacing: .2px;
  box-shadow: 0 8px 18px rgba(17,24,39,.12);
  transform: translateZ(0); /* lissage */
}
.woocommerce-checkout #place_order:hover {
  transform: translateY(-1px);
}

/* ====== Responsive ====== */
@media (max-width: 768px) {
  .payment_method_ppcp-credit-card-gateway .wc-credit-card-form,
  .payment_method_stripe .wc-credit-card-form,
  .payment_method_braintree_cc .wc-credit-card-form,
  .woocommerce-checkout .wc-credit-card-form {
    grid-template-columns: 1fr; /* empilé sur mobile */
    gap: 10px;
  }
}
