/* CSS optimisé pour 3 colonnes */
.facture-container {
    max-width: 1000px;
    margin: 20px auto;
    padding: 25px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.facture-container h1 {
    text-align: center;
    color: #2e7d32;
    margin-bottom: 25px;
    font-size: 1.8em;
}

fieldset {
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 20px;
    margin-bottom: 25px;
}

legend {
    font-weight: 600;
    color: #2e7d32;
    padding: 0 5px;
    font-size: 1.1em;
    margin-bottom: 15px;
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 15px;
    gap: 20px;
}

.form-group {
    flex: 1;
    min-width: 250px;
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    flex: 1 0 100%;
}

.form-group label {
    font-size: 0.9em;
    margin-bottom: 5px;
    font-weight: 500;
    color: #444;
}

.form-group input,
.form-group select {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.95em;
    background: #fafafa;
}

.form-group input:required,
.form-group select:required {
    border-left: 2px solid #ff9800;
}

.option-row {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
}

.option-row select {
    flex: 2;
    padding: 8px;
}

.option-row input[type="number"] {
    flex: 1;
    padding: 8px;
}

button.remove_option {
    background: #ff5252;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
}

button.add-option {
    background: #4caf50;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    margin-top: 10px;
}

.alert-compact {
    background: #e3f2fd;
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 15px;
    text-align: center;
}

.alert-compact button {
    background: #4caf50;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    margin-top: 10px;
    cursor: pointer;
}

.btn-submit {
    display: block;
    background: #2e7d32;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 4px;
    font-size: 1em;
    cursor: pointer;
    margin: 25px auto 0;
    width: 100%;
    max-width: 200px;
}

.btn-submit:hover {
    background: #1b5e20;
}

.payment-section {
    margin-top: 15px;
    padding: 15px;
    background: #f5f5f5;
    border-radius: 4px;
    display: none;
}

.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 10px;
}

.checkbox-item {
    display: flex;
    align-items: center;
}

.checkbox-item input {
    margin-right: 6px;
}

#locataire_existant_section, #locataire_nouveau_section {
    margin-top: 10px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

@media (max-width: 992px) {
    .form-group {
        min-width: 200px;
    }
}

@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
    }

    .form-group {
        width: 100%;
    }

    .option-row {
        flex-direction: column;
        align-items: stretch;
    }
}