:root {
  --dark-grey: #222;
  --dark-purple: #2e1065;
  --off-white-purple: #f5f5f5;
  --mid-purple: #a17ce5;
}

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

html {
  scroll-behavior: smooth;
}

@font-face {
  font-family: 'roboto';
  src: url(/assets/Roboto-Regular.ttf);
}

body {
  font-family: 'roboto', Arial, Helvetica, sans-serif;
  color: var(--dark-grey);
  background-color: var(--off-white-purple);
  line-height: 1.5;
}

header {
  position: sticky;
  top: 0;
  background-color: var(--dark-grey);
}

nav {
  height: clamp(35px, 3.5vw, 70px);
  display: flex;
  justify-content: end;
  align-items: center;
  box-shadow: 0 0 5px var(--dark-grey);
}

h1 {
  padding: 25px 0 25px 5%;
  background: linear-gradient(
    332deg,
    var(--off-white-purple) 48%,
    #986ee6 48.5%,
    var(--mid-purple) 50%
  );
  font-size: clamp(32px, 2.6vw, 40px);
}

li {
  list-style: none;
}

.nav-list {
  display: flex;
  gap: 4vw;
  padding: 0 10vw 0 0;
}

.nav-list > li > a {
  text-decoration: none;
  font-size: clamp(16px, 1.5vw, 22px);
  color: var(--off-white-purple);
}

.nav-list > li > a:hover,
.nav-list > li > a:focus {
  border-bottom: 2px solid var(--off-white-purple);
}

a {
  display: inline-block;
}

p {
  font-size: clamp(16px, 2vw, 20px);
}

.skill-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  justify-content: center;
  margin: 0 5% 0 5%;
  padding: 1em 0 1em 0;
  border-radius: 5px;
  background-color: var(--dark-purple);
  color: var(--off-white-purple);
}

.skill-icon {
  width: 60px;
}

.skill-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.project-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  justify-items: center;
  gap: 20px;
  margin: 0 5% 0 5%;
}

.project-list > li {
  display: flex;
  flex-direction: column;
  width: 100%;
  box-shadow: 0px 0px 15px var(--mid-purple);
  margin: 10px;
}

.project-github-icon,
.project-live-icon {
  margin-right: 10px;
  width: clamp(25px, 2.5vw, 40px);
  transition: 0.5s transform ease-in-out, 0.35s rotate ease;
}

.project-github-icon:hover {
  transform: scale(1.5);
  cursor: pointer;
}

.project-live-icon:hover {
  transform: scale(1.5);
  cursor: pointer;
  rotate: 45deg;
}

.project-header {
  display: flex;
  justify-content: space-between;
  padding: 1rem;
}

h3 {
  font-size: clamp(1.2rem, 1.5vw, 26px);
}

.project-list > li > p {
  padding: 0 1rem 0.5rem 1rem;
}

.contact-icon {
  width: clamp(40px, 2.5vw, 55px);
  transition: 0.5s transform;
}

.contact-icon:hover {
  transform: scale(1.5);
}

section {
  padding-top: 50px;
}

h2 {
  margin: 0 5% 3% 5%;
  border-bottom: 3px solid var(--dark-purple);
  text-align: center;
  font-size: clamp(21px, 2.6vw, 26px);
}

#projects-section > p,
#about-section > p {
  margin: 0 10% 3% 10%;
}

#contact-section {
  padding-bottom: 45px;
}

#contact-section > p {
  margin: 0 20% 0.5rem 20%;
}

#contact-section > a:first-of-type {
  margin: 10px 15px 0 20%;
}

@media (max-width: 700px) {
  nav {
    height: 50px;
  }
  .nav-list > li > a {
    font-size: 17px;
    justify-content: center;
  }
}
