:root {
  --dark-gray:  hsl(220, 15%, 20%);
  --dark-grayish-blue: hsl(240, 20%, 40%);
  --redish: hsl(350, 80%, 40%);
  background-color: var(--dark-gray);
}

* {
    box-sizing: border-box;
    scroll-behavior: smooth;    
}

a, body {
  color: white;
  font-size: 24px;
  font-family: Roboto, Poppins, sans-serif;
}

body, h1, h2 {
  margin: 0px;
  padding: 0px;
}

section {
  min-height: 100vh;
  padding-top: 5px;
}

#welcome-section {
  display: initial;
}
#welcome-section header {
  background: linear-gradient(
    45deg,
    hsl(220, 15%, 50%),
    hsl(220, 15%, 5%)
  );
}
#welcome-section header, #contact {
  min-height: calc(100vh - 60px);
  display: flex;
  flex-flow: column;
  justify-content: center;
  align-items: center;
}

header h1 {
  font-size: 48px;
}

#welcome-section header p, #contact header p {
  font-size: 32px;
  font-weight: light;
  font-style: italic;
  color: var(--redish);
}

#contact header p {
  color: white;
}

#navbar {
  background-color: var(--redish);
  position: sticky;
  top: 0px;
  display: flex;
  justify-content: flex-end;
  padding-right: 20px;
  height: 60px;
  box-shadow: 0px 0px 5px 5px rgba(0, 0, 0, 0.3);
}

#navbar a {
  height: 100%;
  padding: 15px;
  text-decoration: none;
}
#navbar a:hover {
  background-color: var(--dark-grayish-blue);
}
#projects {
  background-color: var(--dark-grayish-blue);
  padding-bottom: 50px;
}

#contact {
  background-color: var(--dark-gray);
}

#projects header {
  margin: 70px 0px 40px 0px;
}

#projects h2 {
  text-decoration: underline;
  text-align: center;
}

#projects > div {
  display: flex;
  flex-flow: row wrap;
  justify-content: center;
  gap: 20px 20px;
  width: 100%;
  padding-bottom: 50px;
}

.project-tile {
  display: block;
  width: 350px;
  height: 300px;
  text-decoration: none;
  text-align: center;
  --caption-height: 50px;
    transition: all 0.5s cubic-bezier(0, 0.5, 0.8, 1.5);
}

.project-tile figure {
  width: 100%;
  height: 100%;
  margin: unset;
}

.project-tile img {
  display: block;
  width: 100%;
  height: calc(100% - var(--caption-height));
  object-fit: cover;
}

.project-tile figcaption {
  background-color: var(--dark-gray);
  height: var(--caption-height);
  border-bottom-left-radius: 3px;
  border-bottom-right-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-tile:hover {
  transform: scale(1.1);
  box-shadow: 0 0 15px 5px hsl(0, 0%, 25%, 0.5);
}

.project-tile figcaption::before, .project-tile figcaption::after {
  color: orange;
  opacity: 0;
  transition: 0.5s linear;
  font-size: 80%;
}

.project-tile figcaption::before {
  content: "< ";
}

.project-tile figcaption::after {
  content: " />";
}

.project-tile:hover figcaption::before,
.project-tile:hover figcaption::after {
  opacity: 1;
}

#projects button {
  border: none;
  padding: 15px;
  border-radius: 3px;
  font-size: 20px;
  color: white;
  background-color: var(--dark-gray);
  display: block;
  margin: auto;
}

#projects button, #projects button i {
  transition: 0.3s linear;
}

#projects button:hover {
  background-color: var(--redish);
}

#projects button:hover i{
  margin-left: 5px;
}

footer {
  border-top: 3px solid var(--redish);
  width: 100%;
  margin-top: auto;
  margin-bottom: 0px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 15px;
  padding: 15px;
}

#contact header {
  margin-top: auto;
}

#contact .links a {
  padding: 10px;
  height: fit-content;
  transition: padding-top 150ms linear;
}

#contact .links a i {
  margin-right: 10px;
}

#contact .links a:hover {
  padding-top: 15px;
  transition: all 0.3s linear;
}

#contact header p {
  font-weight: thin;
}

.links {
  display: flex;
  flex-flow: row wrap;
  min-height: 75px;
}

@media (max-width: 768px) {
  body {
    font-size: 15px;
  }

  header h1, header h2 {
    font-size: 36px;
  }

 #welcome-section header p, #contact header p {
    font-size: 20px;
  }

  #contact .links {
    justify-content: center;
  }

  #contact .links a:hover {
    padding-top: 10px;
    color: pink;
    transition: all 0.3s linear;
  }
}
