Design comparison
Solution retrospective
hey, please check out my solution and give me feedback on it especially on margins and paddings. I use my eyes to visualize where things should be placed and how much space should be given and it most times results into guess work. please check it out and give me tips on how to manage that. Thanks
Community feedback
- @correlucasPosted about 2 years ago
πΎHello Khlez, congratulations for your new solution!
You don't need to really use
transform: translateY(50%);
for the alignment, instead of that usemin-height
to align the child element and flexbox for the vertical alignment. See the code fixes below:body { min-height: 100vh; background-color: var(--main-background); display: flex; align-items: center; justify-content: center; } @media (min-width: 900px) .card { display: flex; flex-direction: row-reverse; width: 55em; border-radius: 5px; /* transform: translateY(50%); */ /* overflow: hidden; */ }
Add the overlay effect with,
filter
,background-blend-mode
ormix-blend-mode
(the best choice in my opinion). See the code belowimg { mix-blend-mode: multiply; opacity: 0.8;}
π I hope this helps you and happy coding!
Marked as helpful0@KhlezPosted about 2 years ago@correlucas Thank you so much for the tip. I will work on it.
1
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