.btn{ color: #fff; background: #45ab27; font-family: 'IBM Plex Mono', monospace; font-size: 18px; font-weight: 700; text-transform: capitalize; padding: 8px 25px 7px; border: none; border-radius: 0; overflow: hidden; position: relative; z-index: 1; transition: all 0.5s ease-in-out; } .btn:focus, .btn:hover{ color: #45ab27; background: transparent; box-shadow: -7px -7px 20px 0px #fff9, -4px -4px 5px 0px #fff9, 7px 7px 20px 0px #0002, 4px 4px 5px 0px #0001; } .btn:before, .btn:after{ content: ''; background: #45ab27; position: absolute; top: 0; right: 0; height: 2px; width: 0; transition: 400ms ease all; } .btn:after{ right: auto; top: auto; left: 0; bottom: 0; } .btn:hover:before, .btn:focus:before, .btn:hover:after, .btn:focus:after{ width: 100%; transition: 800ms ease all; } @media only screen and (max-width: 767px){ .btn{ margin-bottom: 30px; } }