/* Card Carousel Slider - Standard CSS */

/* Variables */
:root {
    --carousel-trans-speed: 0.4s;
    --carousel-spacer: 1rem;
}

/* Functional carousel style */
.card-carousel {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-bottom: 2rem;
    overflow: hidden;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.card-carousel .card {
    display: none;
    /* Hide by default */
    border: none;
    width: 100%;
}

.card-carousel .card.active {
    display: flex;
    /* Show only active */
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card-carousel .card .card-body {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Fixed Navigation Container */
.card-carousel .card-carousel__nav {
    position: absolute;
    bottom: 30px;
    left: 3rem;
    /* Align with card body margin */
    display: flex;
    z-index: 10;
    gap: 5px;
}

.card-carousel .card-carousel__nav .carousel__arrow {
    width: 45px;
    height: 45px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    fill: #ffffff;
    background-color: var(--primary-color);
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.card-carousel .card-carousel__nav .carousel__arrow:hover {
    background-color: #33b077;
    transform: scale(1.1);
}

.card-carousel .carousel__icon {
    width: 20px;
    height: 20px;
}

.card-carousel .card img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    border-radius: 0 15px 15px 0;
}

@media (max-width: 991px) {
    .card-carousel {
        min-height: 600px;
        padding-bottom: 70px;
        /* Space for buttons below image */
    }

    .card-carousel .card.active {
        flex-direction: column-reverse;
    }

    .card-carousel .card img {
        height: 300px;
        border-radius: 15px 15px 0 0;
    }

    .card-carousel .card .card-body {
        padding: 2rem;
        padding-bottom: 2rem;
        /* Normal padding */
        min-height: auto;
    }

    .card-carousel .card-carousel__nav {
        position: absolute;
        bottom: 10px;
        /* 10px from container bottom */
        top: auto;
        left: 50%;
        transform: translateX(-50%);
        width: auto;
        justify-content: center;
        gap: 15px;
        z-index: 10;
    }

    .card-carousel .card-carousel__nav .carousel__arrow {
        background-color: var(--primary-color);
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    }
}

/* Animation for content */
.active .card-title,
.active .card-text,
.active .card-subtitle {
    animation: slideUp 0.6s ease-out forwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}