/* Construction de la charte graphique globale */

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

:root {
  --bg-primary: #0e0325;
  --btn-primary: #241f3a;
  --police-principale: "Century Gothic", Arial, sans-serif;
  --police-primary: #8bc5bb;
  --police-contour: #009688;

  /** CSS DARK THEME PRIMARY COLORS */
  --color-primary-100: #8bc5bb;
  --color-primary-200: #98cbc2;
  --color-primary-300: #a5d2ca;
  --color-primary-400: #b2d8d1;
  --color-primary-500: #bfdfd9;
  --color-primary-600: #cce5e0;
  /** CSS DARK THEME SURFACE COLORS */
  --color-surface-100: #0e0325;
  --color-surface-200: #241f3a;
  --color-surface-300: #3c364f;
  --color-surface-400: #555066;
  --color-surface-500: #6f6a7e;
  --color-surface-600: #8a8696;
  /** CSS DARK THEME MIXED SURFACE COLORS */
  --color-surface-mixed-100: #191932;
  --color-surface-mixed-200: #2f2e46;
  --color-surface-mixed-300: #46445b;
  --color-surface-mixed-400: #5e5c70;
  --color-surface-mixed-500: #777587;
  --color-surface-mixed-600: #918f9e;
}
* {
  box-sizing: border-box;
}
body,
main {
  margin: 0;
  padding: 0;
  width: 100%;
  box-sizing: border-box;
}

main {
  width: 100%;
}

/* Construction de la NavBar*/

header {
  height: 10vh;
  position: fixed;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  top: 0;
  z-index: 10000;
  padding: 10px;
  background-color: var(--color-surface-400);
}
nav {
  height: 100%;
  display: flex;
  align-items: center;
}
header > img {
  height: 8vh;
}
.menu-icon {
  display: block;
  font-size: 2rem;
  cursor: pointer;
}
.nav-links {
  display: none;
  flex-direction: column;
  width: 100%;
  position: absolute;
  top: 8vh;
  left: 0;
  background-color: var(--color-surface-400);
  text-align: center;
}
.nav-links a {
  text-decoration: none;
  color: var(--police_primary);
  padding: 1rem 0;
}
.nav-links > a:hover,
.nav-links > a:active {
  color: white;
  text-decoration: underline;
}
#menu-burger {
  display: none;
}
#menu-burger:checked + .menu-icon + .nav-links {
  display: flex;
}

/* Construction de la première section : HOME */
body {
  display: flex;
  background-color: var(--bg-primary);
  font-family: var(--police-principale);
  color: var(--police-primary);
}
.section_home {
  margin-top: 15vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
}
.banner_home {
  height: 85vh;
  width: 90vw;
  background: linear-gradient(to top, rgba(80, 68, 18, 0.6) 10%, transparent),
    url(../images/homeillustration.jpeg) left 50% bottom 25% / cover no-repeat
      border-box;
  color: white;
  font-size: 1.5em;
  text-align: center;
  text-shadow: rgb(49, 59, 23) 1px 0 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
#flex_value {
  display: flex;
  flex-direction: column;
  text-align: center;
  margin-top: 15vh;
}
.flex_value_item {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  margin: 4%;
  border-bottom: 1px dashed;
  border-left: 1px dashed;
  box-shadow: -1px 1px 2px #807c7c;
}

/*Construction de la section PORTFOLIO*/
.section_portfolio {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 5%;
  margin: 5%;
  margin-top: 15vh;
}
.section_portfolio img {
  height: 10vh;
  margin-bottom: 1rem;
}
#grid_portfolio {
  margin-top: 10%;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(4, 1fr);
  column-gap: 10%;
  row-gap: 10%;
  justify-content: space-around;
}
.grid_portfolio_project {
  display: flex;
  flex-direction: column;
  box-shadow: 2px 2px 2px 2px rgba(231, 243, 230, 0.1);
}
.grid_portfolio_project > a {
  text-decoration: none;
  color: var(--police_primary);
  font-weight: bold;
  text-align: center;
}
.grid_portfolio_project > a:hover,
.grid_portfolio_project > a:active {
  color: white;
  text-shadow: rgb(222, 207, 148) 1px 0 10px;
}
.bonapp {
  grid-column: 1;
  grid-row: 1;
}
.museohunt {
  grid-column: 2;
  grid-row: 1;
}
.sortir {
  grid-column: 1;
  grid-row: 2;
}
.avengers {
  grid-column: 2;
  grid-row: 2;
}

/*Construction de la section ARBRE DE COMPETENCES*/

.section_tree_skills {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.header_tree_skills {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  margin-bottom: 3vh;
}
.grid_tree_skills {
  width: 90%;
  margin-top: 3vh;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto repeat(10, 1fr);
  gap: 2%;
  position: relative;
}
.grid_tree_skills img {
  height: 6vh;
}
.grid_tree_skills > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.8rem;
  text-align: center;
  position: relative;
}
.grid_tree_logo {
  background: none;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin: auto;
}
.grid_tree_title {
  white-space: nowrap;
  overflow: hidden;
  text-align: center;
}
.grid_tree_seperator::after {
  content: "";
  position: absolute;
  top: 135%;
  left: -125%;
  width: 150%;
  height: 2px;
  background-color: #555066;
}

.workenv {
  grid-column: 1 / span 3;
  grid-row: 7;
  text-align: center;
}

.workmethod {
  grid-column: 1 / span 3;
  grid-row: 9;
  text-align: center;
}

.intellij {
  grid-column: 1;
  grid-row: 8;
}
.vsc {
  grid-column: 2;
  grid-row: 8;
}
.agile {
  grid-column: 3;
  grid-row: 8;
}
.figma {
  grid-column: 1;
  grid-row: 10;
}
.wp {
  grid-column: 2;
  grid-row: 10;
}
.uml {
  grid-column: 3;
  grid-row: 10;
}

.fe {
  grid-column: 1 / span 3;
  grid-row: 1;
  text-align: center;
}
.be {
  grid-column: 1 / span 3;
  grid-row: 3;
  text-align: center;
}

.htmlcss {
  grid-column: 1;
  grid-row: 2;
}
.vue {
  grid-column: 2;
  grid-row: 2;
}
.ang {
  grid-column: 3;
  grid-row: 2;
}
.java {
  grid-column: 1;
  grid-row: 4;
}
.node {
  grid-column: 2;
  grid-row: 4;
}
.symfony {
  grid-column: 3;
  grid-row: 4;
}

.server {
  grid-column: 1 / span 3;
  grid-row: 5;
  text-align: center;
}

.plsql {
  grid-column: 1;
  grid-row: 6;
}
.maria {
  grid-column: 2;
  grid-row: 6;
}
.postgre {
  grid-column: 3;
  grid-row: 6;
}

/* Construction de la section CONTACT*/
#section_contact {
  padding-top: 12vh;
}

section h1,
section h3 {
  padding-left: 2vw;
  margin-top: 12vh;
}
#banner_contact {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}
#banner_contact img {
  height: 80%;
}
.section_contact {
  width: 100%;
  height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 8vh;
}

.form_contact {
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 30vw;
}
.form_contact_input {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin-bottom: 3vh;
}
form {
  display: flex;
  flex-direction: column;
  max-width: 30vw;
  max-height: 20vh;
  justify-content: space-around;
}
button {
  text-decoration: none;
  background-color: #777587;
  border-radius: 5px;
  font-family: var(--police_primary);
  font-weight: bold;
  color: var(--police_primary);
  text-shadow: #555066;
  box-shadow: 1px 1px 1px 1px rgba(111, 174, 130, 0.1);
}
button:hover,
button:active {
  background-color: var(--police-contour);
  color: black;
  text-decoration: underline;
}
#dlcv {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  margin-top: 5vh;
}
/* Apprendre comment rendre le bouton de téléchargement de CV accessible pour le lecteur d'écran
tout en étant invisible à l'écran pour les utilisateurs */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
#dlcv img {
  height: 5vh;
}
.dl-link {
  text-decoration: none;
}
.dl-icon:hover {
  transform: scale(1.1); /* Agrandit l'icône au survol */
}

.dl-link:active {
  transform: scale(0.9); /* Réduit l'icône lorsqu'on clique dessus */
}

/*Mise en place de la fonction RESPONSIVE, avec un design Mobile First*/
@media (min-width: 768px) {
  /* Changements responsive pour la section Navbar*/
  img {
    height: 8vh;
  }
  nav {
    justify-content: space-around;
  }
  .menu-icon {
    display: none;
  }
  .nav-links {
    display: flex;
    flex-direction: row;
    position: static;
    width: auto;
  }
  .nav-links a {
    padding: 0 1rem;
  }
  /* Changements responsive pour la section HOME*/
  .banner_home {
    font-size: 2rem;
  }
  #flex_value {
    flex-direction: row;
  }
  .flex_value_item {
    flex: 1;
    box-sizing: border-box;
  }
  /* Changements responsive pour la section PORTFOLIO*/
  #grid_portfolio {
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(2, 1fr);
  }
  .section_portfolio img {
    height: 15vh;
    margin-bottom: 2rem;
  }
  .bonapp {
    grid-column: 1;
    grid-row: 1 / span2;
  }
  .museohunt {
    grid-column: 3;
    grid-row: 1;
  }
  .sortir {
    grid-column: 3;
    grid-row: 2;
  }
  .avengers {
    grid-column: 4 / span2;
    grid-row: 1 / span2;
  }
  /* Changements responsive pour la section ARBRE DE COMPETENCES*/
  .header_tree_skills {
    justify-content: flex-start;
  }
  .grid_tree_skills {
    grid-template-columns: repeat(7, 1fr);
    grid-template-rows: auto repeat(5, 1fr);
  }
  .grid_tree_skills img {
    height: 7vh;
  }
  .grid_tree_skills > div {
    font-size: 1rem;
  }
  .grid_tree_skills::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%; /* pour centrer sur l'axe vertical*/
    height: calc(100% / 5 * 3); /* calculer la hauteur, s'arrêter au 4e rang */
    width: 2px; /* épaisseur du trait */
    background-color: #555066;
    transform: translateX(-50%); /* corriger un éventuel offset */
  }

  .grid_tree_skills::after {
    content: "";
    position: absolute;
    top: calc(100% / 5 * 1.5); /*  calculer le début de la ligne */
    left: calc(100% / 5); /*calculer sur quelle colonne la positionner */
    width: calc(100% / 5 * 3); /* indique la longueur de la ligne */
    height: 2px;
    background-color: #555066;
  }
  .grid_tree_seperator::after {
    display: none;
  }
  .workenv {
    grid-column-start: 1;
    grid-row: 1;
  }

  .workmethod {
    grid-column: 5 / span 3;
    grid-row: 1;
  }

  .intellij {
    grid-column: 1;
    grid-row: 2;
  }
  .vsc {
    grid-column: 2;
    grid-row: 2;
  }
  .agile {
    grid-column: 3;
    grid-row: 2;
  }
  .figma {
    grid-column: 5;
    grid-row: 2;
  }
  .wp {
    grid-column: 6;
    grid-row: 2;
  }
  .uml {
    grid-column: 7;
    grid-row: 2;
  }

  .fe {
    grid-column: 1 / span 3;
    grid-row: 3;
  }
  .be {
    grid-column: 5 / span 3;
    grid-row: 3;
  }

  .htmlcss {
    grid-column: 1;
    grid-row: 4;
  }
  .vue {
    grid-column: 2;
    grid-row: 4;
  }
  .ang {
    grid-column: 3;
    grid-row: 4;
  }
  .java {
    grid-column: 5;
    grid-row: 4;
  }
  .node {
    grid-column: 6;
    grid-row: 4;
  }
  .symfony {
    grid-column: 7;
    grid-row: 4;
  }

  .server {
    grid-column: 4;
    grid-row: 5;
    text-align: center;
  }

  .plsql {
    grid-column: 3;
    grid-row: 6;
  }
  .maria {
    grid-column: 4;
    grid-row: 6;
  }
  .postgre {
    grid-column: 5;
    grid-row: 6;
  }
  /* section CONTACT changement Responsive pour desktop*/
  section h1,
  section h3 {
    padding-left: 2vw;
    margin-top: 12vh;
  }
  .section_contact {
    width: 100vw;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: auto;
  }
  #banner_contact {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  #banner_contact img {
    height: 100%;
  }
  form {
    max-width: 70vw;
  }
  .form_contact {
    max-width: 80vw;
    flex-direction: row;
    justify-content: space-between;
  }

  .form_contact_input {
    flex: 1;
    margin-bottom: 0;
    margin-right: 1rem;
  }

  .form_contact_input:last-child {
    margin-right: 0;
  }

  .form_contact_input label,
  .form_contact_input input {
    width: 100%;
  }

  button {
    width: 100%;
    margin-top: 2rem;
  }

  #dlcv {
    margin-top: 6vh;
  }
}
