Entity badge color

I am working on a picture element card. In it I have several entity badges for door locks, covers, etc. My eyesight is pretty bad so I would like the badge to show red when locked or closed and green when opened or unlocked. Is this possible? Thanks in advance.