div { border: none !important; width: 400px; margin: auto; background-color: #eee !important; text-indent: -9999px;}
div::before{content: 'test';color: black;}
div { border: none !important; width: 400px; margin: auto; background-color: #eee !important; text-indent: -9999px;}
div::before{content: 'test';color: black;}
The ::before and ::after attribute don't change the main tag's content, but rather they add content before or after it.