Kerala MLA Abdul Razak dies of heart attack