Styling select
and option
tag is very limited.
This is because the way they are displayed may change according to the browser/the OS. Think about what happens when you click a select tag on your phone. You don't get a dropdown list as expected on a desktop browser. So you couldnt style something universal as it doesn't natively display the save everywhere.
Styling possibilities are: mainly on the select
tag but very restricted on the option
. You could for example disable the native style of the select box:
select {
appearance: none;
/* may need vendors prefixes. */
}
Other solution is: jQuery plugins that simulate select box using other HTML tags: