@import "settings/variables";
@import "settings/mixins";

@keyframes gradationSignal {
	0% {
		opacity: 1;
		transform: scale(0);
	}

	100% {
		transform: scale(1);
		opacity: 0;
	}
}

.civi-gradation {
	.count-wrap {
		position: relative;
		width: 46px;
		height: 46px;
		&:before,
		&:after {
			content: "";
			position: absolute;
			left: -25px;
			top: -25px;
			opacity: 0;
			width: 100px;
			height: 100px;
			border-radius: 50%;
			pointer-events: none;
			border: 1px solid $accent_color;
			transform-origin: 50% 50%;
			animation-timing-function: cubic-bezier(0, 0.55, 0.55, 1);
			animation-duration: 2s;
			animation-fill-mode: forwards;
			animation-iteration-count: infinite;
		}

		&:after {
			animation-delay: 0.75s;
		}
	}

	.content-wrap {
		margin-left: 60px;
	}

	.count {
		@extend %NormalTransition;
		position: absolute;
		top: 50%;
		left: 0;
		width: 50px;
		height: 50px;
		line-height: 48px;
		border-radius: 50%;
		text-align: center;
		transform: translate(0, -50%);
		z-index: 3;
		background: #f2f8f7;
		border: 1px solid #f2f8f7;
		color: $accent_color;
		font-size: 24px;
		font-weight: 600;
	}

	.item {
		@include d-flex();
		&:last-child {
			.line {
				&:before {
					display: none;
				}
			}
		}

		&:hover {
			.count {
				border-color: transparent;
			}

			.count-wrap {
				&:before,
				&:after {
					animation-name: gradationSignal;
				}
			}
		}

		+ .item {
			margin-top: 38px;
		}
	}

	.line {
		&:before {
			content: "";
			position: absolute;
			top: 70px;
			left: 23px;
			border-left: 2px solid #ffd75e;
			width: 2px;
			height: 60px;
			display: inline-block;
		}
	}

	.title {
		font-size: 24px;
		line-height: 1.25;
		margin-bottom: 8px;
		mark {
			color: $accent_color;
			background-color: transparent;
		}
	}
}
