/* Paso 3: el radio queda unido al nombre del transportista. */
body.page-order #checkout-delivery-step .delivery-option__label,
body#checkout #checkout-delivery-step .delivery-option__label {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  grid-template-areas:
    "head price"
    "delay price" !important;
  align-items: center !important;
  column-gap: 16px !important;
  row-gap: 6px !important;
}

body.page-order #checkout-delivery-step .delivery-option__left,
body#checkout #checkout-delivery-step .delivery-option__left {
  grid-area: head !important;
  display: grid !important;
  grid-template-columns: max-content max-content !important;
  align-items: center !important;
  justify-content: start !important;
  column-gap: 10px !important;
  width: max-content !important;
  flex: initial !important;
  min-width: 0 !important;
}

body.page-order #checkout-delivery-step .delivery-option__left .delivery-option__carrier,
body#checkout #checkout-delivery-step .delivery-option__left .delivery-option__carrier {
  display: flex !important;
  flex: 0 0 auto !important;
  width: max-content !important;
  min-width: 0 !important;
  margin: 0 !important;
  justify-content: flex-start !important;
  text-align: left !important;
}

body.page-order #checkout-delivery-step .delivery-option__left .delivery-option__carrier-name,
body#checkout #checkout-delivery-step .delivery-option__left .delivery-option__carrier-name {
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
  text-align: left !important;
  white-space: nowrap !important;
}

body.page-order #checkout-delivery-step .delivery-option__content,
body#checkout #checkout-delivery-step .delivery-option__content {
  grid-area: delay !important;
  flex-basis: auto !important;
  padding-left: 30px !important;
}

/* La recogida no necesita repetir su descripción: el nombre ya identifica
   con claridad la modalidad. */
body.page-order #checkout-delivery-step .delivery-option__item.is-pickup .delivery-option__content,
body#checkout #checkout-delivery-step .delivery-option__item.is-pickup .delivery-option__content {
  display: none !important;
}

body.page-order #checkout-delivery-step .delivery-option__price,
body#checkout #checkout-delivery-step .delivery-option__price {
  grid-area: price !important;
  justify-self: end !important;
  align-self: center !important;
  margin-left: 0 !important;
}

/* Navegación vertical, a ancho completo, para separar con claridad ambas acciones. */
body.page-order #checkout-delivery-step .buttons-wrapper,
body#checkout #checkout-delivery-step .buttons-wrapper {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  gap: 10px !important;
  margin-top: 8px !important;
}

body.page-order #checkout-delivery-step .buttons-wrapper > a,
body.page-order #checkout-delivery-step .buttons-wrapper > button,
body#checkout #checkout-delivery-step .buttons-wrapper > a,
body#checkout #checkout-delivery-step .buttons-wrapper > button {
  display: inline-flex !important;
  width: 100% !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 42px !important;
  padding: 0 16px !important;
  border-radius: 9px !important;
  font-family: var(--sans) !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  text-decoration: none !important;
}

body.page-order #checkout-delivery-step .buttons-wrapper .js-back,
body#checkout #checkout-delivery-step .buttons-wrapper .js-back {
  order: 2 !important;
  border: 1px solid var(--rule) !important;
  background: #fff !important;
  color: var(--dark) !important;
}

body.page-order #checkout-delivery-step .buttons-wrapper button.btn-primary,
body#checkout #checkout-delivery-step .buttons-wrapper button.btn-primary {
  order: 1 !important;
  min-height: 42px !important;
  padding: 0 24px !important;
  border: 0 !important;
  border-radius: 9px !important;
  background: var(--accent) !important;
  color: #fff !important;
  gap: 10px !important;
}

body.page-order #checkout-delivery-step .buttons-wrapper .material-icons,
body#checkout #checkout-delivery-step .buttons-wrapper .material-icons {
  display: inline !important;
}

body.page-order #checkout-delivery-step .buttons-wrapper .btn-primary::after,
body#checkout #checkout-delivery-step .buttons-wrapper .btn-primary::after {
  content: none !important;
  display: none !important;
}
