@beowulf1958
Posted
Congratulations on completing this challenge! I love the hover effects and the smooth transition.
The reason your card becomes hidden when resizing the screen is that you hard coded the margin-top and margin-left. This is not a good way to position your card. It would be better to use one of the centering techniques from this website Then the card stays visible (and centered) when resizing.
Remove the margin-top an margin-left from .preview-card Then add this to the body
body {
background-color: hsl(47, 88%, 63%);
font-size: 16px;
font-family: "Figtree", sans-serif;
letter-spacing: 0px;
/* add */
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
}
Now everything works fine.
Marked as helpful
@OlgaElKhayat
Posted
@beowulf1958 "Thank you so much! I followed your advice, and it worked. I initially considered using a flexbox but only applied it to the blog card, not realizing that it could also be used for the entire body. Thanks for taking the time to explain everything so clearly. Your help is much appreciated!