/* Carousel des témoignages - Style élégant et premium */
#testimonials-carousel {
    position: relative;
    max-width: 1100px;
    margin: 0 auto;
    min-height: 350px;
    padding: 0 15px;
    overflow: visible; /* Permet aux éléments de déborder */
}

.testimonials-wrapper {
    position: relative;
    min-height: 300px; /* Hauteur minimale réduite */
    overflow: hidden;
}

.testimonial-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transform: translateX(50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    display: none;
    border-radius: 16px;
}

.testimonial-slide.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
    position: relative;
    display: block;
}

/* Grille de contenu pour plusieurs cartes */
.slide-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px; /* Réduction de l'espace entre les cartes */
    grid-auto-rows: 1fr; /* Hauteur uniforme */
}

/* Style de carte premium avec bordures élégantes */
.testimonial-card {
    position: relative;
    background: var(--white, #FFFFFF);
    border-radius: 16px; /* Rayon de bordure plus grand */
    overflow: hidden;
    box-shadow: 
        0 10px 25px rgba(0,0,0,0.12),
        0 0 0 1px rgba(0,0,0,0.03);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    height: 100%;
    min-height: 280px;
    display: flex;
    flex-direction: column;
    /* Ajout d'une bordure élégante */
    border: 1px solid rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(5px);
    transform: translateY(0) scale(1);
    /* Effet de relief */
    border-bottom: 4px solid rgba(26, 84, 144, 0.2);
}

.testimonial-card:hover {
    transform: translateY(-8px) perspective(1000px) rotateX(1deg) scale(1.02);
    box-shadow: 
        0 20px 40px rgba(0,0,0,0.15),
        0 0 0 1px rgba(0,0,0,0.03),
        0 0 0 4px rgba(255, 215, 0, 0.2); /* Contour doré au survol */
    border-color: rgba(255, 215, 0, 0.3);
    /* Effet de brillance */
    border-bottom: 4px solid rgba(255, 215, 0, 0.6);
}

/* En-tête de carte avec photo de profil - style amélioré */
.testimonial-header {
    padding: 18px; /* Légèrement plus spacieux */
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(26, 84, 144, 0.08), rgba(43, 112, 184, 0.12));
    border-bottom: 1px solid rgba(255, 215, 0, 0.1); /* Bordure dorée subtile */
    gap: 12px;
    position: relative;
    z-index: 1;
    /* Effet décoratif */
    box-shadow: 0 3px 10px -5px rgba(0,0,0,0.1);
    border-radius: 16px 16px 0 0; /* Coins arrondis cohérents avec la carte */
}

/* Avatar premium avec double bordure et effet lumineux */
.testimonial-avatar {
    width: 60px; /* Plus grand */
    height: 60px; /* Plus grand */
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    border: 2px solid #FFD700;
    box-shadow: 
        0 4px 10px rgba(0,0,0,0.18),
        0 0 0 2px rgba(255, 255, 255, 0.9),
        0 0 0 4px rgba(255, 215, 0, 0.3); /* Double bordure */
    background: #fff;
    flex-shrink: 0;
    z-index: 2;
    transition: all 0.4s ease;
}

.testimonial-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.testimonial-card:hover .testimonial-avatar img {
    transform: scale(1.05);
}

/* Placeholder d'avatar pour les témoignages sans photo */
.avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1a5490, #2b70b8);
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
}

/* Informations de profil */
.testimonial-profile {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.testimonial-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary, #1a5490);
    margin: 0 0 1px 0;
    line-height: 1.3;
    /* Effet de texte */
    text-shadow: 0 1px 1px rgba(255,255,255,0.9);
    /* Dégradé subtil */
    background: linear-gradient(135deg, #1a5490, #2b70b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.testimonial-title {
    font-size: 0.8rem; /* Taille de police réduite */
    color: var(--gray-600, #6c757d);
    margin: 0;
    line-height: 1.3;
}

/* Contenu du témoignage avec style amélioré */
.testimonial-content {
    padding: 22px; /* Plus spacieux */
    height: 100%;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    position: relative;
    z-index: 1;
    /* Ajout d'un fond avec dégradé plus raffiné */
    background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(250,250,250,0.92));
    /* Effet de citation */
    border-left: 3px solid rgba(255, 215, 0, 0.2);
}

/* Contenu du texte avec style amélioré */
.testimonial-text {
    font-size: 1rem; /* Taille légèrement plus grande */
    line-height: 1.7; /* Interligne augmenté */
    color: var(--gray-800, #1F2937);
    margin-bottom: 1.2rem; /* Plus d'espace en bas */
    flex-grow: 1;
    position: relative;
    z-index: 1;
    /* Style de citation élégant */
    font-style: italic;
    text-shadow: 0 1px 0 rgba(255,255,255,0.8);
    /* Guillemets décoratifs discrets */
    position: relative;
    /* Espacement plus confortable */
    padding: 5px 0;
    letter-spacing: 0.01em;
}

/* Suppression des guillemets */
.testimonial-text::before {
    content: ''; /* Suppression du guillemet */
}

/* Styles hébreu */
.hebrew {
    direction: rtl;
    text-align: right;
    font-family: 'Open Sans Hebrew', 'Arial', sans-serif;
}

/* Badges de type améliorés */
.type-rabbin .testimonial-header::before {
    content: 'Rabbin';
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #FFD700, #b8860b);
    color: white;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    opacity: 0.9;
    z-index: 2;
    /* Effets améliorés */
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 2px 6px rgba(184, 134, 11, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.type-communaute .testimonial-header::before {
    content: 'Communauté';
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #1a5490, #2b70b8);
    color: white;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    opacity: 0.9;
    z-index: 2;
    /* Effets améliorés */
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 2px 6px rgba(26, 84, 144, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Carousel Indicators - Style moderne et centré - Positionné au-dessus */
.carousel-indicators {
    position: relative;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    gap: 12px; /* Espacement accru entre les points */
    justify-content: center; /* Centre les points */
    align-items: center; /* Alignement vertical */
    margin: 0 auto 20px auto; /* Marge en bas pour séparer des témoignages */
    padding: 12px 0;
    /* Fond subtil pour mieux voir les indicateurs */
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    width: fit-content;
    z-index: 5;
}

.carousel-indicator {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 20px; /* Forme plus allongée pour permettre l'expansion */
    cursor: pointer;
    transition: all 0.3s ease-in-out, width 0.3s ease-in-out; /* Transition fluide pour la largeur */
    position: relative;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border: none;
    outline: none;
}

@keyframes subtlePulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.1); }
}

.carousel-indicator.active {
    background-color: rgba(255, 215, 0, 0.8);
    width: 24px; /* Plus large quand actif */
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5), 0 0 5px rgba(255, 255, 255, 0.3);
}

.carousel-indicator:hover {
    border-color: var(--gold, #FFD700);
}

/* Boutons de navigation élégants */
.carousel-nav-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 45px; /* Légèrement plus grand */
    height: 45px; /* Légèrement plus grand */
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.9);
    color: var(--primary, #1a5490);
    font-size: 1.8rem; /* Plus grand */
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    z-index: 10;
    /* Effet de bordure */
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.carousel-nav-button:hover {
    background: white;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    transform: translateY(-50%) scale(1.05);
}

.carousel-prev {
    left: -25px;
}

.carousel-next {
    right: -25px;
}

/* Responsive */
@media (max-width: 1200px) {
    .carousel-nav-button {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .carousel-prev {
        left: -10px;
    }
    
    .carousel-next {
        right: -10px;
    }
}

@media (max-width: 1024px) {
    .slide-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    #testimonials-carousel {
        padding: 0 40px;
    }
}

@media (max-width: 768px) {
    .slide-content {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .testimonials-wrapper {
        min-height: 300px;
    }
    
    .testimonial-avatar {
        width: 50px;
        height: 50px;
    }
    
    .testimonial-text {
        font-size: 0.95rem;
    }
    
    .testimonial-name {
        font-size: 1rem;
    }
    
    .testimonial-title {
        font-size: 0.8rem;
    }
    
    .carousel-nav-button {
        top: auto;
        bottom: -60px;
        transform: none;
    }
    
    .carousel-prev {
        left: calc(50% - 50px);
    }
    
    .carousel-next {
        right: calc(50% - 50px);
    }
    
    .carousel-indicators {
        margin-top: 60px;
    }
}
