@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300..700&display=swap");

/* || RESET */

*,
*::after,
*::before {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

/* || VARIABLES */

:root {
  /* FONTS */
  --FF: "Space Grotesk", serif;

  /* COLORS */
  --BG-COLOR: #fff4e5;
  --BG-SECONDARY-COLOR: #ffbb50;
  --FONT-COLOR: hsl(30, 100%, 10%);
}

/* || UTILITY CLASSES */

.offscreen {
  position: absolute;
  left: -10000px;
}

.nowrap {
  white-space: nowrap;
}

.center {
  text-align: center;
}

/* || GENERAL STYLES */

html {
  scroll-behavior: smooth;
  font-family: var(--FF);
  background-color: var(--BG-COLOR);
}

body {
  min-height: 100vh;
  margin: 0 auto;
}

p {
  line-height: 1.5;
}

a:any-link {
  color: var(--FONT-COLOR);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  color: hsla(31, 100%, 25%, 0.5);
}

/* || HEADER */

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  top: 0;
  z-index: 1;
  background-color: var(--BG-SECONDARY-COLOR);
  height: 75px;
  position: sticky;
  padding: 0 1rem;
  opacity: 0.95;
}

.header__h1 {
  font-size: clamp(5px, 3.75vw, 30px);
  font-weight: 550;
  color: var(--FONT-COLOR);
}

.header__nav {
  font-size: clamp(3px, 3.25vw, 25px);
  font-weight: 350;
}

.header__ul {
  list-style-type: none;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  gap: 1rem;
}

/* || MAIN */

main {
  display: flex;
  flex-flow: column nowrap;
  justify-content: center;
  align-items: center;
  padding: 2rem 3rem 2rem 3rem;
}

/* || HERO */

.hero {
  display: flex;
  flex-flow: column nowrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  scroll-margin-top: 6.5rem;
  margin-bottom: 5rem;
}

.hero__h2 {
  text-align: center;
  color: var(--FONT-COLOR);
  font-size: 2.5rem;
  font-weight: 700;
}

.hero__presentation {
  display: flex;
  flex-flow: row nowrap;
  justify-content: center;
  align-items: center;
  gap: 3rem;
}

.hero__icon {
  font-size: clamp(1rem, 1.5rem + 1vw, 3rem);
  transition: transform 0.3s ease;
}

.hero__icon:hover {
  transform: translateY(-5px);
}

.hero__figure img {
  border-radius: 100%;
  max-height: 350px;
  max-width: 350px;
  box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.5);
}

.hero__p1 {
  color: var(--FONT-COLOR);
  text-align: center;
  max-width: 100ch;
  font-size: clamp(1rem, 0.8rem + 1vw, 1.5rem);
}

.hero__p2 {
  color: var(--FONT-COLOR);
  text-align: center;
  max-width: 100ch;
  font-size: clamp(1rem, 0.8rem + 1vw, 1.5rem);
}

/* || MEDIA QUERY FOR MOBILE DEVICES */

@media (max-width: 768px) {
  .hero__presentation {
    display: flex;
    flex-flow: column nowrap;
  }

  .hero__figure {
    order: 1;
  }

  .hero__icon {
    order: 2;
    transition: transform 0.3s ease;
  }

  .hero__icon:hover {
    transform: translateY(-5px);
  }

  .hero__figure img {
    border-radius: 100%;
    max-height: 275px;
    max-width: 275px;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.5);
  }

  .hero__presentation {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    justify-items: center;
  }

  .hero__figure {
    grid-column: 1 / -1;
  }
}

/* || SKILLS */

.skills {
  display: flex;
  flex-flow: column nowrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  max-width: max-content;
  margin-bottom: 5rem;
  scroll-margin-top: 15rem;
}

/* || SEPARATOR */

.separator {
  border: 1.5px dashed var(--FONT-COLOR);
  border-radius: 5px;
  margin: 0 auto;
  width: 100%;
}

.skills__container {
  display: flex;
  flex-flow: row wrap;
  gap: 2rem;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

@media (max-width: 768px) {
  .skills__container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 0.5rem;
    justify-items: center;
  }
}

.skills__icon {
  font-size: clamp(50px, 10vw, 75px);
  color: var(--FONT-COLOR);
  transition: transform 0.3s ease;
}

.skills__icon:hover {
  color: hsla(31, 100%, 25%, 0.5);
  transform: translateY(-5px);
}

/* || PROJECTS */

.projects {
  width: 100%;
  scroll-margin-top: 6.5rem;
  margin-bottom: 5rem;
}

.projects__h2 {
  text-align: center;
  color: var(--FONT-COLOR);
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 2rem;
}

.projects__container {
  display: flex;
  gap: 2rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}

.projects__card {
  min-width: 400px;
  max-width: 400px;
  height: 450px;
  background-color: var(--BG-SECONDARY-COLOR);
  border-radius: 12px;
  overflow: hidden;
  scroll-snap-align: start;
  box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  position: relative;
}

.projects__card:hover {
  transform: translateY(-5px);
}

.projects__img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.projects__content {
  padding: 1rem;
  height: calc(100% - 200px);
}

.projects__title {
  color: var(--FONT-COLOR);
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.projects__description {
  color: var(--FONT-COLOR);
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

@media (max-width: 768px) {
  .projects__card {
    min-width: 275px;
    max-width: 275px;
    height: 450px;
    background-color: var(--BG-SECONDARY-COLOR);
    border-radius: 12px;
    overflow: hidden;
    scroll-snap-align: start;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
    position: relative;
  }
  .projects__title {
    color: var(--FONT-COLOR);
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
  }
  .projects__description {
    color: var(--FONT-COLOR);
    font-size: 1rem;
    margin-bottom: 1rem;
  }
}

.projects__skills {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  display: flex;
  gap: 0.75rem;
  font-size: 1.5rem;
}

.projects__i {
  color: var(--FONT-COLOR);
}

/* || CONTACT */

.contact {
  display: flex;
  flex-flow: column nowrap;
  justify-content: center;
  align-items: center;
  scroll-margin-top: 6.5rem;
  margin-bottom: 5rem;
}

.contact__icon {
  font-size: clamp(50px, 10vw, 75px);
  color: var(--FONT-COLOR);
  margin-bottom: 2rem;
}

.contact__h2 {
  text-align: center;
  color: var(--FONT-COLOR);
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 2rem;
}

.contact__container {
  position: relative;
  display: flex;
  flex-flow: row nowrap;
  justify-content: center;
  align-items: center;
  width: 100%;
  gap: 2rem;
  padding: 0 1rem;
}

.contact__decoration-left,
.contact__decoration-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  font-size: clamp(1rem, 1.5rem + 1vw, 3rem);
  color: var(--FONT-COLOR);
  opacity: 0.5;
  padding: 2rem;
}

.contact__decoration-icon {
  transition: transform 0.3s ease;
}

.contact__decoration-icon:hover {
  transform: translateY(-5px);
  opacity: 1;
}

@media (max-width: 750px) {
  .contact__decoration-left,
  .contact__decoration-right {
    display: none;
  }
}

.contact__form {
  flex: 0 1 600px;
}

.contact__fieldset {
  border: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact__p {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.contact__input,
.contact__textarea {
  padding: 0.75rem;
  border: 2px solid var(--FONT-COLOR);
  border-radius: 8px;
  background-color: white;
  font-family: var(--FF);
  font-size: clamp(1rem, 0.8rem + 1vw, 1.5rem);
  color: var(--FONT-COLOR);
}

.contact__textarea {
  resize: vertical;
  min-height: 150px;
}

.contact__input::placeholder,
.contact__textarea::placeholder {
  color: #999;
}

.contact__submit {
  background-color: var(--BG-SECONDARY-COLOR);
  color: var(--FONT-COLOR);
  border: none;
  border-radius: 8px;
  padding: 0.75rem;
  font-family: var(--FF);
  font-size: clamp(1rem, 0.8rem + 1vw, 1.5rem);
  cursor: pointer;
  transition: transform 0.3s ease;
}

.contact__submit:hover {
  transform: translateY(-5px);
}

/* || FOOTER */

footer {
  bottom: 0;
  width: 100%;
}

.footer__p {
  background-color: var(--BG-SECONDARY-COLOR);
  color: var(--FONT-COLOR);
  text-align: center;
  font-size: clamp(1rem, 0.8rem + 1vw, 1.5rem);
}
