I have a select option markup like this
<div class="styleselect">
<select onchange="setLocation(this.value)" class="selections">
<option selected="selected" value="position">Position</option>
<option value="name">Name</option>
<option value="price">Price</option>
</select>
</div>
Here I want to style the default arrow of select option and I changed my css like this
.styleselect {
background-color: #DFD3C3;
background-image: url("http://s21.postimg.org/nx05vn15f/dropdown_style.png");
background-position: 117px center;
background-repeat: no-repeat;
border: 1px solid #C5AF8A;
overflow: hidden;
vertical-align: middle;
width: 140px;
padding: 0;
margin: 0;
display: inline-block;
}
.styleselect select {
background-color: transparent;
margin: 0 0 1px;
padding: 4px;
vertical-align: middle;
width: 190px;
}
It worked fine. But again I got one problem that when I made click on the options the options came with the extra width from the actual width where it is looking really odd. I know that the extra width is coming from the width .styleselect select where I have put extra width. But that has been donefor the styling the arrow. Can someone kindly tell me how to fix the extrawidth so that the my custom arrow should come in place for default arrow in the select options and the extra width for the options will be also hide. The link for fiddle is here
Any help and suggestions will be really appreciable. Thanks