I'm trying to mimic a website. I'm using flex for my divs, but they are not properly aligning.
What mine looks like: https://i.stack.imgur.com/8xl7e.png
What I want it to look like: https://i.stack.imgur.com/uPFQF.png
My Code:
<div class="div1">
<img src="https://i.imgur.com/AbZMoEL.png" class="image" alt="cookie picture">
<p class=""> cookies are great! </p>
<a class="modulbutton" href="#open1">Open modal link</a>
<div class="div1">
<img src="https://i.imgur.com/kdOyxwV.png" class="image" alt="icecream picture">
<p class=""> Ice cream is great! </p>
<a class="modulbutton" href="#open1">Open modal link</a>
<div id="open1" class="modalwindow">
<div class="msgblock">
<h1>Heading</h1>
<p>some text</p>
<img src="2.jpg" alt="missing">
<div class=""> <a href="#">Close</a></div>
</div>
</div>
</body>
<footer>
<style>
.div1 {
width: 900px;
height: 400px;
border: 3px solid blue;
display: flex;
align-items: center;
}
.modulbutton{
background-color: green;
color: white;
padding: 3%;
text-decoration: none;
}
Any help would be greatly appreciated, I can't seem to align the description text and modal button properly on the bottom of the image.
Thanks!