Complex section
I have no real clue how to start doing this section nor do I know how to properly make this responsive that it also look good.
(I did not made this design, this is a design I got from school and have to follow)

28 Replies
i see a 2x2 grid with the images place-self:
- end start
- start start
- end end
- start end
you can layer the text and images with a grid as well (same grid area)
with a media query you can make it a single column for the images (or what ever you like)
Hmmm.
I think I will have the text layer positioned absolute over the images then a flexbox. This will give me freedom for each layer seperate I think.
grid for layers + alignment is ❤️
I am just seeing this, will this allow me to basically have 2 different layers that act seperately?
you could do it with a grid like this one (dimensions aren't exact 'cause I'm lazy) :
I mean that is more complex than probably need but I approve
Yes you can use absolute or just give them all the same space, isolate is a great feature too so then you have a clean stack.
wait isolate?
Here is a simple example of just using one area
you can also do like
> * { grid-area: 1 / -1;}
or something
Or like ragnar did be very specificah it's a grid thing?
yes isolate helps with z-index mostly but can be handy if you are in a project
no isolate is not a grid thing
https://developer.mozilla.org/en-US/docs/Web/CSS/isolation
I always enjoy ragnars short hand grid and use of areas heh ❤️
another quick example.. I have some more but they seem more confusing than helpful atm LOL these are the simplest
ah but it do anyting with positions? the isolation?
Yes isolation works for keeping stacking context to that parent
Its not needed in this case persay just good to have in the pocket
I have got something to work, I am just using position absolute since both "layers" have to stay at width 100% anways. and then for the images themselves prolly gonna do grid.

almost there

this is my html

woahh

aight, this is as close I can get thx a lot for the help.

responsiveness pfff, it's gonna look ugly af on smaller screensizes...
sus

man this is difficult to work with why not 2x2 grid
Cuz a 2x2 grid is to small?
you can set the size to whatever you want, why need more than 2x grid
size here is width, height not number of rows, columns
2x1 grid doesnt fit my 4 images in the size I want.
My images are slightly off centered
And have different aspect ratio
Here's my attempt for fun: https://codepen.io/vince1444/pen/GgpmeGd