﻿
:root {
    --carousel-primary-blue: #1e40af;
    --carousel-highlight-blue: #3b82f6;
    --carousel-shadow-blue: #1e3a8a;
    --carousel-card-width: 280px;
}

.carousel-section * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.carousel-section body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #333;
    min-height: 100vh;
}

.carousel-main-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.carousel-aside-container {
    background: white;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    z-index: 20;
}

    .carousel-aside-container h1 {
        font-size: 1.75rem;
        font-weight: 700;
        color: #1f2937;
        margin-bottom: 1rem;
        text-align: center;
    }

    .carousel-aside-container p {
        color: #6b7280;
        text-align: center;
        margin-bottom: 1.5rem;
        line-height: 1.5;
        max-width: 300px;
    }

    .carousel-aside-container img {
        width: 70%;
        max-width: 200px;
        height: auto;
    }

.carousel-content-container {
    flex: 1;
    padding: 1rem;
    display: flex;
    flex-direction: column;
}


.carousel-nav {
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    padding: 0.75rem;
    margin-bottom: 1rem;
}

    .carousel-nav ul {
        display: flex;
        gap: 0.75rem;
        justify-content: center;
        font-weight: 600;
        color: #4b5563;
        flex-wrap: wrap;
    }

        .carousel-nav ul li a {
            transition: color 0.2s;
            white-space: nowrap;
        }

            .carousel-nav ul li a:hover {
                color: var(--carousel-highlight-blue);
            }


.carousel-secondary-nav-container {
    background: var(--carousel-primary-blue);
    color: white;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 0.5rem;
    margin-bottom: 1.5rem;
}

.carousel-secondary-nav {
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none;
}

    .carousel-secondary-nav::-webkit-scrollbar {
        display: none;
    }

    .carousel-secondary-nav ul {
        display: flex;
        gap: 0.5rem;
        font-size: 0.875rem;
        text-align: center;
    }

.carousel-secondary-nav-item a {
    display: block;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    transition: background 0.2s;
    white-space: nowrap;
}

    .carousel-secondary-nav-item a:hover {
        background: rgba(255, 255, 255, 0.15);
    }


.carousel-section-title {
    text-align: center;
    margin-bottom: 1.5rem;
}

    .carousel-section-title h2 {
        font-size: 1.25rem;
        font-weight: 600;
        color: #374151;
    }


.carousel-container {
    position: relative;
    width: 100%;
    margin-bottom: 2rem;
}

.carousel-card-carousel {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding: 0.5rem;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

    .carousel-card-carousel::-webkit-scrollbar {
        display: none;
    }

.carousel-card {
    min-width: var(--carousel-card-width);
    scroll-snap-align: start;
    flex: 0 0 auto;
    height: 200px;
    border-radius: 0.75rem;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transform-style: preserve-3d;
    perspective: 1000px;
}

    .carousel-card img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.5s ease;
    }

.carousel-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    text-align: center;
    padding: 0.75rem;
}

    .carousel-card-content h3 {
        font-size: 1.125rem;
        font-weight: 700;
        margin-bottom: 0.25rem;
    }

.carousel-login-button {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(59, 130, 246, 0.9);
    color: white;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
    transform: translateY(100%);
    font-size: 1rem;
}

.carousel-card:hover {
    transform: translateY(-5px) rotateX(5deg);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

    .carousel-card:hover img {
        transform: scale(1.05);
    }

    .carousel-card:hover .carousel-login-button {
        opacity: 1;
        transform: translateY(0);
    }

.carousel-card-highlight {
    animation: carouselHighlightCard 1s ease forwards;
    z-index: 10;
}

@keyframes carouselHighlightCard {
    0% {
        transform: scale(1) translateZ(0);
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    }

    50% {
        transform: scale(1.05) translateZ(20px);
        box-shadow: 0 25px 50px -12px rgba(37, 99, 235, 0.5);
    }

    100% {
        transform: scale(1.03) translateZ(10px);
        box-shadow: 0 20px 25px -5px rgba(37, 99, 235, 0.4), 0 10px 10px -5px rgba(37, 99, 235, 0.3);
    }
}

.carousel-nav-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 15;
    padding: 0.5rem;
    background: var(--carousel-primary-blue);
    color: white;
    border-radius: 50%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    display: none;
    cursor: pointer;
}

    .carousel-nav-button:hover {
        background: var(--carousel-highlight-blue);
        transform: translateY(-50%) scale(1.1);
    }

#carousel-prev-button {
    left: 0.5rem;
}

#carousel-next-button {
    right: 0.5rem;
}


@media (min-width: 768px) {
    .carousel-main-container {
        flex-direction: row;
    }

    .carousel-aside-container {
        width: 30%;
        max-width: 300px;
        padding: 2rem;
        justify-content: center;
    }

    .carousel-content-container {
        width: 70%;
        padding: 1.5rem;
    }

    .carousel-card {
        min-width: calc(50% - 1rem);
        height: 220px;
    }

    .carousel-nav-button {
        display: block;
    }

    .carousel-nav ul {
        flex-wrap: nowrap;
    }
}

@media (min-width: 1024px) {
    .carousel-card {
        min-width: calc(33.333% - 1rem);
        height: 240px;
    }

    .carousel-aside-container h1 {
        font-size: 2rem;
    }

    .carousel-aside-container p {
        font-size: 1.125rem;
    }
}

@media (min-width: 1280px) {
    .carousel-card {
        min-width: calc(25% - 1rem);
    }
}
