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

body {
    font-family: 'Poppins', sans-serif;
    color: black;
}

.lostCats {
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.lost-cats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); /* Grille fluide */
    gap: 20px;
    padding: 20px;
    justify-items: center;
}

.card {
    max-width: 90%;
    min-width: 90%;
    border-radius: 15px;
    overflow: hidden;
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 2px solid rgb(179, 179, 179);
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 6px 20px rgba(56, 56, 56, 0.334);
}

.card img {
    min-width: 100%;
    max-width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.3s ease-in-out;
    border-bottom: 2px solid rgb(179, 179, 179);
}

.card-content {
    padding: 20px;
    text-align: center;
}

.card h2 {
    font-size: 20px;
    font-weight: 600;
    margin: 10px 0;
    color: black;
}

.card h3 {
    font-size: 16px;
    font-weight: 500;
    margin: 10px 0;
    color: black;
}

.card .location {
    font-size: 14px;
    color: black;
    margin: 5px 0;
}

.card p {
    font-size: 12px;
    color: black;
    margin: 5px 0;
}

.card button {
    background: linear-gradient(to right,
                #ff512f,
                #f09819);
    color: #fff;
    border: none;
    padding: 10px 20px;
    font-weight: bold;
    font-size: 14px;
    border-radius: 5px;
    cursor: pointer;
}

.card button:hover {
    background: linear-gradient(to right,
                red,
                orange);
                color: black;
}

.popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.popup {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 90%;
    height: 90%;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: end;
}

@media (max-width: 768px) {
    .lost-cats {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }

    .card img {
        height: 200px;
    }

    .card h2 {
        font-size: 18px;
    }

    .card .location {
        font-size: 12px;
    }

    .card button {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    /* .lost-cats {
        grid-template-columns: 1fr;
    } */

    .card img {
        height: 180px;
    }

    .card h2 {
        font-size: 16px;
    }

    .card p {
        font-size: 10px;
    }

    .card button {
        font-size: 14px;
    }
}
