h2 {
    margin-top: clamp(36px, 8vw, 100px);
    margin-bottom: clamp(20px, 3vw, 40px);
    padding-bottom: 10px;
    position: relative;
    display: flex;
    justify-content: center;
    font-size: clamp(1.1rem, 3vw, 1.6rem);
}

h2::after {
    content: "";
    background-color: #DB6161;
    position: absolute;
    width: 100px;
    height: 2px;
    bottom: 0;
    left: -10;
}

.projets {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    margin-top: clamp(24px, 8vw, 100px);
    margin-bottom: clamp(40px, 8vw, 100px);
    gap: clamp(6px, 1.5vw, 10px);
}

.cards {
    position: relative;
    margin: clamp(4px, 1vw, 10px);
}

.cards p {
    font-family: 'gravitas';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    margin: 0;
    padding-left: 10px;
    padding-right: 10px;
    height: 100%;
    background: #1F0802;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
    opacity: 0;
    display: flex;
    align-items: center;
    border-radius: clamp(14px, 2.5vw, 20px);
    font-size: clamp(0.78rem, 1.2vw, 1rem);
}

.cards:hover p,
.cards:focus-within p { /* Mise en forme de l'apparance du paragraphe lors du hover */
    opacity: 0.55;
}

.cards img {
    height: clamp(140px, 22vw, 300px);
    width: auto;
    max-width: 100%;
    border: 1px solid white;
    border-radius: clamp(14px, 2.5vw, 30px);
}

/* ── MOBILE (≤ 480px) ── */
@media (max-width: 480px) {

    .projets {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        padding: 0 10px;
    }
    
    .cards img {
        width: 100%;
        object-fit: cover;
    }
}