/*jaime.r.c@hotmail.com*/
/*https://www.w3schools.com/cssref/tryit.php?filename=trycss_cursor, editor de cursors*/
/*https://getbootstrap.com/docs/4.0/components/carousel/ carrusel boostrap*/
@font-face {
    font-family: 'PPMori';
    src: url("../../PPMori-Regular.otf") format('truetype');
}
body{
    font-family: "PPMori", sans-serif;
    background-color: #edede9;   
    cursor: none;     
    z-index: 0;
}
a{
    text-decoration: none;
    color: black;
}
#inici {
  height: 100vh;            /* ocupa tota l’alçada de la pantalla */
  display: flex;            /* centrem el contingut */
  justify-content: center;  /* horitzontal */
  align-items: center;      /* vertical */
}
#inici h2 {
  font-size: 8vw;              /* text gran i responsive */
  margin: 0;
  line-height: 1.2;
  text-align: center;          /* centra el text */
}
#treballs {
  padding-top: 100px; /* separació respecte al #inici */
}
article{
    position: relative;
    overflow: hidden;
    width: 60%;           
    margin: 50px auto;
    min-height: 400px;
}
article p{
    position: relative;
    margin-top: 50px;   
    text-align: center;
}
article .carrusel {
  position: relative;
  width: 100%;
  overflow: hidden;
  min-height: 500px;
}
article .carrusel img{
    position: absolute;   
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.1s ease;
}
article .carrusel img.actiu{
      opacity: 1;
      position: relative;
}
article .click-zone {
      position: absolute;
      top: 0;
      width: 50%;
      height: 100%;
      cursor: pointer;
      z-index: 2;
}
.left {
      left: 0;
 }
.right {
      right: 0;
}
.indicadors {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 25px;
}

.indicadors .dot {
  width: 10px;
  height: 10px;
  background-color: #bbb;   /* gris suau */
  border-radius: 50%;
  transition: background-color 0.1s ease;
}

.indicadors .dot.actiu {
  background-color: #000;   /* negre per al punt actiu */
}
img{
    display:block;
    margin-left: auto;
    margin-right:auto;
} 
header{
    padding: 20px;
    position: sticky;
    top: 0;
    z-index: 1;
}
nav ul{
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: space-between;
}
article{
    align-content: center;
}
.sobremi{
  display: grid;
  grid-auto-rows: max(750px);
  grid-template-columns: 1fr 1fr;
  grid-gap: 30px;
  gap: 30px;
  margin: 50px 0px;
  padding: 50px 25px;
  }
.imatge{
    grid-column: 1;
}
.descripcio{
    grid-column: 2;
}
footer{
    text-align: center;
}
.cursor-invert {
  position: fixed;
  top: 0;
  left: 0;
  width: 25px;              /* mida del cercle d'inversió */
  height: 25px;
  border-radius: 50%;        /* forma circular */
  pointer-events: none;      /* no bloqueja els clics */
  background: white;
  mix-blend-mode: difference;/* inverteix els colors */
  transform: translate(-50%, -50%);
  z-index: 9999;
}
/* ===== MODAL PROJECTES ===== */

.modal {
  display: none;
  position: fixed;
  inset: 0; /* equival a top:0; right:0; bottom:0; left:0 */
  background: rgba(0, 0, 0, 0.6);
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

/* Quan el modal està actiu */
.modal.visible {
  opacity: 1;
}

/* Contingut del modal */
.modal-content {
  background: #fff;
  padding: 3rem;
  max-width: 700px;
  width: 90%;
  text-align: left;
  position: relative;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
  transform: translateY(20px);
  transition: transform 0.3s ease;
}

/* Efecte "slide-up" quan s’activa */
.modal.visible .modal-content {
  transform: translateY(0);
}

/* Botó de tancament */
.modal .close {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  font-size: 2rem;
  cursor: pointer;
  color: #333;
  transition: transform 0.2s;
}

.modal .close:hover {
  transform: scale(1.2);
}

/* Text dins del modal */
.modal-text h3 {
  margin-top: 0;
  font-size: 1.6rem;
  color: #111;
}

.modal-text p {
  font-size: 1rem;
  line-height: 1.6;
  color: #333;
}
.projecte-info {
  cursor: pointer;
  transition: opacity 0.1s ease;
}
.projecte-info:hover {
  opacity: 0.1;
}
