/**
 * BIGBAT58 — Phase 12D premium footer
 */

.bb58-footer--premium {
	--bb58-footer-pad-y: clamp(3.75rem, 5vw, 5rem);
	--bb58-footer-pad-top: clamp(1.75rem, 3vw, 2.5rem);
	--bb58-footer-pad-bottom: clamp(0.25rem, 0.75vw, 0.5rem);
	--bb58-footer-col-gap: clamp(1.75rem, 3vw, 2.75rem);
	--bb58-footer-link-gap: 0.55rem;
	margin-top: clamp(1.5rem, 3vw, 2rem);
	position: relative;
	overflow: hidden;
	border-top: 1px solid color-mix(in srgb, var(--color-primary) 22%, transparent);
	background-color: color-mix(in srgb, var(--color-background) 88%, #000);
	background-image:
		var(--bb58-footer-bg-image, none),
		radial-gradient(ellipse 120% 80% at 50% -20%, color-mix(in srgb, var(--color-primary) 14%, transparent), transparent 55%),
		linear-gradient(
			180deg,
			color-mix(in srgb, var(--color-secondary) 92%, #000) 0%,
			color-mix(in srgb, var(--color-background) 96%, #000) 100%
		);
	background-size: cover, auto, auto;
	background-position: center, center, center;
}

.bb58-footer--premium::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background: linear-gradient(
		90deg,
		transparent 0%,
		color-mix(in srgb, var(--color-primary) 6%, transparent) 50%,
		transparent 100%
	);
	opacity: 0.65;
}

.bb58-footer--premium > * {
	position: relative;
	z-index: 1;
}

.bb58-footer__main {
	padding-top: var(--bb58-footer-pad-top);
	padding-bottom: var(--bb58-footer-pad-bottom);
}

.bb58-footer__grid {
	display: grid;
	gap: var(--bb58-footer-col-gap);
}

.bb58-footer__column {
	min-width: 0;
}

.bb58-footer__heading {
	margin: 0 0 1rem;
	font-size: 0.8125rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--color-primary);
}

.bb58-footer__heading::after {
	content: "";
	display: block;
	width: 2.25rem;
	height: 2px;
	margin-top: 0.55rem;
	border-radius: 999px;
	background: linear-gradient(
		90deg,
		var(--color-primary),
		color-mix(in srgb, var(--color-primary) 20%, transparent)
	);
}

.bb58-footer__logo {
	display: inline-block;
	margin-bottom: 1rem;
	line-height: 0;
	transition: opacity 0.2s ease, transform 0.2s ease;
}

.bb58-footer__logo:hover,
.bb58-footer__logo:focus-visible {
	opacity: 0.92;
	transform: translateY(-1px);
}

.bb58-footer__logo-img {
	width: auto;
	max-width: min(100%, 168px);
	max-height: 52px;
	object-fit: contain;
}

.bb58-footer__description,
.bb58-footer__intro,
.bb58-footer__support {
	margin: 0 0 0.85rem;
	font-size: 0.9375rem;
	line-height: 1.55;
	color: color-mix(in srgb, var(--color-text) 78%, transparent);
}

.bb58-footer__intro {
	max-width: 36ch;
}

.bb58-footer__support {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 0.65rem;
	max-width: 38ch;
	font-size: 0.875rem;
}

.bb58-footer__support-badge {
	display: inline-flex;
	align-items: center;
	padding: 0.2rem 0.55rem;
	border-radius: 999px;
	border: 1px solid color-mix(in srgb, var(--color-primary) 45%, transparent);
	background: color-mix(in srgb, var(--color-primary) 12%, transparent);
	color: var(--color-primary);
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	white-space: nowrap;
}

.bb58-footer__social {
	display: flex;
	flex-wrap: wrap;
	gap: 0.55rem;
	margin-top: 0.35rem;
}

.bb58-footer__social-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	height: 2.25rem;
	border-radius: 50%;
	border: 1px solid color-mix(in srgb, var(--color-primary) 28%, transparent);
	background: color-mix(in srgb, var(--color-secondary) 70%, transparent);
	color: color-mix(in srgb, var(--color-text) 82%, transparent);
	text-decoration: none;
	transition:
		color 0.2s ease,
		border-color 0.2s ease,
		background-color 0.2s ease,
		transform 0.2s ease,
		box-shadow 0.2s ease;
}

.bb58-footer__social-link:hover,
.bb58-footer__social-link:focus-visible {
	color: var(--color-primary);
	border-color: color-mix(in srgb, var(--color-primary) 55%, transparent);
	background: color-mix(in srgb, var(--color-primary) 10%, var(--color-secondary));
	transform: translateY(-2px);
	box-shadow: 0 6px 18px color-mix(in srgb, var(--color-primary) 18%, transparent);
}

.bb58-footer__links {
	display: grid;
	gap: var(--bb58-footer-link-gap);
	list-style: none;
	margin: 0;
	padding: 0;
}

.bb58-footer__link {
	display: inline-block;
	color: color-mix(in srgb, var(--color-text) 84%, transparent);
	font-size: 0.9375rem;
	line-height: 1.35;
	text-decoration: none;
	transition: color 0.2s ease, transform 0.2s ease;
}

.bb58-footer__link:hover,
.bb58-footer__link:focus-visible {
	color: var(--color-primary);
	transform: translateX(3px);
}

.bb58-footer__providers {
	--bb58-footer-marquee-gap: clamp(2.5rem, 4vw, 3.75rem);
	--bb58-footer-marquee-logo-h: clamp(1.875rem, 3.2vw, 2.25rem);
	--bb58-footer-marquee-duration: 55s;
	margin-top: 0;
	padding: 0.35rem 0 1.65rem;
	border-top: 1px solid color-mix(in srgb, var(--color-primary) 16%, transparent);
	border-bottom: 1px solid color-mix(in srgb, var(--color-primary) 16%, transparent);
	background: color-mix(in srgb, var(--color-background) 70%, #000);
}

.bb58-footer__providers-label {
	margin: 0 0 0.85rem;
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: color-mix(in srgb, var(--color-primary) 80%, var(--color-text));
	text-align: center;
}

.bb58-footer__providers-marquee {
	position: relative;
	overflow: hidden;
	width: 100%;
	mask-image: linear-gradient(
		90deg,
		transparent 0%,
		#000 6%,
		#000 94%,
		transparent 100%
	);
	-webkit-mask-image: linear-gradient(
		90deg,
		transparent 0%,
		#000 6%,
		#000 94%,
		transparent 100%
	);
}

.bb58-footer__providers-track {
	display: flex;
	width: max-content;
	align-items: center;
	will-change: transform;
	animation: bb58-footer-marquee-scroll var(--bb58-footer-marquee-duration) linear infinite;
}

.bb58-footer__providers-marquee:hover .bb58-footer__providers-track,
.bb58-footer__providers-marquee:focus-within .bb58-footer__providers-track {
	animation-play-state: paused;
}

.bb58-footer__providers-row {
	display: flex;
	flex-wrap: nowrap;
	flex-shrink: 0;
	align-items: center;
	gap: var(--bb58-footer-marquee-gap);
	list-style: none;
	margin: 0;
	padding: 0 0 0 var(--bb58-footer-marquee-gap);
}

.bb58-footer__providers-item {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
}

.bb58-footer__provider-link {
	display: flex;
	align-items: center;
	justify-content: center;
	height: var(--bb58-footer-marquee-logo-h);
	padding: 0.15rem 0;
	text-decoration: none;
	transition:
		filter 0.28s ease,
		transform 0.28s ease;
}

.bb58-footer__provider-logo {
	display: block;
	width: auto;
	height: var(--bb58-footer-marquee-logo-h);
	max-width: none;
	max-height: var(--bb58-footer-marquee-logo-h);
	object-fit: contain;
	object-position: center;
	filter: grayscale(1) brightness(0.92);
	opacity: 0.72;
	transition:
		filter 0.28s ease,
		opacity 0.28s ease,
		transform 0.28s ease;
}

.bb58-footer__provider-link:hover .bb58-footer__provider-logo,
.bb58-footer__provider-link:focus-visible .bb58-footer__provider-logo {
	filter: none;
	opacity: 1;
	transform: scale(1.05);
}

.bb58-footer__provider-link:hover,
.bb58-footer__provider-link:focus-visible {
	filter: drop-shadow(0 0 10px color-mix(in srgb, var(--color-primary) 55%, transparent));
	transform: scale(1.02);
}

@keyframes bb58-footer-marquee-scroll {
	from {
		transform: translate3d(0, 0, 0);
	}

	to {
		transform: translate3d(-50%, 0, 0);
	}
}

@media (min-width: 768px) {
	.bb58-footer__providers {
		--bb58-footer-marquee-logo-h: clamp(2.625rem, 3vw, 3.125rem);
	}
}

.bb58-footer__bottom {
	padding: 0.95rem 0 1.1rem;
	background: color-mix(in srgb, var(--color-background) 94%, #000);
}

.bb58-footer__bottom-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.85rem 1.25rem;
}

.bb58-footer__copyright {
	margin: 0;
	font-size: 0.8125rem;
	color: color-mix(in srgb, var(--color-text) 62%, transparent);
}

.bb58-footer__legal-list {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.35rem 0.85rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.bb58-footer__legal-link {
	color: color-mix(in srgb, var(--color-text) 72%, transparent);
	font-size: 0.8125rem;
	text-decoration: none;
	transition: color 0.2s ease;
}

.bb58-footer__legal-link:hover,
.bb58-footer__legal-link:focus-visible {
	color: var(--color-primary);
}

.bb58-lang-switcher--footer {
	margin-inline: auto;
}

@media (min-width: 768px) {
	.bb58-footer__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.bb58-footer__column--brand {
		grid-column: 1 / -1;
	}
}

@media (min-width: 1024px) {
	.bb58-footer__grid {
		grid-template-columns: minmax(0, 1.35fr) repeat(3, minmax(0, 1fr));
		align-items: start;
	}

	.bb58-footer__column--brand {
		grid-column: auto;
		padding-right: 0.5rem;
	}
}

@media (max-width: 767px) {
	.bb58-footer__column,
	.bb58-footer__providers-label,
	.bb58-footer__bottom-inner {
		text-align: center;
	}

	.bb58-footer__heading::after {
		margin-inline: auto;
	}

	.bb58-footer__description,
	.bb58-footer__intro,
	.bb58-footer__support {
		margin-inline: auto;
	}

	.bb58-footer__social {
		justify-content: center;
	}

	.bb58-footer__bottom-inner {
		flex-direction: column;
		justify-content: center;
	}

	.bb58-footer__legal-list {
		justify-content: center;
	}

	.bb58-lang-switcher--footer {
		justify-content: center;
	}
}

@media (prefers-reduced-motion: reduce) {
	.bb58-footer__logo,
	.bb58-footer__social-link,
	.bb58-footer__link,
	.bb58-footer__provider-link,
	.bb58-footer__provider-logo {
		transition: none;
	}

	.bb58-footer__providers-track {
		animation: none;
		transform: none;
	}

	.bb58-footer__providers-marquee {
		overflow-x: auto;
		mask-image: none;
		-webkit-mask-image: none;
	}

	.bb58-footer__link:hover,
	.bb58-footer__link:focus-visible,
	.bb58-footer__social-link:hover,
	.bb58-footer__social-link:focus-visible,
	.bb58-footer__provider-link:hover,
	.bb58-footer__provider-link:focus-visible {
		transform: none;
	}
}
