@import url('https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,100..900;1,100..900&display=swap');
/* Import Roboto font as well */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');
/* Import Cinzel font */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400..900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Tenor+Sans&display=swap');

/* reset simple plus désactivation du surligange*/
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

@keyframes gradient {
  0% { background-position: 0% }
  100% { background-position: 100% }
}

body {
  font-family: "Jost", serif;
  color: white;
  background: linear-gradient(45deg, #000000, #000000, #000000);
}


/* Loader Styles */
#loader-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 1s ease-in-out;
}

#logo {
    animation: fill 1s ease forwards 3.5s;
    width: 80%;
    max-width: 497px;
}
#logo path {
    stroke-dashoffset: 0;
    fill: transparent;
}
#logo path:nth-child(1) {
    stroke-dasharray: 433;
    stroke-dashoffset: 433;
    animation: line-anim 2s ease forwards 1.8s;
}
#logo path:nth-child(2) {
    stroke-dasharray: 489;
    stroke-dashoffset: 489;
    animation: line-anim 2s ease forwards 1.5s;
}
#logo path:nth-child(3) {
    stroke-dasharray: 450;
    stroke-dashoffset: 450;
    animation: line-anim 2s ease forwards 1.2s;
}
#logo path:nth-child(4) {
    stroke-dasharray: 320;
    stroke-dashoffset: 320;
    animation: line-anim 2s ease forwards 0.9s;
}
#logo path:nth-child(5) {
    stroke-dasharray: 473;
    stroke-dashoffset: 473;
    animation: line-anim 2s ease forwards 0.6s;
}
#logo path:nth-child(6) {
    stroke-dasharray: 222;
    stroke-dashoffset: 222;
    animation: line-anim 2s ease forwards 0.3s;
}
#logo path:nth-child(7) {
    stroke-dasharray: 399;
    stroke-dashoffset: 399;
    animation: line-anim 2s ease forwards;
}

@keyframes line-anim {
    to{
        stroke-dashoffset: 0;
    }
}
@keyframes fill{
    from{
        fill: transparent;
    }
    to{
        fill : white;
    }
}


/* Main content fade-in */
#main-content {
    opacity: 0;
    transition: opacity 1s ease-in-out;
}
#main-content.visible {
    opacity: 1;
}



/* navbar */
.navbar {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    width: 100%;
    position: sticky;
    top: 0;
    background: transparent;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    z-index: 999;
}

.navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0 2rem;
    max-width: 1600px;
}

.navbar-logo {
    font-size: 2rem;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
}

.navbar-container .navbar-menu {
    display: flex;
    text-align: center;
    gap: 1.5rem;
    list-style: none;
}

.navbar-container .navbar-menu li a {
    text-decoration: none;
    color: #fff;
    font-size: 1.3rem;
    font-weight: 500;
    padding: 3px 20px;
    border-radius: 20px;
    border: 2px solid transparent;
    transition: all 0.7s ease;
    white-space: nowrap;
}

.navbar-container .navbar-menu li a:hover,
.navbar-container .navbar-menu li a.active {
    color: #ffffff;
    background: rgba(188, 212, 229, 0);
    border: 2px solid #fff;
}

.navbar-toggle {
    display: none;
    background: transparent;
    padding: 10px;
    border: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: #fff;
    transition: all 0.3s ease-in-out;
}

@media (max-width: 880px) {
    .navbar {
        backdrop-filter: none;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.219);
    }

    .navbar-container .navbar-menu {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.7rem !important;
    position: fixed;
    height: 100vh;
    width: 250px;
    top: 0;
    right: -250px;
    padding: 5rem 1.5rem;
    box-shadow: 0 10px 10px rgba(0, 0, 0, 1);
    backdrop-filter: blur(12px);
    transition: all 0.5s ease-in-out;
    z-index: 998;
  }

    .navbar-container .navbar-menu.active {
    right: 0;
  }

    .navbar-toggle {
        display: block;
        z-index: 999;
    }

    .navbar-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }

    .navbar-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .navbar-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}

@media (max-width: 480px) {
    .navbar-container {
        padding: 0 1rem;
    }

    .navbar-logo {
        font-size: 1.7rem;
    }

    .navbar-container .navbar-menu li a {
        font-size: 1.2rem;
        padding: 3px 15px;
    }
}

.title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2rem;
  letter-spacing: 1px;
}



/* Galerie */
.image-container {
  column-count: 4;
  column-gap: 1rem;
  padding: 2rem;
  background: linear-gradient(45deg, #150e35, #000000, #000000);
}

.image-wrapper.visible{
    opacity: 1;
    scale : 1;
}


.image-wrapper {
  break-inside: avoid;
  overflow: hidden;
  margin-bottom: 1rem;
  border-radius: 12px;
  opacity: 0;
  transition: 600ms ease;
  scale: 0.8;
  position: relative;
}

/* Style pour les éléments canvas dans la galerie */
.gallery-image-canvas {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.4s ease;
}

/* Animation de survol sur le canvas lui-même */
.gallery-image-canvas:hover {
  transform: scale(1.07);
}


/* Responsive */
@media (max-width: 2000px) {
  .image-container {
    column-count: 3;
  }
}

@media (max-width: 1024px) {
  .image-container {
    column-count: 2;
  }
}

@media (max-width: 600px) {
  .image-container {
    column-count: 1;
  }
}




/* Styles pour le nouveau titre du carrousel */
.main-carousel-title {
    position: absolute;
    top: 23%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    z-index: 2; 
    opacity: 0;
    transition: opacity 1s ease-in-out;
    pointer-events: none;
    font-family: 'roboto';
    width: 80%;
    max-width: 600px;
}

.main-carousel-title h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.main-carousel-title p {
    font-size: clamp(1rem, 2vw, 1.5rem);
    line-height: 1.5;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.main-carousel-title.visible {
    opacity: 1; 
}


/*Caroussel paramètre*/
.carousel {
    overflow: hidden;
    position: relative;
    z-index: 1;
    height: 95vh;
    pointer-events: none;
    margin-top: 50px;
}

.carousel-item {
  --items: 10;
  --width: clamp(150px, 30vw,  300px);
  --height: clamp(200px, 40vw,  400px);
  --x: calc(var(--active) * 800%);
  --y: calc(var(--active) * 200%);
  --rot: calc(var(--active) * 120deg);
  --opacity: calc(var(--zIndex) / var(--items) * 3 - 2);
  overflow: hidden;
  position: absolute;
  z-index: var(--zIndex);
  width: var(--width);
  height: var(--height);
  margin: calc(var(--height) * -0.5) 0 0 calc(var(--width) * -0.5);
  border-radius: 10px;
  top: 50%;
  left: 50%;
  user-select: none;
  transform-origin: 0% 100%;
  box-shadow: 0 10px 50px 10px rgba(0, 0, 0, .5);
  background: black;
  pointer-events: all;
  transform:  translate(var(--x), var(--y)) rotate(var(--rot)) ;
  transition: transform .8s cubic-bezier(0, 0.02, 0, 1);
}

.carousel-item .carousel-box {
    position: absolute;
    z-index: 1;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transition: opacity .8s cubic-bezier(0, 0.02, 0, 1);
    opacity: var(--opacity);
    font-family: 'Orelo-sw-db', serif;
}

.carousel-item .carousel-box:before {
    content: '';
    position: absolute;
    z-index: 1;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, .3), rgba(0, 0, 0, 0) 30%, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, .5));
}

.carousel-item .title {
    position: absolute;
    z-index: 1;
    color: #fff;
    bottom: 20px;
    left: 20px;
    transition: opacity .8s cubic-bezier(0, 0.02, 0, 1);
    font-size: clamp(20px, 3vw, 30px);
    text-shadow: 0 4px 4px rgba(0, 0, 0, .1);
}

.carousel-item .num { 
    position: absolute;
    z-index: 1;
    color: #fff;
    top: 10px;
    left: 20px;
    transition: opacity .8s cubic-bezier(0, 0.02, 0, 1);
    font-size: clamp(20px, 10vw, 80px);
}

.carousel-item img { 
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}


.layout {
  position: absolute;
  z-index: 0;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.layout:before { 
    content: '';
    position: absolute;
    z-index: 1;
    top: 0;
    left: 90px;
    width: 10px;
    height: 100%;
    border: 1px solid #fff;
    border-top: none;
    border-bottom: none;
    opacity: .15;
}

.layout .box {
    position: absolute;
    bottom: 0;
    left: 30px;
    color: #fff;
    transform-origin: 0% 10%;
    transform: rotate(-90deg);
    font-size: 9px;
    line-height: 1.4;
    text-transform: uppercase;
    opacity: .4;
}

.cursor {
  position: fixed;
  z-index: 10;
  top: 0;
  left: 0;
  --size: 40px;
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .2);
  margin: calc(var(--size) * -0.5) 0 0 calc(var(--size) * -0.5);
  transition: transform .85s cubic-bezier(0, 0.02, 0, 1);
  display: none;
  pointer-events: none;
}
  
@media (pointer: fine) {
    .cursor {
        display: block;
    }
}

.cursor2 {
  --size: 2px;
  transition-duration: .7s;
}

/* Responsive carousel */
@media (max-width: 1100px) {
    .carousel {
        height: 1000px;
    }

    .carousel-item {
        
        --width: clamp(250px, 80vw, 400px);
        --height: clamp(300px, 90vw, 500px);
    }
    .main-carousel-title {
    position: absolute;
    top: 20%;
}
}

@media (max-width: 600px) {
    .main-carousel-title {
        top: 27%
    }
    .carousel {
        height: 80vh;
        margin-top: 100px;
    }

    .carousel-item {
        --width: clamp(150px, 70vw, 300px);
        --height: clamp(200px, 90vw, 400px);
    }

    .carousel-item .title{
        font-size: clamp(14px, 4vw, 20px);

    }
    .carousel-item .num {
        font-size: clamp(30px, 15vw, 50px);
    }
}

/* Styles pour la modale de la galerie */
.gallery-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.9);
    justify-content: center;
    align-items: center;
    touch-action: manipulation;
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    opacity: 0;
    transition: transform 0.5s ease-in-out, opacity 0.5s ease-in-out;
    transform: translateX(0); 
}

/* Bouton de fermeture */
.close-button {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
    touch-action: manipulation; 
}

.close-button:hover,
.close-button:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

/* Flèches de navigation */
.prev-arrow, .next-arrow {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -50px;
    color: white;
    font-weight: bold;
    font-size: 20px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation; 
}

.prev-arrow {
    left: 0;
    border-radius: 3px 0 0 3px;
}

.next-arrow {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev-arrow:hover, .next-arrow:hover {
    background-color: rgba(0, 0, 0, 0);
}

/* Page transition overlay */
#page-transition {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    opacity: 0;
    pointer-events: none;
    z-index: 9998;
    transition: opacity 0.5s ease-in-out;
}

#page-transition.is-active {
    opacity: 1;
    pointer-events: all;
}

/* Ensure body content is not visible during transition */
body.is-transitioning {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}
