styles.css

Aus Infopedia
Wechseln zu:Navigation, Suche
Zeile 17: Zeile 17:
  
 
.flip-card:hover .flip-card-inner {
 
.flip-card:hover .flip-card-inner {
   transform: rotateY(180deg);
+
   transform: rotateY(-180deg);
 
}
 
}
  
Zeile 35: Zeile 35:
 
   background-color: #2980b9;
 
   background-color: #2980b9;
 
   color: white;
 
   color: white;
   transform: rotateY(180deg);
+
   transform: rotateY(-180deg);
 
}
 
}

Version vom 3. März 2021, 22:29 Uhr

.flip-card {
  background-color: transparent;
  width: 250px;
  height: 250px;
  perspective: 1000px;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s;
  transform-style: preserve-3d;
  box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2);
}

.flip-card:hover .flip-card-inner {
  transform: rotateY(-180deg);
}

.flip-card-front, .flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
}

.flip-card-front {
  background-color: #bbb;
  color: black;
}

.flip-card-back {
  background-color: #2980b9;
  color: white;
  transform: rotateY(-180deg);
}