You got into an accident, but you didn't cause it. The blame fell squarely on the other driver. Even so, your anxiety goes through the roof any time you're even near a road. You refuse to drive. Just the thought of it threatens to bring on a panic attack.
There are many ways to treat these symptoms, such as therapy and medication. One option that many people overlook, though, is simply enrolling in a driving course.
You don't need the course because you're not a good driver. However, it can help you out because it forces you to face your fears. The encouragement from the instructor helps you get back behind the wheel.
This is actually a common therapeutic technique. People will look for a way out when they have a phobia, so it never heals. Being forced to face it and overcome it can break down that wall.
Further, you have the driving instructor right there with you. This person is a professional. You can trust them. They'll keep you safe. This gives you more confidence than you would have while driving alone, and that can help you fight through it. Eventually, when you finish the course, you will likely be able to drive again on your own.
Do not ignore the way that anxiety and fear can impact your life after an accident. When you need to meet with professionals or use medications to get past these issues, make sure you know if you have a right to financial compensation for all of your costs that you can seek as part of a legal action against the driver who caused the crash.