MIgrating to New clean environment

After 9 months, home assistant upgraded my smart home to a higher level.
I started learning and experimenting till i reached to a very stable environment on my rasberry pi but recently I started facing some fatal errors and loosing access from outside outside the local network.

I would like to restart on a clean environment from the beginning building a clean environment without the hassle of interruption of my home.
How can i clone the current pi SD card to another to have it as a temp working environment by the time the new production enviornment is ready.
Is there any smooth recommendation or guidelines you recommend to replicate the configurations with the minimal efforts.
having over 80 smart devices at home will be a very time consuming job to add to home assistant and re-setup the dashboards

Honestly am not sure where to start so any advice will be appreciated

Create a snapshot on your old device, backup to your pc.
Then install home assistant on the new device and when prompted upload the snapshot.

Hello Sam,
The issue is in my current production environment its causing some issues especially when connecting it to the cloud. The purpose is having a fresh start with a clean and stable environment.
My concern in performing this restore will get the glitches to the new environment.