:root {
    --bg: #f6f8fa;
    --text: #24292f;
    --accent: #0099cc;
    --secondary: #00b36b;
    --gray: #57606a;
    --card: #ffffff;
}

* { margin:0; padding:0; box-sizing:border-box; }
body {
    font-family: 'Inter', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-tap-highlight-color: transparent;
}
h1, h2, h3 { font-family: 'Space Grotesk', sans-serif; font-weight: 600; }

nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    background: rgba(246, 248, 250, 0.97);
    backdrop-filter: blur(16px);
    z-index: 1000;
    padding: 1rem 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #d0d7de;
    transition: padding 0.3s ease;
}
.logo { font-size: 1.85rem; font-weight: 700; color: var(--accent); text-decoration: none; }

.nav-links {
    display: flex; gap: 2.5rem; list-style: none;
}
.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}
.hamburger span {
    width: 30px; height: 3px; background: var(--text);
    transition: all 0.4s ease;
}

/* HERO - PHOTO EN HAUT + CENTRÉE */
.hero {
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 110px 5% 80px;
    background: linear-gradient(135deg, #f6f8fa 0%, #e6ebf1 100%);
}
.hero-container {
    max-width: 1000px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
    text-align: center;
}
.hero-image {
    width: 260px;
    height: 260px;
    border-radius: 50%;
    overflow: hidden;
    border: 8px solid var(--accent);
    box-shadow: 0 0 60px rgba(0, 153, 204, 0.35);
}
.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.hero-text h1 {
    font-size: clamp(2.8rem, 8.5vw, 5.8rem);
    line-height: 1.05;
    background: linear-gradient(90deg, var(--accent), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.6rem;
}

.hero-text h2 {
    font-size: clamp(2.0rem, 8.5vw, 5.8rem);
    line-height: 1.05;
    background: linear-gradient(90deg, var(--accent), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.6rem;
}

.hero-subtitle {
    font-size: clamp(1.15rem, 4vw, 1.35rem);
    color: var(--accent);
    margin-bottom: 0.8rem;
    font-weight: 500;
}
.hero-text p {
    font-size: 1.15rem;
    color: var(--gray);
    max-width: 620px;
    margin: 0 auto;
}
.hero-buttons {
    display: flex;
    gap: 1.2rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 2rem;
}

.btn {
    padding: 17px 34px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.08rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-height: 58px;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.btn-primary {
    background: var(--accent);
    color: white;
}
.btn-primary:hover { transform: translateY(-6px); box-shadow: 0 20px 40px rgba(0, 153, 204, 0.4); }
.btn-secondary {
    background: transparent;
    color: var(--text);
    border: 2.5px solid var(--accent);
}
.btn-secondary:hover {
    background: var(--accent);
    color: white;
}

section { padding: 110px 5% 90px; }
@media (max-width: 768px) { section { padding: 90px 5% 70px; } }

.section-title {
    font-size: clamp(2.3rem, 6vw, 2.9rem);
    text-align: center;
    margin-bottom: 3.8rem;
    position: relative;
}
.section-title::after {
    content: '';
    width: 75px;
    height: 4px;
    background: linear-gradient(to right, var(--accent), var(--secondary));
    position: absolute;
    bottom: -14px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 4px;
}

#apropos { background: var(--card); }
.about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    max-width: 1100px;
    margin: 0 auto;
}
@media (min-width: 769px) {
    .about-grid { grid-template-columns: 1fr 1fr; gap: 5rem; }
}
.about-text p {
    font-size: 1.12rem;
    color: var(--gray);
    margin-bottom: 1.6rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}
.skill-card {
    background: var(--card);
    padding: 2.2rem;
    border-radius: 20px;
    border: 1px solid #d0d7de;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.progress-bar {
    height: 9px;
    background: #e6ebf1;
    border-radius: 999px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    background: linear-gradient(to right, var(--accent), var(--secondary));
    width: 0;
    transition: width 2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#projets { background: var(--bg); }
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.2rem;
    max-width: 1200px;
    margin: 0 auto;
}
.project-card {
    background: var(--card);
    border-radius: 22px;
    overflow: hidden;
    border: 1px solid #d0d7de;
    box-shadow: 0 8px 25px rgba(0,0,0,0.06);
    transition: all 0.4s ease;
}
.project-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 25px 50px rgba(0, 153, 204, 0.18);
}
.project-img img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.project-card:hover .project-img img { transform: scale(1.1); }

#contact { background: var(--card); }
.contact-container { max-width: 680px; margin: 0 auto; }
input, textarea {
    width: 100%;
    padding: 18px 22px;
    background: #fff;
    border: 1px solid #d0d7de;
    border-radius: 16px;
    color: var(--text);
    font-size: 1.07rem;
    min-height: 58px;
}
input:focus, textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(0, 153, 204, 0.15);
}

footer {
    background: linear-gradient(135deg, #24292f, #1e252e);
    color: #f0f3f8;
    padding: 0.5rem 5% 0.5rem;
    text-align: center;
    position: relative;
}
footer::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(to right, var(--accent), var(--secondary));
}
.social-links {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    margin-bottom: 0.1rem;
}
.social-links a {
    font-size: 2.1rem;
    color: #adbac7;
    transition: all 0.3s ease;
}
.social-links a:hover {
    color: var(--accent);
    transform: translateY(-8px) scale(1.15);
}
.footer-bottom {
    margin-top: 1.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(255,255,255,0.12);
    font-size: 0.92rem;
    opacity: 0.75;
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 85%;
        height: 100vh;
        background: var(--bg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 3rem;
        transition: right 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55);
        padding-top: 100px;
        box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    }
    .nav-links.active { right: 0; }
    .hamburger { display: flex; }
    .hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(6px, 6px); }
    .hamburger.active span:nth-child(2) { opacity: 0; }
    .hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(7px, -7px); }
}

.fade-in {
    opacity: 0;
    transform: translateY(50px);
    transition: all 1.1s cubic-bezier(0.23, 1, 0.32, 1);
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}