
.lds-spinner {
  color: official;
  display: inline-block;
  position: relative;
  width: 64px;
  height: 64px;
}
.lds-spinner div {
  transform-origin: 32px 32px;
  animation: lds-spinner 1.2s linear infinite;
}
.lds-spinner div:after {
  content: " ";
  display: block;
  position: absolute;
  top: 3px;
  left: 29px;
  width: 5px;
  height: 14px;
  border-radius: 20%;
  background: #fff;
}
.lds-spinner div:nth-child(1) {
  transform: rotate(0deg);
  animation-delay: -1.1s;
}
.lds-spinner div:nth-child(2) {
  transform: rotate(30deg);
  animation-delay: -1s;
}
.lds-spinner div:nth-child(3) {
  transform: rotate(60deg);
  animation-delay: -0.9s;
}
.lds-spinner div:nth-child(4) {
  transform: rotate(90deg);
  animation-delay: -0.8s;
}
.lds-spinner div:nth-child(5) {
  transform: rotate(120deg);
  animation-delay: -0.7s;
}
.lds-spinner div:nth-child(6) {
  transform: rotate(150deg);
  animation-delay: -0.6s;
}
.lds-spinner div:nth-child(7) {
  transform: rotate(180deg);
  animation-delay: -0.5s;
}
.lds-spinner div:nth-child(8) {
  transform: rotate(210deg);
  animation-delay: -0.4s;
}
.lds-spinner div:nth-child(9) {
  transform: rotate(240deg);
  animation-delay: -0.3s;
}
.lds-spinner div:nth-child(10) {
  transform: rotate(270deg);
  animation-delay: -0.2s;
}
.lds-spinner div:nth-child(11) {
  transform: rotate(300deg);
  animation-delay: -0.1s;
}
.lds-spinner div:nth-child(12) {
  transform: rotate(330deg);
  animation-delay: 0s;
}
@keyframes lds-spinner {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}


.lds-roller {
  display: inline-block;
  position: relative;
  width: 64px;
  height: 64px;
}
.lds-roller div {
  animation: lds-roller 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  transform-origin: 32px 32px;
}
.lds-roller div:after {
  content: " ";
  display: block;
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
  margin: -3px 0 0 -3px;
}
.lds-roller div:nth-child(1) {
  animation-delay: -0.036s;
}
.lds-roller div:nth-child(1):after {
  top: 50px;
  left: 50px;
}
.lds-roller div:nth-child(2) {
  animation-delay: -0.072s;
}
.lds-roller div:nth-child(2):after {
  top: 54px;
  left: 45px;
}
.lds-roller div:nth-child(3) {
  animation-delay: -0.108s;
}
.lds-roller div:nth-child(3):after {
  top: 57px;
  left: 39px;
}
.lds-roller div:nth-child(4) {
  animation-delay: -0.144s;
}
.lds-roller div:nth-child(4):after {
  top: 58px;
  left: 32px;
}
.lds-roller div:nth-child(5) {
  animation-delay: -0.18s;
}
.lds-roller div:nth-child(5):after {
  top: 57px;
  left: 25px;
}
.lds-roller div:nth-child(6) {
  animation-delay: -0.216s;
}
.lds-roller div:nth-child(6):after {
  top: 54px;
  left: 19px;
}
.lds-roller div:nth-child(7) {
  animation-delay: -0.252s;
}
.lds-roller div:nth-child(7):after {
  top: 50px;
  left: 14px;
}
.lds-roller div:nth-child(8) {
  animation-delay: -0.288s;
}
.lds-roller div:nth-child(8):after {
  top: 45px;
  left: 10px;
}
@keyframes lds-roller {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}


// variables
// -- colors
@red: #dd5454;
@red-dark: #f84a4a;
@blue: #82cefa;
@blue-dark: #20cceb;
@green: #8dea7b;
@green-dark: #a9ff3a;
@orange: #e88239;
@orange-dark: #dc5b00;
@pink: #ff8ed0;
@pink-dark: #ff58b9;
@purple: #aa7eff;
@purple-dark: #7a38f7;
@yellow: #dcbd00;
@yellow-dark: #ffdb00;

@default: #307bbb;
@default-bg: #cccccc;
@default-dark-bg: #777777;
@default-dark: #c6ff00;

@colors: red, blue, green, orange, pink, purple, yellow;

.percircle {
  position: relative;
  font-size: 120px;
  width: 1em;
  height: 1em;
  border-radius: 50%;
  float: left;
  margin: 0 0.1em 0.1em 0;
  background-color: @default-bg;

  // output color themes
  each(@colors, {
      &.@{value} {
        .bar,
        .fill,
        &.gt50 .fill {
          border-color: @@value;
        }

        &:hover > span {
          color: @@value;
        }

        &.dark {
          @dark-color: "@{value}-dark";

          .bar,
          .fill {
            border-color: @@dark-color;
          }

          &:hover > span {
            color: @@dark-color;
          }
        }
      }
    }
  );

  // dark mode
  &.dark {
    background-color: @default-dark-bg;

    .bar,
    .fill,
    &.gt50 .fill {
      border-color: @default-dark;
    }

    >span {
      color: @default-dark-bg;
    }

    &:after {
      background-color: #555;
    }

    &:hover>span {
      color: @default-dark;
    }
  }

  // structure
  .rect-auto,
  &.gt50 .slice {
    clip: rect(auto, auto, auto, auto);
  }

  .pie,
  .bar,
  &.gt50 .fill {
    position: absolute;
    border: 0.08em solid @default;
    width: 0.84em;
    height: 0.84em;
    clip: rect(0, 0.5em, 1em, 0);
    border-radius: 50%;
    transform: rotate(0deg);
  }

  .bar {
    backface-visibility: hidden;
  }

  .pie-fill,
  &.gt50 .bar:after,
  &.gt50 .fill {
    transform: rotate(180deg);
  }

  *,
  *:before,
  *:after {
    box-sizing: content-box;
  }

  .center {
    float: none;
    margin: 0 auto;
  }

  // sizes
  &.big {
    font-size: 240px;
  }

  &.small {
    font-size: 80px;
  }

  >span {
    position: absolute;
    z-index: 1;
    width: 100%;
    top: 50%;
    top: calc(50% - 0.1em);
    transform: translateY(-50%);
    height: 1em;
    font-size: 0.2em;
    color: @default-bg;
    display: block;
    text-align: center;
    white-space: nowrap;
  }

  .perclock>span {
    font-size: 0.175em;
  }

  &:after {
    position: absolute;
    top: 0.08em;
    left: 0.08em;
    display: block;
    content: " ";
    border-radius: 50%;
    background-color: #f5f5f5;
    width: 0.84em;
    height: 0.84em;
  }

  .slice {
    position: absolute;
    width: 1em;
    height: 1em;
    clip: rect(0, 1em, 1em, 0.5em);
  }

  &:hover {
    cursor: default;

    >span {
      transform: scale(1.3) translateY(-50%);
      color: @default;
    }

    &:after {
      transform: scale(1.1);
    }
  }

  // animation
  &.animate {
    >span,
    &:after {
      transition: transform 0.2s ease-in-out;
    }
    .bar {
      transition: transform 0.6s ease-in-out;
    }
  }
}