/* Style pour le formulaire */
#calculateur-form {
    font-family: Arial, sans-serif;
    margin: 20px auto; /* Centre le formulaire horizontalement */
    max-width: 800px; /* Limite la largeur maximale du formulaire si nécessaire */
}

/* Style pour les étiquettes et les champs du formulaire */
#calculateur-form label {
    display: block;
    margin: 10px 0 5px;
}

#calculateur-form input[type="number"],
#calculateur-form input[type="text"] {
    width: 100%;
    padding: 6px;
    box-sizing: border-box;
    margin-bottom: 10px;
}

/* Style pour les tableaux de charges déductibles et non déductibles */
#charges-deductibles-table,
#charges-non-deductibles-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

#charges-deductibles-table th,
#charges-non-deductibles-table th,
#charges-deductibles-table td,
#charges-non-deductibles-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
}

#charges-deductibles-table tfoot,
#charges-non-deductibles-table tfoot {
    font-weight: bold;
}

/* Style pour les boutons */
#calculateur-form button {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 10px 0;
    cursor: pointer;
}

#calculateur-form button:hover {
    background-color: #45a049;
}

/* Style pour le titre et le tableau historique */
#historique {
    text-align: center; /* Centre le texte à l'intérieur du conteneur */
    margin: 20px auto; /* Espace au-dessus et centrer horizontalement */
    max-width: 1000px; /* Limite la largeur maximale du conteneur */
}

#historique h2 {
    font-size: 24px; /* Taille de la police du titre */
    margin-bottom: 20px; /* Espace entre le titre et le tableau */
}

/* Style pour le tableau historique */
#historique-table {
    width: 80%; /* Ajuste la largeur pour éviter que le tableau soit trop large */
    max-width: 100%; /* Assure que le tableau ne dépasse pas la largeur du conteneur */
    border-collapse: collapse;
    margin: 0 auto; /* Centre le tableau horizontalement */
	margin-left: -320px; /* Décale le tableau à gauche de 20 pixels */
}

#historique-table th,
#historique-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}

#historique-table th {
    background-color: #214165;
}

/* Style général pour les tableaux */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

th,
td {
    border: 1px solid #ddd;
    padding: 8px;
}

th {
    background-color: #f2f2f2;
    text-align: left;
}

/* Conteneur principal pour le formulaire */
#historique_coffre_container {
    max-width: 600px;
    margin: 0 auto 20px; /* Centré avec un espace en dessous pour le tableau */
    padding: 20px;
    border: 1px solid #ccc;
    background-color: #333333;
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Titre du formulaire */
#historique_coffre_container h2 {
    color: #ffffff;
    margin-bottom: 20px;
    text-align: center;
}

/* Conteneur du formulaire pour éviter l'étalement */
#historique_coffre form {
    width: 100%;
}

/* Style des champs du formulaire */
#historique_coffre label {
    display: block;
    margin: 10px 0 5px;
}

#historique_coffre input[type="text"],
#historique_coffre input[type="number"] {
    width: 100%;
    padding: 8px;
    margin: 5px 0 10px;
    border: 1px solid #ccc;
    background-color: #444444;
    color: #ffffff;
}

/* Style du bouton de soumission */
#historique_coffre input[type="submit"] {
    width: auto;
    background-color: #154782;
    color: white;
    padding: 10px 20px;
    border: none;
    cursor: pointer;
    margin-top: 15px;
}

#historique_coffre input[type="submit"]:hover {
    background-color: #0056b3;
}

/* Style du tableau d'historique */
#historique_coffre_table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

#historique_coffre_table th,
#historique_coffre_table td {
    border: 1px solid #ccc;
    padding: 8px;
    text-align: center;
    background-color: #333333;
    color: #ffffff;
}

#historique_coffre_table th {
    background-color: #154782;
    color: white;
}

/* Responsive */
@media (max-width: 600px) {
    #historique_coffre_container {
        padding: 10px;
    }

    #historique_coffre input[type="submit"] {
        width: 100%;
    }
}
#calculateur-form fieldset {
	background: #2a2c2c;
}

#coffreVariationChart, 
#coffreMontantChart {
    width: 100% !important;
    height: calc(100% - 30px) !important;
}

@media (max-width: 768px) {
    .coffre-charts-container {
        flex-direction: column;
    }
    
    .coffre-chart-container {
        min-width: 100%;
    }
}