/* =============================================
   === ANIMATIONS ET STYLES GLOBAUX ===
   ============================================= */

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes whiteToPink {
    0%, 100% { filter: brightness(0) saturate(100%) invert(100%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(100%) contrast(100%); }
    50% { filter: brightness(0) saturate(100%) invert(34%) sepia(98%) saturate(1030%) hue-rotate(270deg) brightness(100%) contrast(100%); }
}

@keyframes irregularBlink {
    0%, 100% { color: #ffffff; }
    10% { color: #e94df7; }
    25% { color: #ffffff; }
    35% { color: #e94df7; }
    50% { color: #ffffff; }
    65% { color: #e94df7; }
    80% { color: #ffffff; }
}

/* =============================================
   === BODY ET POLICES ===
   ============================================= */
body {
    font-family: 'Grajon', sans-serif;
    font-weight: normal;
    font-style: normal;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: #000000;
    color: #ffffff;
    opacity: 0;
    animation: fadeIn 6s ease-in forwards; /* 6 secondes au lieu de 3 */
    
}




/* Polices personnalisées */
@font-face {
    font-family: 'Grajon';
    src: url('../fonts/Grajon-Regular.woff2') format('woff2'),
         url('../fonts/Grajon-Regular.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Grajon';
    src: url('../fonts/Grajon-Italic.woff2') format('woff2'),
         url('../fonts/Grajon-Italic.woff') format('woff');
    font-weight: normal;
    font-style: italic;
    font-display: swap;
}

/* =============================================
   === HEADER ===
   ============================================= */
header {
    position: absolute;
    width: 100%;
    padding: 1rem;
    box-sizing: border-box;
    background-color: transparent;
    top: 0;
    left: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 100%;
    width: 100%;
}

.header-links {
    display: flex;
    gap: 20px;
    align-items: center;
}

.logo {
    height: 50px;
    width: auto;
    margin: 0;
    white-space: nowrap;
    animation: whiteToPink 6s infinite;
    cursor: pointer;
}

.portfolio-link, .contact-link {
    font-family: 'Grajon', sans-serif;
    font-style: italic;
    font-size: 1.2rem;
    color: white;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.portfolio-link:hover, .contact-link:hover {
    color: #e94df7;
}

/* =============================================
   === FLÈCHES UNIFIÉES ===
   ============================================= */
.arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    z-index: 10001;
    opacity: 0.7;
    transition: opacity 0.3s ease;
    font-weight: bold;
    padding: 0;
}

.arrow:hover {
    opacity: 1;
}

.arrow--prev {
    left: 5%;
}

.arrow--next {
    right: 5%;
}



/* =============================================
   === HERO SECTION ===
   ============================================= */
.hero-section {
    width: 100%;
    padding: 40px 0 120px; /* Ajout de padding-bottom pour éviter le chevauchement avec le header */
    background-color: #000000;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    margin-top: 80px; /* Espace pour le header fixed */
}

.hero-images {
    display: flex;
    gap: 20px;
    max-width: 1200px;
    width: 100%;
    justify-content: center;
    align-items: center;
    padding: 0 10px;
    box-sizing: border-box;
}

.hero-img {
    width: 100%;
    max-width: 45%;
    height: auto;
    display: block;
    cursor: pointer;
}

/* === TABLETTE PORTRAIT (768px - 1023px) === */
@media (min-width: 768px) and (max-width: 1023px) and (orientation: portrait) {
    .hero-section {
        min-height: 100vh;
        padding: 2rem 0;
        margin-top: 0;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }
    .hero-images {
        flex-direction: column;
        gap: 1rem;
        width: 100%;
        max-width: 80%; /* Limite la largeur du conteneur pour éviter les débordements */
    }
    .hero-img {
        width: 70%; /* Même largeur pour les 2 photos */
        max-width: 100%; /* Empêche toute déformation */
        height: auto; /* Conserve les proportions */
        object-fit: contain; /* Garantit qu'aucune déformation ne se produit */
        margin: 0 auto;
    }

}

@media (max-width: 767px) and (orientation: portrait) {
    .hero-section {
        padding: 20px 0 60px;
        margin-top: 60px;
    }

    .hero-images {
        flex-direction: column;
        gap: 10px;
    }

    .hero-img {
        width: 75%;
        max-width: 100%;
    }
}


/* =============================================
   === SCÈNES SECTION ===
   ============================================= */
.scenes-section {
    width: 100%;
    background-color: #000000;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.scene {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    margin: 0;
    padding: 0;
}

.scene-content {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 2;
}

.scene-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}

/* =============================================
   === SCÈNE 1 ===
   ============================================= */
#scene1 {
    background-color: #1a1a1a;
}

#scene1 .scene-content {
     position: relative; /* Si ce n'est pas déjà le cas */
    top: -10vh; /* Valeur négative pour monter */
    box-sizing: border-box;
    
}

#scene1 .triple-images-container {
    display: flex;
    justify-content: center;
    gap: 40px;
    max-width: 1200px;
    width: 100%;
    margin-top: 0;
    top: 0vh;
}

#scene1 .triple-image {
    width: auto;
    height: 420px;
    object-fit: contain;
    cursor: pointer;
    transition: transform 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#scene1 .triple-image:hover {
    transform: scale(1.04);
}

/* Overlays pour les sliders de la scène 1 */
.slider-overlay {
    position: fixed;
    top: 0%; 
    left: 0;
    width: 100%;
    height: 100%; /* Hauteur réduite pour un positionnement plus haut */
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: none;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}

.slider-overlay.show {
    display: flex;
    pointer-events: auto;
}

.slider-container {
    position: relative;
    width: 95%;
    height: 95%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slider-images {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slider-image {
    position: absolute;
    width: 100%;
    height: 100%;
    max-width: 100 vw;
    max-height: 100vh;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    filter: drop-shadow(0 0 30px rgba(0, 0, 0, 0.6));
}

.slider-image.active {
    opacity: 1;
    pointer-events: auto;
}

/* Masque les flèches de la Scène 1 par défaut (sur tous les écrans) */
#scene1 .arrow--prev,
#scene1 .arrow--next {
    display: none;
}

/* Affiche les flèches UNIQUEMENT en portrait tablette (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) and (orientation: portrait) {
    #scene1 .triple-images-container {
        gap: 0;
        width: 100%;
        max-width: 80%;
        padding-top: 5vh;
        margin-right: 3%;
        position: relative;
    }
    #scene1 .triple-image {
        height: 60vh;
        width: auto;
        object-fit: contain;
        margin: 0;
        padding: 0;
        display: block;
    }

    /* Affiche les flèches avec les styles unifiés */
    #scene1 .arrow--prev,
    #scene1 .arrow--next {
        display: block;
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        pointer-events: none;
        cursor: default;
        z-index: 10; /* Assure que les flèches sont au-dessus des images */
    }
    #scene1 .arrow--prev {
        left: 3%; /* Positionne à 5% du bord gauche du conteneur */
        top: 42%;
    }
    #scene1 .arrow--next {
        right: 3%; /* Positionne à 5% du bord droit du conteneur */
        top: 42%;
    }
}








/* =============================================
   === SCÈNE 2 ===
   ============================================= */
#scene2 {
    position: relative;
    overflow: hidden;
}

.scene2-backgrounds {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.scene2-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.3s ease-in-out;
    z-index: 1;
}

.scene2-background.active {
    opacity: 1;
}

.scene2-jewels {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2;
}

.scene2-jewel {
    position: absolute;
    width: auto;
    max-width: 72%;
    max-height: 72vh;
    object-fit: contain;
    opacity: 0;
    transition: opacity 1.3s ease-in-out;
    pointer-events: none;
}

.scene2-jewel.active {
    opacity: 1;
    pointer-events: auto;
}

.scene2-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    z-index: 3;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.scene2-arrow:hover {
    opacity: 1;
}

.scene2-arrow.arrow--prev {
    left: 5%;
}

.scene2-arrow.arrow--next {
    right: 5%;
}

.scene2-video {
  width: auto;
  max-width: 72%;
  max-height: 72vh;
  object-fit: contain;
  opacity: 0;
  transition: opacity 1.3s ease-in-out;
  pointer-events: none;
  outline: none;
}

.scene2-video.active {
  opacity: 1;
  pointer-events: auto;
}







/* =============================================
   === SCÈNE 3 ===
   ============================================= */
#scene3 .scene-content {
    display: flex;
    justify-content: center;
    align-items: center;
}

.aggressive-flick-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.aggressive-flick-image {
    position: absolute;
    width: auto;
    height: 60vh;
    max-width: 84%;
    object-fit: contain;
    opacity: 0;
    z-index: 3;
    transform: translate(-50%, -50%) scale(1.2);
    filter: drop-shadow(0 0 20px rgba(0, 0, 0, 0.4));
    outline: 2px solid #00a2ff;
    outline-offset: -2px;
    transition: none;
    left: 50%;
    top: 50%;
}

@media (max-width: 767px) and (orientation: portrait) {
    #scene3 .aggressive-flick-image {
        height: calc(60vh * 0.7); /* Réduction de 30% sur la hauteur (60vh → 42vh) */
        max-width: calc(84% * 0.7); /* Réduction de 30% sur la largeur maximale (84% → ~59%) */
        transform: translate(-50%, -50%) scale(0.7); /* Réduction globale de 30% + centrage */
        outline-width: calc(2px * 0.7); /* Réduction de 30% sur l'épaisseur du cadre bleu */
    }
}


/* =============================================
   === SCÈNE 4 ===
   ============================================= */
#scene4 .scene-content {
    display: flex;
    justify-content: center;
    align-items: center;
}

#scene4 .slider-container {
    width: 100%;
    height: 100%;
    position: relative;
}

#scene4 .slider-images {
    width: 100%;
    height: 100%;
}

#scene4 .slider-image {
    width: auto;
    height: 60vh;
    max-width: 84%;
    object-fit: contain;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(1.2);
    filter: drop-shadow(0 0 20px rgba(0, 0, 0, 0.4));
    opacity: 0;
    transition: opacity 0.5s ease;
}

#scene4 .slider-image.active {
    opacity: 1;
}

#openPanoramaLeft {
    left: 10%;
}

#openPanoramaRight {
    left: 80%;
}

@media (max-width: 767px) and (orientation: portrait) {
    #scene4 .slider-image {
        height: calc(90vh * 0.7); /* 90vh → 63vh */
        max-width: calc(90% * 0.7); /* 90% → 63% */
    }
}


/* =============================================
   === SCÈNE 5 ===
   ============================================= */
#scene5 {
    display: flex;
    justify-content: center;
    align-items: center;
}

.scene5-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    z-index: 1;
}

.scene5-photos-container {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 60px;
    padding: 0 5%;
    box-sizing: border-box;
    z-index: 2;
}

.scene5-photo {
    width: calc(30% - 20px);
    max-height: 70vh;
    object-fit: contain;
    display: block;
}

/* === SCÈNE 5 : EMPILEMENT VERTICAL AVEC 50% DE TAILLE ET ESPACEMENT === */
@media (min-width: 768px) and (max-width: 1023px) and (orientation: portrait) {
    #scene5 .scene5-photos-container {
        flex-direction: column; /* Empile verticalement */
        align-items: center; /* Centre horizontalement */
    }

    #scene5 .scene5-photo {
        width: 45%; /* 50% de réduction (30% → 15%) */
        max-height: none;
        height: auto;
        object-fit: contain;
        margin: 0 0 1% 0; /* Écart de 3% uniquement en bas */
        padding: 0;
    }
}

@media (max-width: 767px) and (orientation: portrait) {
    #scene5 .scene5-photos-container {
        flex-direction: column; /* Empile verticalement */
        align-items: center; /* Centre horizontalement */
        gap: var(--photo-gap, 10px); /* Espacement entre les photos (modifiable) */
    }

    #scene5 .scene5-photo {
        width: var(--photo-size, 50%) !important; /* Taille des photos (modifiable) */
        max-height: none !important;
        height: auto !important;
    }
}


/* =============================================
   === SCÈNE 6 ===
   ============================================= */
#scene6 {
    display: flex;
    justify-content: center;
    align-items: center;
}

.scene6-image {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.scene6-photos-container {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    padding: 0 5%;
    box-sizing: border-box;
    z-index: 2;
}

.scene6-photo-wrapper {
    position: relative;
    width: calc(30% - 20px);
    max-height: 70vh;
}

.scene6-photo-blue {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    cursor: pointer;
}

.scene6-photo-polina {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.scene6-photo-wrapper:hover .scene6-photo-polina {
    opacity: 1;
}

/* === SCÈNE 6 : STYLE POUR L'OUVERTURE DES PHOTOS === */
#scene6 .scene6-photo {
    cursor: pointer; /* Indique que la photo est cliquable */
    transition: transform 0.3s ease; /* Animation fluide */
}

:root {
    --scene6-photo-size-tablet: 35%; /* Taille des wrappers en portrait tablette */
    --photo-gap-tablet: 15px; /* Espacement entre les wrappers en portrait tablette */
}

@media (min-width: 768px) and (max-width: 1023px) and (orientation: portrait) {
    #scene6 .scene6-photos-container {
        flex-direction: column; /* Empile verticalement les wrappers */
        align-items: center; /* Centre horizontalement */
        gap: var(--photo-gap-tablet); /* Espacement entre les wrappers */
    }

    #scene6 .scene6-photo-wrapper {
        width: var(--scene6-photo-size-tablet) !important; /* Taille du wrapper */
        max-height: none !important;
        height: auto !important;
    }

    /* Les deux photos dans chaque wrapper conservent leur superposition */
    #scene6 .scene6-photo-blue,
    #scene6 .scene6-photo-polina {
        width: 100% !important; /* Prend toute la largeur du wrapper */
        height: auto !important;
        max-height: none !important;
    }
}


:root {
    --scene6-photo-size: 40%; /* Taille des wrappers (et donc des photos) - Ajustez cette valeur */
    --photo-gap: 15px; /* Espacement entre les wrappers */
}

@media (max-width: 767px) and (orientation: portrait) {
    #scene6 .scene6-photos-container {
        flex-direction: column; /* Empile verticalement les wrappers */
        align-items: center; /* Centre horizontalement */
        gap: var(--photo-gap); /* Espacement entre les wrappers */
    }

    #scene6 .scene6-photo-wrapper {
        width: var(--scene6-photo-size) !important; /* Taille du wrapper */
        max-height: none !important;
        height: auto !important;
    }

    /* Les deux photos dans chaque wrapper conservent leur superposition */
    #scene6 .scene6-photo-blue,
    #scene6 .scene6-photo-polina {
        width: 100% !important; /* Prend toute la largeur du wrapper */
        height: auto !important;
        max-height: none !important;
    }
}



/* =============================================
   === SCÈNE 7 ===
   ============================================= */

#scene7 {
  background-color: #000000;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.scene7-video {
  width: auto;
  max-width: 80%;
  max-height: 80vh;
  object-fit: contain;
  display: block;
  outline: none;
  pointer-events: none;
}

/* Masque les contrôles natifs pour Chrome/Safari/Firefox */
.scene7-video::-webkit-media-controls-panel-container,
.scene7-video::-webkit-media-controls-start-playback-button,
.scene7-video::-moz-media-controls,
.scene7-video::-webkit-media-controls {
  display: none !important;
}



/* =============================================
   === CONTACT SECTION ===
   ============================================= */
.contact-section {
    padding: 2rem;
    text-align: center;
    background-color: #000000;
    color: #ffffff;
}

.blinking-contact {
    font-family: 'Grajon', sans-serif;
    font-style: italic;
    font-size: 2rem;
    margin-bottom: 1rem;
    line-height: 1.1;
    text-align: center;
    width: 100%;
    display: block;
    animation: irregularBlink 0.3s infinite;
}

.contact-image {
    display: block;
    max-width: 300px;
    height: auto;
    margin: 0 auto 1rem;
    border-radius: 4px;
    pointer-events: none;
    user-select: none;
}

.social-section {
    width: 100%;
    padding: 1rem 0;
    background-color: #000000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin-right: 2rem;
}

.social-link {
    display: block;
    width: 40px;
    height: 40px;
}

.social-icon {
    width: 100%;
    height: 100%;
    filter: brightness(0) saturate(100%) invert(34%) sepia(98%) saturate(300%) hue-rotate(280deg) brightness(100%) contrast(100%);
    transition: transform 0.3s ease;
}

.social-link:hover .social-icon {
    transform: scale(1.1);
}

/* =============================================
   === FOOTER ===
   ============================================= */
footer {
    background-color: #000000;
    color: #ffffff;
    text-align: center;
    padding: 1rem;
    border-top: 1px solid #5a2d5a;
    font-family: 'Grajon', sans-serif;
    font-style: italic;
    font-size: 14px;
}

footer p {
    margin: 0.5rem 0;
}

/* =============================================
   === MODALS ===
   ============================================= */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.modal.show {
    display: flex;
    opacity: 1;
    pointer-events: auto;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: #121212;
    margin: 10% auto;
    padding: 30px;
    border: 1px solid #32063c;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    width: 80%;
    max-width: 500px;
    border-radius: 5px;
    color: #fff;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.modal-content.show {
    opacity: 1;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #e94df7;
}

.modal-content h2 {
    text-align: center;
    margin-bottom: 20px;
    font-family: 'Grajon', sans-serif;
    font-style: normal;
    font-size: 1rem;
    line-height: 1.3;
    color: #ccc;
    font-weight: normal;
}

form {
    display: flex;
    flex-direction: column;
}

label {
    margin-bottom: 8px;
    color: #ccc;
    font-family: 'Grajon', sans-serif;
    font-style: italic;
}

input {
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #32063c;
    border-radius: 4px;
    background-color: #2a2a2a;
    color: #fff;
    font-family: 'Grajon', sans-serif;
}

input:focus {
    border-color: #5a2d5a;
    outline: none;
}

button[type="submit"] {
    padding: 12px;
    background-color: #32063c;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Grajon', sans-serif;
    font-style: italic;
    transition: background-color 0.3s ease;
}

button[type="submit"]:hover {
    background-color: #5a2d5a;
}

.message {
    margin-top: 15px;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
    font-family: 'Grajon', sans-serif;
    font-style: italic;
}

.no-password-link {
    text-align: center;
    margin-top: 15px;
    font-family: 'Grajon', sans-serif;
    font-style: italic;
}

.no-password-link a {
    color: #6f0986;
    text-decoration: underline;
    cursor: pointer;
}

.no-password-link a:hover {
    color: #e94df7;
}

#thankYouModal button {
    padding: 12px 24px;
    background-color: #31103e;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Grajon', sans-serif;
    font-style: italic;
    transition: background-color 0.3s ease;
    display: block;
    margin: 20px auto 0;
}

#thankYouModal button:hover {
    background-color: #5a2d5a;
}

/* Modal pour les images en grand écran */
.image-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.image-modal.show {
    display: flex;
    opacity: 1;
    pointer-events: auto;
}

.image-modal-content {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    cursor: pointer;
}