/* 차량 갤러리 슬라이더 CSS */
.car-gallery-slider {
    max-width: 100%;
    margin: 0 auto;
    position: relative;
}

.gallery-main-image {
    width: 100%;
    position: relative;
    border-radius: 40px;
    overflow: hidden;
    margin-bottom: calc(var(--space-l) * 0.5);
    z-index: 1;
}
@media (max-width: 478px) {
    .gallery-main-image {
        border-radius: 20px;
    }
}


.gallery-main-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    aspect-ratio: 16/9;
    transition: transform 0.5s ease, opacity 0.5s ease;
    z-index: 2;
}

/* 슬라이드 전환 애니메이션 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideInLeft {
    from { transform: translateX(-100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideOutRight {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(100%); opacity: 0; }
}

@keyframes slideOutLeft {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(-100%); opacity: 0; }
}

/* 사용자 정의 애니메이션 클래스 */
.slide-in-right {
    animation: slideInRight 0.5s forwards;
    z-index: 3;
}

.slide-in-left {
    animation: slideInLeft 0.5s forwards;
    z-index: 3;
}

.slide-out-right {
    animation: slideOutRight 0.5s forwards;
    z-index: 2;
}

.slide-out-left {
    animation: slideOutLeft 0.5s forwards;
    z-index: 2;
}

.fade-in {
    animation: fadeIn 0.5s forwards;
    z-index: 3;
}

.fade-out {
    animation: fadeOut 0.5s forwards;
    z-index: 2;
}

.gallery-thumbnails {
    display: flex;
    justify-content: center;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 10px;
    scrollbar-width: thin;
    scrollbar-color: #ddd #f5f5f5;
}

.gallery-thumbnails::-webkit-scrollbar {
    height: 6px;
}

.gallery-thumbnails::-webkit-scrollbar-track {
    background: #f5f5f5;
    border-radius: 10px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb {
    background-color: #ddd;
    border-radius: 10px;
}

.gallery-thumbnail {
    flex: 0 0 auto;
    width: 100px;
    height: 70px;
    border-radius: 5px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.7;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.gallery-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-thumbnail:hover img {
    transform: scale(1.1);
}

.gallery-thumbnail.active {
    opacity: 1;
    border-color: #3949ab;
    box-shadow: 0 0 10px rgba(57, 73, 171, 0.5);
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.8);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-size: 20px;
    color: #333;
    transition: all 0.3s ease;
}

.gallery-nav:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.gallery-prev {
    left: 10px;
}

.gallery-next {
    right: 10px;
}

@media (max-width: 768px) {
    .gallery-thumbnail {
        width: 80px;
        height: 60px;
    }
    
    .gallery-nav {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
} 