/* Grille responsive */
.mes-projets-grid {
    display: grid;
    gap: 20px;
    padding: 20px 0;
    grid-template-columns: repeat(5, 1fr);
}

/* Mobile: 1 colonne */
@media (max-width: 599px) {
    .mes-projets-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablette: 2 colonnes */
@media (min-width: 600px) and (max-width: 899px) {
    .mes-projets-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Desktop: 3 colonnes */
@media (min-width: 900px) and (max-width: 1199px) {
    .mes-projets-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Container de projet */
.project-container {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Lien du projet */
.project-link {
    display: flex;
    flex-direction: column;
    flex: 1;
    text-decoration: none;
    color: inherit;
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
    background: #fff;
    height: 100%;
}

.project-link:hover {
    border-color: #4a90e2;
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.25);
    transform: translateY(-2px);
}

/* Titre du projet */
.project-title {
    margin: 0 0 12px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    text-align: center;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: break-word;
}

/* Thumbnail du projet */
.project-thumbnail {
    text-align: center;
    margin-bottom: 12px;
    flex-shrink: 0;
}

.project-thumbnail img {
    width: 128px;
    height: 128px;
    object-fit: contain;
    aspect-ratio: 1/1;
    image-rendering: pixelated;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fafafa;
}

/* Informations du projet */
.project-info {
    font-size: 13px;
    color: #555;
    line-height: 1.8;
    text-align: left;
    flex: 1;
}

.project-info > div {
    margin-bottom: 4px;
}

/* Bouton de suppression */
.delete-btn {
    display: block;
    width: 100%;
    margin-top: 10px;
    padding: 10px 12px;
    color: #fff;
    background-color: #d32f2f;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.delete-btn:hover {
    background-color: #b71c1c;
    transform: scale(1.02);
}

.delete-btn:active {
    transform: scale(0.98);
}

/* Responsive pour très petits écrans */
@media (max-width: 400px) {
    .project-link {
        padding: 12px;
    }

    .project-title {
        font-size: 14px;
        min-height: 36px;
    }

    .project-thumbnail img {
        width: 100px;
        height: 100px;
    }

    .project-info {
        font-size: 12px;
    }
}
