/* Energy Fit Mercado Pago Checkout PRODUCCIÓN */
#payment ul.payment_methods li.payment_method_efmp_checkout,
#payment ul.payment_methods li.payment_method_efmp_checkout .payment_box,
#payment ul.payment_methods li.payment_method_efmp_checkout .efmp-checkout {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}

#payment ul.payment_methods li.payment_method_efmp_checkout {
  padding: 0 !important;
}

/* El tema marca el gateway elegido con un borde rojo. Este gateway usa su propio
   selector interno, por eso el contenedor exterior debe permanecer invisible. */
.sc-payment-panel #payment ul.payment_methods > li.wc_payment_method.payment_method_efmp_checkout,
.sc-payment-panel #payment ul.payment_methods > li.wc_payment_method.payment_method_efmp_checkout:has(> input[type="radio"]:checked),
.sc-payment-panel #payment ul.payment_methods > li.wc_payment_method.payment_method_efmp_checkout.sc-shipping-selected,
.woocommerce-checkout .sc-payment-panel #payment ul.payment_methods > li.payment_method_efmp_checkout {
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.sc-payment-panel #payment ul.payment_methods > li.payment_method_efmp_checkout .payment_box,
.woocommerce-checkout .sc-payment-panel #payment ul.payment_methods > li.payment_method_efmp_checkout .payment_box {
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

#payment ul.payment_methods li.payment_method_efmp_checkout > input.input-radio,
#payment ul.payment_methods li.payment_method_efmp_checkout > label {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

#payment ul.payment_methods li.payment_method_efmp_checkout .payment_box {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  color: #111 !important;
}

#payment ul.payment_methods li.payment_method_efmp_checkout .payment_box::before {
  display: none !important;
}

.efmp-checkout {
  --efmp-red: #ba181c;
  --efmp-border: #dedede;
  --efmp-muted: #717171;
  --efmp-red-soft: #fff5f5;
  width: 100%;
  color: #111;
  font-family: var(--font-body, "Lexend", Arial, sans-serif) !important;
}

.efmp-checkout *,
.efmp-checkout *::before,
.efmp-checkout *::after {
  box-sizing: border-box;
}

.efmp-test-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 14px;
  padding: 9px 12px;
  border: 1px solid #f0c36a;
  border-radius: 7px;
  background: #fff9ec;
  color: #6d4b00;
  font-size: 12px;
  line-height: 1.35;
}

.efmp-test-banner strong {
  display: inline-flex;
  padding: 3px 7px;
  border-radius: 4px;
  background: #f0a000;
  color: #fff;
  font-size: 10px;
  letter-spacing: .4px;
  text-transform: uppercase;
}

.efmp-methods {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.efmp-method {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto minmax(105px, auto);
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 76px;
  padding: 11px 14px;
  border: 1px solid var(--efmp-border) !important;
  border-radius: 8px;
  outline: 0 !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #111;
  font-family: inherit !important;
  text-align: left;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease;
}

.efmp-method:hover {
  border-color: var(--efmp-red) !important;
  background: #fffafa !important;
}

.efmp-method.is-selected {
  border-color: var(--efmp-red) !important;
  background: var(--efmp-red-soft) !important;
  box-shadow: 0 0 0 1px rgba(186, 24, 28, .08) !important;
}

.efmp-method:disabled {
  opacity: .65;
  cursor: wait;
}

.efmp-method-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border: 1px solid #dedede;
  border-radius: 6px;
  background: #fff;
  color: var(--efmp-red);
}

.efmp-method-icon svg {
  width: 25px;
  height: 25px;
}

.efmp-method-icon--wallet {
  padding: 3px;
  overflow: hidden;
}

.efmp-mp-logo {
  display: block;
  width: 100%;
  height: 100%;
  margin: auto;
  object-fit: contain;
  object-position: 50% 50%;
  transform: scale(.94);
}

.efmp-card-slot {
  display: block;
  width: 100%;
}

.efmp-card-slot:empty {
  display: none;
}

.efmp-method-copy {
  min-width: 0;
}

.efmp-method-copy strong,
.efmp-method-copy small {
  display: block;
  font-family: inherit !important;
}

.efmp-method-copy strong {
  color: #111;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
}

.efmp-method-copy small {
  margin-top: 3px;
  color: var(--efmp-muted);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.3;
}

.efmp-method-badge {
  color: var(--efmp-red);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
  text-transform: uppercase;
}

.efmp-method-price {
  min-width: 105px;
  color: #111;
  font-size: 15px;
  font-weight: 800;
  text-align: right;
  white-space: nowrap;
}

.efmp-method-price .woocommerce-Price-amount {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

/* Formulario de tarjeta personalizado con MercadoPago.js/CardForm. */
.efmp-card-area {
  display: none;
  width: 100%;
  margin: 0;
  padding: 18px 0 8px;
  border: 0 !important;
  border-radius: 0 !important;
  outline: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.efmp-card-area.is-visible {
  display: block;
}

.efmp-card-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  width: 100%;
  padding: 0;
  background: transparent;
  font-family: Arial, Helvetica, sans-serif !important;
}

.efmp-input-shell,
.efmp-installments-field {
  position: relative;
  width: 100%;
  min-width: 0;
  height: 48px;
  border: 1px solid #d8d8d8;
  border-radius: 6px;
  background: #fff;
  box-shadow: none;
  transition: border-color .16s ease, box-shadow .16s ease;
}

.efmp-input-shell:focus-within,
.efmp-installments-field:focus-within {
  border-color: #bdbdbd;
  box-shadow: none;
}

.efmp-card-two-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
}

.efmp-secure-field,
.efmp-secure-field > div,
.efmp-secure-field iframe {
  display: block !important;
  width: 100% !important;
  height: 46px !important;
  min-height: 46px !important;
  border: 0 !important;
  outline: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.efmp-input-shell input,
.efmp-installments-field select {
  display: block !important;
  width: 100% !important;
  height: 46px !important;
  min-height: 46px !important;
  margin: 0 !important;
  padding: 0 13px !important;
  border: 0 !important;
  border-radius: 5px !important;
  outline: 0 !important;
  background: transparent !important;
  color: #111 !important;
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 16px !important;
  font-weight: 400 !important;
  line-height: 46px !important;
  box-shadow: none !important;
}

.efmp-input-shell input::placeholder {
  color: #7f7f7f !important;
  opacity: 1 !important;
}

/* Los Secure Fields de Mercado Pago se montan dentro de iframes. El padding
   debe aplicarse al contenedor del iframe para que el texto no quede pegado
   al borde y se alinee con Nombre y DNI. */
.efmp-input-shell--secure {
  padding: 0 13px;
  overflow: hidden;
}

.efmp-input-shell--secure.efmp-input-shell--icon {
  padding-right: 42px;
}

.efmp-input-shell--secure .efmp-secure-field {
  padding: 0 !important;
}

.efmp-field-icon {
  position: absolute;
  top: 50%;
  right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  color: #777;
  pointer-events: none;
  transform: translateY(-50%);
}

.efmp-field-icon svg {
  width: 20px;
  height: 20px;
}

.efmp-installments-field {
  display: none;
}

.efmp-installments-field.is-visible {
  display: block;
}

.efmp-installments-field select {
  appearance: none;
  padding-right: 38px !important;
  background-image: linear-gradient(45deg, transparent 50%, #777 50%), linear-gradient(135deg, #777 50%, transparent 50%) !important;
  background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px !important;
  background-size: 5px 5px, 5px 5px !important;
  background-repeat: no-repeat !important;
  cursor: pointer;
}

.efmp-hidden-card-control {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.efmp-card-loading,
.efmp-card-error {
  margin: 0;
  padding: 4px 2px 0;
  font-family: var(--font-body, "Lexend", Arial, sans-serif) !important;
  font-size: 11px;
  line-height: 1.4;
}

.efmp-card-loading {
  color: #777;
  text-align: left;
}

.efmp-card-error {
  color: var(--efmp-red);
  font-weight: 600;
}

.efmp-security-note {
  margin: 10px 2px 0 !important;
  color: #777 !important;
  font-family: var(--font-body, "Lexend", Arial, sans-serif) !important;
  font-size: 11px !important;
  line-height: 1.45 !important;
}

/* El recargo está incluido en el total financiado, no se expone como renglón aparte. */
tr.efmp-hidden-finance-fee {
  display: none !important;
}

.payment_method_efmp_checkout + .place-order,
#payment .place-order {
  clear: both;
}

@media (max-width: 720px) {
  .efmp-method {
    grid-template-columns: 42px minmax(0, 1fr) auto;
    min-height: 72px;
    padding: 10px;
    gap: 9px;
  }

  .efmp-method-icon {
    width: 40px;
    height: 40px;
  }

  .efmp-method-icon svg {
    width: 23px;
    height: 23px;
  }

  .efmp-method-copy strong {
    font-size: 12.5px;
  }

  .efmp-method-copy small {
    font-size: 10px;
  }

  .efmp-method-badge {
    grid-column: 2;
    font-size: 10.5px;
  }

  .efmp-method-price {
    grid-column: 3;
    grid-row: 1 / span 2;
    min-width: 86px;
    font-size: 13px;
  }

  .efmp-card-area {
    padding: 16px 0 8px;
  }

  .efmp-card-two-columns {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
}

/* Estados internos neutros: sin líneas rojas del tema ni del plugin. */
.efmp-method:focus,
.efmp-method:focus-visible,
.efmp-method:active {
  outline: 0 !important;
  box-shadow: none !important;
}

.efmp-method.is-selected:focus,
.efmp-method.is-selected:focus-visible {
  border-color: var(--efmp-red) !important;
  box-shadow: 0 0 0 1px rgba(186, 24, 28, .08) !important;
}


/* Identidad visual Energy Fit: rojo corporativo en estados, iconos y acción final. */
.efmp-method.is-selected .efmp-method-icon {
  border-color: var(--efmp-red);
  background: #fff;
  color: var(--efmp-red);
}

.efmp-method.is-selected .efmp-method-badge,
.efmp-method-badge {
  color: var(--efmp-red) !important;
}

.woocommerce-checkout #place_order.efmp-place-order-button,
.woocommerce-checkout button#place_order.efmp-place-order-button {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100% !important;
  min-height: 52px;
  border: 0 !important;
  border-radius: 7px !important;
  background: var(--efmp-red, #ba181c) !important;
  color: #fff !important;
  font-family: var(--font-body, "Lexend", Arial, sans-serif) !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  letter-spacing: .15px;
  text-transform: uppercase;
  box-shadow: none !important;
}

.woocommerce-checkout #place_order.efmp-place-order-button:hover:not(:disabled) {
  background: #9f1216 !important;
}

.woocommerce-checkout #place_order.efmp-place-order-button:disabled,
.woocommerce-checkout #place_order.efmp-place-order-button.is-efmp-disabled {
  background: #e3e3e3 !important;
  color: #999 !important;
  cursor: not-allowed !important;
  opacity: 1 !important;
}

/* El aviso legal se incorporará en el primer paso del checkout; no se repite en Pago. */
.woocommerce-checkout .woocommerce-terms-and-conditions-wrapper,
.woocommerce-checkout .woocommerce-privacy-policy-text {
  display: none !important;
}


/* v0.1.9 — uniformidad visual de los campos y separación tipo checkout premium. */
.efmp-card-form > .efmp-input-shell,
.efmp-card-form > .efmp-card-two-columns,
.efmp-card-form > .efmp-installments-field {
  margin: 0 !important;
}

.efmp-card-form .efmp-secure-field,
.efmp-card-form input,
.efmp-card-form select {
  font-synthesis: none;
  letter-spacing: 0 !important;
}

.efmp-card-form .efmp-input-shell:hover,
.efmp-card-form .efmp-installments-field:hover {
  border-color: #bdbdbd;
}

@media (max-width: 520px) {
  .efmp-card-form { gap: 14px; }
  .efmp-card-two-columns { gap: 8px; }
  .efmp-input-shell input,
  .efmp-installments-field select {
    font-size: 15px !important;
  }
}


/* v0.2.2 — foco uniforme. Los Secure Fields de Mercado Pago viven en iframes y
   no transmiten el foco al contenedor igual que los inputs normales. Por eso todos
   los campos mantienen un borde neutro al escribir; el rojo queda reservado para
   la forma de pago seleccionada y los mensajes de error. */
.efmp-card-form .efmp-input-shell:focus-within,
.efmp-card-form .efmp-installments-field:focus-within,
.efmp-card-form .efmp-input-shell:focus,
.efmp-card-form .efmp-installments-field:focus {
  border-color: #bdbdbd !important;
  outline: 0 !important;
  box-shadow: none !important;
}

.efmp-card-form .efmp-input-shell input:focus,
.efmp-card-form .efmp-installments-field select:focus {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}


/* v0.2.3 — cuotas: el selector ya no autoselecciona la primera opción.
   Se muestra como un campo neutro hasta que la persona elige manualmente
   la cantidad de cuotas, más parecido al flujo de Gadnic. */
.efmp-installments-field.is-empty select {
  color: #7f7f7f !important;
}

.efmp-installments-field:not(.is-empty) select {
  color: #111 !important;
}


/* v0.2.4 — selector de cuotas con presentación más parecida a Gadnic.
   El select nativo queda invisible pero funcional, y se muestra una capa visual
   con label + valor/resumen. */
.efmp-installments-field {
  min-height: 60px;
  height: 60px;
  overflow: hidden;
}

.efmp-installments-display {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 10px 42px 10px 14px;
  pointer-events: none;
  z-index: 1;
}

.efmp-installments-display__label {
  font-family: var(--font-body, "Lexend", Arial, sans-serif) !important;
  font-size: 11px;
  line-height: 1.2;
  color: #777;
}

.efmp-installments-display__value {
  font-family: var(--font-body, "Lexend", Arial, sans-serif) !important;
  font-size: 15px;
  line-height: 1.35;
  color: #111;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.efmp-installments-field.is-empty .efmp-installments-display__value {
  color: #038d62;
  font-size: 13px;
  font-weight: 500;
}

.efmp-installments-field.is-selected .efmp-installments-display__value {
  color: #111;
  font-size: 15px;
  font-weight: 500;
}

.efmp-installments-field select {
  position: absolute;
  inset: 0;
  z-index: 2;
  width: 100% !important;
  height: 100% !important;
  opacity: 0 !important;
  cursor: pointer;
}

.efmp-installments-field::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 16px;
  width: 9px;
  height: 9px;
  border-right: 1.8px solid #8a8a8a;
  border-bottom: 1.8px solid #8a8a8a;
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
  z-index: 1;
}

.efmp-installments-field:hover,
.efmp-installments-field:focus-within {
  border-color: #bdbdbd !important;
}

@media (max-width: 520px) {
  .efmp-installments-field {
    min-height: 58px;
    height: 58px;
  }

  .efmp-installments-display {
    padding: 9px 38px 9px 12px;
  }

  .efmp-installments-display__value {
    font-size: 14px;
  }
}

/* v0.4.0 — confirmación, consulta de estado y detalles del pedido. */
body.efmp-order-success .woocommerce-order > .woocommerce-notice,
body.efmp-order-success .woocommerce-order > .woocommerce-order-overview,
body.efmp-order-success .woocommerce-order > ul.order_details {
  display: none !important;
}

body.efmp-order-success .woocommerce-order,
body.efmp-order-view .woocommerce-MyAccount-content,
body.efmp-order-tracking-page .site-main {
  max-width: 1120px;
  margin-right: auto;
  margin-left: auto;
}

.efmp-success-card {
  position: relative;
  width: min(100%, 620px);
  margin: 30px auto 38px;
  padding: 36px 28px 24px;
  overflow: hidden;
  border: 1px solid #e8e8e8;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 16px 44px rgba(24, 24, 24, .09);
  color: #171717;
  font-family: var(--font-body, "Lexend", Arial, sans-serif);
  text-align: center;
}

.efmp-success-confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.efmp-success-confetti i {
  position: absolute;
  width: 5px;
  height: 10px;
  border-radius: 2px;
  background: #15985f;
  opacity: .75;
  transform: rotate(28deg);
}

.efmp-success-confetti i:nth-child(1) { top: 24px; left: 28%; }
.efmp-success-confetti i:nth-child(2) { top: 58px; left: 18%; background: #ba181c; transform: rotate(-42deg); }
.efmp-success-confetti i:nth-child(3) { top: 28px; right: 27%; transform: rotate(58deg); }
.efmp-success-confetti i:nth-child(4) { top: 68px; right: 19%; background: #ba181c; transform: rotate(12deg); }
.efmp-success-confetti i:nth-child(5) { top: 42px; left: 35%; width: 4px; height: 4px; border-radius: 50%; }
.efmp-success-confetti i:nth-child(6) { top: 44px; right: 35%; width: 4px; height: 4px; border-radius: 50%; background: #ba181c; }

.efmp-success-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 66px;
  height: 66px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: #18a766;
  color: #fff;
  box-shadow: 0 9px 25px rgba(24, 167, 102, .25);
}

.efmp-success-icon svg {
  width: 34px;
  height: 34px;
}

.efmp-success-card h1 {
  margin: 0 !important;
  color: #151515 !important;
  font-family: var(--font-title, "Oswald", "Lexend", Arial, sans-serif) !important;
  font-size: clamp(29px, 5vw, 40px) !important;
  font-weight: 800 !important;
  line-height: 1.08 !important;
  letter-spacing: -.5px;
  text-transform: none;
}

.efmp-success-lead {
  margin: 8px 0 18px !important;
  color: #6d6d6d;
  font-size: 13px !important;
  line-height: 1.5 !important;
}

.efmp-order-number-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 190px;
  margin: 0 auto 22px;
  padding: 10px 16px;
  border: 1px solid #d9f0e3;
  border-radius: 10px;
  background: #edf9f2;
  color: #137e50;
  text-align: left;
}

.efmp-chip-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: #d8f2e3;
  font-size: 18px;
}

.efmp-order-number-chip span:last-child,
.efmp-order-number-chip small,
.efmp-order-number-chip strong {
  display: block;
}

.efmp-order-number-chip small {
  color: #5b7869;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.2;
}

.efmp-order-number-chip strong {
  margin-top: 2px;
  color: #118653;
  font-size: 17px;
  line-height: 1.15;
}

.efmp-success-info-list {
  display: grid;
  gap: 10px;
  padding: 18px 0;
  border-top: 1px solid #ededed;
  border-bottom: 1px solid #ededed;
}

.efmp-success-info {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  border-radius: 10px;
  text-align: left;
}

.efmp-success-info--status {
  border: 1px solid #dcefe3;
  background: #f4fbf7;
}

.efmp-success-info--email {
  border: 1px solid #dfe8f6;
  background: #f4f8fe;
}

.efmp-success-info-icon {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  font-size: 19px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, .05);
}

.efmp-success-info strong,
.efmp-success-info small {
  display: block;
}

.efmp-success-info strong {
  color: #242424;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.efmp-success-info small {
  margin-top: 3px;
  color: #6f6f6f;
  font-size: 10px;
  line-height: 1.45;
}

.efmp-success-progress {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 20px 0 8px;
}

.efmp-success-progress::before {
  position: absolute;
  top: 14px;
  right: 16.66%;
  left: 16.66%;
  height: 2px;
  background: #e1e1e1;
  content: "";
}

.efmp-success-progress-step {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 6px;
}

.efmp-success-progress-step i {
  display: grid;
  width: 29px;
  height: 29px;
  place-items: center;
  border: 2px solid #d9d9d9;
  border-radius: 50%;
  background: #fff;
  color: #8a8a8a;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.efmp-success-progress-step small {
  color: #8a8a8a;
  font-size: 9px;
  font-weight: 700;
}

.efmp-success-progress-step.is-active i {
  border-color: #18a766;
  background: #18a766;
  color: #fff;
}

.efmp-success-progress-step.is-active small {
  color: #16794d;
}

.efmp-success-actions-title {
  margin: 22px 0 11px !important;
  color: #222;
  font-size: 11px !important;
  font-weight: 800 !important;
}

.efmp-success-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.efmp-success-actions--single {
  grid-template-columns: minmax(0, 1fr);
}

.efmp-success-action {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  min-height: 72px;
  padding: 11px 12px;
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  background: #fff;
  color: #222 !important;
  text-align: left;
  text-decoration: none !important;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.efmp-success-action:hover {
  border-color: #ba181c;
  box-shadow: 0 7px 18px rgba(186, 24, 28, .10);
  transform: translateY(-1px);
}

.efmp-success-action > span {
  display: grid;
  width: 30px;
  height: 30px;
  grid-row: 1 / span 2;
  place-items: center;
  border-radius: 50%;
  background: #f4f4f4;
  font-size: 16px;
}

.efmp-success-action strong,
.efmp-success-action small {
  display: block;
  grid-column: 2;
}

.efmp-success-action strong {
  align-self: end;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.25;
}

.efmp-success-action small {
  align-self: start;
  color: #787878;
  font-size: 8px;
  line-height: 1.35;
}

.efmp-success-shop-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 19px;
  color: #168855 !important;
  font-size: 11px;
  font-weight: 800;
  text-decoration: none !important;
}

.efmp-success-shop-link:hover {
  color: #ba181c !important;
}

/* Detalles del pedido y direcciones, tanto en gracias como en Mi cuenta. */
body.efmp-order-success .woocommerce-order-details,
body.efmp-order-success .woocommerce-customer-details,
body.efmp-order-view .woocommerce-order-details,
body.efmp-order-view .woocommerce-customer-details {
  width: min(100%, 820px);
  margin: 26px auto 0 !important;
  font-family: var(--font-body, "Lexend", Arial, sans-serif);
}

body.efmp-order-success .woocommerce-order-details__title,
body.efmp-order-success .woocommerce-column__title,
body.efmp-order-view .woocommerce-order-details__title,
body.efmp-order-view .woocommerce-column__title {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 12px !important;
  color: #191919 !important;
  font-family: var(--font-title, "Oswald", "Lexend", Arial, sans-serif) !important;
  font-size: 21px !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
  text-transform: none;
}

body.efmp-order-success .woocommerce-order-details__title::before,
body.efmp-order-view .woocommerce-order-details__title::before {
  content: "📦";
  font-size: 21px;
}

body.efmp-order-success .woocommerce-column--billing-address .woocommerce-column__title::before,
body.efmp-order-view .woocommerce-column--billing-address .woocommerce-column__title::before {
  content: "👤";
  font-size: 21px;
}

body.efmp-order-success .woocommerce-column--shipping-address .woocommerce-column__title::before,
body.efmp-order-view .woocommerce-column--shipping-address .woocommerce-column__title::before {
  content: "🚚";
  font-size: 21px;
}

body.efmp-order-success table.woocommerce-table--order-details,
body.efmp-order-view table.woocommerce-table--order-details {
  overflow: hidden;
  width: 100%;
  border: 1px solid #e5e5e5 !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .045);
}

body.efmp-order-success table.woocommerce-table--order-details th,
body.efmp-order-success table.woocommerce-table--order-details td,
body.efmp-order-view table.woocommerce-table--order-details th,
body.efmp-order-view table.woocommerce-table--order-details td {
  padding: 14px 16px !important;
  border: 0 !important;
  border-bottom: 1px solid #eeeeee !important;
  background: transparent !important;
  color: #303030 !important;
  font-size: 12px !important;
  line-height: 1.5 !important;
  vertical-align: middle !important;
}

body.efmp-order-success table.woocommerce-table--order-details thead th,
body.efmp-order-view table.woocommerce-table--order-details thead th {
  background: #f7f7f7 !important;
  color: #4a4a4a !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  text-transform: uppercase;
}

body.efmp-order-success table.woocommerce-table--order-details tbody a,
body.efmp-order-view table.woocommerce-table--order-details tbody a {
  color: #ba181c !important;
  font-weight: 700;
  text-decoration: none !important;
}

body.efmp-order-success table.woocommerce-table--order-details tbody td:last-child,
body.efmp-order-view table.woocommerce-table--order-details tbody td:last-child {
  width: 34%;
  color: #171717 !important;
  font-weight: 800 !important;
  text-align: right !important;
  white-space: nowrap;
}

body.efmp-order-success table.woocommerce-table--order-details .efmp-order-item-qty,
body.efmp-order-view table.woocommerce-table--order-details .efmp-order-item-qty {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #f7f7f7;
  color: #4a4a4a;
  line-height: 1;
}

body.efmp-order-success table.woocommerce-table--order-details .efmp-order-item-qty small,
body.efmp-order-view table.woocommerce-table--order-details .efmp-order-item-qty small {
  color: #666;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .03em;
  text-transform: uppercase;
}

body.efmp-order-success table.woocommerce-table--order-details .efmp-order-item-qty strong,
body.efmp-order-view table.woocommerce-table--order-details .efmp-order-item-qty strong {
  color: #191919;
  font-size: 12px;
  font-weight: 800;
}

body.efmp-order-success table.woocommerce-table--order-details .product-quantity,
body.efmp-order-view table.woocommerce-table--order-details .product-quantity {
  color: #555;
  font-weight: 800;
}

body.efmp-order-success table.woocommerce-table--order-details tfoot th,
body.efmp-order-view table.woocommerce-table--order-details tfoot th {
  width: 62%;
  color: #5b5b5b !important;
  font-weight: 700 !important;
  text-align: right !important;
}

body.efmp-order-success table.woocommerce-table--order-details tfoot td,
body.efmp-order-view table.woocommerce-table--order-details tfoot td {
  color: #171717 !important;
  font-weight: 800 !important;
  text-align: right !important;
}

body.efmp-order-success table.woocommerce-table--order-details tfoot tr:last-child th,
body.efmp-order-success table.woocommerce-table--order-details tfoot tr:last-child td,
body.efmp-order-view table.woocommerce-table--order-details tfoot tr:last-child th,
body.efmp-order-view table.woocommerce-table--order-details tfoot tr:last-child td {
  border-bottom: 0 !important;
  background: #fff7f7 !important;
  color: #8f1216 !important;
  font-size: 14px !important;
}

body.efmp-order-success .woocommerce-customer-details address,
body.efmp-order-view .woocommerce-customer-details address {
  min-height: 120px;
  padding: 17px 18px !important;
  border: 1px solid #e5e5e5 !important;
  border-radius: 14px !important;
  background: #fff !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .045);
  color: #454545 !important;
  font-size: 12px !important;
  font-style: normal !important;
  line-height: 1.75 !important;
}

body.efmp-order-success .woocommerce-customer-details address p,
body.efmp-order-view .woocommerce-customer-details address p {
  margin: 7px 0 0 !important;
}

body.efmp-order-success .woocommerce-customer-details address a,
body.efmp-order-view .woocommerce-customer-details address a {
  color: #ba181c !important;
  font-weight: 700;
  text-decoration: none !important;
}

/* Estado destacado al abrir Mi cuenta > Pedidos > Ver. */
.efmp-view-status-card {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 14px;
  width: min(100%, 820px);
  margin: 0 auto 24px;
  padding: 19px 20px;
  border: 1px solid #dcefe3;
  border-radius: 14px;
  background: #f4fbf7;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .04);
}

.efmp-view-status-icon {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border-radius: 50%;
  background: #dff4e7;
  font-size: 24px;
}

.efmp-view-status-card small,
.efmp-view-status-card h2,
.efmp-view-status-card p {
  display: block;
  margin: 0 !important;
}

.efmp-view-status-card small {
  color: #52806a;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.efmp-view-status-card h2 {
  margin-top: 3px !important;
  color: #1a1a1a !important;
  font-size: 18px !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
}

.efmp-view-status-card p {
  margin-top: 5px !important;
  color: #5e6f65;
  font-size: 11px !important;
  line-height: 1.5 !important;
}

/* Página estándar para invitados: número de pedido + email de facturación. */
body.efmp-order-tracking-page .woocommerce-form-track-order {
  width: min(100%, 620px);
  margin: 28px auto;
  padding: 26px;
  border: 1px solid #e5e5e5;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .07);
}

body.efmp-order-tracking-page .woocommerce-form-track-order::before {
  display: block;
  margin-bottom: 10px;
  color: #171717;
  content: "📦 Consultá el estado de tu pedido";
  font-size: 21px;
  font-weight: 800;
}

body.efmp-order-tracking-page .woocommerce-form-track-order p:first-child {
  color: #666;
  font-size: 12px;
  line-height: 1.6;
}

body.efmp-order-tracking-page .woocommerce-form-track-order input.input-text {
  min-height: 46px;
  border: 1px solid #d8d8d8;
  border-radius: 8px;
}

body.efmp-order-tracking-page .woocommerce-form-track-order button.button {
  min-height: 46px;
  padding: 0 22px;
  border-radius: 8px;
  background: #ba181c;
  color: #fff;
  font-weight: 800;
}

@media (max-width: 640px) {
  .efmp-success-card {
    margin: 18px auto 28px;
    padding: 28px 14px 21px;
    border-radius: 15px;
  }

  .efmp-success-actions {
    grid-template-columns: 1fr;
  }

  .efmp-success-action {
    min-height: 68px;
  }

  body.efmp-order-success .woocommerce-order-details,
  body.efmp-order-success .woocommerce-customer-details,
  body.efmp-order-view .woocommerce-order-details,
  body.efmp-order-view .woocommerce-customer-details {
    margin-top: 20px !important;
  }

  body.efmp-order-success .woocommerce-order-details__title,
  body.efmp-order-success .woocommerce-column__title,
  body.efmp-order-view .woocommerce-order-details__title,
  body.efmp-order-view .woocommerce-column__title {
    gap: 7px;
    margin-bottom: 10px !important;
    font-size: 16px !important;
  }

  body.efmp-order-success .woocommerce-order-details__title::before,
  body.efmp-order-success .woocommerce-column__title::before,
  body.efmp-order-view .woocommerce-order-details__title::before,
  body.efmp-order-view .woocommerce-column__title::before {
    font-size: 16px;
  }

  body.efmp-order-success table.woocommerce-table--order-details th,
  body.efmp-order-success table.woocommerce-table--order-details td,
  body.efmp-order-view table.woocommerce-table--order-details th,
  body.efmp-order-view table.woocommerce-table--order-details td {
    padding: 10px 12px !important;
    font-size: 10px !important;
  }

  body.efmp-order-success table.woocommerce-table--order-details tbody a,
  body.efmp-order-view table.woocommerce-table--order-details tbody a {
    font-size: 9px !important;
    line-height: 1.45 !important;
  }

  body.efmp-order-success table.woocommerce-table--order-details tbody td:last-child,
  body.efmp-order-view table.woocommerce-table--order-details tbody td:last-child,
  body.efmp-order-success table.woocommerce-table--order-details tfoot td,
  body.efmp-order-view table.woocommerce-table--order-details tfoot td {
    font-size: 9px !important;
  }

  body.efmp-order-success table.woocommerce-table--order-details .efmp-order-item-qty,
  body.efmp-order-view table.woocommerce-table--order-details .efmp-order-item-qty {
    gap: 6px;
    margin-top: 8px;
    padding: 5px 9px;
  }

  body.efmp-order-success table.woocommerce-table--order-details .efmp-order-item-qty small,
  body.efmp-order-view table.woocommerce-table--order-details .efmp-order-item-qty small {
    font-size: 9px;
  }

  body.efmp-order-success table.woocommerce-table--order-details .efmp-order-item-qty strong,
  body.efmp-order-view table.woocommerce-table--order-details .efmp-order-item-qty strong {
    font-size: 11px;
  }

  body.efmp-order-success table.woocommerce-table--order-details tfoot th,
  body.efmp-order-view table.woocommerce-table--order-details tfoot th {
    width: 54%;
    font-size: 10px !important;
  }

  body.efmp-order-success table.woocommerce-table--order-details tfoot tr:last-child th,
  body.efmp-order-success table.woocommerce-table--order-details tfoot tr:last-child td,
  body.efmp-order-view table.woocommerce-table--order-details tfoot tr:last-child th,
  body.efmp-order-view table.woocommerce-table--order-details tfoot tr:last-child td {
    font-size: 11px !important;
  }

  body.efmp-order-success .woocommerce-customer-details address,
  body.efmp-order-view .woocommerce-customer-details address {
    min-height: 0;
    padding: 14px 15px !important;
    font-size: 10px !important;
    line-height: 1.65 !important;
  }

  .efmp-view-status-card {
    grid-template-columns: 42px minmax(0, 1fr);
    padding: 15px;
  }

  .efmp-view-status-icon {
    width: 42px;
    height: 42px;
    font-size: 20px;
  }
}

/* Render personalizado de pedido: producto con foto, columnas separadas y pago aparte. */
body.efmp-order-success .woocommerce-order-details,
body.efmp-order-success .woocommerce-customer-details,
body.efmp-order-view .woocommerce-order-details,
body.efmp-order-view .woocommerce-customer-details {
  display: none !important;
}

.efmp-custom-order-wrap {
  width: min(100%, 920px);
  margin: 24px auto 0;
  font-family: var(--font-body, "Lexend", Arial, sans-serif);
}

.efmp-custom-order-section + .efmp-custom-order-section {
  margin-top: 28px;
}

.efmp-custom-section-title {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 12px !important;
  color: #191919 !important;
  font-family: var(--font-title, "Oswald", "Lexend", Arial, sans-serif) !important;
  font-size: 21px !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

.efmp-custom-order-panel,
.efmp-custom-billing-card {
  border: 1px solid #e5e5e5;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,.045);
}

.efmp-custom-order-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
}

.efmp-custom-order-table thead th {
  padding: 15px 18px;
  border-bottom: 1px solid #eeeeee;
  background: #f7f7f7;
  color: #4a4a4a;
  font-size: 11px;
  font-weight: 800;
  text-align: left;
  text-transform: uppercase;
}

.efmp-custom-order-table thead th:nth-child(2),
.efmp-custom-order-table thead th:nth-child(3),
.efmp-custom-order-table tbody td:nth-child(2),
.efmp-custom-order-table tbody td:nth-child(3) {
  text-align: center;
}

.efmp-custom-order-table tbody td:nth-child(3) {
  text-align: right;
}

.efmp-custom-order-table tbody td {
  padding: 18px;
  border-bottom: 1px solid #eeeeee;
  vertical-align: middle;
}

.efmp-custom-product {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.efmp-custom-product-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border: 1px solid #ededed;
  border-radius: 14px;
  background: #fafafa;
  overflow: hidden;
}

.efmp-custom-product-thumb img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.efmp-custom-product-name {
  color: #ba181c !important;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.45;
  text-decoration: none !important;
}

.efmp-custom-product-meta,
.efmp-custom-product-meta * {
  margin-top: 4px;
  color: #666 !important;
  font-size: 12px !important;
  line-height: 1.45 !important;
}

.efmp-custom-qty-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  background: #f7f7f7;
  color: #4a4a4a;
  line-height: 1;
}

.efmp-custom-qty-badge small {
  color: #666;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .03em;
  text-transform: uppercase;
}

.efmp-custom-qty-badge strong,
.efmp-custom-total-cell {
  color: #171717;
  font-size: 15px;
  font-weight: 800;
}

.efmp-custom-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 16px;
}

.efmp-custom-summary-card {
  padding: 16px;
  border: 1px solid #ededed;
  border-radius: 14px;
  background: #fafafa;
}

.efmp-custom-summary-card--payment {
  background: #fff7f7;
}

.efmp-custom-summary-card h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px !important;
  color: #191919;
  font-size: 16px !important;
  font-weight: 800 !important;
}

.efmp-custom-summary-card ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.efmp-custom-summary-card li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid #e9e9e9;
  color: #4e4e4e;
  font-size: 13px;
}

.efmp-custom-summary-card li:last-child {
  border-bottom: 0;
}

.efmp-custom-summary-card li strong {
  color: #171717;
  font-weight: 800;
  text-align: right;
}

.efmp-custom-summary-card li.is-total span,
.efmp-custom-summary-card--payment li strong {
  color: #8f1216;
}

.efmp-custom-billing-card {
  min-height: 0;
  padding: 18px;
  color: #454545;
  font-size: 13px;
  line-height: 1.75;
}

.efmp-custom-billing-card p {
  margin: 0 0 6px !important;
}

.efmp-custom-billing-card p:last-child {
  margin-bottom: 0 !important;
}

.efmp-custom-billing-name {
  color: #191919;
  font-size: 15px;
  font-weight: 700;
}

.efmp-custom-billing-card a {
  color: #ba181c !important;
  font-weight: 700;
  text-decoration: none !important;
}

@media (max-width: 640px) {
  .efmp-custom-order-wrap {
    margin-top: 20px;
  }

  .efmp-custom-order-section + .efmp-custom-order-section {
    margin-top: 24px;
  }

  .efmp-custom-section-title {
    gap: 7px;
    margin-bottom: 10px !important;
    font-size: 17px !important;
  }

  .efmp-custom-order-panel,
  .efmp-custom-billing-card {
    border-radius: 15px;
  }

  .efmp-custom-order-table thead th,
  .efmp-custom-order-table tbody td {
    padding: 12px 10px;
  }

  .efmp-custom-order-table thead th {
    font-size: 10px;
  }

  .efmp-custom-product {
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 10px;
  }

  .efmp-custom-product-thumb {
    width: 52px;
    height: 52px;
    border-radius: 12px;
  }

  .efmp-custom-product-name {
    font-size: 12px;
    line-height: 1.4;
  }

  .efmp-custom-product-meta,
  .efmp-custom-product-meta * {
    font-size: 10px !important;
  }

  .efmp-custom-qty-badge {
    gap: 5px;
    padding: 5px 8px;
  }

  .efmp-custom-qty-badge small {
    font-size: 8px;
  }

  .efmp-custom-qty-badge strong,
  .efmp-custom-total-cell {
    font-size: 11px;
  }

  .efmp-custom-summary-grid {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px;
  }

  .efmp-custom-summary-card {
    padding: 12px;
  }

  .efmp-custom-summary-card h3 {
    margin-bottom: 10px !important;
    font-size: 14px !important;
  }

  .efmp-custom-summary-card li {
    padding: 7px 0;
    font-size: 11px;
  }

  .efmp-custom-billing-card {
    padding: 15px;
    font-size: 11px;
    line-height: 1.65;
  }

  .efmp-custom-billing-name {
    font-size: 13px;
  }
}

/* Íconos propios en rojo/verde de Energy Fit: evita emojis dependientes del dispositivo. */
.efmp-brand-icon {
  display: inline-grid;
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 9px;
  background: #fff1f1;
  color: #ba181c;
}
.efmp-brand-icon svg { width: 16px; height: 16px; }
.efmp-custom-summary-card--payment .efmp-brand-icon {
  background: #eaf8f0;
  color: #13a866;
}
.efmp-custom-billing-card .efmp-brand-icon {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: #f7f7f7;
  color: #ba181c;
}
.efmp-custom-billing-card .efmp-brand-icon svg { width: 14px; height: 14px; }
.efmp-custom-billing-line {
  display: flex;
  align-items: center;
  gap: 9px;
}
.efmp-custom-billing-country {
  padding-left: 33px;
  color: #666;
}
.efmp-custom-summary-card li strong { max-width: 58%; }
.efmp-custom-summary-card--payment li:last-child strong { color: #118552; }
@media (max-width: 640px) {
  .efmp-brand-icon { width: 24px; height: 24px; border-radius: 7px; }
  .efmp-brand-icon svg { width: 14px; height: 14px; }
  .efmp-custom-billing-card .efmp-brand-icon { width: 21px; height: 21px; }
  .efmp-custom-billing-country { padding-left: 30px; }
}


/* v0.4.8: estados claros, facturación completa e íconos propios de marca. */
.efmp-custom-billing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.efmp-custom-billing-item {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid #eeeeee;
  border-radius: 12px;
  background: #fafafa;
}

.efmp-custom-billing-item--wide {
  grid-column: auto;
}

.efmp-custom-billing-item .efmp-brand-icon {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: #fff1f1;
  color: #ba181c;
}

.efmp-custom-billing-item small,
.efmp-custom-billing-item strong,
.efmp-custom-billing-item a {
  display: block;
}

.efmp-custom-billing-item small {
  margin-bottom: 3px;
  color: #777;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .03em;
  line-height: 1.2;
  text-transform: uppercase;
}

.efmp-custom-billing-item strong,
.efmp-custom-billing-item a {
  color: #202020 !important;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
  overflow-wrap: anywhere;
  text-decoration: none !important;
}

.efmp-custom-summary-card--payment li:last-child strong {
  color: #118552 !important;
}

/* Los íconos de la tarjeta superior también usan los SVG de Energy Fit. */
.efmp-order-number-chip > .efmp-brand-icon,
.efmp-success-info > .efmp-brand-icon,
.efmp-success-action > .efmp-brand-icon {
  flex: 0 0 auto;
}

.efmp-order-number-chip > .efmp-brand-icon {
  background: #def5e8;
  color: #118552;
}

.efmp-success-info--status > .efmp-brand-icon {
  background: #fff1f1;
  color: #ba181c;
}

.efmp-success-info--email > .efmp-brand-icon {
  background: #eef5ff;
  color: #2768b3;
}

.efmp-success-action > .efmp-brand-icon {
  background: #fff1f1;
  color: #ba181c;
}

.efmp-view-status-icon .efmp-brand-icon {
  width: 38px;
  height: 38px;
  background: transparent;
  color: #118552;
}

@media (max-width: 640px) {
  .efmp-custom-billing-grid {
    gap: 9px;
  }

  .efmp-custom-billing-item {
    grid-template-columns: 26px minmax(0, 1fr);
    gap: 8px;
    padding: 10px;
  }

  .efmp-custom-billing-item .efmp-brand-icon {
    width: 26px;
    height: 26px;
  }

  .efmp-custom-billing-item small {
    font-size: 8px;
  }

  .efmp-custom-billing-item strong,
  .efmp-custom-billing-item a {
    font-size: 11px;
  }
}

/* v0.5.1: ficha de producto apilada en mobile para evitar nombres angostos. */
@media (max-width: 640px) {
  .efmp-custom-order-table,
  .efmp-custom-order-table tbody,
  .efmp-custom-order-table tr,
  .efmp-custom-order-table td {
    display: block;
    width: 100%;
  }

  .efmp-custom-order-table thead {
    display: none;
  }

  .efmp-custom-order-table tbody tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .efmp-custom-order-table tbody td {
    box-sizing: border-box;
  }

  .efmp-custom-order-table tbody td:first-child {
    grid-column: 1 / -1;
    padding: 14px 12px !important;
  }

  .efmp-custom-order-table tbody td:nth-child(2),
  .efmp-custom-order-table tbody td:nth-child(3) {
    padding: 10px 12px !important;
    border-top: 1px solid #eeeeee;
    border-bottom: 0;
  }

  .efmp-custom-order-table tbody td:nth-child(2) {
    text-align: left !important;
  }

  .efmp-custom-order-table tbody td:nth-child(3) {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    text-align: right !important;
  }

  .efmp-custom-order-table tbody td:nth-child(3)::before {
    color: #666;
    content: "Total";
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .03em;
    text-transform: uppercase;
  }

  .efmp-custom-product {
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 12px;
  }

  .efmp-custom-product-thumb {
    width: 64px;
    height: 64px;
  }

  .efmp-custom-product-info {
    min-width: 0;
  }

  .efmp-custom-product-name {
    display: block;
    font-size: 12px;
    line-height: 1.45;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
  }

  .efmp-custom-qty-badge {
    justify-content: center;
  }
}


/* v0.5.9: condición de facturación destacada. */
.efmp-billing-type {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 11px;
  align-items: center;
  margin: 0 0 14px;
  padding: 13px 14px;
  border: 1px solid #dcefe3;
  border-radius: 13px;
  background: #f3fbf6;
}

.efmp-billing-type--invoice {
  border-color: #f0cccc;
  background: #fff5f5;
}

.efmp-billing-type .efmp-brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: #dff4e7;
  color: #118552;
}

.efmp-billing-type--invoice .efmp-brand-icon {
  background: #ffe5e5;
  color: #ba181c;
}

.efmp-billing-type small,
.efmp-billing-type strong {
  display: block;
}

.efmp-billing-type small {
  margin-bottom: 3px;
  color: #6b766f;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.efmp-billing-type strong {
  color: #117447;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: .025em;
}

.efmp-billing-type--invoice strong {
  color: #9d1519;
}

@media (max-width: 640px) {
  .efmp-billing-type {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 9px;
    margin-bottom: 10px;
    padding: 11px;
  }

  .efmp-billing-type .efmp-brand-icon {
    width: 32px;
    height: 32px;
  }

  .efmp-billing-type small {
    font-size: 8px;
  }

  .efmp-billing-type strong {
    font-size: 13px;
  }
}


/* v0.6.5: no exponer domicilios completos en el resultado del seguimiento. */
body.efmp-order-tracking-page .woocommerce-customer-details {
  display: none !important;
}


/* v0.6.7: Facturación compacta y responsive dentro de Mi cuenta. */
body.efmp-order-view .efmp-custom-billing-card {
  padding: 12px;
  border-radius: 15px;
}

body.efmp-order-view .efmp-custom-billing-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.efmp-order-view .efmp-custom-billing-item {
  min-width: 0;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 8px;
  padding: 9px 10px;
  border-radius: 10px;
}

body.efmp-order-view .efmp-custom-billing-item--wide {
  grid-column: 1 / -1;
}

body.efmp-order-view .efmp-custom-billing-item .efmp-brand-icon {
  width: 26px;
  height: 26px;
  border-radius: 8px;
}

body.efmp-order-view .efmp-custom-billing-item small {
  margin-bottom: 2px;
  font-size: 8px;
}

body.efmp-order-view .efmp-custom-billing-item strong,
body.efmp-order-view .efmp-custom-billing-item a {
  font-size: 11px;
  line-height: 1.3;
}

body.efmp-order-view .efmp-billing-type {
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 9px;
  margin-bottom: 9px;
  padding: 10px 11px;
  border-radius: 11px;
}

body.efmp-order-view .efmp-billing-type .efmp-brand-icon {
  width: 32px;
  height: 32px;
}

body.efmp-order-view .efmp-billing-type small {
  font-size: 8px;
}

body.efmp-order-view .efmp-billing-type strong {
  font-size: 13px;
}

/* En pantallas amplias de Mi cuenta, aprovecha tres columnas. */
@media (min-width: 900px) {
  body.efmp-order-view .efmp-custom-billing-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Solo teléfonos extremadamente angostos vuelven a una columna. */
@media (max-width: 340px) {
  body.efmp-order-view .efmp-custom-billing-grid {
    grid-template-columns: 1fr;
  }

  body.efmp-order-view .efmp-custom-billing-item--wide {
    grid-column: auto;
  }
}


/* v0.6.8: Facturación compacta también en Compra confirmada. */
body.efmp-order-success .efmp-custom-billing-card {
  padding: 12px;
  border-radius: 15px;
}

body.efmp-order-success .efmp-custom-billing-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.efmp-order-success .efmp-custom-billing-item {
  min-width: 0;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 8px;
  padding: 9px 10px;
  border-radius: 10px;
}

body.efmp-order-success .efmp-custom-billing-item--wide {
  grid-column: 1 / -1;
}

body.efmp-order-success .efmp-custom-billing-item .efmp-brand-icon {
  width: 26px;
  height: 26px;
  border-radius: 8px;
}

body.efmp-order-success .efmp-custom-billing-item small {
  margin-bottom: 2px;
  font-size: 8px;
}

body.efmp-order-success .efmp-custom-billing-item strong,
body.efmp-order-success .efmp-custom-billing-item a {
  font-size: 11px;
  line-height: 1.3;
}

body.efmp-order-success .efmp-billing-type {
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 9px;
  margin-bottom: 9px;
  padding: 10px 11px;
  border-radius: 11px;
}

body.efmp-order-success .efmp-billing-type .efmp-brand-icon {
  width: 32px;
  height: 32px;
}

body.efmp-order-success .efmp-billing-type small {
  font-size: 8px;
}

body.efmp-order-success .efmp-billing-type strong {
  font-size: 13px;
}

@media (min-width: 900px) {
  body.efmp-order-success .efmp-custom-billing-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 340px) {
  body.efmp-order-success .efmp-custom-billing-grid {
    grid-template-columns: 1fr;
  }

  body.efmp-order-success .efmp-custom-billing-item--wide {
    grid-column: auto;
  }
}


/* v0.6.9: Compra confirmada en dos columnas únicamente en escritorio. */
@media (min-width: 1100px) {
  body.efmp-order-success .woocommerce-order {
    display: grid;
    grid-template-columns: minmax(380px, 430px) minmax(0, 1fr);
    gap: 28px;
    align-items: start;
    max-width: 1320px;
  }

  body.efmp-order-success .efmp-success-card {
    grid-column: 1;
    width: 100%;
    max-width: none;
    margin: 30px 0 0;
    box-sizing: border-box;
  }

  body.efmp-order-success .efmp-custom-order-wrap {
    grid-column: 2;
    width: 100%;
    max-width: none;
    margin: 30px 0 0;
    min-width: 0;
  }

  body.efmp-order-success .efmp-custom-order-section:first-child {
    margin-top: 0;
  }
}


/* v0.7.0: una sola etiqueta Total en la ficha móvil del producto. */
.efmp-mobile-total-label {
  display: none;
}

@media (max-width: 640px) {
  body.efmp-order-success .efmp-custom-order-table tbody td:nth-child(3)::before,
  body.efmp-order-view .efmp-custom-order-table tbody td:nth-child(3)::before,
  .efmp-custom-order-table tbody td:nth-child(3)::before {
    display: none !important;
    content: none !important;
  }

  .efmp-custom-order-table .efmp-mobile-total-label {
    display: inline-block;
    color: #666;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .03em;
    line-height: 1;
    text-transform: uppercase;
  }

  .efmp-custom-order-table .efmp-custom-total-value {
    color: #171717;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
  }
}


/* v0.7.1: descuentos por cupón en Compra confirmada y Mi cuenta. */
.efmp-custom-summary-card li.is-discount span,
.efmp-custom-summary-card li.is-discount strong {
  color: #118552;
}

.efmp-custom-summary-card li.is-discount strong {
  font-weight: 900;
}


/* v0.7.2: detalle completo del pago dentro de Mi cuenta. */
body.efmp-order-view .efmp-custom-summary-card--payment {
  border-color: #dcefe3;
  background: #f2fbf5;
}

body.efmp-order-view .efmp-custom-summary-card--payment li strong {
  color: #171717;
}

body.efmp-order-view .efmp-custom-summary-card--payment li:first-child strong {
  color: #0b9444;
}


/* v1.0.7: oculta el rótulo externo del gateway en producción.
   El título se conserva internamente para pedidos, correos y administración. */
#payment ul.payment_methods li.payment_method_efmp_checkout > input.input-radio,
#payment ul.payment_methods li.payment_method_efmp_checkout > label {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
