main {
  min-height: 95vh;
  width: 100%;
  background-color: var(--light-tone);
  padding: 0 10%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-content {
  width: 100%;
  max-height: 80vh;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 1rem;
}

.cards.main {
  grid-column: 1 / span 3;
  grid-row: 1 / span 2;
}

.text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  color: var(--light-tone);
  font-size: 24px;
  font-weight: bold;
  text-align: center;
}

.cards.img {
  aspect-ratio: 1 / 1;
}

.cards {
  background-color: var(--dark-tone);
  position: relative;
  width: 100%;
  height: 100%;
  border: 0.3rem solid #03346e;
}

.cards-button {
  background-color: var(--dark-tone);
  border: 0.1rem solid var(--light-tone);
  font-family: "Courier New", Courier, monospace;
  font-size: small;
  font-weight: bold;
  height: 3rem;
  padding: 0 1rem;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  transition: 150ms ease-in-out;
  z-index: 2;
}

.cards-button a {
  color: var(--light-tone);
  text-decoration: none;
}

.cards-button:hover {
  background-color: var(--light-tone);

  a {
    color: var(--dark-tone);
  }
}

.cards-button:hover {
  background-color: var(--light-tone);
  color: #03346e;
}

.cards img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.cards::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--overlay-tone);
  z-index: 1;
}

@media only screen and (max-width: 820px) {
  main {
    height: 90vh;
    min-height: auto;
    padding: 10% 10%;
  }

  .main-content {
    height: 100%;
  }

  .cards.main {
    grid-column: 1 / span 2;
    grid-row: 1 / span 1;
  }

  .cards {
    aspect-ratio: 0;
    grid-column: span 2;
  }

  .cards.img {
    aspect-ratio: auto;
  }

  .main-content {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, auto);
    grid-auto-rows: 1fr;
    max-height: fit-content;
  }
}

/*
body {
    overflow: hidden;
}

.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--dark-tone);
    transition: transform 1s ease-in-out;
    z-index: 9999;
  }

  .loader--hidden {
    transform: translateY(100vh);
  }

  .loader::after {
    content: "Designad av Mohammed T24a, Täby Enskilda";
    margin-top: 1rem;
    font-size: medium;
    color: var(--light-tone);
  }

  .loader::before {
    content: "Webb1-projekt";
    color: var(--light-tone);
    font-size: xx-large;
  }

  .loader::before {
    padding-right: 0.1rem;
    max-width: fit-content;
    overflow: hidden;
    white-space: nowrap;
    border-right: 0.1rem solid;
    animation: typing 5s steps(25) forwards, blink 1s step-end 5;
}

@keyframes typing {
    from {
        width: 0;
    }

    to {
        width: 80%;
    }
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

@media (max-width: 720px) {
    .loader::after {
        font-size: smaller;
    }

    .loader::before {
        font-size: medium;
    }
}

*/
