.slider { height: 5vh; width: 20vw; border-radius: 88px; box-shadow: 0 0 68px 8px rgba(0, 0, 0, .3); padding: 32px; display: grid; place-items: center; background: #fff; position: fixed; bottom: 0; opacity: 0; left: 50%; transform: translateX(-50%); transition: opacity 0.3s ease-out, bottom 0.3s ease-out; } .slider input { width: 100%; transform: translateY(-7px); color: #0b58ff; background: #fcc; } .slider.show { opacity: 1; bottom: 64px; }