Hi, My name is Anissa & I have some advice for you!
Confusion is your Friend!
When you start programming your first web app you are doing something that you have never done before. It's a new challenge, a new opportunity, and in the case of software development, something so specific that it's probably never been done before.
Confusion, therefore, is a a sign that you are heading in the right direction. It's a signal that you have engaged in the problem solving pursuit that is math and technology and that it's time for you to dig deeper and keep going because clarity awaits.
Suspended disbelief plays an important role
When you are learning a new technology, whether you are learning to write your first programming language, or just the lastest framework, you go through this uncomfortable phase where you know that the code that you are looking at is doing this THING but you don't understand HOW exactly it's happening.
This is normal part of the process of learning new technology, in fact, it's a critical part of the process.
You see when you encounter a new programming language part of your learning process includes learning to train your eye. The way to train your eye is to read a good deal of code even when you don't totally understand what it's doing.
Final Piece of Advice
If the confusion ever becomes too much because there will be that moment of overwhelming frustration and doubt that creeps up on you. Just remember to close your eyes, breathe, then open your eyes and move forward knowing that You Got This and:
“If you tried to do something and failed, you are vastly better off
than if you had tried to do nothing and succeeded.”
- Unknown
PS. Use a background color in your divs to help understand the box model a little better. You can see how the boxes move around on your page.