Мне удалось просмотреть код с помощью инспектора Mozilla и успешно проверить проблему.Проблема заключалась в том, что у вас установлено свойство color
, равное inherit
, поэтому оно будет того же цвета, что и фон.Это просто делает его невидимым.Вместо этого установите для свойства видимый цвет, отличный от того же цвета.Попробуйте этот фрагмент.
.form-control {
background: none;
border-radius: 0;
border: 1px solid #fff;
font-size: 18px;
text-transform: uppercase;
font-family: 'PT Sans Narrow', sans-serif;
height: 44px;
letter-spacing: 1px;
padding: 26px 10px 26px 15px;
color: black !important; /* Set the text color to be black, not inherited to the background */
}
.form-control {
display: block;
width: 100%;
height: 34px;
padding: 6px 12px;
font-size: 14px;
line-height: 1.42857143;
color: black;
background-color: #fff;
background-image: none;
border: 1px solid #ccc;
border-radius: 4px;
-webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.075);
box-shadow: inset 0 1px 1px rgba(0,0,0,.075);
-webkit-transition: border-color ease-in-out .15s,-webkit-box-shadow ease-in-out .15s;
-o-transition: border-color ease-in-out .15s,box-shadow ease-in-out .15s;
transition: border-color ease-in-out .15s,box-shadow ease-in-out .15s;
}
button, input, select, textarea {
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
button, select {
text-transform: none;
}
option {
margin: 0;
font: inherit;
font-size: inherit;
line-height: inherit;
font-family: inherit;
font-size: inherit;
line-height: inherit;
font-family: inherit;
font-color: black; /* Set the text color to be black, not inherited to the background */
}
* {
-webkit-box-sizing: border-box;
box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
body {
font-size: 16px;
font-family: 'PT Sans', sans-serif;
color: #414141;
}
html {
font-size: 10px;
}
html {
font-family: sans-serif;
-webkit-text-size-adjust: 100%
;
}
/* Change the background of all choices */
option {
background-color: blue;
color: gray; /* This is the color of text */
}
#Responsive {
background-color: lightblue;
}
<h2> You could change the background/color of all options. </h2>
<select id="form_service" name="service" class="form-control" title="Please Select Your Service" required="" data-error="Select Your Service.">
<option disabled="">Choose Your Require Service</option>
<option value="Responsive Website Desin">Responsive Website Design</option>
<option value="Wordpress Website Design">Wordpress Website Design</option>
<option value="Only Template/PSD Design">Only Template/PSD Design</option>
<option value="PSD to HTML">PSD to HTML</option>
<option value="PSD to Wordpress">PSD to Wordpress</option>
<option>Banner Design</option>
</select>
<h2> You could change the background/color of a specific option. </h2>
<select id="form_service" name="service" class="form-control" title="Please Select Your Service" required="" data-error="Select Your Service.">
<option disabled="">Choose Your Require Service</option>
<option id="Responsive">Responsive Website Design</option>
<option>Wordpress Website Design</option>
<option>Only Template/PSD Design</option>
<option>PSD to HTML</option>
<option>PSD to Wordpress</option>
<option>Banner Design</option>
</select>