@use '../utils' as *;

/*----------------------------------------*/
/*  2.1 Back to top
/*----------------------------------------*/

.backtotop-wrap {
	position: fixed;
	bottom: 30px;
	right: 30px;
	height: 46px;
	width: 46px;
	cursor: pointer;
	display: block;
	border-radius: 50px;
	z-index: 100;
	opacity: 0;
	visibility: hidden;
	@include transform(translateY(20px));
	-webkit-transition: all 400ms linear;
	-o-transition: all 400ms linear;
	transition: all 400ms linear;
	background: var(--rs-theme-orange);
	box-shadow: 0px 0px 2px rgba(0, 0, 0, 0.2);
	&:hover{
		background: #ea3e00;
	}
	&.has-theme-green{
		background: #507a7c;
	}
	&.has-theme-yellow{
		background: var(--rs-theme-yellow);
		&::after{
			color: var(--rs-black);
		}
	}
	&.has-theme-deep-blue{
		background: var(--rs-theme-deep-blue);
		&::after{
			color: var(--rs-white);
		}
	}
	&.has-theme-blue{
		background: var(--rs-theme-blue);
		&::after{
			color: var(--rs-white);
		}
	}
	&.has-theme-light-blue{
		background: var(--rs-theme-light-blue);
		&::after{
			color: var(--rs-white);
		}
	}
	&.has-theme-cyan{
		background: var(--rs-theme-cyan);
		&::after{
			color: var(--rs-white);
		}
	}
	&.has-theme-red{
		background: var(--rs-theme-red);
		&::after{
			color: var(--rs-white);
		}
		&:hover{
			background: var(--rs-black);
		}
	}
	@media #{$xs} {
		bottom: 20px;
		inset-inline-end: 20px;
	} 
	&.active-progress {
		opacity: 1;
		visibility: visible;
		@include transform(translateY(0px));
	}
	&::after {
		position: absolute;
		font-family: var(--rs-ff-fontawesome);
		content: "\f062";
		text-align: center;
		line-height: 46px;
		font-size: 16px;
		font-weight: 400;
		color: var(--rs-white);
		inset-inline-start: 0;
		top: 0;
		height: 46px;
		width: 46px;
		cursor: pointer;
		display: block;
		z-index: 1;
		-webkit-transition: all 400ms linear;
		-o-transition: all 400ms linear;
		transition: all 400ms linear;
	}
	svg {
		path {
			fill: none;
		}
		&.backtotop-circle {
			path {
				stroke: #ccc;
				stroke-width: 0;
				-webkit-box-sizing: border-box;
				box-sizing: border-box;
				-webkit-transition: all 400ms linear;
				-o-transition: all 400ms linear;
				transition: all 400ms linear;
			}
		}
	}
}


