/* --- 1. TYPOGRAPHIES --- */
@font-face { font-family: 'Oswald'; src: url('fonts/Oswald-Bold.woff2') format('woff2'); font-weight: 700; }
@font-face { font-family: 'Inter'; src: url('fonts/Inter-Regular.woff2') format('woff2'); font-weight: 400; }
@font-face { font-family: 'Inter-Light'; src: url('fonts/Inter18pt-ExtraLight.woff2') format('woff2'); font-weight: 200; }
@font-face { font-family: 'SpaceMono'; src: url('fonts/SpaceMono-Regular.woff2') format('woff2'); font-weight: 400; }

/* --- 2. BASE --- */
:root {
    --bg: #080808;
    --text: #ffffff;
    --text-dim: #888888;
    --accent: #FFE600; 
    --border: rgba(255, 255, 255, 0.1);
}

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

html {
    scroll-behavior: smooth; /* Permet un défilement doux quand on clique sur la flèche */
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* --- 3. HEADER & TITRE ALICIA --- */
header {
    position: fixed;
    top: 0; width: 100%; height: 90px;
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 50px; border-bottom: 1px solid var(--border);
    background: rgba(8, 8, 8, 0.85); backdrop-filter: blur(10px);
    z-index: 1000;
}

header h1 {
    font-family: 'Inter-Light', sans-serif;
    font-size: 1.4rem;
    letter-spacing: 0.4em;
    font-weight: 200;
}

.info-btn {
    font-family: 'Inter-Light', sans-serif;
    font-size: 2.8rem;
    font-weight: 200;
    background: none; border: none; color: var(--text);
    cursor: pointer; padding: 0 15px;
    transition: color 0.3s ease;
    display: flex; align-items: center; justify-content: center;
}
.info-btn:hover { color: var(--accent); }

/* --- 4. PAGE DE GARDE (LANDING) --- */
.landing {
    width: 100%;
    height: calc(100vh - 90px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative; /* Indispensable pour positionner la flèche en bas */
}

.landing img {
    max-width: 70%; 
    max-height: 80%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: max-width 0.5s ease;
}

/* Style et animation de la flèche de scroll */
.scroll-down {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--text-dim);
    font-size: 1.5rem;
    text-decoration: none;
    font-family: 'SpaceMono', monospace;
    transition: color 0.3s ease;
    animation: bounce 2s infinite; /* Animation de rebond */
}

.scroll-down:hover {
    color: var(--accent); /* Devient jaune au survol */
}

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

/* --- 5. PROJETS --- */
main { padding-top: 90px; }
.projects-list { display: flex; flex-direction: column; gap: 100px; padding-bottom: 100px; }
.project-row { display: flex; flex-direction: column; gap: 30px; width: 100%; padding: 0 50px; }

.project-info { width: 100%; max-width: 300px; border-top: 1px solid var(--border); padding-top: 15px; }
.project-link { text-decoration: none; color: inherit; }
.project-info h3 { font-family: 'Inter-Light'; font-size: 1.7rem; font-weight: 200; margin-bottom: 8px; }
.cta-voir { font-family: 'SpaceMono'; font-size: 0.7rem; text-transform: uppercase; color: var(--text-dim); }

.project-gallery {
    display: flex; flex-direction: row; gap: 20px;
    overflow-x: auto; scrollbar-width: none;
    scroll-snap-type: x mandatory; padding-bottom: 10px;
}
.project-gallery::-webkit-scrollbar { display: none; }

.gallery-item { flex: 0 0 auto; scroll-snap-align: start; display: block; text-decoration: none; }
.gallery-item img, .gallery-item video { 
    height: 320px; 
    width: auto; 
    display: block;
    object-fit: contain; 
}


/* --- 6. PANNEAU INFO --- */
.about-panel {
    position: fixed; top: 0; right: -100%; width: 100%; max-width: 500px; height: 100vh;
    background: #0c0c0c; z-index: 2000; 
    padding: 100px 40px 60px 60px; /* On laisse de la place en haut pour le bouton Fermer */
    transition: right 0.6s cubic-bezier(0.19, 1, 0.22, 1);
    display: flex; flex-direction: column;
    border-left: 1px solid var(--border);
}
.about-panel.open { right: 0; }

/* Conteneur du texte avec le défilement (Scroll) */
.about-content {
    overflow-y: auto; /* Active le défilement vertical */
    height: 100%;
    padding-right: 20px; /* Espace pour ne pas que le texte touche la barre de défilement */
    
    /* Design de la barre de défilement (Firefox) */
    scrollbar-width: thin;
    scrollbar-color: var(--text-dim) transparent;
}

/* Design de la barre de défilement (Chrome/Safari) */
.about-content::-webkit-scrollbar { width: 4px; }
.about-content::-webkit-scrollbar-track { background: transparent; }
.about-content::-webkit-scrollbar-thumb { background: var(--text-dim); border-radius: 10px; }

.about-content p { 
    font-family: 'Inter'; 
    font-size: 1.1rem; 
    line-height: 1.8; 
    color: var(--text); 
    margin-bottom: 1.2rem; /* Aère tes paragraphes */
}



/* Le bouton fermer reste fixe par dessus le texte */
.close-about { 
    position: absolute; top: 40px; right: 50px; 
    background: #0c0c0c; border: none; color: var(--text); 
    font-family: 'SpaceMono'; cursor: pointer; font-size: 1.1rem; 
    z-index: 10; /* Le maintient au premier plan */
}
.close-about:hover { color: var(--accent); }

/* --- 7. MODALE --- */
/* (Garde ta section modale existante ici) */
.modal { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.95); z-index: 3000; justify-content: center; align-items: center; }
.modal-content { width: 95%; max-width: 1200px; height: 85vh; display: flex; flex-direction: column; position: relative; }
#modal-media-container { flex: 1; display: flex; align-items: center; justify-content: center; overflow: hidden; }
#modal-media-container img, #modal-media-container video { max-width: 100%; max-height: 100%; object-fit: contain; }
.slider-controls { height: 80px; display: flex; justify-content: space-between; align-items: center; font-family: 'SpaceMono'; border-top: 1px solid var(--border); }
.slider-controls button { background: none; border: none; color: white; cursor: pointer; }
.close-btn { position: absolute; top: -50px; right: 0; color: white; font-family: 'SpaceMono'; cursor: pointer; font-size: 1.1rem; background: none; border: none; }

/* --- 8. ADAPTATION MOBILE (MEDIA QUERIES) --- */
@media (min-width: 1024px) { 
    .project-row { flex-direction: row; align-items: flex-start; } 
}

@media (max-width: 768px) {
    header { padding: 0 20px; height: 70px; }
    header h1 { font-size: 1.1rem; letter-spacing: 0.3em; }
    
    .landing { height: calc(100vh - 70px); }
    .landing img { max-width: 90%; }
    
    .scroll-down { bottom: 20px; }
    
    .project-row { padding: 0 20px; gap: 20px; }
    .gallery-item img, .gallery-item video { height: 240px; }
    
    /* Adaptation du panneau Info pour Mobile */
    .about-panel { padding: 80px 20px 40px 30px; max-width: 100%; }
    .close-about { top: 25px; right: 25px; }
    .about-content p { font-size: 1rem; line-height: 1.6; }
}