Input_number brightness slider

I have created an input_number slider for my living room lights to control the brightness:

HA

What I would like to do is have the icon for the slider change color based on the brightness, just as it does with the 2 lamp icons below it (these are Hue bulbs). Is there a way to do this? Thanks.

With an icon_template you can change the icon, not sure you can change the colour. That would need a theme but not sure you can change it this way…