/* Two endless logo rows (same look as the original HTML widget). */
.hylm-wrapper {
	--hylm-height: 90px;
	--hylm-gap: 25px;
	--hylm-fade: 150px;
	direction: ltr; /* Keeps the math the same on RTL pages. */
	position: relative;
	width: 100%;
	overflow: hidden;
	padding: 20px 0;
	background: transparent;
}

.hylm-wrapper::before,
.hylm-wrapper::after {
	content: "";
	position: absolute;
	top: 0;
	z-index: 10;
	width: var(--hylm-fade);
	height: 100%;
	pointer-events: none;
}

.hylm-wrapper::before {
	left: 0;
	background: linear-gradient(to right, #fff, rgba(255, 255, 255, 0));
}

.hylm-wrapper::after {
	right: 0;
	background: linear-gradient(to left, #fff, rgba(255, 255, 255, 0));
}

.hylm-track {
	display: block;
	overflow: hidden;
	width: 100%;
	height: var(--hylm-height);
	margin: 0;
	padding: 0;
	user-select: none;
}

.hylm-track + .hylm-track {
	margin-top: 30px;
}

.hylm-content {
	display: flex;
	flex-shrink: 0;
	width: max-content;
	height: 100%;
	will-change: transform;
	backface-visibility: hidden; /* Keeps the row on its own GPU layer in Safari. */
}

.hylm-left {
	animation: hylm-left var(--hylm-duration, 40s) linear infinite;
}

.hylm-right {
	animation: hylm-right var(--hylm-duration, 40s) linear infinite;
}

.hylm-group {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	height: 100%;
}

.hylm-wrapper .hylm-group img.hylm-logo {
	display: block;
	flex-shrink: 0;
	width: auto !important;
	height: var(--hylm-height) !important;
	max-width: none !important;
	min-width: 0;
	margin: 0 var(--hylm-gap) 0 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	object-fit: contain;
	pointer-events: none;
	user-select: none;
}

/* --hylm-shift (one group width) is set by marquee.js; 50% is the no-JS fallback for two copies. */
@keyframes hylm-left {
	from { transform: translateX(0); }
	to   { transform: translateX(calc(-1 * var(--hylm-shift, 50%))); }
}

@keyframes hylm-right {
	from { transform: translateX(calc(-1 * var(--hylm-shift, 50%))); }
	to   { transform: translateX(0); }
}

@media (max-width: 768px) {
	.hylm-wrapper {
		--hylm-height: 60px;
		--hylm-gap: 15px;
		--hylm-fade: 60px;
		padding: 10px 0;
	}

	.hylm-track + .hylm-track {
		margin-top: 15px;
	}
}

/* marquee.js animates the row itself; the CSS keyframes above are only the no-JS fallback. */
.hylm-content.hylm-js {
	animation: none;
}
