Hi dear friend nice job at tackling this challenge, it seems quite good!
I've reviewed the code, and it's clean and easy to read, great job there. I saw also that you used certainly a display: flex
approach in order to solve this problem, it might not make such a great difference but, did you know that you can use two lines of code to center an element, it's cool
Check this out!
display: grid;
place-content: center;
Voila! As easy as writing console.log("Hello World")
.
I noticed that you used em
to measure the font-size of the text, it's a good choice and it can also be upgraded if it's used rem
which takes directly from the html
or root of the document's font-size preset font-size and apply it automatically
An example of what I'm referring:
html {
font-size: 16px;
}
/* Now I can reference an scalable font-size using rem anywhere */
text-container p {
font-size: 1rem; /* Equivalent to: 16px */
}
Hope it can help you out a bit, thanks for reading!