/* Global Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
}

header {
    background-color: #333;
    color: #fff;
    padding: 10px 0;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo-container {
    font-size: 1.5em;
}

.site-name {
    font-weight: bold;
}

.search-form {
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.search-form label {
    display: block;
    margin: 10px 0 5px;
}

/* Styles mis à jour pour l'alignement des champs et des annonces */
        .search-form form {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap; /* Empêche le retour à la ligne */
}

.search-form .form-group {
    flex: 1; /* Prend un espace proportionnel dans la ligne */
}

.search-form select,
.search-form input {
    width: auto; /* Adapte la largeur des champs */
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.search-form button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 6px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    width: auto; /* Ajuste automatiquement la largeur du bouton */
}

        .search-form button:hover {
            background-color: #0056b3;
        }

        .search-results {
            max-width: 800px;
            margin: 20px auto;
            padding: 20px;
            background: #fff;
            border-radius: 8px;
            box-shadow: 0 4px 8px rgba(0,0,0,0.1);
        }

        .search-results h2 {
            margin-top: 0;
            text-align: center;
        }

        .results-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 20px;
            margin-top: 20px;
        }

        .result-item {
            border: 1px solid #ddd;
            border-radius: 8px;
            padding: 15px;
            box-shadow: 0 4px 8px rgba(0,0,0,0.1);
            text-align: center;
            background-color: #f9f9f9;
        }

        .result-item h3 {
            font-weight: bold;
            margin: 0;
            text-decoration: none;
        }

        .result-item p {
            margin: 5px 0;
            font-size: 14px;
            text-decoration: none;
        }

        .result-item .price {
            font-weight: bold;
            font-size: 16px;
        }

        .result-item img {
            max-width: 100%;
            border-radius: 8px;
            margin-bottom: 10px;
        }

        .details-button {
            background-color: #007bff;
            color: white;
            border: none;
            padding: 6px 8px;
            border-radius: 4px;
            cursor: pointer;
            font-size: 14px;
            margin-top: 10px;
            display: inline-block;
            text-decoration: none;
        }

        .details-button:hover {
            background-color: #0056b3;
        }
/* Style pour le modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 300px;
    text-align: center;
    border-radius: 10px;
}

.modal-content .button {
    display: inline-block;
    margin: 10px;
    padding: 10px 15px;
    background-color: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

.modal-content .button:hover {
    background-color: #0056b3;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

