If your button would be an <a>
element, you could use the :visited
selector.
You are limited however, you can only change:
I haven't read this article about revisiting the :visited
but maybe some smarter people have found more ways to hack it.