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

/* Style global du body */
body {
    font-family: "Arial", sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    color: #333;
}
header img{
    max-width: 200px;
    height: auto;
}

/* En-tête avec un fond en dégradé et des éléments centrés */
header {
    background: linear-gradient(135deg, #b71c1c, #e63d3d);
    text-align: center;
    padding: 30px 20px;
    color: white;
     
}
header .logo img {
    width: 200px;  /* Réduit la largeur de l'image à 200px */
}



header h1 {
    font-size: 2.5rem;
    margin-top: 15px;
}

/* Barre de navigation */
nav {
    display: flex; /* Utilise flexbox pour la disposition des éléments */
    justify-content: center; /* Centre les liens de navigation horizontalement */
    background-color: #b71c1c; /* Définie la couleur de fond */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Ajoute une ombre */
}

nav a {
    text-decoration: none; /* Enlève le soulignement des liens */
    color: white; /* Définit la couleur des liens */
    padding: 18px 25px; /* Ajoute de l'espace autour des liens */
    font-size: 1.1rem; /* Définit la taille de la police des liens */
    transition: background-color 0.3s, color 0.3s; /* Transition pour les changements de couleur */
}

nav a:hover,
nav a.active {
    background-color: white; /* Change la couleur de fond des liens */
    color: #b71c1c; /* Change la couleur du texte des liens */
}

/* Conteneur principal */
main {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
}

.news {
    margin-top: 40px;
}

/* Articles */
.news-item {
    display: grid;
    grid-template-columns: 1fr 2fr;
    align-items: center;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-item:nth-child(even) {
    grid-template-columns: 2fr 1fr;
}

.news-item:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.news-item img {
    width: 100%;
    height: auto;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-item div {
    padding: 20px;
}

.news-item h2 {
    font-size: 1.5rem;
    color: #b71c1c;
    margin-bottom: 10px;
}

.news-item p {
    line-height: 1.6;
    font-size: 1rem;
}

.news-item a {
    display: inline-block;
    margin-top: 10px;
    color: #d30000;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.news-item a:hover {
    color: #b71c1c;
}

/* Footer */
footer {
    background-color: #b71c1c; /* Couleur de fond du footer */
    color: white; /* Texte blanc dans le footer */
    text-align: center; /* Centre le texte dans le footer */
    padding: 15px 10px; /* Espacement intérieur du footer */
    
    line-height: 1.8; /* Augmente l'espace entre les lignes de texte */
}


/* Masquer le texte sous les h2 quand l'écran est inférieur à 500px */
@media (max-width: 499px) {
    .news-item p {
        display: none; /* Cache le texte sous les h2 */
    }
}

/* Responsive Design */

/* Adaptations pour les écrans plus petits */
@media (max-width: 768px) {
    *{
        width: 100%;
    }
    nav a {
        flex: 1 1 auto;
        text-align: center;
        padding: 10px 5px;
    }

    header {
        padding: 20px 10px;
    }
}

/* Masquer les 5 dernières colonnes des tableaux pour les écrans de moins de 500px */
@media (max-width: 500px) {
    table th:nth-last-child(-n+5),
    table td:nth-last-child(-n+5) {
        display: none;
    }

    table {
        font-size: 0.9rem;
    }

    header {
        font-size: 1.5rem;
    }

    nav a {
        font-size: 0.8rem;
        padding: 8px 3px;
    }

    footer {
        font-size: 0.8rem;
    }
  
}




