* {
  margin: 0;
  padding: 0;
  box-sizing: inherit;
}

html {
  font-size: 62.5%;
  box-sizing: border-box;
}

body {
  font-family: sans-serif;
  line-height: 1.5;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: linear-gradient(to top left, #383d38, #aae8d1);
  margin: 0;
  padding: 5rem;
}

header {
  position: absolute;
  height: 33vh;
  margin: 0;
  padding: 1rem 2rem 1.5rem 2rem;
  text-align: center;
  display: contents;
}

h2 {
  font: 2.1em sans-serif;
  letter-spacing: 1.5px;
  line-height: 4rem;
}

h1 {
  font: 4.5em sans-serif;
  font-weight: bold;
  letter-spacing: 1.5px;
}

h3 {
  font: 2.5em sans-serif;
  letter-spacing: 1.5px;
  line-height: 4rem;
}

main {
  position: relative;
  padding: 2rem;
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* 5 columns, equal width */
  grid-gap: 0; /* No space between grid items */
  place-items: center;
  margin: auto;
}

.grid-button {
  width: 100%; /* Make buttons fill the grid cell */
  height: 100%; /* Make buttons fill the grid cell */
  border: 1px solid black; /* Example button style */
  width: 10rem;
  height: 10rem;
  display: inline-block;
  align-items: center;
  font-size: x-small;
  padding: 0.5rem;
  float: none;
  color: black;
}

#boxfree {
  font: 3rem sans-serif;
  font-weight: bold;
  color: rgb(167, 2, 2);
}

footer {
  position: relative;
  text-align: center;
}

footer button {
  font: 1.5em sans-serif;
  text-align: center;
  margin: 1rem;
  padding: 5px;
  border-radius: 9px;
  color: black;
}

h4 {
  font: 4em sans-serif;
  font-weight: bold;
  letter-spacing: 1.5px;
}

li {
  font: 1.5rem sans-serif;
}

/* modal css */

.hidden {
  display: none;
}
.close-modal {
  font: 2em sans-serif;
  margin-bottom: 1em;
  padding: 0.2em;
  background-color: #aae8d1;
}

.modal {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70%;

  background-color: white;
  padding: 6rem;
  border-radius: 5px;
  box-shadow: 0 3rem 5rem rgba(0, 0, 0, 0.3);
  z-index: 10;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  z-index: 5;
}

/*  ------ media queries -------- */

/* ---- mobile devices  phones etc.---- */

@media (width <= 450px) {
  body {
    display: inline;
    background: #6f9285;
    color: black;
  }

  main {
    padding: 2rem 1rem;
  }

  h2 {
    font: 1em sans-serif;
    letter-spacing: 1.5px;
    line-height: 1.5rem;
  }

  h1 {
    font: 2em sans-serif;
    font-weight: bold;
    letter-spacing: 1.5px;
  }

  h3 {
    font: 1em sans-serif;
    letter-spacing: 1.5px;
    line-height: 1.5rem;
  }

  .grid-container {
    width: 34rem;
    height: 34rem;
    margin: auto;
  }

  .grid-button {
    border: 0.3px solid black;
    width: 6.8rem;
    height: 6.8rem;
    font-size: 0.55rem;
    padding: 0.2rem;
  }

  #boxfree {
    font: 1rem sans-serif;
  }

  footer button {
    font: 1rem sans-serif;
    margin: 0 1rem;
    padding: 3px;
  }
  h4 {
    font: 1.2em sans-serif;
  }

  li {
    font: 1rem sans-serif;
  }
}
