The quest for learning grammar is a valiant one, and it is not only difficult, but everybody is going to learn grammar differently. Thus, it's well-nigh impossible to write an exhaustive answer here. So I'm not gonna. :)
Pronunciations are relatively static; spellings and definitions are, too. Grammar, on the other hand, can be different for every sentence. That's part of what makes it so hard.
Here are a couple of tips:
Familiarize yourself with the basics
You're not going to know everything about the grammar when you begin-- in fact, you may never know all the grammar rules of your target language.
Nevertheless, familiarize yourself with the basic grammar as much as possible: read, listen, read, listen. Then practice what you know. Don't sweat it if you don't get it right the first, fifth, or fiftieth time.
Once you have the basics down, you should be good for a while.
Study the grammar academically
Just like in school. Get a textbook or study articles online. This isn't necessarily the most fun, but stick it out-- it will help.
Do grammar exercises
Quiz yourself with simple sentences. Even working on the easiest stuff can help you with the most complex sentence structures.
Immerse yourself in the language
Grammar is not the most important part of learning a language. It's important, indeed, but not the most important. Ability to communicate in that language is the most important.
Specifically studying grammar may not be what helps you the most. Watch movies, read books, listen to music in your target language. Your brain will find the "method to the madness" eventually.
Don't be afraid to make mistakes
If someone asked you "Yourself show me bathroom, please?", you would understand them, no? Is it proper grammar? Not quite, but it gets the point across, and that's what language is about, anyways: communication.
If you're making mistakes in your grammar and don't realize it, that's OK. You might not sound quite right, but if your vocabulary is mostly there, you'll be communicating adequately. Once you do realize your mistakes, you're halfway to fixing them; as you familiarize yourself more with your target language, the grammar will come.
In the end, the more you work at it, the better you'll get.
Do I have perfect grammar skills even in my own native language? Nope. Will I ever? Probably not.
As I mentioned in this answer, try changing up how you study: it'll give your brain a new challenge.