No, God hasn't given up on you - not at all. His love never changes, and He loves you just as much today as He did when you first gave your life to Jesus. As the Bible says, "Jesus Christ is the same yesterday and today and forever" (Hebrews 13:8).
Why has this happened to you? In my experience, this usually happens for two reasons. First, it happens because we rely on our feelings instead of on facts - the facts of what Christ has done for us. Feelings and emotions aren't wrong; God gave them to us, and they are an important part of our lives. Feelings, however, come and go; we don't always feel on top of the world.
But facts - unlike our feelings - don't change, and we need to rely on them instead of our feelings. And the greatest fact of all is that Jesus Christ died for you, because He loves you and wants you to be with Him in heaven forever. The Bible says, "How great is the love the Father has lavished on us, that we should be called children of God! And that is what we are!" (1 John 3:1).
The second reason God seems distant is because we neglect the spiritual "food" He has provided to strengthen us - the "food" of the Bible, prayer, and fellowship with other believers. Just as we'll grow weak physically if we neglect to eat, so we'll grow weak spiritually if we neglect these. Make them part of your life every day, for through them you'll grow closer to Christ.