/* ===================================================================
   TESTIMONIAL FIX CSS - Zero Risk Override
   Purpose: Fix testimonial card layout without modifying existing files
   ================================================================== */

/* Force correct layout structure for testimonial cards */
#Testimonial .review-3 {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    height: 450px !important;
    padding: 20px !important;
    position: relative !important;
    overflow: visible !important;
    text-align: center !important;
    background-color: #fff !important;
    border-radius: 8px !important;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05) !important;
    transition: all 0.3s ease !important;
    max-width: 320px !important;
    margin: 0 auto !important;
}

/* Profile image - force to top */
#Testimonial .review-3 .profile-image {
    order: 1 !important;
    position: static !important;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    margin-bottom: 15px !important;
    flex-shrink: 0 !important;
    height: 95px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: none !important;
    border: none !important;
    padding: 0 !important;
    box-shadow: none !important;
}

#Testimonial .review-3 .profile-image img {
    width: 75px !important;
    height: 75px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid #f8f8f8 !important;
    background: none !important;
    background-color: transparent !important;
}

/* Feedback area - force to middle with scroll */
#Testimonial .review-3 .feedback-scroll-area {
    order: 2 !important;
    flex: 1 !important;
    max-height: 168px !important;
    overflow-y: auto !important;
    margin: 10px 0 !important;
    padding: 12px !important;
    text-align: center !important;
    width: 100% !important;
}

#Testimonial .review-3 .feedback-scroll-area p.p-md {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    line-height: 1.6 !important;
    text-align: center !important;
    word-wrap: break-word !important;
    hyphens: auto !important;
    color: #555 !important;
}

/* Profile info - force to bottom */
#Testimonial .review-3 .profile-info-fixed {
    order: 3 !important;
    flex-shrink: 0 !important;
    margin-top: auto !important;
    padding: 12px 8px 8px 8px !important;
    border-top: 1px solid #f0f0f0 !important;
    text-align: center !important;
    width: 100% !important;
}

#Testimonial .review-3 .app-rating {
    margin: 8px 0 !important;
    flex-shrink: 0 !important;
    height: 20px !important;
    text-align: center !important;
}

#Testimonial .review-3 h6.h6-sm {
    margin: 8px 0 4px 0 !important;
    font-weight: 600 !important;
    color: #333 !important;
    flex-shrink: 0 !important;
    line-height: 1.3 !important;
    text-align: center !important;
}

#Testimonial .review-3 p.p-sm {
    margin: 0 !important;
    font-size: 13px !important;
    color: #777 !important;
    flex-shrink: 0 !important;
    font-weight: 400 !important;
    line-height: 1.3 !important;
    text-align: center !important;
}

/* Hover effects */
#Testimonial .review-3:hover {
    transform: translateY(-7px) !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important;
}

/* Carousel spacing */
#Testimonial .reviews-wrapper {
    margin: 0 -12px !important;
}

#Testimonial .reviews-wrapper .owl-item {
    padding: 0 12px !important;
}

/* Pagination dots */
#Testimonial .reviews-wrapper .owl-dots {
    text-align: center !important;
    margin-top: 30px !important;
    display: block !important;
}

#Testimonial .reviews-wrapper .owl-dots .owl-dot {
    display: inline-block !important;
    margin: 0 8px !important;
    width: 10px !important;
    height: 10px !important;
    border-radius: 50% !important;
    background: #ddd !important;
    cursor: pointer !important;
    transition: background 0.3s ease !important;
}

#Testimonial .reviews-wrapper .owl-dots .owl-dot.active,
#Testimonial .reviews-wrapper .owl-dots .owl-dot:hover {
    background: #007bff !important;
}

/* Desktop scrollbar styling */
@media (min-width: 768px) {
    #Testimonial .review-3 .feedback-scroll-area {
        scrollbar-width: thin !important;
        scrollbar-color: rgba(0,0,0,0.2) transparent !important;
    }

    #Testimonial .review-3 .feedback-scroll-area::-webkit-scrollbar {
        width: 4px !important;
    }

    #Testimonial .review-3 .feedback-scroll-area::-webkit-scrollbar-thumb {
        background-color: rgba(0,0,0,0.2) !important;
        border-radius: 4px !important;
    }
    
    #Testimonial .review-3 .feedback-scroll-area p.p-md {
        padding-right: 8px !important;
    }
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    #Testimonial .review-3 {
        height: auto !important;
        min-height: 400px !important;
        margin: 0 auto !important;
        padding: 18px !important;
        max-width: none !important;
        width: 94% !important;
    }
    
    #Testimonial .review-3 .profile-image {
        height: 85px !important;
        margin-bottom: 15px !important;
    }
    
    #Testimonial .review-3 .profile-image img {
        width: 65px !important;
        height: 65px !important;
    }
    
    #Testimonial .review-3 .feedback-scroll-area {
        height: auto !important;
        max-height: none !important;
        margin: 8px 0 !important;
    }
    
    #Testimonial .review-3 .feedback-scroll-area p.p-md {
        font-size: 14px !important;
        line-height: 1.5 !important;
    }
    
    #Testimonial .review-3 .profile-info-fixed {
        margin-top: 15px !important;
        padding: 10px 8px 6px 8px !important;
    }
    
    #Testimonial .review-3 .app-rating {
        margin: 6px 0 !important;
    }
}

@media (max-width: 767px) {
    #Testimonial .reviews-wrapper {
        margin: 0 -5px !important;
    }
    
    #Testimonial .reviews-wrapper .owl-item {
        padding: 0 5px !important;
        margin-bottom: 24px !important;
    }
    
    #Testimonial .review-3 {
        width: 94% !important;
        max-width: none !important;
        margin: 0 auto !important;
        padding: 24px 16px !important;
        height: auto !important;
        min-height: 360px !important;
    }
    
    #Testimonial .review-3 .profile-image {
        height: 75px !important;
        margin-bottom: 12px !important;
    }
    
    #Testimonial .review-3 .profile-image img {
        width: 55px !important;
        height: 55px !important;
    }
    
    #Testimonial .review-3 .feedback-scroll-area {
        height: auto !important;
        max-height: none !important;
        margin: 6px 0 !important;
    }
    
    #Testimonial .review-3 .feedback-scroll-area p.p-md {
        font-size: 1rem !important;
        line-height: 1.5 !important;
    }
    
    #Testimonial .review-3 .profile-info-fixed {
        margin-top: 12px !important;
        padding: 8px 6px 4px 6px !important;
    }
    
    #Testimonial .review-3 .app-rating {
        margin: 5px 0 !important;
    }
    
    #Testimonial .review-3 h6.h6-sm {
        font-size: 14px !important;
        margin: 6px 0 3px 0 !important;
    }
    
    #Testimonial .review-3 p.p-sm {
        font-size: 12px !important;
    }
    
    #Testimonial .reviews-wrapper .owl-dots {
        display: block !important;
        text-align: center !important;
        margin-top: 25px !important;
        padding: 0 20px !important;
    }
    
    #Testimonial .reviews-wrapper .owl-dots .owl-dot {
        width: 10px !important;
        height: 10px !important;
        margin: 0 6px !important;
    }
}

@media (max-width: 480px) {
    #Testimonial .review-3 {
        width: 85% !important;
        max-width: 300px !important;
        min-width: 260px !important;
        padding: 20px 12px !important;
    }
    
    #Testimonial .reviews-wrapper {
        margin: 0 -4px !important;
    }
    
    #Testimonial .reviews-wrapper .owl-item {
        padding: 0 4px !important;
    }
}

/* Remove any unwanted backgrounds that might be added by other CSS */
#Testimonial .review-3 .profile-image,
#Testimonial .review-3 .profile-image img {
    background: none !important;
    background-color: transparent !important;
}

/* Ensure proper stacking order */
#Testimonial .review-3 > * {
    position: relative !important;
    z-index: auto !important;
}

/* Mobile uniform card sizing - match desktop behavior */
@media (max-width: 767px) {
    #Testimonial .review-3 {
        height: 450px !important; /* Same as desktop */
        max-width: 320px !important; /* Same as desktop */
        width: 100% !important;
        margin: 0 auto !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: flex-start !important;
        align-items: center !important;
        padding: 20px !important; /* Same as desktop */
        min-height: 450px !important; /* Override previous min-height */
    }
    
    #Testimonial .review-3 .feedback-scroll-area {
        max-height: 170px !important; /* Same scroll limit as desktop */
        overflow-y: auto !important;
        flex: 1 !important;
        margin: 10px 0 !important;
    }
    
    #Testimonial .review-3 .profile-image {
        height: 95px !important; /* Same as desktop */
        margin-bottom: 15px !important;
        flex-shrink: 0 !important;
    }
    
    #Testimonial .review-3 .profile-image img {
        width: 75px !important; /* Same as desktop */
        height: 75px !important; /* Same as desktop */
    }
    
    #Testimonial .review-3 .profile-info-fixed {
        margin-top: auto !important; /* Push to bottom like desktop */
        padding: 12px 8px 8px 8px !important; /* Same as desktop */
        flex-shrink: 0 !important;
    }
} 