/* ——————————— CUSTOM FONTS ——————————— */

@font-face {
  font-family: 'NHaasGroteskDSPro-55Rg';
  src: url('../fonts/NHaasGroteskDSPro-55Rg.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  letter-spacing: 0.05em;
 
}

/* ——————————— RESET / BASE ——————————— */
html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  z-index: 9999; /* Très au-dessus de tout */
  font-family: 'NHaasGroteskDSPro-55Rg', Helvetica, Arial, sans-serif;
  letter-spacing: 0.05em;
  color: white;
  box-sizing: border-box;
}

/* ——————————— HEADER ——————————— */
.header {
position: fixed;
top: 0;
left: 0;
width: 100%;
cursor: none;
padding: 0.5rem 1rem;
display: flex;
justify-content: space-between;
align-items: flex-start;
z-index: 100;
color: white;
mix-blend-mode: difference;
box-sizing: border-box;
}


.header a {
color: inherit;
text-decoration: none;
font-size: calc(1rem + 0.2vw);
pointer-events: auto;
line-height: 1.4;
}

.header-right a.about-link {
  position: relative;
  z-index: 10001; /* Encore au-dessus de l'overlay */
}
@media (max-width: 768px) {
.header {
padding: 1rem 1rem;
align-items: flex-start;
gap: 0.5rem;
}
}

/* ——————————— SCROLL SNAP LAYOUT ——————————— */
/* === Desktop === */
.snap-container {
overflow-y: scroll;
height: 100vh;
scroll-snap-stop: always;
-webkit-overflow-scrolling: touch;
scroll-snap-type: y mandatory;
scroll-behavior: smooth;
}

.snap-section {
position: relative;
scroll-snap-align: start;
width: 100%;
height: 100vh;
overflow: hidden;
}

/* === Mobile === */
@media (max-width: 768px) {
.snap-container {
scroll-snap-type: none;
overflow-y: auto;
height: auto;
}


.hero-section {
display: none;
}


.snap-section,

.project-section {
height: 50dvh !important;
min-height: 50dvh !important;
max-height: 50dvh !important;
overflow: hidden;
}


.carousel-wrapper,
.carousel-track,
.carousel-slide {
 
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

}


.carousel-slide img,
.carousel-slide video {
width: 100%;
height: 100%;
object-fit: cover;
display: block;
}


.project-title h1 {
position: absolute;
bottom: 1rem;
left: 1rem;
font-size: calc(1rem + 0.2vw);
}


.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 32px;
  background-image: url('../img/cursors/cursor-right.svg');
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  opacity: 0.7;
  z-index: 20;
  animation: bounce 1.5s infinite;
  cursor: pointer;
}

/* Animation de scroll indicator */
@keyframes bounce {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 10px); }
}

/* Masquer sur mobile */
@media (max-width: 768px) {
  .scroll-indicator {
    display: none;
  }
}








/* ——————————— HERO CAROUSEL ——————————— */

.carousel {
position: relative;
width: 100%;
height: 100vh;
overflow: hidden;
}


.carousel-wrapper {
display: flex;
height: 100vh;
transition: transform 0.8s ease-in-out;
}


.carousel-slide {
flex: 0 0 100%;
height: 100%;
}


.carousel-slide img,
.carousel-slide video {
width: 100%;
height: 100%;
object-fit: cover;
display: block;
}

/* Scroll down indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 32px;
  background-image: url('../img/cursors/cursor-bottom.svg');
  mix-blend-mode: difference;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  cursor: pointer;
  animation: bounce 1.5s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(10px); }
}

/* ——————————— PROJECTS FULLSCREEN SECTIONS ——————————— */
.project-section {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}
.project-title h1 {
  position: absolute;
  bottom: 1rem;
  left: 3rem;
  font-family: 'NHaasGroteskDSPro-55Rg', Helvetica, Arial, sans-serif;
  font-weight: normal;
  font-size: calc(1rem + 0.2vw);
  line-height: 1.4;
  color: black;
  z-index: 10;
  
  cursor: pointer;
}
.open-project.hidden-title {
  visibility: hidden;
}
/* ——————————— MANUAL PROJECT CAROUSEL ——————————— */
.manual-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  height: 100%;
  transition: transform 0.6s ease;
}

.carousel-slide {
  flex: 0 0 100%;
  height: 100%;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}



.custom-arrow {
  position: fixed;
  width: 40px;
  height: 40px;
  background-image: url('../img/cursors/cursor-right.svg');
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
  opacity: 0;
  mix-blend-mode: difference;
  transform: translate(-50%, -50%) rotate(0deg);
  transition: opacity 0.15s ease, transform 0.15s ease;
  z-index: 10000;
}
/* === CURSEUR CUSTOM POUR LA HERO SECTION === */
.hero-section {
  cursor: none; /* cache le curseur normal */
  position: relative;
}

/* flèche vers le bas qui suit la souris dans le hero */
.hero-cursor {
  position: fixed;
  width: 40px;
  height: 40px;
  background-image: url('../img/cursors/cursor-bottom.svg');
  background-repeat: no-repeat;
  background-size: contain;
  mix-blend-mode: difference;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.2s ease;
  z-index: 10000;
}

.hero-cursor.visible {
  opacity: 1;
}

/* désactive sur mobile */
@media (max-width: 768px) {
  .hero-cursor {
    display: none;
  }
}


.custom-arrow.visible {
  opacity: 1;
}

/* direction gauche = on retourne la même flèche */
.custom-arrow.left {
  transform: translate(-50%, -50%) rotate(180deg);
  background-image: url('../img/cursors/cursor-right.svg');
}

.custom-arrow.right {
  transform: translate(-50%, -50%) rotate(0deg);
}
.manual-carousel:hover {
  cursor: none;
}
/* pas de flèche flottante sur mobile */
@media (max-width: 768px) {
  .custom-arrow {
    display: none !important;
  }
}



/* ——————————— PROJECT OVERLAY (BOTTOM) ——————————— */
/* ───────────────────────────────
   PROJECT OVERLAY (3 columns)
────────────────────────────────── */
.project-overlay {
  position: fixed;
  bottom: -100%;
  left: 0;
  width: 100%;
  height: fit-content;
  background: white;
  color: black;
  z-index: 1000;
  overflow: hidden;
  transition: all 0.2s ease;
}
.project-section h1 {
  position: absolute;
  bottom: 0.7rem;
  left: 1rem;
  font-weight: normal;
  font-size: calc(1rem + 0.2vw);
  color: white;
  mix-blend-mode: difference;
  margin: 0;
  cursor: pointer;
}
@media (max-width: 768px) {
  .project-section h1 {

  left: 1rem;
  bottom: 0rem;

}
}
/* ——————————— PROJECT OVERLAY VERSION MOBILE ——————————— */
@media (max-width: 900px) {
 

  .project-overlay.active {
    height: 50dvh; /* s'adapte à la hauteur du contenu */
    opacity: 1;
    
  }

  .project-overlay-content {
    
    display: block;
  }

  .overlay-columns {
    display: block;
  }

  .overlay-columns p {
    margin-bottom: 0.8rem;
  }

  .project-description {
    margin-top: 1rem;
  }
}


.project-section h1 .plus {
  margin-left: 0.5rem;
  font-size: calc(1rem + 0.2vw);
  line-height: 1;
  display: inline-block;
  transition: transform 0.1s ease, opacity 0.1s;
}

/* Animation lors du passage de + à × */
.project-section h1 .plus.close {
  transform: rotate(0deg) scale(1.2);
  transition: transform 0.9s ease;
  animation: plusToClose 0.9s ease forwards;
}

/* Animation keyframes */
@keyframes plusToClose {
  0% {
    transform: rotate(0deg) scale(1);
  }
 
  100% {
    transform: rotate(0deg) scale(1);
  }
}
.project-title-overlay{
  color: black;
  cursor: pointer;
  padding-bottom: calc(0.7rem + 0.4vw);
}


.project-overlay.active {
  bottom: 0;
}

.overlay-close-btn {
 
  cursor: pointer;
  padding-left: 0.5rem;
  
}

.overlay-close-btn:hover, .project-title-overlay:hover {
  opacity: 0.5;
}
.project-overlay-content {
  padding:  1rem;
  display: flex;
  align-items:center;
  justify-content: center;
  box-sizing: border-box;
}

.overlay-columns {
  display: grid;
  grid-template-columns: 1fr  1fr;
  align-items: start;
  width: 100%;
  gap: 2rem;

}

.overlay-columns p {
  font-family: 'NHaasGroteskDSPro-55Rg', sans-serif;
  letter-spacing: 0.05em;
  font-size: calc(1rem + 0.2vw);
  font-weight: 600;
  line-height: 1.3;
  
  margin: 0;
}

/* Description column (left) */
.description-column .project-description {
  font-size: calc(1rem + 0.2vw);
  line-height: 1.3;
  font-weight: 600;
  color: black;
  margin-bottom: 2rem;
  
}

/* Middle info column (author + size) */
.info-column {
    display: flex;
  flex-direction: column;
  height: 100%;
}
/* Le tag est poussé en bas */
.info-column .project-tag{
  margin-top: auto;
}
/* Right meta column (year + tag) */
.meta-column {
  color: black;
  text-align: right;
}


.carousel-counter{
  position: absolute;
  bottom: 0.7rem;
    right: 1rem;
  z-index: 12;
  font-size: calc(1rem + 0.2vw);
  line-height: 1.4;
  color: white;
  mix-blend-mode: difference;
  pointer-events: none;
}
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive overlay on mobile */
/* ================================
   MOBILE: layout titre + compteur sous image
   + overlay inline qui pousse le contenu
   ================================ */
@media (max-width: 768px){
p{
  font-size: 1rem;
}
  /* IMPORTANT: sur mobile, il faut des sections en hauteur auto,
     sinon rien ne peut "pousser" le projet suivant */
  .snap-section,
  .project-section{
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
  }

  /* Image: tu peux garder un ratio stable */
  .manual-carousel{
    height: 30vh;      /* ajuste si tu veux plus/moins haut */
    padding: 0;
  }

  .manual-carousel .carousel-slide img,
  .manual-carousel .carousel-slide video{
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* Barre blanche (on réutilise ton .project-title / .open-project) */
  .project-title{
    display: block !important;
    position: static !important;
    background: #fff;
    color: #000;
    padding: 14px 16px;
    border-top: 1px solid rgba(0,0,0,0.08);
  }

  /* Réactive le H1 (tu l'avais masqué en desktop) */
  .project-title h1.open-project{
    display: flex !important;
    align-items: baseline;
    justify-content: space-between;
    position: static !important;
    margin: 0 !important;
    font-size: 1rem;
    line-height: 1.3;
    font-weight: 600;
    color: #000 !important;
    mix-blend-mode: normal !important;
  }

  /* Le + */
  .project-title h1 .plus{
    display: inline-block;
    margin-left: 6px;
  }

  /* Compteur DANS la barre (on le déplacera en JS) */
  .project-title .carousel-counter{
    position: static !important;
    right: auto !important;
    bottom: auto !important;
    color: #000 !important;
    mix-blend-mode: normal !important;
    opacity: 1 !important;
    pointer-events: none;
    flex: 0 0 auto;
  }

  /* L’overlay devient inline (dans le flux) et pousse le contenu */
  .project-overlay.inline-mobile{
    position: static !important;
    left: auto !important;
    bottom: auto !important;
    width: 100%;
    background: #fff;
    color: #000;
    z-index: 1;

    overflow: hidden;
    max-height: 0;
    transition: max-height 0.35s ease;
    
  }

  /* Ouvert */
  .project-overlay.inline-mobile.active{
    max-height: 120vh; /* assez grand pour le contenu */
  }

  /* Mise en page overlay en une colonne sur mobile */
  .project-overlay.inline-mobile .project-overlay-content{
    padding: 0px 16px 18px !important;
    display: block !important;
  }

  .project-overlay.inline-mobile .overlay-columns{
    display: block !important;
  }

  /* On n’a pas besoin de la croix en mobile (optionnel) */
  .project-overlay.inline-mobile .overlay-close-btn{
    display: none !important;
  }

  /* Le titre dans l’overlay peut être masqué si tu veux uniquement la barre */
  .project-overlay.inline-mobile .overlay-title-text{
    display: none !important;
  }

  .description-column .project-description{
    padding-top: 0 !important;
  }
}

/* ===============================
   MOBILE — alignement du + au titre
   =============================== */
@media (max-width: 768px){

  /* Le titre devient une ligne flex complète */
  .project-title h1.open-project{
    display: flex;
    align-items: center;
    width: 100%;
  }

  /* Groupe titre + plus */
  .project-title h1.open-project .title-text,
  .project-title h1.open-project .plus{
    flex: 0 0 auto;
  }

  /* Le compteur est poussé à droite */
  .project-title h1.open-project .carousel-counter{
    margin-left: auto;   /* 🔑 clé */
    flex: 0 0 auto;
    text-align: right;
  }
  .overlay-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
    width: 100%;
    gap: 0rem;
}
}
/* ===============================
   MOBILE — animation + → ×
   =============================== */
@media (max-width: 768px){

  /* état fermé */
  .project-title h1 .plus{
    transform: rotate(0deg);
    transition: transform 0.25s ease;
  }

  /* état ouvert */
  .project-section.is-open .project-title h1 .plus{
    transform: rotate(45deg); /* + devient × */
  }
}



@media (max-width: 768px){
  .carousel-counter{
    right: 1rem;
    bottom: 0rem;
  }
}



/* ——————————— ABOUT OVERLAY (RIGHT) ——————————— */
/* --- About Overlay --- */
.about-toggle {
  position: fixed;
  top: 0.8rem;
  right:1.5rem;
  z-index: 1000;
  font-size: calc(1rem + 0.2vw);
  color: white;
  mix-blend-mode: difference;
  cursor: pointer;
  user-select: none;
}

.about-toggle .plus {
  margin-left: 0.3rem;
}
.about-link {
  position: relative;  /* important */
  z-index: 1001;       /* plus que l'overlay (qui est à 300) */
  color: white;
  font-size: calc(1rem + 0.2vw);
  text-decoration: none;
  mix-blend-mode: difference;
  pointer-events: auto;


}

.about-link .plus {
  margin-left: 0.25rem;
  font-weight: normal;
}

.about-overlay {
  position: fixed;
  top: 0;
  right: -100%;
  width:30vw;
  height: 100vh;
  background: white;
  font-size: calc(1rem + 0.2vw);
    line-height: 1.3;
    font-weight: 600;
    color: rgb(0, 0, 0);
  z-index: 300; /* bien plus bas que .about-link */
  padding: 4rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
      transition: all 0.4s ease;

}
@media (max-width: 900px) {
  .about-overlay {
  position: fixed;
  top: 0;
  right: -120%;
  width:85vw;
  height: 100vh;
  background: white;
  color: black;
  z-index: 300; /* bien plus bas que .about-link */
  padding: 5rem 2rem 5rem 5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.about-toggle {

  right: 1rem;
  top: 1rem;

}
}

.about-overlay.active {
  right: 0;
}

.about-body {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.about-left .subtitle {
  
  letter-spacing: 0.05em;
  font-weight: normal;
  font-size: calc(1rem + 0.2vw);
  margin-bottom: 1rem;
}
/* Masquer le titre du projet actif sous l’overlay */
.hide-title {
 z-index: 1;

}

.about-right {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about-right img {
  width: 22px;
  height: 22px;
}

.about-address {
  font-size: calc(1rem + 0.2vw);
  line-height: 1.4;
}
.about-address a{
  color: black;
}

/* Bouton fermeture en bas à droite */
.close-about {
  position: absolute;
  bottom: 2rem;
  right: 2rem;
  width: 32px;
  height: 32px;
  background-image: url('../img/cursors/cursor-right.svg');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  background-color: transparent;
  border: none;
  cursor: pointer;
  z-index: 999;
}
/* ===============================
   MOBILE — tag sous la description
   =============================== */
@media (max-width: 768px){

  /* On empile le contenu de l’overlay */
  .project-overlay.inline-mobile .overlay-columns{
    display: flex !important;
    flex-direction: column;
     font-size: 1rem;
  }

  /* La description d’abord */
  .project-overlay.inline-mobile .description-column{
    order: 1;
  }

  /* Le tag passe en dessous */
  .project-overlay.inline-mobile .project-tag{
    order: 2;
    margin-top: 0.75rem;   /* espace entre description et tag */
   
  }
}
@media (max-width: 768px){

  .project-title h1.open-project{
    display: flex;
    align-items: flex-start;   /* important quand ça wrap */
    width: 100%;
    gap: 0.75rem;              /* espace entre bloc titre et compteur */
  }


  /* Le + ne doit jamais partir tout seul */
  .project-title h1.open-project .title-wrap .plus{
    flex: 0 0 auto;
    white-space: nowrap;
    line-height: 1;
  }

  /* Compteur toujours à droite */
  .project-title h1.open-project .carousel-counter{
    margin-left: auto;
    text-align: right;
    flex: 0 0 auto;
    white-space: nowrap;
  }
}
