#212121
1.button { 2 width: 90px; 3 height: 90px; 4 border-radius: 15px; 5 -webkit-backdrop-filter: blur(10px); 6 backdrop-filter: blur(10px); 7 background-color: rgba(255, 255, 255, 0.1); 8 border: 0px; 9 cursor: pointer; 10 outline: 0px; 11 padding: 0 2px; 12 font-weight: 600; 13 font-size: 18px; 14 color: white; 15 box-shadow: rgba(0, 0, 0, 0.3) 0px 19px 38px, rgba(0, 0, 0, 0.22) 0px 15px 12px; 16} 17 18.backdrop { 19 position: absolute; 20 width: 80px; 21 height: 80px; 22 background-color: rgb(36, 33, 228); 23 z-index: -1; 24 top: 50%; 25 left: 50%; 26 border-radius: 15px; 27 transform: translateX(-50%) translateY(-50%); 28 transition: all ease-in-out 0.5s; 29} 30 31.button:hover + .backdrop { 32 top: 48%; 33 box-shadow: rgba(0, 0, 0, 0.3) 0px 19px 38px, rgba(0, 0, 0, 0.22) 0px 15px 12px; 34 transform: rotate(15deg) translateX(-50%) translateY(-50%); 35} 36 37.button:active,.button:active +.backdrop { 38 box-shadow: none; 39}
2.9K views
2.9K views
Comments
Variations
1 MIT License