How to make a section responsive to screen size?

Hello, I have a section with text and Image side by side. (Text on the right, image on the left) I know how to use CSS @media max-width and min-with but I am using display flex on the section to make the image side by side with the text and it doesn't work now. HTML code: https://pastebin.com/sZm8TS75 CSS code: https://pastebin.com/3L3sNAD2
Pastebin
HTML code - Pastebin.com
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
Pastebin
CSS code - Pastebin.com
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
4 Replies
Monimolimnion
Monimolimnion3y ago
What's your desired layout on mobile?
8
8OP3y ago
Forgot to mention, sorry. I want the text to be beneath the image and the image need to fit. I just cant understand how to do it after I used display flex
Monimolimnion
Monimolimnion3y ago
add flex-direction: column; to your media query

Did you find this page helpful?