diff options
Diffstat (limited to 'src/scss')
-rw-r--r-- | src/scss/flip-card.scss | 31 | ||||
-rw-r--r-- | src/scss/index.scss | 2 |
2 files changed, 33 insertions, 0 deletions
diff --git a/src/scss/flip-card.scss b/src/scss/flip-card.scss new file mode 100644 index 0000000..1f9af5b --- /dev/null +++ b/src/scss/flip-card.scss @@ -0,0 +1,31 @@ +.flip-card { + perspective: 1000px; +} + +.flip-card-inner { + position: relative; + width: 100%; + height: 100%; + transition: transform 0.8s; + transform-style: preserve-3d; +} + +.flip-card:hover .flip-card-inner { + transform: rotateY(180deg); +} + +.flip-card-front, .flip-card-back { + position: absolute; + width: 100%; + height: 100%; + -webkit-backface-visibility: hidden; + backface-visibility: hidden; +} + +.flip-card-front { +} + +.flip-card-back { + transform: rotateY(180deg); +} + diff --git a/src/scss/index.scss b/src/scss/index.scss index 2b9aec2..59aac49 100644 --- a/src/scss/index.scss +++ b/src/scss/index.scss @@ -122,3 +122,5 @@ $body-font-size: 1.25rem; body { background-image: url("/bg.png"); } + +@import "./flip-card.scss"; |