It’s because the pseudo-element isn’t generated if the content
value is omitted (since the initial/default value is none
).
Specify a content
value in order to generate the pseudo-element. A value of ''
is sufficient.
.product-show .readMore.less:after {
content: '';
background: rgba(255, 255, 255, 0);
display: block;
position: absolute;
bottom: 0;
left: 0;
width: 100%;
height: 30px;
}