/**
 * Fast Toner cart page — phone layout.
 *
 * WooCommerce's smallscreen stylesheet turns .shop_table_responsive into a
 * stacked "label: value" list. That is readable but generic: the product name
 * is clipped, the remove control lands alone on a full-width row, and each line
 * carries its own divider, so a two-item cart runs well past a phone screen.
 *
 * Below WooCommerce's own 768px breakpoint each cart line becomes a card with
 * the thumbnail on the left and the product details on the right, which is the
 * layout shoppers expect on a phone.
 */

@media (max-width: 900px) {

	/* The nested cards (page > form > table) each carried 22px of padding, which
	   left only ~202px of usable width on a 345px screen. Trim the shells so the
	   content itself gets the room. */
	body.ft-cart-page .woocommerce {
		padding: 20px 12px 40px;
	}

	body.ft-cart-page .woocommerce-cart-form {
		padding: 14px;
	}

	/* The collaterals wrapper boxed the order summary and the cross-sells into a
	   single card, so the "สินค้าที่ใช้ร่วมกัน" heading landed 4px below the
	   checkout button and read as part of the totals. Drop the shared box and
	   give each block its own card with real space between them. */
	body.ft-cart-page .cart-collaterals {
		display: flex;
		flex-direction: column-reverse;
		gap: 18px;
		padding: 0;
		border: 0;
		background: none;
	}

	body.ft-cart-page .cart-collaterals > .cart_totals {
		box-sizing: border-box;
		width: 100%;
		margin: 0;
		padding: 14px;
		border: 1px solid var(--ft-line, #e3ecf3);
		border-radius: 16px;
		background: #fff;
	}

	/* The suggestions stay an open section, like "สินค้าที่เกี่ยวข้อง" on a
	   product page: the product cards carry the boxes, so wrapping them in a
	   second card would nest one border inside another. */
	body.ft-cart-page .cart-collaterals > .cross-sells {
		box-sizing: border-box;
		width: 100%;
		margin: 0;
		padding: 0;
		border: 0;
		background: none;
	}

	/* 30px under the heading plus the table's own spacing left ~51px of empty
	   card before the first amount. */
	body.ft-cart-page .cart_totals h2 {
		margin: 0 0 12px;
		font-size: 17px;
	}

	body.ft-cart-page .cart_totals table.shop_table {
		margin: 0;
	}

	body.ft-cart-page .cart_totals .wc-proceed-to-checkout {
		margin: 14px 0 0;
		padding: 0;
	}

	body.ft-cart-page table.shop_table_responsive.cart,
	body.ft-cart-page table.shop_table_responsive.cart tbody {
		display: block;
		width: 100%;
	}

	/* One cart line = one card. */
	body.ft-cart-page table.shop_table_responsive.cart tbody tr.cart_item {
		position: relative;
		display: grid;
		grid-template-columns: 84px minmax(0, 1fr);
		grid-template-areas:
			"thumb name"
			"thumb price"
			"qty   subtotal";
		align-items: center;
		gap: 6px 14px;
		box-sizing: border-box;
		width: 100%;
		margin: 0 0 12px;
		padding: 14px;
		border: 1px solid var(--ft-line, #e3ecf3);
		border-radius: 14px;
		background: #fff;
	}

	body.ft-cart-page table.shop_table_responsive.cart tbody tr.cart_item:last-of-type {
		margin-bottom: 0;
	}

	body.ft-cart-page table.shop_table_responsive.cart tbody tr.cart_item > td {
		display: block;
		width: auto;
		margin: 0;
		padding: 0;
		border: 0;
		text-align: left;
		font-size: 14px;
	}

	/* The stacked layout's "label:" prefixes only repeat what the card already
	   shows through position and styling. */
	body.ft-cart-page table.shop_table_responsive.cart tbody tr.cart_item > td::before {
		content: none !important;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-thumbnail {
		grid-area: thumb;
		align-self: start;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-thumbnail img {
		display: block;
		width: 84px;
		height: 84px;
		object-fit: contain;
		border: 1px solid var(--ft-line, #e3ecf3);
		border-radius: 10px;
		background: #fff;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-name {
		grid-area: name;
		align-self: end;
		padding-right: 26px; /* clears the remove button pinned top-right */
	}

	/* Toner names carry the printer models that tell two products apart, so give
	   them three lines instead of the single clipped line WooCommerce showed. */
	body.ft-cart-page table.shop_table_responsive.cart td.product-name a {
		display: -webkit-box;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 3;
		overflow: hidden;
		color: var(--ft-blue-dark, #17354b);
		font-size: 14px;
		font-weight: 600;
		line-height: 1.45;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-price {
		grid-area: price;
		align-self: start;
		color: #5b7386;
		font-size: 13px;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-quantity {
		grid-area: qty;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-quantity .quantity {
		float: none !important;
		margin: 0 !important;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-subtotal {
		grid-area: subtotal;
		justify-self: end;
		color: var(--ft-blue-dark, #17354b);
		font-size: 16px;
		font-weight: 700;
	}

	/* Pinned to the card corner instead of taking a full row of its own. */
	body.ft-cart-page table.shop_table_responsive.cart td.product-remove {
		position: absolute;
		top: 10px;
		right: 10px;
		z-index: 1;
	}

	body.ft-cart-page table.shop_table_responsive.cart td.product-remove a.remove {
		display: flex;
		align-items: center;
		justify-content: center;
		width: 26px;
		height: 26px;
		border-radius: 8px;
		background: #f2f6f9;
		color: #7b93a5 !important;
		font-size: 16px;
		line-height: 1;
	}

	body.ft-cart-page table.shop_table_responsive.cart tr:not(.cart_item) td.actions {
		display: block;
		width: 100%;
		padding: 14px 0 0;
		border: 0;
		text-align: center;
	}

	/* Cross-sells: the carousel is configured for two slides, so a single
	   suggestion was sized to half the column and left the rest of the row
	   empty. Lay the slides out as a grid that fills the width instead. */
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-list {
		overflow: hidden;
	}

	/* The `#jas-content .products.jas-carousel.slick-slider` rules in
	   product-card.css keep Slick's flex track, which is right for a wide
	   archive row but leaves a lone suggestion at half width on a phone. Matched
	   through the same id and carousel class so this grid wins there. */
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-track {
		display: flex !important;
		flex-wrap: wrap !important;
		gap: 14px;
		width: 100% !important;
		transform: none !important;
	}

	/* `flex: 1 1 150px` lets a lone suggestion stretch across the row while two
	   or more still sit side by side. */
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-slide {
		flex: 1 1 150px !important;
		float: none !important;
		width: auto !important;
		margin: 0 !important;
	}

	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-slide.slick-cloned {
		display: none !important;
	}

	/* A 940x1200 product shot stretched to the column turned the suggestion into
	   a mostly empty half-screen box. Cap it so the name, price and add-to-cart
	   button stay in view. */
	body.ft-cart-page #jas-content .cross-sells .product-image img {
		width: 100%;
		height: 150px;
		object-fit: contain;
	}

	body.ft-cart-page #jas-content .cross-sells .product-inner .product-title,
	body.ft-cart-page #jas-content .cross-sells .product-inner h3 {
		font-size: 14px;
		line-height: 1.45;
	}

	body.ft-cart-page .cross-sells h2 {
		margin: 0 0 14px;
		font-size: 17px;
	}
}

/* The generic scroll wrapper is intended for wide data tables, not the
   two-column cart summary. Keep amounts and shipping within the card. */
body.ft-cart-page .cart_totals .ft-table-scroll {
	overflow: visible;
}

body.ft-cart-page .cart_totals .ft-table-scroll table.shop_table {
	width: 100% !important;
	min-width: 0 !important;
	table-layout: auto;
}

body.ft-cart-page .cart_totals table.shop_table :is(th, td) {
	width: auto;
	padding: 12px 0;
	vertical-align: top;
}

body.ft-cart-page .cart_totals table.shop_table th { text-align: left; }
body.ft-cart-page .cart_totals table.shop_table td {
	text-align: right;
	overflow-wrap: anywhere;
}

/* The line subtotal already expresses the price at the selected quantity.
   Showing the unit price beside it repeats the same amount for quantity one. */
body.ft-cart-page table.shop_table_responsive.cart :is(th, td).product-price {
	display: none !important;
}

@media (min-width: 901px) {
	body.ft-cart-page .woocommerce-cart-form { padding: 24px; }
	body.ft-cart-page table.shop_table_responsive.cart {
		width: 100%;
		table-layout: fixed;
	}
	body.ft-cart-page table.shop_table_responsive.cart th.product-thumbnail { width: 90px; }
	body.ft-cart-page table.shop_table_responsive.cart th.product-quantity { width: 132px; }
	body.ft-cart-page table.shop_table_responsive.cart th.product-subtotal { width: 100px; }
	body.ft-cart-page table.shop_table_responsive.cart th.product-removed { width: 46px; }
	body.ft-cart-page table.shop_table_responsive.cart tr.cart_item td { vertical-align: middle; }
	body.ft-cart-page table.shop_table_responsive.cart td.product-name,
	body.ft-cart-page table.shop_table_responsive.cart td.product-name a {
		text-align: left;
		line-height: 1.5;
	}
	body.ft-cart-page table.shop_table_responsive.cart td.product-subtotal { text-align: right; }

	body.ft-cart-page .cart-collaterals {
		display: grid !important;
		grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
		align-items: start;
		gap: 28px;
		width: 100%;
		padding: 0;
		border: 0;
		background: transparent;
	}
	body.ft-cart-page .cart-collaterals > :is(.cross-sells, .cart_totals) {
		float: none !important;
		width: auto !important;
		min-width: 0;
		margin: 0;
	}
	body.ft-cart-page .cart-collaterals > .cross-sells,
	body.ft-cart-page .cart-collaterals > .cart_totals {
		box-sizing: border-box;
		padding: 22px;
		border: 1px solid var(--ft-line, #e3ecf3);
		border-radius: 16px;
		background: #fff;
	}
	body.ft-cart-page .cart-collaterals > .cart_totals {
		grid-column: 2;
	}
	body.ft-cart-page .cross-sells .product-image > a {
		height: 160px !important;
		min-height: 0 !important;
		aspect-ratio: auto !important;
	}
	body.ft-cart-page .cross-sells .product-image img {
		height: 100% !important;
		object-fit: contain !important;
	}
}

@media (max-width: 900px) {
	body.ft-cart-page .cart-collaterals > :is(.cross-sells, .cart_totals) {
		float: none !important;
	}
	body.ft-cart-page table.shop_table_responsive.cart thead { display: none; }
	body.ft-cart-page table.shop_table_responsive.cart tbody tr.cart_item {
		grid-template-columns: 70px minmax(0, 1fr);
		grid-template-areas: "thumb name" "qty qty";
		gap: 6px 10px;
		padding: 12px;
	}
	body.ft-cart-page table.shop_table_responsive.cart td.product-thumbnail img {
		width: 70px;
		height: 70px;
	}
	body.ft-cart-page table.shop_table_responsive.cart td.product-name {
		align-self: center;
	}
	body.ft-cart-page table.shop_table_responsive.cart td.product-quantity {
		justify-self: start;
		padding-top: 8px;
	}
	body.ft-cart-page table.shop_table_responsive.cart td.product-subtotal {
		position: absolute;
		right: 12px;
		bottom: 20px;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-track {
		display: grid !important;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px;
		width: 100% !important;
		transform: none !important;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-slide {
		flex: none !important;
		width: auto !important;
		padding: 0 !important;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-slide.slick-cloned,
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-arrow {
		display: none !important;
	}
	body.ft-cart-page #jas-content .cross-sells .product-image > a {
		height: 120px !important;
		min-height: 0 !important;
		aspect-ratio: auto !important;
	}
	body.ft-cart-page #jas-content .cross-sells .product-image img {
		height: 100% !important;
		object-fit: contain !important;
	}
}

/* Storefront cart: a restrained Fast Toner interpretation of a marketplace
   cart. Preserve WooCommerce's real quantity, coupon and checkout controls. */
body.ft-cart-page #jas-content { background: #f6f9fc; }
body.ft-cart-page .woocommerce { max-width: 1240px; }
body.ft-cart-page .woocommerce-cart-form {
	border-color: #dce7f1;
	border-radius: 12px;
	box-shadow: 0 8px 28px rgba(25, 62, 91, .045);
}
body.ft-cart-page .woocommerce-cart-form table.shop_table {
	width: 100%;
	margin: 0;
	border: 0;
}
body.ft-cart-page .woocommerce-cart-form thead {
	background: #edf5fb;
}
body.ft-cart-page .woocommerce-cart-form thead th {
	padding-block: 15px;
	color: #37536c;
	font-size: 14px;
	font-weight: 600;
}
body.ft-cart-page .woocommerce-cart-form tbody tr.ft-cart-store-row td {
	padding: 14px 16px;
	border-bottom: 1px solid #dce7f1;
	background: #f9fcff;
	color: #24435c;
	font-size: 14px;
	text-align: left;
}
body.ft-cart-page .ft-cart-store-mark {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	margin-right: 10px;
	border-radius: 8px;
	background: #0969bd;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	vertical-align: middle;
}
body.ft-cart-page .ft-cart-store-caption {
	margin-left: 10px;
	color: #74889a;
	font-size: 12px;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item td {
	border-bottom: 1px solid #e6edf3;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-name a {
	color: #243b50;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.5;
	text-decoration: none !important;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-subtotal {
	color: #087449;
	font-weight: 700;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-remove a.remove {
	color: #6e8293 !important;
	text-decoration: none !important;
}
body.ft-cart-page .woocommerce-cart-form td.actions {
	padding: 8px 12px 0;
}
body.ft-cart-page .woocommerce-cart-form td.actions:not(:has(.coupon)):has([name="update_cart"]:disabled) {
	padding: 0;
	height: 0;
	font-size: 0;
}
body.ft-cart-page .woocommerce-cart-form td.actions:not(:has(.coupon)):has([name="update_cart"]:disabled) [name="update_cart"] {
	display: none;
}
body.ft-cart-page .woocommerce-cart-form td.actions .coupon {
	box-sizing: border-box;
	gap: 10px;
	padding: 12px 14px;
	border: 1px solid #dceaf5;
	border-radius: 10px;
	background: #f5faff;
}
body.ft-cart-page .woocommerce-cart-form td.actions .coupon input {
	max-width: 220px;
	background: #fff;
}
body.ft-cart-page .woocommerce-cart-form td.actions .coupon .button {
	background: #e4f1fb !important;
	color: #075b9d !important;
}
body.ft-cart-page .cart-collaterals {
	border: 0;
	background: transparent;
}
body.ft-cart-page .cart-collaterals > .cart_totals {
	border-color: #dce7f1;
	border-radius: 12px;
	box-shadow: 0 8px 28px rgba(25, 62, 91, .045);
}
body.ft-cart-page .cart_totals h2 {
	color: #24435c;
	font-size: 18px;
	font-weight: 700;
}
body.ft-cart-page .cart_totals .order-total :is(th, td) {
	color: #087449;
	font-size: 17px;
	font-weight: 700;
}
body.ft-cart-page .cart_totals .wc-proceed-to-checkout .checkout-button {
	width: 100%;
	min-height: 50px;
	margin: 0;
	background: #0969bd !important;
	box-shadow: 0 5px 15px rgba(9, 105, 189, .18);
}
body.ft-cart-page .cross-sells h2 {
	color: #24435c;
	font-size: 19px;
	font-weight: 600;
}
body.ft-cart-page #jas-content .cross-sells .jas-carousel:not(.slick-initialized) {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	align-items: stretch;
	gap: 16px;
	visibility: visible !important;
	opacity: 1 !important;
}
body.ft-cart-page #jas-content .cross-sells .jas-carousel:not(.slick-initialized) > .product {
	float: none !important;
	width: auto !important;
	max-width: none !important;
	margin: 0 !important;
	padding: 14px !important;
	border: 1px solid #dce7f1;
	border-radius: 10px;
	background: #fff;
	visibility: visible !important;
}

@media (min-width: 901px) {
	body.ft-cart-page .woocommerce-cart-form { padding: 0 20px 16px; }
	body.ft-cart-page .woocommerce-cart-form table.shop_table.cart {
		table-layout: auto !important;
	}
	body.ft-cart-page .woocommerce-cart-form thead { height: 56px; }
	body.ft-cart-page .woocommerce-cart-form tr.cart_item td { padding-block: 18px; }
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-thumbnail img {
		width: 80px;
		height: 80px;
	}
	body.ft-cart-page .cart-collaterals {
		display: flex !important;
		flex-direction: column;
		gap: 28px;
		padding: 0;
	}
	body.ft-cart-page .cart-collaterals > .cart_totals {
		order: 0;
		display: block;
		align-self: flex-end;
		box-sizing: border-box;
		width: min(100%, 420px) !important;
		padding: 20px 24px 24px;
	}
	body.ft-cart-page .cart_totals h2 {
		margin: 0 0 10px;
		padding-bottom: 12px;
		border-bottom: 1px solid #dce7f1;
	}
	body.ft-cart-page .cart_totals .ft-table-scroll { min-width: 0; }
	body.ft-cart-page .cart_totals .wc-proceed-to-checkout {
		margin: 16px 0 0;
		padding: 0;
	}
	body.ft-cart-page .cart-collaterals > .cross-sells {
		order: 1;
		box-sizing: border-box;
		width: 100% !important;
		padding: 0;
		border: 0;
		background: transparent;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-list { overflow: visible; }
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-track {
		display: grid !important;
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 16px;
		width: 100% !important;
		transform: none !important;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-slide {
		float: none !important;
		width: auto !important;
		margin: 0 !important;
		padding: 0 !important;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-slide.slick-cloned,
	body.ft-cart-page #jas-content .cross-sells .jas-carousel .slick-arrow { display: none !important; }
}

@media (max-width: 900px) {
	body.ft-cart-page .woocommerce { padding: 20px 12px 48px; }
	body.ft-cart-page #jas-content .cross-sells .jas-carousel:not(.slick-initialized) {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px;
	}
	body.ft-cart-page #jas-content .cross-sells .jas-carousel:not(.slick-initialized) > .product {
		padding: 8px !important;
	}
	body.ft-cart-page .woocommerce-cart-form { padding: 0 12px 14px; }
	body.ft-cart-page .woocommerce-cart-form .ft-table-scroll { overflow: visible; }
	body.ft-cart-page .woocommerce-cart-form .ft-table-scroll table.shop_table {
		min-width: 0 !important;
	}
	body.ft-cart-page .woocommerce-cart-form table.shop_table.cart1,
	body.ft-cart-page .woocommerce-cart-form table.shop_table.cart1 tbody {
		display: block;
		width: 100%;
	}
	body.ft-cart-page .woocommerce-cart-form table.shop_table.cart1 thead { display: none; }
	body.ft-cart-page .woocommerce-cart-form tr.ft-cart-store-row {
		display: block;
		margin: 0 -12px 12px;
	}
	body.ft-cart-page .woocommerce-cart-form tr.ft-cart-store-row td {
		display: block;
		width: 100%;
		box-sizing: border-box;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 tr.cart_item {
		position: relative;
		display: grid;
		grid-template-columns: 70px minmax(0, 1fr);
		grid-template-areas: "thumb name" "subtotal subtotal";
		gap: 8px 12px;
		margin: 0 0 12px;
		padding: 12px;
		border: 1px solid #dce7f1;
		border-radius: 10px;
		background: #fff;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 tr.cart_item > td {
		display: block;
		width: auto;
		padding: 0;
		border: 0;
		text-align: left;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 tr.cart_item > td::before { content: none !important; }
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-thumbnail { grid-area: thumb; }
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-thumbnail img {
		width: 70px;
		height: 70px;
		object-fit: contain;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-name { grid-area: name; padding-right: 24px; }
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-name a {
		display: -webkit-box;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 3;
		overflow: hidden;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-name .product-price { display: none !important; }
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-name .quantity {
		float: none !important;
		margin: 10px 0 0 !important;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-subtotal {
		grid-area: subtotal;
		justify-self: end;
		font-size: 16px;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 td.product-remove {
		position: absolute;
		top: 8px;
		right: 8px;
	}
	body.ft-cart-page .woocommerce-cart-form table.cart1 tr:not(.cart_item) td.actions {
		display: block;
		width: 100%;
		box-sizing: border-box;
	}
	body.ft-cart-page .woocommerce-cart-form td.actions .coupon {
		flex-wrap: wrap;
		justify-content: flex-start;
	}
	body.ft-cart-page .cart-collaterals { gap: 26px; }
	body.ft-cart-page .cart-collaterals > .cart_totals {
		width: 100%;
		padding: 18px;
	}
	body.ft-cart-page .cart-collaterals > .cross-sells { width: 100%; }
}

/* Cart v2: marketplace structure, restrained Fast Toner palette. */
body.ft-cart-page #jas-content { background: #f7f8fa; }
body.ft-cart-page #jas-content .woocommerce { margin-top: -24px; }
body.ft-cart-page .woocommerce-cart-form {
	padding: 0 !important;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}
body.ft-cart-page .woocommerce-cart-form .ft-table-scroll { overflow: visible; }
body.ft-cart-page .woocommerce-cart-form table.shop_table {
	border-collapse: separate;
	border-spacing: 0;
	background: transparent;
}
body.ft-cart-page .woocommerce-cart-form thead { background: #fff; }
body.ft-cart-page .woocommerce-cart-form thead th {
	padding-block: 17px;
	border-bottom: 1px solid #e7eaf0;
	color: #64748b;
	font-size: 14px;
	font-weight: 500;
}
body.ft-cart-page .woocommerce-cart-form thead th:first-child { border-radius: 8px 0 0 8px; }
body.ft-cart-page .woocommerce-cart-form thead th:last-child { border-radius: 0 8px 8px 0; }
body.ft-cart-page .woocommerce-cart-form tbody tr.ft-cart-store-row td {
	padding: 16px 22px;
	border-top: 12px solid #f7f8fa;
	border-bottom: 1px solid #e7eaf0;
	background: #fff;
	font-size: 15px;
}
body.ft-cart-page .woocommerce-cart-form tbody tr.cart_item td {
	border-bottom: 1px solid #e7eaf0;
	background: #fff;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-name a {
	color: #243448;
	font-size: 15px;
	font-weight: 500;
	line-height: 1.5;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-subtotal {
	color: #087449;
	font-size: 16px;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity input.qty {
	text-align: center !important;
}
body.ft-cart-page .woocommerce-cart-form td.actions {
	border: 0;
	background: #fff;
}
body.ft-cart-page .cart-collaterals > .cart_totals {
	position: relative;
	border: 1px solid #e6eaf0;
	border-radius: 8px;
	background: #fff;
	box-shadow: none;
}
body.ft-cart-page .cart_totals h2 {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip-path: inset(50%);
	white-space: nowrap;
}
body.ft-cart-page .cart_totals table.shop_table :is(th, td) {
	padding: 10px 0;
	font-size: 14px;
}
body.ft-cart-page .cart_totals .order-total :is(th, td) { font-size: 18px; }
body.ft-cart-page .cart_totals .wc-proceed-to-checkout .checkout-button {
	border-radius: 8px;
	font-size: 16px;
}
body.ft-cart-page .cross-sells h2 {
	font-size: 18px;
	font-weight: 500;
}

@media (min-width: 901px) {
	body.ft-cart-page .woocommerce-cart-form thead th.product-thumbnail {
		width: 110px;
		padding-left: 22px;
		color: transparent;
	}
	body.ft-cart-page .woocommerce-cart-form thead th.product-thumbnail::before {
		content: 'สินค้า';
		color: #64748b;
	}
	body.ft-cart-page .woocommerce-cart-form thead th.product-name {
		color: transparent;
		text-align: left;
	}
	body.ft-cart-page .woocommerce-cart-form tr.cart_item td { padding-block: 20px; }
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-thumbnail img {
		width: 92px;
		height: 92px;
	}
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-name a {
		display: block;
		max-width: 530px;
	}
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-subtotal { text-align: center; }
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-quantity,
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-removed {
		text-align: center;
		vertical-align: middle;
	}
	body.ft-cart-page .woocommerce-cart-form tr.cart_item .product-quantity .quantity {
		display: inline-block;
		float: none !important;
		margin: 0 !important;
		vertical-align: middle;
	}
	body.ft-cart-page .cart-collaterals { gap: 32px; }
	body.ft-cart-page .cart-collaterals > .cart_totals {
		display: block;
		align-self: stretch;
		width: 100% !important;
		margin-bottom: 68px;
		padding: 20px 28px 24px;
	}
	body.ft-cart-page .cart_totals .ft-table-scroll {
		width: 100%;
	}
	body.ft-cart-page .cart_totals .wc-proceed-to-checkout {
		position: absolute;
		right: 0;
		bottom: -68px;
		width: 220px;
		margin: 0;
		padding: 0;
	}
}

@media (max-width: 900px) {
	body.ft-cart-page .woocommerce-cart-form {
		padding: 0 12px 12px !important;
		border: 1px solid #e6eaf0;
		border-radius: 10px;
		background: #fff;
	}
	body.ft-cart-page .woocommerce-cart-form tbody tr.ft-cart-store-row td {
		border-top: 0;
	}
	body.ft-cart-page .cart-collaterals > .cart_totals { border-radius: 10px; }
	body.ft-cart-page .cart-collaterals > .cart_totals { margin-bottom: 68px; }
	body.ft-cart-page .cart_totals .wc-proceed-to-checkout {
		position: absolute;
		right: 0;
		bottom: -68px;
		width: min(220px, 100%);
		margin: 0;
		padding: 0;
	}
}

/* Single, balanced quantity control on every cart breakpoint. */
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity {
	position: relative;
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 112px !important;
	height: 38px;
	padding: 0 !important;
	border: 1px solid #d7e1eb !important;
	border-radius: 8px !important;
	background: #fff;
	box-shadow: none !important;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > input.qty {
	box-sizing: border-box;
	width: 100% !important;
	height: 36px !important;
	padding: 0 34px !important;
	border: 0 !important;
	border-radius: 8px !important;
	background: transparent !important;
	color: #243448;
	font-size: 15px;
	font-weight: 600;
	line-height: 36px !important;
	text-align: center !important;
	appearance: textfield;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > input.qty::-webkit-inner-spin-button,
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > input.qty::-webkit-outer-spin-button {
	appearance: none;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > div.qty.tc {
	position: absolute !important;
	inset: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > div.qty.tc a {
	top: 0 !important;
	bottom: auto !important;
	display: flex !important;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 100%;
	padding: 0;
	border: 0 !important;
	color: #24435c;
	line-height: 1;
	pointer-events: auto;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > div.qty.tc .minus {
	left: 0 !important;
	right: auto !important;
}
body.ft-cart-page .woocommerce-cart-form tr.cart_item .quantity > div.qty.tc .plus {
	left: auto !important;
	right: 0 !important;
}
