I'm trying to make an animation in the :: before of a paragraph every time I move the mouse
But this CSS is overwriting everything that is written in the paragraph, even though Before instead of After.
p::before{
width:200px;
height:20px;
position: absolute;
content: "";
}
p:hover::before{
animation: blink 2s infinite alternate;
}
@keyframes blink {
from {
background-color: #89F0FF;
box-shadow: 0 0 10px #89F0FF;
}
to {
background-color: white;
box-shadow: 0 0 10px #89F0FF;
}
}
<p>Passe o Mouse Aqui</p>