how to dynamically change text color based on a background color css code example
Example 1: set background color dynamically javascript
document.body.style.backgroundColor="white"
Example 2: changong text color css
color: #EAF6F6;
color: red;
color: rgb(255, 255, 255);