/* kleine overrides indien nodig */

/* Cart: betere mobiele weergave */
@media (max-width: 640px){
  /* Stapel cart items verticaal zodat niets buiten beeld valt */
  #cart-items .card{ display:flex; flex-direction:column; align-items:stretch; }
  #cart-items .card > div:first-child{ align-items:flex-start; }
  #cart-items .card .h-16.w-24{ width:100%; height:auto; max-height:160px; }
  #cart-items .card .h-16.w-24 img{ width:100%; height:160px; object-fit:cover; }

  /* Besturingsgroep onder elkaar met ruimte */
  #cart-items .card .flex.items-center.gap-3{ width:100%; justify-content:space-between; flex-wrap:wrap; gap:.5rem; }
  #cart-items [data-qty]{ width:60px; }
  #cart-items .min-w-\[5\.5rem\]{ min-width:unset; text-align:left; }

  /* Sidebar onder content i.p.v. sticky rechts */
  #view-cart .grid{ grid-template-columns: 1fr !important; }
  #view-cart aside.sticky{ position:static; top:auto; }

  /* Prevent horizontal overflow in cart on small screens */
  #view-cart, #view-cart *{ box-sizing:border-box; }
  #view-cart .card{ max-width:100%; overflow:hidden; }
  #view-cart .grid{ width:100%; overflow:hidden; }
  #view-cart .text-right{ text-align:right; }
  #view-cart .btn{ white-space:nowrap; }
}

/* Fix header logo te groot op mobiel */
@media (max-width: 640px){
  header img[alt="Timmerwerken020"]{ height:56px; }
}

/* Avoid layout shift causing overflow on very small devices */
html, body{ width:100%; overflow-x:hidden; }