/* ===========================
   Maysa Cart Random Products
=========================== */

.woocommerce-cart-form .mcrp-row > .mcrp-cell {
	padding: 0 0 24px !important;
	border: 0 !important;
	background: transparent !important;
	text-align: right;
}

.mcrp-box {
	box-sizing: border-box;
	width: 100%;
	margin: 12px 0 0;
	padding: 18px;
	overflow: hidden;
	border: 1px solid #e8e8e8;
	border-radius: 14px;
	background: #fff;
	box-shadow: 0 4px 18px rgba(0, 0, 0, .04);
}

.mcrp-box *,
.mcrp-box *::before,
.mcrp-box *::after {
	box-sizing: border-box;
}

.mcrp-header {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 16px;
}

.mcrp-icon {
	flex: 0 0 auto;
	font-size: 18px;
	line-height: 1;
}

.mcrp-title {
	color: #222;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.7;
}

.mcrp-products {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px;
	width: 100%;
}

.mcrp-card {
	display: flex;
	min-width: 0;
	flex-direction: column;
	align-items: stretch;
	padding: 12px;
	border: 1px solid #ededed;
	border-radius: 12px;
	background: #fff;
	text-align: center;
	transition: box-shadow .2s ease, transform .2s ease;
}

.mcrp-card:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 22px rgba(0, 0, 0, .08);
}

.mcrp-image {
	display: block;
	margin-bottom: 10px;
	overflow: hidden;
	border-radius: 9px;
	aspect-ratio: 1 / 1;
}

.mcrp-image img {
	display: block;
	width: 100%;
	height: 100%;
	margin: 0;
	object-fit: cover;
}

.mcrp-name {
	display: -webkit-box;
	min-height: 42px;
	margin-bottom: 8px;
	overflow: hidden;
	color: #222;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.6;
	text-decoration: none;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
}

.mcrp-name:hover {
	color: var(--wd-primary-color, #c62828);
}

.mcrp-price {
	margin: auto 0 12px;
	color: #111;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.6;
}

.mcrp-price del {
	opacity: .6;
}

.mcrp-button {
	width: 100%;
}

.mcrp-button .button,
.mcrp-button .add_to_cart_button {
	display: inline-flex;
	width: 100%;
	min-height: 40px;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 8px 10px;
	border-radius: 9px;
	font-size: 12px;
	font-weight: 600;
	line-height: 1.4;
	white-space: normal;
}

@media (max-width: 768px) {
	.woocommerce-cart-form .mcrp-row {
		display: block !important;
		width: 100%;
	}

	.woocommerce-cart-form .mcrp-row > .mcrp-cell {
		display: block !important;
		width: 100% !important;
		padding: 0 0 18px !important;
	}

	.mcrp-box {
		width: 100%;
		margin-top: 8px;
		padding: 14px;
		border-radius: 12px;
	}

	.mcrp-header {
		margin-bottom: 12px;
	}

	.mcrp-title {
		font-size: 13px;
	}

	.mcrp-products {
		display: flex;
		gap: 10px;
		margin: 0;
		padding: 0 0 8px;
		overflow-x: auto;
		overflow-y: hidden;
		scroll-behavior: smooth;
		scroll-snap-type: x mandatory;
		-webkit-overflow-scrolling: touch;
	}

	.mcrp-products::-webkit-scrollbar {
		height: 4px;
	}

	.mcrp-products::-webkit-scrollbar-thumb {
		border-radius: 10px;
		background: #d8d8d8;
	}

	.mcrp-card {
		flex: 0 0 72%;
		max-width: 210px;
		min-width: 160px;
		padding: 10px;
		scroll-snap-align: start;
	}

	.mcrp-card:hover {
		transform: none;
		box-shadow: none;
	}

	.mcrp-button .button,
	.mcrp-button .add_to_cart_button {
		min-height: 38px;
		font-size: 11px;
	}
}

@media (max-width: 390px) {
	.mcrp-box {
		padding: 12px;
	}

	.mcrp-card {
		flex-basis: 78%;
		min-width: 150px;
	}
}
