/*=====================================================
  VARIABLES CHROMATIQUES DIGIPAY
======================================================*/
:root {
    --cyan-electric: #00D4FF;
    --violet-royal: #943CFF;
    --corail-vif: #FF4E50;
    --bg-dark-overlay: rgba(2, 10, 29, 0.82);
}

.uppercase {
    text-transform: uppercase;
}

/*=====================================================
  HERO FULL BACKGROUND
======================================================*/
.hero-slider {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    color: #ffffff;
    background-color: #030a1c;
    padding: 120px 0 80px;
}

/* SLIDES D'ARRIÈRE-PLAN */
.hero-bg-slides {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.hero-bg-slide {
    background-image: var(--bg-desktop);
    /* Applique l'image Desktop par défaut */
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center left;
    opacity: 0;
    transition: opacity 1.2s ease-in-out, transform 8s ease-out;
    transform: scale(1.05);
}

.hero-bg-slide.active {
    opacity: 1;
    transform: scale(1);
}

/* OVERLAY DÉGRADÉ POUR S'ASSURER QUE LE TEXTE EST LISIBLE */
.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    background: linear-gradient(90deg,
            rgba(3, 10, 28, 0.15) 0%,
            rgba(3, 10, 28, 0.65) 65%,
            rgba(3, 10, 28, 0.85) 95%);
}

.hero-container {
    position: relative;
    z-index: 3;
    width: 100%;
}

/* WRAPPER EN GRILLE (Gauche libre / Droite contenu) */
.hero-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.gradient-bar {
    width: 120px;
    height: 15px;
    background: linear-gradient(to right, var(--corail-vif), var(--violet-royal), var(--cyan-electric));
    /* border-radius: 5px; */
    margin-bottom: 22px;
}

/*=====================================================
  TEXTES & SLIDES (FIX RESPONSIVE OVERLAP)
======================================================*/
.hero-slides {
    /* On utilise Grid pour superposer les éléments sans perdre la hauteur dynamique */
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
    align-items: start;
    width: 100%;
}

.hero-slide {
    /* Au lieu de position: absolute, on place tous les slides dans la même case de la grille */
    grid-column: 1;
    grid-row: 1;

    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
    z-index: 1;
}

.hero-slide.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
    z-index: 2;
}

/* TYPOGRAPHIE FLUIDE */
.hero-subtitle {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 14px;
}

.hero-title {
    font-family: var(--font-heading, sans-serif);
    /* Le texte s'adapte automatiquement à la largeur de l'écran */
    font-size: clamp(26px, 3.2vw, 46px);
    line-height: 1.15;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -1px;
    margin-bottom: 20px;
}

.hero-title .text-highlight {
    color: var(--accent-orange);
    text-shadow: 0 0 25px rgba(0, 212, 255, 0.2);
}

.hero-description {
    font-size: clamp(15px, 1.2vw, 18px);
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
    max-width: 540px;
    margin-bottom: 10px;
}

/*=====================================================
  BOUTONS D'ACTION
======================================================*/
.hero-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 45px;
}

.btn-slider-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #1881ff;
    /* background: linear-gradient(135deg, #00d4ff 0%, #0066ff 100%); */
    background: linear-gradient(to right, var(--corail-vif), var(--violet-royal), var(--cyan-electric));
    color: #ffffff;
    padding: 16px 32px;
    border-radius: 999px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 10px 25px rgba(0, 110, 255, 0.35);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn-slider-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(0, 212, 255, 0.5);
}

.btn-video {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.btn-video:hover {
    opacity: 0.85;
}

.play-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
}

/*=====================================================
  BADGES DE CONFIANCE
======================================================*/
.hero-right {
    display: flex;
    flex-direction: column;
    /* Aligne les slides puis les badges verticalement */
    align-items: flex-start;
    justify-content: center;
    width: 100%;
}

/* 2. On configure le bloc de confiance pour qu'il se place sous le bouton */
.hero-trust {
    margin-top: 45px;
    /* Ajoute un bel espace entre le bouton et les badges */
    display: flex;
    flex-direction: column;
    /* Place "LICENCÉ PAR" au-dessus des logos */
    align-items: flex-start;
    gap: 12px;
    width: 100%;
}

/* 3. On s'assure que le texte ne se coupe plus sur deux lignes */
.hero-trust .trust-title {
    font-size: 11px;
    letter-spacing: 1.5px;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 700;
    white-space: nowrap;
    /* Force le texte à rester sur une seule ligne */
}

/* 4. On garde les logos alignés horizontalement */
.hero-trust .trust-icons {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    /* Sécurité : passe à la ligne sur les très petits écrans */
}

.hero-trust .trust-icon-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hero-trust .trust-name {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.trust-divider {
    color: rgba(255, 255, 255, 0.2);
    font-size: 12px;
}

/*=====================================================
  FLÈCHES DE NAVIGATION LATÉRALES
======================================================*/
.hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(8px);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hero-prev {
    left: 30px;
}

.hero-next {
    right: 30px;
}

.hero-arrow:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: #ffffff;
    transform: translateY(-50%) scale(1.08);
}

/*=====================================================
  BARRE DU BAS (COMPTEUR & INDICATEURS)
======================================================*/
.hero-bottom-bar {
    margin-top: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hero-counter {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-heading, sans-serif);
}

.hero-counter .current-num {
    font-size: 28px;
    font-weight: 800;
}

.hero-counter .total-num {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.4);
}

.progress-bar {
    width: 140px;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    overflow: hidden;
    margin-left: 10px;
}

.progress-fill {
    width: 0%;
    height: 100%;
    background: var(--cyan-electric);
    transition: width 0.1s linear;
}

.hero-indicators {
    display: flex;
    gap: 8px;
}

.indicator-bar {
    width: 32px;
    height: 3px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 2px;
    cursor: pointer;
    transition: background 0.3s ease, width 0.3s ease;
}

.indicator-bar.active {
    background: var(--cyan-electric);
    width: 44px;
}

/*=====================================================
  RESPONSIVE (TABLETTES & MOBILES) - SPLIT LAYOUT BLANC
======================================================*/

@media (max-width: 1024px) {
    .hero-bg-slide {
        background-image: var(--bg-mobile);
    }

    .hero-slider {
        display: flex;
        flex-direction: column;
        background-color: #ffffff;
        padding: 90px 0 40px 0;
        min-height: auto;
    }

    .hero-bg-slides {
        position: relative;
        width: calc(100% - 40px);
        max-width: 800px;
        height: 350px;
        margin: 0 auto;
        border-radius: 24px;
        overflow: hidden;
        z-index: 1;
        box-shadow: 0 15px 35px rgba(0, 10, 30, 0.1);
    }

    .hero-overlay {
        display: none;
    }

    /* Centrage mathématique : 90px (padding-top) + 175px (moitié de 350px) */
    .hero-arrow {
        top: calc(90px + 175px);
        width: 42px;
        height: 42px;
    }

    .hero-prev {
        left: 30px;
    }

    .hero-next {
        right: 30px;
    }

    /* Couleurs du texte inversées */
    .hero-title {
        color: #030a1c;
        font-size: 40px;
    }

    .hero-description {
        color: #4a5568;
    }

    .hero-subtitle {
        color: var(--violet-royal);
    }

    .hero-counter {
        color: #030a1c;
    }

    .hero-counter .total-num {
        color: #718096;
    }

    .progress-bar {
        background: #e2e8f0;
    }

    .indicator-bar {
        background: #cbd5e0;
    }

    .hero-container {
        padding-top: 40px;
    }

    .hero-wrapper {
        grid-template-columns: 1fr;
    }

    .hero-left-spacer {
        display: none;
    }
}

@media (max-width: 767px) {
    .hero-slider {
        min-height: 100svh;
        height: auto;
        padding: 80px 0 20px 0;
        /* Laisse l'espace exact pour la navbar en haut */
        overflow: hidden;
    }

    /* 1. Image bien proportionnée */
    .hero-bg-slides {
        height: clamp(200px, calc(100svh - 420px), 320px);
        width: calc(100% - 40px);
        /* Marges latérales respectées */
        margin: 0 auto;
        border-radius: 20px;
        flex-shrink: 0;
    }

    /* 2. Flèches toujours centrées dynamiquement sur l'image */
    .hero-arrow {
        top: calc(80px + (max(220px, 35vh) / 2));
        width: 36px;
        height: 36px;
        background: rgba(3, 10, 28, 0.4);
        border: none;
    }

    .hero-prev {
        left: 30px;
    }

    .hero-next {
        right: 30px;
    }

    /* =========================================================
       LE CORRECTIF : Alignement et respiration du contenu 
    ========================================================= */
    .hero-container {
        flex-grow: 1;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        /* On ancre tout vers le haut (sous l'image) */
        padding-top: 35px;
        /* Distance exacte et fixe entre l'image et le titre */
        padding-bottom: 20px;
    }

    .hero-title {
        font-size: clamp(26px, 7vw, 32px);
        margin-bottom: 12px;
        /* Rapproche le titre de la barre dégradée */
        line-height: 1.15;
    }

    .gradient-bar {
        margin-bottom: 15px;
        /* Espace avant le texte descriptif */
        height: 8px;
        width: 80px;
    }

    .hero-description {
        font-size: 15px;
        line-height: 1.5;
        margin-bottom: 30px;
        /* Espace volontaire pour bien détacher le bouton */
        color: #4a5568;
    }

    .hero-actions {
        margin-top: 0;
        flex-direction: column;
        align-items: stretch;
        /* Le margin-top automatique poussera le bouton vers le bas si vous 
           voulez qu'il soit collé en bas de l'écran plus tard, 
           mais pour l'instant, il suit le texte naturellement */
    }

    .btn-slider-primary {
        justify-content: center;
        padding: 16px 24px;
        font-size: 16px;
    }

    /* 3. On cache les éléments superflus */
    .hero-bottom-bar {
        display: none;
    }
}