<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->
<!DOCTYPE html><html class=''>
<head><script src='//production-assets.codepen.io/assets/editor/live/console_runner-079c09a0e3b9ff743e39ee2d5637b9216b3545af0de366d4b9aad9dc87e26bfd.js'></script><script src='//production-assets.codepen.io/assets/editor/live/events_runner-73716630c22bbc8cff4bd0f07b135f00a0bdc5d14629260c3ec49e5606f98fdd.js'></script><script src='//production-assets.codepen.io/assets/editor/live/css_live_reload_init-2c0dc5167d60a5af3ee189d570b1835129687ea2a61bee3513dee3a50c115a77.js'></script><meta charset='UTF-8'><meta name="robots" content="noindex"><link rel="shortcut icon" type="image/x-icon" href="//production-assets.codepen.io/assets/favicon/favicon-8ea04875e70c4b0bb41da869e81236e54394d63638a1ef12fa558a4a835f1164.ico" /><link rel="mask-icon" type="" href="//production-assets.codepen.io/assets/favicon/logo-pin-f2d2b6d2c61838f7e76325261b7195c27224080bc099486ddd6dccb469b8e8e6.svg" color="#111" /><link rel="canonical" href="https://codepen.io/danny_pule/pen/vNbqxx?depth=everything&limit=all&order=popularity&page=72&q=material+&show_forks=false" />
<style class="cp-pen-styles">.card {
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
position: absolute;
top: 0;
bottom: 0;
right: 0;
left: 0;
margin: auto;
height: 300px;
width: 100%;
max-width: 300px;
}
.material-toggle {
position: absolute;
top: 0;
bottom: 0;
right: 0;
left: 0;
margin: auto;
display: block;
height: 22px;
width: 40px;
}
.material-toggle input:empty {
margin-left: -9999px;
}
.material-toggle input:empty ~ label {
position: relative;
float: left;
width: 150px;
cursor: pointer;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.material-toggle input:empty ~ label:before,
.material-toggle input:empty ~ label:after {
position: absolute;
display: block;
content: ' ';
-webkit-transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.material-toggle input:empty ~ label:before {
top: 3px;
left: 0px;
width: 32px;
height: 13px;
border-radius: 12px;
background-color: #bdbdbd;
}
input.switch:empty ~ label:after {
top: -1px;
left: -9px;
width: 1.4em;
height: 8px;
bottom: 0.1em;
margin-left: 0.1em;
background-color: #fff;
border-radius: 50%;
width: 17px;
height: 17px;
border-radius: 50%;
border: solid 2px;
border-color: #fff;
box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.14), 0 3px 3px -2px rgba(0, 0, 0, 0.2), 0 1px 8px 0 rgba(0, 0, 0, 0.12);
}
.material-toggle input:checked ~ label:before {
background-color: #1e88e5;
}
.material-toggle input:checked ~ label:after {
left: 15px;
background-color: #1565c0;
border-color: #1565c0;
}
</style></head><body>
<div class="card">
<div class="material-toggle">
<input type="checkbox" id="toggle" name="toggle" checked=true class="switch" />
<label for="toggle" class=""></label>
</div>
</div>
</body></html>