/* ===== Déclaration de la police Avara ===== */
@font-face {
  font-family: 'Avara';
  src: url('fonts/Avara-BoldItalic.woff2') format('woff2');
  font-style: italic;
  font-weight: bold;
}

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

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

/* Fond de la page */
body {
  background-color: #fffff8;
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
  color: black;
  height: 100vh;
}

.separator {
  border: none;
  height: 3px;
  background-image: repeating-linear-gradient(
    to right,
    black 0 10px,
    transparent 10px 20px
  );
  margin: 40px 0;
}

/* Container pour les trois colonnes */
.container {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* Sidebar gauche */
.sidebar-left {
  width: 25%;
  background-color: #fffff8;
  padding: 20px;
  height: 100vh;
  overflow-y: auto;
}

.sidebar-left h1 {
  font-family: 'Avara', serif;
  font-weight: bold;
  font-style: italic;
  font-size: 3em;
  margin-top: 10px;
  margin-bottom: 30px;
  color: black;
}

.sidebar-left .portrait {
  width: 220px;
  height: auto;
  border-radius: 50%;
  margin-bottom: 15px;
}

.sidebar-left .intro {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
  margin-bottom: 15px;
}



.sidebar-left .contact p {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
  line-height: 1.5;
}

.sidebar-left .contact a {
  color: #111;
  text-decoration: none;
}

/* Colonne centrale */
.content {
  position: relative;
  width: 50%;
  background-color: #fffff8;
  padding: 20px;
  height: 100vh;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}



.content::-webkit-scrollbar {
  display: none;
}

.content h1 {
  font-family: 'Avara', serif;
  font-weight: bold;
  font-style: italic;
  font-size: 3em;
  margin-top: 10px;
  margin-bottom: 30px;
  color:black;
}

/* Zone projet */
.project {
  margin-bottom: 40px;
}

/* Grille d’images 1/2/2 */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
}

/* La première image occupe toute la largeur */
.grid .img-large {
  grid-column: 1 / -1;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Les autres images */
.grid img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

/* grille deux image cote a cote */
.grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.grid-two img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* grille image seule */
.grid-single {
  display: block;
}

.grid-single img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

.grid-3-then-2 {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 colonnes par défaut */
  gap: 10px; /* espace entre les images */
}

.grid-3-then-2 img {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
}

.grid-3-then-2 img:nth-child(n+4) {
  grid-column: span 1;
}

.grid-3-then-2 img:nth-child(4),
.grid-3-then-2 img:nth-child(5) {
  grid-column: span 1; /* leur dit "prends seulement une colonne" */
}

.img-large {
  grid-column: span 2;
}

/* Texte en deux colonnes */
.project-text {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 20px;
  margin-top: 20px;
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
  color: black;
}

.project-text .col-left {
  color: #444;
}

.project-text .col-right {
  line-height: 1.5;
}

.back-to-top {
  display: none;
  position: sticky;
  bottom: 20px;
  left: 0;
  margin-left: 20px;
  font-size: 2.5em;
  text-decoration: none;
  color: #000;
  background: transparent;
  padding: 2px 4px;
  border-radius: 0;
  z-index: 10;
}

.back-to-top:hover {
  background: none;
}

html {
  scroll-behavior: smooth;
}

/* Sidebar droite */
.sidebar-right {
  width: 25%;
  background-color: #fffff8;
  padding: 20px;
  height: 100vh;
  overflow-y: auto;
}

.sidebar-right h1 {
  font-family: 'Avara', serif;
  font-weight: bold;
  font-style: italic;
  font-size: 3em;
  margin-top: 10px;
  margin-bottom: 30px;
  color: black;
}



/* Structure CV */
.cv {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.cv-row {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 10px;
  align-items: start;
}

.cv-date {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
  color: black;
}

.cv-desc {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
}

/* Paragraphes (texte de corps) */
p {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82em;
  margin-bottom: 30px;
  line-height: 1.5;
}

/* ===== Responsive simple ===== */
@media (max-width: 900px) {
  .container {
    flex-direction: column;
  }
  .sidebar-left,
  .content,
  .sidebar-right {
    width: 100%;
    max-height: none;
  }
}

/* Tooltip carré avec image */
#hover-tooltip {
  position: fixed;
  pointer-events: none;
  display: none;
  z-index: 1000;
  max-width: 300px;
  height: auto;
  background: none;
border: none;
}

#hover-tooltip img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}


/* ===== Version mobile ===== */
.mobile-version {
  display: none;
  background-color: #fffff8;
  color: black;
  padding: 30px 20px;
  text-align: left;
  font-family: 'Overpass Mono', monospace;
}

.mobile-logo {
  width: 60px;
  height: auto;
  margin-bottom: 10px;
}

.mobile-name {
  font-family: 'Avara', serif;
  font-weight: bold;
  font-style: italic;
  font-size: 2em;
  margin-bottom: 15px;
}

.mobile-intro {
  font-size: 0.9em;
  margin-bottom: 25px;
  line-height: 1.5;
}

.mobile-contact p {
  margin-bottom: 8px;
}

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

.mobile-projects {
  margin-top: 40px;
}

.mobile-projects h2 {
  font-family: 'Avara', serif;
  font-weight: bold;
  font-style: italic;
  font-size: 1.8em;
  margin-bottom: 20px;
}

.mobile-projects img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 15px;
  display: block;
}

/* Cacher la version desktop sur mobile */
@media (max-width: 768px) {
  .container, .sidebar-left, .content, .sidebar-right {
    display: none !important;
  }

  .mobile-version {
    display: block;
  }
/* ===== Version mobile : affichage des projets ===== */
@media (max-width: 768px) {
  /* On masque tout sauf les images */
  .project-text,
  .project h1,
  .project h2,
  .project p {
    display: none !important;
  }

  /* On rend les images bien visibles et fluides */
  .grid,
  .grid-two,
  .grid-single {
    display: grid;
    grid-template-columns: 1fr; /* une seule colonne */
    gap: 10px;
  }

  /* Grille d’images 1/2/2 */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
}

/* La première image occupe toute la largeur */
.grid .img-large {
  grid-column: 1 / -1;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Les autres images */
.grid img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

/* grid-3-then-1 */
.grid-3-then-1 {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 colonnes pour la première ligne */
  gap: 10px;
}

/* L’image de la deuxième ligne doit prendre toute la largeur */
.grid-3-then-1 .single-wide {
  grid-column: 1 / 4; /* s’étend sur les 3 colonnes */
}

/* grille deux image cote a cote */
.grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.grid-two img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* grille image seule */
.grid-single {
  display: block;
}

.grid-single img {
  width: 100%;
  height: auto;
  object-fit: cover;
}



  /* On enlève les marges trop grandes autour */
  .project {
    margin-bottom: 20px;
    padding: 0;
  }

  /* Si tu veux garder ton fond beige */
  body {
    background-color: #fffff8;
  }
}


}

