Radio Button
by piiantom
HTML
<form>
<input class="radio-btn" type="radio" id="female" name="gender" value="female">
<label for="female">Mme</label>
<input class="radio-btn" type="radio" id="male" name="gender" value="male">
<label for="male">Mr</label>
</form>
CSS
.radio-btn{
display: none;
}
.radio-btn + label {
display:inline-block;
padding: 10px;
font-family: Arial;
font-weight: bold;
text-align: center;
font-size: 15px;
border: 2px solid #999;
cursor: pointer;
vertical-align: middle;
line-height: 16px;
color: #333;
background: transparent;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
-webkit-transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
-moz-transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
-o-transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
/* Espacement et taille arbritraire. A voir comment les définir sur un layout */
min-width: 100px;
margin:2px;
}
.radio-btn:checked + label {
background-color: #999;
color: #fff;
}