@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

header h1, header p {
    animation: fadeIn 1s ease-in-out;
}
/* Styles globaux */
body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    background: #121212;
    color: #f1f1f1;
    line-height: 1.6;
    background: linear-gradient(-45deg, #1a1a40, #3a0ca3, #4361ee);
    background-size: 400% 400%;
    animation: gradientMove 8s infinite alternate;
    margin: 0;
    overflow-x: hidden;

}
@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    100% { background-position: 100% 50%; }
}
canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.logo {
    width: 100px;
    height: auto;
    display: block;
    margin: 0 auto 10px;
}


/* En-tête */
header {
    text-align: center;
    padding: 30px;
    background: linear-gradient(135deg, #1f1f1f, #3e3e3e);
    color: #00ff88;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

header h1 {
    font-size: 2.5rem;
    margin: 0;
}

header p {
    font-style: italic;
    color: #aaffc3;
}

/* Navigation */
nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    background: #1f1f1f;
    padding: 10px 0;
    border-bottom: 3px solid #00ff88;
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav a {
    color: #f1f1f1;
    text-decoration: none;
    font-weight: bold;
    padding: 10px 15px;
    border-radius: 5px;
    transition: background 0.3s ease, transform 0.2s ease;
}

nav a:hover {
    background: #00ff88;
    color: #121212;
    transform: scale(1.1);
}

/* Sections */
section {
    max-width: 900px;
    margin: 20px auto;
    padding: 20px;
    background: #1f1f1f;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

section h2 {
    color: #00ff88;
    border-bottom: 2px solid #00ff88;
    padding-bottom: 5px;
}

/* Badges */
.badge-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    padding: 20px;
}

.badge {
    display: inline-block;
    padding: 8px 15px;
    font-size: 16px;
    font-weight: bold;
    color: white;
    background: linear-gradient(45deg, #ffcc00, #ff6600);
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(255, 204, 0, 0.8);
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
}

.badge:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(255, 102, 0, 1);
    animation: glow 1s infinite alternate;
}

@keyframes glow {
    0% { box-shadow: 0 0 10px rgba(255, 204, 0, 0.8); }
    100% { box-shadow: 0 0 20px rgba(255, 102, 0, 1); }
}


/* Projets */
#projects {
    text-align: center;
    color: white;
    padding: 20px;
}
.project {
    margin-bottom: 15px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.7);
    border-left: 4px solid #00ff88;
    border-radius: 8px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    transition: transform 0.5s ease-in-out;
    transform-style: preserve-3d;
}

.project h3 {
    color: #00ff88;
    margin-top: 0;
}

.project:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 255, 136, 0.5);
    transform: rotateY(10deg)
}

/* Liens */
ul {
    list-style-type: none;
    padding: 0;
    text-align: center;
}

ul li {
    margin: 10px 0;
}

ul a {
    color: #00ff88;
    text-decoration: none;
    font-weight: bold;
}

ul a:hover {
    text-decoration: underline;
}

/* Pied de page */
footer {
    text-align: center;
    padding: 10px;
    background: #121212;
    color: #aaffc3;
    border-top: 3px solid #00ff88;
}

/* ------------------------ MEDIA QUERIES ------------------------ */

/* Tablettes (max-width: 768px) */
@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }

    header p {
        font-size: 1rem;
    }

    nav {
        flex-wrap: wrap;
        gap: 10px;
    }

    nav a {
        padding: 8px 12px;
        font-size: 0.9rem;
    }

    section {
        padding: 15px;
        margin: 15px auto;
    }

    .badge {
        padding: 6px 10px;
        font-size: 0.8rem;
    }

    .project {
        padding: 10px;
    }
}

/* Smartphones (max-width: 480px) */
@media (max-width: 480px) {
    body {
        font-size: 14px;
    }

    header {
        padding: 20px;
    }

    header h1 {
        font-size: 1.8rem;
    }

    nav {
        flex-direction: column;
        align-items: center;
        gap: 5px;
    }

    nav a {
        display: block;
        width: 80%;
        text-align: center;
    }

    section {
        padding: 10px;
    }

    .badge-container {
        flex-direction: column;
        gap: 5px;
        align-items: center;
    }

    .badge {
        width: 100%;
        text-align: center;
        padding: 5px;
    }

    .project {
        padding: 10px;
        margin-bottom: 10px;
    }

    footer {
        font-size: 0.8rem;
        padding: 10px;
    }
}
