|
@import "compass"; |
|
body,html { height: 100%; } |
|
$cube-size: 3.1em; |
|
.br { |
|
position: relative; |
|
height: 100%; |
|
width: 100%; |
|
|
|
background-color: red; |
|
color: white; |
|
font-family: Bowlby One Sc, sans-serif; |
|
font-size: 50px; |
|
line-height: 1em; |
|
text-align:justify; |
|
perspective: $cube-size*2; |
|
} |
|
.br-cube { |
|
position: absolute; |
|
top: 0; right: 0; bottom: 0; left: 0; |
|
margin: auto; |
|
height: $cube-size; |
|
width: $cube-size; |
|
border: 1px solid purple; |
|
transform-style: preserve-3d; |
|
transform: rotateY(45deg) rotateX(0); |
|
animation: datspintho 2.5s .5s ease-in-out infinite; |
|
} |
|
.br-cube-face { |
|
position: absolute; |
|
top: 0; bottom: 0; |
|
margin: auto; |
|
height: 33.33333333%; |
|
width: 100%; |
|
background-color: red; |
|
-webkit-backface-visibility: hidden; |
|
backface-visibility: hidden; |
|
} |
|
.br-cube-face-full { height: 100%; } |
|
|
|
|
|
.br-cube-t { transform: rotateX(90deg) translateZ($cube-size/2); } |
|
.br-cube-tf { transform: translateY(-$cube-size/3) translateZ($cube-size/2); } |
|
.br-cube-tr { transform: translateY(-$cube-size/3)rotateY(90deg) translateZ($cube-size/2); } |
|
.br-cube-tl { transform: translateY(-$cube-size/3)rotateY(-90deg) translateZ($cube-size/2); } |
|
.br-cube-tb { transform: translateY(-$cube-size/3) translateZ(-$cube-size/2) rotateY(180deg); } |
|
|
|
|
|
.br-cube-mf { transform: rotateY(10deg) translateZ($cube-size/2); } |
|
.br-cube-mr { transform: rotateY(100deg) translateZ($cube-size/2); } |
|
.br-cube-ml { transform: rotateY(-80deg) translateZ($cube-size/2); } |
|
.br-cube-mb { transform: translateZ(-$cube-size/2) rotateY(190deg); } |
|
|
|
|
|
.br-cube-d { transform: rotateY(-10deg) rotateX(-90deg) translateZ($cube-size/2); } |
|
.br-cube-df { transform: rotateY(-10deg) translateY($cube-size/3) translateZ($cube-size/2); } |
|
.br-cube-dr { transform: rotateY(-10deg) translateY($cube-size/3) rotateY(90deg) translateZ($cube-size/2); } |
|
.br-cube-dl { transform: rotateY(-10deg) translateY($cube-size/3) rotateY(-90deg) translateZ($cube-size/2); } |
|
.br-cube-db { transform: rotateY(-10deg) translateY($cube-size/3) translateZ(-$cube-size/2) rotateY(180deg); } |
|
|
|
.text-right { text-align: right; } |
|
|
|
@keyframes datspintho { |
|
60% { transform: rotateY(405deg) rotateX(-360deg); } |
|
61% { transform: rotateY(405deg) rotateX(-360deg); } |
|
100% { transform: rotateY(405deg) rotateX(-360deg); } |
|
} |