We're all familiar with the effects an unhealthy diet can have on our hearts and waistlines. Study after study have shown that a diet high in ultra-processed foods (think added sugars, preservatives and chemical additives) can lead to obesity, cardiovascular disease, diabetes and a shorter lifespan — just to name a few of the downsides. And now, a recent case study from the Annals of Internal Medicine has shown how junk food can also affect the nervous system.

The study focuses on a teenage boy in the United Kingdom who first went to his family doctor with complaints of fatigue. Blood level tests showed he was deficient in vitamins B12 and iron. Just a year later, the now 15-year-old boy returned, this time with poor vision and hearing loss. MRI scans and an eye exam revealed nothing and yet, a year later, his eyesight had declined to a level considered legally blind in the United States.

When doctors began to investigate his diet for the source of lacking nutrients, they discovered that the teen, who was described as a "picky eater," went far beyond picky — sticking to an extremely limited diet of white bread, French fries, potato chips and processed meats. In the end, doctors diagnosed him with nutritional optic neuropathy, a condition not usually seen in the developed world. Vision loss is potentially reversible if caught early enough, but not in this case.

Vitamin deficiencies — particularly of the B vitamins, which are important for cellular reactions — can damage essential nerve cells. A well-rounded diet, full of whole grains, fruits and vegetables, is just as essential for your nervous system as it is for your heart health and BMI. Below are five ways your diet affects your brain, spine and your entire central nervous system.

1. Brain food

Grilled sardines on a wooden surface with sun-dried baby tomatoes, salt, and a knife and fork Sardines are a terrific source for omega-3s and vitamin B-12. (Photo: Dani Vincek/Shutterstock)

Your brain is the control center of the nervous system, which means it needs lots of omega-3 fatty acids to keep it healthy. You can find these fats in foods like cold-water oily fish, walnuts, broccoli, flaxseed and beans. These essential fatty acids are also thought to help reduce inflammation throughout the body.

2. Know your Bs

Thiamine, one of the B vitamins, is also important for nerve health. It's usually in enriched products like cereal and pasta, and definitely found in any B-complex vitamins. Speaking of Bs, B12 maintains your myelin sheath, which is what surrounds and protects your nerves. If the sheath is damaged, your nerves can lose function. For those who aren't able to absorb these crucial vitamins through food (sometimes a problem for vegans), a B-complex supplement is highly recommended.

3. Go green

seaweed salad Seaweed makes a tangy, nutritious, delicious salad. (Photo: Foodio/Shutterstock)

Green leafy vegetables, and not just those found on terra firma, can help heal your nervous system. They're high in B-complex vitamins, vitamin C, vitamin E and magnesium, all of which keep your neurotransmitters synthesized and circulating along nicely. Sea vegetables (you guessed it: seaweed) can also assist in proper nervous system functioning.

4. Embrace complex carbs

Your body and brain need energy, which they get from glucose, which is found largely in carbohydrates. Not all carbs are created equal, however. White bread and potato chips will make your body "crash" after the initial sugar spike; instead, aim for whole grain pastas and rice. They release energy slowly, letting your brain function in a stable fashion.

5. Break up with sugar

bowl of sugar with scoop and sugar cubes Sugar — it's in everything. (Photo: Africa Studio/Shutterstock)

Alcohol, packaged foods, sugary sodas, microwave meals ... excess sugar is an additive in just about everything we eat. But that doesn't mean you shouldn't try to cut back when possible. Too much sugar can impair cognitive skills because it releases that feel-good chemical dopamine, a key ingredient in our brain's reward system. We also now know that sugar is addictive, so practicing moderation is crucial, particularly if you're prone to a sweet tooth.

Whether you're concerned about the health of your head, shoulders, knees, or toes, know that your diet is a huge factor in keeping healthy. And, as always, when considering any big changes in diet, you should consult your physician first.

5 ways your diet affects neurological health
A recent U.K. case study focused on a teenage boy's highly restrictive diet, and how his junk food preferences led to permanent vision loss.