Implemented below mentioned changes :

1. Used object oriented approach.
2. On click of product name, changed the header selection only if there is
a radio button already selected.