/**
 * Logo Carousel – frontend
 */

.lgc-carousel {
	--lgc-gap: 2.5rem;
	--lgc-item-width: 10rem;
	--lgc-item-height: 4.5rem;
	--lgc-speed: 40s;
	--lgc-shift: 0px;
	position: relative;
	width: 100%;
	overflow: hidden;
	padding: 1rem 0;
	mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
}

.lgc-track {
	display: flex;
	align-items: center;
	width: max-content;
	gap: var(--lgc-gap);
	will-change: transform;
}

.lgc-group {
	display: flex;
	align-items: center;
	flex: 0 0 auto;
	gap: var(--lgc-gap);
}

/* Animation starts after JS measures and fills the track. */
.lgc-carousel.lgc-ready:not(.lgc-static) .lgc-track {
	animation: lgc-scroll var(--lgc-speed) linear infinite;
}

.lgc-carousel.lgc-pause-hover:hover .lgc-track,
.lgc-carousel.lgc-paused .lgc-track {
	animation-play-state: paused;
}

.lgc-carousel.lgc-static .lgc-track {
	animation: none;
	flex-wrap: wrap;
	justify-content: center;
	width: 100%;
	max-width: 100%;
}

.lgc-carousel.lgc-static .lgc-group {
	flex-wrap: wrap;
	justify-content: center;
}

.lgc-item {
	flex: 0 0 auto;
	width: var(--lgc-item-width);
	height: var(--lgc-item-height);
	display: flex;
	align-items: center;
	justify-content: center;
}

.lgc-logo-inner {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
}

.lgc-logo-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	text-decoration: none;
	color: inherit;
	transition: opacity 0.2s ease, transform 0.2s ease;
}

.lgc-logo-link:hover,
.lgc-logo-link:focus-visible {
	opacity: 0.75;
	transform: scale(1.04);
	outline: none;
}

.lgc-logo-img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	display: block;
}

.lgc-grayscale .lgc-logo-img {
	filter: grayscale(1);
	opacity: 0.85;
	transition: filter 0.25s ease, opacity 0.25s ease;
}

.lgc-grayscale .lgc-item:hover .lgc-logo-img,
.lgc-grayscale .lgc-logo-link:focus-visible .lgc-logo-img {
	filter: grayscale(0);
	opacity: 1;
}

.lgc-logo-fallback {
	font-size: 0.875rem;
	font-weight: 600;
	text-align: center;
	line-height: 1.2;
	opacity: 0.7;
	padding: 0.25rem;
	word-break: break-word;
}

.lgc-empty {
	margin: 0;
	opacity: 0.8;
}

@keyframes lgc-scroll {
	from {
		transform: translateX(0);
	}
	to {
		transform: translateX(calc(-1 * var(--lgc-shift)));
	}
}

@media (prefers-reduced-motion: reduce) {
	.lgc-carousel.lgc-ready:not(.lgc-static) .lgc-track,
	.lgc-track {
		animation: none;
	}

	.lgc-carousel {
		mask-image: none;
		-webkit-mask-image: none;
	}

	.lgc-carousel .lgc-track {
		flex-wrap: wrap;
		justify-content: center;
		width: 100%;
		max-width: 100%;
	}

	.lgc-carousel .lgc-group {
		flex-wrap: wrap;
		justify-content: center;
	}
}

@media (max-width: 600px) {
	.lgc-carousel {
		--lgc-gap: 1.5rem;
		--lgc-item-width: 7.5rem;
		--lgc-item-height: 3.5rem;
	}
}
