body {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    padding: 0;
    background-image: url('Image/fond.avif');
    color: #333;
}

/* Le style du web */
#MainTop {
    background: rgba(0,121,107,0.9);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 999;
}

#MainTop nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 15px 0;
}

#MainTop nav a {
    text-decoration: none;
    color: #fff;
    padding: 10px 20px;
    border-radius: 20px;
    background: #004d40;
    font-weight: 600;
    transition: transform 0.3s, background 0.3s;
}

#MainTop nav a:hover {
    background: #ffffff;
    color: #00796b;
    transform: scale(1.05);
}

main h1 {
    text-align: center;
    color: #00796b;
    margin: 20px 0;
    font-size: 2.5rem;
}

.search-and-sort {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0;
}

.search-and-sort input[type="text"] {
    padding: 12px 20px;
    font-size: 1rem;
    border: 2px solid #00796b;
    border-radius: 25px;
    width: 300px;
    outline: none;
}

.search-and-sort select {
    padding: 12px;
    font-size: 1rem;
    border: 2px solid #00796b;
    border-radius: 25px;
    outline: none;
}

/* Bouton pour basculer */
#dark-mode-toggle {
    position: fixed;
    top: 10px;
    right: 10px;
    padding: 10px 15px;
    background-color: #00796b;
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    z-index: 1000;
}

#dark-mode-toggle:hover {
    background-color: #004d40;
}

/* Mode sombre */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

body.dark-mode a {
    color: #80cbc4;
}

body.dark-mode a:hover {
    color: #4db6ac;
}

body.dark-mode .article-block {
    background-color: #1e1e1e;
    color: #e0e0e0;
    box-shadow: 0 4px 8px rgba(255, 255, 255, 0.1);
}

body.dark-mode footer {
    background-color: #1e1e1e;
    color: #b0b0b0;
}


/* Les conteneurs et blocks des articles */
.articles-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: auto;
}

.article-block {
    background-color: #ffffff;
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 20px;
    width: 300px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.article-block:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.article-block img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 10px 0;
    transition: transform 0.3s ease;
}

.article-block img:hover {
    transform: scale(1.1);
}

.article-block h2 {
    color: #00796b;
    font-size: 1.5rem;
    margin: 15px 0;
}

.article-block p {
    font-size: 1rem;
    line-height: 1.5;
    margin: 10px 0;
    color: #555;
}

.article-block a {
    display: inline-block;
    padding: 10px 15px;
    color: #ffffff;
    background-color: #00796b;
    text-decoration: none;
    border-radius: 25px;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.article-block a:hover {
    background-color: #004d40;
    transform: scale(1.05);
}

/* Responsive */
@media (max-width: 768px) {
    .articles-container {
        flex-direction: column;
        align-items: center;
    }

    .article-block {
        width: 90%;
    }
}
footer {
    background-color: #0a3d2e;
    padding: 1rem;
    text-align: center;
    color: #aaa;
    position: relative;
    bottom: 0;
    width: 100%;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem; /* Ajuste l'espacement entre les éléments */
    font-size: 0.9rem;
}

.footer-content a {
    color: #aaa;
    text-decoration: none;
}

.footer-content a:hover {
    color: #fff;
}

.footer-content img {
    width: 30px;
    height: 30px;
    border-radius: 50%; /* Pour rendre l'image circulaire */
    margin-left: 1rem; /* Ajuste l'espacement entre l'avatar et le texte */
}

.footer-content span {
    color: #aaa;
    font-size: 0.9rem;
    margin-left: 1rem;
}
@media screen and (max-width: 768px) {
    /* Styles pour tablettes */
}

@media screen and (max-width: 480px) {
    /* Styles pour téléphones */
}

   /* ------------------------ *
 *     MENU BURGER (Mobile)
 * ------------------------ */
 #menu-label {
    display: none;
    font-size: 2rem;
    cursor: pointer;
    color: white;
    padding: 10px;
    text-align: center;
    background: #004d40;
  }
  
  #MainTop nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 15px 0;
    flex-wrap: wrap;
  }
  
  #MainTop nav a {
    text-decoration: none;
    color: #fff;
    padding: 10px 20px;
    border-radius: 20px;
    background: #004d40;
    font-weight: 600;
    transition: transform 0.3s, background 0.3s;
  }
  
  #MainTop nav a:hover {
    background: #ffffff;
    color: #00796b;
    transform: scale(1.05);
  }
  
  /* Mode mobile */
  @media (max-width: 768px) {
    #menu-label {
        display: block;
        padding: 15px;
        font-size: 1.5rem;
    }
  
    #MainTop nav {
        display: none;
        flex-direction: column;
        align-items: center;
        width: 100%;
        background: #004d40;
        position: absolute;
        top: 60px;
        left: 0;
        z-index: 999;
    }
  
    /* ✅ Ajout de cette ligne pour s'assurer que la classe active s'affiche bien */
    #MainTop nav.active {
        display: flex;
    }
  
    #MainTop nav a {
        width: 100%;
        text-align: center;
        padding: 15px;
        font-size: 1.2rem;
    }
  }