/* Panier desktop : lignes plus denses et contrôles proportionnés. */
body.woocommerce-cart table.shop_table th,
body.woocommerce-cart table.shop_table td {
  padding:.7rem .85rem;
  vertical-align:middle;
}
body.woocommerce-cart table.shop_table tr.cart_item td { height:auto; }
body.woocommerce-cart table.shop_table td.product-thumbnail img {
  max-height:68px;
  max-width:68px;
  object-fit:contain;
}

/* Quantité : le champ et les commandes forment un seul contrôle compact. */
body.woocommerce-cart .quantity {
  display:block !important;
  float:none !important;
  height:48px !important;
  margin:0 !important;
  max-width:106px;
  position:relative !important;
  width:106px !important;
}
body.woocommerce-cart .quantity input.qty {
  display:block !important;
  float:none !important;
  height:48px !important;
  padding:0 34px 0 8px !important;
  width:106px !important;
}
body.woocommerce-cart .quantity .quantity-nav {
  float:none !important;
  height:48px !important;
  line-height:24px !important;
  position:absolute !important;
  right:0;
  top:0;
  width:34px;
}
body.woocommerce-cart .quantity .quantity-button {
  height:24px !important;
  left:0 !important;
  line-height:23px !important;
  right:auto !important;
  transform:none !important;
  width:34px !important;
}
body.woocommerce-cart .quantity .quantity-button.quantity-up { bottom:auto !important; top:0 !important; }
body.woocommerce-cart .quantity .quantity-button.quantity-down { bottom:0 !important; top:auto !important; }

@media (max-width:900px) {
  body.woocommerce-cart .woocommerce { padding-left:14px; padding-right:14px; }
  body.woocommerce-cart table.shop_table_responsive,
  body.woocommerce-cart table.shop_table_responsive tbody { display:block; }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item {
    border-bottom:1px solid #d5d3cc;
    display:grid !important;
    gap:5px 14px;
    grid-template-columns:minmax(96px, 34%) minmax(0, 1fr);
    padding:16px 30px 16px 0;
    position:relative;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td {
    background:transparent !important;
    border:0 !important;
    display:block !important;
    min-height:0;
    padding:3px 0 !important;
    text-align:left !important;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-remove {
    align-items:center;
    display:flex !important;
    height:32px;
    justify-content:center;
    position:absolute;
    right:4px;
    top:12px;
    width:32px;
    z-index:3;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-remove a.remove {
    align-items:center;
    display:flex !important;
    height:32px;
    justify-content:center;
    line-height:1;
    position:relative;
    width:32px;
    z-index:4;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-thumbnail {
    align-self:start;
    grid-column:1;
    grid-row:1 / span 4;
    padding-top:2px !important;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-thumbnail img {
    margin:0;
    max-height:72px;
    max-width:72px;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-name,
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-price,
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-quantity,
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-subtotal {
    grid-column:2;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-name {
    font-size:.95rem;
    font-weight:500;
    padding-right:34px !important;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-price,
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-subtotal { font-size:.9rem; }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-quantity { margin:5px 0 3px; }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-quantity::before { content:none !important; }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-subtotal::before,
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-price::before,
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-name::before {
    float:none;
    font-size:.78rem;
    margin-right:.25rem;
  }
  body.woocommerce-cart table.shop_table_responsive tr td.actions {
    padding:14px !important;
  }
}

@media (max-width:420px) {
  body.woocommerce-cart .woocommerce { padding-left:10px; padding-right:10px; }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item {
    gap:4px 11px;
    grid-template-columns:minmax(78px, 29%) minmax(0, 1fr);
    padding-right:24px;
  }
  body.woocommerce-cart table.shop_table_responsive tr.cart_item td.product-thumbnail img {
    max-height:60px;
    max-width:60px;
  }
}
