@ohermans1
Posted
Hey Mate
Looking awesome, well done!
Regarding your two questions:
-
Centering - that seems like as good an approach as any. If you think about it, the main body needs a height, otherwise, what will the container know to centre too. So giving it a height of (at minimum) 100% of the view height allows it to know where it is centring.
-
When using just plain old CSS and not a preprocessor (I use SASS/SCSS) it is good practice to put the variables in :root. I would recommend taking a look at a preprocessor like SASS, because it gives you the power to have a whole separate sheet dedicated to variables + much more powerful variables, like background-color: rgba($color-black, 0.7); for instance if you wanted a transparent version of a variable color you already have stored. There is a course on udemy call Advanced CSS and Sass which I found super helpful!
Cheers and keep up the good work.
Ollie
Marked as helpful
@humbruno
Posted
@ohermans1 Thanks for the feedback! I'll definitely take a look at preprocessors for CSS; I had heard of them before but was under the impression that they would be considered a more advanced skill.
@ohermans1
Posted
@humbruno Sorry about the super slow response - I def found them easier than expected, once you've got a bit of a foundation with standard CSS.