/* 1. Use a more-intuitive box-sizing model */
*, *::before, *::after {
  box-sizing: border-box;
}
  
  /* 2. Remove default margin */
* {
  font-family:'Franklin Gothic Medium', Arial, sans-serif;
  margin: 0;
}
  
body {
  /* 3. Add accessible line-height */
  line-height: 1.5;
  /* 4. Improve text rendering */
  -webkit-font-smoothing: antialiased;
  overflow: auto;
}
  
  /* 5. Improve media defaults */
img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}
  
/* 6. Inherit fonts for form controls */
input, button, textarea, select {
  font: inherit;
}

/* 7. Avoid text overflows */
p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

/* 8. Improve line wrapping */
p {
  text-wrap: pretty;
}
h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
}

/*
  9. Create a root stacking context
*/
#root, #__next {
  isolation: isolate;
}

  /* Custom CSS */

* {
    background-color: antiquewhite;
}

header {
  min-height: 4rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.logo {
  height: 4em;
  position: absolute;
  left: 1em;
  padding-top: 1em;
  padding-right: 5vw;
  user-select: none;
}

nav {
  display: flex;
  justify-content: space-around;
  gap: 0.5em;
}

nav a {
  flex: 1; /* Flex-grow, flex-shrink, and flex-basis in one */
  text-decoration: none;
  color: black;
  padding: 1em 3em; /* Adjust padding for smaller screens */
  text-align: center;
  border-bottom: 2px solid;
  box-sizing: border-box; /* Ensure padding doesn’t overflow */
}

nav a:hover, nav a:active {
  background-color: black;
  color: antiquewhite;
  transition: transform 100ms ease-in-out;
  transform: scale(1.05);
}

section {
  margin: 2em;
  border-left: 2px solid;
  padding: 2em;
}

h1 a, h2 a {
    text-decoration: none;
    color: black;
}

h1 a:hover, h2 a:hover, h1 a:active, h2 a:active {
    text-decoration: underline;
}

.projects {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
}

article {
  /* border: 2px solid; */
  width: 100%;
  padding: 1em 3em;
  max-inline-size: 66ch;
}

.project-header {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 0.5em;
}

.github-link {
  flex-shrink: 0;
  display: inline-block;
  height: 24px;
  width: 24px;
}

.project-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* .content-text {
  text-align: center;
} */

/* Slideshow container */
.slideshow-container {
  width: 20rem;
  height: 20rem;
  position: relative;
  margin: 1em;
}

.slideshow-container:hover *, .slideshow-container:active {
  opacity: 100%;
}

/* Hide the images by default */
.mySlides {
  display: none;
}

.mySlides img {
  position: absolute;
  border: 2px solid black;
  max-width: 100%;
  max-height: 100%;
  top: 50%;
  left: 50%;
  transform: translate(-50%,-50%);
}

/* Next & previous buttons */
.prev, .next {
  cursor: pointer;
  position: absolute;
  opacity: 10%;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  margin: 0 8px;
  text-align: center;
  align-content: center;
  background-color: antiquewhite;
  border: 2px solid black;
  color: black;
  font-weight: bold;
  transition: 0.3s ease;
  border-radius: 50%;
  user-select: none;
}

.next {
  right: 0;
}

/* .prev:hover, .next:hover, .prev:active, .next:active {
  opacity: 100%;
} */

.dots {
  text-align: center;
  position: absolute;
  opacity: 10%;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  transition: 0.3s ease;
  background: none;
}

/* .dots:hover, .dots:active {
  opacity: 100%;
} */

.dot {
  cursor: pointer;
  height: 15px;
  width: 15px;
  background-color: antiquewhite;
  border: 1px solid black;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.6s ease;
}

.active {
  background-color: black;
}

/* Fading animation */
.fade {
  animation-name: fade;
  animation-duration: 600ms;
}

@keyframes fade {
  from {opacity: .4}
  to {opacity: 1}
}

/* Media queries at width 750px and 450px */

@media screen and (max-width: 750px) {
  /* nav {
    width: 100%;
  } */
  nav a {
    padding: 1em 2em;
  }
  .logo {
    padding-left: 1em;
    position: inherit;
  }
  .projects {
    flex-direction: column;
  }
  article {
    padding: 1em 1em;
  }
}

@media screen and (max-width: 450px) {
  /* nav {
    visibility: collapse;
  } */
  header {
    flex-direction: column;
  }
  .logo {
    /* position: absolute; */
    /* padding: 0; */
  }
  section {
    padding: 1em;
    margin: 1em;
  }
}