/* Variables de Couleurs & Polices */
:root {
    --font-primary: 'Poppins', sans-serif;

    /* Mode Sombre (Défaut inspiré par Tamdaz) */
    --bg-dark-primary: #101214; /* Plus sombre, comme tamdaz */
    --bg-dark-secondary: #1A1D20; /* Un peu moins sombre pour les éléments */
    --bg-dark-tertiary: #24282D; /* Pour cartes, etc. */
    --text-dark-primary: #E0E0E0;
    --text-dark-secondary: #A0A2A5;
    --accent-primary-dark: #FFA500; /* Orange vif comme Tamdaz */
    --accent-primary-dark-hover: #FFC04D;
    --border-dark: #30343A;
    --shadow-dark: rgba(0, 0, 0, 0.2);

    /* Mode Clair */
    --bg-light-primary: #F8F9FA;
    --bg-light-secondary: #FFFFFF;
    --bg-light-tertiary: #F1F3F5;
    --text-light-primary: #212529;
    --text-light-secondary: #495057;
    --accent-primary-light: #007BFF;
    --accent-primary-light-hover: #0056b3;
    --border-light: #DEE2E6;
    --shadow-light: rgba(0, 0, 0, 0.1);

    /* Assignations initiales (mode sombre par défaut) */
    --bg-color: var(--bg-dark-primary);
    --bg-secondary-color: var(--bg-dark-secondary);
    --bg-tertiary-color: var(--bg-dark-tertiary);
    --text-color: var(--text-dark-primary);
    --text-secondary-color: var(--text-dark-secondary);
    --accent-color: var(--accent-primary-dark);
    --accent-color-hover: var(--accent-primary-dark-hover);
    --border-color: var(--border-dark);
    --shadow-color: var(--shadow-dark);
    --danger-color: #dc3545; /* Pour les messages d'erreur du formulaire */

    --header-height: 70px;
    --border-radius: 8px;
    --container-width: 1140px;
    --transition-speed: 0.3s;
}

body.light-mode {
    --bg-color: var(--bg-light-primary);
    --bg-secondary-color: var(--bg-light-secondary);
    --bg-tertiary-color: var(--bg-light-tertiary);
    --text-color: var(--text-light-primary);
    --text-secondary-color: var(--text-light-secondary);
    --accent-color: var(--accent-primary-light);
    --accent-color-hover: var(--accent-primary-light-hover);
    --border-color: var(--border-light);
    --shadow-color: var(--shadow-light);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-height) + 20px);
}

body {
    font-family: var(--font-primary);
    line-height: 1.7;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: background-color var(--transition-speed) ease, color var(--transition-speed) ease;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: var(--container-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: 20px;
    padding-right: 20px;
}

.section {
    padding: 100px 0;
    overflow: hidden;
}
.section-alt {
    background-color: var(--bg-secondary-color);
}
.full-height {
    min-height: 100vh;
}

.section-title {
    font-size: clamp(2.2rem, 5vw, 3rem);
    text-align: center;
    margin-bottom: 60px;
    color: var(--text-color);
    position: relative;
    padding-bottom: 20px;
    font-weight: 700;
}
.section-title span {
    position: relative;
    z-index: 1;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--accent-color);
    border-radius: 2px;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--text-color);
    font-weight: 600;
    line-height: 1.3;
}
h3 { font-size: 1.8rem; margin-bottom: 20px; }

p {
    margin-bottom: 1.2em;
    font-size: 1rem;
    color: var(--text-secondary-color);
}

ul { list-style: none; }

a {
    text-decoration: none;
    color: var(--accent-color);
    transition: color var(--transition-speed) ease-out;
}
a:hover {
    color: var(--accent-color-hover);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Header */
#mainHeader {
    background-color: rgba(16, 18, 20, 0.8); /* --bg-dark-primary avec transparence */
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: var(--header-height);
    box-shadow: 0 2px 10px var(--shadow-dark); /* Ombre plus subtile pour dark */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: background-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}
body.light-mode #mainHeader {
    background-color: rgba(248, 249, 250, 0.8); /* --bg-light-primary avec transparence */
    box-shadow: 0 2px 10px var(--shadow-light);
}

#mainHeader nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

#mainHeader .logo a {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-color);
    letter-spacing: -0.5px;
}
#mainHeader .logo a:hover {
    color: var(--accent-color);
}

.nav-items-container { display: flex; align-items: center; }
#navMenu { display: flex; align-items: center; list-style: none; }
#navMenu li { margin-left: 30px; }
#navMenu li a {
    color: var(--text-secondary-color);
    padding: 8px 0px;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    transition: color var(--transition-speed) ease-out;
}
#navMenu li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--accent-color);
    border-radius: 1px;
    transition: width var(--transition-speed) cubic-bezier(0.25, 0.8, 0.25, 1);
}
#navMenu li a:hover::after,
#navMenu li a.active::after { width: 100%; }
#navMenu li a:hover,
#navMenu li a.active { color: var(--accent-color); }

#darkModeToggle {
    background: transparent;
    border: 1.5px solid var(--text-secondary-color);
    color: var(--text-secondary-color);
    font-size: 1rem; padding: 8px 10px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all var(--transition-speed) ease-out;
    margin-left: 30px;
}
#darkModeToggle:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
}

.mobile-menu-button {
    display: none;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.8rem;
    cursor: pointer;
    padding: 8px;
}

/* Hero Section */
.hero {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
    position: relative;
    background: var(--bg-color); /* Fallback pour gradient */
    background: linear-gradient(135deg, var(--bg-color) 0%, var(--bg-secondary-color) 100%);
}
.hero-background-shapes {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    overflow: hidden;
    z-index: 0;
}
.hero-background-shapes div {
    position: absolute;
    background-color: var(--accent-color);
    opacity: 0.05; /* Très subtil */
    border-radius: 50%;
    animation: floatShapes 20s infinite ease-in-out alternate;
}
.hero-background-shapes div:nth-child(1) { width: 100px; height: 100px; left: 10%; top: 20%; animation-duration: 22s; }
.hero-background-shapes div:nth-child(2) { width: 150px; height: 150px; left: 80%; top: 10%; animation-duration: 25s; }
.hero-background-shapes div:nth-child(3) { width: 70px; height: 70px; left: 20%; top: 70%; animation-duration: 18s; }
.hero-background-shapes div:nth-child(4) { width: 120px; height: 120px; left: 70%; top: 80%; animation-duration: 28s; }
.hero-background-shapes div:nth-child(5) { width: 50px; height: 50px; left: 40%; top: 40%; animation-duration: 15s; }
.hero-background-shapes div:nth-child(6) { width: 90px; height: 90px; left: 50%; top: 5%; animation-duration: 23s; }

@keyframes floatShapes {
    0% { transform: translateY(0px) translateX(0px) rotate(0deg); }
    100% { transform: translateY(20px) translateX(-15px) rotate(30deg); }
}

.hero-content { position: relative; z-index: 1; }
.hero-intro {
    font-size: 1.2rem;
    color: var(--text-secondary-color);
    margin-bottom: 5px;
}
.hero-content h1 {
    font-size: clamp(2.5rem, 8vw, 4.5rem); /* Responsive font size */
    margin-bottom: 15px;
    font-weight: 700;
    color: var(--text-color);
    letter-spacing: -1px;
}
#typed-name::after {
    content: '_';
    animation: blink 0.8s infinite step-end;
    color: var(--accent-color);
    font-weight: normal;
}
@keyframes blink { 50% { opacity: 0; } }

.hero-content .subtitle {
    font-size: clamp(1.1rem, 3vw, 1.5rem);
    margin-bottom: 25px;
    font-weight: 400;
    color: var(--text-secondary-color);
}
.hero-description {
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
    font-size: 1.05rem;
    margin-bottom: 40px;
    color: var(--text-secondary-color);
}
.hero-actions .btn { margin: 10px; }
.scroll-down-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.5rem;
    color: var(--text-secondary-color);
    animation: bounce 2s infinite;
}
.scroll-down-indicator:hover { color: var(--accent-color); }
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}


/* Boutons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 0.95rem;
    text-align: center;
    font-weight: 600;
    transition: all var(--transition-speed) ease-out;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}
.btn:active {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.btn i { margin-right: 8px; } /* Changé margin-left en margin-right pour correspondre à l'ordre icône-texte */

.btn-primary {
    background-color: var(--accent-color);
    color: var(--bg-dark-primary); /* Texte contrasté sur accent */
    border-color: var(--accent-color);
}
.btn-primary:hover {
    background-color: var(--accent-color-hover);
    border-color: var(--accent-color-hover);
    color: var(--bg-dark-primary);
}
body.light-mode .btn-primary {
    color: var(--bg-light-secondary); /* Texte blanc sur accent bleu */
}
body.light-mode .btn-primary:hover {
    color: var(--bg-light-secondary);
}


.btn-secondary {
    background-color: transparent;
    color: var(--accent-color);
    border-color: var(--accent-color);
}
.btn-secondary:hover {
    background-color: var(--accent-color);
    color: var(--bg-dark-primary);
}
body.light-mode .btn-secondary:hover {
    color: var(--bg-light-secondary);
}

.btn-outline { /* Pour les liens GitHub sur les cartes */
    padding: 8px 18px;
    font-size: 0.85rem;
    background-color: transparent;
    color: var(--accent-color);
    border: 1.5px solid var(--accent-color);
}
.btn-outline:hover {
    background-color: var(--accent-color);
    color: var(--bg-dark-primary);
}
body.light-mode .btn-outline:hover {
    color: var(--bg-light-secondary);
}

.btn-projet {
    background-color: var(--bg-secondary-color);
    color: var(--text-color);
    border: 1px solid var(--border-color);
}
/* Section À Propos */
.about-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: flex-start;
}
@media (min-width: 768px) {
    .about-layout {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
         gap: 60px;
    }
}
.about-text p { font-size: 1.05rem; }

.skills-title {
    color: var(--text-color);
    font-size: 1.6rem;
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}
.skills-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 25px;
}
@media (min-width: 576px) {
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}
.skill-category {
    background-color: var(--bg-tertiary-color);
    padding: 20px;
    border-radius: var(--border-radius);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}
.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px var(--shadow-color);
}
.skill-category h4 {
    font-size: 1.1rem;
    color: var(--accent-color);
    margin-bottom: 10px;
}
.skill-category h4 i {
    margin-right: 10px;
    font-size: 1.3em;
    vertical-align: middle;
}
.skill-category p {
    font-size: 0.9rem;
    color: var(--text-secondary-color);
    margin-bottom: 0;
}

/* Section Projets */
.project-card {
    background-color: var(--bg-tertiary-color);
    border-radius: var(--border-radius);
    box-shadow: 0 5px 15px var(--shadow-color);
    overflow: hidden;
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
    display: flex;
    flex-direction: column;
    height: 100%; /* Important pour que les slides aient la même hauteur */
    position: relative; /* Nécessaire pour le project-card-link */
}
.project-card:hover {
    /* L'effet de scale peut être un peu gênant avec Swiper, à ajuster si besoin */
    /* transform: translateY(-8px) scale(1.02);  */
    transform: translateY(-8px); 
    box-shadow: 0 10px 25px var(--shadow-color);
}

/* Lien couvrant la carte pour la navigation vers la page détail du projet */
.project-card-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; /* Se place au-dessus du contenu mais en dessous des liens explicites (GitHub) */
    /* border: 1px dashed red; /* Pour débugger la zone cliquable */
}

.project-image-container {
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    position: relative;
    overflow: hidden;
}
.project-image-container img {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.project-card:hover .project-image-container img {
    transform: scale(1.1);
}
.project-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.project-content h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--text-color);
}
.project-content p {
    font-size: 0.95rem;
    color: var(--text-secondary-color);
    margin-bottom: 20px;
    flex-grow: 1;
}
.project-tags { margin-bottom: 25px; display: flex; flex-wrap: wrap; gap: 8px; }
.project-tags span {
    background-color: var(--accent-color);
    color: var(--bg-dark-primary);
    padding: 6px 12px;
    border-radius: 20px; /* Pill shape */
    font-size: 0.75rem;
    font-weight: 500;
    display: inline-flex; /* Pour aligner icône et texte */
    align-items: center;
    transition: background-color var(--transition-speed) ease;
}
body.light-mode .project-tags span { color: var(--bg-light-secondary); }
.project-tags span i { margin-right: 6px; }

.project-links { 
    margin-top: auto; 
    text-align: right; 
    position: relative; /* Pour s'assurer que les boutons sont au-dessus du project-card-link */
    z-index: 2; /* Plus élevé que project-card-link */
}


/* Swiper Styles */
.project-swiper {
    width: 100%;
    padding-top: 20px; /* Espace pour le titre de section */
    padding-bottom: 50px; /* Espace pour la pagination */
}

.swiper-slide {
    height: auto; /* Permet aux cartes de définir leur propre hauteur */
    display: flex; 
    justify-content: center; 
}
.swiper-slide .project-card {
    width: 100%; 
    max-width: 400px; 
}

/* Section Projets (Remplaçant les styles Swiper spécifiques pour .project-swiper) */
.project-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: center; /* Centrer lignes incomplètes */
  padding-top: 20px;
  padding-bottom: 20px;
  align-items: stretch;
}

.project-card {
  flex: 0 1 calc(33.333% - 30px);
  max-width: calc(33.333% - 30px);
  display: flex;
  flex-direction: column;
  height: 550px; /* Hauteur fixe */
  background-color: var(--bg-tertiary-color);
  border-radius: var(--border-radius);
  box-shadow: 0 5px 15px var(--shadow-color);
  overflow: hidden;
  cursor: pointer;
  position: relative;
  transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

@media (max-width: 991px) {
  .project-card {
    flex: 0 1 calc(50% - 30px);
    max-width: calc(50% - 30px);
  }
}

@media (max-width: 640px) {
  .project-card {
    flex: 0 1 100%;
    max-width: 100%;
  }
}



.project-card:hover {
    transform: translateY(-8px); 
    box-shadow: 0 10px 25px var(--shadow-color);
}

/* Le lien couvrant toute la carte */
.project-card-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; /* S'assure qu'il est cliquable */
}

.project-image-container {
    width: 100%;
    /* Utilise une hauteur fixe ou un padding-top pour maintenir l'aspect ratio */
    padding-top: 56.25%; /* Ratio 16:9 pour les images */
    position: relative;
    overflow: hidden;
}
.project-image-container img {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.project-card:hover .project-image-container img {
    transform: scale(1.1);
}
.project-content {
    padding: 25px;
    flex-grow: 1; /* Permet au contenu de prendre l'espace restant et pousse les liens en bas */
    display: flex;
    flex-direction: column;
}
.project-content h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--text-color);
}
.project-content p {
    font-size: 0.95rem;
    color: var(--text-secondary-color);
    margin-bottom: 20px;
    flex-grow: 1; /* Permet au paragraphe de prendre l'espace restant */
}
.project-tags { margin-bottom: 25px; display: flex; flex-wrap: wrap; gap: 8px; }
.project-tags span {
    background-color: var(--accent-color);
    color: var(--bg-dark-primary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    transition: background-color var(--transition-speed) ease;
}
body.light-mode .project-tags span { color: var(--bg-light-secondary); }
.project-tags span i { margin-right: 6px; }

.project-links { 
    margin-top: auto; /* Pousse les liens vers le bas de la carte */
    text-align: right; 
    position: relative;
    z-index: 2; /* S'assure que ces liens sont au-dessus de project-card-link */
    display: flex; /* Pour aligner les boutons si plusieurs */
    justify-content: flex-end; /* Aligner à droite */
    gap: 10px; /* Espace entre les boutons */
}

/* Supprimez toutes les règles concernant .project-swiper, .swiper-slide, .swiper-pagination, .swiper-button-next, .swiper-button-prev */
/* Conservez cependant les styles du .veille-swiper pour la section Veille Technologique */

/* Exemple de ce qu'il faut supprimer dans style.css (section Projets) */
/*
.project-swiper { ... }
.swiper-slide { ... }
.project-swiper .swiper-pagination-bullet { ... }
.project-swiper .swiper-pagination-bullet-active { ... }
.project-swiper .swiper-button-next, .project-swiper .swiper-button-prev { ... }
.project-swiper .swiper-button-next::after, .project-swiper .swiper-button-prev::after { ... }
*/

/* Responsive Design (Assurez-vous que .project-grid est bien géré ici) */
@media (max-width: 992px) {
    /* ... vos styles existants ... */
    /* Ancien : .project-grid { grid-template-columns: 1fr; gap: 30px; } */
    /* Ces media queries sont désormais intégrées dans .project-grid ci-dessus */
}

@media (max-width: 768px) {
    /* ... vos styles existants ... */
    /* Ancien : .project-grid { grid-template-columns: 1fr; gap: 30px; } */
}

@media (max-width: 480px) {
    /* ... vos styles existants ... */
}



/* Section Parcours (CV) */
.cv-download-cta { text-align: center; margin-bottom: 60px; }
.cv-download-cta p { font-size: 1.1rem; margin-bottom: 20px; }
.cv-download-cta .btn { margin: 5px; } /* Espacement pour les boutons CV */

.parcours-layout-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 50px;
}
@media (min-width: 992px) {
    .parcours-layout-container { grid-template-columns: 1fr 1fr; gap: 70px; }
}

.parcours-column-title {
    text-align: left;
    font-size: 1.7rem;
    margin-bottom: 30px;
    color: var(--text-color);
    padding-bottom: 15px;
    border-bottom: 3px solid var(--border-color);
    position: relative;
}
.parcours-column-title::before {
    content: '';
    position: absolute;
    bottom: -3px; /* Aligns with border-bottom */
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
}

.timeline { position: relative; padding: 10px 0 20px 10px; }
.timeline::before { /* Vertical line */
    content: '';
    position: absolute;
    left: 20px; /* Match half of icon width */
    top: 5px;
    bottom: 5px;
    width: 3px;
    background-color: var(--border-color);
    border-radius: 2px;
}
.timeline-item { position: relative; margin-bottom: 30px; padding-left: 55px; } /* Increased padding-left */
.timeline-icon {
    position: absolute;
    left: 0;
    top: 0;
    width: 42px; height: 42px;
    border-radius: 50%;
    background-color: var(--accent-color);
    color: var(--bg-dark-primary);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    border: 3px solid var(--bg-secondary-color); /* Pour que l'icône se détache */
    z-index: 1;
    box-shadow: 0 0 0 4px var(--accent-color); /* Subtle glow */
}
body.light-mode .timeline-icon { color: var(--bg-light-secondary); }

.timeline-content {
    background-color: var(--bg-tertiary-color);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 12px var(--shadow-color);
    position: relative; /* For potential pseudo-elements like arrows */
}
.timeline-content h4 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: var(--text-color);
}
.timeline-date {
    font-size: 0.85rem;
    color: var(--accent-color);
    margin-bottom: 12px;
    font-weight: 500;
    display: block;
}
.timeline-content ul { list-style: none; padding-left: 0; }
.timeline-content ul li {
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-secondary-color);
    position: relative;
    padding-left: 20px;
}
.timeline-content ul li::before {
    content: '\f00c'; /* FontAwesome check icon */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 3px;
    color: var(--accent-color);
    font-size: 0.8em;
}
.timeline-content p {
    font-size: 0.95rem;
    margin-bottom: 0;
}

.additional-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 60px;
    text-align: left;
}
.info-block {
    background-color: var(--bg-tertiary-color);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 12px var(--shadow-color);
}
.info-block h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--accent-color);
}
.info-block h3 i { margin-right: 10px; }
.info-block p { font-size: 0.95rem; color: var(--text-secondary-color); margin-bottom: 8px; }


/* Section Contact */
.contact-intro {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 40px auto;
    font-size: 1.05rem;
}
#contactForm {
    max-width: 750px;
    margin: 0 auto;
    padding: 35px;
    background-color: var(--bg-tertiary-color);
    border-radius: var(--border-radius);
    box-shadow: 0 8px 25px var(--shadow-color);
}
.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    margin-bottom: 25px;
}
.form-row .form-group {
    flex: 1 1 calc(50% - 12.5px); /* Gère le gap */
    min-width: 250px;
}
#contactForm > .form-group { /* Pour le champ textarea seul */
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background-color: var(--bg-secondary-color);
    color: var(--text-color);
    font-size: 1rem;
    font-family: var(--font-primary);
    transition: border-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease, background-color var(--transition-speed) ease;
}
.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-secondary-color);
    opacity: 0.7;
}
.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(from var(--accent-color) r g b / 0.25);
    background-color: var(--bg-tertiary-color);
}
.form-group textarea { resize: vertical; min-height: 150px; }

.btn-submit {
    width: 100%;
    padding: 16px;
    font-size: 1rem;
}
#form-status {
    margin-top: 25px;
    text-align: center;
    font-weight: 500;
    font-size: 0.95rem;
}

/* Footer */
footer {
    text-align: center;
    padding: 60px 0 30px 0;
    background-color: var(--bg-dark-primary); /* Toujours sombre, comme Tamdaz */
    color: var(--text-dark-secondary); /* Texte pour fond sombre */
    border-top: 1px solid var(--border-dark);
    margin-top: 0; /* Si la section précédente est section-alt */
}
body.section-alt + footer {
    margin-top: 0;
}
.social-links { margin-bottom: 25px; }
.social-links a {
    font-size: 1.8rem;
    margin: 0 15px;
    color: var(--text-dark-secondary);
    transition: color var(--transition-speed) ease, transform var(--transition-speed) ease;
}
.social-links a:hover {
    color: var(--accent-primary-dark); /* Accent du mode sombre */
    transform: translateY(-4px) scale(1.1);
}
footer p {
    font-size: 0.9rem;
    margin-bottom: 5px;
}
.footer-credit {
    font-size: 0.8rem;
    opacity: 0.7;
    margin-top: 15px;
}


/* Animations au défilement */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}
/* Délais pour certains éléments */
.hero-content h1 { transition-delay: 0.2s; }
.hero-content .subtitle { transition-delay: 0.4s; }
.hero-description { transition-delay: 0.6s; }
.hero-actions { transition-delay: 0.8s; }


/* Responsive Design */
@media (max-width: 992px) {
    #mainHeader .nav-items-container {
        display: none; /* Caché par défaut */
        flex-direction: column;
        align-items: stretch; /* Les éléments prennent toute la largeur */
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        height: calc(100vh - var(--header-height));
        background-color: var(--bg-color); /* Utilise la couleur de fond du body */
        box-shadow: 0 5px 15px var(--shadow-color);
        padding: 30px 0;
        overflow-y: auto;
        transform: translateX(100%); /* Vient de la droite */
        transition: transform 0.35s cubic-bezier(0.23, 1, 0.32, 1); /* EaseOutQuint */
    }
    #mainHeader .nav-items-container.open {
        transform: translateX(0);
        display: flex; /* Affiché quand 'open' */
    }
    #navMenu {
        flex-direction: column;
        width: 100%;
        align-items: center;
    }
    #navMenu li {
        margin: 0;
        width: 100%;
    }
    #navMenu li a {
        display: block;
        padding: 18px 25px;
        text-align: center;
        border-bottom: 1px solid var(--border-color);
        font-size: 1.1rem;
    }
    #navMenu li:last-of-type a { border-bottom: none; }
    #darkModeToggle {
        margin: 30px auto; /* Centré horizontalement */
        display: block; /* Nécessaire pour le margin auto horizontal */
        padding: 10px 16px;
        font-size: 1rem;
    }
    .mobile-menu-button { display: block; }

    .parcours-layout-container {
        gap: 40px;
    }
     .additional-info-grid {
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .section { padding: 80px 0; }
    .section-title { font-size: clamp(1.8rem, 6vw, 2.5rem); margin-bottom: 40px; }
    .hero { min-height: calc(90vh - var(--header-height));}
    .hero-content h1 { font-size: clamp(2rem, 7vw, 3.5rem); }
    .hero-content .subtitle { font-size: clamp(1rem, 2.5vw, 1.3rem); }

    .about-layout { grid-template-columns: 1fr; } /* Empiler sur mobile */
    /* .project-grid { grid-template-columns: 1fr; gap: 30px; } /* Remplacé par Swiper */
    .parcours-layout-container { grid-template-columns: 1fr; } /* Empiler */
    
    .form-row { flex-direction: column; gap: 0; margin-bottom: 0; }
    .form-row .form-group { margin-bottom: 25px; }
    #contactForm > .form-group { margin-bottom: 25px; }
    #contactForm { padding: 25px; }

    .additional-info-grid { grid-template-columns: 1fr; }

    /* Swiper responsive */
    .project-swiper .swiper-button-next,
    .project-swiper .swiper-button-prev {
        /* Option: cacher les boutons sur mobile et ne garder que la pagination */
        /* display: none;  */
        width: calc(var(--swiper-navigation-size, 44px) / 44 * 24);
        height: calc(var(--swiper-navigation-size, 44px) / 44 * 24);
        padding: 8px;
    }
    .project-swiper .swiper-button-next::after,
    .project-swiper .swiper-button-prev::after {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    body { font-size: 15px; }
    .section { padding: 60px 0; }
    .hero-content h1 { font-size: clamp(1.8rem, 9vw, 2.8rem); }
    .hero-actions { display: flex; flex-direction: column; gap: 15px; align-items: center;}
    .hero-actions .btn { width: 80%; max-width: 300px; }
    .btn { padding: 10px 20px; font-size: 0.9rem; }
    .section-title::after { width: 60px; height: 3px; }
    .timeline-content { padding: 20px; }
    .timeline-content h4 { font-size: 1.1rem; }
    .social-links a { font-size: 1.6rem; margin: 0 12px; }
    .cv-download-cta .btn { width: 70%; }
}