/* ── Logo Carousel – Front-end Styles ─────────────────────────────────── */

.lc-wrapper {
    --lc-height: 60px;
    --lc-gap: 40px;
    width: 100%;
    overflow: hidden;
    position: relative;
    /* fade edges */
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

.lc-track-outer {
    overflow: hidden;
    width: 100%;
}

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

.lc-wrapper[data-rows="2"] .lc-track,
.lc-wrapper[data-rows="3"] .lc-track,
.lc-wrapper[data-rows="4"] .lc-track,
.lc-wrapper[data-rows="5"] .lc-track {
    flex-wrap: wrap;
    /* JS will handle row-based layout */
}

.lc-item {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lc-item img {
    height: var(--lc-height);
    width: auto;
    max-width: 180px;
    object-fit: contain;
    display: block;
    transition: opacity 0.3s ease, filter 0.3s ease;
}

/* Grayscale mode */
.lc-grayscale .lc-item img {
    filter: grayscale(100%);
    opacity: 0.6;
}

.lc-grayscale .lc-item:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

/* Hover opacity on normal mode */
.lc-wrapper:not(.lc-grayscale) .lc-item img:hover {
    opacity: 0.75;
}

.lc-item a {
    display: block;
    line-height: 0;
}

/* Empty state */
.lc-empty {
    text-align: center;
    color: #777;
    padding: 1em;
}

/* ── CSS animation (applied by JS) ─────────────────────────────────────── */
/* --lc-shift is set per-track by JS to exactly one set's width, so the loop
   is seamless regardless of gap size. Falls back to 50% if JS hasn't run. */
@keyframes lc-scroll-left {
    from { transform: translateX(0); }
    to   { transform: translateX(calc(-1 * var(--lc-shift, 50%))); }
}

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

/* Respect users who ask for reduced motion: render a static strip. */
@media (prefers-reduced-motion: reduce) {
    .lc-track,
    .lc-track-row {
        animation: none !important;
    }
}
