/* style.css */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;700;900&display=swap');

:root {
    --bg-dark: #121212;
    --bg-light: #1e1e1e;
    --primary: #2c2c2c;
    --accent: #69F0AE;
    --text-light: #ffffff;
    --text-muted: #a0a0a0;
    --navbar-height: 70px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--navbar-height);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-light);
    line-height: 1.7;
    overflow-x: hidden; /* Empêche le défilement horizontal indésirable */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--navbar-height);
    background: transparent;
    z-index: 1000;
    transition: background-color 0.3s ease;
}
.navbar.scrolled {
    background-color: rgba(30, 30, 30, 0.9); /* Plus opaque quand scrollé */
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--primary);
}
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}
.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-light);
    font-weight: 700;
    font-size: 1.2rem;
}
.nav-logo img {
    width: 40px;
    height: 40px;
    border-radius: 8px;
}
.nav-menu {
    list-style: none;
    display: flex;
    gap: 30px;
}
.nav-menu a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 700;
    transition: color 0.3s ease;
}
.nav-menu a:hover {
    color: var(--accent);
}
.mobile-menu-toggle {
    display: none; /* Caché par défaut sur grand écran */
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
    padding: 10px;
}
.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-light);
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
}
.mobile-menu-toggle.is-active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.mobile-menu-toggle.is-active span:nth-child(2) {
    opacity: 0;
}
.mobile-menu-toggle.is-active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
    padding-top: calc(var(--navbar-height) + 80px);
    text-align: center;
    padding-bottom: 80px;
}
.hero-logo {
    width: 120px;
    height: 120px;
    border-radius: 24px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}
.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 900;
    margin-bottom: 1rem;
    line-height: 1.1;
}
.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.25rem);
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto 2.5rem auto;
}
.cta-button {
    background: var(--accent);
    color: #000;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: inline-block;
}
.cta-button:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(105, 240, 174, 0.2);
}

/* --- Feature Sections --- */
.feature {
    display: flex;
    align-items: center;
    gap: 4rem;
    padding: 4rem 0;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.feature.visible {
    opacity: 1;
    transform: translateY(0);
}
.feature:nth-child(even) {
    flex-direction: row-reverse;
}
.feature-text {
    flex: 1.2;
    position: relative;
    z-index: 2;
}
.feature-text h2 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 900;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}
.feature-text p {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 500px;
}
.feature-image-group {
    flex: 1;
    display: flex;
    position: relative;
    justify-content: center;
    align-items: center;
    gap: -40px; /* Superposition réduite */
    min-height: 300px; /* Hauteur minimale pour éviter l'écrasement */
}
.phone-mockup {
    max-width: 280px;
    width: 100%;
    border-radius: 30px;
    border: 8px solid #000;
    box-shadow: 0 20px 50px rgba(0,0,0,0.6);
    transition: transform 0.4s ease;
    display: block;
    margin: 0 auto;
}
.phone-mockup:hover {
    transform: scale(1.05) rotate(2deg);
    z-index: 3;
}
.feature-image-group img:nth-child(2) {
    transform: rotate(5deg) translateX(-40px); /* Décalage réduit */
}
.feature-image-group img:nth-child(2):hover {
    transform: scale(1.05) rotate(0deg) translateX(-40px);
}
.feature:nth-child(even) .feature-image-group img:nth-child(2) {
    transform: rotate(-5deg) translateX(40px); /* Décalage réduit */
}
.feature:nth-child(even) .feature-image-group img:nth-child(2):hover {
    transform: scale(1.05) rotate(0deg) translateX(40px);
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 3rem 0;
    background: var(--bg-light);
    border-top: 1px solid var(--primary);
}
footer a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.3s ease;
}
footer a:hover {
    color: var(--accent);
}

/* --- Responsive Design pour tablettes et petits desktops (max-width: 992px) --- */
@media (max-width: 992px) {
    .feature {
        flex-direction: column !important;
        gap: 3rem;
        padding: 3rem 0;
        text-align: center;
    }
    .feature-text p {
        margin: 0 auto;
    }
    .feature-image-group {
        gap: -60px;
        margin-top: 2rem;
        min-height: auto;
        flex-wrap: wrap;
        justify-content: center;
    }
    .phone-mockup {
        max-width: 250px;
    }
    .feature-image-group img:nth-child(2) {
        transform: rotate(5deg) translateX(-30px);
    }
    .feature-image-group img:nth-child(2):hover {
        transform: scale(1.05) rotate(0deg) translateX(-30px);
    }
    .feature:nth-child(even) .feature-image-group img:nth-child(2) {
        transform: rotate(-5deg) translateX(30px);
    }
    .feature:nth-child(even) .feature-image-group img:nth-child(2):hover {
        transform: scale(1.05) rotate(0deg) translateX(30px);
    }
}

/* --- Responsive Design pour mobile (max-width: 767px) --- */
@media (max-width: 767px) {
    .container {
        padding: 0 15px;
    }
    .nav-menu {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: var(--bg-dark);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transform: translateX(100%);
        transition: transform 0.3s ease-in-out;
        z-index: 999;
    }
    .nav-menu.is-active {
        transform: translateX(0);
        display: flex;
    }
    .nav-menu li {
        margin: 20px 0;
    }
    .nav-menu a {
        font-size: 1.5rem;
        color: var(--text-light);
    }
    .mobile-menu-toggle {
        display: block;
    }

    .hero-title {
        font-size: 2.5rem;
    }
    .hero-subtitle {
        font-size: 1rem;
    }
    .feature-text h2 {
        font-size: 2rem;
    }
    .feature-text p {
        font-size: 1rem;
    }
    .feature-image-group {
        /* Modifications clés pour les images côte à côte sur mobile */
        flex-direction: row; /* Repasse en ligne pour les images */
        flex-wrap: wrap;     /* Permet aux images de s'ajuster sur plusieurs lignes si l'écran est trop étroit */
        justify-content: center; /* Centre les images */
        gap: 15px;           /* Petit espace entre les images */
        margin-top: 1.5rem;
        position: static;
    }
    .phone-mockup {
        max-width: 48%; /* Chaque image prendra environ la moitié de la largeur du conteneur */
        width: 100%;    /* Assure que la largeur max s'applique bien */
        border-width: 6px;
        /* Supprime les transformations spécifiques à la deuxième image */
        transform: none !important; 
        position: static !important;
        margin: 0 !important; /* Réinitialise les marges pour un affichage côte à côte */
    }
    /* Supprime la classe hidden-on-mobile car on veut voir les deux images */
    .hidden-on-mobile {
        display: block !important; 
    }
}

body {
    overflow-x: hidden;
}
