I currently have a responsive layout featuring a grid of content blocks.
For desktop view, each row consists of 4 blocks.
When viewed on a tablet, each row displays 3 blocks.
On mobile devices, each row showcases 2 blocks only.
I am looking to add a horizontal line between each row of blocks across all screen sizes. Currently, I'm using a border bottom on each block, but the line doesn't span the full width of the page in case there is empty space (for example, displaying 3 blocks on a 4 column grid).
The only workaround I can think of is wrapping each row in a container using JS and reloading that function every time the screen is resized.
Is there a CSS solution for achieving this effect?
For clarification, refer to this image showcasing what I aim to accomplish: