<div class="pie-wrap">
		<div class="slice1 slice-wrap"> </div>
		<div class="slice2 slice-wrap"> </div>
  <b>50%</b>
</div>




/* based on http://www.kylejlarson.com/blog/2011/how-to-create-pie-charts-with-css3/ */

.pie-wrap {
  height: 100px;
  position: relative;
  margin: 20px
}

.pie-wrap:before {
  content: "";
  display: block;
  background-color: #e4dac2;
  position: absolute;
  border-radius: 50%;
  width: 100px;
  height: 100px;
  top: 0;
  left: 0;
}

.slice-wrap:before {
  content: " ";
  position: absolute;
  width: 100px;
  height: 100px;
  border-radius: 50px;
  clip: rect(0px, 50px, 100px, 0px);
  background-color: #968763;
  -webkit-transform: rotate(10deg);
  -moz-transform: rotate(10deg);
  -o-transform: rotate(10deg);
  -ms-transform: rotate(10deg);
  transform: rotate(10deg);
}

.slice-wrap {
  position: absolute;
  width: 100px;
  height: 100px;
  border-radius: 50px;
  clip: rect(0px, 100px, 100px, 50px);
}

.slice2.slice-wrap {
  -webkit-transform: rotate(180deg);
  -moz-transform: rotate(180deg);
  -o-transform: rotate(180deg);
  -ms-transform: rotate(180deg);
  transform: rotate(180deg);
}

.slice1:before {
  -webkit-animation: 2s spin linear forwards;
  -moz-animation: 2s spin linear forwards;
  -o-animation: 2s spin linear forwards;
  -ms-animation: 2s spin linear forwards;
  animation: 2s spin linear forwards;
}

.slice2:before {
  -webkit-transform: rotate(0.00001deg);
  /* webkit seems buggy with zero*/
  -moz-transform: rotate(0.00001deg);
  -o-transform: rotate(0.00001deg);
  -ms-transform: rotate(0.00001deg);
  transform: rotate(0.00001deg);
  -webkit-animation: 2s spin2 linear 2s forwards;
  -moz-animation: 2s spin2 linear 2s forwards;
  -ms-animation: 2s spin2 linear 2s forwards;
  -o-animation: 2s spin2 linear 2s forwards;
  animation: 2s spin2 linear 2s forwards;
}

.pie-wrap:after {
  /* remove this if you want pie shape to show*/
  content: " ";
  width: 80px;
  height: 80px;
  background: #fde3a7;
  position: absolute;
  top: 10px;
  left: 10px;
  border-radius: 50%;
  z-index: 2;
}

@-webkit-keyframes spin {
  from {
    -webkit-transform: rotate(10deg);
  }
  to {
    -webkit-transform: rotate(180deg);
  }
}

@-moz-keyframes spin {
  from {
    -moz-transform: rotate(10deg);
  }
  to {
    -moz-transform: rotate(180deg);
  }
}

@-ms-keyframes spin {
  from {
    -ms-transform: rotate(10deg);
  }
  to {
    -ms-transform: rotate(180deg);
  }
}

@-o-keyframes spin {
  from {
    -o-transform: rotate(10deg);
  }
  to {
    -o-transform: rotate(180deg);
  }
}

@keyframes spin {
  from {
    transform: rotate(10deg);
  }
  to {
    transform: rotate(180deg);
  }
}

.pie-wrap b {
  font-size: 130%;
  display: block;
  width: 100px;
  height: 100px;
  line-height: 100px;
  text-align: center;
  position: relative;
  z-index: 4
}
Run Pen

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.