/* PRISP Canada: keep all order-summary controls visible in narrow columns. */
body.onestepcheckout-index-index #checkout-review-table {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box;
}

body.onestepcheckout-index-index #checkout-review-table thead {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

body.onestepcheckout-index-index #checkout-review-table tbody {
  display: block;
  width: 100%;
}

body.onestepcheckout-index-index #checkout-review-table tbody tr {
  display: grid !important;
  grid-template-columns: minmax(94px, 1fr) minmax(85px, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 12px 0;
  border-bottom: 1px solid #ddd;
  width: 100%;
  box-sizing: border-box;
}

body.onestepcheckout-index-index #checkout-review-table td {
  display: block !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  padding: 4px !important;
  border: 0;
  box-sizing: border-box;
}

body.onestepcheckout-index-index #checkout-review-table td.product {
  grid-column: 1 / -1;
  display: grid !important;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
}

/* Porto/Mageplaza adds clearfix pseudo-elements; they must not become grid items. */
body.onestepcheckout-index-index #checkout-review-table td.product::before,
body.onestepcheckout-index-index #checkout-review-table td.product::after {
  content: none !important;
  display: none !important;
}

body.onestepcheckout-index-index #checkout-review-table td.product > .product-image-container {
  grid-column: 1;
  grid-row: 1;
  float: none !important;
  padding: 0 !important;
  height: auto !important;
  margin: 0 !important;
}

body.onestepcheckout-index-index #checkout-review-table td.product > .product-item-detail {
  grid-column: 2;
  grid-row: 1;
  padding: 0 !important;
  text-align: left;
}

body.onestepcheckout-index-index #checkout-review-table .product-image-container,
body.onestepcheckout-index-index #checkout-review-table .product-image-wrapper {
  width: 100% !important;
  max-width: 72px !important;
}

body.onestepcheckout-index-index #checkout-review-table .product-image-wrapper img {
  max-width: 100% !important;
  height: auto !important;
}

body.onestepcheckout-index-index #checkout-review-table .product-item-detail,
body.onestepcheckout-index-index #checkout-review-table .product-item-inner,
body.onestepcheckout-index-index #checkout-review-table .product-item-name-block,
body.onestepcheckout-index-index #checkout-review-table .product-item-name {
  display: block !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  white-space: normal !important;
  overflow-wrap: anywhere;
}

body.onestepcheckout-index-index #checkout-review-table .product-item-name {
  font-size: 15px !important;
  line-height: 1.4 !important;
  word-break: normal !important;
}

body.onestepcheckout-index-index #checkout-review-table td.subtotal .price {
  font-size: 16px !important;
  font-weight: 600;
}

body.onestepcheckout-index-index #checkout-review-table td.details-qty::before,
body.onestepcheckout-index-index #checkout-review-table td.subtotal::before {
  display: block;
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 4px;
}

body.onestepcheckout-index-index #checkout-review-table td.details-qty::before { content: "Qty"; }
body.onestepcheckout-index-index #checkout-review-table td.subtotal::before { content: "Subtotal"; }
html:lang(fr) body.onestepcheckout-index-index #checkout-review-table td.details-qty::before { content: "Qté"; }
html:lang(fr) body.onestepcheckout-index-index #checkout-review-table td.subtotal::before { content: "Sous-total"; }

body.onestepcheckout-index-index #checkout-review-table .qty-wrapper,
body.onestepcheckout-index-index #checkout-review-table td.subtotal > .subtotal,
body.onestepcheckout-index-index #checkout-review-table .remove-wrapper {
  display: block !important;
  margin: 0 auto;
  max-width: 100%;
  width: auto !important;
}

body.onestepcheckout-index-index #checkout-review-table .price-excluding-tax,
body.onestepcheckout-index-index #checkout-review-table .cart-price {
  white-space: normal !important;
  overflow-wrap: anywhere;
}
