The following is a concept that dramatically changed how I cook. I used to be terrified of ruining things. Now, I realize that most culinary cooking errors are salvageable.
The basic premise is that there are five basic tastes: sweet, salty, bitter, sour, and umami. I am going to include the concept of "acid" under the umbrella of sour, and lump in "fat" with umami (umami is generally understood to mean meaty). Unofficially you could add a sixth taste, "spicy."
You can think of these five/six tastes as the colours on your palette. To paint your picture, or season your meal, you need to find a pretty combination. The key is to remember that it is all about the relative strength of each component with respect to the others.
Examples of ingredients that represent the various tastes
Sweet: honey, maple syrup, agave, dates, fruit
Salty: sea salt, nama shoyu, nori
Sour/Acid: vinegar, lemon juice
Bitter: some greens, herbs, cocoa
Umami/Fat: olive oil, cheese
Spicy: cayenne, pepper, ginger, red pepper flakes
Things like onions and garlic fit under many categories.
Now, when you have a recipe that doesn't taste quite right, ask yourself: Is it missing sweet, salty, sour, bitter, umami, or spicy? You can then choose one of the options from that category to boost the taste. Most of the time I am missing sour. I use a lot of apple cider vinegar and lemon juice. The lemon juice, particularly, is like liquid sunshine -- it'll brighten a taste that has become too dense.
Just like in painting, beauty in the culinary arts is in the eye of the beholder. So, be brave, dare to try new flavour combinations! Your tastebuds will thank you.