/**
 * Numbered checkout steps. Every step stays visible, including on small screens.
 */

.wd-checkout-steps {
	--wd-link-color: inherit;
	--wd-link-color-hover: inherit;
	--wd-link-decor: none;
	--wd-link-decor-hover: none;
	--list-mb: 0;
	--li-pl: 0;
	--li-mb: 0;

	counter-reset: wpd-step;
	display: flex !important;
	flex-wrap: nowrap !important;
	justify-content: space-between;
	align-items: flex-start;
	gap: 0;
	width: 100%;
	max-width: 720px;
	margin: 8px auto 12px;
	padding: 0 8px;
	list-style: none;
	text-transform: none;
	letter-spacing: 0;
	font-size: 13px;
	font-weight: 500;
	font-style: normal;
	color: inherit;
	box-sizing: border-box;
}

body .wd-checkout-steps li,
body .wd-checkout-steps li.step-inactive,
body .wd-checkout-steps li.step-active,
body .wd-checkout-steps li.step-complete {
	counter-increment: wpd-step;
	position: relative;
	display: flex !important;
	flex: 1 1 0;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	min-width: 0;
	opacity: 1 !important;
	visibility: visible !important;
}

.wd-checkout-steps li > :is(a, span) {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	width: 100%;
	color: inherit;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.25;
	text-align: center;
	text-decoration: none !important;
	text-transform: none;
	opacity: 1 !important;
}

.wd-checkout-steps li > :is(a, span)::before {
	content: counter(wpd-step);
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border: 1.5px solid #d0d5dd;
	border-radius: 999px;
	background: #fff;
	color: #344054;
	font-size: 13px;
	font-weight: 600;
	line-height: 1;
	text-decoration: none;
}

.wd-checkout-steps li.step-active > :is(a, span)::before {
	border-color: var(--wpd-step-active-bg, #1d1d1f);
	background: var(--wpd-step-active-bg, #1d1d1f);
	color: var(--wpd-step-active-text, #fff);
}

.wd-checkout-steps li.step-complete:not(.step-active):not(.step-inactive) > :is(a, span)::before {
	content: "✓";
	border-color: var(--wpd-step-active-bg, #1d1d1f);
	background: var(--wpd-step-active-bg, #1d1d1f);
	color: var(--wpd-step-active-text, #fff);
}

.wd-checkout-steps li:not(:last-child)::after {
	content: "" !important;
	position: absolute;
	top: 14px;
	left: calc(50% + 18px);
	width: calc(100% - 36px);
	height: 2px;
	background: #e4e7ec;
	font-family: inherit !important;
	font-size: 0 !important;
	font-weight: 400;
	opacity: 1 !important;
}

.wd-checkout-steps li.step-active > :is(a, span),
.wd-checkout-steps .step-active > :is(a, span) {
	text-decoration: none !important;
	opacity: 1 !important;
}

@media (max-width: 768.98px) {
	.wd-checkout-steps {
		max-width: none;
		margin-bottom: 8px;
		padding: 0 4px;
		font-size: 11px;
	}

	body .wd-checkout-steps li,
	body .wd-checkout-steps li.step-inactive,
	body .wd-checkout-steps li:not(.step-active) {
		display: flex !important;
	}

	.wd-checkout-steps li > :is(a, span) {
		font-size: 10px;
		gap: 6px;
		white-space: nowrap !important;
		word-break: keep-all;
	}

	.wd-checkout-steps li.step-pad {
		flex: 1.35 1 0;
	}

	.wd-checkout-steps li > :is(a, span)::before {
		width: 26px;
		height: 26px;
		font-size: 12px;
	}

	.wd-checkout-steps li:not(:last-child)::after {
		top: 13px;
		left: calc(50% + 16px);
		width: calc(100% - 32px);
	}
}
