/* Real WooCommerce basket. Scope all layout rules to this screen; native form behaviour stays intact. */
.ov-screen-basket .ov-wc :is(.ov-wc, .ov-wc__body, .woocommerce, .woocommerce-cart-form, .cart-collaterals) { min-width: 0; max-width: 100%; }
.ov-screen-basket .ov-wc .woocommerce-cart-form { width: 100%; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents { width: 100%; table-layout: fixed; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents :is(th, td) { overflow-wrap: anywhere; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-remove { width: 56px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-thumbnail { width: 112px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents :is(.product-price, .product-subtotal) { width: 112px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-quantity { width: 116px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-name { min-width: 0; line-height: 1.45; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-name > a { font-weight: 650; text-decoration: none; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-thumbnail img { display: block; width: 80px; height: 80px; object-fit: contain; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-remove a { width: 40px; height: 40px; font-size: 24px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents dl.variation { display: flex; flex-wrap: wrap; gap: 2px 6px; margin-top: 8px; font-size: 13px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents dl.variation :is(dt, dd, p) { margin: 0; }
.ov-screen-basket .ov-wc .quantity :is(.ct-increase, .ct-decrease) { display: none; }
.ov-screen-basket .ov-wc .quantity input.qty { display: block; width: 80px; max-width: 100%; height: 44px; min-height: 44px; line-height: normal; padding: 6px 8px; font-size: 16px; text-align: center; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents td.actions { display: table-cell; padding: 16px; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents td.actions::before { content: none; }
.ov-screen-basket .ov-wc .coupon { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 10px; max-width: 100%; }
.ov-screen-basket .ov-wc .coupon input { flex: 1 1 160px; min-width: 0; width: 180px; max-width: 100%; }
.ov-screen-basket .ov-wc .woocommerce-cart-form__contents [name="update_cart"] { float: right; margin-left: 16px; }
.ov-screen-basket .ov-wc button:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
.ov-screen-basket .ov-wc .cart-collaterals { display: grid; gap: 20px; }
.ov-screen-basket .ov-wc .cart_totals { width: 100%; max-width: 30rem; margin-left: auto; min-width: 0; }
.ov-screen-basket .ov-wc .cart_totals > h2 { margin-bottom: 14px; }
.ov-screen-basket .ov-wc .cart_totals table { display: block; width: 100%; table-layout: auto; }
.ov-screen-basket .ov-wc .cart_totals tbody { display: block; }
.ov-screen-basket .ov-wc .cart_totals tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); padding: 0; border-bottom: 1px solid var(--line); }
.ov-screen-basket .ov-wc .cart_totals tr:last-child { border-bottom: 0; }
.ov-screen-basket .ov-wc .cart_totals :is(th, td) { display: block; width: auto; min-width: 0; border: 0; padding: 14px 16px; overflow-wrap: anywhere; }
.ov-screen-basket .ov-wc .cart_totals td { text-align: right; }
.ov-screen-basket .ov-wc .cart_totals td::before { content: none; }
.ov-screen-basket .ov-wc .cart_totals tr:is(.woocommerce-shipping-totals, .shipping) { grid-template-columns: minmax(0, 1fr); }
.ov-screen-basket .ov-wc .cart_totals tr:is(.woocommerce-shipping-totals, .shipping) th { padding-bottom: 0; }
.ov-screen-basket .ov-wc .cart_totals tr:is(.woocommerce-shipping-totals, .shipping) td { text-align: left; }
.ov-screen-basket .ov-wc .cart_totals :is(.woocommerce-shipping-methods, .shipping-calculator-form) { width: 100%; min-width: 0; }
.ov-screen-basket .ov-wc .cart_totals .woocommerce-shipping-methods { display: grid; gap: 8px; list-style: none; padding: 0; margin: 0 0 12px; }
.ov-screen-basket .ov-wc .cart_totals .woocommerce-shipping-destination { margin: 10px 0; font-size: 14px; }
.ov-screen-basket .ov-wc .cart_totals .shipping-calculator-form .form-row { display: block; float: none; width: 100%; margin: 0 0 10px; }
.ov-screen-basket .ov-wc .cart_totals .shipping-calculator-form :is(input, select, .select2-container) { width: 100% !important; min-width: 0; max-width: 100%; }
.ov-screen-basket .ov-wc .cart_totals .wc-proceed-to-checkout { margin-top: 16px; }
.ov-screen-basket .ov-wc .cart_totals .checkout-button { display: flex; justify-content: center; width: 100%; }
.ov-screen-basket .ov-wc :is(#wc-stripe-express-checkout-element, #wc-stripe-express-checkout-element iframe) { max-width: 100%; }
/* Stripe reads typography/colours from this invisible input. Anchor its absolute box within the viewport. */
.ov-screen-checkout #wc-stripe-hidden-style-input { left: 0; max-width: 100%; box-sizing: border-box; }
@media (max-width: 899.98px) {
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents { display: block; border: 0; background: transparent; overflow: visible; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents thead { display: none; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tbody { display: grid; gap: 16px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item { display: grid; grid-template-columns: 76px minmax(0, 1fr) 40px; grid-template-rows: auto auto auto auto; gap: 10px 12px; position: relative; padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: 18px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item > td { display: block; width: auto; min-width: 0; border: 0; padding: 0; text-align: left; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item > td::before { content: none; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-thumbnail { grid-column: 1; grid-row: 1 / 4; align-self: start; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-thumbnail img { width: 76px; height: 76px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-name { grid-column: 2; grid-row: 1; font-size: 15px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-remove { grid-column: 3; grid-row: 1; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-price { grid-column: 2 / 4; grid-row: 2; font-size: 14px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item > td.product-quantity { grid-column: 2 / 4; grid-row: 3; display: flex !important; align-items: center; justify-content: space-between; gap: 10px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item > td.product-quantity::before { content: attr(data-title); font-size: 13px; font-weight: 600; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item > td.product-subtotal { grid-column: 1 / 4; grid-row: 4; display: flex !important; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); padding-top: 12px; font-weight: 650; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item > td.product-subtotal::before { content: attr(data-title); font-weight: 500; font-size: 14px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tbody > tr:not(.cart_item) { display: block; padding: 0; border: 0; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents td.actions { display: flex; flex-direction: column; align-items: stretch; gap: 12px; width: 100%; padding: 0; }
  .ov-screen-basket .ov-wc .coupon { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
  .ov-screen-basket .ov-wc .coupon input { width: 100%; }
  .ov-screen-basket .ov-wc .coupon .button { padding-inline: 14px; white-space: nowrap; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents [name="update_cart"] { float: none; margin: 0; width: 100%; }
  .ov-screen-basket .ov-wc .cart_totals { max-width: none; margin: 0; }
  .ov-screen-basket .ov-wc .cart_totals :is(th, td) { padding: 14px; }
}
@media (max-width: 359.98px) {
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents tr.cart_item { grid-template-columns: 64px minmax(0, 1fr) 36px; gap: 10px; padding: 12px; }
  .ov-screen-basket .ov-wc .woocommerce-cart-form__contents .product-thumbnail img { width: 64px; height: 64px; }
  .ov-screen-basket .ov-wc .coupon { grid-template-columns: minmax(0, 1fr); }
}

/* Keep privacy controls reachable in normal flow at every basket/checkout width. */
body:is(.ov-screen-basket, .ov-screen-checkout) > button.osevaro-cookie-settings.osevaro-cookie-settings-fallback {
  position: static !important; inset: auto !important; transform: none !important;
  display: block; width: max-content; max-width: calc(100% - 32px);
  margin: 16px auto 24px !important;
}
html[data-shell="app"] body.has-tabbar:is(.ov-screen-basket, .ov-screen-checkout) > button.osevaro-cookie-settings.osevaro-cookie-settings-fallback {
  margin-bottom: calc(var(--tabbar-h, 64px) + var(--safe-b, 0px) + 20px) !important;
}
@media (max-width: 899.98px) {
  body.has-tabbar:is(.ov-screen-basket, .ov-screen-checkout) > button.osevaro-cookie-settings.osevaro-cookie-settings-fallback {
    margin-bottom: calc(var(--tabbar-h, 64px) + var(--safe-b, 0px) + 20px) !important;
  }
}
