@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

:root {
    --primary-color: #00A650; /* Vert vif */
    --secondary-color: #212E3B; /* Bleu marine/anthracite foncé */
    --light-gray-color: #F5F4EE; /* Fond clair */
    --text-color: #5C5E5E; /* Gris texte */
    --white-color: #FFFFFF;
    --heading-font: 'Poppins', sans-serif;
    --body-font: 'Poppins', sans-serif;
}

/* Styles globaux */
body {
    font-family: var(--body-font);
    line-height: 1.7;
    margin: 0;
    padding: 0;
    background: var(--light-gray-color);
    color: var(--text-color);
}

.container {
    max-width: 1200px;
    margin: auto;
    overflow: hidden;
    padding: 0 20px;
}

h1, h2, h3, h4 {
    font-family: var(--heading-font);
    font-weight: 700;
    color: var(--secondary-color);
}

h2 span {
    color: var(--primary-color);
}

/* Header */
header {
    background: transparent;
    padding: 1.5rem 0;
    position: absolute;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1000;
    transition: background 0.3s ease, padding 0.3s ease;
}

header.scrolled {
    background: var(--white-color);
    position: fixed;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header .logo {
    font-size: 1.8rem;
    font-weight: bold;
    margin: 0;
    color: var(--white-color);
    text-decoration: none;
}
header.scrolled .logo {
    color: var(--secondary-color);
}


header ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
}

header ul li {
    margin-left: 30px;
}

header a {
    color: var(--white-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

header.scrolled a {
    color: var(--secondary-color);
}

header a:hover {
    color: var(--primary-color);
}

/* Hero Section */
#accueil {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../assets/Background.png') no-repeat center center/cover;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--white-color);
    padding-top: 80px; /* Pour compenser le header */
}

.hero-content h2 {
    font-size: 4rem;
    margin-bottom: 1rem;
    line-height: 1.2;
    color: var(--white-color);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Boutons */
.btn {
    display: inline-block;
    background: var(--primary-color);
    color: var(--white-color);
    padding: 1rem 2.5rem;
    text-decoration: none;
    border-radius: 50px; /* Pour un look plus moderne */
    font-weight: 600;
    transition: background 0.3s ease, transform 0.3s ease;
}

.btn:hover {
    background: #008f44;
    transform: translateY(-3px);
}

.btn-header {
    background: var(--primary-color);
    color: var(--white-color);
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
}

/* Sections générales */
section {
    padding: 6rem 0;
}

.section-title {
    text-align: center;
    font-size: 2.8rem;
    margin-bottom: 4rem;
}

/* Services Section */
#services {
    padding-bottom: 8rem; /* Ajout d'un espacement supplémentaire */
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.service-item {
    background: var(--white-color);
    padding: 0; /* On retire le padding global */
    padding-bottom: 2rem; /* On garde un padding en bas */
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.07);
    text-align: left; /* On aligne le texte à gauche */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden; /* Pour que l'image respecte les coins arrondis */
}

.service-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.service-item img {
    width: 100%; /* L'image prend toute la largeur de la carte */
    height: 200px; /* Hauteur fixe pour l'image */
    object-fit: cover; /* Pour que l'image ne soit pas déformée */
    margin-bottom: 1.5rem;
    /* On retire les anciens styles d'icône */
    background: none;
    padding: 0;
    border-radius: 0;
    box-sizing: border-box;
}

.service-item-content {
    padding: 0 2rem; /* Padding pour le contenu textuel */
}

.service-item h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

/* Pourquoi Nous Section */
#pourquoi-nous {
    background: var(--secondary-color);
    color: var(--white-color);
}

#pourquoi-nous .section-title {
    color: var(--white-color);
}

.reasons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
}

.reason {
    text-align: left; /* Alignement du texte à gauche */
}

.reason h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.reason p {
    color: #ccc;
}

/* Contact Section */
#contact {
    background: var(--white-color);
}

#contact p {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

form {
    max-width: 700px;
    margin: auto;
    background: var(--white-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid #ddd;
    border-radius: 10px;
    background: var(--light-gray-color);
    font-family: var(--body-font);
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

form button {
    width: 100%;
    padding: 1rem;
    border: none;
    cursor: pointer;
}

.contact-info {
    text-align: center;
    margin-top: 4rem;
}

.contact-info p {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

/* Footer */
footer {
    background: #111;
    color: #aaa;
    text-align: center;
    padding: 2rem 0;
}

/* Media Queries pour la responsivité */
@media(max-width: 768px) {
    header {
        padding: 1rem 0;
        background: var(--white-color); /* Sur mobile, le header est visible dès le début */
    }

    header.scrolled {
        padding: 1rem 0;
    }

    header .logo, header.scrolled .logo {
        color: var(--secondary-color);
    }

    /* Ici on cacherait le menu pour le remplacer par un hamburger. Pour l'instant, on simplifie */
    header nav {
        flex-direction: column;
    }

    header ul {
        margin-top: 1rem;
        flex-direction: column;
        text-align: center;
    }

    header ul li {
        margin: 0.5rem 0;
    }
    
    header.scrolled ul a, header ul a {
        color: var(--secondary-color);
    }

    .hero-content h2 {
        font-size: 2.8rem;
    }

    .section-title {
        font-size: 2.2rem;
    }

    .services-grid, .reasons-grid {
        grid-template-columns: 1fr;
    }

    section {
        padding: 4rem 0;
    }
}
