#predictorCard{
    padding-top:40px;
}

.price-per-sqft{
    font-size:13px;
    color:var(--text-muted);
    margin-bottom:14px;
}

.ideal-bhk-hint{
    font-size:13px;
    font-weight:600;
    color:var(--blue-dark);
    background:rgba(37, 99, 235, .08);
    border-left:4px solid var(--blue);
    border-radius:8px;
    padding:10px 12px;
    margin-bottom:14px;
    text-align:left;
    display:none;
}

.form-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:18px;
    margin-bottom:6px;
}

.field{
    margin-bottom:20px;
}

.field label{
    display:flex;
    align-items:center;
    gap:6px;
    font-size:14px;
    font-weight:600;
    margin-bottom:8px;
    color:var(--text);
}

.tooltip{
    position:relative;
    cursor:help;
    color:var(--text-muted);
    font-size:13px;
}

.tooltip:hover::after{
    content:attr(data-tip);
    position:absolute;
    bottom:130%;
    left:0;
    background:#1c2430;
    color:#fff;
    font-size:12px;
    font-weight:400;
    padding:8px 10px;
    border-radius:8px;
    white-space:nowrap;
    box-shadow:0 6px 16px rgba(0,0,0,.25);
    z-index:5;
}

.area,
.location{
    width:100%;
    padding:12px 14px;
    border:1.5px solid var(--border);
    border-radius:10px;
    outline:none;
    font-size:15px;
    background:var(--bg);
    color:var(--text);
    transition:border-color .2s ease, box-shadow .2s ease;
}

.area:focus,
.location:focus{
    border-color:var(--blue);
    box-shadow:0 0 0 3px rgba(37,99,235,.15);
}

.switch-field{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
}

.switch-field input{
    display:none;
}

.switch-field label{
    padding:10px 16px;
    background:var(--bg);
    border:1.5px solid var(--border);
    border-radius:10px;
    cursor:pointer;
    transition:.2s;
    color:var(--text);
    font-weight:600;
    min-width:42px;
    text-align:center;
    margin:0;
}

.switch-field label:hover{
    border-color:var(--blue);
}

.switch-field input:checked + label{
    background:var(--blue);
    border-color:var(--blue);
    color:#fff;
}

.switch-field input:disabled + label{
    background:var(--border);
    color:var(--text-muted);
    cursor:not-allowed;
    opacity:.5;
}

/* Submit button */
.submit{
    width:100%;
    padding:15px;
    margin-top:10px;
    background:var(--blue);
    border:none;
    border-radius:12px;
    color:#fff;
    font-size:16px;
    font-weight:700;
    cursor:pointer;
    transition:transform .15s ease, background .2s ease;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:10px;
}

.submit:hover{
    background:var(--blue-dark);
    transform:scale(1.02);
}

.submit:disabled{
    opacity:.7;
    cursor:not-allowed;
    transform:none;
}

.spinner{
    width:16px;
    height:16px;
    border:2.5px solid rgba(255,255,255,.4);
    border-top-color:#fff;
    border-radius:50%;
    animation:spin .7s linear infinite;
}

@keyframes spin{
    to{ transform:rotate(360deg); }
}

/* Summary card */
.summary-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;
}

.summary-grid div{
    background:var(--bg);
    border-radius:10px;
    padding:12px 14px;
    display:flex;
    flex-direction:column;
    gap:4px;
}

.summary-grid span{
    font-size:12px;
    color:var(--text-muted);
}

.summary-grid strong{
    font-size:16px;
}

/* Result card */
.result-card{
    text-align:center;
    animation:fadeUp .5s ease;
}

.result-header{
    font-size:14px;
    color:var(--text-muted);
    font-weight:600;
    margin-bottom:6px;
    text-transform:uppercase;
    letter-spacing:.5px;
}

.price-display{
    font-size:38px;
    font-weight:800;
    color:var(--green);
    margin-bottom:6px;
}

.price-range{
    font-size:13px;
    color:var(--text-muted);
    margin-bottom:14px;
}

.category-row{
    display:flex;
    justify-content:center;
    align-items:center;
    gap:10px;
    margin-bottom:20px;
}

.category-badge{
    padding:6px 14px;
    border-radius:999px;
    font-size:13px;
    font-weight:700;
    background:rgba(37,99,235,.1);
    color:var(--blue-dark);
}

.rating-stars{
    font-size:15px;
    color:var(--amber);
}

.confidence-block{
    text-align:left;
    margin-bottom:22px;
}

.confidence-label{
    display:flex;
    justify-content:space-between;
    font-size:13px;
    font-weight:600;
    margin-bottom:6px;
}

.confidence-bar{
    width:100%;
    height:9px;
    background:var(--border);
    border-radius:999px;
    overflow:hidden;
}

.confidence-fill{
    height:100%;
    background:linear-gradient(90deg, var(--blue), var(--green));
    width:0%;
    transition:width .8s ease;
}

.chart-block{
    text-align:left;
    margin-bottom:18px;
    display:flex;
    flex-direction:column;
    gap:10px;
}

.chart-row{
    display:grid;
    grid-template-columns:80px 1fr;
    align-items:center;
    gap:10px;
    font-size:12px;
    color:var(--text-muted);
}

.chart-track{
    height:8px;
    background:var(--border);
    border-radius:999px;
    overflow:hidden;
}

.chart-fill{
    height:100%;
    width:0%;
    background:var(--blue);
    border-radius:999px;
    transition:width .8s ease;
}

.success-message{
    font-size:13px;
    font-weight:600;
    color:var(--green);
    margin-bottom:20px;
}

.advisor-block{
    text-align:left;
    background:var(--bg);
    border-radius:12px;
    padding:16px 18px;
}

.advisor-block h3{
    font-size:14px;
    margin-bottom:10px;
}

.advisor-block ul{
    list-style:none;
    display:flex;
    flex-direction:column;
    gap:6px;
    font-size:13px;
    color:var(--text-muted);
}

/* Recent estimates history */
.history-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
}

.history-header .card-title{
    margin-bottom:0;
}

.clear-btn{
    background:none;
    border:1px solid var(--border);
    color:var(--text-muted);
    font-size:12px;
    font-weight:600;
    padding:6px 12px;
    border-radius:8px;
    cursor:pointer;
    transition:.2s;
}

.clear-btn:hover{
    border-color:var(--red);
    color:var(--red);
}

.history-list{
    list-style:none;
    margin-top:16px;
    display:flex;
    flex-direction:column;
    gap:10px;
}

.history-list li{
    background:var(--bg);
    border-radius:10px;
    padding:12px 14px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    font-size:13px;
    gap:10px;
}

.history-list .history-meta{
    color:var(--text-muted);
}

.history-list .history-price{
    font-weight:700;
    color:var(--green);
    white-space:nowrap;
}

.history-empty{
    text-align:center;
    color:var(--text-muted);
    font-size:13px;
    padding:8px 0;
}

/* Error card */
.error-card{
    text-align:center;
    color:var(--red);
    font-weight:600;
    border-left:5px solid var(--red);
}

/* Responsive */
@media(max-width:640px){
    .form-grid{
        grid-template-columns:1fr;
    }
    .summary-grid{
        grid-template-columns:1fr;
    }
    .history-list li{
        flex-direction:column;
        align-items:flex-start;
    }
}
