Hi Kumara,
Unfortunately, you can’t do it w/ the template tags.
But in context of what your goal is, you won’t need it anyway.
You can always use the href links of the taxonomy terms as an attribute selector.
https://www.w3schools.com/css/css_attribute_selectors.asp
Say, for example you have a taxonomy animals and term cats and the term link has something like www.yoururl.com/animals/cats/
You can go with:
.page-hero a[href$="/animals/cats/"]:before {
//your pseudo element styling here
}