/**
 * Styles pour le widget Impact Circles
 * @package Ephrem_Agency
 * @version 1.0.0
 */

/* ==========================================================================
   CONTENEUR PRINCIPAL
   ========================================================================== */

.ephrem-impact-section {
    position: relative;
    padding: 80px 20px;
    background: transparent !important ;
    overflow: hidden;
}

.impact-container {
    max-width: 100%;
    margin: 0 auto;
    position: relative;
}

/* Numéro de section */
.section-number {
    position: absolute;
    top: -20px;
    left: 0;
    font-size: 120px;
    font-weight: 700;
    color: rgba(230, 240, 250, 0.5);
    line-height: 1;
    z-index: 0;
    pointer-events: none;
}

/* ==========================================================================
   LAYOUT DEUX COLONNES
   ========================================================================== */

.impact-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

/* Colonne gauche - SVG */
.impact-circles-column {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 600px; /* Augmenté pour accommoder le grand SVG */
}

.circles-svg-container {
    width: 100%;
    max-width: 100%; /* Permettre au SVG d'occuper toute la largeur disponible */
    position: relative;
}

/* Colonne droite - Texte */
.impact-text-column {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* ==========================================================================
   SVG - CERCLES INTERACTIFS
   ========================================================================== */

.impact-svg {
    width: 100%;
    height: auto;
    display: block;
}

/* Groupes de cercles */
.circle-group {
    cursor: pointer;
    transition: transform 0.3s ease;
}

.circle-group:hover {
    transform: scale(1.05);
}

/* Cercles de base */
.impact-circle {
    fill: #d4e3f0;
    stroke: none;
    transition: fill 0.3s ease, opacity 0.3s ease;
    /* Les cercles partent avec une opacité à 0 pour l'animation */
    opacity: 0;
}

/* Couleurs spécifiques par cercle - Design Illustrator */
.circle-attirer {
    fill: #a9cce6 !important; /* Bleu clair */
}

.circle-convertir {
    fill: #9ba9b2 !important; /* Gris moyen */
}

.circle-fideliser {
    fill: #bdc5c9 !important; /* Gris clair */
}

/* État hover des cercles */
.circle-group:hover .impact-circle {
    filter: brightness(1.1);
}

.circle-group.active .impact-circle {
    filter: brightness(1.15);
}

/* Texte dans les cercles */
.circle-text {
    font-family: 'Cooper Black Std', 'Cooper Std', Georgia, serif;
    font-size: 60px;
    font-weight: 900;
    fill: #382a24;
    text-anchor: middle;
    dominant-baseline: middle;
    pointer-events: none;
    transition: opacity 0.3s ease;
    /* Le texte part invisible pour l'animation */
    opacity: 0;
}

/* Fallback pour navigateurs sans Cooper Black */
.svg-text {
    font-family: 'Cooper Black Std', 'Cooper Std', Georgia, serif;
    font-weight: 900;
}

/* ==========================================================================
   CONTENU TEXTUEL
   ========================================================================== */

.impact-main-title {
    font-size: 32px;
    line-height: 1.3;
    font-weight: 700;
    margin: 0 0 20px 0;
}

.impact-intro-text {
/*     font-size: inherit; */
    line-height: 1.6;
    color: #555;
    margin-bottom: 20px;
    position: relative; /* Conteneur pour les blocs en position absolue */
    min-height: 180px; /* Hauteur minimale pour éviter le saut */
}

.impact-intro-text p {
    margin: 0 0 15px 0;
}

.impact-intro-text em {
    font-style: italic;
}

/* ==========================================================================
   CONTENU DYNAMIQUE (dans impact-intro-text)
   ========================================================================== */

/* Les blocs de contenu se superposent dans la zone d'intro */
.content-block {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, visibility 0.4s;
    pointer-events: none;
}

.content-block.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* Le bloc intro est en position relative (flux normal) quand actif */
.content-block.content-intro {
    position: relative;
}

.content-block.content-intro.active {
    position: relative; /* Reste dans le flux normal */
}

.content-title {
/*
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
*/
    margin: 0 0 12px 0;
}

.content-description {
    font-size: inherit;
    line-height: 1.6;
    color: inherit;
    margin: 0;
}

/* ==========================================================================
   ANIMATIONS - États initiaux avant ScrollMagic
   ========================================================================== */

/* Les groupes de cercles sont visibles, mais leurs enfants (circles et textes) 
   ont opacity: 0 pour l'animation ScrollMagic */

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 992px) {
    .impact-content-wrapper {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .section-number {
        font-size: 80px;
        display: none
    }
    
    .impact-main-title {
        font-size: 28px;
    }
    
    .circles-svg-container {
        max-width: 100%; /* Garder le SVG pleine largeur sur tablette */
    }
    
    .impact-circles-column {
        min-height: 500px; /* Réduire un peu pour tablette */
    }
}

@media (max-width: 768px) {
    .ephrem-impact-section {
        padding: 60px 15px;
    }
    
    .section-number {
        font-size: 60px;
        top: -10px;
    }
    
    .impact-main-title {
        font-size: 24px;
    }
    
    .impact-intro-text {
/*         font-size: 15px; */
    }
    
    .circle-text {
        font-size: 50px; /* Réduire légèrement le texte sur mobile */
    }
    
    .content-title {
/*         font-size: 18px; */
    }
    
    .content-description {
        font-size: 14px;
    }
    
    .impact-circles-column {
        min-height: 400px;
    }
}

@media (max-width: 480px) {
    .circles-svg-container {
        max-width: 100%;
    }
    
    .circle-text {
        font-size: 40px; /* Plus petit texte pour mobile */
    }
    
    .impact-circles-column {
        min-height: 350px;
    }
}

/* ==========================================================================
   ACCESSIBILITÉ
   ========================================================================== */

/* Focus visible pour la navigation au clavier */
.circle-group:focus {
    outline: 2px solid #4A90E2;
    outline-offset: 4px;
}

/* Réduire les animations si l'utilisateur préfère */
@media (prefers-reduced-motion: reduce) {
    .circle-group,
    .impact-circle,
    .circle-text,
    .content-block {
        transition: none !important;
    }
}

/* ==========================================================================
   FIX CRITIQUE - Écraser les règles qui forcent opacity:0 sur les groupes
   ========================================================================== */

/* IMPORTANT: Les groupes de cercles doivent rester visibles (opacity:1)
   pour que GSAP puisse animer les éléments à l'intérieur.
   Si un autre CSS force opacity:0 sur les IDs, cette règle l'écrase. */
#circle-attirer,
#circle-convertir,
#circle-fideliser {
    opacity: 1 !important;
}

/* Les cercles et textes eux-mêmes commencent invisibles
   et sont animés par GSAP au scroll */
#circle-attirer .impact-circle,
#circle-attirer .circle-text,
#circle-convertir .impact-circle,
#circle-convertir .circle-text,
#circle-fideliser .impact-circle,
#circle-fideliser .circle-text {
    opacity: 0;
    /* GSAP va animer cette propriété au scroll */
}

/* FIX FLICKER: Cacher les cercles avant l'initialisation JS
   Cette classe est retirée par le JavaScript une fois prêt */
.impact-circles-column.pre-init .impact-circle,
.impact-circles-column.pre-init .circle-text {
    opacity: 0 !important;
    visibility: hidden !important;
}
