I was learning from youtube and I ended up at transition bcs of my problem with one. Any delay or duration is not workig and I don't know why. I really want to know what is a reason of executing this problem. I'm kinda of new in that stuff. :)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>::AFTER & :: BEFORE</title>
<link rel="stylesheet" href="style.css">
<script>
body {
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
font-size: 5rem;
}
p::before {
content: "";
background-color: red;
display: block;
width: 10px;
height: 10px;
transition: all ease-in-out 250ms;
}
p::after {
content: "";
background-color: red;
display: block;
width: 10px;
height: 10px;
transition-property: width;
transition-delay: 1s;
transition-duration: 2s;
}
p:hover::before,
p:hover::after {
width: auto;
}
</script>
</head>
<body>
<p>Here is some content</p>
</body>
</html>