Design comparison
SolutionDesign
Community feedback
- @silkcoderPosted 12 months ago
Congrats for completing the task, it looks good.
However, I have a suggestion to place the main tag content in the center of the screen horizontally and vertically.
In your style.css file, add the following styles to body tag
body { //add following styles to your existing styles display: flex; justify-content: center; align-items: center; }
remove 'margin-left: 35%;' and 'margin-top: 13.5%;' from your main tag styles
main { //remove the following styles margin-left: 35%; margin-top: 13.5%; }
Now the main content get centered in all sized devices.
You can read more about flex box styles in the following page Introduction to CSS Flexbox
Good luck with your future challenges. Have a good day.
Marked as helpful1
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord