@import url(colors.css);

@font-face {
    font-family: 'SpaceGrotesk-VariableFont_wght', sans-serif;
    src: url('../fonts/SpaceGrotesk-VariableFont_wght.ttf') format('ttf');
    font-weight: normal;
    font-style: normal;
  }
  
@font-face {
    font-family: 'WorkSans', sans-serif;
    src: url('../fonts/WorkSans-VariableFont_wght.ttf') format('ttf');
    font-weight: normal;
    font-style: normal;
}

body{
    padding: 0px;
    font-weight: 400;
    font-family: "Work Sans", sans-serif;;
    font-size: 18px;
    width: 100%;
    height: 100%;
    margin: 0;
    /* was curious and googled if it was hard to change the cursor but ended up beign so simple so wanted to try it out for fun */
    cursor: url('../images/cursor.svg'), auto;
  } 

 .hambMenu {
    display: none;
  }

  .navbar {
    background-color: var(--primaryColor);
    overflow: auto;
    align-items: center;
    padding-left: 80px;
    padding-top: 20px;
    cursor: url('../images/cursor-2.svg'), auto;
  }

.logo {
    display: flex;
    min-height: 5%;
    min-width: 10%;
}
  
nav a {
    float: left;
    font-family: "Space Grotesk", sans-serif;
    text-align: center;
    padding: 12px;
    color:var(--secondaryColorTwo);
    text-decoration: none;
    font-size: 17px;
    cursor: url('../images/cursor-hand.svg'), auto;
}
.dropdown {
    float: left;
    overflow: hidden;
  }

i {
    color: var(--secondaryColorTwo);
    position: relative;
}
  
  /* Dropdown hovering button */
.dropdown .dropdown-button {
    font-size: 16px;
    border: none;
    outline: none;
    color: var(--secondaryColorTwo);
    padding: 14px 16px;
    /* used a tutorial which explained the inherit function which allows what chosen to take the same value from the parent instead having to code it again */ 
    background-color: inherit;
    font-family: inherit;
    margin: 0;
    cursor: url('../images/cursor-2.svg'), auto;
}
  
  /* hide the items inside the drop down item in the navbar */
.dropdown-item {
    display: none;
    position: absolute;
    background-color: var(--primaryColor);
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
}
  
  /* pages inside the dropdown button */
.dropdown-item a {
    float: none;
    color:var(--secondaryColorTwo);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
}
  
.dropdown-item a:hover {
    background-color: var(--secondaryColorTwo);
    color: var(--primaryColor);
}
  
  /* menu items pop up when hovering on "projects" */
.dropdown:hover .dropdown-item {
    display: block;
}

.pageHeading {
    flex-direction:column;
    align-items: left;
    color:var(--secondaryColorTwo);
    font-family: "Space Grotesk", sans-serif;
    font-weight: bold;
    font-size: clamp(2rem, 1rem + 3.3333vw, 4rem);
    padding-left: 40px;
}


/* this about me section is supposed to let you open just one text bubble per time but the tutorial says it needs java script for it */
.about-me {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: start;
  gap: 30px;
  max-width: 1000px;
  margin: auto;
  margin-top: 40px;
  margin-bottom: 40px;
}

h2 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.5rem, 0.625rem + 2.9167vw, 3.25rem);
  margin: 0;
}

h3 {
  font-family: 'Work Sans', sans-serif;
  font-size: clamp(1rem, 0.75rem + 0.8333vw, 1.5rem);
}


.profile-img img {
  width: 100%;
  max-height: 100%;
  display: inline-block;
}

.about {
  display: flex;
  flex-direction: column;
  gap: 20px;
}


/* Accordion with bubbles pink and black */
.about-faq {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

details {
  width: 100%;
}

/* had to give a different size to all of them as the text was going out the text bubble */
summary {
  background: url("../images/pink-bubble-question.svg");  background-size: contain;
  background-position: center center;
  background-repeat: no-repeat; 
  color: var(--secondaryColorTwo);
  font-weight: bold;
  font-size: clamp(1rem, 1rem + 0vw, 1rem);
  padding: 20px 40px;
  border-radius: 10px;
  list-style: none;
  cursor: pointer;
  display: inline-block;
  max-width: 80%;
  text-align: left;
  padding-left: 30%;
  padding-right: 20%;
  word-wrap: break-word;
  font-family: 'Space Grotesk', sans-serif;
  cursor: url('../images/cursor-hand.svg'), auto;
}

details .answerOne {
  background: url("../images/black-bubble-answer.svg"); background-size: contain;
  background-position: center center;
  background-repeat: no-repeat; 
  color: var(--secondaryColorTwo);
  padding: 20px 40px;
  font-size: clamp(1rem, 1rem + 0vw, 1rem);
  margin-top: 10px;
  border-radius: 10px;
  width: fit-content;
  max-width: 80%;
  text-align: left;
  display: none;
  word-wrap: break-word;
  padding-left: 20%;
  padding-right: 25%;
  font-family: 'Work Sans', sans-serif;
}

details .answerTwo {
  background: url("../images/black-bubble-answer.svg"); background-size: contain;
  background-position: center center;
  background-repeat: no-repeat; 
  color: var(--secondaryColorTwo);
  padding: 20px 40px;
  font-size: clamp(1rem, 1rem + 0vw, 1rem);
  margin-top: 10px;
  border-radius: 10px;
  width: fit-content;
  max-width: 80%;
  text-align: left;
  display: none;
  word-wrap: break-word;
  padding-left: 13%;
  padding-right: 20%;
  font-family: 'Work Sans', sans-serif;
}

details .answerThree {
  background: url("../images/black-bubble-answer.svg"); background-size: contain;
  background-position: center center;
  background-repeat: no-repeat; 
  color: var(--secondaryColorTwo);
  padding: 20px 40px;
  font-size: clamp(1rem, 1rem + 0vw, 1rem);
  margin-top: 10px;
  border-radius: 10px;
  width: fit-content;
  max-width: 80%;
  text-align: left;
  display: none;
  word-wrap: break-word;
  padding-left: 12%;
  padding-right: 20%;
  font-family: 'Work Sans', sans-serif;
}

details .answerFour {
  background: url("../images/black-bubble-answer.svg"); background-size: contain;
  background-position: center center;
  background-repeat: no-repeat; 
  color: var(--secondaryColorTwo);
  padding: 20px 40px;
  font-size: clamp(1rem, 1rem + 0vw, 1rem);
  margin-top: 10px;
  border-radius: 10px;
  width: fit-content;
  max-width: 80%;
  text-align: left;
  display: none;
  word-wrap: break-word;
  padding-left: 15%;
  padding-right: 20%;
  font-family: 'Work Sans', sans-serif;
}

details .answerFive {
  background: url("../images/black-bubble-answer.svg"); background-size: contain;
  background-position: center center;
  background-repeat: no-repeat; 
  color: var(--secondaryColorTwo);
  padding: 20px 40px;
  font-size: clamp(1rem, 1rem + 0vw, 1rem);
  margin-top: 10px;
  border-radius: 10px;
  width: fit-content;
  max-width: 80%;
  text-align: left;
  display: none;
  word-wrap: break-word;
  padding-left: 10%;
  padding-right: 20%;
  font-family: 'Work Sans', sans-serif;
}

/* make it as accordion */
details p {
  display: none;
}

details[open] p {
  display: block;
}

footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--primaryColor);
  padding: 10px 80px;
  color: var(--secondaryColorTwo);
  cursor: url('../images/cursor-2.svg'), auto;
}

.social-icons {
  display: flex;
  gap: 10px;
}

.social-icons a {
  display: inline-block;
  width: 24px;
  height: 24px;
  cursor: url('../images/cursor-hand.svg'), auto;
}

.social-icons img {
  width: 100%;
  height: auto;
  display: block;
}

@media only screen and (max-width: 768px) {
/* transform the nav bar into a hamburger menu on tablet and mobile */
 .hambMenu {
  display: flex;
  position: fixed;
  top: 0;
  right: 0;
  z-index: 300;
  width: 100vw;
  justify-content: space-between;
 }

.logoHamb {
  z-index: 1000;
}

/* checkbox to a toggle */

.toggle {
  width: 60px;
  height: 60px;
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;
  opacity: 0;
  cursor: pointer;
  color: var(--primaryColor);
}

/* hamburger icons */

.hamburger {
  position: absolute;
  top: 0;
  right: 20;
  z-index: 1;

  /* style the square */
  width: 30px;
  height: 60px;
  background: transparent;
  padding: 0;

  /* flex to center content */
  display: flex;
  justify-content: center;
  align-items: center;
}

/* hamburger lines */
.hamburger > div {
  position: relative;
  width: 100%;
  height: 2px;
  background-color:var(--secondaryColorTwo);
  transition: all 0.5s ease;
}

/* no need for the toggle to move on hover as theres no hover effect on tablets or mobile */
/* .toggle:checked:hover + .hamburger > div {
  transform: rotate(225deg);
} */

.hamburger > div::before, 
.hamburger > div::after {
  content: "";
  position: absolute;
  z-index: 1;
  width: 100%;
  height: 2px;
  background-color:var(--secondaryColorTwo);
} 

.hamburger > div::before {
  top: -10px
}

.hamburger > div::after {
  top: 10px;
}

/* change the hamburger state to the X */
.toggle:checked + .hamburger > div {
  transform: rotate(135deg);
}

.toggle:checked + .hamburger > div::before,
.toggle:checked + .hamburger > div::after {
  top: 0;
  transform: rotate(90deg);
}

/* link my hb to menu */
.toggle:checked ~ .menu {
  visibility: visible;
  position: fixed;
}

.toggle:checked ~ .menu > div {
  transform: scale(1);
  transition-duration: var(0.75s);
}

.toggle:checked ~ .menu > div > div {
  opacity: 1;
}

/* style menu links */
.menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;

  /* hide menu */
  visibility: hidden;
  overflow: hidden;
}
/* overlay */
.menu > div {
  background-color: var(--primaryColor);
  /* turn into a circle */
  border-radius: 50%;
  width: 200%;
  height: 200vw;

  /* put overlay in the center */
  display: flex;
  flex: none;
  justify-content: center;
  align-items: center;

  /* animation when appears */
  transform: scale(0);
  transition: all 1s ease;
}

/* links */
.menu > div > div {
  text-align: center;
  max-width: 90vw;
  max-height: 100vh;

  /* animation */
  opacity: 0;
  transition: all 0.3s ease;

}

.menu > div > div > ul {
  padding: 0;
}

.menu > div > div > ul > li {
  list-style: none;
  padding: 0;
}
.menu > div > div > ul > li > a {
  font-family:"Space Grotesk", sans-serif; ;
  text-decoration: none;
  color: var(--secondaryColorTwo);
  font-size: 1.5rem;
}

.logo {
  justify-content: left;
  margin: 0;
}

 .link-item {
  display: none;
 }

 .dropdown {
  display: none;
 }

 .pageHeading {
  display: none;
 }
.navbar {
  padding: 0;
}

  /* this responsive section was the most challenging */

.about-me {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin: 20px auto;
  padding: 0 15px;
}

.profile-img img {
  width: 100%;
}

.about {
  gap: 15px;
}

.about-faq {
  gap: 5px;
  justify-content: center;
  position: relative;
  align-items: center;
  text-align: center;
}

.title {
  text-align: center;
}


summary {
  background: url("../images/pink-bubble-question.svg");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--secondaryColorTwo);
  border-radius: 10px;
  list-style: none;
  cursor: pointer;
  display: block;
  text-align: center;
  font-family: 'Space Grotesk', sans-serif;
}

details .answerOne,
details .answerTwo,
details .answerThree,
details .answerFour,
details .answerFive {
  background: url("../images/black-bubble-answer.svg");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--secondaryColorTwo);
  margin-top: 10px;
  max-width: 100%;
  text-align: right;
  display: none;
  word-wrap: break-word;
  font-family: 'Work Sans', sans-serif;
  text-align: center;
}

details[open] .answerOne,
details[open] .answerTwo,
details[open] .answerThree,
details[open] .answerFour,
details[open] .answerFive {
  display: block;
  word-wrap: break-word;
}

footer {
  flex-direction: column;
  text-align: center;
  padding: 15px;
}

.social-icons {
  justify-content: center;
  gap: 15px;
  margin-top: 10px;
}

}

/* mobile */
@media (max-width: 480px) {

  body {
    width: 100%;
  }

  .hambMenu {
    display: flex;
    position: fixed;
    top: 0;
    right: 0;
    z-index: 300;
    width: 100vw;
    justify-content: space-between;
   }
  
  .logoHamb {
    z-index: 1000;
  }
  
  /* checkbox to a toggle */
  
  .toggle {
    width: 60px;
    height: 60px;
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    opacity: 0;
    cursor: pointer;
    color: var(--primaryColor);
  }
  
  /* hamburger icons */
  
  .hamburger {
    position: absolute;
    top: 0;
    right: 20;
    z-index: 1;
  
    /* style the square */
    width: 30px;
    height: 60px;
    background: transparent;
    padding: 0;
  
    /* flex to center content */
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  /* hamburger lines */
  .hamburger > div {
    position: relative;
    width: 100%;
    height: 2px;
    background-color: var(--secondaryColorTwo);
    transition: all 0.5s ease;
  }
  
  /* no need for the toggle to move on hover as theres no hover effect on tablets or mobile */
  /* .toggle:checked:hover + .hamburger > div {
    transform: rotate(225deg);
  } */
  
  .hamburger > div::before, 
  .hamburger > div::after {
    content: "";
    position: absolute;
    z-index: 1;
    width: 100%;
    height: 2px;
    background-color: var(--secondaryColorTwo);
  } 
  
  .hamburger > div::before {
    top: -10px
  }
  
  .hamburger > div::after {
    top: 10px;
  }
  
  /* change the hamburger state to the X */
  .toggle:checked + .hamburger > div {
    transform: rotate(135deg);
  }
  
  .toggle:checked + .hamburger > div::before,
  .toggle:checked + .hamburger > div::after {
    top: 0;
    transform: rotate(90deg);
  }
  
  /* link my hb to menu */
  .toggle:checked ~ .menu {
    visibility: visible;
    position: fixed;
  }
  
  .toggle:checked ~ .menu > div {
    transform: scale(1);
    transition-duration: var(0.75s);
  }
  
  .toggle:checked ~ .menu > div > div {
    opacity: 1;
  }
  
  /* style menu links */
  .menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
  
    /* hide menu */
    visibility: hidden;
    overflow: hidden;
  }
  /* overlay */
  .menu > div {
    background-color: var(--primaryColor);
    /* turn into a circle */
    border-radius: 50%;
    width: 500%;
    height: 500vw;
  
    /* put overlay in the center */
    display: flex;
    flex: none;
    justify-content: center;
    align-items: center;
  
    /* animation when appears */
    transform: scale(0);
    transition: all 1s ease;
  }
  
  /* links */
  .menu > div > div {
    text-align: center;
    max-width: 90vw;
    max-height: 100vh;
  
    /* animation */
    opacity: 0;
    transition: all 0.3s ease;
  
  }
  
  .menu > div > div > ul {
    padding: 0;
  }
  
  .menu > div > div > ul > li {
    list-style: none;
    padding: 0;
  }
  .menu > div > div > ul > li > a {
    font-family:"Space Grotesk", sans-serif; ;
    text-decoration: none;
    color: var(--secondaryColorTwo);
    font-size: 1.5rem;
  }
  
  .logo {
    justify-content: left;
    margin: 0;
  }
  
   .link-item {
    display: none;
   }
  
   .dropdown {
    display: none;
   }
  
   .pageHeading {
    display: none;
   }
  .navbar {
    padding: 0;
  }

  /* this responsive section was the most challenging */

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

  h2 {
    text-align: center;
  }

  h3 {
    text-align: center;
  }


  .about {
    gap: 10px;
    padding: 0%;
  }

  .about-faq {
    gap: 10px;
    padding: 0;
    margin: 0%;
    width: 100%;
  }

  details {
    width: 100%;
  }

  summary {
    background: url("../images/pink-bubble-question.svg");
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    color: var(--secondaryColorTwo);
    border-radius: 10px;
    list-style: none;
    display: block;
    max-width: 100%;
    text-align: center;
    font-family: 'Space Grotesk', sans-serif;
  }

  details .answerOne,
  details .answerTwo,
  details .answerThree,
  details .answerFour,
  details .answerFive {
    background: url("../images/black-bubble-answer.svg");
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    color: var(--secondaryColorTwo);
    border-radius: 10px;
    max-width: 100%;
    text-align: center;
    display: none;
    /* padding-left: 20px;
    padding-right: 30px; */
    word-wrap: break-word;
    font-family: 'Work Sans', sans-serif;
  }

  details[open] .answerOne,
  details[open] .answerTwo,
  details[open] .answerThree,
  details[open] .answerFour,
  details[open] .answerFive {
    display: block;
  }

  footer {
    flex-direction: column;
    text-align: center;
    padding: 10px;
  }

  .social-icons {
    justify-content: center;
    gap: 10px;
    margin-top: 8px;
  }
}

