:root {
    --couleur-principale: #6BC4A5;
    --couleur-clair: #FFF;
    --taille-police: 12pt;
    /*  var(--couleur-principale) */
    --separator-little-side: 10px;
    --header-heigt: 80px;
    --taille-bulle: 100px;
}

@font-face {
    font-family: Ailerons;
    src: url("./fonts/Ailerons-Typeface.otf");
}
@font-face {
    font-family: Nirmala;
    src: url("./fonts/Nirmala.ttf");
}

*{
    font-family: Ailerons, serif;
}

.nirmala{
    font-family: nirmala, serif;
}

.uppercase{
    text-transform: uppercase;
}

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    /*overflow: hidden;*/
    scroll-behavior: smooth;
    font-size: var(--taille-police);
    background-color: var(--couleur-principale);
}

body {
    display: flex;
    flex-direction: column;
}

.section {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.image-container {
    position: relative;
    width: 100%;
    height: 100%;
}

#image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    opacity: 0.7;
}

h1 {
    color: white;
}

#section1 {
    background-color: #3498db;
    flex-direction: column;
}

#section1 .centered-text{
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 10;
    transform: translateX(-50%) translateY(-50%);
    pointer-events: none;
}

#section1 .centered-text h1{
    font-size: 4em;
    letter-spacing: -0.2em;
}

#section1 .centered-text p.subtitre {
    color: white;
    font-size: 1.5em;
    margin: -25px 0 0 9px;
    letter-spacing: 0.37em;
}

#section1 .separator{
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--couleur-principale);
    width: var(--separator-little-side);
    height: 25%;
}

#section1 .separator.top {
    top: 0;
}

#section1 .separator.bottom {
    bottom: 0;
}

#section2 {
    background-color: #3498db;
    flex-direction: column;
    background-image: url("img/fond.jpg");
    background-size: cover;
}

#section2 .top {
    align-items: center;
    justify-content: center;
    position: relative;
    background-color: var(--couleur-principale);
    box-sizing: border-box; /* Inclure les paddings */
}

#section2 .half-height .text {
    font-size: 2em;
    text-align: justify;
}

#section2 .separator {
    width: var(--separator-little-side);
    height: 50vh;
    background-color: var(--couleur-principale);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

#section2 div.conteneur {
    background-color: var(--couleur-principale);
    text-align: center;
    width: 100vw;
    height: 50vh;
    display: flex;
    padding-top: 80px;
}

#section3 {
    flex-direction: column;
    padding: var(--header-heigt) 20px;
    /*color: white;*/
}

#section4 {
    background-color: #e74c3c;
    flex-direction: column;
}

.half-height {
    width: 100%;
    height: 50vh;
    display: flex;
}

.deco-bottom{
    height: var(--separator-little-side);
    width: 100%;
    background-color: var(--couleur-principale);
    position: absolute;
    z-index: 2;
    bottom: 0;
}

.deco-top{
    height: var(--separator-little-side);
    width: 100%;
    background-color: var(--couleur-principale);
    position: absolute;
    z-index: 2;
    top: 0;
}

/* Header styles */
#header {
    /*background-color: var(--couleur-clair);*/
    display: flex; /* Change to block so that opacity transition can be applied */
    opacity: 0; /* Initial opacity */
    width: 100%;
    height: var(--header-heigt); /* Ajuster la hauteur au besoin */
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    transition: opacity 0.3s ease; /* Transition for opacity */
    box-sizing: border-box; /* Inclure les paddings dans la largeur */
    pointer-events: none; /* Permet à la souris de passer au travers du header */
}

/* Style when header is visible */
#header.visible {
    opacity: 1;
    /*opacity: 0;*/
    pointer-events: auto; /* Allow interaction when header is visible */
}

.logo {

}

.logoText{
    text-transform: uppercase;
    font-weight: bold;
    font-size: 2.5em;
    letter-spacing: -5px;
}

.vert{
    color: var(--couleur-principale);
}

.menu-toggle {
    cursor: pointer;
}

/* Menu styles */
#menu {
    display: none;
    z-index: 999; /* Assure que le menu est en dessous du canvas */
}

#menu.active {
    display: block;
}

#menu ul {
    list-style: none;
    padding: 0;
}

#menu ul li {
    display: inline;
    margin-right: 20px;
}

#menu ul li a {
    text-decoration: none;
    color: black;
    font-size: 1rem;
}

/* Cursor style for the blurred area */
.cursor-blur {
    cursor: pointer; /* You can change this to any cursor style you prefer */
}

.deeperBtn{
    position: absolute;
    top: 65%;
    left: 50%;
    z-index: 10;
    transform: translateX(-50%);
    color: white;
}

.scroll-down-btn {
    margin-top: 5px;
    cursor: pointer;
    animation: moveUpDown 1s infinite alternate;
}

.scroll-down-btn .arrow {
    display: block;
    width: 20px;
    height: 20px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    margin: -10px auto;
}

.logoText.logo-fond-blanc .text-clair {
    color: var(--couleur-principale); !important;
}

.skills-container{
    height: 100vh;
}

.skills-title {
    font-size: 2.5em;
    margin-bottom: 40px;
    text-align: center;
}

.desktop-only {
    display: block;
}
.mobile-only {
    display: none;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
}

.skill-card {
    padding: 10px;
}

.skill-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 2em;
    font-weight: bold;
    margin-bottom: 10px;
}

.skill-percent {
    color: var(--couleur-clair);
}

.text-clair{
    color: var(--couleur-clair);
}

p.text{
    font-size: 1.1em;
}

.skill-card p {
    /*font-size: 0.9em;*/
    margin-bottom: 15px;
}

.skill-bar {
    height: 3px;
    background-color: rgba(0,0,0,.1);
    position: relative;
    border-radius: 10px;
}

.skill-fill {
    height: 3px;
    background-color: rgba(0,0,0,1);
    position: absolute;
    top: 0;
    left: 0;
    border-radius: 10px;
}

.skill-circle {
    width: 18px;
    height: 18px;
    border: 2px solid #000;
    background-color: var(--couleur-clair);
    border-radius: 50%;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
}

.projects-top {
    display: flex;
    width: 100%;
    background-color: white;
    height: 75%;
    position: relative;
}

.vertical-separator {
    position: absolute;
    top: 0;
    height: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 10px;
    background-color: var(--couleur-principale);
    z-index: 1;
}

.project-image {
    flex: 1;
    margin: 40px 15px;
    display: flex;
    align-items: center;
}

.project-image img {
    width: 100%;
    object-fit: cover;
    border-radius: 8px;
    transition: opacity 0.5s ease-in-out;
    opacity: 1;
}

.project-description {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-family: "Ailerons", sans-serif;
    font-size: 1.5em;
    padding: 20px;
    line-height: 1.6em;
    transition: opacity 0.5s ease-in-out;
    opacity: 1;
}

/* Bas de la section projet : grille 4 colonnes */
.projects-bottom {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    width: 100%;
    height: 25%;
}

.project-tile {
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: "Ailerons", sans-serif;
    font-size: 1.2em;
    color: #6BC4A5;
    letter-spacing: 0.3em;
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.3s ease;
}

.project-tile:hover {
    transform: scale(1.05);
    background-color: rgba(255, 255, 255, 0.1); /* léger survol */
}

/* Couleurs personnalisées */
.tile1 { background-color: black; color: #6BC4A5; }
.tile2 { background-color: #444; color: #6BC4A5; }
.tile3 { background-color: #3f514d; color: white; }
.tile4 { background-color: #6BC4A5; color: black; }

.bubble.move-left {
    transform: translate(-400px, 0);
    opacity: 0.3;
}

#bubble-stack {
    position: fixed;
    bottom: 20px;
    left: 20px;
    display: flex;
    flex-direction: column-reverse;
    gap: 8px;
    z-index: 1000;
}

.bubble {
    position: absolute;
    background: var(--couleur-principale);
    color: white;
    font-family: "Ailerons", sans-serif;
    font-size: 1.2em;
    width: var(--taille-bulle);
    height: var(--taille-bulle);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    z-index: 999;
    opacity: 0.9;
    transform: translate(-50%, -50%);
    transition: transform 3s ease-out, opacity 0.5s;
}

.bubble.collected {
    position: relative;
    transform: none;
    opacity: 1;
    animation: popIn 0.4s ease;
}

/* ---------------------- @keyframes --------------------------- */

@keyframes moveUpDown {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(10px); /* Déplacement vers le bas de 10px */
    }
}

@keyframes pulse {
    0% {
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
}

@keyframes popIn {
    from {
        transform: scale(0.6);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* ---------------------- @media --------------------------- */

/* Responsive mobile (2 colonnes) */
@media screen and (max-width: 768px) {
    .projects-top {
        flex-direction: column;
    }

    .project-image, .project-description {
        margin: 20px;
    }

    .project-description {
        width: 100%;
        margin: 20px 0;
    }

    .projects-bottom {
        grid-template-columns: repeat(2, 1fr);
        height: auto;
    }

    .project-tile {
        padding: 40px 0;
    }

    .vertical-separator {
        display: none;
    }
}