/* ---------------------RESET ECRAN--------------------- */ 
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 100%; 
  scroll-behavior: smooth;
}

body {
  font-family: "Georgia", "Times New Roman", serif;
  line-height: 1.8;
  color: #111;
  background: #fff;
}

/* ---------------------MISE EN PAGE GEN--------------------- */
.wrapper {
  width: 90%;
  max-width: 80rem; /* 1280px */
  margin: 0 auto;
  padding: 2rem 0;
}

/* ---------------------HEADER---------------------*/
header {
  background: #0E2841;
  color: #FD8916;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 0.3rem 0.6rem rgba(0,0,0,0.3);
  transition: transform 0.3s ease;
}

header .wrapper {
  display: flex;
  align-items: center;
  justify-content: center; 
  flex-direction: column; 
  gap: 1.85rem;
}

header h1 {
  font-size: 1.7rem;
  font-family: "Baskerville", serif;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

header .wrapper_2 {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.05rem; 
}

.quelleedi {
  font-size: 0.9rem;
  font-weight: 400;
  color: #FD8916;
  letter-spacing: 0.03em;
  line-height: 1.2;
}


nav ul {
  list-style: none;
  display: flex;
  flex-direction: row; /* mobile: vertical */
  gap: 2.5rem;
  justify-content: center;
}

nav a {
  color: #FD8916;
  text-decoration: none;
  font-weight: 600;
  transition: opacity 0.2s ease;
}

nav a:hover {
  opacity: 0.7;
}

/* ---------------------INTRO ARTICLE--------------------- */
article .intro {
  font-size: clamp(1.1rem, 1.5vw, 1.3rem);
  font-style: italic;
  color: #555;
  margin: 1.5rem 0 3rem 0;
  border-left: 4px solid #111;
  padding-left: 1rem;
  line-height: 1.9;
  background: #f9f9f9;
  padding: 1rem;
  border-radius: 0.3rem;
}

/* ---------------------TITRES PARTIES--------------------- */
article h4 {
  font-family: "Baskerville", serif;
  font-weight: 650;
  font-size: clamp(1.2rem, 4vw, 1.5rem); 
  margin: 1rem 0 0.5rem 0;
  border-bottom: 2px solid #111;
  padding-bottom: 0.5rem;
  color: #444;
}

article h2 {
  font-family: "Baskerville", serif;
  font-weight: 700;
  font-size: clamp(1.5rem, 4vw, 2rem); 
  margin: 2.5rem 0 0.5rem 0;
  color: #222;
}

article h3 {
  font-family: "Baskerville", serif;
  font-weight: 600;
  font-size: clamp(1.2rem, 4vw, 1.5rem); 
  margin: 2rem 0 0.75rem 0;
  color: #FD8916;
}

/* ---------------------TEXTE--------------------- */
article p {
  font-family: "Georgia", serif;
  font-size: clamp(1rem, 2.2vw, 1.1rem); 
  margin-bottom: 1.5rem;
  text-align: justify;
  line-height: 1.9;
  color: #333;
}

.ajout {
  font-weight: bold;
  color: #3366CC;
  cursor: pointer;
}

.tooltip-box { 
  position: absolute; 
  background: rgba(14,40,65); 
  color: #fff; padding: 0.4rem 0.6rem; 
  border-radius: 0.2rem; font-size: 0.95rem; 
  max-width: 90vw; 
  z-index: 9999; 
  pointer-events: auto; opacity: 0; transition: opacity 0.2s;
 }

.tooltip-box.show {
  opacity: 1;
}

/* ---------------------IMAGES--------------------- */
article img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 0.5rem;
  object-fit: cover;
  margin: 0 auto 1rem auto;
}

/* ---------------------ARTICLES SUGGÉRÉS + HEADER ?--------------------- */

.related-articles {
  margin-top: 4rem;
}

.related-articles h5 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}

.related-articles h5 {
  color: #0E2841;
}

.related-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr; 
}

.related-grid article {
  border: 0.0625rem solid #111;
  border-radius: 0.5rem;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, background 0.2s ease;
  background: #fff;
}

.related-grid article h6 {
  opacity: 0.8;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
  font-weight: normal;
  line-height: 1.6;
  margin: 0.3rem 0 0.6rem 0;
  color: #222;
}



.related-grid article:hover {
  transform: translateY(-0.2rem);
  background: #f5f5f5;
}

.related-grid article img {
  width: 100%;
  max-width: 600px;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.img-description {
  text-align: center;
  color: #444;
  font-size: 0.95rem;
  margin-top: -0.4rem;
  font-style: italic;
}


.related-grid article h5 {
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
}

.article-icon {
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2.5rem;   
  margin-top: 2rem;
  margin-bottom: 2rem;
}

.related-grid article a {
  margin-top: auto;
  font-weight: bold;
  text-decoration: none;
  align-self: flex-start;
}

.related-grid article a:hover {
  text-decoration: underline;
}


/* ---------------------BAS PAGE--------------------- */
footer {
  background: #0E2841;
  color: #FD8916;
  text-align: center;
  padding: 1.5rem 0;
  font-size: 0.85rem;
  margin-top: 5vh;
}

footer a {
  color: #FD8916;
  text-decoration: none;
  font-weight: 400;
  transition: opacity 0.2s ease;
}

footer a:hover {
  opacity: 0.7; 
}

/* ---------------------Appliquer css si--------------------- */
@media (max-width: 48em) {
  header .wrapper {
    gap: 0.85rem;
}
  header .wrapper_2 {
    align-items: center;
}
}

@media (min-width: 48em) {
  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  header .wrapper {
    flex-direction: row;
    justify-content: space-between;
    padding: 1.2rem 0;
  }
  header h1 {
    font-size: 2rem;
  }
  nav ul {
    gap: 1.5rem;
  }
  article h4 {
    font-size: clamp(1.4rem, 2vw, 1.8rem);
  }
  article h2 {
    font-size: clamp(1.8rem, 2.5vw, 2.5rem);
  }
  article h3 {
    font-size: clamp(1.4rem, 2vw, 1.8rem);
  }
  .ajout {
    font-size: clamp(1.1rem, 1.1vw, 1.5rem);
  }
  .related-articles h3 {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
  }
  .related-grid {
    display: grid;
    gap: 2rem;
  }
  footer {
    padding: 2rem 0;
    font-size: 0.9rem;
  }
}
 
@media (min-width: 64em) {
  .related-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  header .wrapper {
    flex-direction: row;
    justify-content: space-between;
    padding: 1.2rem 0;
  }
  header h1 {
    font-size: 2rem;
  }
  nav ul {
    gap: 1.5rem;
  }
  article h4 {
    font-size: clamp(1.4rem, 2vw, 1.8rem);
  }
  article h2 {
    font-size: clamp(1.8rem, 2.5vw, 2.5rem);
  }
  article h3 {
    font-size: clamp(1.4rem, 2vw, 1.8rem);
  }

  }
  .ajout {
    font-size: clamp(1.1rem, 1.1vw, 1.5rem);
  }
  .related-articles h3 {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
  }
  .related-grid {
    display: grid;
    gap: 2rem;
  }
  footer {
    padding: 2rem 0;
    font-size: 0.9rem;
  }
