@font-face {
    font-family: 'Altone';
    src: url('./fonts/altone.woff') format('woff'),
        url('./fonts/altone.woff2') format('woff2');
}

@font-face {
    font-family: 'Bebas';
    src: url('./fonts/Bebas.woff') format('woff'),
        url('./fonts/Bebas.woff2') format('woff2');
}

*,
*::after,
*::before {
    box-sizing: border-box;
}

*{
    -webkit-font-smoothing: antialiased;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
}

html {
    scroll-snap-type: y mandatory;
}

body {
    font-family: 'Alatsi', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #ffffff;
    overflow-x: hidden;
}


.light-purple {
    color: #AF94E0;
}

header {
    scroll-snap-align: start;
}

.header-title-img {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: space-between;
    margin: auto;
    height: 100vh;
    width: fit-content;
    /* padding: 0 200px; */
    position: relative;


    img {
        width: 80vw;
        position: relative;
        top: 5px;
        opacity: 0;
        margin: 0 auto;
        transform: translateY(50vh);
        transition: opacity 0.5s ease, transform 1s ease;
    }

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

    @keyframes slideUp {
        0% {
            transform: translateY(50vh);
        }

        100% {
            transform: translateY(0);
        }
    }

    h1 {
        position: relative;
        top: 80px;
        font-family: 'Bebas', sans-serif;
        color: #2A114B;
        font-size: 3rem;
        display: flex;
        flex-direction: column;


        span {
            margin: 0;
            padding: 0;
            height: max-content;
        }


    }
}

.white {
    color: white;
}

.bigtitle {
    position: relative;
    top: -50px;
    left: -8px;
    font-size: 15rem;
    text-align: left;
}

.presentation {
    position: relative;
    padding: 0 10px;
    scroll-snap-align: center;
    height: 100vh;
    background-color: #AF94E0;
    display: flex;
    flex-direction: row;
    justify-content: center;

    .presentation-text {
        display: flex;
        flex-direction: column;
        margin: auto;
        width: 50%;

        p {
            font-size: 1.25rem;
            color: white;

            a {
                color: white
            }
        }
    }

    h2 {
        font-family: 'Bebas', sans-serif;
        display: flex;
        flex-direction: column;
        font-size: 6rem;
        color: #2A114B;
        margin: 0;

        .white {
            color: white;
            position: relative;
            top: -25px;
        }
    }

    /* img {
        height: 75%;
        margin: auto;
    } */

    svg {
        margin: auto;
    }

    .path1 {
        display: none;
    }

    path {
        animation: none;
    }

    .svg-visible {
        visibility: visible;
    }

    .svg-hidden {
        visibility: hidden;
    }

    path {
        stroke-dasharray: 0;
        /* Adjust based on path length */
        stroke-dashoffset: 0;
        /* Start hidden */
        animation: draw 2s linear forwards;
        /* Default animation */
        fill: none;
        /* Optional, ensure only stroke is visible */
        stroke: white;
        /* Set stroke color */
        stroke-width: 2;
        /* Adjust as needed */
        fill-opacity: 0;
        transition: fill-opacity 0.5s ease;
    }

    @keyframes draw {
        to {
            stroke-dashoffset: 0;
            /* Fully draw the path */
        }
    }

}

/* CODE CSS DU PREMIER GRAPHIQUE */
.section__agression {
    position: relative;
    justify-content: center;
    align-items: center;
    gap: 150px;
    width: 100vw;
    display: flex;

    .smallwhite {
        color: white;
        font-size: 1.5rem;
        line-height: 1;
    }

    .sources {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
        gap: 10px;
        
        p{
            font-family: 'Alatsi', sans-serif;
            color: #FFF;
            font-size: 1rem;
            text-align: center;
    
        }
    
        a {
            color: #fff;
            font-size: 0.9rem;
            /* text-decoration: none; */
        }

        .sources-links {
            display: flex;
            flex-direction: column;
        }
    }

}

.section__agression-text {
    width: 400px;
    display: flex;
    flex-direction: column;
    position: relative;
    top: -50px;

    .hidden {
        display: none;
    }
}

.section__agression-text h2 {
    font-size: 4rem;
    margin: 0;
    margin-bottom: 15px;
    font-family: 'Bebas', sans-serif;
    color: #2A114B;

    .white {
        color: white;
    }
}

.section__agression-text p {
    color: white;
    font-family: 'Alatsi', sans-serif;
    font-size: 1.2rem;
}

.section__agression-list {
    font-family: 'Bebas', sans-serif;
    color: white;
    font-size: 3rem;
    position: absolute;
    right: 75px;
    bottom: 0;
}

.section__agression-list-age:hover {
    color: #2A114B;
    cursor: pointer;
}

.section__agression-list-ul {
    list-style: none;
}

.section__agression-img {
    width: 600px;
}

.section__agression-img img {
    position: relative;
    min-width: 50%;
    /* width: 80%; */
    margin: auto;
    height: 600px;
}

.section__agression-info #info-percentage {
    font-family: 'Bebas', sans-serif;
    color: #2A114B;
    font-size: 4rem;
    margin: 0;
}

.section__agression-info p {
    width: 400px;
}

.section__agression-info a {
    color: #4D2A7B;
    text-decoration: none;
}

/* === */
.section {
    scroll-snap-align: center;
    height: 100vh;
    width: 100vw;
}

/* DEUXIEME GRAPHIQUE */
.section_victime {
    position: relative;
    width: 100vw;

    .section__victime-titre {
        margin-left: 100px;
        padding-top: 25px;
        color: #AF94E0;
        font-family: 'Bebas', sans-serif;
        font-size: 2rem;

        h2 {
            margin: 0px;
        }
    }

    .section__victime-graph-info {
        display: flex;
        padding: 50px;
        padding-top: 15px;
        height: 75%;
    }

    .section__victime-graph {
        flex: 1;
        min-width: 65%;
        max-width: 65%;
        height: 100%;
        min-height: 400px;

        .sources {
            display: flex;
            flex-direction: row;
            align-items: center;
            justify-content: center;
            gap: 10px;
            margin-top: 30px;

            p{
                font-family: 'Alatsi', sans-serif;
                color: #FFF;
                font-size: 1rem;
                text-align: center;
    
            }
    
            a {
                color: #fff;
                font-size: 0.9rem;
                /* text-decoration: none; */
            }

            .sources-links {
                display: flex;
                flex-direction: column;
            }
        }

    }

    .section__victime-info {
        width: auto;
        margin-left: 5%;
        margin-right: 6%;

        .section__victime-info-action {
            color: #ffffff;
            font-size: 2.5rem;
            font-family: 'Bebas', sans-serif;

            .purple {
                font-size: 2.5rem;
                color: #AF94E0;
            }

        }

        .section__victime-info-texte {
            color: white;
            font-family: 'Montserrat', sans-serif;
            font-size: 1rem;
            line-height: 1.3;
            font-weight: 400;
            text-align: left;
        }

        span {
            font-family: 'Bebas', sans-serif;
            color: #ffffff;
            font-size: 2rem;
        }

        .line1 {
            font-size: 4.375rem;

            span {
                font-size: 4.375rem;
            }
        }

        .line2 {
            font-size: 2.625rem;

            span {
                font-size: 2.625rem;
            }
        }

        .purple {
            color: #AF94E0;
        }
    }
}

/* === */

.section__condamnation {
    position: relative;
    width: 100vw;
    max-height: 100vh;
    padding: 3% 8% 0 5%;
    display: flex;
    flex-direction: column;

    .section__condamnation-titre-button {
        .section__condamnation-button {
            position: relative;
            padding: 0;
            left: 40px;
            display: flex;
            justify-content: space-around;
            height: 40px;
            width: 150px;

            button {
                width: 40px;
                background-color: white;
                border: none;
                border-radius: 5px;
                transition: all 0.2s ease-in-out;
                display: flex;
                justify-content: center;
                align-items: center;

                &:hover {
                    scale: 1.15;
                }

                img {
                    height: 25px;
                    width: 25px;
                }
            }
        }

        .section__condamnation-titre {
            font-family: 'Bebas', sans-serif;
            color: #AF94E0;

            h2 {
                font-size: 3rem;
                margin: 0;
            }

            p {
                font-size: 2rem;
                color: white;
                margin: 0 0 25px 0;
            }

            .white {
                color: white;
            }
        }
    }

    .section__condamnation-graph-info {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 50px;
        max-height: 65%;

        .section__condamnation-graph {
            min-width: 65%;
            max-width: 65%;
            max-height: 100%;
            transform: translateY(-35px);

            #custom-legend {
                display: flex;
                flex-direction: column;
                flex-wrap: wrap;
                align-items: flex-end;
                gap: 10px;
                margin-right: 24px;
            }
            
            .legend-item {
                display: flex;
                align-items: center;
                width: fit-content;
                gap: 8px;
                font-family: 'Alatsi', sans-serif;
                color: #FFF;
                font-size: 1rem;
            }
            
            .legend-background {
                width: 70px;
                height: 20px;
                background-color: #fff;
                border-radius: 5px;
                display: flex;
                align-items: center;
                justify-content: center;
            }
            
            .color-box {
                width: 70%;
                height: 5px;
                display: inline-block;
                border-radius: 5px;
            }

            .hidden-legend {
                opacity: 0.5;
                text-decoration: line-through;
            }

            canvas {
                width: 100%;
                height: 100%;
            }

            .sources {
                display: flex;
                flex-direction: row;
                align-items: center;
                justify-content: center;
                gap: 10px;
                margin-top: 15px;

                .sources-links {
                    display: flex;
                    flex-direction: column;
                }
            }

            p{
                font-family: 'Alatsi', sans-serif;
                color: #FFF;
                font-size: 1rem;
                text-align: center;
    
            }

            a {
                color: #fff;
                font-size: 0.9rem;
                /* text-decoration: none; */
            }
        }

        .section__condamnation-info {
            height: 100%;
            display: flex;
            flex-direction: column;
            justify-content: flex-end;

            h2 {
                font-size: 4rem;
                font-family: 'Bebas', sans-serif;
                color: #AF94E0;
                margin: 0;
            }

            h3 {
                font-size: 2rem;
                font-family: 'Bebas', sans-serif;
                color: #AF94E0;
                margin: 0px;
            }

            p {
                color: #ffffff;
                font-family: 'Alatsi', sans-serif;
                width: 400px;
            }

            a {
                color: #AF94E0;
                text-decoration: none;
            }
        }
    }
}

/* Section 4 */
.section__carte {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100vw;
    max-height: 100vh;
    background-color: #160133;

    .section__carte-titre {
        width: fit-content;
        color: white;
        text-transform: uppercase;
        font-family: 'Bebas', sans-serif;
        font-size: 2rem;
        margin: auto;
        padding-top: 25px;

        h2,
        h3 {
            margin: 0px;
        }

        .purple {
            color: #AF94E0;
        }
    }

    .section__carte-info {
        text-align: right;
        color: white;
        font-size: 2rem;
        font-family: 'Bebas', sans-serif;

        h3 {
            font-family: 'Bebas', sans-serif;
            color: #AF94E0;
            font-size: 2.5rem;
            margin: 0px;
        }

        p {
            margin: 0;
            padding: 0;
        }
    }

    #map-container {
        flex: 1;
        display: flex;
        width: 90vw;
        max-width: 1200px;
        justify-content: center;
        align-items: center;
        margin: auto;
        position: relative;
        /* gap: 150px; */
        transition: transform 0.5s ease;

        .map-text {
            display: flex;
            flex-direction: column;
            gap: 2rem;
            /* Garde un espace fluide */
            justify-content: flex-start;
            position: absolute;
            top: 50%;
            transform: translateY(-50%);
            right: 0;
            /* Utilisation d'un pourcentage pour éviter les valeurs fixes */
            opacity: 0;
            display: none;
            transition: all 0.5s ease;
        }

        .sources {
            position: absolute;
            bottom: 25px;  
            left: 55%;
            transform: translateX(-55%);          
            display: flex;
            flex-direction: row;
            align-items: center;
            justify-content: center;
            gap: 10px;

            .sources-links {
                display: flex;
                flex-direction: column;
            }
            
            p{
                font-family: 'Alatsi', sans-serif;
                color: #FFF;
                font-size: 1rem;
                text-align: center;
    
            }
    
            a {
                color: #fff;
                font-size: 0.9rem;
                /* text-decoration: none; */
            }
        }

    }

    #map {
        /* flex: 1; */
        max-width: 700px;
        width: 100%;
        height: 100vh;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -55%);
        background-color: transparent;
        transition: all 0.5s ease;
    }

    #region-map {
        width: 400px;
        height: 400px;
        background-color: transparent;
    }

    #map-container.active #map {
        left: 0;
        transform: translate(0, -55%);
    }

    #map-container.active .map-text {
        opacity: 1;
        display: block;
    }

    #tooltip {
        display: none;
        position: absolute;
        background: rgba(255, 255, 255, 0.9);
        border: 1px solid #ccc;
        padding: 8px;
        border-radius: 5px;
        pointer-events: none;
        z-index: 1000;
        font-size: 14px;
        max-width: 250px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        font-family: "Montserrat", sans-serif;
        font-weight: 600;

        .tooltip-title {
            font-weight: 800;
            margin: 0 0 5px 0;
            font-family: "Montserrat", sans-serif;
        }

        .tooltip-data {
            font-weight: 800;
            color: #4D2A7B;
            font-size: 0.9rem;
        }
    }
}

.hidden {
    display: none !important;
}

.visible {
    display: block;
}

/* =============== */

.section:nth-of-type(1) {
    background-color: #967DC4;
}

.section:nth-of-type(2) {
    background-color: #4D2A7B;
}

.section:nth-of-type(3) {
    background-color: #2A114B;
}

/* Code du footer pour une largeur minimum de 1113 pixel */

footer {
    width: 100vw;
    background-color: #110521;
    display: flex;
    align-items: center;
    justify-content: space-between;
    scroll-snap-align: end;
    font-family: 'Bebas', sans-serif;

    .footer__container {
        padding: 1.5rem 5rem 0rem 5rem;
    }
}


.footer__container-title {
    color: #AF94E0;
    height: fit-content;
    margin: 0px;
    -webkit-margin-before: 0px;
    -webkit-margin-after: 0px;

    h2 {
        margin: 0px;
        -webkit-margin-before: 0px;
        -webkit-margin-after: 0px;
    }
}

.footer__title {
    margin: 0;
    font-size: 2rem;
}

.footer__title--name {
    font-size: 9rem;
}

.footer__title--h2 {
    position: relative;
    top: 25px;
}

.footer__list {
    margin: 0;
    text-align: right;
}

.footer__list-component button {
    color: white;
    list-style: none;
    font-size: 2rem;
    transition: all 0.5s ease-in-out;
    text-decoration: none;
    border: none;
    background-color: transparent;
    font-family: 'Bebas', sans-serif;
}

.footer__list-component button:hover {
    color: #AF94E0;
    cursor: pointer;
}

.footer__title--name {
    position: relative;
}

.footer__title {
    margin: 0;
}

.footer__container-modal {
    visibility: hidden;
}

.footer__title--h2 {
    margin-top: 50px;
    margin-bottom: 40px;
}

.footer__list {
    margin: 0;
    text-align: right;
}

.footer__list-component {
    color: white;
    list-style: none;
    font-size: 2rem;
}

.footer__list-component a {
    text-decoration: none;
    color: white;
    transition: all 0.5s ease-in-out;
}

.footer__list-component a:hover {
    color: #AF94E0;
    cursor: pointer;
}

footer ul {
    list-style-type: none;
    padding: 0;
}

/* Code d'affichage des pop up des mentions légales, sources et contact */

/* Style général pour cacher la modale par défaut */
.modal1,
.modal2 {
    visibility: hidden;
    opacity: 0;
    position: fixed;
    display: flex;
    justify-content: center;
    align-items: center;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100vh;
    width: 100vw;
    background: rgba(45, 44, 44, 0.5);
    transition: all .4s;
}

.no-scroll {
    overflow: hidden;
}

.modal1:target,
.modal2:target {
    visibility: visible;
    opacity: 1;
}

.modal2 .modal {
    height: fit-content;
}

.modal1 .modal {
    height: 90vh;
}

.modal {
    width: 70vw;
    border-radius: 10px;
    overflow: hidden;
    margin: auto;
}

.modal-border {
    border: 2px solid #2A114B;
    border-radius: 10px;
    overflow: hidden;
    margin: auto;
    padding: 25px;
    position: relative;
}

/* Contenu de la modale */
.mention,
.contact {
    overflow-y: auto;
    position: relative;
    background-color: #fff;
    padding: 25px;
    height: fit-content;
    max-height: 100%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    animation: fadeIn 0.5s;
    scroll-behavior: auto;
    font-family: 'Montserrat', sans-serif;

    h2,
    h3 {
        font-family: 'Bebas', sans-serif;
        margin: 0;
    }

    h2 {
        font-size: 2rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    a { 
        color: black;
        text-decoration: underline;
    }
}

.contact {

    .contact-details {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 50px;

        .contact-detail {
            width: 300px;
            border-radius: 10px;
            padding: 20px;
            border: 2px solid #000;
        }
    }

    ul {
        display: flex;
        flex-direction: column;
        gap: 10px;

        li {
            display: flex;
            align-items: center;
            gap: 10px;

            a {
                text-decoration: none;
                color: black;

                &:hover {
                    text-decoration: underline;
                }
            }
        }
    }

    img {
        width: 25px;
        height: 25px;
    }
}

.mention-content, 
.contact-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Bouton de fermeture */
.close {
    background-color: #fff;
    padding: 10px;
    float: right;
    cursor: pointer;
    text-decoration: none;
    position: absolute;
    top: 15px;
    right: 15px;
    border-radius: 50%;
    overflow: hidden;
    z-index: 1;
    width: 60px;
    height: 60px;
    transition: all 0.5s ease;
    
    img {   
        width: 40px;
        height: 40px;
        padding: 10px;
        border-radius: 50%;
        background-color: #2A114B;
        margin: auto;
        
    }
}




/* Animation d’apparition */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}