A sleepless speaker lies awake at half past midnight, thinking about someone who may not be thinking of them back. They mention the saying that if you're awake at night, someone is dreaming of you, then reject it: no one thinks of them or dreams of them, unless this one person does. That small "unless you do" shows how much hope is hiding under the loneliness.
The dreams are split in two. Some are tender, full of hugging and simply being close. Others are nightmares, where the loved one is behind a glass wall, being hurt and left in tears while the speaker can only watch. The glass is a strong image: close enough to see, too far to help. The mood is quiet, anxious and helpless, and the repeated "half past midnight" at the start and end makes it feel like the speaker is stuck in that hour, going round in the same worry.