*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  user-select: none;
}

:root {
  /* --ff-primary: "Source Code Pro", monospace; */
  --ff-primary: "Roboto", sans-serif;
  --ff-primary-light: "Roboto Light", sans-serif;
  --ff-secondary: "Roboto", sans-serif;

  --ff-light: 300;
  --ff-reg: 400;
  --ff-bold: 900;

  --clr-light: #ebfffd;
  --clr-dark: #051111;
  --clr-accent: #72e2bd;

  --fs-h1: 3rem;
  --fs-h2: 2.25rem;
  --fs-h3: 1.25rem;
  --fs-body: 1rem;

  --right-gradient: linear-gradient(
    to right,
    rgba(100, 199, 223, 0.3),
    rgb(114, 226, 189)
  );

  --top-gradient: linear-gradient(
    to top,
    rgba(100, 199, 223, 0.5),
    rgb(114, 226, 189)
  );

  --bs: 0.25em 0.25em 0.75em rgba(0, 0, 0, 0.25),
    0.125em 0.125em 0.25em rgba(0, 0, 0, 0.15);
}

@media (min-width: 800px) {
  :root {
    --fs-h1: 4.5rem;
    --fs-h2: 3.75rem;
    --fs-h3: 1.5rem;
    --fs-body: 1.125rem;
  }
}

/* General Styles */

body {
  background: var(--clr-dark);
  color: var(--clr-light);
  margin: 0;
  font-family: var(--ff-primary);
  font-size: var(--fs-body);
  line-height: 1.6;
}

section {
  padding: 5em 2em;
}

img {
  display: block;
  max-width: 100%;
}

:focus {
  outline: 3px solid var(--clr-accent);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  line-height: 1;
  margin: 0;
}

h1 {
  font-size: var(--fs-h1);
}
h2 {
  font-size: var(--fs-h2);
}
h3 {
  font-size: var(--fs-h3);
}

.section__title {
  margin-bottom: 0.25rem;
}

.section__title--intro {
  font-weight: var(--ff-bold);
  text-shadow: 1px 1px var(--clr-accent);
}

.section__title--intro strong {
  display: block;
}

.section__subtitle {
  margin-bottom: 0;
  font-size: var(--fs-h3);
  text-shadow: 1px 2px var(--clr-dark);
}

.section__subtitle--intro,
.section__subtitle--about,
.section__subtitle--tech {
  display: inline-block;
  background: var(--right-gradient);
  font-family: var(--ff-secondary);
  padding: 0.25em 1em;
  margin-bottom: 1em;
  border-radius: 6px;
}

/* Scroll Animation */

/* .scroll-animation {
  opacity: 0;
  filter: blur(5px);
  transform: translateX(-100%);
  transition: all 1s;
}

.visible {
  opacity: 1;
  filter: blur(0);
  transform: translateX(0);
} */

/* Intro Animation */

/* .colour-segment:nth-child(1) {
  transition-delay: 600ms;
}
.colour-segment:nth-child(2) {
  transition-delay: 200ms;
}
.colour-segment:nth-child(3) {
  transition-delay: 400ms;
} */

/* Technologies Animation */
/* .tech:nth-child(1) {
  transition-delay: 800ms;
}
.tech:nth-child(2) {
  transition-delay: 600ms;
}
.tech:nth-child(3) {
  transition-delay: 400ms;
}
.tech:nth-child(4) {
  transition-delay: 200ms;
} */

/* About me Animation */
/* .about-segment:nth-child(1) {
  transition-delay: 400ms;
}
.about-segment:nth-child(2) {
  transition-delay: 200ms;
}
.about-segment:nth-child(3) {
  transition-delay: 400ms;
}
.about-segment:nth-child(4) {
  transition-delay: 500ms;
} */

/* Footer Animation */

/* .footer-segment:nth-child(1) {
  transition-delay: 700ms;
}
.footer-segment:nth-child(2) {
  transition-delay: 500ms;
}
.footer-segment:nth-child(3) {
  transition-delay: 300ms;
}
.footer-segment:nth-child(4) {
  transition-delay: 150ms;
} */

/* Header */

header {
  display: grid;
  justify-content: right;
  padding: 1em;
}

/* Nav */

.topnav {
  overflow: hidden;
  background-color: var(--clr-dark);
  font-size: var(--fs-h3);
  position: absolute;
  right: 10px;
}

.topnav a {
  float: left;
  display: block;
  color: var(--clr-light);
  /* text-shadow: 1px 1px var(--clr-accent); */
  text-align: center;
  text-decoration: none;
  font-family: var(--ff-primary-light);
  font-size: var(--fs-h3);
  font-weight: var(--ff-light);
  padding: 0.25em 1em;
  border-radius: 6px;
}

.topnav a:hover {
  background-color: var(--clr-accent);
  color: var(--clr-dark);
  font-weight: var(--ff-bold);
  /* text-shadow: 1px 1px var(--clr-light); */
  transition: 0.5s ease;
}

@media (max-width: 700px) {
  .topnav {
    display: none;
  }
}

/* Intro */

.intro {
  position: inherit;
}

.intro__img {
  box-shadow: 1px 1px 5px var(--clr-accent);
  border-radius: 6px;
  max-width: 70%;
}

.section__minititle {
  display: none;
}

@media (min-width: 700px) {
  .intro {
    display: grid;
    width: min-content;
    min-height: 650px;
    margin: 7em auto;
    grid-column-gap: 2em;
    grid-row-gap: 2em;
    grid-template-areas:
      "img title"
      "img subtitle";
    grid-template-columns: min-content max-content;
  }

  .section__title--intro {
    margin-top: 0.9em;
  }

  .section__minititle {
    display: contents;
  }

  .intro__img {
    grid-area: img;
    min-width: 250px;
    position: relative;
    z-index: 2;
  }

  .section__minititle {
    font-family: var(--ff-primary-light);
    font-size: var(--fs-h3);
    font-weight: var(--ff-light);
  }

  .section__subtitle--intro {
    align-self: start;
    grid-column: -1 / 1;
    grid-row: 2;
    text-align: right;
    position: relative;
    top: -100px;
    left: -1.5em;
    height: 3rem;
    width: calc(100% + 1.5em);
    background: var(--right-gradient);
    content-visibility: hidden;
  }

  .section__subtitle--tech {
    margin-left: 1em;
  }
}

/*  */
/* Technologies */
/*  */
.tech_container {
  display: flex;
  flex-wrap: wrap;
  background-color: var(--clr-light);
}

.tech_left {
  flex: 1;
  display: flex;
  flex-wrap: wrap;
}

.tech_right {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.tech {
  width: 100px;
  height: 100px;
  margin: 10px;
}

.image {
  height: auto;
  width: auto;
}

.section__subtitle--tech {
  background: var(--right-gradient);
  /* display: block; */
  height: 3rem;
  width: calc(100% + 1.5em);
  content-visibility: hidden;
}

@media (max-width: 800px) {
  .tech_container {
    display: flex;
    flex-wrap: wrap;
  }

  .tech_left {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  .tech_right {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .tech {
    width: 100px;
    height: 100px;
    margin: 100px;
    justify-content: center;
    margin-bottom: 1rem;
  }

  .image {
    max-width: 100%;
    height: auto;
  }
  .tech_right {
    display: none;
  }

  .tech_left {
    flex-basis: 100%;
  }
  .section__title-tech {
    display: none;
  }

  .tech_wrapper {
    justify-content: center;
  }
  .section__subtitle--tech {
    background: var(--right-gradient);
    font-size: var(--fs-h2);
    color: var(--clr-dark);
    text-shadow: 1px 1px 1px var(--clr-light);
    font-weight: var(--ff-bold);
    margin-top: -0.5em;
    height: 4rem;
    margin-left: 0.1em;
    margin-bottom: 0.2em;
    width: 100%;
    content-visibility: visible;
    text-align: center;
  }
}
/*  */
/* Technologies */
/*  */

/* Technologies */

.section__title-tech {
  color: var(--clr-dark);
  position: relative;
  /* top: -20px; */
  margin-left: 0.4em;
  text-shadow: 1px 1px var(--clr-light);
}

.tech_text {
  color: var(--clr-dark);
  font-size: var(--fs-body);
  margin-top: -13px;
  display: block;
  text-align: center;
  width: 140%;
}

.my-tech {
  display: flex;
  flex-wrap: wrap;
  background-color: var(--right-gradient);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: right;
  color: var(--clr-accent);

  text-align: center;
  width: 100%;
  height: auto;
}

@media (max-width: 870px) {
  .section__subtitle--intro {
    color: var(--ff-light);
  }

  .tech__item {
    justify-content: center;
  }
}

.pc-image {
  padding: 10px;
  display: grid;
}

.tech {
  margin-left: -1em;
  padding-bottom: 100px;
  min-width: 50px;
  margin: 20px 10px 20px 20px;
  float: left;
}

.tech__item {
  background-color: transparent;
  border-radius: 10px;
  box-shadow: 1px 1px 2px 2px var(--clr-accent);
  padding: 20px;
  margin: 20px;
}

.tech__item:hover {
  background-color: var(--clr-accent);
  transition: 0.4s;
}

/* About Me */

.about-me {
  max-width: 1000px;
  margin: 0 auto;
}

.about-me__body {
  background: var(--clr-dark);
  color: var(--clr-light);
  font-family: var(--ff-secondary);

  margin-bottom: 2em;
  max-width: 1000px;
  margin: 0 auto;
}

.about-me__img {
  box-shadow: 3px 2px 4px var(--clr-accent);
  border-radius: 6px;
}

/* NFT image 140% on large screens */
@media (min-width: 1272px) {
  .about-me__img {
    max-width: 140%;
  }

  .tech_wrapper {
    padding-bottom: 10em;
  }
}

@media (min-width: 870px) {
  .about-me {
    display: grid;
    grid-template-columns: 1fr 300px;
    grid-template-areas:
      "title img"
      "subtitle img"
      "text img";
    grid-column-gap: 3em;
  }

  .section__title--about {
    grid-area: title;
    color: var(--clr-light);
    text-shadow: 0.5px 1px var(--clr-accent);
  }

  .section__subtitle--about {
    text-align: left;
    grid-column: 1 / -1;
    grid-row: 2;
    position: relative;
    left: -1em;
    width: calc(100% + 2em);
    padding-left: 1em;
    padding-right: calc(
      200px + 4em
    ); /* img size + 4em, so image doesn't affect text */
  }

  .about-me__img {
    top: 30px;
    grid-area: img;
    position: relative;
    z-index: 2;
  }
}

/* Projects */

.project_wrapper {
  display: flex;
  width: 100%;
  justify-content: space-around;
}

.card {
  width: 380px;
  height: 200px;
  justify-content: center;
  border-radius: 15px;
  margin: 1rem;
  padding: 1.5rem;
  background: white;
  position: relative;
  display: flex;
  align-items: flex-end;
  transition: 0.4s ease-out;
  box-shadow: 0px 7px 10px rgba(0, 0, 0, 0.5);
}
.card:hover {
  transform: translateY(-20px);
}
.card_opacity:hover:before {
  opacity: 1;
}
.card:hover .card_content {
  opacity: 1;
  transform: translateY(0px);
}
.card:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 15px;
  background: rgba(0, 0, 0, 0.6);
  z-index: 2;
  transition: 0.5s;
  opacity: 0;
}
.card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  border-radius: 15px;
}

.card .card_content {
  position: relative;
  z-index: 3;
  color: var(--clr-light);
  opacity: 0;
  transform: translateY(-5px);
  transition: 0.5s;
}

.card .project_name {
  background-color: var(--clr-dark);
  color: var(--clr-accent);
  text-shadow: 0.8px 0.6px var(--clr-light);

  border-radius: 10px;
  font-size: 2.5rem;
  font-weight: var(--ff-bold);
  margin: 0px;
}

.card .card_btn {
  padding: 0.7rem;
  outline: none;
  border: none;
  margin: 15px 15px auto;
  border-radius: 10px;
  box-shadow: 2px 0 1px 0 var(--clr-accent);
  background: var(--clr-dark);
  color: var(--clr-accent);
  font-weight: bold;
  cursor: pointer;
  transition: 0.4s ease;
  text-shadow: 0.2px 0.2px var(--clr-light);
}

.card .card_content button:hover {
  color: var(--clr-dark);
  background-color: var(--clr-accent);
  text-shadow: 0.2px 0.2px var(--clr-light);
}

.google {
  padding-left: 0.3em;
  padding-right: 0.3em;
}

.cert {
  cursor: pointer;
}

.projects {
  background-color: var(--clr-accent);
  color: var(--clr-dark);
  text-align: center;
}

.portfolio {
  display: grid;
  grid-template-columns: repeat(4, 300px);
  margin: 0 auto;
}

@media (min-width: 350px) {
  .portfolio {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    margin: 10px auto;
  }

  .my-tech {
    width: 100%;
    height: auto;
  }
}

@media (max-width: 870px) {
  .portfolio {
    display: table;
    position: relative;
    max-width: 400px;
    margin: 0 auto;
  }
}

.portfolio__item {
  background-color: var(--clr-light);
  margin: 10px 10px auto;
  overflow: hidden;
}

.portfolio__wait {
  cursor: wait;
}

.project_section__title {
  margin-top: -40px;
  margin-bottom: 40px;
  color: var(--clr-dark);
  text-shadow: 1px 1px var(--clr-light);
}

.project_section__title::after {
  content: "";
  display: block;
  width: 10%;
  height: 1px;
  margin: 0.5em auto 1em;
  margin-bottom: 0px;
  background: var(--clr-dark);
  opacity: 0.5;
}

/* Contact */

.contact_form {
  margin-top: 2rem;
}

.form_control {
  font-size: 15px;
  border-top: 15px solid transparent;
}

.input-field:focus::placeholder {
  color: transparent;
}

.input-field::placeholder {
  color: #222;
  transition: color 0.3s ease;
}

.contact_title {
  text-align: center;
  margin-top: -100px;
  padding: 1em;
  color: var(--clr-light);
  text-shadow: 1px 1px var(--clr-accent);
}

.section__title-contact::after {
  content: "";
  display: block;
  width: 10%;
  height: 1px;
  margin: 0.5em auto 1em;
  margin-bottom: 0px;
  background: var(--clr-accent);
  opacity: 0.5;
}

.contact_form_container {
  background-color: var(--clr-dark);
  max-width: 40rem;
  margin: 0 auto;
  padding: 1rem;
  border-radius: 6px;
  box-shadow: 5px 10px 15px var(--clr-accent);
}

.contact_form_container label {
  line-height: 3em;
}

.contact_form_container textarea {
  min-height: 6.25rem;
  font-size: 14px;
}

.contact_form_container .input-field {
  background-color: var(--clr-light);
  width: 100%;
  padding-top: 10px;
  padding-bottom: 10px;
  border-radius: 6px;
  border: 2px outset;
  font-size: 1rem;
  text-indent: 5px;
  outline: none;
}

.input,
textarea {
  font: 2em;
  border: none;
  padding: 10px 1px;
}

.input-field::placeholder {
  position: absolute;
}

.submit_btn {
  width: 100%;
  padding: 8px;
  margin: 5px 0;
  background-color: var(--clr-light);
  border: 2px solid var(--clr-accent);
  border-radius: 6px;
  font-size: 1rem;
  font-weight: var(--ff-bold);
}

.submit_btn:hover {
  background-color: var(--clr-accent);
  border: 2px solid var(--clr-accent);
  cursor: pointer;
  transition: ease 0.5s;
}
/* Footer */

.footer {
  background: var(--clr-dark);
  color: var(--clr-accent);
  text-align: center;
  padding: 2.5 em 0;
  font-size: var(--fs-h3);
  font-weight: var(--ff-bold);
}

.footer a {
  color: inherit;
  text-decoration: none;
}

.footer__link:hover,
.social_list__link:hover {
  opacity: 0.6;
}

.social_list {
  list-style: none;
  display: flex;
  justify-content: center;
  padding: 0;
  margin-top: -20px;
}

.copy {
  font-weight: var(--ff-reg);
  font-size: 0.5em;
  padding: 1.25rem;
  margin: 2rem 0 0;
}

.social_list_item {
  margin: 0 0.5em;
}

.social_list__link {
  padding: 1em;
}
