/* Home Hero Carousel */
.image-carousel {
    position: relative;
    width: 100%;
    height: 500px; /* Fixed height for the carousel */
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    background-color: #f5f5f5; /* Fallback background */
}

.carousel-container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.carousel-slide.active {
    opacity: 1;
    z-index: 1;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}

.carousel-slide.active {
    opacity: 1;
    position: relative;
}

.carousel-caption {
    position: relative;
    z-index: 2;
    background: rgba(9, 42, 75, 0.8);
    color: white;
    padding: 1.5rem;
    width: 100%;
    text-align: center;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.carousel-caption h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.carousel-caption p {
    font-size: 1rem;
    margin: 0;
    opacity: 0.9;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    padding: 0 1rem;
    z-index: 10;
    transform: translateY(-50%);
}

.carousel-prev,
.carousel-next {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.carousel-prev:hover,
.carousel-next:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.carousel-dots {
    position: absolute;
    bottom: 1rem;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    z-index: 10;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-dot.active {
    background: white;
    transform: scale(1.2);
}

.carousel-content {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    color: white;
}

.carousel-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transform: translateY(30px);
    opacity: 0;
    transition: all 0.8s ease;
}

.carousel-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    max-width: 600px;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease 0.2s;
}

.carousel-buttons {
    display: flex;
    gap: 1rem;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease 0.4s;
}

.carousel-slide.active .carousel-content h1,
.carousel-slide.active .carousel-content p,
.carousel-slide.active .carousel-buttons {
    transform: translateY(0);
    opacity: 1;
}

.carousel-nav {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 1rem;
    z-index: 10;
}

.carousel-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-dot.active {
    background: white;
    transform: scale(1.2);
}

.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.2);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
}

.carousel-arrow:hover {
    background: rgba(255,255,255,0.3);
}

.carousel-arrow.prev {
    left: 2rem;
}

.carousel-arrow.next {
    right: 2rem;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .home-carousel {
        height: 80vh;
        min-height: 600px;
    }
    
    .carousel-content h1 {
        font-size: 2.8rem;
    }
}

@media (max-width: 768px) {
    .home-carousel {
        height: 70vh;
        min-height: 500px;
    }
    
    .carousel-content h1 {
        font-size: 2.2rem;
    }
    
    .carousel-content p {
        font-size: 1.1rem;
    }
    
    .carousel-arrow {
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 480px) {
    .carousel-content h1 {
        font-size: 1.8rem;
    }
    
    .carousel-content p {
        font-size: 1rem;
    }
    
    .carousel-buttons {
        flex-direction: column;
        gap: 0.5rem;
    }
}
