/* ========================================
   SHAPES DYNAMIQUES & EFFETS ACTIFS
   SRM TTA - Version 2025 Ultra Moderne
   ======================================== */

/* ========================================
   ANIMATIONS DE SHAPES
   ======================================== */

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

@keyframes floatReverse {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(20px) rotate(-5deg);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes rotateReverse {
    from {
        transform: rotate(360deg);
    }
    to {
        transform: rotate(0deg);
    }
}

@keyframes pulseShape {
    0%, 100% {
        transform: scale(1);
        opacity: 0.6;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.9;
    }
}

@keyframes morph {
    0%, 100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
    50% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
    }
}

@keyframes wave {
    0%, 100% {
        transform: translateX(0) translateY(0);
    }
    25% {
        transform: translateX(10px) translateY(-10px);
    }
    50% {
        transform: translateX(-5px) translateY(-15px);
    }
    75% {
        transform: translateX(-10px) translateY(-5px);
    }
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes sparkle {
    0%, 100% {
        opacity: 0;
        transform: scale(0);
    }
    50% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideDiagonal {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* ========================================
   SHAPES GÉOMÉTRIQUES - CONTAINER GLOBAL
   ======================================== */

.section-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

/* ========================================
   SECTION ESPACE CLIENT - SHAPES
   ======================================== */

.client-section {
    position: relative;
    overflow: hidden;
}

.client-section .section-shapes {
    z-index: 0;
}

/* Cercle flottant animé */
.client-section .shape-circle-1 {
    position: absolute;
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, rgba(74, 113, 170, 0.15) 0%, rgba(52, 152, 219, 0.1) 100%);
    border-radius: 50%;
    top: 10%;
    right: -100px;
    animation: float 8s ease-in-out infinite, morph 12s ease-in-out infinite;
    filter: blur(40px);
}

.client-section .shape-circle-2 {
    position: absolute;
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.12) 0%, rgba(39, 174, 96, 0.08) 100%);
    border-radius: 50%;
    bottom: 20%;
    left: -80px;
    animation: floatReverse 10s ease-in-out infinite, pulseShape 4s ease-in-out infinite;
    filter: blur(30px);
}

/* Triangle animé */
.client-section .shape-triangle {
    position: absolute;
    width: 0;
    height: 0;
    border-left: 80px solid transparent;
    border-right: 80px solid transparent;
    border-bottom: 140px solid rgba(74, 113, 170, 0.08);
    top: 50%;
    right: 15%;
    animation: rotate 20s linear infinite;
    filter: blur(20px);
}

/* Ligne ondulée */
.client-section .shape-wave {
    position: absolute;
    width: 400px;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(74, 113, 170, 0.3), transparent);
    top: 30%;
    left: -200px;
    animation: wave 6s ease-in-out infinite;
    transform: rotate(45deg);
}

/* Forme organique */
.client-section .shape-organic {
    position: absolute;
    width: 250px;
    height: 250px;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(46, 204, 113, 0.08) 100%);
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    bottom: 10%;
    right: 10%;
    animation: morph 15s ease-in-out infinite, float 12s ease-in-out infinite;
    filter: blur(35px);
}

/* Particules flottantes */
.client-section .shape-particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(74, 113, 170, 0.4);
    border-radius: 50%;
    animation: sparkle 3s ease-in-out infinite;
}

.client-section .shape-particle:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.client-section .shape-particle:nth-child(2) {
    top: 60%;
    left: 20%;
    animation-delay: 1s;
}

.client-section .shape-particle:nth-child(3) {
    top: 40%;
    right: 15%;
    animation-delay: 2s;
}

/* ========================================
   SECTION INFO - SHAPES
   ======================================== */

.info-section {
    position: relative;
    overflow: hidden;
}

/* Hexagone animé */
.info-section .shape-hexagon {
    position: absolute;
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, rgba(44, 62, 80, 0.1) 0%, rgba(74, 113, 170, 0.08) 100%);
    clip-path: polygon(30% 0%, 70% 0%, 100% 50%, 70% 100%, 30% 100%, 0% 50%);
    top: 15%;
    right: 5%;
    animation: rotate 25s linear infinite, pulseShape 5s ease-in-out infinite;
    filter: blur(25px);
}

/* Cercle avec gradient animé */
.info-section .shape-circle-gradient {
    position: absolute;
    width: 350px;
    height: 350px;
    background: linear-gradient(135deg, rgba(74, 113, 170, 0.12) 0%, rgba(52, 152, 219, 0.08) 50%, rgba(46, 204, 113, 0.1) 100%);
    background-size: 200% 200%;
    border-radius: 50%;
    bottom: -100px;
    left: -150px;
    animation: gradientShift 8s ease infinite, float 10s ease-in-out infinite;
    filter: blur(50px);
}

/* Lignes diagonales */
.info-section .shape-line-1,
.info-section .shape-line-2 {
    position: absolute;
    width: 300px;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(74, 113, 170, 0.2), transparent);
    transform: rotate(45deg);
    animation: wave 7s ease-in-out infinite;
}

.info-section .shape-line-1 {
    top: 25%;
    left: 10%;
    animation-delay: 0s;
}

.info-section .shape-line-2 {
    bottom: 30%;
    right: 15%;
    animation-delay: 2s;
}

/* ========================================
   SECTION STATISTIQUES - SHAPES
   ======================================== */

.stats-section {
    position: relative;
    overflow: hidden;
}

/* Grand cercle animé en arrière-plan */
.stats-section .shape-big-circle {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    top: -200px;
    right: -200px;
    animation: pulseShape 6s ease-in-out infinite, rotate 30s linear infinite;
    filter: blur(60px);
}

/* Formes géométriques multiples */
.stats-section .shape-polygon {
    position: absolute;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0.1) 100%);
    clip-path: polygon(50% 0%, 100% 38%, 82% 100%, 18% 100%, 0% 38%);
    animation: float 8s ease-in-out infinite, rotateReverse 20s linear infinite;
    filter: blur(20px);
}

.stats-section .shape-polygon:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.stats-section .shape-polygon:nth-child(2) {
    bottom: 25%;
    right: 15%;
    animation-delay: 3s;
}

/* Lignes rayonnantes */
.stats-section .shape-ray {
    position: absolute;
    width: 2px;
    height: 200px;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    top: 50%;
    left: 50%;
    transform-origin: center;
    animation: rotate 15s linear infinite;
    filter: blur(1px);
}

.stats-section .shape-ray:nth-child(1) { transform: translate(-50%, -50%) rotate(0deg); }
.stats-section .shape-ray:nth-child(2) { transform: translate(-50%, -50%) rotate(45deg); animation-delay: 0.5s; }
.stats-section .shape-ray:nth-child(3) { transform: translate(-50%, -50%) rotate(90deg); animation-delay: 1s; }
.stats-section .shape-ray:nth-child(4) { transform: translate(-50%, -50%) rotate(135deg); animation-delay: 1.5s; }

/* ========================================
   SECTION APPELS D'OFFRES - SHAPES
   ======================================== */

.tenders-section {
    position: relative;
    overflow: hidden;
}

.tenders-section .shape-diamond {
    position: absolute;
    width: 180px;
    height: 180px;
    background: linear-gradient(135deg, rgba(74, 113, 170, 0.1) 0%, rgba(52, 152, 219, 0.08) 100%);
    transform: rotate(45deg);
    top: 10%;
    left: -90px;
    animation: float 9s ease-in-out infinite, pulseShape 4s ease-in-out infinite;
    filter: blur(30px);
}

.tenders-section .shape-circle-small {
    position: absolute;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(46, 204, 113, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    bottom: 20%;
    right: 10%;
    animation: floatReverse 7s ease-in-out infinite, sparkle 4s ease-in-out infinite;
    filter: blur(25px);
}

/* ========================================
   SECTION ACTUALITÉS - SHAPES
   ======================================== */

.news-section {
    position: relative;
    overflow: hidden;
}

.news-section .shape-ellipse {
    position: absolute;
    width: 400px;
    height: 200px;
    background: linear-gradient(135deg, rgba(74, 113, 170, 0.08) 0%, rgba(46, 204, 113, 0.06) 100%);
    border-radius: 50%;
    top: 50%;
    right: -200px;
    animation: float 11s ease-in-out infinite, morph 18s ease-in-out infinite;
    filter: blur(40px);
}

.news-section .shape-square {
    position: absolute;
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(44, 62, 80, 0.08) 100%);
    transform: rotate(45deg);
    bottom: 15%;
    left: 5%;
    animation: rotate 18s linear infinite, pulseShape 5s ease-in-out infinite;
    filter: blur(25px);
    border-radius: 20px;
}

/* ========================================
   SECTION CONTACT - SHAPES
   ======================================== */

.contact-section {
    position: relative;
    overflow: hidden;
}

.contact-section .shape-complex {
    position: absolute;
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, rgba(74, 113, 170, 0.12) 0%, rgba(52, 152, 219, 0.1) 50%, rgba(46, 204, 113, 0.08) 100%);
    background-size: 200% 200%;
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    top: -150px;
    right: -150px;
    animation: morph 20s ease-in-out infinite, gradientShift 10s ease infinite, float 12s ease-in-out infinite;
    filter: blur(50px);
}

.contact-section .shape-triangle-contact {
    position: absolute;
    width: 0;
    height: 0;
    border-left: 100px solid transparent;
    border-right: 100px solid transparent;
    border-bottom: 180px solid rgba(44, 62, 80, 0.08);
    bottom: -90px;
    left: 10%;
    animation: rotateReverse 25s linear infinite, floatReverse 10s ease-in-out infinite;
    filter: blur(30px);
}

/* ========================================
   EFFETS DE PARTICULES ACTIVES
   ======================================== */

.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(74, 113, 170, 0.6);
    border-radius: 50%;
    animation: sparkle 4s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(74, 113, 170, 0.5);
}

/* Génération de particules pour chaque section */
.client-section .particle:nth-child(1) { top: 15%; left: 20%; animation-delay: 0s; }
.client-section .particle:nth-child(2) { top: 45%; left: 60%; animation-delay: 1s; }
.client-section .particle:nth-child(3) { top: 70%; left: 30%; animation-delay: 2s; }
.client-section .particle:nth-child(4) { top: 30%; right: 25%; animation-delay: 1.5s; }
.client-section .particle:nth-child(5) { bottom: 20%; right: 40%; animation-delay: 0.5s; }

.info-section .particle:nth-child(1) { top: 25%; left: 15%; animation-delay: 0s; }
.info-section .particle:nth-child(2) { top: 60%; right: 20%; animation-delay: 1.5s; }
.info-section .particle:nth-child(3) { bottom: 30%; left: 50%; animation-delay: 2.5s; }

.stats-section .particle:nth-child(1) { top: 30%; left: 25%; animation-delay: 0s; }
.stats-section .particle:nth-child(2) { top: 50%; right: 30%; animation-delay: 1s; }
.stats-section .particle:nth-child(3) { bottom: 25%; left: 40%; animation-delay: 2s; }

/* ========================================
   GRADIENTS ANIMÉS EN ARRIÈRE-PLAN
   ======================================== */

.section-gradient-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 113, 170, 0.05) 0%, rgba(52, 152, 219, 0.03) 50%, rgba(46, 204, 113, 0.05) 100%);
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
    z-index: 0;
    pointer-events: none;
}

/* ========================================
   EFFETS INTERACTIFS AU HOVER
   ======================================== */

.client-section:hover .shape-circle-1 {
    animation-duration: 4s, 8s;
    filter: blur(30px);
}

.client-section:hover .shape-organic {
    animation-duration: 8s, 6s;
    transform: scale(1.2);
}

.info-section:hover .shape-circle-gradient {
    animation-duration: 4s, 5s;
    filter: blur(40px);
}

.stats-section:hover .shape-big-circle {
    animation-duration: 3s, 20s;
    transform: scale(1.1);
}

/* ========================================
   LIGNES CONNECTEUSES ANIMÉES
   ======================================== */

.connecting-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.connecting-line {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(74, 113, 170, 0.2), transparent);
    animation: wave 8s ease-in-out infinite;
}

.connecting-line-1 {
    top: 20%;
    left: 0;
    width: 30%;
    transform: rotate(25deg);
    animation-delay: 0s;
}

.connecting-line-2 {
    bottom: 30%;
    right: 0;
    width: 35%;
    transform: rotate(-30deg);
    animation-delay: 2s;
}

/* ========================================
   RESPONSIVE - MASQUER SUR MOBILE
   ======================================== */

@media (max-width: 768px) {
    .section-shapes,
    .particles-container,
    .section-gradient-bg,
    .connecting-lines {
        display: none;
    }
    
    /* Garder seulement les formes les plus simples */
    .client-section .shape-circle-1,
    .info-section .shape-circle-gradient,
    .stats-section .shape-big-circle {
        display: block;
        filter: blur(60px);
        opacity: 0.3;
    }
}

@media (max-width: 480px) {
    /* Masquer toutes les formes sur très petits écrans */
    .section-shapes > *,
    .particles-container,
    .section-gradient-bg,
    .connecting-lines {
        display: none !important;
    }
}

/* ========================================
   OPTIMISATION PERFORMANCE
   ======================================== */

.section-shapes,
.particles-container,
.section-gradient-bg {
    will-change: transform, opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Réduire les animations si l'utilisateur préfère moins de mouvement */
@media (prefers-reduced-motion: reduce) {
    .section-shapes > *,
    .particle,
    .section-gradient-bg {
        animation: none !important;
    }
}


