/* -------------------------------------------------------------------------------- */
/* ! Base */
/* -------------------------------------------------------------------------------- */
/* Tavolozza */
:root {
  --primary: #8d8d8d;
  --secondary: #c7c7c7;
  --accent: #ff0000;
  --light: #ffffff;
  --dark: #000000;
}


/* Reset */
* {
  margin: 0;
  padding: 0;

}

html,
body {
  max-width: 1450px;
  overflow-x: hidden;
}



li {
  list-style-type: none;
  font-size: 10px;
}

/* Tipografia */
body {
  cursor: none;
  font-family: 'Montserrat', sans-serif;
  overflow-x: hidden;
}

a {

  color: black;
  text-decoration-thickness: 1px;
  text-decoration-style: solid;
  text-decoration-line: none;
  text-underline-offset: 2px;
  cursor: none;
}

a:is(:hover, :focus) {
  color: #00f;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Montserrat', sans-serif;
}

h1 {
  font-size: 4.9em;
  font-weight: 100;


}

h2 {
  font-weight: 100;
  font-size: 60px;
  letter-spacing: -4.5px;
  color: #000000;
  margin-bottom: 10px;
}

h3 {
  font-weight: 100;
  font-size: 10px;
  letter-spacing: -0.5px;
  color: #000000;
  margin-bottom: 10px;
}

/* 
a {
  font-size: 2.8em;
  line-height: 0.8em;
  margin-bottom: 0px;
  text-decoration: none;
  color: var(--dark);
  font-weight: 100;
  letter-spacing: -3px;
} */

p {
  font-size: 2.25em;
  line-height: 1.1em;
  margin-bottom: 15px;
  word-spacing: 10px;
  letter-spacing: -2px;
}


ul {
  font-size: 2em;
  line-height: 1.2em;
  margin-bottom: 15px;
}

/*p.leading {
  font-size: 1.4em;
  line-height: 1.4em;
  font-family: 'Inter', sans-serif;
  font-weight: 100;
  letter-spacing: -1px;
  font-size: 1.7em;
}
*/

p span {
  font-weight: 100;
  color: var(--secondary);
}

.cta {
  display: block;
  border: 1px solid var(--primary);
  font-weight: normal;
  color: var(--primary);
  margin: 0 auto;
  padding: 12px;
  border-radius: 12px;
  width: fit-content;
  text-transform: uppercase;
}



.cta:hover {
  background: var(--primary);
  color: var(--light)
}

/* Cursore */

.cursor {
  position: fixed;
  width: 20px;
  height: 20px;
  border: 1px solid black;
  background-color: none;
  border-radius: 50%;
  left: 0;
  top: 0;
  pointer-events: none;
  transform: translate(-50%, -50%);

  z-index: 999;
}

/*
.cursor2 {
  position: fixed;
  width: 8px;
  height: 8px;
  background-color: rgb(0, 0, 0);
  border-radius: 50%;
  left: 0;
  top: 0;
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: .15s;
  z-index: 999;
} */



.body:hover ⁓ .cursor {
  transform: translate(-50%, -50%) scale(1.5);
  background-color: black;
  opacity: .5;
}

/* Colore immagini invertite */

.book__img:hover img {
  filter: invert(100%);
  cursor: none;
  mix-blend-mode: difference;
  cursor: crosshair;
}

.book__img:hover .caption {
  opacity: 1;
}


.book__img2:hover img {
  filter: invert(100%);
  cursor: none;
  mix-blend-mode: difference;
  cursor: crosshair;
}

.book__img2:hover .caption {
  opacity: 1;
}

.book__img3:hover img {
  filter: invert(100%);
  cursor: pointer;
  cursor: none;
  mix-blend-mode: difference;
  cursor: crosshair;
}

.book__img3:hover .caption {
  opacity: 1;
}

.book__img4:hover img {
  filter: invert(100%);
  cursor: pointer;
  cursor: none;
  mix-blend-mode: difference;
  cursor: crosshair;
}

.book__img4:hover .caption {
  opacity: 1;
}

.caption {
  position: relative;
  font-family: 'Courier New', Courier, monospace;
  font-size: 12px;
  font-weight: 500;
  bottom: 0;
  left: -10px;
  width: 100%;
  color: #ff073a;
  padding: 10px;
  opacity: 0;
  transition: opacity 0.3s;
}


/* Riuso */
.res {
  width: 100%;
  max-width: 400px;
}


/* Prova */
/* Tooltip container */
.tooltip {
  position: relative;
  display: inline-block;

  line-height: 1.1em;
  margin-bottom: 0px;
  word-spacing: 10px;
  letter-spacing: -2px;

  /* If you want dots under the hoverable text */
}

/* Tooltip text */
.tooltip .tooltiptext {

  /* Position the tooltip text */
  position: absolute;
  z-index: 1;
  bottom: 0%;
  left: 50%;
  margin-left: 0px;
  /* Fade in tooltip */
  opacity: 0;
  transition: opacity 0.3s;
  font-size: 2.25em;
  line-height: 1.1em;
  margin-bottom: 30px;
  word-spacing: 10px;
  letter-spacing: -2px;
}

/* Tooltip arrow */


/* Show the tooltip text when you mouse over the tooltip container */
.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}


/* -------------------------------------------------------------------------------- */
/* ! Mobile first */
/* -------------------------------------------------------------------------------- */
/* Grid system */

.grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 10px;
  padding: 20px;
}

/*navigazione*/

.site-nav h1 {
  color: var(--dark);
  grid-column: 1/7;
  z-index: 1;
  line-height: 0.9em;
  letter-spacing: -5px;
  margin-bottom: 4px;
  margin-top: 30px;
}

.site-nav__menu {
  grid-column: 9/9;
  list-style: none;
  margin: 0;
  padding: 0;

}


.site-nav__menu li {
  display: inline-block;
}


.site-nav__menu a {
  display: block;
  padding: 10px;
  text-decoration: none;
  color: #333;

}

.site-nav__menu a:hover {
  color: #00f;
}

.site-nav__menu .active {

  color: #00f;
}


.open .site-nav__menu {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: fixed;
  max-height: 100%;
  width: 100%;
  height: 100vh;
  background-color: var(--light);

}

.site-nav__hamburger {
  cursor: pointer;
  grid-column: 7/9;
  justify-self: end;
  z-index: 1;

}

.site-nav__hamburger .fa-solid {
  font-size: 2em;
}

.cover__menu {
  display: inline block;
}



/* Benvenuto */

#welcome h2 {
  grid-column: 1/9;
}

.welcome__text {
  grid-column: 1/9;
}

.welcome__img {
  display: flex;
  grid-column: 1/9;
  justify-content: center;
}

/*book*/
#book h2 {
  grid-column: 1/9;
}


.book__img {
  grid-column: 1/3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 0px;
  margin-left: -20px;
}

.book__img2 {
  grid-column: 2/7;
  display: flex;
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 0px;
  margin-left: 0px;
}

.book__img3 {
  grid-column: 7/9;
  display: flex;
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 0px;
  margin-right: -20px;
}

.book__img4 {
  grid-column: 1/4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 0px;
  margin-left: -110px;

}

/* Porfolio */
#portfolio {
  position: relative;
  background: var(--dark) url(img/compressor.jpg) no-repeat;
  background-size: cover;
}

#portfolio::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--dark);
  opacity: 0.8;
}

#portfolio h2 {
  position: relative;
  z-index: 1;
  color: var(--light);
  text-align: center;
  padding: 12;
}

.portfolio__projects a {
  grid-column: 1/9;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.portfolio__projects a * {
  max-width: 50%;
  display: block;
  margin: 5px;
  z-index: 1;
}

.portfolio__projects h3 {
  border: 1px solid var(--light);
  background: var(--light);
  border-radius: 12px;
  padding: 12px;
  text-align: center;
}

.portfolio__projects h3:hover {
  border: 1px solid var(--light);
  background: none;
}

/*Skills*/
#skills h2 {
  text-align: center;
  padding: 12px;
}

#skills img {
  height: 80px;
}

#skills li {
  grid-column: span 2;
  text-align: center;
  background-color: rgb(240, 240, 240);
  padding: 12px;
}


.btt {
  right: 10px;
  background: none;
  font-size: 25px;
  z-index: 1;
  grid-column: 9/9;
}

.btt__icon {
  color: #8d8d8d;
}

/* ! MEDIA QUERY MOBILE  */

@media (max-width: 768px) {


  .caption {
    opacity: 1;
  }

  .book__img {
    grid-column: 1/7;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
    margin-left: -20px;
  }

  .book__img2 {
    grid-column: 3/9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
    margin-right: -20px;
  }

  .book__img3 {
    grid-column: 1/7;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
    margin-left: -20px;
  }

  .book__img4 {
    grid-column: 5/9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
    margin-right: -20px;
  }

  .prefooter {
    grid-column: 1/8;
  }

  .social {
    grid-column: 1/8;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-right: 0px;
    padding-right: 145px;


  }

  .site-nav h1 {
    margin-top: 50px;
    font-size: 72px;
  }

  .site-nav__menu {
    grid-column: 9/9;
    list-style: none;
    margin-top: 0px;
    margin-right: 0px;
    transform: rotate(90deg);
    -webkit-transform: rotate(00deg);

  }

  .cursor {
    display: none;
    touch-action: none;
  }

  .cursor2 {
    display: none;
    touch-action: none;
  }

}





/* Footer */
#prefooter {
  background-color: var(--light);
}

footer {
  padding: 30px 0;
}

footer * {
  color: var(--dark);
}

.credits {
  grid-column: 1/5;
  display: flex;
  align-items: center;
}

.social {
  grid-column: 7/9;
  display: flex;
  justify-content: space-between;
  align-items: center;
}