I would approach this by explaining the system on paper. Then break out the functionality into paragraphs. Each paragraph is its own library. Do those functions first, then move on to the actual program itself (what implements the libraries). Then its just a matter of making sure everything leads to the right place.
Say:
Puppybook is a facebook for puppies.
paragraph #1 Each user logs in. Using two factor authentication.
#2
the user arrives to his profile,
where he can see the latest puppy posts
..and so on.For paragraph #1 I need to write the authentication code. For #2 I need to write the code to pull the latest puppy posts from the database into the system.
Then you would import those libraries and do a regular MVC type app. I suggest your read up on one of those. If you are lost, then check out protocademy.com. You can learn to do just that there.