/* ========== Reset & global ========== */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Instrument Serif', serif;
  background: rgb(255, 255, 255);
  color: #000000;
}

/* ========== Boutons fixes (nav) ========== */
.home-button_me, .contact-button, .autres-button {
  position: fixed;
  top: 20px;
  z-index: 1000;
  font-size: 1.2rem;
  font-weight: bold;
  text-decoration: none;
  padding: 0.4rem 1rem;
  border-radius: 8px;
  transition: color 0.3s;
  color: #000;
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: 'Instrument Serif', serif;
}

.home-button_me { left: 20px; }
.contact-button { right: 120px; }
.autres-button { right: 20px; }

.home-button_me:hover,
.contact-button:hover,
.autres-button:hover { 
  color: rgb(186, 182, 182); 
  font-style: italic;
}


/* menu déroulant flottant */
.floating-dropdown {
  position: absolute;
  display: none;
  background: rgb(255, 255, 255);
  border-radius: 6px;
  min-width: 160px;
  z-index: 2000;
  overflow: hidden;
  font-family: inherit;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
}
.floating-dropdown a {
  display: block;
  padding: 10px 14px;
  text-decoration: none;
  color: #000000;
  font-weight: 600;
}
.floating-dropdown a:hover {
  background: #000000;
  color: #fff;
}

/* ========== Intro (plein écran) ========== */
.intro {
  position: relative;
  min-height: 100vh;              /* prend tout l'écran */
  display: flex;
  flex-direction: column;
  justify-content: center;       /* centre verticalement le contenu */
  align-items: center;           /* centre horizontalement */
  text-align: center;
  padding: 40px 20px;
}

body {
  overflow-x: hidden;        /* on empêche le scroll horizontal */
}

.sticker {
  position: absolute;
  cursor: grab;
  transition: opacity 0.3s, transform 0.2s;
  opacity: 0;
  user-select: none; /* empêche la sélection du texte sur mobile */
  touch-action: none; /* pour le drag sur mobile */
}

.sticker.show {
  opacity: 1;
}

.sticker:active {
  cursor: grabbing;
  transform: scale(1.1);
}

/* titre / paragraphe / bouton */
h1 {
  font-size: clamp(40px, 10vw, 120px); /* responsive */
  line-height: 0.9;
  margin-bottom: 0px; /* contrôle espace sous h1 */
}
h1 .star { font-family: Helvetica, sans-serif; font-size: 0.9em; margin-left:0px; }

p {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  margin: 0 0 25px 0;    /* réduit espace avant le bouton */
  font-size: clamp(10px, 4vw, 20px);
}


/* Effet machine à écrire d'entrée pour l'intro */
#intro-title {
  display: inline-block;
  white-space: nowrap;
  overflow: hidden;
  border-right: 2px solid black; /* curseur */
  font-size: clamp(40px, 10vw, 120px);
  line-height: 0.9;
  transition: border-color .2s linear;
}

@keyframes blink {
  0%, 100% { border-color: black; }
  50%     { border-color: transparent; }
}
#intro-title { animation: blink 0.8s step-end infinite; }

/* subtitle + bouton apparaissent après la frappe */
#intro-subtitle,
.work-button {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}
#intro-subtitle.show,
.work-button.show {
  opacity: 1;
  transform: translateY(0);
}

.hidden {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

.show {
  opacity: 1;
  transform: translateY(0);
}


/* Work button */
.work-button {
  position: relative;
  text-decoration: none;
  display: inline-block;
  padding: 10px 50px;
  background: rgb(255, 255, 255);
  color: black;
  border: 1px solid black;
  border-radius: 999px;
  font-family: 'Libre Baskerville', serif;
  font-weight: 500;
  font-size: clamp(10px, 2vw, 20px);
  transition: background 0.3s ease, color 0.3s ease;
  overflow: hidden;
}


/* pseudo-élément flèche */
.work-button::after {
  content: "↓"; /* flèche vers le bas */
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  font-size: 1em;
  color: rgb(255, 255, 255); /* couleur de la flèche */
}

/* Hover : changer background et texte invisible, flèche visible */
.work-button:hover {
  background: black; /* background devient noir */
  color: transparent; /* texte disparaît */
}

.work-button:hover::after {
  opacity: 1; /* flèche apparaît */
}

.work-button:hover { opacity: .9; }



/* ========== Projects (apparaît après scroll) ========== */
.projects {
  max-width: 1400px;
  margin: 100px auto;
  padding: 0 20px;
  column-count: 4; /* 4 colonnes comme Pinterest */
  column-gap: 5px; /* espace entre colonnes */
}

.card {
  position: relative;
  display: block;
  margin-bottom: 5px; /* espace entre les images des colonnes, en mode horizontal la */
  break-inside: avoid; /* important pour empêcher les coupures d'image */
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.card img {
  width: 100%;
  display: block;
  border-radius: 0; /* bords carrés */
}

.card:hover img {
  filter: brightness(0.6);
}


.card-title {
  position: absolute;
  top: 15px;
  left: 15px;
  width: 100%;
  color: white;
  font-family: 'Instrument Serif', serif;
  font-size: 1.2rem;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none; /* pour que le hover reste fluide */
}

/* Faire apparaître le titre des projets */
.card:hover .card-title {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive - moins de colonnes selon la taille */
@media (max-width: 1200px) {
  .projects { column-count: 3; }
}

@media (max-width: 900px) {
  .projects { column-count: 2; }
}

@media (max-width: 500px) {
  .projects { column-count: 1; }
}






/* style des pages projets */

  .projet-layout {
  display: grid;
  grid-template-columns: 70% 30%;
  max-width: 1400px;
  margin: 0 auto;
  height: 100vh;
  gap: 0;
}

/* Colonne gauche : scrollable mais sans barre visible */
.projet-gauche {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  overflow-y: auto;
  padding: 4.5rem 1.3rem 1.3rem; /* <-- padding top augmenté pour laisser Yiru visible */
  scroll-behavior: smooth;
  
  /* Cache la scrollbar visuellement */
  scrollbar-width: none; /* Firefox */
}
.projet-gauche::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Edge */
}

.projet-gauche img {
  width: 100%;
  object-fit: cover;
  border-radius: 0;
  display: block;
}

/* Galerie verticale */
.projet-galerie {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}


/* Colonne droite avec le texte */
.projet-droite {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 100vh;
  padding: 4.5rem 1.8rem 5rem 0.8rem;
  overflow: hidden;   
}

.projet-titre {
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 0.4rem; /* espace entre titre et texte */
  text-align: left; /* aligne le titre à gauche */
}

.projet-date {
  font-size: 1rem;
  color: #666; /* gris clair */
  margin-bottom: 45px; /* espace avant les infos */
  text-align: left;
}

.projet-label {
 font-size: 1.4rem;
 font-style: italic;
 font-weight: bold;
 margin-bottom: 3px;
}


.projet-contenu {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 1rem;
  letter-spacing: -0.4px;
  line-height: 1;
}


/* Responsive */
@media (max-width: 768px) {
  .projet-layout {
    grid-template-columns: 1fr;
    height: auto;
  }

   .projet-droite {
    position: relative;
    top: auto;
    order: 1; /* s'affiche en premier */
    padding: 5rem 2rem 1rem 2rem;
  }

  .projet-navigation {
    justify-content: center;
    gap: 24px;
  }

  .projet-gauche {
    order: 2; /* s'affiche après le texte */
    padding: 1rem;
    overflow-y: visible; /* scroll si nécessaire */
  }
}



/* navigation (flèches) : prend 100% de la colonne droite */
.navigation {
  position: fixed;
  bottom: 15px;
  right: 30px;
  display: flex;
  gap: 20.7rem;
  z-index: 2000;
}


/* style des flèches (tu peux remplacer le contenu par SVG si tu préfères) */
.nav-arrow {
  text-decoration: none;
  font-size: 1.5rem;
  font-weight: bold;
  color: black;
  transition: transform 0.2s ease, color 0.2s ease;
  cursor: pointer;
  user-select: none;
}

.nav-arrow:hover { color: #666;  font-style: italic; }






/* Page photos images et tout là */

  /* Container principal */
    .gallery-container {
      display: grid;
      grid-template-columns: 3fr 1fr; /* ← images plus larges à gauche */
      height: 100vh; /* occupe toute la hauteur comme tes projets */
      padding: 20px 30px;
      gap: 30px;
    }

    /* Colonne gauche */
    .titles-column {
      overflow-y: auto;
      padding-right: 15px;
      padding-top: 60px;
    }
    .title-item {
      font-size: 1.1rem;
      font-weight: bold;
      color: #000000;
      cursor: pointer;
      padding: 8px 10px;
      margin: 0;
      border-bottom: 1px solid #000000; /* séparateur rouge fin */
      transition: all 0.3s ease;
    }
    .title-item:hover {
      background: #c4c3c3;
      color: #000000;
    }

    /* Colonne droite */
    .right-side {
      order: -1; /* passe la colonne images à gauche */
      display: flex;
      flex-direction: column;
      height: 100%;
      position: relative;
    }

    /* Image principale */
    .main-stage {
      flex: 1;
      display: flex;
      justify-content: center;
      align-items: center;
      overflow: hidden;
    }
    .main-stage img {
      max-width: 100%;
      max-height: 100%;
      object-fit: contain;
    }

    /* Vignettes fixées en bas */
    .thumbnail-container {
      position: absolute;
      bottom: 0;
      left: 0;
      right: 0;
      height: 12vh;
      display: flex;
      align-items: center;
      overflow-x: auto;
      overflow-y: hidden;
      scroll-behavior: smooth;
      white-space: nowrap;
      background: whitesmoke;
      gap: 4px;          
      padding: 20px 0 0 0;  /* petit espace au-dessus */
    }

    .thumbnail-container::-webkit-scrollbar {
      height: 6px;
    }
    .thumbnail-container::-webkit-scrollbar-thumb {
      background: whitesmoke;
    }

    .thumbnail-container img {
      height: 100%;
      width: auto;
      display: inline-block;
      cursor: pointer;
      border-radius: 0;
      flex-shrink: 0;
    }



    /* s'assurer que le container est scrollable horizontalement */
#thumbnails,
.thumbnail-container {
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch; /* inertie sur iOS */
  touch-action: pan-y; /* permet le scroll vertical de la page ; si tu veux forcer horizontal, utiliser pan-x */
}

/* curseur pendant le drag */
#thumbnails.dragging,
.thumbnail-container.dragging {
  cursor: grabbing;
}
#thumbnails,
.thumbnail-container {
  cursor: grab;
}



    /* Responsive mobile */
@media (max-width: 768px) {
  .gallery-container {
    display: flex;
    flex-direction: column;
    height: auto;
    padding: 10px 10px;
  }

  .titles-column {
    order: 1;
    padding-top: 90px; /* 🔽 descend les titres sur mobile */
    padding-bottom: 20px;
  }

  .right-side {
    order: 2;
    flex: 1;
  }

  .main-stage img {
    max-height: 60vh; /* images bien grandes sur mobile */
  }

  .thumbnail-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 13vh;              /* taille des thumbnails */
    background: whitesmoke;    /* petit fond pour bien voir */
    display: flex;
    align-items: center;
    justify-content: flex-start;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 10px;
    gap: 8px;
    z-index: 1000;             /* au-dessus du reste */
  }

  .main-stage {
    padding-bottom: 15vh; /* 🔽 laisse la place pour la barre fixée */
  }
}



/* Page photo, gallerie, Quand on appuie +, infos cachées */
  .info-text {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.4s ease;
    font-weight: normal;
    color: #333;
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-size: 1rem;
    letter-spacing: -0.4px;
    line-height: 1;
  }

  .info-text.open {
    max-height: 200px; /* hauteur max — ajustable */
    opacity: 1;
    margin-top: 15px;
    margin-bottom: 15px;
  }

  /* Petit plus à droite */
  .title-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .title-item .plus {
    font-weight: normal;
    transition: transform 0.3s ease;
  }

  /* Rotation du + en × ou flèche vers le bas */
  .title-item.active .plus {
    transform: rotate(45deg);
  }

