/*
 * shop-common.scss
 * -----------------------------------------------
*/
.woocommerce {
	.product {
		/* Added to Cart Button */
		a.added_to_cart {
			background: #f5f5f5;
			border-radius: 2px;
			color: #333;
			font-size: 11px;
			margin-left: 5px;
			padding: 4px 11px;
			&:hover {
				background-color: #eee;
			}
		}
	}

	/**
	 * Star ratings
	 */
	@include star-rating-function();

	.woocommerce-product-rating {
		@include clearfix();
		line-height: 2;
		display: block;

		.star-rating {
			margin: 0.5em 4px 0 0;
			float: left;
		}
	}

	.products .star-rating {
		display: inline-block;
		margin: 0;
		float: none;
	}

	.hreview-aggregate .star-rating {
		margin: 10px 0 0;
	}

	#review_form #respond {
		@include clearfix();
		position: static;
		margin: 0;
		width: auto;
		padding: 0;
		background: transparent none;
		border: 0;

		.form-submit input {
			left: auto;
		}

		textarea {
			box-sizing: border-box;
			width: 100%;
		}
	}

	p.stars {
		a {
			color: #d3ced2;
			position: relative;
			height: 1em;
			width: 1em;
			text-indent: -999em;
			display: inline-block;
			text-decoration: none;

			&::before {
				display: block;
				position: absolute;
				top: 0;
				left: 0;
				width: 1em;
				height: 1em;
				line-height: 1;
				font-family: "Font Awesome 5 Free";
				font-weight: 500;
				content: '\f005';
				text-indent: 0;
			}

			&:hover ~ a {
				color: #d3ced2;
				&::before {
					content: '\f005';
				}
			}
		}

		&:hover a {
			color: #f9ca63;
			&::before {
				content: '\f005';
			}
		}

		&.selected {
			a.active {
				color: #f9ca63;
				&::before {
					content: '\f005';
				}

				~ a {
					color: #d3ced2;
					&::before {
						content: '\f005';
					}
				}
			}

			a:not( .active ) {
				color: #f9ca63;
				&::before {
					content: '\f005';
				}
			}
		}
	}

	.woocommerce-cart-form,
	.cart {
		.quantity {
			position: relative;
			display: inline-block;
			vertical-align: middle;
			margin: 0 11px 0 0;
			.qty {
				position: relative;
				height: 53px;
				width: 50px;
				padding: 0;
				margin: 0 22px 0 0;
				font-family: inherit;
				line-height: 42px;
				outline: 0;
				border-radius: 2px;
				font-size: 16px;
				display: inline-block;
				vertical-align: middle;
				color: #565969;
				background-color: #e8e8e9;
				border: 1px solid #e8e8e9;
				text-align: center;
				-webkit-user-select: none;
				-webkit-box-sizing: border-box;
				box-sizing: border-box;
			}
			.minus, .plus {
				position: absolute;
				right: 0;
				width: 22px;
				height: 27px;
				line-height: 27px;
				border: 0;
				cursor: pointer;
				-webkit-transition: color .15s ease-in-out;
				-o-transition: color .15s ease-in-out;
				transition: color .15s ease-in-out;
				background-color: var(--theme-color1);
				color: #fff;
				border-color: var(--theme-color1);
				&:hover {
					background-color: var(--theme-color2);
					color: #fff;
					border-color: var(--theme-color2);
				}
			}
			.minus {
				bottom: 0;
				border-bottom-left-radius: 2px;
				border-bottom-right-radius: 2px;
			}
			.plus {
				top: 0;
				border-bottom: 0;
				border-top-left-radius: 2px;
				border-top-right-radius: 2px;
			}
		}
		.wc-cart-action-btns {
			.coupon-form {
				float: left;
			}
			.wc-update-cart-btn {
				float: right;
			}
			@include media-breakpoint-down(sm) {
				.coupon-form {
					input {
						margin-bottom: 10px;
					}
				}
				.wc-update-cart-btn {
				}
			}
		}
	}
}
.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
	.button {
		margin-right: 20px;
	}

	li {
		list-style: none outside !important; // Required for default theme compatibility
		padding-left: 0 !important; // Required for default theme compatibility
		margin-left: 0 !important; // Required for default theme compatibility
	}
}

.woocommerce-error, .woocommerce-info, .woocommerce-message {
	background-color: #f7f6f7;
	color: #515151;
	border-top: 3px solid var(--theme-color1);
	word-wrap: break-word;
	display: flex;
	align-items: center;
	padding: 1.25rem 1.25rem;
	.button {
		background: none;
		padding: 0;
		margin-left: auto;
		padding: 0.5rem 1.1rem !important;
		font-size: 0.8rem;
		order: 2!important;
	}
	.btn-close {
		padding: 1.5rem 1rem;
	}
}
body.single-product.woocommerce {
	.woocommerce-message .button, .woocommerce-error .button, .woocommerce-info .button {
		margin-right: 30px;
	}
}


/* Sale Badge */
.woocommerce {
	.tm-woo-product-item, &.single-product, #yith-quick-view-content {
		.onsale {
			border-radius: 15px;
			background-size: 200% auto;
			text-shadow: 0px 0px 10px rgba(0,0,0,0.2);
			font-size: 1rem;
			position: absolute;
			left: 10px;
			top: 10px;
			text-align: center;
			color: #fff;
			display: block;
			padding: 0 12px;
			text-transform: uppercase;
			z-index: 3;
			@include transition(all 0.3s ease-in-out);
		}
	}
}