/* =========================
   VARIABLES & THÈMES
   ========================= */
:root {
  /* Variables pour le thème sombre (par défaut) */
  --background-color: #1e1f2f; /* Couleur de fond principale */
  --text-color: #c8c4c4; /* Couleur du texte principale */
  --card-bg: #343654; /* Couleur de fond des cartes/conteneurs */
  --accent-color: #5d5dff; /* Couleur d'accentuation (liens, bordures, etc.) */
  --secondary-bg: #232436; /* Couleur de fond secondaire */
  --border-color: #5d5dff; /* Couleur des bordures */
  --shadow-color: rgba(0, 0, 0, 0.3); /* Couleur des ombres */
  --input-bg: rgba(
    255,
    255,
    255,
    0.1
  ); /* Couleur de fond des champs de formulaire */
  --skill-icon-bg: #343654; /* Couleur de fond des icônes de compétence */
  --skill-text-color: #b8c2cc; /* Couleur du texte des compétences */
  --transition-speed: 0.3s; /* Vitesse de transition générale */
  --accent-rgb: 93, 93, 255; /* Valeur RGB de #5d5dff pour les ombres */
}

[data-theme="light"] {
  /* Variables pour le thème clair */
  --background-color: rgb(242, 240, 250);
  --text-color: #6d6a6a;
  --card-bg: rgba(255, 255, 255, 0.8);
  --accent-color: #c822ff; /* Couleur d'accentuation change en rose */
  --secondary-bg: rgba(229, 227, 255, 0.8);
  --border-color: #5d5dff;
  --shadow-color: rgba(93, 93, 255, 0.15);
  --input-bg: rgba(0, 0, 0, 0.05);
  --skill-icon-bg: rgba(255, 255, 255, 0.8);
  --skill-text-color: #555555;
  --accent-rgb: 255, 102, 196; /* Valeur RGB de #ff66c4 pour les ombres en mode clair */
}

/* =========================
   RESET & STYLES DE BASE
   ========================= */


@import url("https://fonts.googleapis.com/css2?family=Iceland&family=Lato:wght@400;500;700&display=swap");

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

body {
  font-family: "Open Sans", sans-serif;
  font-optical-sizing: auto;
  line-height: 1.6;
  text-align: center;
  color: var(--text-color);
  position: relative;
  z-index: 0;
  background-color: transparent !important;
  transition: color var(--transition-speed) ease;
  padding-top: 90px;
}

body.contact-page,
body.project-page {
  padding-top: 60px;
}

body::before,
body::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

body::before {
  background: url("../images/emily-bernal-v9vII5gV8Lw-unsplash.jpg")
    center/cover no-repeat fixed;
  opacity: 0.1;
  z-index: -1;
  transition: opacity var(--transition-speed) ease;
}

body::after {
  background-color: var(--background-color);
  z-index: -2;
  transition: background-color var(--transition-speed) ease;
}

[data-theme="light"] body::before {
  opacity: 0;
}

h1,
h2,
h3 {
  font-family: "Iceland", sans-serif;
}

p,
li,
article {
  font-family: "Open Sans", sans-serif;
}

/* =========================
   DIVISEUR D'INTRO
   ========================= */
.intro-divider {
  margin: 40px auto 80px;
  width: min(90%, 640px);
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--accent-color),
    #c822ff,
    transparent
  );
  position: relative;
}
.intro-divider::after {
  content: "";
  position: absolute;
  inset: -12px 0 -20px;
  background: linear-gradient(180deg, rgba(93, 93, 255, 0.2), transparent);
  filter: blur(12px);
  opacity: 0.6;
}

/* =========================
   CONTENEUR PRINCIPAL ET SECTIONS
   ========================= */
/* Conteneur principal du contenu */
main {
  overflow: hidden;
  width: 100%;
  margin: 0px;
  padding: 0px; /* Supprimez le padding-left: 250px; d'ici s'il y était */
  background-color: transparent !important;
  transition: padding-left 0.4s ease; /* Transition pour le décalage fluide */
}

/* Nouvelle règle : Décaler main lorsque le menu est ouvert */
body.body-menu-open main {
  pointer-events: none;
  padding-left: 20%;
  /* IMPORTANT: Cette valeur doit correspondre à la largeur de votre .dropdown-menu. 
  Si width: 250px pour le menu, utilisez padding-left: 250px; ici */
}

/* Empêcher le scroll de la page quand le menu est ouvert */
body.body-menu-open {
  overflow: auto;
}

/* Override pour le thème clair */
[data-theme="light"] main {
  background-color: rgba(255, 255, 255, 0.997) !important;
  /* ou utilisez une autre couleur de votre choix */
}

/* Styles de base pour les sections - Mode sombre par défaut */
section {
  scroll-margin-top: 100px; /* Ajuste le point d'arrivée lors du défilement */
  margin-top: 0px;
  margin-bottom: 100px; /* Marges entre les sections */
  background-color: transparent !important;
  padding: 0px; /* Padding pour l'espace interne */
}

/* Marge spécifique pour l'ancre #about pour compenser le header fixe */
section#about,
#about {
  scroll-margin-top: 100px;
  margin-top: 50px;
  border-radius: 25%;
}

section#projects,
#projects {
  scroll-margin-top: 100px;
  margin-top: 100px;
}

section#skills,
#skills {
  scroll-margin-top: 100px;
  margin-top: 100px;
}

/* ==================================
   ANIMATIONS, TRANSITIONS, BOUTONS
   ================================== */

/* Styles pour le bouton "Voir plus d'articles" */
.view-more-container {
  display: flex;
  justify-content: center;
  margin-top: 60px;
}

.btn-view-more {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-color);
  font-family: "Iceland", sans-serif;
  font-size: 1.3rem;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
}

.btn-view-more:hover {
  color: #c822ff;
  transform: translateY(-2px);
}

/* Animation d'apparition séquentielle */
.intro-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 1200px;
  margin: 25px auto;
}

/* Titre principal */
.intro-text h1 {
  margin-bottom: 0;
  width: 100%;
  text-align: center;
}

/* Container photo et texte */
.intro-text .content-wrapper {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 100px;
  width: 100%;
  margin: 20px 0px 20px 0px;
}

/* Style de la photo de profil */

.intro-text .profile-photo-container {
  opacity: 0;
  transform: translateX(-100px);
  transition: opacity 1s ease, transform 1s ease;
  border-radius: 2%;
  overflow: hidden;
  border: 1px solid var(--accent-color);
  box-shadow: 0 5px 5px rgba(var(--accent-rgb), 0.5);
  margin: 0;
  /* Dimensions fixes qui correspondent à l'image */
  width: 600px; /* Même valeur que la photo */
  max-width: 100vw;
  height: 450px;
  /* Centrage du contenu */
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Style de la photo */
.intro-text .profile-photo {
  width: 480px;
  height: 330px;
  object-fit: cover;
  border-radius: 2%;
  box-shadow: 2 2px 3px rgba(0, 0, 0, 0.15);
  filter: brightness(0.86);
}

/* Ombre de la photo de profil au survol pour le thème clair */
[data-theme="light"] .intro-text .profile-photo-container {
  box-shadow: 0 5px 15px var(--accent-color);
}

/* Conteneur de texte */
.intro-text .text-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Titres et paragraphes dans la section texte */
.intro-text .text-content p,
.intro-text .text-content h2 {
  margin-bottom: 20px;
  text-align: center;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
}

.text-content p {
  color: #c2c2c2;
}

/* Animations pour le titre, le paragraphe de texte et le bouton de la page d'accueil */
.intro-text .animated-title {
  opacity: 0;
  transform: translateX(500px);
  transition: opacity 1.8s ease-out, transform 1.8s ease-out;
  margin-bottom: 80px;
  margin-top: 30px;
  font-size: 5rem;
}

.intro-text .animated-paragraph {
  opacity: 0;
  transform: translateX(-500px);
  transition: opacity 2.4s ease-out, transform 2.4s ease-out;
  margin-bottom: 25px;
  font-size: 1.6rem;
}

/* Bouton explorer */
.intro-text .btn-explore {
  /* Animation d'apparition */
  margin: 45px;
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
  /* Style de base */
  display: inline-block;
  padding: 8px 25px;
  font-size: 1.5rem;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  border-radius: 5%;
  box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.4);
  /* Effet brillant */
  background-clip: text;
  -webkit-background-clip: text;
  background-image: linear-gradient(
    135deg,
    var(--accent-color) 0%,
    #ffffff 30%,
    var(--accent-color) 60%,
    #ffffff 100%
  );
  background-size: 200% auto;
  /* Combinaison des animations */
  animation: fadeInUp 0.8s ease forwards 3.5s, pulseButtonLight 2s infinite 3s,
    textShine 3s linear infinite 3s,
    /* textShine commence à 3s */ floatButton 3s ease-in-out infinite 5.5s; /* floatButton commence après 4s */
}

.intro-text .btn-explore:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(var(--accent-rgb), 0.6);
}

/* Bouton de téléchargement CV */
.btn-download-cv {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 30px;
  font-size: 1.4rem;
  margin: 50px 0 0;
  background: linear-gradient(45deg, var(--accent-color), #5d5dff);
  color: var(--text-color);
  border-radius: 15%;
  text-decoration: none;
  box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.4);
  transition: transform 0.3s, box-shadow 0.3s;
  border: none;
  cursor: pointer;

  /* Animation d'apparition */
  opacity: 1; /* Commencer visible plutôt que caché */
  transform: translateY(0); /* Position initiale normale */

  /* Nouvelles animations en boucle continue */
  animation: floatButton 3s ease-in-out infinite, pulseButton 2s infinite,
    textShine 3s linear infinite;

  /* Effet brillant en mode sombre */
  background-clip: text;
  -webkit-background-clip: text;
  background-image: linear-gradient(
    135deg,
    var(--secondary-bg) 0%,
    #ffffff 30%,
    var(--secondary-bg) 60%,
    #ffffff 100%
  );
  background-size: 200% auto;
}

/* Style spécifique pour le thème clair */
[data-theme="light"] .btn-download-cv {
  background: linear-gradient(45deg, #c822ff, #ffb3ff);
  background-clip: initial;
  -webkit-background-clip: initial;
  color: white;
  /* Choisissez UNE SEULE animation selon votre préférence : */
  animation: floatButton 3s ease-in-out infinite, pulseButtonLight 2s infinite;
}

/* Pour garantir que l'icône est visible en mode clair */
[data-theme="light"] .btn-download-cv i {
  color: white;
}

/* Style pour l'icône dans le bouton */
.btn-download-cv i {
  margin-right: 15px;
  display: inline-block;
  color: inherit; /* Hérite la couleur du parent */
}

/* Effet au survol */
.btn-download-cv:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(var(--accent-rgb), 0.6);
}

/* Keyframes pour les animations */
/* Animation de flottement intensifiée */
@keyframes floatButton {
  0% {
    opacity: 0.7;
    transform: translateY(0px) translateX(0px) rotate(0deg);
  }
  25% {
    opacity: 0.85;
    transform: translateY(-15px) translateX(5px) rotate(1deg);
  }
  50% {
    opacity: 1;
    transform: translateY(-20px) translateX(0px) rotate(0deg);
  }
  75% {
    opacity: 0.85;
    transform: translateY(-15px) translateX(-5px) rotate(-1deg);
  }
  100% {
    opacity: 0.7;
    transform: translateY(0px) translateX(0px) rotate(0deg);
  }
}

@keyframes fadeInScale {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-500px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(-500px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes textShine {
  0% {
    background-position: 0% center;
  }
  100% {
    background-position: 200% center;
  }
}

/* Animation d'arrivée depuis la gauche pour le texte */
@keyframes SlideInLeft {
  from {
    opacity: 0;
    transform: translateX(
      -500px
    ); /* Ou une autre valeur pour un effet différent */
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Animation d'arrivée depuis la droite pour le texte */
@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(500px); /* Ou une autre valeur comme 50vw ou 300px */
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Animation de pulsation pour le bouton */
@keyframes pulseButton {
  0% {
    box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.4);
  }
  50% {
    box-shadow: 0 5px 25px rgba(var(--accent-rgb), 0.7);
  }
  100% {
    box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.4);
  }
}

/* Applique le dégradé aux textes de l'intro dans le thème clair */
[data-theme="light"] .intro-text .text-content p,
[data-theme="light"] .intro-text .text-content h2 {
  background: linear-gradient(45deg, var(--accent-color), #5d5dff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
}

/* Style du bouton explorer en thème clair */
[data-theme="light"] .intro-text .btn-explore {
  /* Fond et style de base */
  background: linear-gradient(
    45deg,
    #c822ff,
    #ffb3ff
  ); /* Nouveau dégradé rose plus vif */
  color: white; /* Couleur du texte visible (pas transparent) */
  box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.3);
  border: none;
  animation: fadeInUp 0.8s ease forwards 3.5s, pulseButtonLight 2s infinite 3s,
    textShine 3s linear infinite 3s,
    /* textShine commence à 3s */ floatButton 3s ease-in-out infinite 5.5s; /* floatButton commence après 4s */
}

/* Effet de brillance pour le texte uniquement si vous le souhaitez */
[data-theme="light"] .intro-text .btn-explore.text-effect {
  /* Si vous voulez l'effet brillant sur le texte, utilisez cette classe séparément */
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  background-image: linear-gradient(
    135deg,
    var(--secondary-bg) 0%,
    #333333 30%,
    var(--secondary-bg) 60%,
    #333333 100%
  );
  background-size: 200% auto;
}

/* Effet de survol en thème clair */
[data-theme="light"] .intro-text .btn-explore:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(var(--accent-rgb), 0.5);
}

/* Keyframe spécifique pour le thème clair */
@keyframes pulseButtonLight {
  0% {
    box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.3);
  }
  50% {
    box-shadow: 0 5px 25px rgba(var(--accent-rgb), 0.5);
  }
  100% {
    box-shadow: 0 5px 15px rgba(var(--accent-rgb), 0.3);
  }
}

/* =========================
   ANIMATIONS AU DÉFILEMENT
   ========================= */

/* Animations pour le défilement */
.slide-hidden {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s ease-out, transform 0.8s ease-out, visibility 0s 0.8s; /* Ajout de visibility à la transition */
}

/* Animation depuis la gauche */
.slide-from-left {
  transform: translateX(-150px); /* Valeur par défaut pour les grands écrans */
}

/* Animation depuis la droite */
.slide-from-right {
  transform: translateX(150px); /* Valeur par défaut */
}

/* Animation depuis le bas */
.slide-from-bottom {
  transform: translateY(150px); /* Valeur par défaut */
}

/* Animation fade-in simple */
.fade-in {
  opacity: 0;
}

/* Classe qui sera ajoutée par JavaScript pour déclencher l'animation */
.slide-visible {
  opacity: 1;
  visibility: visible;
  transform: translate(0, 0);
  transition-delay: 0s; /* S'assurer que la transition de visibilité s'applique immédiatement */
}

/* Animation en cascade pour les enfants */
.cascade-container > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

/* Délais pour les enfants en cascade */
.cascade-container.slide-visible > *:nth-child(1) {
  transition-delay: 0.1s;
}
.cascade-container.slide-visible > *:nth-child(2) {
  transition-delay: 0.3s;
}
.cascade-container.slide-visible > *:nth-child(3) {
  transition-delay: 0.5s;
}
.cascade-container.slide-visible > *:nth-child(4) {
  transition-delay: 0.7s;
}
.cascade-container.slide-visible > *:nth-child(5) {
  transition-delay: 0.9s;
}

/* Rendre visible les enfants quand le parent est visible */
.cascade-container.slide-visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* =========================
   LOADER STYLES
   ========================= */
#loader-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--background-color);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s ease-out, visibility 0s linear 0.5s;
}

/* Classe pour cacher le loader via JS */
#loader-wrapper.hidden {
  opacity: 0;
  visibility: hidden;
}

#loader-video {
  width: 125px;
  height: 125px;
  border-radius: 50%;
  object-fit: contain;
  border: 2px solid var(--border-color);
  box-shadow: 0 5px 100px #5d5dff;
}

/* Assurer que la couleur de fond du loader s'adapte au thème clair */
[data-theme="light"] #loader-wrapper {
  background-color: var(--background-color);
}

/* =========================
   HEADER (Normal & Compact) 
   ========================= */
header,
.compact-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2001;
  transition: transform 0.2s ease, background-color 0.3s ease,
    box-shadow 0.3s ease;
  will-change: transform;
  background: rgba(35, 36, 54, 0.9);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  border-bottom: 3px solid transparent;
  border-image: linear-gradient(45deg, var(--accent-color), #c822ff) 1;
}

/* Classe pour cacher le header */
header.header-hidden,
.compact-header.header-hidden {
  transform: translateY(-100%);
}

/* Styles spécifiques au header normal */
header {
  padding-top: 10px;
  padding-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.header-placeholder {
  display: none;
}

/* Centrage du logo et du hamburger */
.header-logo img {
  margin: 5px 30px 0px 45px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
}

.header-logo :hover {
  transform: scale(1.1);
}

/* Ajustements pour le logo vidéo */
#logo-video {
  display: block;
  height: 50px;
  width: auto;
  margin: 0;
  margin-bottom: 0;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  box-shadow: 0 5px 100px #5d5dff;
}

/* Réseaux sociaux dans le header */
header .social-media {
  display: flex;
  justify-content: flex-end; /* Alignement à droite au lieu de center */
  gap: 25px; /* Réduit légèrement l'espacement entre les icônes */
  margin: 0;
  margin-left: auto; /* Pousse les éléments vers la droite */
  margin-right: 0px; /* Marge à droite pour l'espacement */
}

/* Taille réduite pour les icônes dans le header */
header .social-media a {
  width: 45px; /* Plus petit que les 66px d'origine */
  height: 45px; /* Plus petit que les 66px d'origine */
  border-radius: 50%;
  transition: all 0.4s ease;
  box-shadow: 0 5px 15px var(--shadow-color); /* Ombre légèrement réduite */
  position: relative;
  overflow: hidden;
}

/* Ajuster la taille des icônes dans le header */
header .social-media img {
  width: 30px; /* Plus petit que les 32px d'origine */
  height: 30px; /* Plus petit que les 32px d'origine */
  position: relative;
  z-index: 1;
  transition: filter 0.3s ease;
}

/* Contrôles (Thème/Langue) dans le menu déroulant */
.menu-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  padding: 0px;
  margin: 0px; /* Ajustement de la marge pour le menu déroulant */
  width: 200px;
}

.menu-controls button {
  background: none;
  border: none;
  color: #5d5dff;
  outline: none;
  padding: 0;
  cursor: pointer;
}

.menu-controls :hover {
  color: #c822ff;
  transform: scale(1.1);
}

/* Thème clair pour le menu dropdown */
[data-theme="light"] .dropdown-menu {
  background-color: #ffffff00; /* Fond transparent pour le menu déroulant */
  color: var(--text-color);
}
[data-theme="light"] .dropdown-nav a {
  color: var(--accent-color);
}
[data-theme="light"] .dropdown-nav a:hover {
  color: #5d5dff;
}
[data-theme="light"] .menu-controls {
  border-top-color: var(--border-color);
}

/* Effet au survol adapté pour le header */
header .social-media a:hover {
  transform: translateY(-5px) scale(1.1); /* Moins prononcé que l'original */
}

/* Styles pour l'icône Hamburger */

.hamburger {
  cursor: pointer;
  font-size: 1.5rem;
  color: #fff; /* Couleur de l’icône (blanc pour contraste) */
  transition: color 0.3s;
  background: linear-gradient(
    45deg,
    var(--accent-color),
    #c822ff
  ); /* Dégradé */
  border: 1px solid var(--accent-color);
  border-radius: 50%;
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translate(-50%, 50%);
  z-index: 1002;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  padding: 0;
  line-height: normal;
}

/* Icône hamburger dans le header */
.hamburger:hover {
  transform: translate(-50%, 50%) scale(1.1);
  background-color: #c822ff;
  color: white;
}

.hamburger svg {
  transition: transform 0.3s ease;
  color: white;
  width: 20px;
  height: 20px;
}

/* Rotation du SVG quand le menu est actif */
.hamburger.active svg {
  transform: rotate(180deg);
}

/* Styles spécifiques au header compact (plus petit) */
.compact-header {
  height: 60px; /* Hauteur fixe réduite */
  display: flex; /* Utilisation de flexbox */
  align-items: center; /* Alignement vertical */
  justify-content: space-between; /* Assure l'espacement entre les groupes gauche/droite */
  padding: 0 20px; /* Padding horizontal */
}

/* Classes pour masquer/afficher le header au scroll */
header.nav-hidden,
.compact-header.nav-hidden {
  transform: translateY(-100%);
} /* Cache le header en le déplaçant vers le haut */
/* Style optionnel quand le header est visible après scroll */
header.nav-scrolled,
.compact-header.nav-scrolled {
  background-color: rgba(35, 36, 54, 0.95);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Styles du header en thème clair */
[data-theme="light"] header,
[data-theme="light"] .compact-header {
  background-color: rgb(240, 238, 255);
  box-shadow: 0 4px 15px var(--shadow-color);
  border-bottom-color: var(--accent-color);
  border-radius: 0px 0px 0px 0px;
}

/* Alignement du contenu du Header */
.header-container {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
} /* Utilisé dans le header compact pour structurer */
.compact-header #logo-video {
  height: 35px;
} /* Logo légèrement plus petit dans le header compact */

/* Contrôles Header (Langue & Thème) */
.header-left {
  display: flex;
  align-items: center;
  gap: 15px;
} /* Côté gauche du header compact */
.header-right {
  display: flex;
  align-items: center;
  gap: 15px;
} /* Côté droit du header compact */

/* Ordre des éléments dans le header compact (côté gauche) */
.compact-header .header-left .btn-back-home {
  order: 1;
} /* Bouton retour en premier */
.compact-header .header-left .language-switch {
  order: 2;
} /* Sélecteur de langue ensuite */
.compact-header .header-left .page-title {
  order: 3;
  font-size: 1.2rem;
  margin: 0;
  color: var(--accent-color);
} /* Titre de la page en dernier */
[data-theme="light"] .compact-header .header-left .page-title {
  color: var(--accent-color);
} /* Assure la couleur en thème clair */

/* Sélecteur de langue */
.language-switch {
  display: flex;
  align-items: center;
  gap: 10px;
}
.lang-button {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: transform 0.3s ease;
} /* Bouton drapeau */
.lang-button:hover {
  transform: scale(1.1);
} /* Effet au survol */
.lang-button img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
} /* Image du drapeau */

/* Positionnement différent des contrôles dans les headers */
/* Les contrôles du header normal sont maintenant dans le dropdown ou placés via .header-right */
.compact-header .language-switch img {
  width: 40px;
  height: 40px;
} /* Taille drapeau dans header compact */

/* Bouton de changement de thème */
.theme-toggle button {
  background: none; /* Pas de fond */
  border: none; /* Pas de bordure */
  color: #7b7bff; /* Couleur par défaut pour les icônes SVG */
  outline: none; /* Pas de contour */
  padding: 0; /* Pas de padding */
  cursor: pointer; /* Curseur main */
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.3s ease, transform 0.3s ease; /* Ajustement transition */
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Ombre légère */
}
.theme-toggle button svg {
  width: 20px;
  height: 20px;
  transition: fill 0.3s ease;
  fill: currentColor;
} /* Style de l'icône SVG (lune/soleil), hérite la couleur du bouton */

.theme-toggle button:hover {
  color: #c822ff; /* Couleur rose au survol */
  transform: scale(1.6); /* Léger zoom */
}
.theme-toggle button:focus {
  outline: none; /* Pas de contour au focus */
}
/* Style pour le bouton de thème dans le header normal */
[data-theme="light"] .theme-toggle button {
  background: none; /* Pas de fond */
  border: none; /* Pas de bordure */
  color: #7b7bff; /* Couleur par défaut pour les icônes SVG */
  outline: none; /* Pas de contour */
  padding: 0; /* Pas de padding */
  cursor: pointer; /* Curseur main */
  box-shadow: 0 2px 5px var(--shadow-color); /* Ombre légère */
}
[data-theme="light"] .theme-toggle button:hover {
  color: #c822ff; /* Couleur rose au survol */
  transform: scale(1.1); /* Léger zoom */
  background-color: rgba(93, 93, 255, 0.15); /* Fond léger au survol */
  box-shadow: 0 4px 10px rgba(93, 93, 255, 0.2); /* Ombre accentuée au survol */
}

/* Icône hamburger au hover dans le header */
[data-theme="light"] .hamburger {
  color: #c822ff; /* Couleur rose par défaut */
}

[data-theme="light"] .hamburger:hover {
  transform: translate(-50%, 50%) scale(1.1);
  background-color: #5d5dff;
  color: white;
}

/* =========================
   DROPDOWN MENU 
   ========================= */
/* Conteneur principal du menu déroulant */
.dropdown-menu {
  position: fixed;
  top: 0; /* Aligné en haut */
  left: 0;
  width: 20%; /* Ou la largeur que vous souhaitez, ex: 250px ou 25% */
  height: 100vh; /* Toute la hauteur de la vue */
  background-color: #23243600; /* Couleur de fond transparente */
  color: white;
  padding: 40px;
  transform: translateX(-100%); /* Caché à gauche initialement */
  transition: transform 0.4s ease; /* Transition sur la transformation X */
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.2); /* Ombre sur le côté droit */
  z-index: 2000;
  text-align: left;
  overflow-y: auto; /* Pour le défilement si le contenu du menu est long */
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch; /* Défilement fluide sur iOS */
  pointer-events: auto; /* ✅ Capture les événements de souris */

  /* Masquer la barre de défilement pour Webkit (Chrome, Safari, Edge) */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE et Edge */
}

/* Correction pour cacher la barre de défilement WebKit */
.dropdown-menu::-webkit-scrollbar {
  display: none;
}

.dropdown-menu.active {
  transform: translateX(
    0
  ); /* Le menu devient visible en glissant depuis la gauche */
}

/* Liens de navigation dans le menu déroulant */
.dropdown-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 30px;
  margin-top: 100px;
  margin-bottom: 0px;
  align-items: start;
}

.dropdown-nav a {
  font-family: "Iceland", sans-serif;
  color: var(--accent-color);
  text-decoration: none;
  font-size: 1.4rem;
  font-weight: bolder;
  padding: 5px 10px;
  transition: color 0.3s, transform 0.2s;
  display: inline-block;
}

.dropdown-nav a:hover {
  color: #c822ff;
  transform: translateX(5px);
}

.dropdown-nav .nav-link {
  display: block;
  width: 100%;
  padding: 5px 10px;
  font-family: "Iceland", sans-serif;
  font-size: 1.4rem;
  color: var(--accent-color);
}

/* =========================
   SOUS-MENU DÉROULANT
   ========================= */

/* Conteneur parent (assure le bon contexte) */
.dropdown-submenu {
  position: relative;
}

/* Sous-menu: fermé par défaut, mais dans le flux (pas display:none) */
.dropdown-submenu > .submenu-list {
  /* Neutralise l'ancien display:none !important */
  display: flex !important;
  flex-direction: column;
  gap: 8px;

  /* Liste */
  list-style: none;
  margin: 5px 0 0 0;
  padding: 0 0 0 20px;

  /* État fermé (accordéon CSS) */
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(6px);

  /* Transitions */
  transition:
    max-height 0.25s ease,
    opacity 0.2s ease,
    transform 0.2s ease,
    visibility 0s linear 0.2s; /* retarde la visibilité pour éviter le flash */
}

/* Ouvrir au survol (desktop) ET quand un enfant a le focus (clavier/tactile) */
.dropdown-submenu:hover > .submenu-list,
.dropdown-submenu:focus-within > .submenu-list,
/* Fallback: focus direct sur le lien parent */
.dropdown-submenu > a:focus + .submenu-list {
  max-height: 1000px; /* assez grand pour contenir les éléments */
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
  transition-delay: 0s;
}

/* Style des éléments du sous-menu */
.dropdown-submenu .submenu-link {
  font-size: 1.2rem;
  padding: 0;
  opacity: 0.9;
}

/* Flèche du sous-menu */
.submenu-chevron {
  transition: transform 0.25s ease;
  margin-left: 5px;
}

/* Rotation de la flèche quand ouvert (hover ou focus-within) */
.dropdown-submenu:hover .submenu-chevron,
.dropdown-submenu:focus-within .submenu-chevron,
.dropdown-submenu > a:focus .submenu-chevron {
  transform: rotate(180deg);
}

/* Overlay sombre affiché derrière le menu déroulant (inchangé) */
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgb(0 0 0 / 0%);
  z-index: 999;
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.menu-overlay.active {
  display: block;
  opacity: 1;
  pointer-events: auto; /* ✅ Permet les clics sur l'overlay pour fermer */
}

/* =========================
   TITRES DE SECTION
   ========================= */
.title-banner {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  font-size: 2.5rem; /* Taille du texte */
  position: relative; /* Style bannière */
  padding: 20px;
  width: fit-content;
  margin: 0 auto 30px;
  border-radius: 5px 5px 15px 15px; /* Arrondit les coins inférieurs */ /* Dimensions et espacement */
}
h3.title-banner {
  font-size: 2rem; /* Taille du texte pour h3 */
  font-weight: bold; /* Gras */
  margin-bottom: 40px; /* Espacement en dessous */
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
} /* Titre secondaire */

/* Titre bannière en thème clair */
[data-theme="light"] .title-banner {
  color: var(--accent-color);
  box-shadow: 0 4px 15px var(--shadow-color);
}
[data-theme="light"] .title-banner::after {
  background: var(--accent-color);
}

/* =========================
   SECTION RADAR DIGITAL 
   ========================= */
/* Styles pour le titre principal de la section Radar sur la page d'accueil */
/* Cible le h2.section-title avec data-i18n="home.radarTeaserTitle" dans section.page-title-container */
section.page-title-container
  > h2.section-title[data-i18n="home.radarTeaserTitle"] {
  font-size: 3.5rem; /* Taille de police responsive, ajustée pour correspondre à d'autres titres principaux */
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  margin-bottom: 20px; /* Ajusté pour un espacement standard sous le titre */
  padding-bottom: 10px; /* Optionnel, pour s'assurer que le dégradé n'est pas coupé */
}

.page-subtitle {
  font-size: 1.6rem;
  color: var(--text-color); /* Couleur du sous-titre */
  padding: 40px; /* Espacement autour du sous-titre */
}

/* =========================
   SECTION ACTUALITÉS ACCUEIL
   ========================= */

.page-title-container {
  font-size: 2rem; /* Taille de police pour le titre principal des actualités */
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  font-weight: bold; /* Met le titre en gras */
  padding: 35px;
  margin-bottom: 150px;
  margin-top: 200px;
}

.news-teaser-section,
.all-news-list {
  padding: 0px 50px 0px 50px; /* Ajustez le padding selon vos besoins */
}

.news-teaser-section .section-title,
.all-news-list .main-page-title {
  margin-bottom: 40px; /* Espace sous le titre de la section */
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(
    auto-fit,
    minmax(450px, 1fr)
  ); /* Grille responsive */
  gap: 100px; /* Espace entre les cartes */
}

.news-card {
  height: auto; /* Hauteur automatique pour s'adapter au contenu */
  width: 100%; /* Prend toute la largeur du conteneur parent */
  border: 1px solid var(--border-color);
  background-color: rgb(79 89 102 / 2%);
  border-radius: 12px;
  overflow: hidden; /* Pour que l'image/icône ne dépasse pas si vous utilisez des images */
  display: flex; /* Pour que le lien prenne toute la carte */
  flex-direction: column;
  text-decoration: none; /* Enlève le soulignement du lien global de la carte */
  box-shadow: 0 5px 15px var(--accent-color); /* Ombre plus marquée au survol */
}

.news-card-link {
  /* Le lien <a> qui englobe la carte */
  text-decoration: none;
  color: inherit; /* Hérite la couleur du texte de la carte */
  display: flex;
  flex-direction: column;
  height: 100%; /* Pour que le lien remplisse la carte */
}

.news-card-image-container {
  height: 250px; /* Hauteur fixe pour l'image ou l'icône */ 
  background-color: var(--section-bg-light);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  width: 100%;
}

.news-card-image-container img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Assure que l'image couvre bien sans se déformer */
}

.news-card-icon {
  /* Si vous utilisez une icône à la place d'une image */
  font-size: 3rem;
  color: var(--accent-color);
}

.news-card-content {
  padding: 20px 25px;
  display: flex;
  flex-direction: column;
  flex-grow: 1; /* Permet à cette section de grandir et de pousser la dateline en bas */
}

.news-card-title {
  font-size: 1.8rem;
  color: var(--text-color);
  margin-bottom: 10px;
  font-weight: bold;
  line-height: 1.3;
}

.news-card-summary {
  font-size: 1rem;
  color: var(--text-color);
  line-height: 1.6;
  margin-bottom: 15px;
  flex-grow: 1; /* Permet au résumé de prendre l'espace disponible */
}

.news-card-dateline {
  font-size: 1rem;
  color: var(--accent-color);
  margin-top: auto; /* Pousse la dateline en bas de la carte */
}

.news-card-author {
  font-size: 0.9rem;
  color: var(--text-color-light);
  margin-top: 5px;
}

.view-all-news-container {
  margin-top: 20px; /* Espace au-dessus du bouton "Tout voir" */
}

/* =========================
   BLOG - STYLES GÉNÉRAUX
   ========================= */
.blog-page {
  background-color: var(--background-color);
}

.blog-main-container {
  padding-top: 0px;
}

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

/* =========================
   BLOG - BANNIÈRE HÉRO
   ========================= */
.blog-hero {
  text-align: center;
  padding: 60px 0;
  background: linear-gradient(
    135deg,
    rgba(93, 93, 255, 0.1),
    rgba(168, 52, 211, 0.85)
  );
  border-radius: 0 0 75px 75px;
  margin-bottom: 40px;
}

.blog-title {
  font-family: "Iceland", sans-serif;
  font-size: 3.5rem;
  margin-bottom: 20px;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}

.blog-subtitle {
  font-size: 1.2rem;
  max-width: 600px;
  margin: 0 auto;
  opacity: 0.8;
}

/* =========================
   BLOG - FILTRES
   ========================= */
.blog-filters {
  margin-bottom: 40px;
}

.filter-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 200px;
}

.search-box input {
  width: 100%;
  padding: 12px 45px 12px 15px;
  border: 1px solid rgba(93, 93, 255, 0.2);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(93, 93, 255, 0.1), rgba(168, 52, 211, 0.85));
  font-family: "Lato", sans-serif;
  color: var(--text-color);
}

.search-box button {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--accent-color);
}

.category-filter select {
  padding: 12px 35px 12px 15px;
  border: 1px solid rgba(93, 93, 255, 0.2);
  border-radius: 8px;
  background-color: rgba(93, 93, 255, 0.05);
  font-family: "Lato", sans-serif;
  color: var(--text-color);
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235d5dff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 16px;
  cursor: pointer;
}

/* =========================
   BLOG - CARTES D'ARTICLES
   ========================= */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px;
  margin-bottom: 50px;
}

.blog-card {
  background: rgba(35, 36, 54, 0.2);
  border-radius: 12px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(93, 93, 255, 0.2);
}

.blog-card-link {
  display: block;
  text-decoration: none;
  color: var(--text-color);
}

.blog-card-image-container {
  position: relative;
  height: 200px;
  overflow: hidden;
}

.blog-card-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-card-image {
  transform: scale(1.05);
}

.blog-card-category {
  position: absolute;
  top: 15px;
  right: 15px;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

.blog-card-content {
  padding: 25px;
}

.blog-card-title {
  font-family: "Iceland", sans-serif;
  font-size: 1.5rem;
  margin-bottom: 15px;
  color: var(--accent-color);
}

.blog-card-summary {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 20px;
  opacity: 0.9;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  opacity: 0.8;
}

.blog-card-readmore {
  color: var(--accent-color);
  font-weight: 600;
  transition: opacity 0.3s;
}

.blog-card:hover .blog-card-readmore {
  opacity: 1;
  text-decoration: none;
}

/* =========================
   BLOG - PAGINATION
   ========================= */
.blog-pagination {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 50px 0;
}

.pagination-btn {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid rgba(93, 93, 255, 0.3);
  background-color: transparent;
  color: var(--text-color);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pagination-btn:hover {
  background-color: rgba(93, 93, 255, 0.1);
  border-color: var(--accent-color);
}

.pagination-btn.active {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  color: white;
  border: none;
}

.pagination-btn.next-page {
  width: auto;
  padding: 0 15px;
}


/* =========================
   SECTION ARTICLE DÉTAILLÉ
   ========================= */

/* Styles pour la page d'article détaillé */
.article-detail-page .article-content-full {
  padding: 40px 20px;
}

.article-header-detailed {
  text-align: center;
  margin-bottom: 40px;
}

.article-title-main {
  font-size: 4rem;
  color: #c822ff;
  margin-bottom: 15px;
  margin-top: 50px;
}

.article-dateline-detailed {
  font-size: 1.2rem;
  color: var(--text-color-light);
  margin-bottom: 30px;
}

.article-banner-image {
  width: min(100%, 720px);
  height: auto;
  display: block;
  margin: 0 auto 60px;
  border-radius: 8px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.25);
}

.article-body {
  max-width: 800px; /* Limite la largeur du contenu de l'article pour la lisibilité */
  margin: 0 auto;
  font-size: 1.3rem;
  line-height: 1.8;
  color: var(--text-color);
  text-align: left;
}

.article-body h2 {
  font-size: 2.5rem;
  color: var(--accent-color);
  margin-top: 40px;
  margin-bottom: 20px;
}
.article-body h3 {
  font-size: 2rem;
  color: var(--accent-color);
  margin-top: 30px;
  margin-bottom: 15px;
}
.article-body p,
.article-body ul,
.article-body ol {
  margin-bottom: 20px;
  font-size: 1.3rem;
}
.article-body ul,
.article-body ol {
  padding-left: 30px;
}
.article-body a {
  color: var(--accent-color);
  text-decoration: underline;
}
.article-body a:hover {
  text-decoration: none;
}

.article-image img{
  width: 100%;
  height: auto;
  margin: 20px 0;
  border-radius: 8px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.article-navigation {
  margin-top: 50px;
  text-align: center;
}
.btn-nav-style {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 26px;
  font-weight: 700;
  font-size: 1rem;
  border-radius: 8px;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  border: 1px solid rgba(93, 93, 255, 0.35);
  box-shadow: 0 4px 18px rgba(93, 93, 255, 0.25);
  transition: transform 0.3s ease, box-shadow 0.3s ease, color 0.3s ease;
}

.btn-nav-style:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 24px rgba(93, 93, 255, 0.4);
  color: white;
  background-clip: border-box;
  -webkit-background-clip: border-box;
}

/* =========================
   SECTION "À PROPOS"
   ========================= */

.about-text-box {
  background: transparent;
  padding: 50px;
  max-width: 800px;
  margin: 150px auto;
}
.about-text-box p {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  line-height: 1.7;
  font-size: 1.4rem;
  margin-bottom: 0px;
} /* Style des paragraphes */

.link-schools-openclassrooms,
.link-schools-studi {
  /* Liens vers les écoles */
  color: var(--accent-color);
  text-decoration: none;
  font-weight: bold; /* Style de base */
  border-bottom: 2px dotted var(--accent-color);
  padding-bottom: 2px;
  transition: all 0.3s ease; /* Soulignement pointillé et transition */
}
.link-schools-openclassrooms:hover,
.link-schools-studi:hover {
  color: #5d5dff;
  border-bottom-style: solid;
} /* Changement au survol */

/* Conteneur pour la photo de profil */
.profile-photo {
  width: 500px;
  height: 500px;
  border-radius: 0;
  object-fit: contain; /* Dimensions, forme, ajustement image */
  border: 1px solid var(--border-color);
  box-shadow: 0 5px 100px #5d5dff;
}

/* Styles "À propos" en thème clair */
[data-theme="light"] .about-text-box {
  background: var(--card-bg);
  border-radius: 5%;
  box-shadow: 0 8px 30px var(--shadow-color) !important;
}
[data-theme="light"] .about-text-box p {
  color: var(--accent-color);
} /* Couleur du texte en thème clair */
[data-theme="light"] .link-schools-openclassrooms,
[data-theme="light"] .link-schools-studi {
  color: var(--accent-color);
  border-bottom-color: var(--accent-color);
}
[data-theme="light"] .link-schools-openclassrooms:hover,
[data-theme="light"] .link-schools-studi:hover {
  color: #c822ff;
  border-bottom-color: solid;
}
[data-theme="light"] .profile-photo {
  border-color: rgba(93, 93, 255, 0.6);
  box-shadow: 0 35px 80px var(--shadow-color);
}
[data-theme="light"] .profile-photo:hover {
  box-shadow: 0 35px 80px rgba(93, 93, 255, 0.25);
}

/* =========================
   BOUTONS
   ========================= */
/* Style de base commun pour les boutons principaux (dégradé) */
.btn,
.btn-back-home,
.btn-view-project,
.view-all-projects .btn,
.project-links a:first-child,
.contact-form button,
.project-detail .project-links a:first-child,
.project-links a {
  display: inline-block;
  padding: 8px 35px;
  background: linear-gradient(45deg, var(--accent-color), rgba(0, 0, 0, 0.2));
  color: white; /* Affichage, padding, fond dégradé, couleur texte */
  text-decoration: none;
  border-radius: 5%;
  font-weight: bold;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); /* Style texte, forme, ombre */
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  text-align: center;
  font-family: inherit; /* Transition, reset bordure, curseur, alignement */
}
/* Effet commun au survol des boutons principaux */
.btn:hover,
.btn-back-home:hover,
.btn-view-project:hover,
.view-all-projects .btn:hover,
.project-links a:first-child:hover,
.contact-form button:hover,
.project-detail .project-links a:first-child:hover {
  transform: translateY(-3px);
  box-shadow: 0 7px 20px rgba(93, 93, 255, 0.4);
  background: linear-gradient(
    45deg,
    #4a4aff,
    #4b75ff
  ); /* Léger déplacement, ombre accentuée, dégradé modifié */
}

/* Styles spécifiques à certains boutons */
.btn-back-home {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 20px;
} /* Bouton retour accueil (avec icône potentielle) */
.view-all-projects .btn {
  padding: 15px 30px;
  font-size: 1.1rem;
} /* Bouton "Voir tous les projets" (plus grand) */
.contact-form button {
  padding: 8px 25px;
  margin-top: 15px;
  font-size: 1.3rem;
  align-self: center;
  min-width: 200px;
  position: relative;
  overflow: hidden;
} /* Bouton envoyer formulaire */
.contact-form button::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.5s ease;
} /* Effet "shine" au survol */
.contact-form button:hover::before {
  left: 100%;
}

/* Style spécifique pour les liens GitHub (style secondaire) */
.project-links a.github-link {
  background-color: transparent;
  border: 1px solid var(--accent-color);
  color: var(--accent-color);
}
/* Style spécifique lien GitHub dans la page détail projet */
.project-detail .project-links a.github-link {
  background-color: rgba(35, 36, 54, 0.8);
  border: 2px solid var(--accent-color);
  color: #ffffff;
}
/* Effet survol commun pour les liens de projet (y compris GitHub) */
.project-links a:hover,
.project-detail .project-links a:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Bouton "Scroll to Top" (remonter en haut) */
.scroll-to-top {
  position: fixed;
  bottom: 50px;
  right: 40px;
  width: 40px;
  height: 40px;
  background: var(--accent-color);
  color: white; /* Positionnement, dimensions, couleurs */
  border: 2px solid var(--accent-color);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center; /* Bordure, forme, centrage icône */
  cursor: pointer;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 1000;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  padding: 0; /* Curseur, caché par défaut, transition, empilement, ombre */
}
.scroll-to-top svg {
  width: 30px;
  height: 30px;
  fill: currentColor;
} /* Icône flèche */
.scroll-to-top:hover {
  background: #c822ff;
  color: white;
  transform: translateY(-5px);
  box-shadow: 0 6px 15px rgba(93, 93, 255, 0.4);
} /* Effet au survol */

/* Scroll to top en thème clair */
[data-theme="light"] .scroll-to-top {
  background: var(--accent-color);
  color: white;
  border-color: #c822ff;
  box-shadow: 0 4px 10px var(--shadow-color);
}
[data-theme="light"] .scroll-to-top:hover {
  background: #5d5dff;
  color: white;
  border-color: #c822ff;
  box-shadow: 0 6px 15px rgba(93, 93, 255, 0.3);
}

/* =========================
   PROJETS (Grille, Aperçu, Détail)
   ========================= */
/* Grille principale des projets (page projets) */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(
    auto-fill,
    minmax(400px, 1fr)
  ); /* Grille en rangée */
  gap: 100px;
  padding: 100px;
  max-width: 1400px;
  margin: 0 auto;
  /* supprime grid-template-rows et max-height */
}

/* Effet Parallaxe */
.parallax-container {
  overflow: hidden;
  position: relative;
  border-radius: 0%;
  height: 200px;
} /* Conteneur */
.parallax-image {
  transition: transform 0.2s ease-out;
  width: 150%;
  height: 150%;
  object-fit: cover;
  position: absolute;
  top: -25%;
  left: -25%;
} /* Image plus grande pour effet */

/* Carte individuelle de projet */
.project-card {
  background-color: #34365400;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 8px 20px var(--shadow-color); /* Style de la carte */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column; /* Transition, hauteur, flex pour contenu */
  border: 1px solid transparent;
  border-image: 0;
}
.project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(93, 93, 255, 0.3);
} /* Effet au survol */
.project-card img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-bottom: 3px solid transparent;
  border-image: linear-gradient(45deg, var(--accent-color), #c822ff) 1;
} /* Image de la carte */
.project-info {
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-grow: 1;
} /* Zone de texte de la carte */
.project-info h3 {
  margin: 0 0 15px;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  font-size: 1.8rem;
  font-weight: bold;
} /* Titre */
.project-info p {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.6;
  margin-bottom: 20px;
  font-size: 1.3rem;
} /* Description */
.project-tech {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
} /* Technologies (tags) */
.project-tech span {
  background: rgb(0 0 0 / 0.1);
  color: var(--text-color);
  padding: 5px 10px;
  border-radius: 15%;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid rgba(93, 93, 255, 0.3);
} /* Style des tags */
.project-links {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
  margin-top: auto;
  margin-bottom: auto;
  margin-bottom: 30px;
}
/* Conteneur des liens (en bas) */
.project-links a {
  color: white;
  padding: 10px 20px;
  border-radius: 5%;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.2rem;
  min-width: 120px;
} /* Style des liens dans la carte */

/* Grille d'aperçu des projets (page d'accueil) */
.project-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 40px auto;
  padding: 20px;
} /* Grille 2 colonnes */
/* Aperçu individuel */
.project-preview {
  position: relative;
  border-radius: 15%;
  overflow: hidden;
  height: 350px;
  box-shadow: 0 10px 30px var(--shadow-color);
  transition: all 0.5s ease;
} /* Conteneur avec image */
.project-preview:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(93, 93, 255, 0.4);
} /* Effet survol conteneur */
.project-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.8s ease;
} /* Image */
.project-preview:hover img {
  transform: scale(1.1);
  filter: brightness(0.7) blur(2px);
} /* Effet survol image (zoom, assombrissement, flou) */
.project-preview-overlay {
  /* Overlay qui apparaît au survol */
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(
    to top,
    rgba(35, 36, 54, 0.9),
    transparent
  ); /* Positionnement, fond dégradé */
  padding: 30px 20px 20px;
  transform: translateY(100%);
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  opacity: 0; /* Caché en bas, transition complexe, invisible */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%; /* Centrage contenu */
}
.project-preview:hover .project-preview-overlay {
  transform: translateY(0);
  opacity: 1;
} /* Affichage de l'overlay au survol */
.project-preview-overlay h3 {
  color: white;
  font-size: 1.8rem;
  margin-bottom: 20px;
  text-align: center;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  transform: translateY(20px);
  opacity: 0;
  transition: all 0.5s ease 0.1s;
} /* Titre dans l'overlay (animation) */
.project-preview:hover .project-preview-overlay h3 {
  transform: translateY(0);
  opacity: 1;
} /* Animation titre au survol */
.btn-view-project {
  transform: translateY(20px);
  opacity: 0;
  transition: all 0.5s ease 0.2s;
} /* Bouton dans l'overlay (animation) */
.project-preview:hover .btn-view-project {
  transform: translateY(0);
  opacity: 1;
} /* Animation bouton au survol */

/* Bouton "Voir tous les projets" */
.view-all-projects {
  text-align: center;
  margin: 50px 0;
}

/* Page de détail d'un projet */
.project-detail {
  max-width: 900px;
  margin: 70px auto 0 auto; /* Centrage automatique avec auto */
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px; /* Espace entre les sections */
}
.project-hero {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  border-radius: 5%;
  box-shadow: 0 10px 30px var(--shadow-color);
  margin-bottom: 40px;
}
.project-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
  display: block;
} /* Style image */
.project-hero:hover img {
  transform: scale(1.05);
} /* Effet zoom sur image */
.project-hero::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 5px;
} /* Ligne colorée sous l'image */
.project-content {
  background: #34365400;
  border-radius: 15px;
  padding: 30px;
  box-shadow: 0 8px 30px var(--shadow-color);
  margin-bottom: 40px;
  border: 1px solid transparent;
} /* Conteneur du contenu du projet */
.project-content p {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.7;
  text-align: center;
  margin-bottom: 50px;
  font-size: 1.3rem; /* Taille du texte */
} /* Paragraphes */
.project-content h4 {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 1.5rem;
  border-bottom: 2px solid rgba(93, 93, 255, 0.2);
  padding-bottom: 30px;
  margin-top: 20px;
} /* Sous-titres */
.project-detail .project-tech {
  justify-content: center;
  margin: 20px 0;
} /* Technologies centrées */
.project-detail .project-links {
  justify-content: center;
  margin: 25px 0;
} /* Liens centrés */
.project-detail .project-links a {
  padding: 8px 25px;
  font-size: 1rem;
  min-width: 150px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
} /* Style des liens */

/* Navigation entre projets (Précédent/Suivant) */
.project-navigation {
  display: flex;
  justify-content: space-between;
  margin: 40px 0 40px;
  flex-wrap: wrap;
  gap: 15px; /* Ajout wrap et gap pour responsive */
}

.prev-project,
.next-project {
  display: inline-flex;
  align-items: center;
  gap: 12px; /* Légèrement augmenté l'espace */
  padding: 8px 20px; /* Augmenté le padding vertical et horizontal */
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  font-weight: bold;
  font-size: 0.9rem; /* Optionnel: Augmenter la taille de la police */
  border-radius: 5%;
  transition: all 0.3s ease;
  position: relative;
  z-index: 1;
  overflow: hidden;
  cursor: pointer; /* Ajout d'un curseur main */
}

.prev-project::before,
.next-project::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: -1;
}

.prev-project:hover,
.next-project:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(93, 93, 255, 0.5);
  color: white;
}

.prev-project:hover::before,
.next-project:hover::before {
  opacity: 1;
}

.prev-project svg,
.next-project svg {
  width: 22px; /* Optionnel: Augmenter la taille de l'icône */
  height: 22px; /* Optionnel: Augmenter la taille de l'icône */
  fill: currentColor;
  flex-shrink: 0; /* Empêche le SVG de rétrécir */
}

/* Galerie d'images du projet */
.project-gallery {
  background: #34365400;
  border-radius: 15px;
  padding: 25px;
  border: 1px solid transparent;
  margin-top: 40px;
  margin-bottom: 40px;
} /* Conteneur galerie */
.project-gallery:hover {
  box-shadow: 0 10px 30px rgba(93, 93, 255, 0.3);
} /* Effet survol galerie */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 25px;
} /* Grille responsive */
.gallery-item {
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  border: 1px solid var(--secondary-bg);
  transition: all 0.3s ease;
  height: 120px; /* Image individuelle */
  display: flex; /* Ajout pour centrer l'image */
  align-items: center; /* Centrage vertical */
  justify-content: center; /* Centrage horizontal */
  background-color: var(
    --secondary-bg
  ); /* Fond pour les images transparentes */
}
/* Effet survol image */
.gallery-item:hover {
  transform: translateY(-50px) scale(2.2);
  border-color: 1px solid transparent;
  border-image: linear-gradient(45deg, var(--accent-color), #c822ff) 1;
  box-shadow: 0 10px 25px rgba(93, 93, 255, 0.3);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: all 0.5s ease;
} /* Style image (contain pour voir toute l'image) */

/* Carrousel */
.carousel-container {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
  overflow: hidden;
}
.carousel-track {
  display: flex;
  transition: transform 0.7s ease;
  will-change: transform;
}
.carousel-item {
  min-width: 50%;
  min-height: 50%;
  padding: 20px;
  box-sizing: border-box;
  margin: 0 auto;
  flex: 0 0 auto;
}

.carousel-item .project-preview {
  height: 280px;
}
.carousel-item .project-preview img {
  height: 100%;
  object-fit: contain;
}

.carousel-controls {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin: 20px 0;
}
.carousel-btn {
  background-color: #5d5dff;
  color: white;
  border: 2px solid var(--accent-color);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s;
  font-size: 16px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}
.carousel-btn:hover {
  background-color: #c822ff;
  transform: scale(1.05);
}
.carousel-btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.3);
}

/* Styles Projets en thème clair */
[data-theme="light"] .project-card {
  background-color: var(--card-bg);
  box-shadow: 0 8px 20px var(--shadow-color);
  border-color: var(--accent-color);
}
[data-theme="light"] .project-info p {
  color: var(--accent-color);
}
[data-theme="light"] .project-tech span {
  background: rgba(93, 93, 255, 0.2);
  color: var(--accent-color);
  border-color: rgba(93, 93, 255, 0.3);
  box-shadow: 0 2px 5px rgba(93, 93, 255, 0.1);
}
[data-theme="light"] .project-preview {
  box-shadow: 0 10px 30px var(--shadow-color);
}
[data-theme="light"] .project-preview:hover {
  box-shadow: 0 20px 40px rgba(93, 93, 255, 0.25);
}
[data-theme="light"] .project-preview-overlay {
  background: linear-gradient(to top, rgba(240, 238, 255, 0.8), transparent);
}
[data-theme="light"] .project-preview-overlay h3 {
  color: var(--accent-color);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}
[data-theme="light"] .project-info h3 {
  margin: 0 0 15px;
  color: var(--accent-color);
  font-size: 1.5rem;
}
[data-theme="light"] .project-content {
  background-color: var(--card-bg);
  box-shadow: 0 8px 25px var(--shadow-color);
  border-left-color: var(--accent-color);
}
[data-theme="light"] .project-content p {
  color: var(--accent-color);
}
[data-theme="light"] .project-content h4 {
  color: var(--accent-color);
  border-bottom-color: rgba(93, 93, 255, 0.2);
}
[data-theme="light"] .project-gallery {
  background-color: var(--card-bg);
  box-shadow: 0 8px 25px var(--shadow-color);
}
[data-theme="light"] .gallery-item {
  border-color: rgba(0, 0, 0, 0.1);
}
[data-theme="light"] .gallery-item:hover {
  border-color: var(--accent-color);
  box-shadow: 0 10px 25px rgba(93, 93, 255, 0.2);
}
[data-theme="light"] .project-navigation a {
  background-color: var(--card-bg);
  color: #5d5dff;
  border-color: rgba(93, 93, 255, 0.3);
  box-shadow: 0 4px 10px var(--shadow-color);
}
[data-theme="light"] .project-navigation a:hover {
  background-color: #f0f4ff;
  color: #5d5dff;
  border-color: var(--accent-color);
  box-shadow: 0 6px 15px rgba(93, 93, 255, 0.2);
}

/* MODIFIÉ: Cible les nouvelles classes */
[data-theme="light"] .project-navigation .prev-project,
[data-theme="light"] .project-navigation .next-project {
  background-color: var(--card-bg);
  color: var(--accent-color);
  border-color: #c822ff;
  box-shadow: 0 4px 10px var(--shadow-color);
}
/* MODIFIÉ: Cible les nouvelles classes */
[data-theme="light"] .project-navigation .prev-project:hover,
[data-theme="light"] .project-navigation .next-project:hover {
  background-color: #f0f4ff;
  border-color: var(--accent-color);
  box-shadow: 0 6px 15px rgba(93, 93, 255, 0.2);
}

[data-theme="light"] .carousel-btn {
  background-color: #c822ff;
  color: white;
  border: 2px solid var(--accent-color);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}
[data-theme="light"] .carousel-btn:hover {
  background-color: #5d5dff;
  box-shadow: 0 4px 10px rgba(93, 93, 255, 0.2);
}

/* =========================
   COMPÉTENCES (Skills) - 
   ========================= */
.skills-section {
  padding: 0 20px;
  max-width: 1400px;
  margin-bottom: 200px;
}
.skills-categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
  gap: 100px;
  justify-items: center;
  align-items: stretch;
  width: 100%;
  margin: 0 auto;
  padding: 30px 0;
}
.skills-category {
  min-width: 320px;
  max-width: 600px;
  width: 100%;
  border-radius: 25px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 24px 32px 24px 32px;
  background-color: rgb(0 0 0 / 2%);
  box-shadow: 0 8px 20px var(--shadow-color);
  transition: all 0.3s ease;
  height: auto;
}
.skills-category:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 35px rgba(93, 93, 255, 0.3);
}
.category-title {
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  font-size: 1.6rem;
  margin-bottom: 50px;
  font-weight: 700;
  text-align: center;
  padding-bottom: 8px;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 2px;
  width: 100%;
  justify-items: center;
  align-items: center;
}
.skill {
  display: flex;
  flex-direction: column-reverse;
  align-items: center;
  max-width: 90px;
  width: 100%;
  margin: 0 auto;
  transition: all 0.3s ease;
}
.skill:hover {
  transform: translateY(-5px);
}
.skill-icon {
  width: 48px;
  height: 48px;
  padding: 4px;
  background-color: var(--skill-icon-bg);
  border-radius: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 5px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px var(--shadow-color);
  border: 2px solid transparent;
  border-image: linear-gradient(45deg, var(--accent-color), #c822ff) 1;
}
.skill img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  transition: transform 0.3s ease;
}
.skill p {
  font-size: 1.2rem;
  font-weight: bold;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin: 0;
  text-align: center;
}

/* Styles Compétences en thème clair */
[data-theme="light"] .skills-category {
  background-color: var(--card-bg);
  box-shadow: 0 8px 20px var(--shadow-color);
  border-top-color: var(--accent-color);
}
[data-theme="light"] .category-title {
  color: var(--accent-color);
} /* Correction: var(--accent-color) et non var (--accent-color) */
[data-theme="light"] .category-title::after {
  background: var(--accent-color);
}
[data-theme="light"] .skill-icon {
  background-color: var(--skill-icon-bg);
  border-color: var(--accent-color);
  box-shadow: 0 4px 10px var(--shadow-color);
}
[data-theme="light"] .skill:hover .skill-icon {
  background-color: #f0f4ff;
  box-shadow: 0 8px 15px rgba(93, 93, 255, 0.2);
}
[data-theme="light"] .skill p {
  color: var(--accent-color);
}

/* =========================
   CONTACT
   ========================= */
.contact-form {
  /* Formulaire de contact */
  background: rgb(0 0 0 / 0%);
  box-shadow: 0 10px 30px var(--shadow-color);
  border-radius: 5%;
  padding: 30px 40px;
  margin: 30px auto;
  max-width: 600px;
  transition: all 0.5s ease; /* Forme, padding, marges, largeur max, transition */
}
.contact-form:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(93, 93, 255, 0.3);
} /* Effet survol */
.contact-form form {
  display: flex;
  flex-direction: column;
  gap: 20px;
} /* Structure interne formulaire */
.form-group {
  display: flex;
  flex-direction: column;
  text-align: left;
} /* Groupe label + input */
.contact-form label {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 10px;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  display: flex;
  align-items: center;
  gap: 8px;
} /* Style des labels */
.contact-form label svg {
  width: 18px;
  height: 18px;
  fill: var(--accent-color);
} /* Icône dans le label */
.contact-form input,
.contact-form textarea {
  /* Champs de saisie */
  padding: 15px;
  border: 2px solid var(--secondary-bg);
  background: var(--input-bg);
  border-radius: 10px;
  color: var(--text-color); /* Padding, bordure, fond, forme, couleur texte */
  font-family: inherit;
  font-size: 16px;
  transition: all 0.3s ease;
  resize: none; /* Police, taille, transition, pas de redimensionnement textarea */
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(93, 93, 255, 0.3);
  background: var(--secondary-bg);
} /* Style au focus */
.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--text-color);
  opacity: 0.7;
} /* Style placeholder */

/* Carte Google Maps */
.contact-map {
  margin-bottom: 60px;
}
.map {
  border-radius: 2px;
  box-shadow: 0 10px 30px var(--shadow-color);
  width: 100%;
  max-width: 900px;
  height: 350px;
  margin: 0 auto;
  border: none;
  display: block;
} /* Style de la carte */

/* Section email */
.contact-email {
  padding: 20px;
  border-radius: 5%;
  max-width: 600px;
  margin: 50px auto !important; /* Style conteneur */
  box-shadow: 0 10px 25px var(--shadow-color);
  font-size: 1.3rem;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  transition: all 0.3s ease; /* Ombre, bordure gauche, texte, transition */
}
.contact-email:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(93, 93, 255, 0.2);
} /* Effet survol */
.contact-email a {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: bold;
  border-bottom: 2px dotted var(--accent-color);
  padding-bottom: 2px;
  transition: all 0.3s ease;
} /* Lien email */
.contact-email a:hover {
  color: var(--accent-color);
  border-bottom-style: solid;
} /* Effet survol lien */

/* Style de base pour le logo video dans la section social-media de la page contact */
#logo-video-dropdown {
  /* Ajoutez une transition pour un effet fluide */
  transition: transform 0.3s ease-in-out;
  /* Assurez-vous que la vidéo est affichée comme un bloc ou inline-block pour que transform fonctionne correctement */
  display: inline-block; /* ou block, selon votre layout */
  vertical-align: middle; /* Ajustez si nécessaire pour l'alignement */
  /* Définissez une largeur si ce n'est pas déjà fait, pour référence */
  width: 66px; /* Exemple, ajustez à la taille actuelle ou souhaitée */
  height: 66px; /* Exemple, ajustez à la taille actuelle ou souhaitée */
  border-radius: 50%; /* Arrondi pour correspondre aux autres icônes */
  border: 1px solid var(--accent-color); /* Bordure pour correspondre aux autres icônes */
  box-shadow: 0 4px 10px var(--shadow-color); /* Ombre pour correspondre aux autres icônes */
  margin: 30px; /* Espace autour de l'icône */
}

/* Effet d'agrandissement au survol */
#logo-video-dropdown:hover {
  /* Agrandit la vidéo de 10% (ajustez la valeur si besoin) */
  transform: scale(2.2);
}

/* Styles Contact en thème clair */
[data-theme="light"] .contact-form {
  background: var(--card-bg);
  box-shadow: 0 10px 30px var(--shadow-color);
  border-top-color: var(--accent-color);
}
[data-theme="light"] .contact-form label {
  color: var(--accent-color);
}
[data-theme="light"] .contact-form input,
[data-theme="light"] .contact-form textarea {
  border-color: var(--accent-color);
  background: #ffb3ff;
  color: #5d5dff;
} /* Champs de saisie */
[data-theme="light"] .contact-form input::placeholder,
[data-theme="light"] .contact-form textarea::placeholder {
  color: var(--accent-color);
  opacity: 0.7;
} /* Placeholder */
[data-theme="light"] .contact-form input:focus,
[data-theme="light"] .contact-form textarea:focus {
  border-color: #5d5dff;
  box-shadow: 0 0 0 3px rgba(93, 93, 255, 0.3);
}
[data-theme="light"] .map {
  filter: grayscale(20%) contrast(90%);
} /* Léger filtre sur la carte */
[data-theme="light"] .contact-email {
  background: var(--card-bg);
  box-shadow: 0 10px 25px var(--shadow-color);
  border-right: 5px solid var(--accent-color);
  border-left: 5px solid var(--accent-color);
  font-size: 1.3rem;
  color: var(--accent-color);
  transition: all 0.3s ease; /* Ombre, bordure gauche, texte, transition */
}
[data-theme="light"] .contact-email:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(93, 93, 255, 0.2);
} /* Effet survol */
[data-theme="light"] .contact-email a {
  color: #5d5dff;
  text-decoration: none;
  font-weight: bold;
  border-bottom: 2px dotted #5d5dff;
  padding-bottom: 2px;
  transition: all 0.3s ease;
} /* Lien email */
[data-theme="light"] .contact-email a:hover {
  color: #5d5dff;
  border-bottom-style: solid;
} /* Effet survol lien */
[data-theme="light"] .social-media a {
  background: var(--card-bg);
  box-shadow: 0 8px 20px var(--shadow-color);
}


/* =========================
   BLOG - NEWSLETTER
   ========================= */
.blog-newsletter {
  background: linear-gradient(
    135deg,
    rgba(93, 93, 255, 0.1),
    rgba(200, 34, 255, 0.1)
  );
  padding: 40px;
  border-radius: 12px;
  text-align: center;
  margin: 150px 100px 100px;
}

.blog-newsletter h3 {
  font-family: "Iceland", sans-serif;
  font-size: 2rem;
  margin-bottom: 15px;
  color: var(--accent-color);
}

.blog-newsletter p {
  max-width: 600px;
  margin: 0 auto 25px;
  opacity: 0.9;
}

.newsletter-form {
  display: flex;
  max-width: 500px;
  margin: 0 auto;
  gap: 10px;
}

.newsletter-form input {
  flex: 1;
  padding: 12px 15px;
  border: 1px solid rgba(93, 93, 255, 0.2);
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--text-color);
  font-family: "Lato", sans-serif;
}

.newsletter-form button {
  padding: 12px 25px;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.3s;
}

.newsletter-form button:hover {
  transform: translateY(-3px);
}

.newsletter-form input[type="email"] {
  transition: border-color 0.3s ease;
}

.newsletter-form input[type="email"].valid-email {
  border-color: #4CAF50;
  box-shadow: 0 0 0 1px rgba(76, 175, 80, 0.2);
}

.newsletter-form input[type="email"].invalid-email {
  border-color: #FF5252;
  box-shadow: 0 0 0 1px rgba(255, 82, 82, 0.2);
}

.newsletter-form button.submitting {
  background-color: #7b7b7b;
  cursor: wait;
}

.newsletter-form button.success {
  background-color: #4CAF50;
}

/* =========================
   FOOTER
   ========================= */
#footer {
  background-color: #1f203200; /* Thème sombre par défaut */
  padding: 20px 30px; /* Padding de base pour tous les côtés */
  margin-top: 0px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
  width: 100%;
  box-sizing: border-box;
  transition: padding-left 0.4s ease;
}

/* Décaler le contenu interne du footer lorsque le menu est ouvert (BASE) */
body.body-menu-open #footer {
  padding-left: 25%;
}

/* Texte copyright */
#footer p {
  margin: 0;
  flex-grow: 1;
  margin-left: auto;
  text-align: center;
  font-size: 1rem;
  background: linear-gradient(45deg, var(--accent-color), #c822ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
  transition: transform 0.3s;
  line-height: 1.7;
}

/* ... autres styles pour les icônes, liens, etc. ... */
#footer .github,
#footer div:not(.github) {
  display: inline-flex;
  align-items: center;
  gap: 0;
}

#footer a {
  transition: transform 0.3s ease;
  display: inline-block;
  margin-left: 0;
}

#footer a:hover {
  transform: scale(1.1);
}

#footer img {
  width: 32px;
  height: 32px;
}

/* Thème clair pour le FOOTER */
[data-theme="light"] #footer {
  background-color: white;
  border-top-color: var(
    --accent-color
  ); /* Utilise la var --accent-color du thème clair */
  /* Le padding: 20px 30px; est hérité de la règle #footer de base */
}

[data-theme="light"] #footer p {
  color: var(--accent-color); /* Utilise la var --accent-color du thème clair */
}

/* Cette règle combine le thème clair et l'état du menu ouvert */
[data-theme="light"] body.body-menu-open #footer {
  padding-left: 20%; /* Réaffirme le padding-left pour le thème clair quand le menu est ouvert */
}

/* =========================
   UTILITAIRES & EFFETS
   ========================= */
/* Animation AOS (Animate On Scroll) */
[data-aos] {
  opacity: 0;
  transition: all 0.8s ease;
} /* Caché par défaut */
[data-aos].aos-animate {
  opacity: 1;
} /* Visible quand animé */

/* =========================
   RESPONSIVE (Adaptation écrans)
   ========================= */

@media (min-width: 1400px) {
  /* Grands écrans */
  .project-detail {
    padding: 50px 80px 0px 80px;
  }
  .gallery-item {
    height: 180px; /* Hauteur plus grande sur grands écrans */
  }

  .profile-photo {
    width: 300px;
    height: 320px;
    border-radius: 0;
    object-fit: contain;
    border: 1px solid var(--border-color);
    box-shadow: 0 5px 100px #5d5dff;
  }
}

@media (max-width: 1200px) {
  /* Tablettes larges et ordinateurs moyens */
  .dropdown-menu {
    padding: 35px;
  }

  .intro-text .animated-paragraph {
    font-size: 0.9rem; /* Ajuster la taille de la police pour les tablettes */
  }
}

/* Tablettes et petits ordinateurs */
@media (max-width: 992px) {
  section#skills,
  #skills {
    scroll-margin-top: 100px;
    margin-top: 50px;
  }

  section#contact,
  #contact {
    scroll-margin-top: 100px;
    margin-top: 50px;
  }
  .dropdown-menu {
    padding: 35px;
    width: 33%;
  }

  .intro-text {
    padding: 0px 25px;
  }

  .intro-text .animated-paragraph {
    font-size: 1.1rem; /* Ajuster la taille de la police pour les tablettes */
  }

  .intro-text .profile-photo-container {
    width: 375px;
    max-width: 100%;
    height: 450px;
  }

  .intro-text .profile-photo {
    width: 500px;
    height: 350px;
  }

  .about-text-box {
    padding: 0px;
    margin: 50px;
  }

  .projects-grid {
    display: grid;
    grid-template-columns: repeat(
      auto-fill,
      minmax(350px, 1fr)
    ); /* Grille en rangée */
    gap: 100px;
    padding: 100px;
    max-width: 1400px;
    margin: 0 auto;
    /* supprime grid-template-rows et max-height */
  }

  .contact-form {
    padding: 15px 75px;
  }
}

@media (max-width: 576px) {
  /* Mobiles */

  /* Bloquer le scroll du body quand le menu est ouvert */
  body.body-menu-open {
    overflow: hidden; /* ✅ Empêche le scroll de la page */
    position: fixed; /* ✅ Fixe la position du body */
    width: 100%; /* ✅ Maintient la largeur */
  }

  /* Empêcher le décalage du main en mobile */
  body.body-menu-open main {
    padding-left: 0 !important; /* ✅ Annule le décalage */
  }

  /* Empêcher le décalage du footer en mobile */
  body.body-menu-open #footer {
    padding-left: 20px !important; /* ✅ Garde le padding normal */
  }

  /* Faire que le menu passe au-dessus avec un overlay plus visible */
  .menu-overlay.active {
    background-color: rgb(35, 36, 54); /* ✅ Overlay sombre visible */
    pointer-events: auto; /* ✅ Permet de fermer en cliquant sur l'overlay */
  }

  /* Ajuster la largeur du menu pour mobile */
  .dropdown-menu {
    width: 100%; /* ✅ Plus large que les 30% actuels pour une meilleure UX */
    z-index: 2000; /* ✅ S'assure qu'il passe au-dessus */
    top: 40px; /* Positionné sous le header compact */
    height: calc(95vh - 0px); /* Hauteur restante */
    padding: 20px; /* Padding réduit */
    position: fixed; /* ✅ Menu fixe */
    overflow: hidden; /* ✅ Pas de scroll interne au menu */
  }

  body {
    padding-top: 60px;
  } /* Ajuster le padding du body pour le header compact */

  section#projects,
  #projects {
    scroll-margin-top: 100px;
    margin-top: 100px;
  }

  section#skills,
  #skills {
    scroll-margin-top: 100px;
    margin-top: 100px;
  }

  section#contact,
  #contact {
    scroll-margin-top: 100px;
    margin-top: 50px;
    padding: 20px;
  }

  #loader-video {
    width: 100px;
    height: 100px;
  }

  /* Ajuster le Header Compact pour Mobile */
  header {
    height: 60px;
    padding: 0 15px;
  } /* Header compact */
  header h1 {
    font-size: 1rem;
    margin: 0 10px;
  } /* Titre plus petit */

  .header-logo img {
    margin: 15px 30px 5px 15px;
    border-radius: 50%;
    width: 40px;
    height: 40px;
  }

  .hamburger {
    font-size: 1rem;
  } /* Taille de l'icône */

  /* Ajuster le Header Compact pour Mobile */
  .compact-header {
    padding: 0 15px;
  } /* Header compact */
  .compact-header .header-left {
    gap: 8px;
  } /* Espacement entre logo et titre */
  .compact-header .page-title {
    font-size: 1rem;
  } /* Titre plus petit */
  .compact-header #logo-video {
    height: 30px;
  } /* Logo plus petit */
  .compact-header .language-switch img {
    width: 32px;
    height: 32px;
  } /* Icône langue plus petite */
  .menu-toggle {
    font-size: 1.8rem;
    padding: 8px;
  } /* Bouton menu plus petit */
  .theme-toggle button {
    width: 35px;
    height: 35px;
  } /* Bouton thème plus petit */
  .theme-toggle button svg {
    width: 18px;
    height: 18px;
  }

  /* Ajuste le titre bannière pour mobile */
  .title-banner {
    font-size: 1.9rem; /* Réduire la taille de la police (ajustez si besoin) */
    padding: 15px; /* Réduire le padding */
  }

  h3.title-banner {
    font-size: 1.7rem; /* Réduire la taille de la police */
    margin-bottom: 50px; /* Réduire la marge inférieure */
  }

  .intro-text {
    padding: 0px;
  }

  .intro-text .animated-title {
    font-size: 2rem; /* Réduire la taille de la police */
    padding: 30px;
  }

  .intro-text .animated-paragraph {
    font-size: 1.2rem; /* Réduire la taille de la police */
    margin-bottom: 10px;
    padding: 30px;
  }

  /* Taille de la photo de profil sur mobile */
  .intro-text .content-wrapper {
    flex-direction: column;
    gap: 30px;
    padding: 0px 30px;
    width: 100%;
    max-width: 400px; /* Largeur maximale réduite */
    margin: 0 auto; /* Centrage horizontal */
  }

  /*.intro-text .profile-photo-container { */
  /* width: 375px; /* Largeur maximale réduite */
  /* height: 400px; /* Hauteur maximale réduite */
  /* margin: 0 auto;} /* Centrage horizontal */

  .intro-text .profile-photo-container {
    width: 375px;
    max-width: 100%;
    height: 410px;
  }

  .intro-text .profile-photo {
    box-shadow: 0 5px 50px var(--accent-color); /* Ombre légèrement réduite */
    width: 340px;
    height: 300px;
  }

  .intro-text .btn-explore {
    padding: 8px 15px; /* Réduire le padding vertical et horizontal */
    font-size: 1.3rem; /* Réduire la taille de la police */
    min-width: auto; /* Permettre au bouton de prendre une largeur plus naturelle */
  }

  .btn-download-cv {
    padding: 8px 25px; /* Réduire le padding vertical et horizontal */
    font-size: 1.3rem; /* Réduire la taille de la police */
    margin: 60px 0px 0px 0px; /* Marge supérieure réduite */
  }

  .btn-download-cv i {
    margin-right: 8px; /* Réduire l'espace de l'icône si besoin */
  }

  /* Ajustements pour le carrousel en mode mobile */
  .carousel-container {
    padding-left: 10px; /* Un peu d'espace sur les côtés du conteneur */
    padding-right: 10px;
  }

  .carousel-item {
    min-width: 100%; /* Chaque item prend toute la largeur disponible */
    padding: 10px 0; /* Réduire le padding vertical, pas de padding horizontal car l'item fait 100% */
  }

  /* Ajuster la hauteur des images dans les .project-preview du carrousel si nécessaire */
  .carousel-item .project-preview {
    height: 150px; /* Ajustez cette hauteur selon vos besoins pour le carrousel mobile */
  }

  .carousel-item .project-preview img {
    /* S'assurer que l'image remplit bien le conteneur .project-preview */
    height: 100%;
    object-fit: contain;
  }

  .carousel-item .project-preview-overlay h3 {
    font-size: 1.2rem; /* Ajuster la taille du titre dans l'overlay du carrousel mobile */
    margin-bottom: 10px;
  }

  .carousel-item .project-preview .btn-view-project {
    padding: 8px 15px;
    font-size: 0.8rem;
  }

  .carousel-controls {
    margin: 15px 0; /* Réduire la marge des contrôles */
  }

  .carousel-btn {
    width: 35px; /* Boutons de contrôle plus petits */
    height: 35px;
    font-size: 14px;
  }

  /* Ajustements généraux du contenu pour mobile */
  .about-text-box {
    margin: 40px auto; /* ✅ Centrage automatique horizontal */
    padding: 10px; /* Optionnel: réduire le padding pour mobile */
    max-width: calc(
      100% - 80px
    ); /* Optionnel: éviter que la box touche les bords */
  }
  .about-text-box p {
    font-size: 1.3rem;
  }
  .project-info p {
    font-size: 1.3rem;
    text-align: center;
  } /* Texte projet plus petit */
  .project-content p {
    font-size: 1.3rem;
    text-align: center;
  } /* Texte projet plus petit */
  .project-detail .project-links a {
    font-size: 1.1rem;
  } /* Liens projet plus petits */
  .projects-grid {
    grid-template-columns: 1fr;
    padding: 20px;
  } /* Grille projets 1 colonne */
  .project-links a {
    font-size: 1.3rem;
  } /* Liens projet plus petits */
  .project-tech span {
    font-size: 1rem;
  } /* Taille police tech projet plus petite */
  .project-card img {
    height: 180px;
  } /* Image carte projet plus haute */
  .project-preview-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 0 10px;
  } /* Grille aperçu 1 colonne */
  .project-preview {
    height: 250px;
  } /* Aperçu moins haut */
  .project-preview .btn-view-project {
    padding: 8px 18px; /* Réduits le padding vertical et horizontal */
    font-size: 0.9rem; /* Réduits la taille de la police */
    min-width: auto; /* Permet au bouton de prendre une largeur plus naturelle si nécessaire */
  }
  .project-preview-overlay h3 {
    color: white;
    font-size: 1rem;
  } /* Titre overlay plus petit */
  .project-hero {
    height: 250px;
  } /* Image détail projet moins haute */
  .project-navigation {
    flex-wrap: nowrap;
    display: flex;
    justify-content: space-between;
    gap: 15px;
    align-items: center;
  } /* Navigation projet en colonne */
  .project-detail .project-links {
    flex-direction: column;
  } /* Liens détail projet en colonne */
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .skills-categories {
    grid-template-columns: 1fr;
    padding: 5px;
    margin-bottom: 50px;
    gap: 100px;
  }
  .skills-category {
    min-width: 0;
    width: 100%;
    padding: 10px 2vw;
    box-sizing: border-box;
    height: auto;
    flex-direction: column;
    align-items: stretch;
  }
  .skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    width: 100%;
    max-width: 100%;
  }
  .skill {
    flex: 1 1 40%;
    min-width: 110px;
    max-width: 48%;
    margin-bottom: 10px;
    box-sizing: border-box;
  }
  .skill-icon {
    width: 38px;
    height: 38px;
    padding: 4px;
  }
  .skill img {
    width: 22px;
    height: 22px;
  }
  .skill p {
    font-size: 1.1rem;
  }

  .contact-form {
    padding: 40px 40px;
  }

  .contact-form label {
    font-size: 1.2rem;
  } /* Taille police label plus petite */
  .contact-form button {
    font-size: 1.4rem;
    padding: 8px 12px;
  } /* Bouton formulaire plus petit */
  .contact-email {
    font-size: 1.2rem;
  } /* Taille police email plus petite */
  .contact-email a {
    font-size: 1.2rem;
  } /* Lien email plus petit */

  /* Ajustements dropdown pour mobile */
  .dropdown-nav ul {
    margin-bottom: 40px;
    margin-top: 60px;
  }

  .dropdown-nav a {
    font-size: 1.2rem;
  } /* Liens plus petits */

  /* Menu dropdown en mode thème clair */
  [data-theme="light"] .dropdown-menu {
    background-color: rgb(240, 238, 255) !important;
  }

  /* Si vous voulez aussi modifier l'overlay en mode clair */
  [data-theme="light"] .menu-overlay.active {
    background-color: rgba(240, 238, 255, 0.9) !important;
  }

  /* Pour harmoniser les éléments du menu en mode clair */
  [data-theme="light"] .dropdown-nav a {
    color: var(--accent-color); /* Utilise la couleur de texte du thème clair */
  }

  [data-theme="light"] .dropdown-nav a:hover {
    color: #5d5dff;
  }

  .menu-controls {
    width: 100px;
    gap: 15px;
    margin-left: 0px;
  } /* Contrôles dropdown */

  .gallery-item:hover {
    transform: translateY(
      -5px
    ); /* Supprime le scale(2.2) et garde/réduit le translateY */
    border-color: var(--accent-color); /* Garde la bordure colorée */
    box-shadow: 0 10px 25px rgba(93, 93, 255, 0.3); /* Garde l'ombre */
  }

  .scroll-to-top {
    bottom: 80px;
  }

  #footer {
    flex-direction: row-reverse; /* Garde l'ordre inversé même en mobile */
    justify-content: flex-start;
    gap: 0;
    padding: 15px 15px;
    margin-top: 0px;
  }

  #footer p {
    margin-right: auto;
    text-align: left;
    font-size: 0.9rem;
  }

  /* Container pour les icônes sociales */
  #footer .github,
  #footer div:not(.github) {
    margin: 0;
    gap: 0;
  }

  /* Supprime la règle qui centre les icônes */
  #footer div:first-of-type {
    display: inline-flex;
    justify-content: flex-start;
    width: auto;
    gap: 0;
  }

  #footer img {
    width: 28px; /* Légèrement plus petit sur mobile */
    height: 28px;
  }
}

/* =========================
   RESPONSIVE BLOG + ARTICLES 
   ========================= */

/* Ajustements pour les écrans moyens et petits */
@media (max-width: 768px) {
  .blog-main-container {
    padding-top: 80px;
  }

  .blog-hero {
    padding: 40px 0;
  }

  .blog-title {
    font-size: 2.8rem;
  }

  .filter-container {
    flex-direction: column;
    align-items: stretch;
  }

  .articles-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
  }

  .newsletter-form {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .blog-title {
    font-size: 2.3rem;
  }

  .blog-card-title {
    font-size: 1.3rem;
  }

  .blog-newsletter {
    padding: 30px 20px;
  }
}

/* Ajustements spécifiques pour les sections News en mobile */
@media (max-width: 576px) {
  section {
    padding: 0px;
    margin-top: 100px;
    margin-bottom: 0px;
  }

  .main-page-title {
    font-size: 1.3rem;
    color: var(--accent-color);
    font-weight: bold;
    padding: 20px;
  }

  .page-subtitle {
    font-size: 1.1rem; /* Taille de police responsive pour le sous-titre */
  }

  .news-teaser-section,
  .all-news-list {
    padding: 20px; /* Ajustez le padding selon vos besoins */
  }

  .news-card {
    box-shadow: 0 6px 25px #5d5dff;
  }
}

@media (max-width: 768px) {
  .news-grid {
    grid-template-columns: 1fr; /* Une colonne sur mobile */
  }
  .news-card-title {
    font-size: 1.2rem;
  }
  .article-title-main {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
  }
  .article-body {
    font-size: 1rem;
  }
}
