JSFiddle - React, Tailwind, and code Playground

HTML

<div class="checkbutton">
  <input type="checkbox" value="None" id="slideThree" name="check"/>
  <label for="slideThree"></label>
</div>

CSS

/* Just to make it more clear */
body { background: black; }

/* Original: http://cssdeck.com/labs/css-checkbox-styles */
input[type=checkbox]
  {
  visibility: hidden;
  }
    /* SLIDE THREE */
.checkbutton
  {
  width: 120px;
  height: 28px;
  background: #333;
  margin: 20px auto;
  
  border-radius: 6px;
  position: relative;
  box-shadow: inset 0px 0px 2px black;
  }

.checkbutton:before
  {
  content: 'Hombre';
  float: left;
  width: 60px;
  text-align: center;
  
  /* 28 es la altura total */
  font: 12px/28px Arial, sans-serif;
  color: CornflowerBlue;
  z-index: 0;
  font-weight: bold;
  }

.checkbutton:after
  {
  content: 'Mujer';
  position: absolute;
  right: 0px;
  width: 60px;
  text-align: center;
  
  font: 12px/28px Arial, sans-serif;
  color: HotPink;
  font-weight: bold;
  }

/* Ancho del boton */
.checkbutton label
  {
  display: block;
  width: 60px;
  height: 28px;

  border-radius: 6px;
  
  /*
  -webkit-transition: all .4s ease;
  -moz-transition: all .4s ease;
  -o-transition: all .4s ease;
  -ms-transition: all .4s ease; */
  transition: all .4s ease;
  cursor: pointer;
  position: absolute;
  top: 0px;
  left: 60px;
  z-index: 1;

  box-shadow: 0px 0px 1px 0px white;
  background-color: rgba(255,255,255,0.8);
  }

.checkbutton input[type=checkbox]:checked + label
  {
  left: 0px;
  }