/* --- 1. VARIABLES & RESET --- */
:root {
    /* Palette de couleurs */
    --bg-body: #FFFFFF;
    --bg-alt: #F8FAFC;     /* Gris très clair */
    --bg-dark: #0F172A;    /* Bleu nuit profond (Dark Mode) */
    
    --text-main: #0F172A;  /* Texte principal */
    --text-muted: #64748B; /* Texte secondaire */
    --text-light: #CBD5E1; /* Texte sur fond sombre */
    
    --primary: #2563EB;    /* Bleu Royal */
    --primary-dark: #1E40AF;
    --accent: #F59E0B;     /* Orange (Avis) */
    
    --border: #E2E8F0;
    
    /* Typographie & Animation */
    --font-main: 'Plus Jakarta Sans', sans-serif;
    --ease-out: cubic-bezier(0.215, 0.61, 0.355, 1); /* Courbe fluide */
    --header-height: 80px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* --- 2. TYPOGRAPHIE RESPONSIVE --- */
h1, h2, h3, h4 { line-height: 1.1; font-weight: 800; letter-spacing: -0.02em; }

h1 { font-size: clamp(2.5rem, 5vw + 1rem, 4rem); margin-bottom: 1.5rem; }
h2 { font-size: clamp(2rem, 4vw + 1rem, 3rem); margin-bottom: 1rem; }
h3 { font-size: 1.5rem; margin-bottom: 0.5rem; }

p { font-size: clamp(1rem, 0.5vw + 0.9rem, 1.125rem); color: var(--text-muted); max-width: 65ch; }
.lead { font-size: 1.25rem; color: var(--text-main); font-weight: 500; }

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* --- 3. NAVIGATION --- */
.navbar {
    position: fixed; top: 0; left: 0; width: 100%; height: var(--header-height);
    background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(12px);
    z-index: 1000; border-bottom: 1px solid rgba(0,0,0,0.05);
    display: flex; justify-content: space-between; align-items: center; padding: 0 5%;
}
.logo { font-size: 1.5rem; font-weight: 800; letter-spacing: -1px; z-index: 1001; color: var(--text-main); }
.nav-links { display: flex; gap: 2.5rem; align-items: center; }
.nav-links a { font-weight: 600; font-size: 0.95rem; position: relative; color: var(--text-muted); }
.nav-links a:hover, .nav-links a.active { color: var(--primary); }

/* Soulignement animé */
.nav-links a::after {
    content: ''; position: absolute; width: 0; height: 2px; bottom: -4px; left: 0;
    background-color: var(--primary); transition: width 0.3s var(--ease-out);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-links a.btn::after { display: none; } 

/* --- 4. BOUTONS --- */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 14px 28px; border-radius: 50px; font-weight: 600;
    transition: transform 0.3s var(--ease-out), box-shadow 0.3s ease, background 0.3s;
    cursor: pointer; border: none; font-family: inherit; font-size: 0.95rem;
}
.btn-primary { background: var(--text-main); color: #FFF; }
.btn-primary:hover { background: var(--primary); transform: translateY(-2px); box-shadow: 0 10px 20px rgba(37, 99, 235, 0.2); }

.btn-outline { border: 1px solid var(--border); background: transparent; color: var(--text-main); }
.btn-outline:hover { border-color: var(--text-main); background: var(--text-main); color: #FFF; }

/* --- 5. LAYOUT & GRIDS --- */
section { padding: 100px 5%; position: relative; }
.container { max-width: 1200px; margin: 0 auto; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }

/* --- 6. CARDS & VISUALS --- */
.card {
    background: #FFF; border: 1px solid var(--border); padding: 40px; border-radius: 16px;
    transition: 0.4s var(--ease-out); height: 100%; display: flex; flex-direction: column; justify-content: space-between;
}
.card:hover { transform: translateY(-8px); border-color: var(--primary); box-shadow: 0 20px 40px rgba(0,0,0,0.05); }

.tag {
    display: inline-block; padding: 6px 12px; background: #EFF6FF; color: var(--primary);
    border-radius: 6px; font-size: 0.8rem; font-weight: 700; text-transform: uppercase; margin-bottom: 1rem; letter-spacing: 0.05em;
}

.visual-box {
    background: var(--bg-alt); border-radius: 20px; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--border);
}

/* --- 7. STYLES SPECIFIQUES HOMEPAGE & PRODUITS --- */

/* Section Sombre (Dark Mode) */
.dark-mode {
    background-color: var(--bg-dark);
    color: white;
}
.dark-mode h2, .dark-mode h3 { color: white; }
.dark-mode p, .dark-mode .lead { color: var(--text-light); }
.dark-mode .tag { background: rgba(255,255,255,0.1); color: white; border: 1px solid rgba(255,255,255,0.2); }

/* Product Box (Le conteneur des logiciels sur fond noir) */
.product-box {
    background: rgba(255,255,255,0.05); 
    padding: 40px; 
    border-radius: 16px; 
    border: 1px solid rgba(255,255,255,0.1);
    transition: 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.product-box:hover {
    background: rgba(255,255,255,0.08);
    transform: translateY(-5px);
    border-color: rgba(255,255,255,0.3);
}

/* Product Logo (Les icônes JPG arrondies) */
.product-logo {
    width: 80px;
    height: 80px;
    border-radius: 16px;   /* Arrondi type App */
    object-fit: cover;
    margin-bottom: 24px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
}
.product-box:hover .product-logo {
    transform: scale(1.05);
}

/* Process Steps (Ligne verticale) */
.process-step {
    position: relative; padding-left: 30px; border-left: 2px solid var(--border); padding-bottom: 40px;
}
.process-step:last-child { border-left: 2px solid transparent; }
.process-step::before {
    content: ''; position: absolute; left: -6px; top: 0; width: 10px; height: 10px;
    background: var(--primary); border-radius: 50%; outline: 4px solid white;
}
.process-step h3 { font-size: 1.25rem; margin-bottom: 10px; }

/* Chiffres Clés */
.stat-number { font-size: 3.5rem; font-weight: 800; color: var(--primary); line-height: 1; margin-bottom: 10px; }
.stat-label { font-size: 1.1rem; font-weight: 600; color: var(--text-main); }

/* --- 8. FORMULAIRES --- */
.form-group { margin-bottom: 1.5rem; }
.form-label { display: block; margin-bottom: 0.5rem; font-weight: 600; font-size: 0.9rem; }
.form-input, .form-select, .form-textarea {
    width: 100%; padding: 16px; background: var(--bg-alt); border: 1px solid transparent;
    border-radius: 8px; font-family: inherit; font-size: 1rem; transition: 0.3s;
}
.form-input:focus, .form-textarea:focus { outline: none; border-color: var(--primary); background: #FFF; box-shadow: 0 0 0 4px #EFF6FF; }
.checkbox-group { display: flex; gap: 10px; align-items: start; font-size: 0.9rem; }

/* --- 9. FOOTER --- */
footer { background: var(--text-main); color: #FFF; padding: 80px 5% 30px; }
footer h3 { color: white; }
footer a { color: #94A3B8; transition: 0.3s; }
footer a:hover { color: #FFF; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 60px; }

/* --- 10. ANIMATIONS (SECURISÉES) --- */

/* État par défaut : Visible (sécurité si JS plante) */
.reveal {
    transition: all 0.8s var(--ease-out);
    opacity: 1; 
    transform: translateY(0);
}

/* État d'attente (ajouté par JS au chargement) */
.reveal-waiting {
    opacity: 0;
    transform: translateY(30px);
}

/* État visible (ajouté par JS au scroll) */
.reveal-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- 11. RESPONSIVE & MOBILE --- */
.burger { display: none; cursor: pointer; z-index: 1001; }
.burger div { width: 25px; height: 2px; background: var(--text-main); margin: 6px; transition: 0.4s; }

/* Bannière Cookie */
#cookie-banner {
    position: fixed; bottom: 20px; right: 20px; width: 340px; background: #FFF;
    padding: 24px; border-radius: 16px; box-shadow: 0 20px 50px rgba(0,0,0,0.15);
    border: 1px solid var(--border); z-index: 9999; transform: translateY(200%); transition: 0.6s var(--ease-out);
}

@media (max-width: 900px) {
    .grid-2, .grid-3 { grid-template-columns: 1fr; gap: 40px; }
    .footer-grid { grid-template-columns: 1fr; gap: 30px; }
    
    .navbar { padding: 0 20px; }
    .burger { display: block; }
    
    .nav-links {
        position: fixed; top: 0; right: 0; height: 100vh; width: 100%; background: #FFF;
        flex-direction: column; justify-content: center; align-items: center;
        transform: translateX(100%); transition: transform 0.4s var(--ease-out); padding: 2rem;
    }
    .nav-links.nav-active { transform: translateX(0); }
    .nav-links a { font-size: 1.5rem; margin: 15px 0; }
    
    .toggle .line1 { transform: rotate(-45deg) translate(-5px, 6px); }
    .toggle .line2 { opacity: 0; }
    .toggle .line3 { transform: rotate(45deg) translate(-5px, -6px); }
    
    h1 { font-size: 2.5rem; }
    .visual-box { height: 300px; }
}
