/* --- A) Style général --- */
body {
    background-color: #f2f2f2;
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 20px;
}

/* --- B) Conteneur blanc --- */
.container {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

/* --- C) Tableaux (index) --- */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

table th, table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

table th {
    background-color: #e9ecef;
    text-align: left;
}

/* --- D) Formulaires (create/edit) --- */
form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

form label {
    font-weight: bold;
}

form input[type="text"],
form input[type="number"],
form input[type="email"],
form input[type="date"],
form select {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    width: 300px;
}

form button,
form input[type="submit"] {
    background-color: #28a745;
    color: white;
    padding: 10px 15px;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
}

form button:hover,
form input[type="submit"]:hover {
    background-color: #218838;
}

/* --- E) Boutons généraux --- */
.btn {
    padding: 10px 15px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    display: inline-block;
}

/* Bouton vert */
.btn-green {
    background-color: #28a745;
    color: white;
}

.btn-green:hover {
    background-color: #218838;
}

/* Bouton gris */
.btn-back {
    background-color: #6c757d;
    color: white;
}

.btn-back:hover {
    background-color: #5a6268;
}


.btn-blue {
    background-color: #5bc0de; /* bleu pâle */
    color: white;
    padding: 8px 12px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    display: inline-block;
}

.btn-blue:hover {
    background-color: #31b0d5;
}


/**********catalogue***/
.card {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    background-color: #fff;
}

.card h2 {
    margin-top: 0;
}

.btn {
    display: inline-block;
    padding: 10px 15px;
    background-color: #0d6efd;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

.btn:hover {
    background-color: #0b5ed7;
}

/*********Voitures**/
.catalogue {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.car-card {
    width: 320px;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 15px;
    background: #fff;
    text-align: center;
}

.car-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
}

.car-card h2 {
    margin-top: 15px;
}

.car-card .btn {
    display: inline-block;
    margin-top: 10px;
}
