/* --- CAROUSEL --- */
.mouse-tracing-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 2000px;
    position: relative;
    overflow: visible;
    z-index: 10;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
}
.mouse-tracing-wrapper:active { cursor: grabbing; }

.scene-container {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-style: preserve-3d;
    transition: transform 0.3s ease-out;
    transform-origin: center center;
}

.carousel-3d {
    position: relative;
    transform-style: preserve-3d;
    transition: transform 1s cubic-bezier(0.19, 1, 0.22, 1);
    width: 420px;
    height: 260px;
}

.carousel-item {
    position: absolute;
    inset: 0;
    margin: 0;
    background: rgba(255, 255, 255, 0.03);
    backface-visibility: visible;
    border-radius: 8px;
    overflow: hidden;
    transform-origin: center center;
    user-select: none;
    -webkit-user-select: none;
}

.carousel-link-wrapper {
    display: block;
    width: 100%;
    height: 100%;
    cursor: pointer;
    transform-style: preserve-3d;
}

.carousel-item img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    transition: transform 0.6s ease;
    transform: scale(1);
}

/* Zoom no hover apenas em ponteiros finos (desktop) */
@media (hover: hover) and (pointer: fine) {
    .carousel-item:hover img { transform: scale(1.05); }
}

/* --- INDICADOR DE POSIÇÃO ---
   Fica dentro do <footer>, na mesma linha do copyright (alinhado à direita
   via justify-between). Minimalista e pequeno. */
.carousel-dots {
    display: flex;
    align-items: center;
    gap: 6px;
}
.carousel-dot {
    width: 5px;
    height: 5px;
    padding: 0;
    border: 0;
    border-radius: 9999px;
    background: rgba(0, 0, 0, 0.25);
    cursor: pointer;
    transition: width 0.3s ease, background-color 0.3s ease;
}
.carousel-dot.is-active {
    width: 14px;
    background: rgba(0, 0, 0, 0.8);
}
.carousel-dot:focus-visible {
    outline: 2px solid rgba(0, 0, 0, 0.6);
    outline-offset: 3px;
}

/* --- MOBILE --- */
@media (max-width: 768px) {
    .mouse-tracing-wrapper { perspective: 600px; }
    .carousel-3d {
        width: 180px;
        height: 260px;
    }
    .scene-container { transform: rotateX(-10deg); }
    .carousel-item img {
        transform: none;
        transition: none;
    }
}

/* --- MOVIMENTO REDUZIDO --- */
@media (prefers-reduced-motion: reduce) {
    .carousel-3d,
    .scene-container,
    .carousel-item img {
        transition: none !important;
    }
}
