change badge colors after form is submitted