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

/* Start Here */

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

.cards {
  width: 100%;
  background-color: var(--dark-tone);
  border: 0.3rem solid var(--accent-tone);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  z-index: 1;
  overflow: hidden;
}

.content-heading {
  color: var(--light-tone);
  font-size: large;
  background-color: var(--dark-tone);
  color: var(--light-tone);
  border: 0.1rem solid var(--light-tone);
  padding: 1rem;
  text-align: center;
  margin-bottom: auto;
}

@media only screen and (max-width: 820px) {
  main {
    height: fit-content;
    padding: 10% 10%;
  }

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

  .content-heading {
    font-size: medium;
  }

  .cards {
    height: 45vh;
  }
}

/* Infintity Scroll Animation */

.wrapper {
  margin: 2rem 1rem 1rem 1rem;
  display: flex;
  position: relative;
  flex-grow: 1;
  overflow: hidden;
  mask-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 0),
    rgba(0, 0, 0, 1) 20%,
    rgba(0, 0, 0, 1) 80%,
    rgba(0, 0, 0, 0)
  );
}

@keyframes scrollleft {
  to {
    left: -200px;
  }
}

.item {
  width: 200px;
  height: 100%;
  background-color: var(--light-tone);
  position: absolute;
  left: max(calc(200px * 4), 100%);
  animation-name: scrollleft;
  animation-duration: 30s;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}

.item1 {
  animation-delay: calc((30s / 4) * (4 - 1) * -1);
}

.item2 {
  animation-delay: calc((30s / 4) * (8 - 2) * -1);
}

.item3 {
  animation-delay: calc((30s / 4) * (8 - 3) * -1);
}

.item4 {
  animation-delay: calc((30s / 4) * (8 - 4) * -1);
}

/* Border animation */

.border-card {
  flex-grow: 1;
  background-color: var(--dark-tone);
  margin: 2rem 1rem 1rem 1rem;
  position: relative;
}

@property --angel {
  syntax: "<angle>";
  initial-value: 0deg;
  inherits: false;
}

.border-card::after,
.border-card::before {
  content: "";
  position: absolute;
  background-image: conic-gradient(
    from var(--angel),
    transparent 70%,
    var(--light-tone)
  );
  z-index: -1;
  inset: -0.3rem;
  animation: 3s spin linear infinite;
}

.border-card::before {
  filter: blur(1.5rem);
  opacity: 0.5;
}

@keyframes spin {
  from {
    --angel: 0deg;
  }

  to {
    --angel: 360deg;
  }
}

/* Text-marquee animation */

.text-marquee-container {
  margin: 2rem 1rem 1rem 1rem;
  display: flex;
  flex-grow: 1;
  user-select: none;
  overflow: hidden;
  overflow-x: hidden; /* add this */
  gap: 2rem;
  mask-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 0),
    rgba(0, 0, 0, 1) 20%,
    rgba(0, 0, 0, 1) 80%,
    rgba(0, 0, 0, 0)
  );
}

.text-marquee-container ul {
  min-width: 100%;
  flex-shrink: 0;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  animation: scroll-ex 20s linear infinite;
  color: var(--light-tone);
  font-size: xx-large;
}

@keyframes scroll-ex {
  to {
    transform: translateX(calc(-100% - 2rem));
  }
}
