* {
  box-sizing: border-box;
  text-align: center;
}
/* variables to style the dark mode, add these in another variable in dark mode and add those to the selectors */
:root {
  --borderColor: 2px solid white;
  --linkColor: white;
  --usernameColor: white;
}

body {
  background: #f9f3ec;
  font-family: "Stick No Bills", sans-serif;
  letter-spacing: 2px;
  margin: 0;
  transition: 0.6s ease, color 1s ease;
}

.dark-mode {
  background: rgba(0, 0, 0, 0.8);
  color: white;
  --borderImgColor: var(--borderColor);
  --colorOfLink: var(--linkColor);
  --colorOfUsername: var(--usernameColor);
}

.toggleBtn {
  font-family: "Stick No Bills", sans-serif;
  border-radius: 20px;
  padding: 8px;
  cursor: pointer;
  font-size: 20px;
}

.toggleBtn:hover {
  border: 2px solid #fff;
  background: #5f939a;
  color: #fff;
}

header {
  background: #5f939a;
  padding: 10px;
  width: 100%;
  margin-bottom: 30px;
  text-transform: uppercase;
}

.username {
  color: var(--colorOfUsername);
  font-size: 24px;
}

.username-link {
  text-decoration: none;
  color: var(--colorOfLink);
}

.username-link:hover {
  transition: all 1s;
  background: #5f939a;
  border-radius: 30px;
  padding: 5px;
}

.repo-amount {
  font-style: italic;
}

.repo-title {
  text-transform: uppercase;
}

.push-date {
  width: 100%;
}

.push-title {
  font-weight: bold;
  display: block;
}

.cards {
  border: 2px solid #5f939a;
  background-color: #dbd7d298;
  display: grid;
  width: 90%;
  text-align: center;
  margin: 10px auto;
  border-radius: 20px;
  padding: 0 5px;
}

.branch {
  border: 2px solid black;
  border-radius: 30px;
  width: 30%;
  margin: auto;
  background: #5f939a;
  color: white;
}

.grid-container {
  margin: auto;
}

fieldset {
  border: 4px solid;
  border-color: #5f939a;
  border-radius: 20px;
  margin: 0 10px;
}

legend {
  text-transform: uppercase;
  font-size: 28px;
}

img {
  border: var(--borderImgColor);
  width: 70%;
  border-radius: 50%;
}

.chart {
  margin: 10px auto;
  height: 200px;
  width: 200px;
}

.links {
  color: var(--colorOfLink);
  width: 80%;
  margin: auto;
  text-decoration: none;
  font-size: 12px;
}

.links:hover {
  transition: all 1s;
  background: #5f939a;
  border-radius: 30px;
}

footer {
  background: #5f939a;
  padding: 10px;
  margin-top: 20px;
}

/* MEDIA QUERIES */

/* TABLET */
@media (min-width: 767px) and (max-width: 1023px) {
  .cards {
    font-size: 28px;
    margin: 20px auto;
  }
  .links {
    font-size: 24px;
  }
  .repo-amount {
    font-size: 24px;
  }
  .location {
    font-size: 22px;
  }
  .chart {
    margin: 10px auto;
    height: 275px;
    width: 275px;
  }
}

/* DESKTOP */
@media (min-width: 1024px) {
  /* container for the whole page (profile section and cards) */
  .grid-container {
    display: grid;
    grid-template-columns: 1fr 2fr;
  }

  /* class from HTML / container for all of the cards only */
  .project-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding-top: 45px;
  }

  /* class from JS / container for each card */
  .cards {
    display: grid;
    width: 90%;
    margin: 10px auto;
    font-size: 18px;
  }

  .cards:hover {
    transform: scale(1.05);
    box-shadow: 4px 8px 16px -3px rgba(0, 0, 0, 0.459);
  }

  .chart {
    margin-top: 40px;
    width: 300px;
    height: 300px;
  }

  .links {
    font-size: 12px;
  }
  /* class from js */
  .repo-amount {
    margin: 30px 0;
  }

  img {
    animation: myAnim 2s ease 0s 1 normal forwards;
  }

  @keyframes myAnim {
    0% {
      transform: rotate(0) scale(0.3);
      opacity: 0.5;
    }

    100% {
      transform: rotate(360deg);
    }
  }
}
