/* =========================================================
   Mensualité crédit immo
   ========================================================= */

/* --- Layout global --- */
.afr-mensualites-immo {
    padding: 30px;
    border-radius: 15px;
    font-family: 'Raleway', sans-serif;
}

/* --- Disposition en colonnes --- */
.afr-mensualites-immo .afr-row{
    display: flex;
    align-items: center;
    gap: 70px;
    flex-wrap: wrap;
}

.afr-mensualites-immo .afr-col {
    flex: 1;
    min-width: 280px;
}

/* --- Champs et labels --- */
.afr-mensualites-immo .afr-field {
    margin-bottom: 24px;
}

.afr-mensualites-immo .afr-field label {
    font-size: 20px;
    font-weight: bold;
    color: #213559;
    display: block;
}

.afr-mensualites-immo .afr-field .text-muted {
    font-size: 13px;
}

/* --- Inputs avec unité --- */
.afr-input-wrapper {
    position: relative;
    width: 190px;
}

.afr-input-wrapper.ans input {
    padding-right: 55px; /* pour 'ans' */
}

.afr-input-wrapper input {
    width: 100%;
    padding: 10px 34px 10px 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1.6rem;
    text-align: right;
    background: #f7f9fc;
    transition: border-color 0.2s ease;
}

.afr-input-wrapper input:focus {
    border-color: #324269;
    outline: none;
}

.afr-input-wrapper .afr-unit {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    font-weight: 700;
    font-size: 1.6rem;
    color: #555;
}

/* --- Sliders --- */
.afr-mensualites-immo input[type="range"] {
    -webkit-appearance: none;
    width: 100%;
    height: 10px;
    background: linear-gradient(to right, #324269 0%, #d8dde5 0%);
    border-radius: 5px;
    outline: none;
    margin-top: 8px;
}

.afr-mensualites-immo input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: #324269;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 0 3px rgba(0, 0, 0, 0.2);
}

.afr-mensualites-immo input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #324269;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 0 3px rgba(0, 0, 0, 0.2);
}


/* --- Résultats --- */
.afr-result {
    background: #f7f9fc;
    border: 1px solid #e3e6ee;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
}

.afr-result-main {
    font-size: 40px;
    font-weight: 800;
    color: #324269;
    margin-bottom :10px
}

.afr-result-sub {
    color: #666;
    font-size: 18px;
    line-height: 25px;
}

.afr-btn {
    display: inline-block;
    background: #324269;
    color: white;
    padding: 12px 25px;
    border-radius: 8px;
    margin-top: 10px;
    font-weight: bold;
    text-decoration: none;
    transition: background 0.2s;
}

.afr-btn:hover {
    background: #273657;
}

/* --- Graphique --- */
.afr-chart-container {
    margin-top: 30px;
    height: 400px;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .afr-mensualites-immo .afr-row{
        flex-direction: column;
    }

    .afr-input-wrapper {
        width: 100%;
    }
}