body {
    background-color: #550000;
    background-image: url('/data/img/fonds/john-matychuk-gUK3lA3K7Yo-unsplash.jpg');
    background-attachment: fixed;
    background-size: cover;
    background-position: center;
    margin: 0;
    padding: 0;
}

.content-wrapper {
    max-width: 960px;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.85);
    padding: 20px;
    box-sizing: border-box;
    overflow: auto;
}

h1 {
    font-family: "Cooper Black", "Caprasimo", serif;
    color: #324755;
    font-size: 8vh;
    text-align: center;
    margin-top: 20px;
}

h2 {
    font-family: "Cooper Black", "Caprasimo", serif;
    color: #550000;
    font-size: 3vh;
    text-align: center;
    margin-top: 20px;
}

.center {
    text-align: center;
}

/* --- BARRE DE NAVIGATION --- */
nav {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 2000;
    background-color: #38444d;
}

nav ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: #38444d;
    width: 100%;
}

nav li {
    float: left;
}

nav li.right {
    float: right;
}

nav li a, .dropbtn {
    display: inline-block;
    color: white;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
}

nav li a:hover, .dropdown:hover .dropbtn {
    background-color: #111;
}

nav li a.active, li.dropdown.active .dropbtn {
    background-color: #04AA6D;
}

/* --- MENUS DEROULANTS (DROPDOWN) --- */
li.dropdown {
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #38444d;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 2001;
}

.dropdown-content a {
    color: white;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
}

.dropdown-content a:hover {
    background-color: #111;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* --- RESPONSIVE MENU & TITRES --- */
@media screen and (max-width: 600px) {
    h1 {
        font-size: 2.5rem; /* Bien plus calme que 8vh */
        margin-top: 10px;
    }
    h2 {
        font-size: 1.5rem;
    }
    nav ul {
        overflow: visible; /* Important pour laisser le menu s'étendre */
    }
    nav li {
        float: none;
        width: 100%;
        border-bottom: 1px solid #4a5a63;
    }
    nav li.right {
        float: none;
    }
    nav li a, .dropbtn {
        display: block;
        width: 100%;
        text-align: left;
        box-sizing: border-box;
        padding: 15px 20px;
    }
    .dropdown-content {
        position: static; /* On l'intègre au flux normal du menu */
        display: none; /* On le cache par défaut */
        width: 100%;
        box-shadow: none;
        background-color: #2c3640; /* Un peu plus sombre pour distinguer */
    }
    /* On l'affiche quand on survole (ou clique sur mobile) l'élément parent */
    .dropdown:hover .dropdown-content, .dropdown.active .dropdown-content {
        display: block;
    }
    .dropdown-content a {
        padding-left: 40px; /* On indente les sous-liens */
    }
}

/* --- GRILLE DES TITRES (LISTE) --- */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
}

.grid-item {
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.grid-item img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* --- FOOTER --- */
footer {
    background-color: #38444d;
    color: #fff;
    padding: 30px 0;
    text-align: center;
    margin-top: 40px;
    clear: both;
}

.footer-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-content a {
    color: #fff;
    text-decoration: none;
}

.footer-content a:hover {
    color: #d32f2f;
}

/* --- BOUTONS --- */
.btn-primary {
    background-color: #d32f2f;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: bold;
    cursor: pointer;
}

.btn-primary:hover {
    background-color: #b71c1c;
}

#back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #d32f2f;
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    text-align: center;
    line-height: 40px;
    cursor: pointer;
    z-index: 3000;
}
