Previously, I have added hover and transition styles to the box. Well, then I thought of trying to add a button which when clicked would be the same as on hover without hovering the pointer over the box.
Since there are no examples of your code, I will just give basic example.
You will need to create a function, something like this
var element = document.getElementById("IdOfYourElement").style.color;
function changeColor(){
element = "blue"; // example
}
And then, just call the function on your button, by adding
onClick = "changeColor()"