I changed from codes :before to :after This solved the problem. Is this the definitive solution?
:before
:after