/* ===== RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #1d1d1f;
    background-color: #ffffff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== NAVIGATION ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
}

.nav-brand {
    font-size: 20px;
    font-weight: 600;
    color: #1d1d1f;
}

.nav-brand span {
    background: linear-gradient(135deg, #007AFF, #5856D6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav-link {
    text-decoration: none;
    color: #1d1d1f;
    font-weight: 400;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #007AFF;
}

.nav-link.active {
    color: #007AFF;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #007AFF, #5856D6);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.hamburger span {
    width: 24px;
    height: 2px;
    background-color: #1d1d1f;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* ===== HERO SECTION ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    text-align: center;
    padding-top: 80px; /* Compensation pour la navbar fixe */
}

.hero-content {
    max-width: 800px;
    animation: fadeInUp 1s ease-out;
}

.hero-greeting {
    display: block;
    font-size: 24px;
    font-weight: 300;
    color: #86868b;
    margin-bottom: 8px;
}

.hero-name {
    display: block;
    font-size: clamp(48px, 8vw, 80px);
    font-weight: 700;
    background: linear-gradient(135deg, #1d1d1f, #86868b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 24px;
}

.hero-subtitle {
    font-size: 20px;
    font-weight: 300;
    color: #515154;
    margin-bottom: 48px;
    line-height: 1.5;
}

.hero-cta {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary {
    padding: 16px 32px;
    background: linear-gradient(135deg, #007AFF, #5856D6);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(0, 122, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.4);
}

.btn-secondary {
    padding: 16px 32px;
    background: transparent;
    color: #1d1d1f;
    text-decoration: none;
    border: 2px solid #d2d2d7;
    border-radius: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-secondary:hover {
    background: #1d1d1f;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(29, 29, 31, 0.2);
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.scroll-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #86868b;
}

/* ===== SECTIONS ===== */
section {
    padding: 80px 0; /* Réduit de 100px à 80px */
}

.section-header {
    text-align: center;
    margin-bottom: 40px; /* Réduit de 60px à 40px */
}

.section-title {
    font-size: 48px;
    font-weight: 700;
    color: #1d1d1f;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 20px;
    font-weight: 300;
    color: #86868b;
}

/* ===== ABOUT SECTION ===== */
.about {
    background-color: #f5f5f7;
    padding: 60px 0;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    align-items: center;
}

.about-text p {
    font-size: 18px;
    line-height: 1.7;
    color: #515154;
    margin-bottom: 20px;
}

.about-link {
    color: #007AFF;
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: inherit;
}

.about-link:hover {
    color: #5856D6;
    text-decoration: underline;
}

.about-highlight {
    margin-top: 30px;
    padding: 24px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.highlight-item h3 {
    font-size: 24px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #007AFF, #5856D6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.highlight-item h3 .about-link {
    background: linear-gradient(135deg, #007AFF, #5856D6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.highlight-item h3 .about-link:hover {
    background: linear-gradient(135deg, #5856D6, #007AFF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
}

.about-image {
    display: flex;
    justify-content: center;
}

.image-placeholder {
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, #f5f7fa, #c3cfe2);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.placeholder-icon {
    font-size: 48px;
}

/* ===== SKILLS SECTION ===== */
.skills {
    padding: 50px 0; /* Réduit de 60px à 50px */
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px; /* Réduit de 40px à 30px */
}

.skill-category {
    background: white;
    padding: 30px; /* Réduit de 40px à 30px */
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skill-category:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

.skill-category h3 {
    font-size: 24px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 20px; /* Réduit de 24px à 20px */
}

.skill-items {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.skill-tag {
    padding: 8px 16px;
    background: #f5f5f7;
    color: #1d1d1f;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.skill-tag:hover {
    background: linear-gradient(135deg, #007AFF, #5856D6);
    color: white;
    transform: translateY(-2px);
}

/* ===== PROJECTS SECTION ===== */
.projects {
    background-color: #f5f5f7;
    padding: 50px 0; /* Réduit de 60px à 50px */
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px; /* Réduit de 40px à 30px */
}

.project-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.project-card.featured {
    grid-column: span 2;
}

.project-image {
    height: 200px;
    background: linear-gradient(135deg, #f5f7fa, #c3cfe2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-placeholder .placeholder-icon {
    font-size: 48px;
}

.project-content {
    padding: 24px; /* Réduit de 32px à 24px */
}

.project-content h3 {
    font-size: 24px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 12px; /* Réduit de 16px à 12px */
}

.project-content p {
    color: #515154;
    line-height: 1.6;
    margin-bottom: 20px; /* Réduit de 24px à 20px */
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px; /* Réduit de 24px à 20px */
}

.project-tech span {
    padding: 6px 12px;
    background: #f5f5f7;
    color: #86868b;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
}

.project-links {
    display: flex;
    gap: 16px;
}

.project-link {
    color: #007AFF;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: #5856D6;
}

/* ===== CONTACT SECTION ===== */
.contact {
    padding: 60px 0; /* Réduit de 100px à 60px */
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px; /* Réduit de 60px à 40px */
    align-items: start;
}

.contact-info h3 {
    font-size: 32px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 20px; /* Réduit de 24px à 20px */
}

.contact-info p {
    font-size: 18px;
    color: #515154;
    line-height: 1.7;
    margin-bottom: 30px; /* Réduit de 40px à 30px */
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 20px; /* Réduit de 24px à 20px */
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: #f5f5f7;
    border-radius: 12px;
    transition: background 0.3s ease;
}

.contact-method:hover {
    background: #ebebed;
}

.contact-icon {
    font-size: 24px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.contact-method h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 4px;
}

.contact-method a {
    color: #007AFF;
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-method a:hover {
    color: #5856D6;
}

.contact-form {
    background: white;
    padding: 30px; /* Réduit de 40px à 30px */
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.form-group {
    margin-bottom: 20px; /* Réduit de 24px à 20px */
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px;
    border: 2px solid #d2d2d7;
    border-radius: 12px;
    font-size: 16px;
    font-family: inherit;
    background: #f5f5f7;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #007AFF;
    background: white;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* ===== FOOTER ===== */
.footer {
    background: #1d1d1f;
    color: #86868b;
    padding: 40px 0; /* Réduit de 60px à 40px */
    text-align: center;
}

.footer-content p {
    margin-bottom: 8px;
    font-size: 14px;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0) translateX(-50%);
    }
    40% {
        transform: translateY(-10px) translateX(-50%);
    }
    60% {
        transform: translateY(-5px) translateX(-50%);
    }
}

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 20px;
        gap: 16px;
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    }

    .nav-menu.active {
        display: flex;
    }

    .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(6px, -6px);
    }

    .container {
        padding: 0 16px;
    }

    section {
        padding: 60px 0; /* Réduit de 80px à 60px sur mobile */
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }

    .section-title {
        font-size: 36px;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 30px; /* Réduit de 40px à 30px */
        text-align: center;
    }

    .about-image {
        order: -1;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 30px; /* Réduit de 40px à 30px */
    }

    .project-card.featured {
        grid-column: span 1;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-greeting {
        font-size: 20px;
    }

    .hero-subtitle {
        font-size: 18px;
    }

    .section-title {
        font-size: 28px;
    }

    .section-subtitle {
        font-size: 16px;
    }

    .about-text p {
        font-size: 16px;
    }

    .contact-info h3 {
        font-size: 24px;
    }

    .contact-info p {
        font-size: 16px;
    }

    .contact-form {
        padding: 20px; /* Réduit de 30px à 20px */
    }

    section {
        padding: 40px 0; /* Encore plus réduit sur très petits écrans */
    }
}
