/* === STYLES GÉNÉRAUX === */
:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --text-color: #1f2937;
    --bg-color: #f9fafb;
    --card-bg: #ffffff;
    --border-color: #e5e7eb;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --nav-bg: rgba(255, 255, 255, 0.95);
    --project-card-bg: #ffffff;
    --transition: all 0.3s ease;
}

[data-theme="dark"] {
    --primary-color: #3b82f6;
    --secondary-color: #2563eb;
    --text-color: #f9fafb;
    --bg-color: #111827;
    --card-bg: #1f2937;
    --border-color: #374151;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --nav-bg: rgba(17, 24, 39, 0.95);
    --project-card-bg: #1a2435;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: var(--transition);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 5px;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
}

section {
    padding: 80px 0;
}

/* === HEADER & NAVIGATION === */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: var(--nav-bg);
    box-shadow: 0 2px 10px var(--shadow-color);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

/* === LOGO STYLES === */
.logo-img {
    height: 40px;
    width: auto;
    transition: var(--transition);
}

.logo-img:hover {
    transform: scale(1.05);
}

/* Ajustements pour la navigation avec le logo */
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

/* Ajustements responsives */
@media (max-width: 768px) {
    .logo-img {
        height: 35px;
    }
}

.logo-svg {
    transition: var(--transition);
}

.logo-svg:hover {
    transform: scale(1.05);
}

[data-theme="dark"] .logo-svg rect {
    fill: #3b82f6;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    align-items: center;
}

.nav-item {
    margin-left: 30px;
}

.nav-link {
    font-weight: 600;
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--primary-color);
}

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--text-color);
    margin-left: 20px;
}

.hamburger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

/* === HERO SECTION === */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(37, 99, 235, 0.05) 100%);
    padding-top: 80px;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.hero-text {
    flex: 1;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 30px;
    color: var(--text-color);
    opacity: 0.9;
}

.hero-image {
    flex: 1;
    text-align: center;
}

.hero-img {
    width: 100%;
    max-width: 400px;
    border-radius: 50%;
    border: 5px solid var(--primary-color);
    box-shadow: 0 10px 30px var(--shadow-color);
}

.hero-img1 {
    width: 100%;
    max-width: 400px;
    border-radius: 10%;
    border: 5px solid var(--primary-color);
    box-shadow: 0 10px 30px var(--shadow-color);
}
.parent {
display: grid;
grid-template-columns: 1fr;
grid-template-rows: repeat(2, 1fr);
grid-column-gap: 0px;
grid-row-gap: 0px;
}

.div1 { grid-area: 1 / 1 / 3 / 2; }
.div2 { grid-area: 2 / 1 / 3 / 2; }
.div1 {
    background-image: url('../img/404 error.jpg');
    background-repeat: no-repeat;
    background-size: cover;
    height: 100vh;
}
.div2{
   display: flex;
   justify-content: center;
   align-items: end;
   height: 100%;
}
  /* === ABOUT SECTION === */

        .about-content {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 50px;
            align-items: start;
        }

        .about-text h3 {
            font-size: 2rem;
            margin-bottom: 20px;
            color: var(--primary-color);
        }

        .about-text p {
            margin-bottom: 15px;
            opacity: 0.9;
            line-height: 1.8;
        }

        /* === CONTACT SECTION === */

        .skills-categories {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 25px;
            margin-top: 30px;
        }

        .skill-category {
            background-color: var(--card-bg);
            padding: 20px;
            border-radius: 10px;
            box-shadow: 0 4px 6px var(--shadow-color);
            border: 1px solid var(--border-color);
        }

        .category-title {
            font-size: 1.2rem;
            color: var(--primary-color);
            margin-bottom: 15px;
            padding-bottom: 10px;
            border-bottom: 2px solid var(--primary-color);
            display: flex;
            align-items: center;
        }

        .category-title i {
            margin-right: 10px;
            font-size: 1.4rem;
        }

        .skills-list {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
        }

        .skill {
            background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
            color: white;
            padding: 8px 16px;
            border-radius: 50px;
            font-size: 0.9rem;
            font-weight: 600;
        }

    /* === FORMATION/CERTIFICATION SECTION === */
    .formation-certification {
        background-color: var(--card-bg);
    }
        .education-certification {
            margin-top: 40px;
        }

        .education-item, .certification-item {
            background-color: var(--card-bg);
            padding: 20px;
            border-radius: 10px;
            margin-bottom: 20px;
            box-shadow: 0 4px 6px var(--shadow-color);
            border: 1px solid var(--border-color);
        }

        .education-title, .certification-title {
            font-size: 1.2rem;
            color: var(--primary-color);
            margin-bottom: 10px;
        }

        .education-institution, .certification-institution {
            font-weight: 600;
            margin-bottom: 5px;
        }

        .education-date, .certification-date {
            color: var(--text-color);
            opacity: 0.8;
            font-size: 0.9rem;
        }

        .about-image {
            text-align: center;
        }

        .about-img {
            width: 100%;
            max-width: 400px;
            border-radius: 10px;
            box-shadow: 0 10px 30px var(--shadow-color);
            margin-bottom: 30px;
        }

/* === PROJECTS SECTION === */
.projects {
    background-color: var(--card-bg);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: var(--project-card-bg);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px var(--shadow-color);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.project-card:hover {
    transform: translateY(-10px);
}

.project-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border: 2px solid var(--primary-color);
    box-shadow: 0 10px 30px var(--shadow-color);
}

.project-content {
    padding: 20px;
}

.project-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.project-description {
    opacity: 0.9;
    margin-bottom: 15px;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.tech {
    background-color: var(--primary-color);
    color: white;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* === CONTACT SECTION === */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-weight: 600;
}

.form-input, .form-textarea {
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
    background-color: var(--card-bg);
    color: var(--text-color);
}

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

/* === FOOTER === */
footer {
    background-color: var(--card-bg);
    color: var(--text-color);
    padding: 40px 0;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-link:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

.copyright {
    text-align: center;
    opacity: 0.8;
}

/* Lightbox Styles */
        .lightbox {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.9);
            z-index: 2000;
            justify-content: center;
            align-items: center;
            opacity: 0;
            transition: opacity 0.3s ease;
        }
        
        .lightbox.active {
            display: flex;
            opacity: 1;
        }
        
        .lightbox-content {
            max-width: 90%;
            max-height: 90%;
            position: relative;
        }
        
        .lightbox-img {
            max-width: 100%;
            max-height: 90vh;
            border-radius: 8px;
            box-shadow: 0 0 25px rgba(0, 0, 0, 0.5);
        }
        
        .lightbox-close {
            position: absolute;
            top: -40px;
            right: 0;
            color: white;
            font-size: 2rem;
            cursor: pointer;
            background: none;
            border: none;
            transition: transform 0.3s ease;
        }
        
        .lightbox-close:hover {
            transform: scale(1.2);
        }
        
        .lightbox-nav {
            position: absolute;
            top: 50%;
            width: 100%;
            display: flex;
            justify-content: space-between;
            transform: translateY(-50%);
            padding: 0 20px;
        }
        
        .lightbox-prev, .lightbox-next {
            color: white;
            font-size: 2rem;
            cursor: pointer;
            background: none;
            border: none;
            transition: transform 0.3s ease;
        }
        
        .lightbox-prev:hover, .lightbox-next:hover {
            transform: scale(1.2);
        }
        
        /* Make images clickable */
        .clickable-image {
            cursor: pointer;
            transition: transform 0.3s ease;
        }
        
        .clickable-image:hover {
            transform: scale(1.03);
        }
        
        /* Caption styling */
        .lightbox-caption {
            color: white;
            text-align: center;
            margin-top: 15px;
            font-size: 1.2rem;
        }
        
/* === RESPONSIVE DESIGN === */
@media (max-width: 992px) {
    .hero-content, .about-content, .contact-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-content {
        flex-direction: column-reverse;
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .section-title {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
    }
    
    .nav-menu {
        position: fixed;
        top: 80px;
        right: -100%;
        background-color: var(--card-bg);
        width: 80%;
        height: calc(100vh - 80px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: var(--transition);
        box-shadow: -5px 0 15px var(--shadow-color);
    }
    
    .nav-menu.active {
        right: 0;
    }
    
    .nav-item {
        margin: 20px 0;
    }
    
    .hero-title {
        font-size: 2.3rem;
    }
    
    .hero-subtitle {
        font-size: 1.3rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .btn {
        padding: 10px 20px;
    }
}