I have the following Codes:
html...
<div id="solidcolor">
<div class="transcolor">transcolor
<div class="notranscolor">some text</div>
</div>
</div>
css..
#solidcolor{
background: url("http://i45.tinypic.com/o5aycp.gif") repeat;
width: 200px;
height: 200px;
}
.transcolor{
background: blue;
opacity: 0.4;
height: 100px;
}
.notranscolor{
background: red; /* I want this color to solid color not transparent color*/
}
Edit note I couldn't use rgba() method to set it background-color because I have to set linear gradient color.
Edit1
I couldn't get proper solution to this even after applying absolute positioning too. But next idea I would like to do this with calc() method but it doesn't exits. Any idea?
Edit2
As @rokburgar has stated an answer, I couldn't able to solve my problem even after applying absolute position. But I wanted to set opacity equal to 1.25 I know this should be 0 to 1 but he has stated 0.4 * 1.0 = 0.4 like this 0.8 * 1.25 = 1 then why does it not work?