.Button{ .buttoncl { padding: 10px 30px; border: 2px solid var(--btnColor); border-radius: 30px; position: relative; display: flex; flex-wrap: wrap; justify-content: center; margin-top: 10px; overflow: hidden; cursor: pointer; transition: 0.5s; background: transparent; color: var(--btnTextColor); font-size: 14px; font-weight: 600; text-transform: uppercase; z-index: 9; width: fit-content; } .toptxt { position: relative; display: flex; top: 0; z-index: 2; transition: 0.3s; } .container { width: 100%; min-height: 1px; overflow: hidden; } .subtxt { position: absolute; top: 100%; z-index: 3; height: 100%; transition: 0.3s; display: flex; align-items: center; justify-content: center; } .buttoncl::before { content: ""; position: absolute; height: 50px; width: 50px; border-radius: 50%; background: var(--btnHoverColor); top: -50%; transition: 0.3s; left: 50%; transform: translateX(-50%); clip-path: circle(37% at 50% 50%); z-index: 1; opacity: 0; border: 2px solid var(--btnHoverColor); } .buttoncl:hover::before { top: -2px; opacity: 1; height: 110%; width: 110%; border-radius: 30px; clip-path: circle(100% at 50% 50%); opacity: 1; } .buttoncl:hover .toptxt { top: -100px; } .buttoncl:hover .subtxt { top: 0; color: var(--btnHoverTextColor) !important; } }.Button{ @media only screen and (max-width: 900px) { background-attachment:scroll; } }