/**
 * This work is licensed under the Creative Commons
 * Attribution 3.0 Unported License. To view a copy
 * of this license, visit http://creativecommons.org/licenses/by/3.0/.
 *
 * Author: Girish Sharma <scrapmachines@gmail.com>
 */

/* Demo specific styles begin */

* {margin: 0; padding: 0;}
body {	
	background: #222;
}
.loader-ring {
  top: calc(50% - 100px);
  left: 50%;
  pointer-events: none;
}
#long-tail {
  visibility: hidden;
}
.btn {
  position: absolute;
  cursor: pointer;
  min-width: 90px;
  min-height: 90px;
  line-height: 90px;
  background: #25292C;
  margin: auto auto;
  top: calc(50% - 50px);
  left: calc(50% - 50px);
  text-align: center;
  border-radius: 999px;
  color: rgba(155,155,155,1);
  text-shadow: -1px -1px 0px rgba(255,255,255,0.8), 1px 1px 2px rgba(0,0,0,1);
  font-family: sans-serif;
  box-shadow: inset 1px 1px 2px rgba(255,255,255,0.3), 
              inset 3px 15px 45px rgba(255,255,255,0.1),
              inset -1px -1px 2px rgba(0,0,0,0.5), 
              inset -3px -15px 45px rgba(0,0,0,0.2),
              1px 5px 30px -4px rgba(0,0,0,1);
  transition: 0.1s ease-out;
}

.btn:before {
  content: "";
  cursor: pointer;
  background: #1A1A1A;
  width: 120px;
  height: 120px;
  position: absolute;
  top: -15px;
  left: -15px;
  z-index: -99;
  border-radius: 999px;
  box-shadow: inset -1px -1px 2px rgba(255,255,255,0.3), 
    inset -5px -15px 40px rgba(255,255,255,0.1),
    inset 1px 1px 2px rgba(0,0,0,0.5), 
    inset 5px 15px 40px rgba(0,0,0,0.2),
    -2px -40px 50px -20px rgba(255,255,255,0.1),
    2px 35px 50px -10px rgba(0,0,0,0.4),
    0px 0px 25px 8px rgba(60,60,60,1);
}

.btn:active, input:checked + .btn {
  text-shadow: 1px 1px 0px rgba(255,255,255,0.15);
  box-shadow: inset 1px 1px 2px rgba(255,255,255,0.3), 
              inset 3px 15px 45px rgba(0,0,0,0.2),
              inset -1px -1px 2px rgba(0,0,0,0.5), 
              inset -3px -15px 45px rgba(255,255,255,0.1),
              1px 5px 10px -4px rgba(0,0,0,1);
}
a {
  font-family: arial,sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  position: fixed;
  bottom: 0;
  right: 0;
  margin: 5px;
  color: #555;
}
a:hover {
  color: #888;
}
b {
  position: absolute;
  left: 50%;
  margin-right: -50%;
  transform: translateX(-50%);
  top: calc(50% - 200px);
  color: rgba(155,155,155,1);
  font-family: sans-serif;
}
/* Demo specific styles end */

.loader-ring {
  position: absolute;
  height: 100px;
  width: 100px;
  border-radius: 0 100% 0 0;
  border: 1px solid white;
  border-width: 0px 5px 0px 0px;
  box-shadow: 5px 1px 2px -4px white, inset -4px 1px 3px -4px white;
  transform-origin: 0px 100%;
  animation: rotate 1s linear infinite;
}

.loader-ring:after {
  position: absolute;
  height: 1px;
  width: 1px;
  top: 100%;
  left: calc(100% + 2px);
  border-radius: 100%;
  border-width: 0;
  background: white;
  box-shadow: 0px 0 3px 5px white;
  content: '';
}

#long-tail:checked ~ .loader-ring:before {
  position: absolute;
  height: 200%;
  width: 200%;
  top: -1px;
  left: calc(-100% - 1px);
  border-radius: 100%;
  border: 1px solid rgba(255,255,255,.5);
  border-width: 1px 0 0;
  transform-origin: 0px 0px;
  content: '';
}

#long-tail:checked ~ .loader-ring {
  animation-duration: .8s;
}

@keyframes rotate {
  to {
    transform: rotate(360deg);
  }
}