I am new to CSS and I need help styling a checkbox element.
When the user selects one of the checkboxes, I want the background color to change to yellow.
Thank you for any assistance you can provide!
.radio_toggle {
float:left;
}
.radio_toggle label {
float:left;
width:100px;
overflow:auto;
}
.radio_toggle label span {
text-align:center;
font-size: 15px;
padding:5px 0px;
display:block;
}
.radio_toggle label input {
position:absolute;
}
.radio_toggle .venue {
background-color:#edf1f2;
color: #58666e;
min-height: 100% !important;
border: thin #ced9db solid;
border-top-left-radius: 3px;
border-bottom-left-radius: 3px;
}
<div class="categories">
<div class="radio_toggle">
<label class="venue" style="">
<input type="checkbox" name="toggle">
<span>Category</span>
</label>
</div>
</div>
<div class="categories">
<div class="radio_toggle">
<label class="venue" style="">
<input type="checkbox" name="toggle">
<span>Category</span>
</label>
</div>
</div>
<div class="categories">
<div class="radio_toggle">
<label class="venue" style="">
<input type="checkbox" name="toggle">
<span>Category</span>
</label>
</div>
</div>