Spanish subjunctive mood
The Spanish Subjunctive Mood, el modo subjuntivo, is mainly used for hypothetical, uncertain statements or desires.
The subjunctive can be very confusing for English speakers as it is almost no longer in use in English, but it is still common in Latin-based / Romance languages. The easiest way for English speakers to understand el modo subjuntivo is to look at the few cases where it's still used in English.
In English, the subjunctive is noticeable only because it seems a bit archaic (it appears a lot in Shakespeare, for example). Where it is still in common use, it's often invisible because it's identical to other forms. These English sentences are all in the subjunctive:
If I were you... (still in use)
Were I so kind! (modern: if only I was so kind)
Be that as it may! (still in modern use)
Note that all these cases express a hypothetical situation, which is the hallmark of the subjunctive mood. In English, it's often found in expressions like "I wish..." or "If X were true..."
Spanish has a whole set of tenses for the subjunctive mood, which makes learning it more difficult, but like anything it's just a matter of practice.
It helps to know that El Subjuntivo generally follows que:
Ojalá que gane la loteria.
If only I won the lottery.
Espero que vengáis.
I hope you come.
There are six tenses within subjunctive mood:
Related lesson: Tense / Mood