FAQ card using flexbox

Solution retrospective
Positioning the images was challenging. I had to use negative margins to overlap them. But, the hardest challenge was laying out the box, which was not hidden in the overflow of the white card container. I used position: fixed
initially, but then the rest of the elements moved when scrolling the whole screen, while the box remained fixed. Then I changed it to position: absolute
and the box moves with the rest of the layout.
I feel like my layouts require so many nested containers. I am concerned that I make things more difficult than they need to be.
I also struggle with trying to get my solution to have the same dimensions as the example. I debate in my own head about how many absolute pixels to size things, or whether to use more responsive percentage values.
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on wbandersonjr's solution.
Join 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