I am losing my mind… I have been trying for hours to make this display work for a portfolio page. I am trying to make a grid display - 5 column display with each card spanning 2 columns and 1 row, so there is a free column down the centre for spacing. First card starting in column 1 row 1, next card starting in column 4 row 2, next card column 1 row 3, next card column 4 row 4 and so on for 10 posts. I would like the cards on the right to have a negative margin to draw them upward. Also, the card info is being drawn in with a query loop. See the picture below.
I can get it to the point that each card is 2 spans so column 1 and 2 but I cant get a selector to work to be able to select the children so I can use:
.portfolio-card:nth-child(odd) {
grid-column: 1 / span 2;
}
.portfolio-card:nth-child(even) {
grid-column: 4 / span 2;
margin-top: -6rem;
}
Please help!!
