I am having a very odd problem.
So I have a huge pile of CSS, and among many selectors within it, I have selector that looks like this, which is working just fine:
.spoilertop, #QUOTETOP, #CODETOP, .utubetop {
padding-left: 44px;
font-size:12px;
}
But then I add a selector that looks like this just above it:
.spoilermain:after, #QUOTE:after {
content: "";
position: absolute;
top: -24px;
left: 12px;
border-width: 24px 24px 0 0;
border-color: transparent #766161;
border-style: solid;
display: block;
width: 0;
}
And then the spoilertop, #QUOTETOP, #CODETOP, .utubetop { }
stops working. It doesn't give me the visual effect that it should've given.
I tested it again with different selector. I have a selector that looks like this:
#recaptcha {
background:#766161!important;
font-size:11px;
}
Then I add this above it:
.utubemain:after, #CODE:after {
content: "";
position: absolute;
top: -24px;
left: 12px;
border-width: 24px 24px 0 0;
border-color: transparent #c08f84;
border-style: solid;
display: block;
width: 0;
}
Again, the #recaptcha { }
stops working.
I have tried to remove the properties one by one, and I found that the content: "";
is the one which is causing problem. For now the solution is putting a random unused selector below the { content: ""; }
. So for example it will look like this:
.spoilermain:after, #QUOTE:after {
content: "";
position: absolute;
top: -24px;
left: 12px;
border-width: 24px 24px 0 0;
border-color: transparent #766161;
border-style: solid;
display: block;
width: 0;
}
.some-line {
border:#000;
background:#200;
}
.spoilertop, #QUOTETOP, #CODETOP, .utubetop {
padding-left: 44px;
font-size:12px;
}
But that solution is kind of troublesome if I have a lot content: "";
. And I'm really confused why is that kind of problem happening.
So... could anyone help me explain why?