Sometimes, for better look of your website, you may want your selection color match with your theme color. Here is a simple trick how you can do it.
Just add the following lines to your style.css file and you are all set.
::-moz-selection {
background-color: #000;
color: #fff;
} ::selection {
background-color: #000;
color: #fff;
}
Remember to change the color values to suite your theme.
Yes, you have to add the mozilla section, as mozilla does not understand the “selection” property.