@correlucas
Posted
๐พHello Saadi, congratulations for your first solution and ๐ welcome to the Frontend Mentor Coding Community!
Your first solution is just great and the component design is perfect! Two things you can improve in your solution. One is the shadow that is a bit dark and other is the alignment.
To create a smooth shadow you need to give it less opacity
and more blur
hereโs a good value for this shadow box-shadow: 5px 7px 12px 5px rgb(0 0 0 / 7%);
To make the vertical alignment, first of all remove the margin
and add to the body
min-height: 100vh
to make the body display 100% of the browser screen size and display: flex
e flex-direction: column
to align the child element (the container) vertically using the body as reference.
Here's your code fixed and the container aligned:
main {
min-height: 100vh;
/* margin: auto; */
/* width: 50%; */
padding: 10px;
display: flex;
align-items: center;
justify-content: center;
}
๐ I hope this helps you and happy coding!
Marked as helpful