@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');
*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    scroll-behavior: smooth;
    font-family: "Poppins", sans-serif;
}

:root{
    --bg-color: #080808;
    --second-bg-color: #131313;
    --text-color: white;
    --main-color: #00ffee;
}

html{
    font-size: 60%;
    overflow-x: hidden;
}

body{
    background: var(--bg-color);
    color: var(--text-color);
}

.header {
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    padding: 2rem 12% 2rem;
    background: #111;
    border-bottom: 1px solid #1effd422;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 5;
}
.logo{
    font-size: 3rem;
    color: var(--text-color);
    font-weight: 800;
    cursor: pointer;
    transition: 0.3s ease;
}
.logo:hover{
    transform: scale(1.1)
}
.logo span{
    text-shadow: 0 0 25px var(--main-color);
}
.navbar a{
    font-size: 1.8rem;
    color: var(--text-color);
    margin-left: 4rem;
    font-weight: 500;
    transition: 0.3s ease;
    border-bottom: 3px solid transparent;
}
.navbar a:hover,
.navbar a.active{
    color: var(--main-color);
    border-bottom: 3px solid var(--main-color)
}
#menu-icon{
    font-size: 3.6rem;
    color: var(--main-color);
    display: none;
}

section{
    min-height: 100vh;
    padding: 10rem 12% 10rem;
}
.home{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15rem;
}
.home-content{
    display: flex;
    flex-direction: column;
    align-items: baseline;
    text-align: left;
    justify-content: center;
    margin-top: 3rem;
}
span{
    color: var(--main-color);
}
.logo span{
    color: var(--main-color);
}
.home-content h3{
    margin-top: 1rem;
    margin-bottom: 2rem;
    font-size: 2.5rem;
}
.home-content h1{
    font-size: 3rem;
    font-weight: 700;
    margin-top: 1.5rem;
    line-height: 1;
}
.home-img{
    border-radius: 50%;
}
.home-img img{
    display: none;              /* A modifier en supprimant le display */
    position: relative;
    top: 3rem;
    width: 22vw;
    border-radius:50%;
    box-shadow: 0 0 25px var(--main-color);
    cursor: pointer;
    transition: 0.4s ease-in-out;
}
.home-img img:hover{
    box-shadow: 0 0 25px var(--main-color),
                0 0 50px var(--main-color);
}
.home-content p{
    font-size: 1.5rem;
    font-weight: 500;
    line-height: 1.8;
    max-width: 1000px;
}
.social-icons a{
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4.5rem;
    height: 4.5rem;
    background: transparent;
    border: 2px solid var(--main-color);
    font-size: 2.5rem;
    border-radius: 50%;
    color: var(--main-color);
    margin: 3rem 1.5rem 3rem 0;
    transition: 0.3s ease-in-out;
}
.social-icons a:hover{
    color: var(--text-color);
    transform: scale(1.3)translateY(-5px);
    box-shadow: 0 0 25px var(--main-color);
    background-color: var(--main-color);
}
.btn{
    display: inline-block;
    padding: 1rem 2.8rem;
    background: var(--main-color);
    box-shadow: 0 0 25px var(--main-color);
    border-radius: 4rem;
    font-size: 1.6rem;
    color: black;
    border: 2px solid transparent;
    letter-spacing: 0.1rem;
    font-weight: 600;
    transition: 0.3s ease-in-out;
    cursor: pointer;
}
.btn:hover{
    transform: scale(1.05);
    box-shadow: 0 0 50px var(--main-color);
}
.btn-group{
    display: flex;
    align-items: center;
    gap: 1.5rem;
}
.btn-group a:nth-of-type(2){
    background-color: black;
    color: var(--main-color);
    border: 2px solid var(--main-color);
    box-shadow: 0 0 25px transparent;
}
.btn-group a:nth-of-type(2):hover{
    box-shadow: 0 0 25px var(--main-color);
    background-color: var(--main-color);
    color: black;
}
.text-animation {
    font-size: 34px;
    font-weight: 600;
    min-width: 280px;
}

.text-animation span {
    position: relative;
    color: var(--main-color);
}

/* Texte dynamique */
.text-animation span::before {
    content: "Étudiant en informatique";
    animation: words 20s infinite;
}

/* Curseur propre */
.text-animation span::after {
    content: "";
    position: absolute;
    right: -8px;
    width: 2px;
    height: 100%;
    background-color: var(--main-color);
    animation: blink 0.7s infinite;
}

/* Blink curseur */
@keyframes blink {
    50% {
        opacity: 0;
    }
}

/* Changement des mots */
@keyframes words {
    0%, 20% {
        content: "Étudiant en informatique";
    }
    21%, 40% {
        content: "Développeur Web";
    }
    41%, 60% {
        content: "Développeur Mobile";
    }
    61%, 80% {
        content: "Backend Developer";
    }
    81%, 100% {
        content: "Concepteur d'applications";
    }
}
/* A modifier */

.heading{
    font-size: 4rem;
    text-align: center;
    margin: 5rem 0;
}

/* Styles pour la section formations */
.formations{
    padding: 100px 15px;
    background: var(--second-bg-color);
}
.formations h2{
    margin-bottom: 5rem;
}
.timeline-items{
    max-width: 1200px;
    margin: auto;
    display: flex;
    flex-wrap: wrap;
    position: relative;
}
.timeline-items::before{
    content: "";
    position: absolute;
    width: 5px;
    height: 100%;
    background-color: var(--main-color);
    left: calc(50% - 1px);
}
.timeline-item{
    margin-bottom: 40px;
    width: 100%;
    position: relative;
    animation: scale-up linear both; /* Animation */
    animation-timeline: view(block); /* Animation */
    animation-range: cover 0% contain 30%; /* Animation */
}
.timeline-item:last-child{
    margin-bottom: 0;
}
.timeline-item:nth-child(odd){
    padding-right: calc(50% + 30px);
    text-align: right;
}
.timeline-item:nth-child(even){
    padding-left: calc(50% + 30px);
}
.timeline-dot{
    height: 21px;
    width: 21px;
    background-color: var(--main-color);
    box-shadow: 0 0 25px var(--main-color),
                0 0 50px var(--main-color);
    position: absolute;
    left: calc(50% - 8px);
    border-radius: 50%;
    top: 10px;
}
.timeline-date{
    font-size: 20px;
    font-weight: 800;
    color: white;
    margin: 6px 0 15px;
}
.timeline-content{
    background-color: var(--bg-color);
    border: 3px solid var(--main-color);
    padding: 30px 30px;
    border-radius: 4rem;
    box-shadow: 0 0 10px var(--main-color);
    cursor: pointer;
    transition: 0.3s ease-in-out;
}
.timeline-content:hover{
    transform: scale(1.05);
    box-shadow: 0 0 25px var(--main-color);
}
.timeline-content h3{
    font-size: 20px;
    color: white;
    margin: 0 0 10px;
    font-weight: 500;
}
.timeline-content p{
    font-size: 16px;
    color: white;
    font-weight: 300;
    line-height: 22px;
}
::-webkit-scrollbar{
    width: 15px;
}
::-webkit-scrollbar-thumb{
    background-color: var(--main-color);
}
::-webkit-scrollbar-track{
    background-color: var(--bg-color);
    width: 50px;
}

/* Styles pour la section competences */
.competences{
    padding: 100px 15px;
    background: var(--bg-color);
}
.competences h2{
    margin-bottom: 5rem;
}
.skills-items{
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* a revoir pour afficher 4 colonnes */
    gap: 50px 50px;
    position: relative;
    /*max-width: 1000px;*/
    margin: 0 150px;
}
@media (max-width: 1024px) {
    .skills-items {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .skills-items {
        grid-template-columns: 1fr;
    }
}
.skills-item{
    font-size: 15px;
    background-color: var(--bg-color);
    border: 3px solid var(--main-color);
    padding: 30px 20px;
    border-radius: 2rem;
    box-shadow: 0 0 10px var(--main-color);
    cursor: pointer;
    transition: 0.3s ease-in-out;
}
.skills-item:hover{
    transform: scale(1.1);
    box-shadow: 0 0 25px var(--main-color);
}
.progress-bar {
    width: 100%;
    background-color: var(--text-color);
    border-radius: 20px;
    overflow: hidden;
    height: 10px;
    margin-top: 10px;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
}
.progress {
    height: 100%;
    background: var(--main-color);
    text-align: center;
    color: white;
    font-weight: bold;
    line-height: 10px;
    width: 0%;
    transition: width 1s ease-in-out;
    transition: width 0.5s ease-in-out;
}
h3 i {
    margin-right: 8px;
    color: var(--main-color);
}

/* Styles pour la section experiences */
.experiences{
    padding: 100px 15px;
    background: var(--second-bg-color);
}
.experiences h2{
    margin-bottom: 5rem;
}
.travail-items{
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin: auto;
    gap: 40px;
    max-width: 1200px;
}
.travail-item{
    font-size: 15px;
    background-color: var(--bg-color);
    border: 3px solid var(--main-color);
    padding: 30px 20px;
    border-radius: 5rem;
    box-shadow: 0 0 10px var(--main-color);
    cursor: pointer;
    transition: 0.3s ease-in-out;
}
.travail-item:hover{
    transform: scale(1.1);
    box-shadow: 0 0 25px var(--main-color),
                0 0 50px var(--main-color);
}
.travail-date,
.association-date{
    font-size: 2rem;
}
.travail-content h3,
.association-content h3{
    font-size: 2rem;
}
.travail-content p,
.association-content p{
    font-size: 2rem;
}

/* Styles pour la section association */
.association-items{
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin: auto;
    gap: 40px;
    max-width: 1200px;
}
.association-item{
    font-size: 15px;
    background-color: var(--bg-color);
    border: 3px solid var(--main-color);
    padding: 30px 20px;
    border-radius: 5rem;
    box-shadow: 0 0 10px var(--main-color);
    cursor: pointer;
    transition: 0.3s ease-in-out;
}
.association-item:hover{
    transform: scale(1.1);
    box-shadow: 0 0 25px var(--main-color),
                0 0 50px var(--main-color);
}

/* Styles pour la section projet */
/* ===== SECTION PROJETS ===== */
.projets {
    padding: 60px 20px;
    background-color: #0a0a0a;
}

.projets-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

/* ===== CARTE ===== */
.projet-item {
    background: #111;
    border: 1px solid #1effd422;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    
    opacity: 0;
    transform: translateY(40px);

    transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.projet-item.visible {
    opacity: 1;
    transform: translateY(0);
}
.projet-item:hover {
    transform: translateY(0) scale(1.02);
    box-shadow: 0 0 30px #1effd420;
    border-color: #1effd4aa;
}

/* ===== IMAGE ===== */
.projet-image-wrapper {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.projet-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.projet-item:hover .projet-image-wrapper img {
    transform: scale(1.05);
}

/* Badge date sur l'image */
.projet-date {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #1effd4;
    color: #0a0a0a;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
}

/* ===== BODY ===== */
.projet-body {
    padding: 20px 20px 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.projet-body h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1effd4;
    line-height: 1.3;
    margin: 0;
}

.projet-body p {
    font-size: 0.9rem;
    color: #aaa;
    line-height: 1.6;
    margin: 0;

    /* Troncature */
    display: -webkit-box;
    -webkit-line-clamp: 2; /* nombre de lignes visibles */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ===== TECHNOS ===== */
.technos {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
    padding-top: 8px;
}

.techno-tag {
    font-size: 0.72rem;
    font-weight: 600;
    color: #1effd4;
    background: #1effd412;
    border: 1px solid #1effd444;
    padding: 3px 10px;
    border-radius: 20px;
    letter-spacing: 0.05em;
}

/* ===== FOOTER ===== */
.projet-footer {
    padding: 16px 20px 20px;
}

.projet-footer .btn {
    display: block;
    text-align: center;
    background: transparent;
    color: #1effd4;
    border: 2px solid #1effd4;
    padding: 10px 20px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}

.projet-footer .btn:hover {
    background: #1effd4;
    color: #0a0a0a;
}

/* Styles pour la section contact */
.contact{
    background-color: var(--second-bg-color);
}
.contact h2{
    margin-bottom: 3rem;
    color: white;
}
.infos-mail{
    display: grid;
    grid-template-columns: 1fr 1fr; /* Crée deux colonnes de taille égale */
    gap: 20px;
}

.contact .infos{
    display: flex;
    flex-direction: column;
    justify-content: left;
    gap: 2rem;
    margin: auto;
    width: 100%;
}
.contact .infos h3{
    font-size: 2.2rem;
    color: var(--main-color);
}
.contact .infos p {
    font-size: 1.7rem;
    color: var(--main-color);
    transition: color 0.3s ease; /* Ajout d'une transition pour un effet plus fluide */
}

.contact .infos p:hover {
    color: white; /* Change la couleur en blanc au survol */
}
.contact .infos p i{
    font-size: 2rem;
    margin-right: 8px;
    color: var(--main-color);
}   
.contact form{
    display: flex;
    align-items: center;
    justify-content: right;
    gap: 3rem;
    margin: 5rem 5rem;
    text-align: center;
}
.contact form .input-box{
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}
.contact form .input-box input,
.contact form textarea{
    width: 100%;
    padding: 1rem;
    font-size: 1.8rem;
    color: var(--text-color);
    background: var(--second-bg-color);
    border-radius: 2rem;
    border: 2px solid var(--main-color);
    margin: 1.5rem 0;
    resize: none;
}
.contact form .btn{
    margin-top: 2rem;
}
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Styles pour le footer */
.footer{
    position: relative;
    bottom: 0;
    width: 100%;
    padding: 40px 0;
    background-color: var(--bg-color);
}
.footer .social{
    text-align: center;
    padding-bottom: 15px;
    color: var(--main-color);
}
.footer .social a{
    font-size: 25px;
    color: var(--main-color);
    border: 2px solid var(--main-color);
    width: 42px;
    height: 42px;
    line-height: 42px;
    display: inline-block;
    text-align: center;
    border-radius: 50%;
    margin: 0 10px;
    transition: 0.3s ease-in-out;
}
.footer .social a:hover{
    transform: scale(1.2)translateY(-10px);
    background-color: var(--main-color);
    color: black;
    box-shadow: 0 0 25px var(--main-color);
}
.footer .copyright{
    margin-top: 20px;
    text-align: center;
    font-size: 16px;
    color: white;
}

/* Écrans larges */
@media(max-width: 1285px){
    html{
        font-size: 55%;
    }
    .skills-items{
        padding-bottom: 7rem;
        grid-template-columns: repeat(2,1fr);
        margin: 0 5rem;
    }
}

/* Écrans moyens et tablettes */
@media(max-width: 991px){
    header{
        padding: 2rem 3%;
    }
    section {
        padding: 6rem 5% 2rem; /* Réduction des marges */
    }
    .home {
        margin: 4rem 2rem; /* Réduction de la marge latérale */
    }
    .home-content h1 {
        font-size: 6rem; /* Éviter les textes trop grands */
    }
    .timeline-items::before{
        left: 7px;
    }
    .timeline-item:nth-child(odd){
        padding-right: 0;
        text-align: left;
    }
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even){
        padding-left: 37px;
    }
    .timeline-dot{
        left: 0;
    }
    .competences{
        padding-bottom: 7rem;
    }
    .contact {
        flex-direction: column;
    }
    .footer{
        padding: 2rem 3%;
    }
}

/* Petites tablettes et grands smartphones */
@media(max-width:895px){
    #menu-icon {
        display: block;
        font-size: 2.5rem;
        cursor: pointer;
    }
    .navbar {
        position: absolute;
        top: 100%;
        right: 0;
        width: 60%; /* Augmenté pour plus de lisibilité */
        padding: 1rem 3%;
        background: rgba(0, 0, 0, 0.9);
        backdrop-filter: blur(15px);
        border-radius: 10px;
        display: none;
        flex-direction: column;
        align-items: center;
        transition: all 0.3s ease-in-out;
    }
    .navbar.active {
        display: flex; /* Utilisation de flex pour un meilleur alignement */
    }
    .navbar a {
        font-size: 2rem;
        margin: 2rem 0;
        color: white;
        text-align: center;
    }
    .home{
        flex-direction: column-reverse;
        margin: 5rem 4rem;
    }
    .home-content h3{
        font-size: 2.6rem;
    }
    .home-content h1{
        font-size: 8rem;
        margin-top: 3rem;
    }
    .home-content p{
        max-width: 600px;
        margin: 0 auto;
    }
    .home-img img{
        width: 56vw;
    }
}

/* Smartphones et petites tablettes */
@media screen and (max-width: 768px) {
    .infos-mail {
        grid-template-columns: 1fr; /* Empiler les deux blocs en une seule colonne sur les écrans plus petits */
    }

    /* Faire en sorte que .infos apparaisse en premier */
    .infos {
        order: -1; /* Place la div .infos en haut */
        max-width: 90%; /* Réduire la largeur de .infos sur des écrans plus petits */
        margin: 0 auto; /* Centrer la div .infos */
        justify-content: center;
    }

    .input-group {
        flex-direction: column; /* Assurer que les champs sont en colonne */
    }

    .input-box {
        flex-direction: column; /* Empiler les champs de texte un au-dessus de l'autre */
        width: 100%;
    }

    .input-box input {
        width: 100%; /* Faire en sorte que les inputs prennent toute la largeur */
    }

    .input-group2 {
        width: 100%; /* Assurer que la deuxième section du formulaire occupe toute la largeur */
    }
    
    /* Ajustements supplémentaires pour la timeline et les skills */
    .timeline-content {
        padding: 20px;
    }
    
    .skills-items {
        grid-template-columns: 1fr;
        gap: 30px;
        margin: 0 2rem;
    }
    
    /* Ajustements pour le menu */
    .navbar a {
        margin: 1.5rem 0;
        font-size: 1.8rem;
    }
}

/* Petits smartphones */
@media screen and (max-width: 480px) {
    /* Pour les petits écrans comme les téléphones */
    html {
        font-size: 45%;
    }
    
    .header {
        padding: 1.5rem 4%;
    }
    
    .logo {
        font-size: 2.2rem;
    }
    
    .infos h3 {
        font-size: 1.2em; /* Réduire la taille du titre */
    }

    .input-group2 textarea {
        height: 150px; /* Ajuster la taille du champ textarea pour les petits écrans */
        width: 100%;
    }

    .btn {
        padding: 12px 20px; /* Ajuster la taille du bouton */
    }
    
    /* Ajustements pour l'affichage du contenu principal */
    .home-content h1 {
        font-size: 5rem;
    }
    
    .home-img img {
        width: 70vw;
    }
    
    .social-icons a {
        width: 3.5rem;
        height: 3.5rem;
        font-size: 1.8rem;
    }
    
    /* Ajustements pour la section compétences */
    .skills-item {
        padding: 20px 15px;
    }
    
    /* Expériences */
    .travail-item, .association-item {
        padding: 20px 15px;
    }
    
    /* Footer */
    .footer ul li {
        padding: 0 8px;
    }
}

/* Très petits smartphones */
@media screen and (max-width: 350px) {
    html {
        font-size: 40%;
    }
    
    .home-content h1 {
        font-size: 4rem;
    }
    
    .btn {
        padding: 0.8rem 1.5rem;
        font-size: 1rem;
    }
    
    .home-img img {
        width: 80vw;
    }
    
    .timeline-content, .skills-item, .travail-item, .association-item {
        padding: 15px 10px;
    }
}

