/* -------------------------------------------
	Hotspot
---------------------------------------------- */

@if use_component(hotspot) {
	.hotspot-wrapper {
		color: #fff;
		z-index: 1;
	}

	.hotspot-type1:not(:hover) {
		&::before {
			content: '';
			display: block;
			position: absolute;
			left: 0;
			width: 100%;
			height: 100%;
			background: #fff;
			border-radius: 50%;
			animation: zooming 2s infinite;
		}
	}

	.hotspot-type2:not(:hover) {
		.hotspot {
			animation: zooming2 2s infinite;
		}
	}

	@keyframes zooming {
		0% {
			opacity: 1;
			transform: scale(1);
		}
		100% {
			opacity: 0;
			transform: scale(2.5);
		}
	}

	@keyframes zooming2 {
		0% {
			opacity: 1;
		}
		50% {
			opacity: .5;
		}
		100% {
			opacity: 1;
		}
	}

	.hotspot {
		display: block;
		position: relative;
		text-align: center;
		color: inherit;
		background-color: #222;
		transition: .3s;

		&:hover,
		&:focus {
			color: inherit;
		}

		&.btn-quickview:before {
			content: none;
		}
		
		i {
			line-height: inherit;
		}

		&::after {
			content: '';
			position: absolute;
			display: block;
		}

		.hotspot-left-tooltip &::after {
			top: 0;
			right: 100%;
			height: 100%;
			width: 40px;
		}

		.hotspot-right-tooltip &::after {
			top: 0;
			left: 100%;
			height: 100%;
			width: 40px;
		}

		.hotspot-top-tooltip &::after {
			left: 0;
			bottom: 100%;
			width: 100%;
			height: 40px;
		}

		.hotspot-bottom-tooltip &::after {
			left: 0;
			top: 100%;
			width: 100%;
			height: 40px;
		}
	}

	.hotspot-wrapper {
		.tooltip {
			position: absolute;
			min-width: 240px;
			width: 240px;
			padding: 10px;
			background: #fff;
			color: #222;
			box-shadow: 0 0 30px rgba(0, 0, 0, 0.06);
			visibility: hidden;
			opacity: 0;
			transition: opacity .3s, transform .3s, visibility .3s;
			z-index: 10;
			pointer-events: none;
		}

		&:hover {
			.tooltip {
				visibility: visible;
				opacity: 1;
				pointer-events: all;
			}
			.top-tooltip {
				transform: translateY(-10px);
			}
			.bottom-tooltip {
				transform: translateY(10px);
			}
			.left-tooltip {
				transform: translateX(-10px);
			}
			.right-tooltip {
				transform: translateX(10px);
			}
		}

		.product-body {
			padding: 15px 10px 10px;
		}

		.product .price {
			margin-bottom: 10px;
		}

		.product .product-action {
			position: static;
			opacity: 1;
			visibility: visible;
			transform: none;

			.button {
				width: 100%;
				color: #222;
				background: none;
				border-color: #ccc;
				border-radius: 3px;
				font-size: 13px;
				padding: 10px 0;
				letter-spacing: -0.025em;

				&:hover {
					background: var(--rio-primary-color, #27c);
					border-color: var(--rio-primary-color, #27c);
					color: #fff;
				}
			}
		}

		.product .product_type_simple::before {
			content: "";
			font-family: "riode";
			font-size: 1.4em;
			font-weight: 400;
			line-height: 1;
			margin-#{$right}: 1rem;
			position: relative;
			bottom: 1px;
			vertical-align: middle;
		}
	}

	.top-tooltip {
		bottom: 40px;
		left: -40px;
	}
	.left-tooltip {
		right: 40px;
		top: -40px;
	}
	.right-tooltip {
		left: 40px;
		top: -40px;
	}
	.bottom-tooltip {
		top: 40px;
		left: -40px;
	}
}