User:Pax/secret.css: Difference between revisions

From From Dusk till Jawn
Jump to navigation Jump to search
No edit summary
No edit summary
 
(33 intermediate revisions by the same user not shown)
Line 1: Line 1:
body {
.container {
   display: flex;
   position: relative;
   justify-content: center;
   display: inline-block;  
   align-items: center;
   border-radius: 2em 2em 2em 2em;
  height: 100vh;
  background: black;
}
}


.scene {
.container2 {
   width: 1000px;
   position: relative;
   display: flex;
   display: inline-block;  
   justify-content: space-between;
   border-radius: 2em 2em 2em 2em;
  perspective: 800px;
}


  .card {
.image {
    position: relative;
  display: block;
    width: 240px;
  width: 100%;
    height: 300px;
  height: auto;
    color: white;
  border-radius: 2em 2em 2em 2em;
    cursor: pointer;
}
    transition: 1s ease-in-out;
    transform-style: preserve-3d;


    &:hover {
.overlay {
      transform: rotateY(0.5turn);
  position: absolute;
    }
  border-radius: 2em 2em 2em 2em;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  width: 100%;
  opacity: 1;
  transition: .5s ease;
  background-color: #140E0A;
}


    .card__face {
.overlay2 {
      position: absolute;
  position: absolute;
      top: 0;
  border-radius: 2em 2em 2em 2em;
      left: 0;
  top: 0;
      width: 100%;
  bottom: 0;
      height: 100%;
  left: 0;
      backface-visibility: hidden;
  right: 0;
      transition: 1s ease-in-out;
  height: 100%;
      -webkit-box-reflect: below 0
  width: 100%;
        linear-gradient(transparent, transparent, rgba(0, 0, 0, 0.4));
  opacity: 0;
  transition: .5s ease;
  background-color: #140E0A;
}


      img {
.container:hover .overlay {
        width: 240px;
  opacity: 0;
        height: 300px;
  border-radius:2em 2em 2em 2em;
        object-fit: cover;
}
      }
 
.container2:hover .overlay2 {
  opacity: 1;
  border-radius:2em 2em 2em 2em;
}


      &--back {
.text {
        transform: rotateY(0.5turn);
  color: white;
      }
  font-size: 12pt;
    }
  position: absolute;
   }
  font-family: Josefin Sans;
  top: 50%;
  left: 50%;
  -webkit-transform: translate(-50%, -50%);
  -ms-transform: translate(-50%, -50%);
  transform: translate(-50%, -50%);
   text-align: center;
}
}

Latest revision as of 09:15, 18 January 2021

.container {
  position: relative;
  display: inline-block; 
  border-radius: 2em 2em 2em 2em;
}

.container2 {
  position: relative;
  display: inline-block; 
  border-radius: 2em 2em 2em 2em;
}

.image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 2em 2em 2em 2em;
}

.overlay {
  position: absolute;
  border-radius: 2em 2em 2em 2em;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  width: 100%;
  opacity: 1;
  transition: .5s ease;
  background-color: #140E0A;
}

.overlay2 {
  position: absolute;
  border-radius: 2em 2em 2em 2em;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  width: 100%;
  opacity: 0;
  transition: .5s ease;
  background-color: #140E0A;
}

.container:hover .overlay {
  opacity: 0;
  border-radius:2em 2em 2em 2em;
}

.container2:hover .overlay2 {
  opacity: 1;
  border-radius:2em 2em 2em 2em;
}

.text {
  color: white;
  font-size: 12pt;
  position: absolute;
  font-family: Josefin Sans;
  top: 50%;
  left: 50%;
  -webkit-transform: translate(-50%, -50%);
  -ms-transform: translate(-50%, -50%);
  transform: translate(-50%, -50%);
  text-align: center;
}