/* Component: totop — green back-to-top button on the right edge of the copyright bar. */

.hg-totop {
	position: absolute;
	right: 0;
	z-index: 9;
	display: block;
	background: var(--hg-green);
}

.hg-totop::after {
	content: "";
	position: absolute;
	width: 16px;
	height: 16px;
	background: url("../../img/totop.svg") 50% 0 no-repeat;
}

@media (min-width: 767px) {
	.hg-totop {
		top: 0;
		width: 70px;
		height: 100%;
		border-radius: 0 0 4px;
	}

	.hg-totop::before {
		content: "";
		position: absolute;
		top: 50%;
		left: 50%;
		width: 2px;
		height: 0;
		margin-left: -1px;
		transition: height 0.25s, margin 0.25s;
	}

	.hg-totop::after {
		top: 50%;
		display: block;
		width: 100%;
		margin-top: -8px;
		line-height: 0;
		transition: margin 0.2s;
	}

	.hg-totop:hover::before,
	.hg-totop:focus::before {
		height: 16px;
		margin-top: -8px;
		background: var(--hg-text-inverse);
	}

	.hg-totop:hover::after,
	.hg-totop:focus::after {
		margin-top: -12px;
	}
}

@media (max-width: 767px) {
	.hg-copyright .hg-totop {
		bottom: 35px;
		width: 40px;
		height: 40px;
		margin-bottom: 20px;
	}

	.hg-copyright .hg-totop::after {
		top: 14px;
		left: 14px;
	}
}

@media (max-width: 413px) {
	.hg-copyright .hg-totop {
		bottom: -20px;
	}
}
