@import url("https://fonts.googleapis.com/css?family=Roboto:100,600");
body {
  width: 100vw;
  height: 100vh;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: center;
      -ms-flex-pack: center;
          justify-content: center;
  -webkit-box-align: center;
      -ms-flex-align: center;
          align-items: center;
  background: #333;
  -webkit-transition: 0.4s;
  transition: 0.4s;
  font-family: "Roboto", sans-serif;
  font-weight: 100;
}

.clock {
  margin: auto;
  position: relative;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-flow: column wrap;
      flex-flow: column wrap;
  width: 100%;
  min-width: 300px;
  max-width: 300px;
  height: 100px;
}

.block {
  width: calc(100% / 13);
  height: 20%;
  color: #474747;
  -webkit-transition: 0.4s;
  transition: 0.4s;
}
.block:not(:nth-child(n + 16)):nth-child(n + 11), .block:not(:nth-child(n + 46)):nth-child(n + 41) {
  margin-right: 10px;
}
.block:not(:nth-child(n + 31)):nth-child(n + 26) {
  margin-right: 20px;
}
.block:before {
  content: attr(data-num);
  position: relative;
  display: block;
  font-size: 16px;
  width: 100%;
  height: 100%;
  line-height: 20px;
  text-align: center;
}
.block:nth-child(-n + 10):before {
  content: "0" attr(data-num);
}
.block.active:before {
  color: whitesmoke;
  font-weight: 500;
}

.block.second {
  background: #333;
}

.block.second:before {
  color: #FF8300;
}

.divider {
  position: absolute;
  width: 2px;
  
  height: 60%;
  top: 20%;
  left: calc(50% + 7px);
  background: #868282;
}

body.dark-theme {
  background: #333;
  color: #d0cbcb;
}
body.dark-theme .block {
  color: #474747;
}
body.dark-theme .block.active:before {
  color: whitesmoke;
}
body.dark-theme .block.second {
  background: #333;
}
body.dark-theme .block.second:before {
  color: #FF8300;
}
body.dark-theme .divider {
  background: #ccc;
}


body.light-theme {
  background: #f2f4f8;
  color: #000;
}
body.light-theme .block {
  color: #d0cbcb;
}
body.light-theme .block.active:before {
  color: #000;
}
body.light-theme .block.second {
  background: #a2a2a2;
}
body.light-theme .block.second:before {
  color: #7d7d7d;
}
body.light-theme .divider {
  background: #333;
}

.switch-theme {
  position: absolute;
  bottom: 40px;
  right: 40px;
  color: grey;
}

.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
  margin-left: 30px;
}
.switch input {
  display: none;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #333;
  -webkit-transition: 0.4s;
  transition: 0.4s;
  border-radius: 34px;
}
.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  -webkit-transition: 0.4s;
  transition: 0.4s;
  border-radius: 50%;
  -webkit-transform: translateX(26px);
          transform: translateX(26px);  
}

input:checked + .slider {
  background-color: #ccc;
}

input:focus + .slider {
  box-shadow: 0 0 1px #2196F3;
}

input:checked + .slider:before {
  -webkit-transform: translateX(0px);
          transform: translateX(0px);
}
