.content { display:flex; flex-direction: row; flex-wrap: wrap; } .content figure { flex: 25%; margin-left: auto; margin-right: auto; align-items: center; } .content img { display: block; margin-left: auto; margin-right: auto; max-width: 50%; height: auto; width: auto; outline: cadetblue solid 3px; } .content p { flex: 50%; } @media only screen and (max-width: 600px) { .content p { flex:100%; } .content figure { flex:100%; } }