/* 3D Carousel Styles */
.carousel-3d-container {
    position: relative;
    width: 100%;
    height: 600px;
    perspective: 1200px;
    overflow: hidden;
    margin: 2rem 0;
}

.carousel-3d-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.8s cubic-bezier(0.4, 0.0, 0.2, 1);
}

.carousel-3d-item {
    position: absolute;
    width: 350px;
    height: 500px;
    left: 50%;
    top: 50%;
    transform-origin: center center;
    transition: all 0.8s cubic-bezier(0.4, 0.0, 0.2, 1);
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    cursor: pointer;
}

.carousel-3d-item:hover {
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4);
    transform: translate(-50%, -50%) translateZ(0px) scale(1.02);
}

.carousel-3d-item.active:hover {
    transform: translate(-50%, -50%) translateZ(0px) scale(1.02);
}

.carousel-3d-item.active {
    transform: translate(-50%, -50%) translateZ(0px) scale(1);
    z-index: 10;
    opacity: 1;
}

.carousel-3d-item.prev {
    transform: translate(-50%, -50%) translateZ(-200px) translateX(-300px) rotateY(45deg) scale(0.8);
    z-index: 5;
    opacity: 0.7;
}

.carousel-3d-item.next {
    transform: translate(-50%, -50%) translateZ(-200px) translateX(300px) rotateY(-45deg) scale(0.8);
    z-index: 5;
    opacity: 0.7;
}

.carousel-3d-item.hidden {
    transform: translate(-50%, -50%) translateZ(-400px) scale(0.5);
    z-index: 1;
    opacity: 0;
}

.carousel-3d-item img {
    width: 100%;
    height: 70%;
    object-fit: cover;
    border-radius: 15px 15px 0 0;
}

.carousel-3d-item .item-content {
    padding: 1rem;
    background: white;
    height: 30%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    position: relative;
}

.carousel-3d-item .item-title {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: #333;
    line-height: 1.3;
}

.carousel-3d-item .item-artist {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.carousel-3d-item .item-year {
    font-size: 0.8rem;
    color: #999;
    font-style: italic;
}

/* Vendu badge for carousel */
.carousel-3d-item .vendu-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: #d14755e7;
    color: white;
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: bold;
    z-index: 15;
    transform: rotate(0deg);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Price badge for carousel */
.carousel-3d-item .price-badge {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background-color: rgba(255, 193, 7, 0.9); /* Yellow with transparency */
    color: #212529; /* Dark text */
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: bold;
    z-index: 15;
    transform: rotate(0deg);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Vendu badge for gallery cards */
.price-badge {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background-color: rgba(255, 193, 7, 0.9); /* Yellow with transparency */
    color: #212529; /* Dark text */
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: bold;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(2px);
}

/* Gallery card vendu badge */
.vendu-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: rgba(220, 53, 69, 0.9); /* Red with transparency */
    color: white;
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: bold;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(2px);
}

/* Carousel controls */
.carousel-3d-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 20;
}

.carousel-3d-controls button {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.carousel-3d-controls button:hover {
    background: white;
    transform: scale(1.1);
}

.carousel-3d-controls button i {
    font-size: 1.2rem;
    color: #333;
}

/* Play/Pause button */
.carousel-3d-controls .play-pause-btn {
    background: rgba(44, 85, 48, 0.9);
}

.carousel-3d-controls .play-pause-btn:hover {
    background: #2c5530;
}

.carousel-3d-controls .play-pause-btn i {
    color: white;
}

/* Progress indicator */
.carousel-3d-progress {
    position: absolute;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 20;
}

.carousel-3d-progress .progress-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-3d-progress .progress-dot.active {
    background: #2c5530;
    transform: scale(1.2);
}

/* Responsive design */
@media (max-width: 768px) {
    .carousel-3d-container {
        height: 450px;
        margin: 1rem 0;
    }
    
    .carousel-3d-item {
        width: 280px;
        height: 400px;
    }
    
    .carousel-3d-item.prev {
        transform: translate(-50%, -50%) translateZ(-150px) translateX(-200px) rotateY(35deg) scale(0.7);
    }
    
    .carousel-3d-item.next {
        transform: translate(-50%, -50%) translateZ(-150px) translateX(200px) rotateY(-35deg) scale(0.7);
    }
    
    .carousel-3d-controls {
        bottom: 10px;
    }
    
    .carousel-3d-controls button {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .carousel-3d-progress {
        bottom: 60px;
        gap: 6px;
    }
    
    .carousel-3d-progress .progress-dot {
        width: 8px;
        height: 8px;
    }
}

@media (max-width: 480px) {
    .carousel-3d-container {
        height: 350px;
        margin: 0.5rem 0;
    }
    
    .carousel-3d-item {
        width: 220px;
        height: 320px;
    }
    
    .carousel-3d-item.prev {
        transform: translate(-50%, -50%) translateZ(-100px) translateX(-150px) rotateY(25deg) scale(0.6);
    }
    
    .carousel-3d-item.next {
        transform: translate(-50%, -50%) translateZ(-100px) translateX(150px) rotateY(-25deg) scale(0.6);
    }
    
    .carousel-3d-controls {
        bottom: 5px;
        gap: 8px;
    }
    
    .carousel-3d-controls button {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }
    
    .carousel-3d-progress {
        bottom: 45px;
        gap: 4px;
    }
    
    .carousel-3d-progress .progress-dot {
        width: 6px;
        height: 6px;
    }
    
    .carousel-3d-item .item-content {
        padding: 0.5rem;
    }
    
    .carousel-3d-item .item-title {
        font-size: 1rem;
        margin-bottom: 0.3rem;
    }
    
    .carousel-3d-item .item-artist {
        font-size: 0.8rem;
        margin-bottom: 0.3rem;
    }
    
    .carousel-3d-item .item-year {
        font-size: 0.7rem;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .carousel-3d-item:hover {
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
        transform: translate(-50%, -50%) translateZ(0px) scale(1);
    }
    
    .carousel-3d-item.active:hover {
        transform: translate(-50%, -50%) translateZ(0px) scale(1);
    }
    
    .carousel-3d-controls button {
        background: rgba(255, 255, 255, 0.95);
    }
    
    .carousel-3d-controls .play-pause-btn {
        background: rgba(44, 85, 48, 0.95);
    }
}
