/* =============================================
   carousel.css  —  Dual vertical infinite scroll
   =============================================

   ⏱  WHERE TO CHANGE SPEED:
       Search for "20s" in this file.
       .scroll-up   → animation duration = scroll speed of left column
       .scroll-down → animation duration = scroll speed of right column
       Lower number = faster.  Example: 12s = fast, 30s = slow.

   ============================================= */

.dual-carousel {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    height: 560px;
}

.vertical-carousel {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-lg);
    /* Grab cursor shows users can interact */
    cursor: grab;
}

.vertical-carousel:active { cursor: grabbing; }

/* Top + bottom fade masks */
.vertical-carousel::before,
.vertical-carousel::after {
    content: '';
    position: absolute;
    left: 0; right: 0;
    height: 80px;
    z-index: 2;
    pointer-events: none;
}

.vertical-carousel::before {
    top: 0;
    background: linear-gradient(to bottom, var(--bg2), transparent);
}

.vertical-carousel::after {
    bottom: 0;
    background: linear-gradient(to top, var(--bg2), transparent);
}

.carousel-track {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 8px 0;
    /* will-change gives the GPU a heads-up for smoother animation */
    will-change: transform;
    user-select: none;
}


.scroll-up   { animation: scrollUp   35s linear infinite; }
.scroll-down { animation: scrollDown 35s linear infinite; }

@keyframes scrollUp   { from { transform: translateY(0);    } to { transform: translateY(-50%); } }
@keyframes scrollDown { from { transform: translateY(-50%); } to { transform: translateY(0);    } }

/* Pauses auto-scroll when hovering or dragging */
.carousel-track:hover,
.carousel-track.is-dragging { animation-play-state: paused; }

/* ── CARDS ──────────────────────────────────── */
.service-card {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
    height: 155px;
    flex-shrink: 0;
    transition: transform var(--t), box-shadow var(--t);
}

.service-card:hover {
    transform: scale(1.03);
    box-shadow: var(--shadow-md);
}

.card-label {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: rgba(0,0,0,0.62);
    color: #fff;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    font-size: 12px;
    backdrop-filter: blur(2px);
    pointer-events: none;
}

/* ── RESPONSIVE ─────────────────────────────── */
/* Note: mobile overrides for the hero carousel are in home.css
   so they are scoped to .hero-panel--carousel and don't affect
   any other carousel usage on the site */
@media (max-width: 900px) {
    .dual-carousel { height: 360px; }
    .service-card  { height: 110px; }
}
/* IMPORTANT: never collapse to 1 column — always keep 2 side by side */