Is this possible? I want selected text to have a solid background, not a transparent background. opacity: 1
does not do it because there must be a standard override from the browser (or something like that).
::-moz-selection {
background: #fff;
color: #000;
}
::selection {
background: #fff;
color: #000;
}
body {
color: #fff;
font-family: sans-serif;
line-height: 2em;
}
div {
padding: 2em;
background: #F8372A;
text-align: center;
}
<div>
<h1>HEY!</h1>
<p>why is my background not<br/><strong>STARK WHITE</strong><br/>when selected?</p>
</div>