/* ===================================================================
   PORTFOLIO THIBAUD MASUREL - STYLESHEET
   Style inspiré du portfolio de Karim Bouzgarne
   Design moderne, minimaliste avec animations subtiles
=================================================================== */

/* ===================================================================
   1. VARIABLES CSS & CONFIGURATION GLOBALE
=================================================================== */

:root {
    /* Couleurs principales */
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --text-primary: #2c3e50;
    --text-secondary: #7f8c8d;
    --accent-primary: #f05f40;
    --accent-secondary: #e74c3c;
    
    /* Ombres */
    --shadow-light: 0 2px 15px rgba(0,0,0,0.08);
    --shadow-medium: 0 4px 25px rgba(0,0,0,0.1);
    --shadow-heavy: 0 8px 40px rgba(0,0,0,0.12);
    
    /* Styles génériques */
    --border-radius: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --bg-primary: #1a1a1a;
    --bg-secondary: #2d2d2d;
    --text-primary: #fff;
    --text-secondary: #ccc;
    --accent-primary: #4aa3df;
    --accent-secondary: #3498db;
    --shadow-light: 0 2px 10px rgba(0,0,0,0.3);
    --shadow-medium: 0 5px 20px rgba(0,0,0,0.3);
    --shadow-heavy: 0 10px 30px rgba(0,0,0,0.4);
}


/* ===================================================================
   2. RESET & BASE STYLES
=================================================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Accessibilité : Focus visible pour navigation clavier */
*:focus-visible {
    outline: 3px solid var(--accent-primary);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Supprimer l'outline par défaut seulement si focus-visible est supporté */
*:focus:not(:focus-visible) {
    outline: none;
}

html {
    scroll-behavior: smooth;
    overscroll-behavior: none;
    width: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Open Sans', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.7;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    transition: var(--transition);
    overflow-x: hidden;
    font-weight: 400;
    width: 100%;
    max-width: 100vw;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}


/* ===================================================================
   3. HEADER & NAVIGATION
=================================================================== */

header {
    background: rgba(255,255,255,0.95);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

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

.logo {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--accent-primary);
    transition: var(--transition);
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 40px;
    align-items: center;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    position: relative;
    padding: 10px 0;
}

.nav-menu a:hover {
    color: var(--accent-primary);
}

.nav-menu a:focus-visible {
    outline: 3px solid var(--accent-primary);
    outline-offset: 4px;
}

.cv-link {
    background: none;
    color: var(--text-primary) !important;
    padding: 10px 0;
    border-radius: 0;
    font-weight: 600;
    transition: var(--transition);
}

.cv-link:hover {
    color: var(--accent-primary) !important;
    background: none;
    transform: none;
}


/* ===================================================================
   4. HERO SECTION
=================================================================== */

#hero {
    background-image: linear-gradient(rgba(44, 62, 80, 0.7), rgba(44, 62, 80, 0.7)),
                      url('https://images.unsplash.com/photo-1517180102446-f3ece451e9d8?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=70');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: white;
    padding: 0;
    margin-top: 70px;
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(44, 62, 80, 0.5);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 0 20px;
}

.hero-text h1 {
    font-size: 4rem;
    font-weight: 300;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.hero-text h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    font-weight: 400;
    color: var(--accent-primary);
}

.hero-text p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.95;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    background: var(--accent-primary);
    color: white;
    padding: 15px 35px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    display: inline-block;
    border: 2px solid var(--accent-primary);
}

.cta-button:hover {
    background: transparent;
    color: var(--accent-primary);
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

.cta-button:focus-visible {
    outline: 3px solid white;
    outline-offset: 4px;
}


/* ===================================================================
   5. SECTIONS GÉNÉRALES
=================================================================== */

section {
    padding: 100px 0;
    position: relative;
}

section h2 {
    text-align: center;
    font-size: 2.8rem;
    margin-bottom: 60px;
    color: var(--text-primary);
    font-weight: 300;
    position: relative;
}

section h2::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 2px;
    background: var(--accent-primary);
}


/* ===================================================================
   6. SECTION À PROPOS
=================================================================== */

#about {
    background: var(--bg-primary);
    transition: var(--transition);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    gap: 40px;
}

.about-text p {
    margin-bottom: 25px;
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.8;
    transition: var(--transition);
}

.skills {
    margin-top: 40px;
}

.skills h3 {
    margin-bottom: 30px;
    color: var(--text-primary);
    font-size: 1.8rem;
    font-weight: 400;
    transition: var(--transition);
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.skill-tag {
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 12px 24px;
    border-radius: 5px;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid #e1e8ed;
}

.skill-tag:hover {
    background: var(--accent-primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}


/* ===================================================================
   7. SECTION FORMATION
=================================================================== */

#formation {
    background: var(--bg-secondary);
    transition: var(--transition);
}

.formation-timeline {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.formation-timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent-primary);
    transform: translateX(-50%);
}

.formation-item {
    display: flex;
    margin-bottom: 40px;
    position: relative;
    align-items: center;
}

.formation-item::before {
    display: none;
}

.formation-item:nth-child(odd) {
    flex-direction: row;
}

.formation-item:nth-child(even) {
    flex-direction: row-reverse;
}

.formation-date {
    flex: 0 0 45%;
    padding: 0 30px;
    text-align: center;
    font-weight: 600;
    color: var(--accent-primary);
    font-size: 0.9rem;
}

.formation-content {
    flex: 0 0 45%;
    padding: 25px;
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-light);
    border: 1px solid #e1e8ed;
    transition: var(--transition);
}

.formation-content:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-medium);
}

.formation-content h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 600;
}

.formation-school {
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.formation-description {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}


/* ===================================================================
   8. SECTION PROJETS/PORTFOLIO
=================================================================== */

#projects {
    background: var(--bg-primary);
    transition: var(--transition);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.project-card {
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    border: 1px solid #e1e8ed;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.project-image {
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: var(--bg-secondary);
}

/* Carrousel pour les images de projet */
.project-image.carousel {
    position: relative;
}

.carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.6s ease-in-out, transform 0.3s ease;
    pointer-events: none;
}

.carousel-slide.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 1;
}

.project-card:hover .carousel-slide.active {
    transform: scale(1.05);
}

/* Indicateurs du carrousel */
.carousel-indicators {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.carousel-indicators .indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.carousel-indicators .indicator:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: scale(1.2);
}

.carousel-indicators .indicator.active {
    background: var(--accent-primary);
    width: 24px;
    border-radius: 4px;
}

/* Support pour les anciennes images sans carrousel */
.project-image img:not(.carousel-slide) {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-image img:not(.carousel-slide) {
    transform: scale(1.05);
}

.project-content {
    padding: 30px;
}

.project-content h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--text-primary);
    font-weight: 600;
    transition: var(--transition);
}

.project-content p {
    color: var(--text-secondary);
    margin-bottom: 25px;
    line-height: 1.7;
    transition: var(--transition);
}

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

.tech-tag {
    background: var(--bg-secondary);
    color: var(--text-secondary);
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid #e1e8ed;
}

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

.project-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 600;
    padding: 10px 20px;
    border: 2px solid var(--accent-primary);
    border-radius: 5px;
    transition: var(--transition);
    text-align: center;
    flex: 1;
}

.project-link:hover {
    background: var(--accent-primary);
    color: white;
}

.project-link:focus-visible {
    outline: 3px solid var(--accent-primary);
    outline-offset: 4px;
}


/* ===================================================================
   9. SECTION CONTACT
=================================================================== */

#contact {
    background: var(--bg-primary);
    text-align: center;
    transition: var(--transition);
}

.contact-content p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    transition: var(--transition);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.contact-link {
    background: var(--accent-primary);
    color: white;
    padding: 15px 30px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: var(--transition);
    min-width: 120px;
    text-align: center;
}

.contact-link:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
}

.contact-link:focus-visible {
    outline: 3px solid var(--accent-primary);
    outline-offset: 4px;
}


/* ===================================================================
   10. FOOTER
=================================================================== */

footer {
    background: var(--text-primary);
    color: var(--bg-primary);
    text-align: center;
    padding: 30px 0;
    transition: var(--transition);
}


/* ===================================================================
   11. ANIMATIONS & EFFETS
=================================================================== */

.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.6s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.6s ease;
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.6s ease;
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}


/* ===================================================================
   12. RESPONSIVE DESIGN
=================================================================== */

/* Tablettes et mobiles (≤ 768px) */
@media (max-width: 768px) {
    /* Optimisation hero pour mobile */
    #hero {
        background-attachment: scroll !important;
        transform: none !important;
    }
    
    /* Header responsive */
    .nav-container {
        flex-direction: column;
        height: auto;
        padding: 15px 20px;
        text-align: center;
    }
    
    .logo {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    .nav-menu {
        margin-top: 0;
        gap: 20px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-menu a {
        padding: 8px 0;
        font-size: 0.95rem;
    }
    
    .cv-link {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
    
    /* Hero responsive */
    #hero {
        padding: 120px 0 80px;
        margin-top: 120px;
    }
    
    .hero-content h2 {
        font-size: 2rem;
    }
    
    /* Sections générales */
    .about-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-links {
        flex-direction: row;
        justify-content: center;
        gap: 15px;
        flex-wrap: nowrap;
    }
    
    .contact-link {
        min-width: 50px;
        width: 50px;
        height: 50px;
        padding: 0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.2rem;
        position: relative;
    }
    
    .contact-link::before {
        font-size: 1.2rem;
    }
    
    .contact-link[href*="mailto"]::before {
        content: "";
        background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"/><polyline points="22,6 12,13 2,6"/></svg>') center/contain no-repeat;
        width: 20px;
        height: 20px;
        display: inline-block;
    }
    
    .contact-link[href*="linkedin"]::before {
        content: "";
        background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z"/><rect width="4" height="12" x="2" y="9"/><circle cx="4" cy="4" r="2"/></svg>') center/contain no-repeat;
        width: 20px;
        height: 20px;
        display: inline-block;
    }
    
    .contact-link[href*="github"]::before {
        content: "";
        background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4"/><path d="M9 18c-4.51 2-5-2-7-2"/></svg>') center/contain no-repeat;
        width: 20px;
        height: 20px;
        display: inline-block;
    }
    
    .contact-link .contact-text {
        display: none;
    }
    
    /* Formation timeline mobile */
    .formation-timeline::before {
        left: 20px;
    }
    
    .formation-item {
        flex-direction: column !important;
        align-items: flex-start;
        padding-left: 50px;
    }
    
    .formation-item::before {
        left: 20px;
        transform: translateX(-50%);
    }
    
    .formation-date {
        flex: none;
        padding: 0 0 10px 0;
        text-align: left;
        font-size: 0.85rem;
    }
    
    .formation-content {
        flex: none;
        width: 100%;
        padding: 20px;
    }
}

/* Petits mobiles (≤ 480px) */
@media (max-width: 480px) {
    html, body {
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
    }
    
    .container {
        padding: 0 15px;
        max-width: 100%;
    }
    
    /* Navigation ultra compacte */
    .nav-container {
        padding: 10px 15px;
        max-width: 100%;
    }
    
    .demo-popup {
        height: auto;
        max-height: none;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }
    
    .demo-popup-content {
        overflow: visible;
        display: flex;
        flex-direction: column;
    }
    
    .demo-popup-header {
        flex-shrink: 0;
    }
    
    .demo-description {
        display: none;
    }
    
    .nav-menu {
        gap: 15px;
    }
    
    .nav-menu a {
        font-size: 0.9rem;
    }
    
    /* Hero ultra responsive */
    .hero-text h1 {
        font-size: 2.5rem;
    }
    
    .hero-content h2 {
        font-size: 1.8rem;
    }
    
    .hero-content p {
        font-size: 1.1rem;
    }
    
    /* Sections */
    section h2 {
        font-size: 2rem;
    }
    
    .project-card {
        margin: 0 10px;
    }
}


/* ===================================================================
   14. DEMO POPUPS
=================================================================== */

/* Overlay sombre */
.demo-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.demo-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Popup principal */
.demo-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    background: var(--bg-primary);
    border-radius: 15px;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-heavy);
    overflow: hidden;
}

.demo-popup.active {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

/* Header du popup */
.demo-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    background: var(--bg-secondary);
}

.demo-popup-header h3 {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.demo-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 50%;
    transition: var(--transition);
    line-height: 1;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.demo-close:hover {
    background: rgba(0,0,0,0.1);
    color: var(--text-primary);
}

/* Contenu de la galerie */
.demo-gallery {
    padding: 30px;
}

.demo-main-image {
    width: 100%;
    height: 400px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow-medium);
    margin-bottom: 20px;
    position: relative;
}

.demo-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

/* Thumbnails */
.demo-thumbnails {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.demo-thumbnail {
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    opacity: 0.7;
}

.demo-thumbnail:hover {
    opacity: 1;
    transform: scale(1.05);
}

.demo-thumbnail.active {
    border-color: var(--accent-primary);
    opacity: 1;
}

.demo-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Navigation */
.demo-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px 20px 30px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.demo-nav-btn {
    background: var(--accent-primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
    min-width: 120px;
}

.demo-nav-btn:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
}

.demo-nav-btn:disabled {
    background: var(--text-secondary);
    cursor: not-allowed;
    transform: none;
}

.demo-counter {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    padding: 10px 20px;
    background: var(--bg-secondary);
    border-radius: 20px;
}

/* Description */
.demo-description {
    padding: 25px 30px;
    background: var(--bg-secondary);
}

.demo-description p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1rem;
    margin: 0;
}

/* Responsive pour popups */
@media (max-width: 768px) {
    .demo-popup {
        width: 95%;
        max-width: 95vw;
        height: auto;
        max-height: none;
        margin: 0;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }
    
    .demo-popup-content {
        overflow: visible;
        display: flex;
        flex-direction: column;
    }
    
    .demo-popup-header {
        flex-shrink: 0;
    }
    
    .demo-description {
        display: none;
    }
    
    .cta-button {
        display: none;
    }
    
    .demo-popup-header {
        padding: 20px;
    }
    
    .demo-popup-header h3 {
        font-size: 1.5rem;
    }
    
    .demo-gallery {
        padding: 20px;
    }
    
    .demo-main-image {
        height: 180px;
    }
    
    .demo-navigation {
        flex-direction: row;
        gap: 10px;
        padding: 15px 20px;
        justify-content: space-between;
    }
    
    .demo-nav-btn {
        min-width: 40px;
        width: 40px;
        height: 40px;
        padding: 0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.2rem;
    }
    
    .demo-nav-btn#demo-prev {
        font-size: 0;
    }
    
    .demo-nav-btn#demo-prev::after {
        content: "‹";
        font-size: 1.5rem;
    }
    
    .demo-nav-btn#demo-next {
        font-size: 0;
    }
    
    .demo-nav-btn#demo-next::after {
        content: "›";
        font-size: 1.5rem;
    }
    
    .demo-counter {
        font-size: 0.9rem;
        padding: 8px 12px;
    }
    
    .demo-description {
        padding: 20px;
    }
    
    .demo-thumbnails {
        gap: 10px;
    }
    
    .demo-thumbnail {
        width: 60px;
        height: 45px;
    }
}

@media (max-width: 480px) {
    .demo-popup {
        width: 98%;
        max-width: 98vw;
        max-height: 95vh;
        margin: 0;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
    }
    
    .demo-main-image {
        height: 150px;
    }
    
    .demo-popup-header {
        padding: 15px;
    }
    
    .demo-gallery {
        padding: 15px;
    }
    
    .demo-navigation {
        padding: 15px;
    }
    
    .demo-description {
        padding: 15px;
    }
}

/* Animations d'entrée */
@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.7);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes overlayFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ===================================================================
   15. ABOUT PHOTO SECTION
=================================================================== */

/* Layout de la section About */
.about-content {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 50px;
    align-items: start;
    margin-top: 50px;
}

.about-photo-container {
    position: sticky;
    top: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    height: fit-content;
}

.profile-photo {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: var(--shadow-heavy);
    transition: var(--transition);
}

.profile-photo:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 50px rgba(0,0,0,0.2);
}

/* Effet glitch */
@keyframes glitch {
    0%, 100% { transform: translate(0); }
    20% { transform: translate(-2px, 2px); }
    40% { transform: translate(-2px, -2px); }
    60% { transform: translate(2px, 2px); }
    80% { transform: translate(2px, -2px); }
}

.photo-digitalizer.glitching #profile-photo {
    animation: glitch 0.3s ease-in-out infinite;
}

/* Section info à droite */
.about-info {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.about-text {
    color: var(--text-secondary);
    line-height: 1.8;
}

.about-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

/* Responsive pour mobile */
@media (max-width: 1024px) {
    .about-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
    
    .about-photo-container {
        position: relative;
        top: 0;
        justify-content: center;
        order: 1;
    }
    
    .about-info {
        order: 2;
    }
}

@media (max-width: 768px) {
    .photo-digitalizer {
        width: 250px;
        height: 250px;
    }
    
    .about-content {
        gap: 30px;
    }
    
    .about-text p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .photo-digitalizer {
        width: 200px;
        height: 200px;
    }
    
    .matrix-char {
        font-size: 10px;
    }
    
    .ascii-canvas {
        font-size: 3px;
    }
}

/* ===================================================================
   FIN DU FICHIER CSS
=================================================================== */


