Untitled

mail@pastecode.io avatar
unknown
css
a month ago
3.4 kB
3
Indexable
Never
.wrap {
  width: 1920px;
  position: relative;
  margin-top: 400px;
  perspective: 1000px;
  perspective-origin: 50% 50%;
}

.leg{
  position: relative;
  width: 0px;
  height: 100px;
  border: 1px solid black;
}

.fr, .sc, .th{
  position: relative;
}

.indicator{
  top: -85px;
  left: -170px;
  position: absolute;
}

.line{
  position: absolute;
  overflow: hidden;
  height: 300px;
  /* transform: rotate(45deg); */
  
}

.text{
  position: absolute;
  top: -120px;
  width: 100px;
}

.h-line{
  width: 100px;
  border: 1px solid black;
}

.d-line{
  margin-left: 86.5px;
  margin-top: 34px;
  width: 100px;
  border: 1px solid black;
  transform: rotate(45deg);
}

.cube {
  margin: auto;
  position: relative;
  height: 200px;
  width: 200px;
  transform-style: preserve-3d;
}

.cube > div {
  position: absolute;
  box-sizing: border-box;
  padding: 10px;
  height: 100%;
  width: 100%;
  opacity: 0.9;
  background-color: #000;
  border: solid 1px #eeeeee;
  color: #ff0000;
}

.legs{
  left: -65px;
  margin-top:240px;
  position: absolute;
  display: flex;
  flex-direction: row;
  gap:70px;
}

.sc{
  margin-left: 152px;
}

.th{
  margin-top: -78px;
}

.third{
  margin-top: 78px;
}

.front {
  transform: translateZ(100px);
}
.front--1 {
  transform: translateZ(100px);
}

.back {
  transform: translateZ(-100px) rotateY(180deg);
}

.right {
  transform: rotateY(-270deg) translateX(100px);
  transform-origin: top right;
}
.right--1 {
  transform: rotateY(-270deg) translateX(100px);
  transform-origin: top right;
}

.left {
  transform: rotateY(270deg) translateX(-100px);
  transform-origin: center left;
}

.top {
  transform: rotateX(-270deg) translateY(-100px);
  transform-origin: top center;
}
.top--1 {
  transform: rotateX(-270deg) translateY(-100px);
  transform-origin: top center;
}

.bottom {
  transform: rotateX(270deg) translateY(100px);
  transform-origin: bottom center;
}
.wrap:hover .front {
  transform: translateZ(200px) translateX(-200px);
/*   margin-left: -200px;
  transition: 0.3s ease-in; */
  background-color: #fcf;
}

.wrap:hover .right {
  transform: rotateY(-270deg) translateZ(150px) translateX(150px);
}

.wrap:hover .top {
  transform: rotateX(-270deg) translateZ(120px) translateY(-100px);
}
.wrap:hover .bottom{
  transform: rotateX(270deg) translateZ(100px) translateY(100px);
}
.wrap:hover .legs{
  transform: translateY(100px);
  transition: transform 0.3s ease-in;
}

.wrap:not(:hover) .legs{
  transform: translateY(0);
  transition: transform 0.3s ease-in;
}

.wrap:hover .first{
  margin-top: 20px;
  transition: 0.3s ease-in;
}

.wrap:not(:hover) .first{
  margin-top: 0;
  transition: 0.3s ease-in;
}

.wrap:hover .second {
  margin-top: 12px;
  transition: 0.3s ease-in;
}

.wrap:not(:hover) .second {
  margin-top: 0;
  transition: 0.3s ease-in;
}

.wrap:hover .third {
  margin-top: -7px;
  transition: 0.3s ease-in;
}

.wrap:not(:hover) .third {
  margin-top:0;
  transition: 0.3s ease-in;
}

.wrap:hover .text {
  top: 5px;
  transition: 0.3s ease-in;
}

.wrap:not(:hover) .text {
  top: -120px;
  transition: 0.3s ease-in;
}

.cube > div {
  transition: transform 0.3s ease-in;
}
.cube {
  transform: rotateX(-15deg) rotateY(-25deg);
}
Leave a Comment