
/* -----------------------------------------------------------------
   Images de figures
   ----------------------------------------------------------------- */

.picture {
    width: 100%;
    max-width: 1200px;
    margin: 20px auto;
    text-align: center;
    background-color: white;
}

.picture img {
    display: block;
    width: 100%;
    height: auto;
    cursor: zoom-in;
    border-radius: 4px;
}

.picture-gauche {
    float: left;
    margin: 0 20px 10px 0;
}

.zoom-image {
    cursor: zoom-in;
}

img.zoom-image {
    width: 100%;
    height: auto;
    transform-origin: center center; /* Change le point d'origine pour le zoom */
    transition: transform 0.3s ease; /* Pour une transition fluide */
    will-change: transform; /* Optimise le rendu pour les transformations */ 
}

.projet-image {
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* -----------------------------------------------------------------
   Visionneuse plein écran
   ----------------------------------------------------------------- */

.image-viewer {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgb(216, 215, 215, 1);
    overflow: hidden;
    touch-action: none;
    /*cursor: grab;*/
}

.image-viewer-dragging {
    cursor: grabbing;
}


/* Image dans la visionneuse */

.image-viewer img {
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    user-select: none;
    -webkit-user-select: none;
    pointer-events: none;
    transform-origin: center center;
    will-change: transform;
}


/* Bouton de fermeture */

.image-viewer-close {
    position: absolute;
    top: 20px;
    right: 25px;
    width: 45px;
    height: 45px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    color: rgb(6, 0, 0);
    font-size: 30px;
    line-height: 40px;
    cursor: pointer;
    z-index: 10000;
}

.image-viewer-close:hover {
    background: rgba(255, 255, 255, 0.35);
}


/* Petit texte d'aide */

.image-viewer-help {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(2, 0, 0, 0.7);
    font-size: 16px;
    pointer-events: none;
    white-space: nowrap;
}


/* Sur petit écran */

@media (max-width: 600px) {

    .picture {
        max-width: 100%;
    }
    .image-viewer img {
        max-width: 96vw;
        max-height: 90vh;
    }
    .image-viewer-help {
        font-size: 11px;
    }
}

.schema {
    /*position: relative;   /* facultatif */
    width: 100%;
    max-width: 1400px;
}

.schema svg {
    display: block;
    width: 100%;
    height: auto;
}

.viewer-schema {
    width: min(90vw, 1600px);
}

.schema-double {
    display: flex;
    gap: 20px;
    width: 100%;
    margin: 0 auto;
}

.image-viewer-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.annotation {
    padding: 10px 15px;
    background: white;
    border: 2px solid red;
    border-radius: 6px;
    font-family: sans-serif;
    box-sizing: border-box;
    width: 100%;
}

.annotation strong {
    display: block;
    font-size: 36px;
    line-height: 1.2;
}

.annotation span {
    display: block;
    font-size: 28px;
    line-height: 1.2;
}

/* Petite annotation */
.annotation-small strong {
    font-size: 24px;
}

.annotation-small span {
    font-size: 18px;
}

/* Annotation normale */
.annotation-medium strong {
    font-size: 36px;
}

.annotation-medium span {
    font-size: 28px;
}

.annotation-large {
    border: 7px solid red;
}
/* Grande annotation */
.annotation-large strong {
    font-size: 48px;
}

.annotation-large span {
    font-size: 36px;
}

.image-texte {
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.image-texte-image {
    flex: 0 0 20%;
}

.image-texte-image img {
    width: 50%;
    height: auto;
}

.boitier {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.boitier h2,
.boitier > p {
    grid-column: 1 / -1;
}

.boitier .picture {
    margin: 0;
}

@media (max-width: 600px) {
    .boitier { grid-template-columns: 1fr; }
}


