@weldu0
Posted
π Hey, @Lunarix09! You do not need to add Flexbox to every container that is inside another container. Use Flexbox only when you need to! The only Flexbox you need is for .avatar
and body
.
Don't use positioning for centering; Flexbox is much better for centering without making your code too complex. Here is how you can do it:
body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
}
For the .card
you don't need to set the height to anything value; it will take the space it needs automatically. For the tag .learning
, you don't need to set the height either. Just add display: inline-block;
and it will only take the space it needs without the risk of issues related to height.
I hope this helps you. π