I'm trying to create a page where I have 2 lists of buttons, each one in a div, side by side. I tried a CSS grid and flex, as you can see below. However, nothing seems to work, as the first div went all the way to the left margin and the other one under it.
How do I add some space to the left margin for the first column and from the half of the page for the second one?
.grid-container {
display: grid;
grid-template-columns: 1fr 1fr 1fr;
grid-gap: 20px;
}
button {
width: 120px;
height: 60px;
text-align: center;
text-decoration: none;
display: flex;
flex-direction: column;
font-size: 16px;
font color: black;
margin: 4px 2px;
transition-duration: 0.4s;
cursor: pointer;
background-color: white;
color: black;
border: 2px solid #CC0000;
}
<div class="grid-container">
<div class="grid-child">
<a href="createCl.php"> <button style="color: #000000; text-decoration: none;">
<strong>Aggiungi</strong></button></a>Aggiungi</span> <br><br>
</div>
<div class="grid-child">
<a href="map.php"> <button style="color: #000000; text-decoration: none;">
<strong>Mappa</strong></button></a>Mappa Clienti</span>
</div>
</div><br>