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

body {
  font-family: "Poppins", sans-serif;
  margin: 0 auto;
  max-width: 100%;
}

:root {
  --bg-color: #040043;
  --second-bg-color: #0073ff;
  --third-bg-color: #7bc9ff;
}

/* ——————————————————————————————————————————————————*/
/* ScrollBar*/
/* ——————————————————————————————————————————————————*/

::-webkit-scrollbar-thumb {
  background-color: #8e8e8e;
  border-radius: 20px;
}

::-webkit-scrollbar-track {
  border-color: white;
  border-radius: 20px;
}

::-webkit-scrollbar {
  width: 8px;
}

/* ——————————————————————————————————————————————————*/
/* ScrollHautBtn*/
/* ——————————————————————————————————————————————————*/

#scrollHautBtn {
  display: none;
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 99;
  font-size: 25px;
  padding: 10px;
  border: none;
  border-radius: 50%;
  background-color: rgba(180, 180, 180, 0.6);
  color: #fff;
  cursor: pointer;
}

/* ——————————————————————————————————————————————————*/
/* NavBar*/
/* ——————————————————————————————————————————————————*/

.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: rgba(123, 201, 255, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  transition: top 0.7s;
  z-index: 1;
}

.navbar.hidden {
  top: -100px; /* Cache la barre de navigation hors de l'écran */
}

.navbar h1 {
  font-size: 30px;
  margin: 0;
}

.navbar a {
  text-decoration: none;
  color: black;
}

.navbar span {
  color: var(--second-bg-color);
}

.nav-list {
  display: flex;
  gap: 15px;
  list-style: none;
}

.nav-list li a {
  position: relative;
  font-size: 18px;
  transition: color 0.3s;
}

.nav-list li a::after {
  content: "";
  background: var(--second-bg-color);
  width: 0;
  height: 1.5px;
  position: absolute;
  left: 0;
  bottom: -4px;
  transform: scaleX(0);
  transform-origin: center bottom;
  transition: transform 0.3s;
}

.nav-list li a:hover::after {
  width: 100%;
  transform: scaleX(1);
}

/* Styles pour le menu burger */
.menu-burger {
  display: none;
}

.menu-toggle {
  position: fixed;
  top: 0;
  right: 0;
  background-color: rgba(123, 201, 255, 0.8);
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.menu-toggle.active {
  display: flex;
  font-size: 1.5rem;
}

.menu-toggle .close-icon {
  position: absolute;
  top: 15px;
  right: 15px;
  font-size: 30px;
  cursor: pointer;
}

.menu-toggle .mobile-menu {
  list-style: none;
  padding: 0;
}

.menu-toggle .mobile-menu li {
  margin-bottom: 15px;
}

.menu-toggle .mobile-menu li a {
  color: black;
  font-size: 2rem;
  text-decoration: none;
  transition: color 0.3s;
}

.menu-toggle .mobile-menu li a:hover {
  color: var(--second-bg-color);
}

/* ——————————————————————————————————————————————————*/
/* Accueil*/
/* ——————————————————————————————————————————————————*/

.accueil {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
  text-align: center;
}

.accueil-texte {
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  max-width: 100%;
  padding: 3rem 1rem;
  /* flex-wrap: wrap; */
  align-items: center;
}

.titre {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.titre h1 {
  min-height: 3em;
  white-space: nowrap;
}

.accueil-texte .contenu-texte {
  flex: 1;
  max-width: 50%;
  text-align: center;
}

#nom {
  display: inline-block;
  width: auto;
  text-align: left;
  color: (--second-bg-color);
}

.accueil-texte .contenu-image {
  flex: 1;
  max-width: 20%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.accueil-texte h5 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.accueil-texte h1 {
  font-size: 3rem;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.accueil-texte #nom {
  color: var(--second-bg-color);
}

.accueil-texte i {
  font-style: italic;
  font-size: 1rem;
  margin-top: 1rem;
}

.contenu-image img {
  max-width: 100%;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* ——————————————————————————————————————————————————*/
/* A propos*/
/* ——————————————————————————————————————————————————*/

#a-propos-section {
  padding: 4rem 2rem;
  background-color: #f0f0f5;
}

.section-a-propos {
  /* max-width: 1200px; */
  margin: 0 auto;
  padding: 2rem;
  background-color: #ffffff;
  border-radius: 15px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  position: relative;
}

.section-titre {
  font-size: 3rem;
  font-weight: bold;
  text-align: center;
  margin-bottom: 2rem;
  color: #333333;
  position: relative;
  z-index: 2;
}

.section-titre::after {
  content: "";
  display: block;
  width: 60px;
  height: 5px;
  background-color: var(--third-bg-color);
  margin: 0.5rem auto 0;
  border-radius: 2.5px;
}

.contenu-a-propos {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  position: relative;
  z-index: 2;
}

.slider-photos {
  flex: 1;
  max-width: 20%;
}

.slider {
  width: 100%;
  height: auto;
  overflow: hidden;
  display: flex;
}

.slider .slide {
  min-width: 100%;
  position: relative;
  animation: slider 10s infinite ease-in-out;
}

@keyframes slider {
  0%,
  11.1% {
    transform: translateX(0);
  }

  22.2%,
  33.3% {
    transform: translateX(-100%);
  }

  44.4%,
  55.5% {
    transform: translateX(-200%);
  }

  66.6%,
  77.7% {
    transform: translateX(-300%);
  }

  88.8%,
  100% {
    transform: translateX(-400%);
  }
}

.slider img {
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.texte-presentation {
  flex: 1;
  max-width: 50%;
  text-align: left;
}

.texte-presentation h3 {
  font-size: 1.25rem;
  font-weight: normal;
  line-height: 1.6;
  color: #555555;
}

/* Responsive Design */
@media (max-width: 768px) {
  .contenu-a-propos {
    flex-direction: column;
  }

  .slider-photos,
  .texte-presentation {
    max-width: 100%;
  }

  .texte-presentation {
    order: 1;
  }

  .slider-photos {
    order: 2;
  }
}

/* Background Decoration */
.section-a-propos::before {
  content: "";
  position: absolute;
  top: -50px;
  left: -50px;
  width: 200px;
  height: 200px;
  background: var(--third-bg-color);
  border-radius: 50%;
  z-index: 1;
}

.section-a-propos::after {
  content: "";
  position: absolute;
  bottom: -50px;
  right: -50px;
  width: 200px;
  height: 200px;
  background: var(--third-bg-color);
  border-radius: 50%;
  z-index: 1;
}

/* ——————————————————————————————————————————————————*/
/* Projets*/
/* ——————————————————————————————————————————————————*/

.conteneur-projets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: center;
  gap: 2.5rem;
}

.case-projet {
  /* background-color: #8e8e8e; */
  height: 350px;
  border-radius: 3rem;
  cursor: pointer;
  transition: 0.3s ease;
  overflow-y: scroll;
  /* color: transparent; */
}

.case-projet:hover {
  background-color: var(--third-bg-color);
  color: white;
  transform: scale(1.03);
}

.case-projet .projet-infobox {
  display: flex;
  flex-direction: column;
  text-align: left;
  max-height: 200px;
  justify-content: center;
  align-items: center;
  padding: 4em;
}

.projet-infobox h4 {
  font-size: 2rem;
  font-weight: 500;
  margin-bottom: 1rem;
}

.projet-infobox p {
  font-size: 1rem;
  font-weight: 400;
  max-height: 100px;
  margin: auto;
}

/* ——————————————————————————————————————————————————*/
/* Compétences*/
/* ——————————————————————————————————————————————————*/

/* .contenu-competences {
  background-color: var(--third-bg-color);
  color: black;
  border-radius: 1rem;
  padding: 2rem;
  width: 70%;
  margin: auto;
  margin-top: 2rem;
}

.contenu-competences .lignes {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  flex-wrap: wrap;
  gap: 1.8rem;
}

.contenu-competences .barres {
  margin-bottom: 15px;
  padding: 10px;
  border-radius: 1rem;
  background: var(--second-bg-color);
  transition: 0.3 ease;
  cursor: pointer;
  box-shadow: 0 4px 10px var(--bg-color);
  display: flex;
  align-items: center;
  justify-content: center;
}

.contenu-competences .barres:hover {
  /* box-shadow: 0 4px 10px var(--bg-color); */
/*transform: scale(1.03);*/
/*}*/
/*
.contenu-competences .barres .info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
}

.contenu-competences .barres .info span {
  font-size: 2rem;
  font-weight: 500;
  justify-content: center;
} */

.section-titre {
  color: var(--second-bg-color);
  font-size: 30px;
}

section {
  min-height: 100vh;
  padding: 2rem;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

/* ——————————————————————————————————————————————————*/
/* Compétences*/
/* ——————————————————————————————————————————————————*/

section.competence {
  padding: 2rem;
  background-color: #ffffff;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
}

.section-titre {
  text-align: center;
  font-size: 2em;
  margin-bottom: 20px;
  color: var(--second-bg-color);
}

.competence .valide {
  display: flex;
  justify-content: baseline;
  align-items: center;
  gap: 0.5em;
  margin-top: 1rem;
}

summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f7f7f7;
  padding: 10px 15px;
  cursor: pointer;
  list-style: none;
  position: relative;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
}

summary::-webkit-details-marker {
  display: none;
}

summary h1 {
  font-size: 1.2em;
  margin: 0;
}

summary ion-icon {
  font-size: 1.2em;
  position: absolute;
  right: 20px;
  transition: transform 0.3s;
}

details[open] summary ion-icon {
  transform: rotate(180deg);
}

.cardBody {
  padding: 15px;
  background-color: #fff;
  display: none;
  border-left: #ddd 1px solid;
  border-right: #ddd 1px solid;
  border-bottom: #ddd 1px solid;
  border-bottom-right-radius: 10px;
  border-bottom-left-radius: 10px;
}

details {
  width: 100%;
}

details[open] .cardBody {
  display: block;
}

.cardBody h3 {
  font-size: 1em;
  margin-bottom: 10px;
}

.cardBody ul {
  list-style: disc;
  padding-left: 20px;
}

.logo_valide {
  max-width: 1.5em;
}

.tabs {
  display: flex;
  justify-content: space-around;
  /* border-bottom: 2px solid #e5e5e5; */
  flex-direction: row;
  flex-wrap: wrap;
}

.tabs__radio {
  display: none;
}

.tabs__label {
  padding: 15px 20px;
  font-size: 1.2em;
  font-weight: bold;
  color: #333;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s;
  border: 1px solid #ddd;
  border-bottom: none;
  border-radius: 8px 8px 0 0;
  background-color: #f7f7f7;
  flex: 1;
  text-align: center;
  height: fit-content;
}

.tabs__label:hover {
  background-color: #eaeaea;
}

.tabs__radio:checked + .tabs__label {
  background-color: #0073ff;
  color: #fff;
  border-bottom: 2px solid #0058c4;
  margin-bottom: -2px;
}

.tabs__content {
  order: 1;
  flex-grow: 1;
  max-height: 0;
  overflow-y: scroll;
  overflow-x: hidden;
  opacity: 0;
  padding: 0 20px;
  border: 1px solid #ddd;
  border-top: none;
  transition: top 1s ease, opacity 0.5s ease, padding 0.5s ease;
  width: 100%;
}

.tabs__radio:checked + .tabs__label + .tabs__content {
  max-height: fit-content;
  opacity: 1;
  padding: 20px;
  display: initial;
}

.desciption-competence {
  margin-left: 0.5rem;
  font-size: 1rem;
  font-weight: normal;
}

/* Styles pour les années et contenu */
.Annee {
  margin: 2rem auto;
  display: flex;
  flex-direction: row;
  gap: 2em;
  /* justify-content: space-around; */
}

.AnneeContent h3 {
  font-size: 1.5em;
  margin-bottom: 10px;
}

.AnneeContent h4 {
  font-size: 1.2em;
  margin-bottom: 10px;
  margin-left: 0.7rem;
}

.AnneeContent ul {
  list-style: disc;
  padding-left: 20px;
  margin-left: 0.7rem;
}

.valide {
  color: #4fc123;
  font-weight: bold;
}

.titleCardProjet {
  margin: 2rem auto;
  font-size: 1.5em;
  text-align: center;
}

.competenceContent {
  display: flex;
  gap: 20px;
}

.projectCard {
  flex: 1 1 calc(50% - 20px);
  border: 1px solid #ddd;
  border-radius: 5px;
  overflow: hidden;
  transition: transform 0.3s;
}

.projectCard:hover {
  transform: scale(1.02);
}

.cardText {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f7f7f7;
  padding: 10px 15px;
}

.cardText h1 {
  font-size: 1.2em;
  margin: 0;
}

.projectCard .cardBody {
  min-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out, padding 0.3s ease-out;
  transition: min-height 0.3s ease-out, padding 0.3s ease-out;
}

.projectCard.expanded .cardBody {
  height: fit-content;
  min-height: 150px;
  padding: 15px;
}

.cardBody h3 {
  font-size: 1em;
  margin-bottom: 10px;
}

.cardBody ul {
  list-style: disc;
  padding-left: 20px;
}

.btnMenuCard {
  background: none;
  border: none;
  cursor: pointer;
}

.btnMenuCard ion-icon {
  width: 20px;
  height: 20px;
}

@media screen and (max-width: 768px) {
  .navbar {
    padding: 10px; /* Réduire l'espace autour du texte de la navbar */
  }

  .accueil-texte {
    flex-direction: column; /* Ajuster le texte d'accueil en colonne */
    align-items: center;
    text-align: center;
    justify-content: space-around;
  }

  .contenu-image {
    margin-left: 0; /* Centrer l'image sur les petits écrans */
  }

  .sliderTest {
    max-width: 100%; /* Faire en sorte que le slider prenne la largeur complète */
    margin: 50px auto; /* Ajuster la marge du slider */
  }

  .conteneur-projets {
    grid-template-columns: 1fr; /* Afficher les projets en une colonne sur mobile */
  }

  .contenu-competences {
    width: 90%; /* Ajuster la largeur des compétences sur mobile */
  }

  .Annee {
    flex-direction: column;
  }

  .contact-info,
  .contact-form {
    max-width: 100%;
  }

  .contact-container {
    flex-direction: column;
  }

  .accueil-texte .contenu-texte,
  .accueil-texte .contenu-image {
    max-width: 100%;
    margin: 1rem 0;
  }

  .nav-list #cat {
    display: none;
  }

  .menu-burger {
    display: flex;
    font-size: 1.5rem;
  }
}

@media screen and (max-width: 576px) {
  .accueil-texte h1 {
    font-size: 1.8rem;
  }

  .conteneur-projets {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .case-projet {
    height: auto;
  }
}

@media (max-width: 1200px) {
  .conteneur-projets {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .skill-box {
    flex-direction: column;
    align-items: flex-start;
  }

  .skill-box .skill-title {
    margin-right: 0;
    margin-bottom: 0.5rem;
  }

  .skill-box .skill-bar {
    width: 100%;
  }

  .accueil {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .conteneur-projets {
    grid-template-columns: 1fr;
  }

  .accueil-texte {
    flex-direction: column;
    text-align: center;
  }

  .accueil-texte h1 {
    font-size: 2.3rem;
  }

  .accueil-texte .contenu-texte,
  .accueil-texte .contenu-image {
    max-width: 70%;
  }

  .navbar {
    padding: 10px;
  }

  .menu-toggle .mobile-menu {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  .menu-toggle .mobile-menu li {
    margin-bottom: 15px;
  }

  .competenceContent {
    flex-wrap: wrap;
  }

  .contenu-competences {
    width: 90%;
  }

  .accueil-texte .contenu-image {
    max-width: 50%;
  }

  .tabs__label {
    width: 100%;
  }

  .projectCard {
    flex: 1 1 100%;
  }

  .annee {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .navbar h1 {
    font-size: 24px;
  }

  .accueil-texte h1 {
    font-size: 1.7rem;
  }

  .accueil-texte h5 {
    font-size: 1.2rem;
  }

  .accueil-texte i {
    font-size: 0.9rem;
  }

  .contenu-competences {
    padding: 1rem;
  }

  .accueil-texte .contenu-image {
    max-width: 65%;
  }
}

/* ——————————————————————————————————————————————————*/
/* Contact*/
/* ——————————————————————————————————————————————————*/

.contact {
  padding: 2rem;
  background-color: #f9f9f9;
}

.contact h1 {
  text-align: center;
  margin-bottom: 2rem;
  color: var(--second-bg-color);
}

.contact-form form {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.contact-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
}

.contact-info,
.contact-form {
  flex: 1;
  margin: 1rem;
  padding: 2rem;
  background-color: #fff;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
}

.contact-info h2,
.contact-form h2 {
  margin-bottom: 1rem;
  color: var(--second-bg-color);
}

.contact-info p,
.contact-form label {
  margin-bottom: 1rem;
  font-size: 1rem;
}

.contact-info p a {
  color: var(--second-bg-color);
  text-decoration: none;
}

.contact-info a:hover {
  text-decoration: underline;
}

.btn-download {
  display: inline-block;
  padding: 0.5rem 1rem;
  color: #fff;
  background-color: var(--second-bg-color);
  border-radius: 5px;
  text-decoration: none;
  transition: transform 0.3s;
}

.btn-download:hover {
  transform: scale(1.05);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 0.75rem;
  margin-bottom: 1rem;
  border: 1px solid #ddd;
  border-radius: 5px;
}

.contact-form textarea {
  resize: both;
  min-width: 100%;
  max-width: 100%;
  min-height: 200px;
}

.contact-form button {
  padding: 0.75rem 2rem;
  background-color: var(--second-bg-color);
  color: #fff;
  border: none;
  border-radius: 5px;
  background-color: var(--second-bg-color);
  color: white;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.3s;
}

.contact-form button:hover {
  transform: scale(1.08);
}

/* ——————————————————————————————————————————————————*/
/* Footer*/
/* ——————————————————————————————————————————————————*/

footer {
  padding: 1rem 0;
  background-color: var(--second-bg-color);
  color: #fff;
  text-align: center;
  font-size: 0.9rem;
}

footer p {
  margin: 0;
}

footer .social-icons {
  margin-top: 1rem;
}

footer .social-icons a {
  color: #fff;
  margin: 0 0.5rem;
  font-size: 1.5rem;
  transition: color 0.3s;
}

footer .social-icons a:hover {
  color: var(--third-bg-color);
}
