/**
 * WooCommerce side cart drawer.
 */

.gd-side-cart-overlay {
	position: fixed;
	inset: 0;
	z-index: 10040;
	background: rgba(0, 0, 0, 0.65);
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.3s ease;
}

.gd-side-cart {
	position: fixed;
	top: 16px;
	bottom: 16px;
	width: 360px;
	max-width: calc(100vw - 24px);
	max-height: calc(100vh - 32px);
	height: auto;
	background: #fff;
	border-radius: 22px;
	overflow: hidden;
	box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
	z-index: 999999;
	opacity: 0;
	pointer-events: none;
	transition: transform 0.32s ease, opacity 0.25s ease;
	display: flex;
	flex-direction: column;
}

html[dir="ltr"] .gd-side-cart,
body:not(.rtl) .gd-side-cart {
	right: 16px;
	left: auto;
	transform: translateX(calc(100% + 24px));
}

html[dir="rtl"] .gd-side-cart,
body.rtl .gd-side-cart {
	left: 16px;
	right: auto;
	transform: translateX(calc(-100% - 24px));
}

body.rtl .gd-side-cart {
	left: 16px;
	right: auto;
	transform: translateX(calc(-100% - 24px));
}

html[dir="ltr"] body.gd-side-cart-open .gd-side-cart,
body:not(.rtl).gd-side-cart-open .gd-side-cart {
	transform: translateX(0);
}

html[dir="rtl"] body.gd-side-cart-open .gd-side-cart,
body.rtl.gd-side-cart-open .gd-side-cart {
	transform: translateX(0);
}

body.gd-side-cart-open .gd-side-cart,
body.gd-side-cart-open .gd-side-cart-overlay {
	opacity: 1;
	pointer-events: auto;
}

html.gd-side-cart-lock,
html.gd-side-cart-lock body {
	overflow: hidden;
}

.gd-side-cart__shell {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
}

.gd-side-cart__header {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: space-between;
	height: 82px;
	padding: 0 18px;
	border-bottom: 1px solid #eee;
}

html[dir="rtl"] .gd-side-cart__header,
body.rtl .gd-side-cart__header {
	flex-direction: row-reverse;
}

.gd-side-cart__title {
	margin: 0;
	color: #1F2A3A;
	font-size: 1.375rem;
	font-weight: 800;
	line-height: 1.2;
}

.gd-side-cart__close {
	display: inline-flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: #1F2A3A;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.gd-side-cart__close:hover,
.gd-side-cart__close:focus-visible {
	background: #F0F0EE;
	color: #1F2A3A;
	outline: none;
}

.gd-side-cart__dynamic {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
	overflow: hidden;
}

.gd-side-cart__body {
	flex: 1 1 auto;
	min-height: 0;
	overflow-y: auto;
	overscroll-behavior: contain;
}

.gd-side-cart__items {
	margin: 0;
	padding: 16px 0 8px;
	list-style: none;
}

.gd-side-cart__item {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 86px;
	margin: 12px 16px;
	padding: 10px 12px;
	border-radius: 15px;
	background: #F0F0EE;
}

html[dir="ltr"] .gd-side-cart__item,
body:not(.rtl) .gd-side-cart__item {
	direction: ltr;
	flex-direction: row;
}

html[dir="rtl"] .gd-side-cart__item,
body.rtl .gd-side-cart__item {
	direction: rtl;
	flex-direction: row;
}

.gd-side-cart__thumb {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	width: 58px;
	height: 58px;
	border-radius: 12px;
	background: #fff;
	overflow: hidden;
	text-decoration: none;
}

.gd-side-cart__thumb-img,
.gd-side-cart__thumb img {
	display: block;
	width: 58px;
	height: 58px;
	object-fit: contain;
}

.gd-side-cart__content {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
}

html[dir="rtl"] .gd-side-cart__content,
body.rtl .gd-side-cart__content {
	direction: rtl;
	align-items: flex-start !important;
	text-align: right !important;
}

html[dir="ltr"] .gd-side-cart__content,
body:not(.rtl) .gd-side-cart__content {
	align-items: flex-start;
	text-align: left;
}

.gd-side-cart__name {
	display: block;
	width: 100%;
	margin: 0 0 6px;
	color: #1F2A3A;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
	text-align: inherit;
	text-decoration: none;
}

html[dir="rtl"] .gd-side-cart__name,
body.rtl .gd-side-cart__name {
	text-align: right;
	width: 100%;
}

.gd-side-cart__name:hover {
	color: #E73F1E;
}

.gd-side-cart__meta {
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: 8px;
	margin-top: 6px;
	width: 100%;
	direction: ltr;
	unicode-bidi: isolate;
	text-align: left;
}

html[dir="rtl"] .gd-side-cart__meta,
body.rtl .gd-side-cart__meta {
	direction: ltr;
	justify-content: flex-end;
	text-align: right;
	width: 100%;
}

.gd-side-cart__multiply {
	color: #1F2A3A;
	font-size: 13px;
	font-weight: 600;
	line-height: 1;
	opacity: 0.75;
}

.gd-side-cart__price {
	color: #E73F1E;
	font-size: 13px;
	font-weight: 800;
	line-height: 1.2;
}

.gd-side-cart__price .amount {
	color: inherit;
	font-weight: inherit;
}

.gd-side-cart__qty {
	color: #1F2A3A;
	font-size: 13px;
	font-weight: 600;
	opacity: 0.75;
}

.gd-side-cart__remove {
	display: inline-flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	margin-inline-start: auto;
	color: #b00000;
	font-size: 1.125rem;
	font-weight: 700;
	line-height: 1;
	text-decoration: none;
	transition: color 0.2s ease, opacity 0.2s ease;
}

html[dir="rtl"] .gd-side-cart__remove,
body.rtl .gd-side-cart__remove {
	margin-inline-start: 0;
	margin-inline-end: 0;
}

.gd-side-cart__remove:hover,
.gd-side-cart__remove:focus-visible {
	color: #8a0000;
	opacity: 0.85;
	outline: none;
}

.gd-side-cart__remove.is-loading {
	pointer-events: none;
	opacity: 0.45;
}

.gd-side-cart__empty {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 48px 24px;
	color: #1F2A3A;
	font-size: 1rem;
	font-weight: 600;
	text-align: center;
}

.gd-side-cart__footer {
	flex-shrink: 0;
	margin-top: auto;
	padding: 16px;
	border-top: 1px solid #eee;
	background: #fff;
}

.gd-side-cart__subtotal {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 14px;
	color: #1F2A3A;
	font-size: 1rem;
	font-weight: 700;
}

.gd-side-cart__subtotal-amount {
	color: #E73F1E;
	font-size: 1.0625rem;
	font-weight: 800;
}

.gd-side-cart__subtotal-amount .amount {
	color: inherit;
	font-weight: inherit;
}

.gd-side-cart__actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.gd-side-cart__button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 54px;
	border: 0;
	border-radius: 12px;
	background: #E73F1E;
	color: #fff;
	font-size: 0.9375rem;
	font-weight: 800;
	line-height: 1;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.gd-side-cart__button--checkout {
	background: #1F2A3A;
}

.gd-side-cart__button:hover,
.gd-side-cart__button:focus-visible {
	background: #1F2A3A;
	color: #fff;
	outline: none;
}

@media (max-width: 575px) {
	.gd-side-cart {
		top: 10px;
		bottom: 10px;
		width: calc(100vw - 20px);
		max-width: calc(100vw - 20px);
		max-height: calc(100vh - 20px);
		border-radius: 18px;
	}

	html[dir="ltr"] .gd-side-cart,
	body:not(.rtl) .gd-side-cart {
		right: 10px;
		left: auto;
		transform: translateX(calc(100% + 20px));
	}

	html[dir="rtl"] .gd-side-cart,
	body.rtl .gd-side-cart {
		left: 10px;
		right: auto;
		transform: translateX(calc(-100% - 20px));
	}

	body.rtl .gd-side-cart {
		left: 10px;
		right: auto;
		transform: translateX(calc(-100% - 20px));
	}

	html[dir="ltr"] body.gd-side-cart-open .gd-side-cart,
	body:not(.rtl).gd-side-cart-open .gd-side-cart {
		transform: translateX(0);
	}

	html[dir="rtl"] body.gd-side-cart-open .gd-side-cart,
	body.rtl.gd-side-cart-open .gd-side-cart {
		transform: translateX(0);
	}

}
