/* Motion Kit — Odometer Stats. Needs core.css.
   Each digit column shows one cell of a 20-cell reel (0–9 twice). The reel rests on its final digit
   in the second set; before .is-in (added by odometer.js on first view) it waits at the first 0,
   so the roll passes one full turn plus the digit. Rightmost digits start a little later. */

.mkit-odo {
	--cell: 1em;
	width: 100%;
	color: var(--mkit-muted);
}

.mkit-odo__list {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr));
	gap: clamp(1.5rem, 3vw, 2.75rem);
	margin: 0;
	padding: 0;
	list-style: none;
}

.mkit-odo--center .mkit-odo__item {
	align-items: center;
	text-align: center;
}

.mkit-odo__item {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: .6rem;
	margin: 0;
}

.mkit-odo--rules .mkit-odo__item {
	padding-top: 1.1rem;
	border-top: 1px solid var(--mkit-line);
}

.mkit-odo--rules .mkit-odo__item::before {
	content: "";
	position: absolute;
	top: -1px;
	left: 0;
	width: 2.75rem;
	height: 2px;
	background: var(--mkit-accent);
	transform-origin: 0 50%;
}

.mkit-odo--center.mkit-odo--rules .mkit-odo__item::before {
	left: calc(50% - 1.375rem);
	transform-origin: 50% 50%;
}

.mkit-odo__value {
	color: var(--mkit-text);
	font-size: clamp(2.6rem, 1.7rem + 3.4vw, 4.75rem);
	font-weight: 600;
	line-height: 1;
	letter-spacing: -.04em;
	font-variant-numeric: tabular-nums;
}

.mkit-odo__digits {
	display: inline-flex;
	align-items: flex-start;
}

.mkit-odo__col {
	display: inline-block;
	width: 1ch;
	height: var(--cell);
	overflow: hidden;
}

.mkit-odo__reel {
	display: flex;
	flex-direction: column;
	translate: 0 calc((var(--d) + 10) * var(--cell) * -1);
}

.mkit-odo__reel i {
	display: block;
	height: var(--cell);
	font-style: normal;
	line-height: var(--cell);
	text-align: center;
}

.mkit-odo__sep {
	display: inline-block;
	height: var(--cell);
	line-height: var(--cell);
}

.mkit-odo__affix {
	display: inline-block;
	height: var(--cell);
	margin-inline: .04em;
	line-height: var(--cell);
	color: var(--mkit-accent-soft);
	font-size: .7em;
	letter-spacing: -.02em;
	align-self: flex-start;
	padding-top: .08em;
}

.mkit-odo__label {
	max-width: 24ch;
	font-size: .975rem;
	line-height: 1.45;
}

@media (prefers-reduced-motion: no-preference) {
	.mkit-js .mkit-odo:not(.is-in) .mkit-odo__reel {
		translate: 0 0;
	}
	.mkit-js .mkit-odo:not(.is-in) :is(.mkit-odo__affix, .mkit-odo__sep, .mkit-odo__label) {
		opacity: 0;
	}
	.mkit-js .mkit-odo--rules:not(.is-in) .mkit-odo__item::before {
		scale: 0 1;
	}
	.mkit-odo.is-in .mkit-odo__reel {
		transition: translate var(--mkit-dur, 1.8s) cubic-bezier(.16, 1, .3, 1);
		transition-delay: calc(var(--j, 0) * 120ms + var(--k, 0) * 70ms);
	}
	.mkit-odo.is-in :is(.mkit-odo__affix, .mkit-odo__sep, .mkit-odo__label) {
		transition: opacity .6s var(--mkit-ease);
		transition-delay: calc(var(--j, 0) * 120ms + var(--mkit-dur, 1.8s) * .45);
	}
	.mkit-odo.is-in .mkit-odo__item::before {
		transition: scale .9s var(--mkit-ease);
		transition-delay: calc(var(--j, 0) * 120ms);
	}
}
