This syntax for a CSS background property is quite effective:
.my-element {
background:
linear-gradient(rgba(131,131,131,0.8), rgba(98,98,98,0.8)),
url('img/background.jpg')
}
However, I am not looking for a gradient effect. Instead, I want the overlay to be a single color with some transparency. While one solution could be starting and ending with the same color in a gradient, I am curious if it's possible to achieve this directly using just an RGBA color value without 'linear-gradient'. My attempts have not been successful so far.
EDIT: To clarify my question further, what I desire is:
.my-element {
background:
color(rgba(131,131,131,0.8)),
url('img/background.jpg')
}
The method above does not yield the desired outcome. Using hex notation for the color is also not feasible as it lacks opacity control.