/* Banner Image Responsive Styles */
.index2-banner-right-con figure {
    height: 100%;
    position: relative;
    overflow: hidden;
}

.index2-banner-right-con figure .desktop-banner,
.index2-banner-right-con figure .mobile-banner {
    height: 894px;
    width: 933px;
    object-fit: cover;
}

.index2-banner-right-con figure .mobile-banner {
    display: none;
}

@media (max-width: 767px) {
    /* Rearrange banner sections for mobile view */
    .index2-banner-inner-con {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 20px !important;
        grid-template-columns: 100% !important;
    }
    
    .index2-banner-left-con {
        order: 1;
        width: 100%;
        margin-bottom: 20px;
    }
    
    .index2-banner-right-con {
        order: 2;
        width: 100%;
        margin-top: 40px;
        position: relative;
    }
    
    .banner2-right-top-txt {
        position: relative;
        right: auto;
        top: auto;
        text-align: center;
        margin-bottom: 20px;
        width: 100%;
    }
    
    .index2-banner-right-con figure .desktop-banner {
        display: none;
    }
    .index2-banner-right-con figure .mobile-banner {
        display: block !important;
        height: 100% !important;
        width: 100% !important;
        max-height: unset;
        object-fit: cover;
    }
    .index2-banner-right-con figure {
        height: auto;
        width: 100%;
    }
    
    .index2-banner-section {
        height: auto !important;
        padding-bottom: 40px;
    }
}

/* Small mobile devices */
@media (max-width: 575px) {
    .index2-banner-right-con figure .mobile-banner {
        height: auto !important;
        min-height: 400px;
        width: 100% !important;
    }
    
    .index2-banner-right-con {
        margin-top: 40px;
    }
    
    /* Adjustments for the quote text */
    .banner2-right-top-txt span {
        font-size: 22px;
        line-height: 26px;
    }
    
    /* Ensure banner details are positioned correctly */
    .banner2-candidate-detail-con {
        margin-top: 15px;
    }
    
    /* Add some spacing between sections */
    .index2-banner-section {
        padding-bottom: 30px;
    }
}

/* Portrait orientation */
@media (max-width: 767px) and (orientation: portrait) {
    .index2-banner-right-con figure .mobile-banner {
        height: auto !important;
        min-height: 50vh;
    }
}

/* Landscape orientation */
@media (max-width: 767px) and (orientation: landscape) {
    .index2-banner-right-con figure .mobile-banner {
        height: auto !important;
        min-height: 70vh;
    }
}
