debugged and restyled