How to display "You sale" function below the price on mobile

Hi, i have added the php funtion in this guide to show the you save text. But on mobile it’s not display right. please guide me how to do it.

link function: https://www.tychesoftwares.com/how-to-display-you-save-percentage-below-sale-prices-for-simple-and-variable-products-in-woocommerce/

I want to bring the price below the title on mobile, so everything will be perfect. please guide how to edit on PHP template, thanks

In this regard, please send a ticket so we can assist you.