/* Checkout #payment — mobile side gutters, no horizontal bleed */
@media (max-width: 767px) {
  .checkout-index-index .page-main {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  /* Magento default: .payment-methods { margin: 0 -15px } — too tight on phone */
  .checkout-index-index .payment-methods {
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .checkout-index-index .opc-wrapper,
  .checkout-index-index .opc-payment,
  .checkout-index-index .checkout-payment-method,
  .checkout-index-index .payment-method,
  .checkout-index-index .payment-method-content,
  .checkout-index-index .payment-method-title {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .checkout-index-index .payment-method-title,
  .checkout-index-index .payment-method-content {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  .checkout-index-index .payment-method-content .actions-toolbar,
  .checkout-index-index .payment-method-content .primary,
  .checkout-index-index button.action.primary.checkout {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    float: none !important;
  }

  .checkout-index-index .opc-estimated-wrapper {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
    box-sizing: border-box !important;
  }
}

/* Long IBAN / predračun text — wrap without breaking layout */
.checkout-index-index .payment-method-content .payment-method-note,
.checkout-index-index .payment-method-billing-address .billing-address-details {
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media (min-width: 768px) {
  .checkout-index-index .payment-method-content {
    padding-right: 22px !important;
  }
}
