the problem is the violin. Their iframe will have the minimum required size (at least in Firefox). Try something like
div { height: 10em; display: table-cell; vertical-align: middle; }
and put a <div> around your <select> . In a real scenario, you can use height: 100% , absolute positioning, or simply change the attributes of any tag that contains your selection.
first misconfirm your question, here is the answer for horizontal alignment
body { text-align: center; }
(or any other tag above <select> )
alternatively add the following
margin-left:auto; margin-right:auto;
but in general, it is recommended that you set some values ββfor the body to avoid differences between browsers (e.g. indentation, margins, and text alignment).
source share