/* Modern Hero Slider - Professional Edition */

/* Base container styles */
.hero-slider {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    height: 100%;
}

/* Slider item styling */
.carousel-item {
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
}

/* Content wrapper and layout */
.slide-content-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.6) 30%, rgba(0, 0, 0, 0.3) 60%, rgba(0, 0, 0, 0) 100%);
    padding: 30px;
    z-index: 5;
}

.slide-content {
    max-width: 550px;
    padding: 30px;
    position: relative;
    z-index: 5;
    margin-left: 5%;
}

/* Slide title styling */
.slide-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: #fff;
    line-height: 1.2;
    position: relative;
    padding-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.slide-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), rgba(255, 255, 255, 0.7));
    border-radius: 2px;
}

.slide-title .highlight {
    color: var(--primary-color);
    position: relative;
    display: inline-block;
}

/* Slide description styling */
.slide-description {
    font-size: 1.25rem;
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
    line-height: 1.6;
    max-width: 90%;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
}

/* Button styling */
.btn-slide-primary {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 600;
    display: inline-block;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    position: relative;
    overflow: hidden;
    z-index: 1;
    box-shadow: 0 6px 15px rgba(0, 166, 81, 0.3);
}

.btn-slide-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0));
    transition: all 0.6s ease;
    z-index: -1;
}

.btn-slide-primary:hover {
    color: white;
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 166, 81, 0.4);
}

.btn-slide-primary:hover::before {
    left: 100%;
}

/* Progress bar for active slide timing */
.carousel-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: rgba(255, 255, 255, 0.2);
    z-index: 10;
}

.progress-bar {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--primary-color), rgba(255, 255, 255, 0.7));
    transition: width 0.1s linear;
}

/* Custom navigation controls */
.carousel-controls {
    position: absolute;
    bottom: 40px;
    right: 40px;
    display: flex;
    gap: 15px;
    z-index: 10;
}

.carousel-control-custom {
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.carousel-control-custom:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.carousel-control-custom i {
    color: var(--primary-color);
    font-size: 18px;
    transition: all 0.3s ease;
}

.carousel-control-custom:hover i {
    color: white;
}

/* Custom indicators with counter */
.carousel-indicators {
    position: absolute;
    right: auto;
    left: 40px;
    bottom: 40px;
    margin: 0;
    display: flex;
    align-items: center;
    z-index: 10;
}

.carousel-indicators-counter {
    color: white;
    font-size: 1.2rem;
    font-weight: 600;
    margin-right: 20px;
    letter-spacing: 1px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.carousel-indicators-counter span {
    color: rgba(255, 255, 255, 0.7);
}

.carousel-indicators [data-bs-target] {
    width: 30px;
    height: 3px;
    background-color: rgba(255, 255, 255, 0.5);
    border: none;
    border-radius: 0;
    margin: 0 5px;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    opacity: 1;
}

.carousel-indicators .active {
    background-color: var(--primary-color);
    width: 50px;
}

/* Animation keyframes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Animation for active slide content */
.carousel-item.active .slide-title {
    animation: fadeInLeft 0.8s forwards;
}

.carousel-item.active .slide-description {
    animation: fadeInLeft 0.8s 0.3s forwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

.carousel-item.active .slide-buttons {
    animation: fadeInUp 0.8s 0.6s forwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

/* Advanced 3D transitions between slides */
.carousel-item {
    transform-style: preserve-3d;
    backface-visibility: hidden;
    transition: transform 1s cubic-bezier(0.165, 0.84, 0.44, 1), 
                opacity 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.carousel-item:not(.active) {
    opacity: 0;
}

/* Kenburns effect for active slide */
.carousel-item.active {
    animation: kenBurnsEffect 10s ease-out forwards;
}

@keyframes kenBurnsEffect {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.05);
    }
}

/* Responsive styles */
@media (max-width: 1200px) {
    .slide-title {
        font-size: 3rem;
    }
    
    .slide-description {
        font-size: 1.2rem;
    }
    
    .btn-slide-primary {
        padding: 12px 28px;
    }
}

@media (max-width: 991px) {
    .slide-content-wrapper {
        background: linear-gradient(90deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.6) 50%, rgba(0, 0, 0, 0.4) 100%);
    }
    
    .slide-content {
        max-width: 100%;
        margin-left: 0;
        text-align: center;
        padding: 20px;
    }
    
    .slide-title {
        font-size: 2.5rem;
        padding-bottom: 10px;
    }
    
    .slide-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .slide-description {
        font-size: 1.1rem;
        margin-bottom: 25px;
        max-width: 100%;
    }
    
    .carousel-controls {
        bottom: 30px;
        right: 30px;
    }
    
    .carousel-indicators {
        left: 30px;
        bottom: 30px;
    }
    
    .carousel-control-custom {
        width: 45px;
        height: 45px;
    }
}

@media (max-width: 767px) {
    .slide-content-wrapper {
        padding: 15px;
    }
    
    .slide-content {
        padding: 15px;
    }
    
    .slide-title {
        font-size: 2.2rem;
    }
    
    .slide-description {
        font-size: 1rem;
    }
    
    .btn-slide-primary {
        padding: 10px 25px;
    }
    
    .carousel-indicators {
        left: 15px;
        bottom: 30px;
    }
    
    .carousel-indicators-counter {
        font-size: 1rem;
    }
    
    .carousel-controls {
        bottom: 30px;
        right: 15px;
    }
    
    .carousel-control-custom {
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 575px) {
    .slide-content-wrapper {
        align-items: center;
        justify-content: center;
        background: linear-gradient(0deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.6) 40%, rgba(0, 0, 0, 0.4) 70%, rgba(0, 0, 0, 0.2) 100%);
    }
    
    .slide-content {
        text-align: center;
        padding: 0;
    }
    
    .slide-title {
        font-size: 1.8rem;
        margin-bottom: 15px;
        padding-bottom: 8px;
    }
    
    .slide-description {
        font-size: 0.9rem;
        margin-bottom: 20px;
    }
    
    .btn-slide-primary {
        padding: 8px 20px;
        font-size: 0.9rem;
    }
    
    .carousel-indicators {
        bottom: 15px;
        left: 10px;
    }
    
    .carousel-indicators-counter {
        font-size: 0.9rem;
        margin-right: 10px;
    }
    
    .carousel-indicators [data-bs-target] {
        width: 20px;
        height: 2px;
        margin: 0 3px;
    }
    
    .carousel-indicators .active {
        width: 35px;
    }
    
    .carousel-controls {
        bottom: 15px;
        right: 10px;
        gap: 10px;
    }
    
    .carousel-control-custom {
        width: 35px;
        height: 35px;
    }
    
    .carousel-control-custom i {
        font-size: 14px;
    }
    
    .carousel-progress {
        height: 3px;
    }
}

/* Special small screen optimizations */
@media (max-width: 400px) {
    .slide-title {
        font-size: 1.5rem;
        margin-bottom: 10px;
    }
    
    .slide-description {
        font-size: 0.85rem;
        margin-bottom: 15px;
    }
    
    .btn-slide-primary {
        padding: 7px 18px;
        font-size: 0.85rem;
    }
    
    .carousel-indicators-counter {
        display: none; /* Hide counter on very small screens */
    }
}
